text
stringlengths
559
401k
source
stringlengths
13
121
In mathematics and computer science, an algorithm ( ) is a finite sequence of mathematically rigorous instructions, typically used to solve a class of specific problems or to perform a computation. Algorithms are used as specifications for performing calculations and data processing. More advanced algorithms can use conditionals to divert the code execution through various routes (referred to as automated decision-making) and deduce valid inferences (referred to as automated reasoning). In contrast, a heuristic is an approach to solving problems without well-defined correct or optimal results. For example, although social media recommender systems are commonly called "algorithms", they actually rely on heuristics as there is no truly "correct" recommendation. As an effective method, an algorithm can be expressed within a finite amount of space and time and in a well-defined formal language for calculating a function. Starting from an initial state and initial input (perhaps empty), the instructions describe a computation that, when executed, proceeds through a finite number of well-defined successive states, eventually producing "output" and terminating at a final ending state. The transition from one state to the next is not necessarily deterministic; some algorithms, known as randomized algorithms, incorporate random input. == Etymology == Around 825 AD, Persian scientist and polymath Muḥammad ibn Mūsā al-Khwārizmī wrote kitāb al-ḥisāb al-hindī ("Book of Indian computation") and kitab al-jam' wa'l-tafriq al-ḥisāb al-hindī ("Addition and subtraction in Indian arithmetic"). In the early 12th century, Latin translations of these texts involving the Hindu–Arabic numeral system and arithmetic appeared, for example Liber Alghoarismi de practica arismetrice, attributed to John of Seville, and Liber Algorismi de numero Indorum, attributed to Adelard of Bath. Here, alghoarismi or algorismi is the Latinization of Al-Khwarizmi's name; the text starts with the phrase Dixit Algorismi, or "Thus spoke Al-Khwarizmi". The word algorism in English came to mean the use of place-value notation in calculations; it occurs in the Ancrene Wisse from circa 1225. By the time Geoffrey Chaucer wrote The Canterbury Tales in the late 14th century, he used a variant of the same word in describing augrym stones, stones used for place-value calculation. In the 15th century, under the influence of the Greek word ἀριθμός (arithmos, "number"; cf. "arithmetic"), the Latin word was altered to algorithmus. By 1596, this form of the word was used in English, as algorithm, by Thomas Hood. == Definition == One informal definition is "a set of rules that precisely defines a sequence of operations", which would include all computer programs (including programs that do not perform numeric calculations), and any prescribed bureaucratic procedure or cook-book recipe. In general, a program is an algorithm only if it stops eventually—even though infinite loops may sometimes prove desirable. Boolos, Jeffrey & 1974, 1999 define an algorithm to be an explicit set of instructions for determining an output, that can be followed by a computing machine or a human who could only carry out specific elementary operations on symbols. Most algorithms are intended to be implemented as computer programs. However, algorithms are also implemented by other means, such as in a biological neural network (for example, the human brain performing arithmetic or an insect looking for food), in an electrical circuit, or a mechanical device. == History == === Ancient algorithms === Step-by-step procedures for solving mathematical problems have been recorded since antiquity. This includes in Babylonian mathematics (around 2500 BC), Egyptian mathematics (around 1550 BC), Indian mathematics (around 800 BC and later), the Ifa Oracle (around 500 BC), Greek mathematics (around 240 BC), Chinese mathematics (around 200 BC and later), and Arabic mathematics (around 800 AD). The earliest evidence of algorithms is found in ancient Mesopotamian mathematics. A Sumerian clay tablet found in Shuruppak near Baghdad and dated to c. 2500 BC describes the earliest division algorithm. During the Hammurabi dynasty c. 1800 – c. 1600 BC, Babylonian clay tablets described algorithms for computing formulas. Algorithms were also used in Babylonian astronomy. Babylonian clay tablets describe and employ algorithmic procedures to compute the time and place of significant astronomical events. Algorithms for arithmetic are also found in ancient Egyptian mathematics, dating back to the Rhind Mathematical Papyrus c. 1550 BC. Algorithms were later used in ancient Hellenistic mathematics. Two examples are the Sieve of Eratosthenes, which was described in the Introduction to Arithmetic by Nicomachus,: Ch 9.2  and the Euclidean algorithm, which was first described in Euclid's Elements (c. 300 BC).: Ch 9.1 Examples of ancient Indian mathematics included the Shulba Sutras, the Kerala School, and the Brāhmasphuṭasiddhānta. The first cryptographic algorithm for deciphering encrypted code was developed by Al-Kindi, a 9th-century Arab mathematician, in A Manuscript On Deciphering Cryptographic Messages. He gave the first description of cryptanalysis by frequency analysis, the earliest codebreaking algorithm. === Computers === ==== Weight-driven clocks ==== Bolter credits the invention of the weight-driven clock as "the key invention [of Europe in the Middle Ages]," specifically the verge escapement mechanism producing the tick and tock of a mechanical clock. "The accurate automatic machine" led immediately to "mechanical automata" in the 13th century and "computational machines"—the difference and analytical engines of Charles Babbage and Ada Lovelace in the mid-19th century. Lovelace designed the first algorithm intended for processing on a computer, Babbage's analytical engine, which is the first device considered a real Turing-complete computer instead of just a calculator. Although the full implementation of Babbage's second device was not realized for decades after her lifetime, Lovelace has been called "history's first programmer". ==== Electromechanical relay ==== Bell and Newell (1971) write that the Jacquard loom, a precursor to Hollerith cards (punch cards), and "telephone switching technologies" led to the development of the first computers. By the mid-19th century, the telegraph, the precursor of the telephone, was in use throughout the world. By the late 19th century, the ticker tape (c. 1870s) was in use, as were Hollerith cards (c. 1890). Then came the teleprinter (c. 1910) with its punched-paper use of Baudot code on tape. Telephone-switching networks of electromechanical relays were invented in 1835. These led to the invention of the digital adding device by George Stibitz in 1937. While working in Bell Laboratories, he observed the "burdensome" use of mechanical calculators with gears. "He went home one evening in 1937 intending to test his idea... When the tinkering was over, Stibitz had constructed a binary adding device". === Formalization === In 1928, a partial formalization of the modern concept of algorithms began with attempts to solve the Entscheidungsproblem (decision problem) posed by David Hilbert. Later formalizations were framed as attempts to define "effective calculability" or "effective method". Those formalizations included the Gödel–Herbrand–Kleene recursive functions of 1930, 1934 and 1935, Alonzo Church's lambda calculus of 1936, Emil Post's Formulation 1 of 1936, and Alan Turing's Turing machines of 1936–37 and 1939. == Representations == Algorithms can be expressed in many kinds of notation, including natural languages, pseudocode, flowcharts, drakon-charts, programming languages or control tables (processed by interpreters). Natural language expressions of algorithms tend to be verbose and ambiguous and are rarely used for complex or technical algorithms. Pseudocode, flowcharts, drakon-charts, and control tables are structured expressions of algorithms that avoid common ambiguities of natural language. Programming languages are primarily for expressing algorithms in a computer-executable form but are also used to define or document algorithms. === Turing machines === There are many possible representations and Turing machine programs can be expressed as a sequence of machine tables (see finite-state machine, state-transition table, and control table for more), as flowcharts and drakon-charts (see state diagram for more), as a form of rudimentary machine code or assembly code called "sets of quadruples", and more. Algorithm representations can also be classified into three accepted levels of Turing machine description: high-level description, implementation description, and formal description. A high-level description describes the qualities of the algorithm itself, ignoring how it is implemented on the Turing machine. An implementation description describes the general manner in which the machine moves its head and stores data to carry out the algorithm, but does not give exact states. In the most detail, a formal description gives the exact state table and list of transitions of the Turing machine. === Flowchart representation === The graphical aid called a flowchart offers a way to describe and document an algorithm (and a computer program corresponding to it). It has four primary symbols: arrows showing program flow, rectangles (SEQUENCE, GOTO), diamonds (IF-THEN-ELSE), and dots (OR-tie). Sub-structures can "nest" in rectangles, but only if a single exit occurs from the superstructure. == Algorithmic analysis == It is often important to know how much time, storage, or other cost an algorithm may require. Methods have been developed for the analysis of algorithms to obtain such quantitative answers (estimates); for example, an algorithm that adds up the elements of a list of n numbers would have a time requirement of ⁠ O ( n ) {\displaystyle O(n)} ⁠, using big O notation. The algorithm only needs to remember two values: the sum of all the elements so far, and its current position in the input list. If the space required to store the input numbers is not counted, it has a space requirement of ⁠ O ( 1 ) {\displaystyle O(1)} ⁠, otherwise ⁠ O ( n ) {\displaystyle O(n)} ⁠ is required. Different algorithms may complete the same task with a different set of instructions in less or more time, space, or 'effort' than others. For example, a binary search algorithm (with cost ⁠ O ( log ⁡ n ) {\displaystyle O(\log n)} ⁠) outperforms a sequential search (cost ⁠ O ( n ) {\displaystyle O(n)} ⁠ ) when used for table lookups on sorted lists or arrays. === Formal versus empirical === The analysis, and study of algorithms is a discipline of computer science. Algorithms are often studied abstractly, without referencing any specific programming language or implementation. Algorithm analysis resembles other mathematical disciplines as it focuses on the algorithm's properties, not implementation. Pseudocode is typical for analysis as it is a simple and general representation. Most algorithms are implemented on particular hardware/software platforms and their algorithmic efficiency is tested using real code. The efficiency of a particular algorithm may be insignificant for many "one-off" problems but it may be critical for algorithms designed for fast interactive, commercial, or long-life scientific usage. Scaling from small n to large n frequently exposes inefficient algorithms that are otherwise benign. Empirical testing is useful for uncovering unexpected interactions that affect performance. Benchmarks may be used to compare before/after potential improvements to an algorithm after program optimization. Empirical tests cannot replace formal analysis, though, and are non-trivial to perform fairly. === Execution efficiency === To illustrate the potential improvements possible even in well-established algorithms, a recent significant innovation, relating to FFT algorithms (used heavily in the field of image processing), can decrease processing time up to 1,000 times for applications like medical imaging. In general, speed improvements depend on special properties of the problem, which are very common in practical applications. Speedups of this magnitude enable computing devices that make extensive use of image processing (like digital cameras and medical equipment) to consume less power. === Best Case and Worst Case === The best case of an algorithm refers to the scenario or input for which the algorithm or data structure takes the least time and resources to complete its tasks. The worst case of an algorithm is the case that causes the algorithm or data structure to consume the maximum period of time and computational resources. == Design == Algorithm design is a method or mathematical process for problem-solving and engineering algorithms. The design of algorithms is part of many solution theories, such as divide-and-conquer or dynamic programming within operation research. Techniques for designing and implementing algorithm designs are also called algorithm design patterns, with examples including the template method pattern and the decorator pattern. One of the most important aspects of algorithm design is resource (run-time, memory usage) efficiency; the big O notation is used to describe e.g., an algorithm's run-time growth as the size of its input increases. === Structured programming === Per the Church–Turing thesis, any algorithm can be computed by any Turing complete model. Turing completeness only requires four instruction types—conditional GOTO, unconditional GOTO, assignment, HALT. However, Kemeny and Kurtz observe that, while "undisciplined" use of unconditional GOTOs and conditional IF-THEN GOTOs can result in "spaghetti code", a programmer can write structured programs using only these instructions; on the other hand "it is also possible, and not too hard, to write badly structured programs in a structured language". Tausworthe augments the three Böhm-Jacopini canonical structures: SEQUENCE, IF-THEN-ELSE, and WHILE-DO, with two more: DO-WHILE and CASE. An additional benefit of a structured program is that it lends itself to proofs of correctness using mathematical induction. == Legal status == By themselves, algorithms are not usually patentable. In the United States, a claim consisting solely of simple manipulations of abstract concepts, numbers, or signals does not constitute "processes" (USPTO 2006), so algorithms are not patentable (as in Gottschalk v. Benson). However practical applications of algorithms are sometimes patentable. For example, in Diamond v. Diehr, the application of a simple feedback algorithm to aid in the curing of synthetic rubber was deemed patentable. The patenting of software is controversial, and there are criticized patents involving algorithms, especially data compression algorithms, such as Unisys's LZW patent. Additionally, some cryptographic algorithms have export restrictions (see export of cryptography). == Classification == === By implementation === Recursion A recursive algorithm invokes itself repeatedly until meeting a termination condition and is a common functional programming method. Iterative algorithms use repetitions such as loops or data structures like stacks to solve problems. Problems may be suited for one implementation or the other. The Tower of Hanoi is a puzzle commonly solved using recursive implementation. Every recursive version has an equivalent (but possibly more or less complex) iterative version, and vice versa. Serial, parallel or distributed Algorithms are usually discussed with the assumption that computers execute one instruction of an algorithm at a time on serial computers. Serial algorithms are designed for these environments, unlike parallel or distributed algorithms. Parallel algorithms take advantage of computer architectures where multiple processors can work on a problem at the same time. Distributed algorithms use multiple machines connected via a computer network. Parallel and distributed algorithms divide the problem into subproblems and collect the results back together. Resource consumption in these algorithms is not only processor cycles on each processor but also the communication overhead between the processors. Some sorting algorithms can be parallelized efficiently, but their communication overhead is expensive. Iterative algorithms are generally parallelizable, but some problems have no parallel algorithms and are called inherently serial problems. Deterministic or non-deterministic Deterministic algorithms solve the problem with exact decisions at every step; whereas non-deterministic algorithms solve problems via guessing. Guesses are typically made more accurate through the use of heuristics. Exact or approximate While many algorithms reach an exact solution, approximation algorithms seek an approximation that is close to the true solution. Such algorithms have practical value for many hard problems. For example, the Knapsack problem, where there is a set of items, and the goal is to pack the knapsack to get the maximum total value. Each item has some weight and some value. The total weight that can be carried is no more than some fixed number X. So, the solution must consider the weights of items as well as their value. Quantum algorithm Quantum algorithms run on a realistic model of quantum computation. The term is usually used for those algorithms that seem inherently quantum or use some essential feature of Quantum computing such as quantum superposition or quantum entanglement. === By design paradigm === Another way of classifying algorithms is by their design methodology or paradigm. Some common paradigms are: Brute-force or exhaustive search Brute force is a problem-solving method of systematically trying every possible option until the optimal solution is found. This approach can be very time-consuming, testing every possible combination of variables. It is often used when other methods are unavailable or too complex. Brute force can solve a variety of problems, including finding the shortest path between two points and cracking passwords. Divide and conquer A divide-and-conquer algorithm repeatedly reduces a problem to one or more smaller instances of itself (usually recursively) until the instances are small enough to solve easily. Merge sorting is an example of divide and conquer, where an unordered list is repeatedly split into smaller lists, which are sorted in the same way and then merged. In a simpler variant of divide and conquer called prune and search or decrease-and-conquer algorithm, which solves one smaller instance of itself, and does not require a merge step. An example of a prune and search algorithm is the binary search algorithm. Search and enumeration Many problems (such as playing chess) can be modelled as problems on graphs. A graph exploration algorithm specifies rules for moving around a graph and is useful for such problems. This category also includes search algorithms, branch and bound enumeration, and backtracking. Randomized algorithm Such algorithms make some choices randomly (or pseudo-randomly). They find approximate solutions when finding exact solutions may be impractical (see heuristic method below). For some problems, the fastest approximations must involve some randomness. Whether randomized algorithms with polynomial time complexity can be the fastest algorithm for some problems is an open question known as the P versus NP problem. There are two large classes of such algorithms: Monte Carlo algorithms return a correct answer with high probability. E.g. RP is the subclass of these that run in polynomial time. Las Vegas algorithms always return the correct answer, but their running time is only probabilistically bound, e.g. ZPP. Reduction of complexity This technique transforms difficult problems into better-known problems solvable with (hopefully) asymptotically optimal algorithms. The goal is to find a reducing algorithm whose complexity is not dominated by the resulting reduced algorithms. For example, one selection algorithm finds the median of an unsorted list by first sorting the list (the expensive portion), and then pulling out the middle element in the sorted list (the cheap portion). This technique is also known as transform and conquer. Back tracking In this approach, multiple solutions are built incrementally and abandoned when it is determined that they cannot lead to a valid full solution. === Optimization problems === For optimization problems there is a more specific classification of algorithms; an algorithm for such problems may fall into one or more of the general categories described above as well as into one of the following: Linear programming When searching for optimal solutions to a linear function bound by linear equality and inequality constraints, the constraints can be used directly to produce optimal solutions. There are algorithms that can solve any problem in this category, such as the popular simplex algorithm. Problems that can be solved with linear programming include the maximum flow problem for directed graphs. If a problem also requires that any of the unknowns be integers, then it is classified in integer programming. A linear programming algorithm can solve such a problem if it can be proved that all restrictions for integer values are superficial, i.e., the solutions satisfy these restrictions anyway. In the general case, a specialized algorithm or an algorithm that finds approximate solutions is used, depending on the difficulty of the problem. Dynamic programming When a problem shows optimal substructures—meaning the optimal solution can be constructed from optimal solutions to subproblems—and overlapping subproblems, meaning the same subproblems are used to solve many different problem instances, a quicker approach called dynamic programming avoids recomputing solutions. For example, Floyd–Warshall algorithm, the shortest path between a start and goal vertex in a weighted graph can be found using the shortest path to the goal from all adjacent vertices. Dynamic programming and memoization go together. Unlike divide and conquer, dynamic programming subproblems often overlap. The difference between dynamic programming and simple recursion is the caching or memoization of recursive calls. When subproblems are independent and do not repeat, memoization does not help; hence dynamic programming is not applicable to all complex problems. Using memoization dynamic programming reduces the complexity of many problems from exponential to polynomial. The greedy method Greedy algorithms, similarly to a dynamic programming, work by examining substructures, in this case not of the problem but of a given solution. Such algorithms start with some solution and improve it by making small modifications. For some problems, they always find the optimal solution but for others they may stop at local optima. The most popular use of greedy algorithms is finding minimal spanning trees of graphs without negative cycles. Huffman Tree, Kruskal, Prim, Sollin are greedy algorithms that can solve this optimization problem. The heuristic method In optimization problems, heuristic algorithms find solutions close to the optimal solution when finding the optimal solution is impractical. These algorithms get closer and closer to the optimal solution as they progress. In principle, if run for an infinite amount of time, they will find the optimal solution. They can ideally find a solution very close to the optimal solution in a relatively short time. These algorithms include local search, tabu search, simulated annealing, and genetic algorithms. Some, like simulated annealing, are non-deterministic algorithms while others, like tabu search, are deterministic. When a bound on the error of the non-optimal solution is known, the algorithm is further categorized as an approximation algorithm. == Examples == One of the simplest algorithms finds the largest number in a list of numbers of random order. Finding the solution requires looking at every number in the list. From this follows a simple algorithm, which can be described in plain English as: High-level description: If a set of numbers is empty, then there is no highest number. Assume the first number in the set is the largest. For each remaining number in the set: if this number is greater than the current largest, it becomes the new largest. When there are no unchecked numbers left in the set, consider the current largest number to be the largest in the set. (Quasi-)formal description: Written in prose but much closer to the high-level language of a computer program, the following is the more formal coding of the algorithm in pseudocode or pidgin code: == See also == == Notes == == Bibliography == Zaslavsky, C. (1970). Mathematics of the Yoruba People and of Their Neighbors in Southern Nigeria. The Two-Year College Mathematics Journal, 1(2), 76–99. https://doi.org/10.2307/3027363 == Further reading == == External links == "Algorithm". Encyclopedia of Mathematics. EMS Press. 2001 [1994]. Weisstein, Eric W. "Algorithm". MathWorld. Dictionary of Algorithms and Data Structures – National Institute of Standards and Technology Algorithm repositories The Stony Brook Algorithm Repository – State University of New York at Stony Brook Collected Algorithms of the ACM – Associations for Computing Machinery The Stanford GraphBase Archived December 6, 2015, at the Wayback Machine – Stanford University
Wikipedia/Algorithm
A geographic information system (GIS) consists of integrated computer hardware and software that store, manage, analyze, edit, output, and visualize geographic data. Much of this often happens within a spatial database; however, this is not essential to meet the definition of a GIS. In a broader sense, one may consider such a system also to include human users and support staff, procedures and workflows, the body of knowledge of relevant concepts and methods, and institutional organizations. The uncounted plural, geographic information systems, also abbreviated GIS, is the most common term for the industry and profession concerned with these systems. The academic discipline that studies these systems and their underlying geographic principles, may also be abbreviated as GIS, but the unambiguous GIScience is more common. GIScience is often considered a subdiscipline of geography within the branch of technical geography. Geographic information systems are utilized in multiple technologies, processes, techniques and methods. They are attached to various operations and numerous applications, that relate to: engineering, planning, management, transport/logistics, insurance, telecommunications, and business, as well as the natural sciences such as forestry, ecology, and Earth science. For this reason, GIS and location intelligence applications are at the foundation of location-enabled services, which rely on geographic analysis and visualization. GIS provides the ability to relate previously unrelated information, through the use of location as the "key index variable". Locations and extents that are found in the Earth's spacetime are able to be recorded through the date and time of occurrence, along with x, y, and z coordinates; representing, longitude (x), latitude (y), and elevation (z). All Earth-based, spatial–temporal, location and extent references should be relatable to one another, and ultimately, to a "real" physical location or extent. This key characteristic of GIS has begun to open new avenues of scientific inquiry and studies. == History and development == While digital GIS dates to the mid-1960s, when Roger Tomlinson first coined the phrase "geographic information system", many of the geographic concepts and methods that GIS automates date back decades earlier. One of the first known instances in which spatial analysis was used came from the field of epidemiology in the Rapport sur la marche et les effets du choléra dans Paris et le département de la Seine (1832). French cartographer and geographer Charles Picquet created a map outlining the forty-eight districts in Paris, using halftone color gradients, to provide a visual representation for the number of reported deaths due to cholera per every 1,000 inhabitants. In 1854, John Snow, an epidemiologist and physician, was able to determine the source of a cholera outbreak in London through the use of spatial analysis. Snow achieved this through plotting the residence of each casualty on a map of the area, as well as the nearby water sources. Once these points were marked, he was able to identify the water source within the cluster that was responsible for the outbreak. This was one of the earliest successful uses of a geographic methodology in pinpointing the source of an outbreak in epidemiology. While the basic elements of topography and theme existed previously in cartography, Snow's map was unique due to his use of cartographic methods, not only to depict, but also to analyze clusters of geographically dependent phenomena. The early 20th century saw the development of photozincography, which allowed maps to be split into layers, for example one layer for vegetation and another for water. This was particularly used for printing contours – drawing these was a labour-intensive task but having them on a separate layer meant they could be worked on without the other layers to confuse the draughtsman. This work was initially drawn on glass plates, but later plastic film was introduced, with the advantages of being lighter, using less storage space and being less brittle, among others. When all the layers were finished, they were combined into one image using a large process camera. Once color printing came in, the layers idea was also used for creating separate printing plates for each color. While the use of layers much later became one of the typical features of a contemporary GIS, the photographic process just described is not considered a GIS in itself – as the maps were just images with no database to link them to. Two additional developments are notable in the early days of GIS: Ian McHarg's publication Design with Nature and its map overlay method and the introduction of a street network into the U.S. Census Bureau's DIME (Dual Independent Map Encoding) system. The first publication detailing the use of computers to facilitate cartography was written by Waldo Tobler in 1959. Further computer hardware development spurred by nuclear weapon research led to more widespread general-purpose computer "mapping" applications by the early 1960s. In 1963, the world's first true operational GIS was developed in Ottawa, Ontario, Canada, by the federal Department of Forestry and Rural Development. Developed by Roger Tomlinson, it was called the Canada Geographic Information System (CGIS) and was used to store, analyze, and manipulate data collected for the Canada Land Inventory, an effort to determine the land capability for rural Canada by mapping information about soils, agriculture, recreation, wildlife, waterfowl, forestry and land use at a scale of 1:50,000. A rating classification factor was also added to permit analysis. CGIS was an improvement over "computer mapping" applications as it provided capabilities for data storage, overlay, measurement, and digitizing/scanning. It supported a national coordinate system that spanned the continent, coded lines as arcs having a true embedded topology and it stored the attribute and locational information in separate files. As a result of this, Tomlinson has become known as the "father of GIS", particularly for his use of overlays in promoting the spatial analysis of convergent geographic data. CGIS lasted into the 1990s and built a large digital land resource database in Canada. It was developed as a mainframe-based system in support of federal and provincial resource planning and management. Its strength was continent-wide analysis of complex datasets. The CGIS was never available commercially. In 1964, Howard T. Fisher formed the Laboratory for Computer Graphics and Spatial Analysis at the Harvard Graduate School of Design (LCGSA 1965–1991), where a number of important theoretical concepts in spatial data handling were developed, and which by the 1970s had distributed seminal software code and systems, such as SYMAP, GRID, and ODYSSEY, to universities, research centers and corporations worldwide. These programs were the first examples of general-purpose GIS software that was not developed for a particular installation, and was very influential on future commercial software, such as Esri ARC/INFO, released in 1983. By the late 1970s, two public domain GIS systems (MOSS and GRASS GIS) were in development, and by the early 1980s, M&S Computing (later Intergraph) along with Bentley Systems Incorporated for the CAD platform, Environmental Systems Research Institute (ESRI), CARIS (Computer Aided Resource Information System), and ERDAS (Earth Resource Data Analysis System) emerged as commercial vendors of GIS software, successfully incorporating many of the CGIS features, combining the first-generation approach to separation of spatial and attribute information with a second-generation approach to organizing attribute data into database structures. In 1986, Mapping Display and Analysis System (MIDAS), the first desktop GIS product, was released for the DOS operating system. This was renamed in 1990 to MapInfo for Windows when it was ported to the Microsoft Windows platform. This began the process of moving GIS from the research department into the business environment. By the end of the 20th century, the rapid growth in various systems had been consolidated and standardized on relatively few platforms and users were beginning to explore viewing GIS data over the Internet, requiring data format and transfer standards. More recently, a growing number of free, open-source GIS packages run on a range of operating systems and can be customized to perform specific tasks. The major trend of the 21st Century has been the integration of GIS capabilities with other Information technology and Internet infrastructure, such as relational databases, cloud computing, software as a service (SAAS), and mobile computing. == GIS software == The distinction must be made between a singular geographic information system, which is a single installation of software and data for a particular use, along with associated hardware, staff, and institutions (e.g., the GIS for a particular city government); and GIS software, a general-purpose application program that is intended to be used in many individual geographic information systems in a variety of application domains.: 16  Starting in the late 1970s, many software packages have been created specifically for GIS applications. Esri's ArcGIS, which includes ArcGIS Pro and the legacy software ArcMap, currently dominates the GIS market. Other examples of GIS include Autodesk and MapInfo Professional and open-source programs such as QGIS, GRASS GIS, MapGuide, and Hadoop-GIS. These and other desktop GIS applications include a full suite of capabilities for entering, managing, analyzing, and visualizing geographic data, and are designed to be used on their own. Starting in the late 1990s with the emergence of the Internet, as computer network technology progressed, GIS infrastructure and data began to move to servers, providing another mechanism for providing GIS capabilities.: 216  This was facilitated by standalone software installed on a server, similar to other server software such as HTTP servers and relational database management systems, enabling clients to have access to GIS data and processing tools without having to install specialized desktop software. These networks are known as distributed GIS. This strategy has been extended through the Internet and development of cloud-based GIS platforms such as ArcGIS Online and GIS-specialized software as a service (SAAS). The use of the Internet to facilitate distributed GIS is known as Internet GIS. An alternative approach is the integration of some or all of these capabilities into other software or information technology architectures. One example is a spatial extension to Object-relational database software, which defines a geometry datatype so that spatial data can be stored in relational tables, and extensions to SQL for spatial analysis operations such as overlay. Another example is the proliferation of geospatial libraries and application programming interfaces (e.g., GDAL, Leaflet, D3.js) that extend programming languages to enable the incorporation of GIS data and processing into custom software, including web mapping sites and location-based services in smartphones. == Geospatial data management == The core of any GIS is a database that contains representations of geographic phenomena, modeling their geometry (location and shape) and their properties or attributes. A GIS database may be stored in a variety of forms, such as a collection of separate data files or a single spatially-enabled relational database. Collecting and managing these data usually constitutes the bulk of the time and financial resources of a project, far more than other aspects such as analysis and mapping.: 175  === Aspects of geographic data === GIS uses spatio-temporal (space-time) location as the key index variable for all other information. Just as a relational database containing text or numbers can relate many different tables using common key index variables, GIS can relate otherwise unrelated information by using location as the key index variable. The key is the location and/or extent in space-time. Any variable that can be located spatially, and increasingly also temporally, can be referenced using a GIS. Locations or extents in Earth space–time may be recorded as dates/times of occurrence, and x, y, and z coordinates representing, longitude, latitude, and elevation, respectively. These GIS coordinates may represent other quantified systems of temporo-spatial reference (for example, film frame number, stream gage station, highway mile-marker, surveyor benchmark, building address, street intersection, entrance gate, water depth sounding, POS or CAD drawing origin/units). Units applied to recorded temporal-spatial data can vary widely (even when using exactly the same data, see map projections), but all Earth-based spatial–temporal location and extent references should, ideally, be relatable to one another and ultimately to a "real" physical location or extent in space–time. Related by accurate spatial information, an incredible variety of real-world and projected past or future data can be analyzed, interpreted and represented. This key characteristic of GIS has begun to open new avenues of scientific inquiry into behaviors and patterns of real-world information that previously had not been systematically correlated. === Data modeling === GIS data represents phenomena that exist in the real world, such as roads, land use, elevation, trees, waterways, and states. The most common types of phenomena that are represented in data can be divided into two conceptualizations: discrete objects (e.g., a house, a road) and continuous fields (e.g., rainfall amount or population density). : 62–65  Other types of geographic phenomena, such as events (e.g., location of World War II battles), processes (e.g., extent of suburbanization), and masses (e.g., types of soil in an area) are represented less commonly or indirectly, or are modeled in analysis procedures rather than data. Traditionally, there are two broad methods used to store data in a GIS for both kinds of abstractions mapping references: raster images and vector. Points, lines, and polygons represent vector data of mapped location attribute references. A new hybrid method of storing data is that of identifying point clouds, which combine three-dimensional points with RGB information at each point, returning a 3D color image. GIS thematic maps then are becoming more and more realistically visually descriptive of what they set out to show or determine. === Data acquisition === GIS data acquisition includes several methods for gathering spatial data into a GIS database, which can be grouped into three categories: primary data capture, the direct measurement phenomena in the field (e.g., remote sensing, the global positioning system); secondary data capture, the extraction of information from existing sources that are not in a GIS form, such as paper maps, through digitization; and data transfer, the copying of existing GIS data from external sources such as government agencies and private companies. All of these methods can consume significant time, finances, and other resources.: 173  ==== Primary data capture ==== Survey data can be directly entered into a GIS from digital data collection systems on survey instruments using a technique called coordinate geometry (COGO). Positions from a global navigation satellite system (GNSS) like the Global Positioning System can also be collected and then imported into a GIS. A current trend in data collection gives users the ability to utilize field computers with the ability to edit live data using wireless connections or disconnected editing sessions. The current trend is to utilize applications available on smartphones and PDAs in the form of mobile GIS. This has been enhanced by the availability of low-cost mapping-grade GPS units with decimeter accuracy in real time. This eliminates the need to post process, import, and update the data in the office after fieldwork has been collected. This includes the ability to incorporate positions collected using a laser rangefinder. New technologies also allow users to create maps as well as analysis directly in the field, making projects more efficient and mapping more accurate. Remotely sensed data also plays an important role in data collection and consist of sensors attached to a platform. Sensors include cameras, digital scanners and lidar, while platforms usually consist of aircraft and satellites. In England in the mid-1990s, hybrid kite/balloons called helikites first pioneered the use of compact airborne digital cameras as airborne geo-information systems. Aircraft measurement software, accurate to 0.4 mm, was used to link the photographs and measure the ground. Helikites are inexpensive and gather more accurate data than aircraft. Helikites can be used over roads, railways and towns where unmanned aerial vehicles (UAVs) are banned. Recently, aerial data collection has become more accessible with miniature UAVs and drones. For example, the Aeryon Scout was used to map a 50-acre area with a ground sample distance of 1 inch (2.54 cm) in only 12 minutes. The majority of digital data currently comes from photo interpretation of aerial photographs. Soft-copy workstations are used to digitize features directly from stereo pairs of digital photographs. These systems allow data to be captured in two and three dimensions, with elevations measured directly from a stereo pair using principles of photogrammetry. Analog aerial photos must be scanned before being entered into a soft-copy system, for high-quality digital cameras this step is skipped. Satellite remote sensing provides another important source of spatial data. Here satellites use different sensor packages to passively measure the reflectance from parts of the electromagnetic spectrum or radio waves that were sent out from an active sensor such as radar. Remote sensing collects raster data that can be further processed using different bands to identify objects and classes of interest, such as land cover. ==== Secondary data capture ==== The most common method of data creation is digitization, where a hard copy map or survey plan is transferred into a digital medium through the use of a CAD program, and geo-referencing capabilities. With the wide availability of ortho-rectified imagery (from satellites, aircraft, Helikites and UAVs), heads-up digitizing is becoming the main avenue through which geographic data is extracted. Heads-up digitizing involves the tracing of geographic data directly on top of the aerial imagery instead of by the traditional method of tracing the geographic form on a separate digitizing tablet (heads-down digitizing). Heads-down digitizing, or manual digitizing, uses a special magnetic pen, or stylus, that feeds information into a computer to create an identical, digital map. Some tablets use a mouse-like tool, called a puck, instead of a stylus. The puck has a small window with cross-hairs which allows for greater precision and pinpointing map features. Though heads-up digitizing is more commonly used, heads-down digitizing is still useful for digitizing maps of poor quality. Existing data printed on paper or PET film maps can be digitized or scanned to produce digital data. A digitizer produces vector data as an operator traces points, lines, and polygon boundaries from a map. Scanning a map results in raster data that could be further processed to produce vector data. When data is captured, the user should consider if the data should be captured with either a relative accuracy or absolute accuracy, since this could not only influence how information will be interpreted but also the cost of data capture. After entering data into a GIS, the data usually requires editing, to remove errors, or further processing. For vector data it must be made "topologically correct" before it can be used for some advanced analysis. For example, in a road network, lines must connect with nodes at an intersection. Errors such as undershoots and overshoots must also be removed. For scanned maps, blemishes on the source map may need to be removed from the resulting raster. For example, a fleck of dirt might connect two lines that should not be connected. === Projections, coordinate systems, and registration === The earth can be represented by various models, each of which may provide a different set of coordinates (e.g., latitude, longitude, elevation) for any given point on the Earth's surface. The simplest model is to assume the earth is a perfect sphere. As more measurements of the earth have accumulated, the models of the earth have become more sophisticated and more accurate. In fact, there are models called datums that apply to different areas of the earth to provide increased accuracy, like North American Datum of 1983 for U.S. measurements, and the World Geodetic System for worldwide measurements. The latitude and longitude on a map made against a local datum may not be the same as one obtained from a GPS receiver. Converting coordinates from one datum to another requires a datum transformation such as a Helmert transformation, although in certain situations a simple translation may be sufficient. In popular GIS software, data projected in latitude/longitude is often represented as a Geographic coordinate system. For example, data in latitude/longitude if the datum is the 'North American Datum of 1983' is denoted by 'GCS North American 1983'. === Data quality === While no digital model can be a perfect representation of the real world, it is important that GIS data be of a high quality. In keeping with the principle of homomorphism, the data must be close enough to reality so that the results of GIS procedures correctly correspond to the results of real world processes. This means that there is no single standard for data quality, because the necessary degree of quality depends on the scale and purpose of the tasks for which it is to be used. Several elements of data quality are important to GIS data: Accuracy The degree of similarity between a represented measurement and the actual value; conversely, error is the amount of difference between them.: 623  In GIS data, there is concern for accuracy in representations of location (positional accuracy), property (attribute accuracy), and time. For example, the US 2020 Census says that the population of Houston on April 1, 2020 was 2,304,580; if it was actually 2,310,674, this would be an error and thus a lack of attribute accuracy. Precision The degree of refinement in a represented value. In a quantitative property, this is the number of significant digits in the measured value.: 115  An imprecise value is vague or ambiguous, including a range of possible values. For example, if one were to say that the population of Houston on April 1, 2020 was "about 2.3 million," this statement would be imprecise, but likely accurate because the correct value (and many incorrect values) are included. As with accuracy, representations of location, property, and time can all be more or less precise. Resolution is a commonly used expression of positional precision, especially in raster data sets. Scale is closely related to precision in maps, as it dictates a desirable level of spatial precision, but is problematic in GIS, where a data set can be shown at a variety of display scales (including scales that would not be appropriate for the quality of the data). Uncertainty A general acknowledgement of the presence of error and imprecision in geographic data.: 99  That is, it is a degree of general doubt, given that it is difficult to know exactly how much error is present in a data set, although some form of estimate may be attempted (a confidence interval being such an estimate of uncertainty). This is sometimes used as a collective term for all or most aspects of data quality. Vagueness or fuzziness The degree to which an aspect (location, property, or time) of a phenomenon is inherently imprecise, rather than the imprecision being in a measured value.: 103  For example, the spatial extent of the Houston metropolitan area is vague, as there are places on the outskirts of the city that are less connected to the central city (measured by activities such as commuting) than places that are closer. Mathematical tools such as fuzzy set theory are commonly used to manage vagueness in geographic data. Completeness The degree to which a data set represents all of the actual features that it purports to include.: 623  For example, if a layer of "roads in Houston" is missing some actual streets, it is incomplete. Currency The most recent point in time at which a data set claims to be an accurate representation of reality. This is a concern for the majority of GIS applications, which attempt to represent the world "at present," in which case older data is of lower quality. Consistency The degree to which the representations of the many phenomena in a data set correctly correspond with each other.: 623  Consistency in topological relationships between spatial objects is an especially important aspect of consistency.: 117  For example, if all of the lines in a street network were accidentally moved 10 meters to the East, they would be inaccurate but still consistent, because they would still properly connect at each intersection, and network analysis tools such as shortest path would still give correct results. Propagation of uncertainty The degree to which the quality of the results of Spatial analysis methods and other processing tools derives from the quality of input data.: 118  For example, interpolation is a common operation used in many ways in GIS; because it generates estimates of values between known measurements, the results will always be more precise, but less certain (as each estimate has an unknown amount of error). The quality of a dataset is very dependent upon its sources, and the methods used to create it. Land surveyors have been able to provide a high level of positional accuracy utilizing high-end GPS equipment, but GPS locations on the average smartphone are much less accurate. Common datasets such as digital terrain and aerial imagery are available in a wide variety of levels of quality, especially spatial precision. Paper maps, which have been digitized for many years as a data source, can also be of widely varying quality. A quantitative analysis of maps brings accuracy issues into focus. The electronic and other equipment used to make measurements for GIS is far more precise than the machines of conventional map analysis. All geographical data are inherently inaccurate, and these inaccuracies will propagate through GIS operations in ways that are difficult to predict. === Raster-to-vector translation === Data restructuring can be performed by a GIS to convert data into different formats. For example, a GIS may be used to convert a satellite image map to a vector structure by generating lines around all cells with the same classification, while determining the cell spatial relationships, such as adjacency or inclusion. More advanced data processing can occur with image processing, a technique developed in the late 1960s by NASA and the private sector to provide contrast enhancement, false color rendering and a variety of other techniques including use of two dimensional Fourier transforms. Since digital data is collected and stored in various ways, the two data sources may not be entirely compatible. So a GIS must be able to convert geographic data from one structure to another. In so doing, the implicit assumptions behind different ontologies and classifications require analysis. Object ontologies have gained increasing prominence as a consequence of object-oriented programming and sustained work by Barry Smith and co-workers. === Spatial ETL === Spatial ETL tools provide the data processing functionality of traditional extract, transform, load (ETL) software, but with a primary focus on the ability to manage spatial data. They provide GIS users with the ability to translate data between different standards and proprietary formats, whilst geometrically transforming the data en route. These tools can come in the form of add-ins to existing wider-purpose software such as spreadsheets. == Spatial analysis == GIS spatial analysis is a rapidly changing field, and GIS packages are increasingly including analytical tools as standard built-in facilities, as optional toolsets, as add-ins or 'analysts'. In many instances these are provided by the original software suppliers (commercial vendors or collaborative non commercial development teams), while in other cases facilities have been developed and are provided by third parties. Furthermore, many products offer software development kits (SDKs), programming languages and language support, scripting facilities and/or special interfaces for developing one's own analytical tools or variants. The increased availability has created a new dimension to business intelligence termed "spatial intelligence" which, when openly delivered via intranet, democratizes access to geographic and social network data. Geospatial intelligence, based on GIS spatial analysis, has also become a key element for security. GIS as a whole can be described as conversion to a vectorial representation or to any other digitisation process. Geoprocessing is a GIS operation used to manipulate spatial data. A typical geoprocessing operation takes an input dataset, performs an operation on that dataset, and returns the result of the operation as an output dataset. Common geoprocessing operations include geographic feature overlay, feature selection and analysis, topology processing, raster processing, and data conversion. Geoprocessing allows for definition, management, and analysis of information used to form decisions. === Terrain analysis === Many geographic tasks involve the terrain, the shape of the surface of the earth, such as hydrology, earthworks, and biogeography. Thus, terrain data is often a core dataset in a GIS, usually in the form of a raster Digital elevation model (DEM) or a Triangulated irregular network (TIN). A variety of tools are available in most GIS software for analyzing terrain, often by creating derivative datasets that represent a specific aspect of the surface. Some of the most common include: Slope or grade is the steepness or gradient of a unit of terrain, usually measured as an angle in degrees or as a percentage. Aspect can be defined as the direction in which a unit of terrain faces. Aspect is usually expressed in degrees from north. Cut and fill is a computation of the difference between the surface before and after an excavation project to estimate costs. Hydrological modeling can provide a spatial element that other hydrological models lack, with the analysis of variables such as slope, aspect and watershed or catchment area. Terrain analysis is fundamental to hydrology, since water always flows down a slope. As basic terrain analysis of a digital elevation model (DEM) involves calculation of slope and aspect, DEMs are very useful for hydrological analysis. Slope and aspect can then be used to determine direction of surface runoff, and hence flow accumulation for the formation of streams, rivers and lakes. Areas of divergent flow can also give a clear indication of the boundaries of a catchment. Once a flow direction and accumulation matrix has been created, queries can be performed that show contributing or dispersal areas at a certain point. More detail can be added to the model, such as terrain roughness, vegetation types and soil types, which can influence infiltration and evapotranspiration rates, and hence influencing surface flow. One of the main uses of hydrological modeling is in environmental contamination research. Other applications of hydrological modeling include groundwater and surface water mapping, as well as flood risk maps. Viewshed analysis predicts the impact that terrain has on the visibility between locations, which is especially important for wireless communications. Shaded relief is a depiction of the surface as if it were a three dimensional model lit from a given direction, which is very commonly used in maps. Most of these are generated using algorithms that are discrete simplifications of vector calculus. Slope, aspect, and surface curvature in terrain analysis are all derived from neighborhood operations using elevation values of a cell's adjacent neighbours. Each of these is strongly affected by the level of detail in the terrain data, such as the resolution of a DEM, which should be chosen carefully. === Proximity analysis === Distance is a key part of solving many geographic tasks, usually due to the friction of distance. Thus, a wide variety of analysis tools have analyze distance in some form, such as buffers, Voronoi or Thiessen polygons, Cost distance analysis, and network analysis. === Data analysis === It is difficult to relate wetlands maps to rainfall amounts recorded at different points such as airports, television stations, and schools. A GIS, however, can be used to depict two- and three-dimensional characteristics of the Earth's surface, subsurface, and atmosphere from information points. For example, a GIS can quickly generate a map with isopleth or contour lines that indicate differing amounts of rainfall. Such a map can be thought of as a rainfall contour map. Many sophisticated methods can estimate the characteristics of surfaces from a limited number of point measurements. A two-dimensional contour map created from the surface modeling of rainfall point measurements may be overlaid and analyzed with any other map in a GIS covering the same area. This GIS derived map can then provide additional information - such as the viability of water power potential as a renewable energy source. Similarly, GIS can be used to compare other renewable energy resources to find the best geographic potential for a region. Additionally, from a series of three-dimensional points, or digital elevation model, isopleth lines representing elevation contours can be generated, along with slope analysis, shaded relief, and other elevation products. Watersheds can be easily defined for any given reach, by computing all of the areas contiguous and uphill from any given point of interest. Similarly, an expected thalweg of where surface water would want to travel in intermittent and permanent streams can be computed from elevation data in the GIS. === Topological modeling === A GIS can recognize and analyze the spatial relationships that exist within digitally stored spatial data. These topological relationships allow complex spatial modelling and analysis to be performed. Topological relationships between geometric entities traditionally include adjacency (what adjoins what), containment (what encloses what), and proximity (how close something is to something else). === Geometric networks === Geometric networks are linear networks of objects that can be used to represent interconnected features, and to perform special spatial analysis on them. A geometric network is composed of edges, which are connected at junction points, similar to graphs in mathematics and computer science. Just like graphs, networks can have weight and flow assigned to its edges, which can be used to represent various interconnected features more accurately. Geometric networks are often used to model road networks and public utility networks, such as electric, gas, and water networks. Network modeling is also commonly employed in transportation planning, hydrology modeling, and infrastructure modeling. === Cartographic modeling === Dana Tomlin coined the term cartographic modeling in his PhD dissertation (1983); he later used it in the title of his book, Geographic Information Systems and Cartographic Modeling (1990). Cartographic modeling refers to a process where several thematic layers of the same area are produced, processed, and analyzed. Tomlin used raster layers, but the overlay method (see below) can be used more generally. Operations on map layers can be combined into algorithms, and eventually into simulation or optimization models. === Map overlay === The combination of several spatial datasets (points, lines, or polygons) creates a new output vector dataset, visually similar to stacking several maps of the same region. These overlays are similar to mathematical Venn diagram overlays. A union overlay combines the geographic features and attribute tables of both inputs into a single new output. An intersect overlay defines the area where both inputs overlap and retains a set of attribute fields for each. A symmetric difference overlay defines an output area that includes the total area of both inputs except for the overlapping area. Data extraction is a GIS process similar to vector overlay, though it can be used in either vector or raster data analysis. Rather than combining the properties and features of both datasets, data extraction involves using a "clip" or "mask" to extract the features of one data set that fall within the spatial extent of another dataset. In raster data analysis, the overlay of datasets is accomplished through a process known as "local operation on multiple rasters" or "map algebra", through a function that combines the values of each raster's matrix. This function may weigh some inputs more than others through use of an "index model" that reflects the influence of various factors upon a geographic phenomenon. === Geostatistics === Geostatistics is a branch of statistics that deals with field data, spatial data with a continuous index. It provides methods to model spatial correlation, and predict values at arbitrary locations (interpolation). When phenomena are measured, the observation methods dictate the accuracy of any subsequent analysis. Due to the nature of the data (e.g. traffic patterns in an urban environment; weather patterns over the Pacific Ocean), a constant or dynamic degree of precision is always lost in the measurement. This loss of precision is determined from the scale and distribution of the data collection. To determine the statistical relevance of the analysis, an average is determined so that points (gradients) outside of any immediate measurement can be included to determine their predicted behavior. This is due to the limitations of the applied statistic and data collection methods, and interpolation is required to predict the behavior of particles, points, and locations that are not directly measurable. Interpolation is the process by which a surface is created, usually a raster dataset, through the input of data collected at a number of sample points. There are several forms of interpolation, each which treats the data differently, depending on the properties of the data set. In comparing interpolation methods, the first consideration should be whether or not the source data will change (exact or approximate). Next is whether the method is subjective, a human interpretation, or objective. Then there is the nature of transitions between points: are they abrupt or gradual. Finally, there is whether a method is global (it uses the entire data set to form the model), or local where an algorithm is repeated for a small section of terrain. Interpolation is a justified measurement because of a spatial autocorrelation principle that recognizes that data collected at any position will have a great similarity to, or influence of those locations within its immediate vicinity. Digital elevation models, triangulated irregular networks, edge-finding algorithms, Thiessen polygons, Fourier analysis, (weighted) moving averages, inverse distance weighting, kriging, spline, and trend surface analysis are all mathematical methods to produce interpolative data. === Address geocoding === Geocoding is interpolating spatial locations (X,Y coordinates) from street addresses or any other spatially referenced data such as ZIP Codes, parcel lots and address locations. A reference theme is required to geocode individual addresses, such as a road centerline file with address ranges. The individual address locations have historically been interpolated, or estimated, by examining address ranges along a road segment. These are usually provided in the form of a table or database. The software will then place a dot approximately where that address belongs along the segment of centerline. For example, an address point of 500 will be at the midpoint of a line segment that starts with address 1 and ends with address 1,000. Geocoding can also be applied against actual parcel data, typically from municipal tax maps. In this case, the result of the geocoding will be an actually positioned space as opposed to an interpolated point. This approach is being increasingly used to provide more precise location information. === Reverse geocoding === Reverse geocoding is the process of returning an estimated street address number as it relates to a given coordinate. For example, a user can click on a road centerline theme (thus providing a coordinate) and have information returned that reflects the estimated house number. This house number is interpolated from a range assigned to that road segment. If the user clicks at the midpoint of a segment that starts with address 1 and ends with 100, the returned value will be somewhere near 50. Note that reverse geocoding does not return actual addresses, only estimates of what should be there based on the predetermined range. === Multi-criteria decision analysis === Coupled with GIS, multi-criteria decision analysis methods support decision-makers in analysing a set of alternative spatial solutions, such as the most likely ecological habitat for restoration, against multiple criteria, such as vegetation cover or roads. MCDA uses decision rules to aggregate the criteria, which allows the alternative solutions to be ranked or prioritised. GIS MCDA may reduce costs and time involved in identifying potential restoration sites. === GIS data mining === GIS or spatial data mining is the application of data mining methods to spatial data. Data mining, which is the partially automated search for hidden patterns in large databases, offers great potential benefits for applied GIS-based decision making. Typical applications include environmental monitoring. A characteristic of such applications is that spatial correlation between data measurements require the use of specialized algorithms for more efficient data analysis. == Data output and cartography == Cartography is the design and production of maps, or visual representations of spatial data. The vast majority of modern cartography is done with the help of computers, usually using GIS but production of quality cartography is also achieved by importing layers into a design program to refine it. Most GIS software gives the user substantial control over the appearance of the data. Cartographic work serves two major functions: First, it produces graphics on the screen or on paper that convey the results of analysis to the people who make decisions about resources. Wall maps and other graphics can be generated, allowing the viewer to visualize and thereby understand the results of analyses or simulations of potential events. Web Map Servers facilitate distribution of generated maps through web browsers using various implementations of web-based application programming interfaces (AJAX, Java, Flash, etc.). Second, other database information can be generated for further analysis or use. An example would be a list of all addresses within one mile (1.6 km) of a toxic spill. An archeochrome is a new way of displaying spatial data. It is a thematic on a 3D map that is applied to a specific building or a part of a building. It is suited to the visual display of heat-loss data. === Terrain depiction === Traditional maps are abstractions of the real world, a sampling of important elements portrayed on a sheet of paper with symbols to represent physical objects. People who use maps must interpret these symbols. Topographic maps show the shape of land surface with contour lines or with shaded relief. Today, graphic display techniques such as shading based on altitude in a GIS can make relationships among map elements visible, heightening one's ability to extract and analyze information. For example, two types of data were combined in a GIS to produce a perspective view of a portion of San Mateo County, California. The digital elevation model, consisting of surface elevations recorded on a 30-meter horizontal grid, shows high elevations as white and low elevation as black. The accompanying Landsat Thematic Mapper image shows a false-color infrared image looking down at the same area in 30-meter pixels, or picture elements, for the same coordinate points, pixel by pixel, as the elevation information. A GIS was used to register and combine the two images to render the three-dimensional perspective view looking down the San Andreas Fault, using the Thematic Mapper image pixels, but shaded using the elevation of the landforms. The GIS display depends on the viewing point of the observer and time of day of the display, to properly render the shadows created by the sun's rays at that latitude, longitude, and time of day. === Web mapping === In recent years there has been a proliferation of free-to-use and easily accessible mapping software such as the proprietary web applications Google Maps and Bing Maps, as well as the free and open-source alternative OpenStreetMap. These services give the public access to huge amounts of geographic data, perceived by many users to be as trustworthy and usable as professional information. For example, during the COVID-19 pandemic, web maps hosted on dashboards were used to rapidly disseminate case data to the general public. Some of them, like Google Maps and OpenLayers, expose an application programming interface (API) that enable users to create custom applications. These toolkits commonly offer street maps, aerial/satellite imagery, geocoding, searches, and routing functionality. Web mapping has also uncovered the potential of crowdsourcing geodata in projects like OpenStreetMap, which is a collaborative project to create a free editable map of the world. These mashup projects have been proven to provide a high level of value and benefit to end users outside that possible through traditional geographic information. Web mapping is not without its drawbacks. Web mapping allows for the creation and distribution of maps by people without proper cartographic training. This has led to maps that ignore cartographic conventions and are potentially misleading, with one study finding that more than half of United States state government COVID-19 dashboards did not follow these conventions. == Uses == Since its origin in the 1960s, GIS has been used in an ever-increasing range of applications, corroborating the widespread importance of location and aided by the continuing reduction in the barriers to adopting geospatial technology. The perhaps hundreds of different uses of GIS can be classified in several ways: Goal: the purpose of an application can be broadly classified as either scientific research or resource management. The purpose of research, defined as broadly as possible, is to discover new knowledge; this may be performed by someone who considers themself a scientist, but may also be done by anyone who is trying to learn why the world appears to work the way it does. A study as practical as deciphering why a business location has failed would be research in this sense. Management (sometimes called operational applications), also defined as broadly as possible, is the application of knowledge to make practical decisions on how to employ the resources one has control over to achieve one's goals. These resources could be time, capital, labor, equipment, land, mineral deposits, wildlife, and so on.: 791  Decision level: Management applications have been further classified as strategic, tactical, operational, a common classification in business management. Strategic tasks are long-term, visionary decisions about what goals one should have, such as whether a business should expand or not. Tactical tasks are medium-term decisions about how to achieve strategic goals, such as a national forest creating a grazing management plan. Operational decisions are concerned with the day-to-day tasks, such as a person finding the shortest route to a pizza restaurant. Topic: the domains in which GIS is applied largely fall into those concerned with the human world (e.g., economics, politics, transportation, education, landscape architecture, archaeology, urban planning, real estate, public health, crime mapping, national defense), and those concerned with the natural world (e.g., geology, biology, oceanography, climate). That said, one of the powerful capabilities of GIS and the spatial perspective of geography is their integrative ability to compare disparate topics, and many applications are concerned with multiple domains. Examples of integrated human-natural application domains include deep mapping, Natural hazard mitigation, wildlife management, sustainable development, natural resources, and climate change response. Institution: GIS has been implemented in a variety of different kinds of institutions: government (at all levels from municipal to international), business (of all types and sizes), non-profit organizations (even churches), as well as personal uses. The latter has become increasingly prominent with the rise of location-enabled smartphones. Lifespan: GIS implementations may be focused on a project or an enterprise. A Project GIS is focused on accomplishing a single task: data is gathered, analysis is performed, and results are produced separately from any other projects the person may perform, and the implementation is essentially transitory. An Enterprise GIS is intended to be a permanent institution, including a database that is carefully designed to be useful for a variety of projects over many years, and is likely used by many individuals across an enterprise, with some employed full-time just to maintain it. Integration: Traditionally, most GIS applications were standalone, using specialized GIS software, specialized hardware, specialized data, and specialized professionals. Although these remain common to the present day, integrated applications have greatly increased, as geospatial technology was merged into broader enterprise applications, sharing IT infrastructure, databases, and software, often using enterprise integration platforms such as SAP. The implementation of a GIS is often driven by jurisdictional (such as a city), purpose, or application requirements. Generally, a GIS implementation may be custom-designed for an organization. Hence, a GIS deployment developed for an application, jurisdiction, enterprise, or purpose may not be necessarily interoperable or compatible with a GIS that has been developed for some other application, jurisdiction, enterprise, or purpose. GIS is also diverging into location-based services, which allows GPS-enabled mobile devices to display their location in relation to fixed objects (nearest restaurant, gas station, fire hydrant) or mobile objects (friends, children, police car), or to relay their position back to a central server for display or other processing. GIS is also used in digital marketing and SEO for audience segmentation based on location. === Topics === ==== Aquatic science ==== ==== Archaeology ==== ==== Disaster response ==== Geospatial disaster response uses geospatial data and tools to help emergency responders, land managers, and scientists respond to disasters. Geospatial data can help save lives, reduce damage, and improve communication. Geospatial data can be used by federal authorities like FEMA to create maps that show the extent of a disaster, the location of people in need, and the location of debris, create models that estimate the number of people at risk and the amount of damage, improve communication between emergency responders, land managers, and scientists, as well as help determine where to allocate resources, such as emergency medical resources or search and rescue teams and plan evacuation routes and identify which areas are most at risk. In the United States, FEMA's Response Geospatial Office is responsible for the agency's capture, analysis and development of GIS products to enhance situational awareness and enable expeditions and effective decision making. The RGO's mission is to support decision makers in understanding the size, scope, and extent of disaster impacts so they can deliver resources to the communities most in need. ==== Environmental governance ==== ==== Environmental contamination ==== ==== Geological mapping ==== ==== Geospatial intelligence ==== ==== History ==== The use of digital maps generated by GIS has also influenced the development of an academic field known as spatial humanities. ==== Hydrology ==== ==== Participatory GIS ==== ==== Public health ==== ==== Traditional knowledge GIS ==== == Other aspects == === Open Geospatial Consortium standards === The Open Geospatial Consortium (OGC) is an international industry consortium of 384 companies, government agencies, universities, and individuals participating in a consensus process to develop publicly available geoprocessing specifications. Open interfaces and protocols defined by OpenGIS Specifications support interoperable solutions that "geo-enable" the Web, wireless and location-based services, and mainstream IT, and empower technology developers to make complex spatial information and services accessible and useful with all kinds of applications. Open Geospatial Consortium protocols include Web Map Service, and Web Feature Service. GIS products are broken down by the OGC into two categories, based on how completely and accurately the software follows the OGC specifications. Compliant products are software products that comply to OGC's OpenGIS Specifications. When a product has been tested and certified as compliant through the OGC Testing Program, the product is automatically registered as "compliant" on this site. Implementing products are software products that implement OpenGIS Specifications but have not yet passed a compliance test. Compliance tests are not available for all specifications. Developers can register their products as implementing draft or approved specifications, though OGC reserves the right to review and verify each entry. === Adding the dimension of time === The condition of the Earth's surface, atmosphere, and subsurface can be examined by feeding satellite data into a GIS. GIS technology gives researchers the ability to examine the variations in Earth processes over days, months, and years through the use of cartographic visualizations. As an example, the changes in vegetation vigor through a growing season can be animated to determine when drought was most extensive in a particular region. The resulting graphic represents a rough measure of plant health. Working with two variables over time would then allow researchers to detect regional differences in the lag between a decline in rainfall and its effect on vegetation. GIS technology and the availability of digital data on regional and global scales enable such analyses. The satellite sensor output used to generate a vegetation graphic is produced for example by the advanced very-high-resolution radiometer (AVHRR). This sensor system detects the amounts of energy reflected from the Earth's surface across various bands of the spectrum for surface areas of about 1 km2 (0.39 sq mi). The satellite sensor produces images of a particular location on the Earth twice a day. AVHRR and more recently the moderate-resolution imaging spectroradiometer (MODIS) are only two of many sensor systems used for Earth surface analysis. In addition to the integration of time in environmental studies, GIS is also being explored for its ability to track and model the progress of humans throughout their daily routines. A concrete example of progress in this area is the recent release of time-specific population data by the U.S. Census. In this data set, the populations of cities are shown for daytime and evening hours highlighting the pattern of concentration and dispersion generated by North American commuting patterns. The manipulation and generation of data required to produce this data would not have been possible without GIS. Using models to project the data held by a GIS forward in time have enabled planners to test policy decisions using spatial decision support systems. === Semantics === Tools and technologies emerging from the World Wide Web Consortium's Semantic Web are proving useful for data integration problems in information systems. Correspondingly, such technologies have been proposed as a means to facilitate interoperability and data reuse among GIS applications and also to enable new analysis mechanisms. Ontologies are a key component of this semantic approach as they allow a formal, machine-readable specification of the concepts and relationships in a given domain. This in turn allows a GIS to focus on the intended meaning of data rather than its syntax or structure. For example, reasoning that a land cover type classified as deciduous needleleaf trees in one dataset is a specialization or subset of land cover type forest in another more roughly classified dataset can help a GIS automatically merge the two datasets under the more general land cover classification. Tentative ontologies have been developed in areas related to GIS applications, for example the hydrology ontology developed by the Ordnance Survey in the United Kingdom and the SWEET ontologies developed by NASA's Jet Propulsion Laboratory. Also, simpler ontologies and semantic metadata standards are being proposed by the W3C Geo Incubator Group to represent geospatial data on the web. GeoSPARQL is a standard developed by the Ordnance Survey, United States Geological Survey, Natural Resources Canada, Australia's Commonwealth Scientific and Industrial Research Organisation and others to support ontology creation and reasoning using well-understood OGC literals (GML, WKT), topological relationships (Simple Features, RCC8, DE-9IM), RDF and the SPARQL database query protocols. Recent research results in this area can be seen in the International Conference on Geospatial Semantics and the Terra Cognita – Directions to the Geospatial Semantic Web workshop at the International Semantic Web Conference. == Societal implications == With the popularization of GIS in decision making, scholars have begun to scrutinize the social and political implications of GIS. GIS can also be misused to distort reality for individual and political gain. It has been argued that the production, distribution, utilization, and representation of geographic information are largely related with the social context and has the potential to increase citizen trust in government. Other related topics include discussion on copyright, privacy, and censorship. A more optimistic social approach to GIS adoption is to use it as a tool for public participation. === In education === At the end of the 20th century, GIS began to be recognized as tools that could be used in the classroom. The benefits of GIS in education seem focused on developing spatial cognition, but there is not enough bibliography or statistical data to show the concrete scope of the use of GIS in education around the world, although the expansion has been faster in those countries where the curriculum mentions them.: 36  GIS seems to provide many advantages in teaching geography because it allows for analysis based on real geographic data and also helps raise research questions from teachers and students in the classroom. It also contributes to improvement in learning by developing spatial and geographical thinking and, in many cases, student motivation.: 38  Courses in GIS are also offered by educational institutions. === In local government === GIS is proven as an organization-wide, enterprise and enduring technology that continues to change how local government operates. Government agencies have adopted GIS technology as a method to better manage the following areas of government organization: Economic development departments use interactive GIS mapping tools, aggregated with other data (demographics, labor force, business, industry, talent) along with a database of available commercial sites and buildings in order to attract investment and support existing business. Businesses making location decisions can use the tools to choose communities and sites that best match their criteria for success. Public safety operations such as emergency operations centers, fire prevention, police and sheriff mobile technology and dispatch, and mapping weather risks. Parks and recreation departments and their functions in asset inventory, land conservation, land management, and cemetery management Public works and utilities, tracking water and stormwater drainage, electrical assets, engineering projects, and public transportation assets and trends Fiber network management for interdepartmental network assets School analytical and demographic data, asset management, and improvement/expansion planning Public administration for election data, property records, and zoning/management The open data initiative is pushing local government to take advantage of technology such as GIS technology, as it encompasses the requirements to fit the open data/open government model of transparency. With open data, local government organizations can implement citizen engagement applications and online portals, allowing citizens to see land information, report potholes and signage issues, view and sort parks by assets, view real-time crime rates and utility repairs, and much more. The push for open data within government organizations is driving the growth in local government GIS technology spending, and database management. == See also == == References == == Further reading == Bolstad, P. (2019). GIS Fundamentals: A first text on Geographic Information Systems, Sixth Edition. Ann Arbor: XanEdu, 764 pp. Burrough, P. A. and McDonnell, R. A. (1998). Principles of geographical information systems. Oxford University Press, Oxford, 327 pp. DeMers, M. (2009). Fundamentals of Geographic Information Systems, 4th Edition. Wiley, ISBN 978-0-470-12906-7 Harvey, Francis (2008). A Primer of GIS, Fundamental geographic and cartographic concepts. The Guilford Press, 31 pp. Heywood, I., Cornelius, S., and Carver, S. (2006). An Introduction to Geographical Information Systems. Prentice Hall. 3rd edition. Ott, T. and Swiaczny, F. (2001) .Time-integrative GIS. Management and analysis of Spatio-temporal data, Berlin / Heidelberg / New York: Springer. Thurston, J., Poiker, T.K. and J. Patrick Moore. (2003). Integrated Geospatial Technologies: A Guide to GPS, GIS, and Data Logging. Hoboken, New Jersey: Wiley. Worboys, Michael; Duckham, Matt (2004). GIS: a computing perspective. Boca Raton: CRC Press. ISBN 978-0415283755. == External links == Media related to Geographic information systems at Wikimedia Commons
Wikipedia/Geographic_information_system
In mathematics and other fields, a lemma (pl.: lemmas or lemmata) is a generally minor, proven proposition which is used to prove a larger statement. For that reason, it is also known as a "helping theorem" or an "auxiliary theorem". In many cases, a lemma derives its importance from the theorem it aims to prove; however, a lemma can also turn out to be more important than originally thought. == Etymology == From the Ancient Greek λῆμμα, (perfect passive εἴλημμαι) something received or taken. Thus something taken for granted in an argument. == Comparison with theorem == There is no formal distinction between a lemma and a theorem, only one of intention (see Theorem terminology). However, a lemma can be considered a minor result whose sole purpose is to help prove a more substantial theorem – a step in the direction of proof. == Well-known lemmas == Some powerful results in mathematics are known as lemmas, first named for their originally minor purpose. These include, among others: While these results originally seemed too simple or too technical to warrant independent interest, they have eventually turned out to be central to the theories in which they occur. == See also == == Notes == == References == == External links == Doron Zeilberger, Opinion 82: A Good Lemma is Worth a Thousand Theorems This article incorporates material from Lemma on PlanetMath, which is licensed under the Creative Commons Attribution/Share-Alike License.
Wikipedia/Lemma_(mathematics)
Tarski–Grothendieck set theory (TG, named after mathematicians Alfred Tarski and Alexander Grothendieck) is an axiomatic set theory. It is a non-conservative extension of Zermelo–Fraenkel set theory (ZFC) and is distinguished from other axiomatic set theories by the inclusion of Tarski's axiom, which states that for each set there is a "Tarski universe" it belongs to (see below). Tarski's axiom implies the existence of inaccessible cardinals, providing a richer ontology than ZFC. For example, adding this axiom supports category theory. The Mizar system and Metamath use Tarski–Grothendieck set theory for formal verification of proofs. == Axioms == Tarski–Grothendieck set theory starts with conventional Zermelo–Fraenkel set theory and then adds “Tarski's axiom”. We will use the axioms, definitions, and notation of Mizar to describe it. Mizar's basic objects and processes are fully formal; they are described informally below. First, let us assume that: Given any set A {\displaystyle A} , the singleton { A } {\displaystyle \{A\}} exists. Given any two sets, their unordered and ordered pairs exist. Given any set of sets, its union exists. TG includes the following axioms, which are conventional because they are also part of ZFC: Set axiom: Quantified variables range over sets alone; everything is a set (the same ontology as ZFC). Axiom of extensionality: Two sets are identical if they have the same members. Axiom of regularity: No set is a member of itself, and circular chains of membership are impossible. Axiom schema of replacement: Let the domain of the class function F {\displaystyle F} be the set A {\displaystyle A} . Then the range of F {\displaystyle F} (the values of F ( x ) {\displaystyle F(x)} for all members x {\displaystyle x} of A {\displaystyle A} ) is also a set. It is Tarski's axiom that distinguishes TG from other axiomatic set theories. Tarski's axiom also implies the axioms of infinity, choice, and power set. It also implies the existence of inaccessible cardinals, thanks to which the ontology of TG is much richer than that of conventional set theories such as ZFC. Tarski's axiom (adapted from Tarski 1939). For every set s {\displaystyle s} , there exists a set u {\displaystyle u} (a "universe") such that s ∈ u {\displaystyle s\in u} : it contains s {\displaystyle s} ( ∀ x ∈ u ) ( ∀ y ⊆ x ) ( y ∈ u ) {\displaystyle (\forall x\in u)(\forall y\subseteq x)(y\in u)} : it contains every subset of every member ( ∀ x ∈ u ) ( P ( x ) ∈ u ) {\displaystyle (\forall x\in u)({\mathcal {P}}(x)\in u)} : it contains the powerset of every member ( ∀ x ⊆ u ) ( | x | < | u | → x ∈ u ) {\displaystyle (\forall x\subseteq u)(|x|<|u|\to x\in u)} : it contains every subset of itself that has smaller cardinality More formally: ∀ s ∃ u [ s ∈ u ∧ ( ∀ x ∈ u ) ( P ( x ) ⊆ u ∧ P ( x ) ∈ u ) ∧ ( ∀ x ⊆ u ) ( | x | < | u | → x ∈ u ) ] {\displaystyle \forall s\exists u[s\in u\land (\forall x\in u)({\mathcal {P}}(x)\subseteq u\land {\mathcal {P}}(x)\in u)\land (\forall x\subseteq u)(|x|<|u|\to x\in u)]} where | ⋅ | {\displaystyle |\cdot |} denotes the cardinality of a set. In short, Tarski's axiom states that every set belongs to a Tarski universe. If a Tarski universe is transitive, it is also a Grothendieck universe. Conversely, assuming the axiom of choice, every Grothendieck universe is a Tarski universe (i.e. satisfies Tarski's axiom). That u {\displaystyle u} looks much like a “universal set” for s {\displaystyle s} – it not only has as members the powerset of s {\displaystyle s} , and all subsets of s {\displaystyle s} , it also has the powerset of that powerset and so on – its members are closed under the operations of taking powerset or taking a subset. It's like a “universal set” except that of course it is not a member of itself and is not a set of all sets. That's the guaranteed universe it belongs to. And then any such u {\displaystyle u} is itself a member of an even larger “almost universal set” and so on. It's an axiom that guarantees vastly more sets than ZFC does. == Implementation in the Mizar system == The Mizar language, underlying the implementation of TG and providing its logical syntax, is typed and the types are assumed to be non-empty. Hence, the theory is implicitly taken to be non-empty. The existence axioms, e.g. the existence of the unordered pair, is also implemented indirectly by the definition of term constructors. The system includes equality, the membership predicate and the following standard definitions: Singleton: A set with one member; Unordered pair: A set with two distinct members. { a , b } = { b , a } {\displaystyle \{a,b\}=\{b,a\}} ; Ordered pair: The set { { a , b } , { a } } = ( a , b ) ≠ ( b , a ) {\displaystyle \{\{a,b\},\{a\}\}=(a,b)\neq (b,a)} ; Subset: A set all of whose members are members of another given set; The union of a set of sets Y {\displaystyle Y} : The set of all members of any member of Y {\displaystyle Y} . == Implementation in Metamath == The Metamath system supports arbitrary higher-order logics, but it is typically used with the "set.mm" definitions of axioms. The ax-groth axiom adds Tarski's axiom, which in Metamath is defined as follows: ⊢ ∃y(x ∈ y ∧ ∀z ∈ y (∀w(w ⊆ z → w ∈ y) ∧ ∃w ∈ y ∀v(v ⊆ z → v ∈ w)) ∧ ∀z(z ⊆ y → (z ≈ y ∨ z ∈ y))) == See also == Axiom of limitation of size == Notes == == References == Andreas Blass, I.M. Dimitriou, and Benedikt Löwe (2007) "Inaccessible Cardinals without the Axiom of Choice," Fundamenta Mathematicae 194: 179-89. Bourbaki, Nicolas (1972). "Univers". In Michael Artin; Alexandre Grothendieck; Jean-Louis Verdier (eds.). Séminaire de Géométrie Algébrique du Bois Marie – 1963-64 – Théorie des topos et cohomologie étale des schémas – (SGA 4) – vol. 1 (Lecture Notes in Mathematics 269) (in French). Berlin; New York: Springer-Verlag. pp. 185–217. Archived from the original on 2003-08-26. Patrick Suppes (1960) Axiomatic Set Theory. Van Nostrand. Dover reprint, 1972. Tarski, Alfred (1938). "Über unerreichbare Kardinalzahlen" (PDF). Fundamenta Mathematicae. 30: 68–89. doi:10.4064/fm-30-1-68-89. Tarski, Alfred (1939). "On the well-ordered subsets of any set" (PDF). Fundamenta Mathematicae. 32: 176–183. doi:10.4064/fm-32-1-176-783. == External links == Trybulec, Andrzej, 1989, "Tarski–Grothendieck Set Theory", Journal of Formalized Mathematics. Metamath: "Proof Explorer Home Page." Scroll down to "Grothendieck's Axiom." PlanetMath: "Tarski's Axiom"
Wikipedia/Tarski–Grothendieck_set_theory
In set theory, the intersection of two sets A {\displaystyle A} and B , {\displaystyle B,} denoted by A ∩ B , {\displaystyle A\cap B,} is the set containing all elements of A {\displaystyle A} that also belong to B {\displaystyle B} or equivalently, all elements of B {\displaystyle B} that also belong to A . {\displaystyle A.} == Notation and terminology == Intersection is written using the symbol " ∩ {\displaystyle \cap } " between the terms; that is, in infix notation. For example: { 1 , 2 , 3 } ∩ { 2 , 3 , 4 } = { 2 , 3 } {\displaystyle \{1,2,3\}\cap \{2,3,4\}=\{2,3\}} { 1 , 2 , 3 } ∩ { 4 , 5 , 6 } = ∅ {\displaystyle \{1,2,3\}\cap \{4,5,6\}=\varnothing } Z ∩ N = N {\displaystyle \mathbb {Z} \cap \mathbb {N} =\mathbb {N} } { x ∈ R : x 2 = 1 } ∩ N = { 1 } {\displaystyle \{x\in \mathbb {R} :x^{2}=1\}\cap \mathbb {N} =\{1\}} The intersection of more than two sets (generalized intersection) can be written as: ⋂ i = 1 n A i {\displaystyle \bigcap _{i=1}^{n}A_{i}} which is similar to capital-sigma notation. For an explanation of the symbols used in this article, refer to the table of mathematical symbols. == Definition == The intersection of two sets A {\displaystyle A} and B , {\displaystyle B,} denoted by A ∩ B {\displaystyle A\cap B} , is the set of all objects that are members of both the sets A {\displaystyle A} and B . {\displaystyle B.} In symbols: A ∩ B = { x : x ∈ A and x ∈ B } . {\displaystyle A\cap B=\{x:x\in A{\text{ and }}x\in B\}.} That is, x {\displaystyle x} is an element of the intersection A ∩ B {\displaystyle A\cap B} if and only if x {\displaystyle x} is both an element of A {\displaystyle A} and an element of B . {\displaystyle B.} For example: The intersection of the sets {1, 2, 3} and {2, 3, 4} is {2, 3}. The number 9 is not in the intersection of the set of prime numbers {2, 3, 5, 7, 11, ...} and the set of odd numbers {1, 3, 5, 7, 9, 11, ...}, because 9 is not prime. === Intersecting and disjoint sets === We say that A {\displaystyle A} intersects (meets) B {\displaystyle B} if there exists some x {\displaystyle x} that is an element of both A {\displaystyle A} and B , {\displaystyle B,} in which case we also say that A {\displaystyle A} intersects (meets) B {\displaystyle B} at x {\displaystyle x} . Equivalently, A {\displaystyle A} intersects B {\displaystyle B} if their intersection A ∩ B {\displaystyle A\cap B} is an inhabited set, meaning that there exists some x {\displaystyle x} such that x ∈ A ∩ B . {\displaystyle x\in A\cap B.} We say that A {\displaystyle A} and B {\displaystyle B} are disjoint if A {\displaystyle A} does not intersect B . {\displaystyle B.} In plain language, they have no elements in common. A {\displaystyle A} and B {\displaystyle B} are disjoint if their intersection is empty, denoted A ∩ B = ∅ . {\displaystyle A\cap B=\varnothing .} For example, the sets { 1 , 2 } {\displaystyle \{1,2\}} and { 3 , 4 } {\displaystyle \{3,4\}} are disjoint, while the set of even numbers intersects the set of multiples of 3 at the multiples of 6. == Algebraic properties == Binary intersection is an associative operation; that is, for any sets A , B , {\displaystyle A,B,} and C , {\displaystyle C,} one has A ∩ ( B ∩ C ) = ( A ∩ B ) ∩ C . {\displaystyle A\cap (B\cap C)=(A\cap B)\cap C.} Thus the parentheses may be omitted without ambiguity: either of the above can be written as A ∩ B ∩ C {\displaystyle A\cap B\cap C} . Intersection is also commutative. That is, for any A {\displaystyle A} and B , {\displaystyle B,} one has A ∩ B = B ∩ A . {\displaystyle A\cap B=B\cap A.} The intersection of any set with the empty set results in the empty set; that is, that for any set A {\displaystyle A} , A ∩ ∅ = ∅ {\displaystyle A\cap \varnothing =\varnothing } Also, the intersection operation is idempotent; that is, any set A {\displaystyle A} satisfies that A ∩ A = A {\displaystyle A\cap A=A} . All these properties follow from analogous facts about logical conjunction. Intersection distributes over union and union distributes over intersection. That is, for any sets A , B , {\displaystyle A,B,} and C , {\displaystyle C,} one has A ∩ ( B ∪ C ) = ( A ∩ B ) ∪ ( A ∩ C ) A ∪ ( B ∩ C ) = ( A ∪ B ) ∩ ( A ∪ C ) {\displaystyle {\begin{aligned}A\cap (B\cup C)=(A\cap B)\cup (A\cap C)\\A\cup (B\cap C)=(A\cup B)\cap (A\cup C)\end{aligned}}} Inside a universe U , {\displaystyle U,} one may define the complement A c {\displaystyle A^{c}} of A {\displaystyle A} to be the set of all elements of U {\displaystyle U} not in A . {\displaystyle A.} Furthermore, the intersection of A {\displaystyle A} and B {\displaystyle B} may be written as the complement of the union of their complements, derived easily from De Morgan's laws: A ∩ B = ( A c ∪ B c ) c {\displaystyle A\cap B=\left(A^{c}\cup B^{c}\right)^{c}} == Arbitrary intersections == The most general notion is the intersection of an arbitrary nonempty collection of sets. If M {\displaystyle M} is a nonempty set whose elements are themselves sets, then x {\displaystyle x} is an element of the intersection of M {\displaystyle M} if and only if for every element A {\displaystyle A} of M , {\displaystyle M,} x {\displaystyle x} is an element of A . {\displaystyle A.} In symbols: ( x ∈ ⋂ A ∈ M A ) ⇔ ( ∀ A ∈ M , x ∈ A ) . {\displaystyle \left(x\in \bigcap _{A\in M}A\right)\Leftrightarrow \left(\forall A\in M,\ x\in A\right).} The notation for this last concept can vary considerably. Set theorists will sometimes write " ⋂ M {\displaystyle \bigcap M} ", while others will instead write " ⋂ A ∈ M A {\displaystyle {\bigcap }_{A\in M}A} ". The latter notation can be generalized to " ⋂ i ∈ I A i {\displaystyle {\bigcap }_{i\in I}A_{i}} ", which refers to the intersection of the collection { A i : i ∈ I } . {\displaystyle \left\{A_{i}:i\in I\right\}.} Here I {\displaystyle I} is a nonempty set, and A i {\displaystyle A_{i}} is a set for every i ∈ I . {\displaystyle i\in I.} In the case that the index set I {\displaystyle I} is the set of natural numbers, notation analogous to that of an infinite product may be seen: ⋂ i = 1 ∞ A i . {\displaystyle \bigcap _{i=1}^{\infty }A_{i}.} When formatting is difficult, this can also be written " A 1 ∩ A 2 ∩ A 3 ∩ ⋯ {\displaystyle A_{1}\cap A_{2}\cap A_{3}\cap \cdots } ". This last example, an intersection of countably many sets, is actually very common; for an example, see the article on σ-algebras. == Nullary intersection == In the previous section, we excluded the case where M {\displaystyle M} was the empty set ( ∅ {\displaystyle \varnothing } ). The reason is as follows: The intersection of the collection M {\displaystyle M} is defined as the set (see set-builder notation) ⋂ A ∈ M A = { x : for all A ∈ M , x ∈ A } . {\displaystyle \bigcap _{A\in M}A=\{x:{\text{ for all }}A\in M,x\in A\}.} If M {\displaystyle M} is empty, there are no sets A {\displaystyle A} in M , {\displaystyle M,} so the question becomes "which x {\displaystyle x} 's satisfy the stated condition?" The answer seems to be every possible x {\displaystyle x} . When M {\displaystyle M} is empty, the condition given above is an example of a vacuous truth. So the intersection of the empty family should be the universal set (the identity element for the operation of intersection), but in standard (ZF) set theory, the universal set does not exist. However, when restricted to the context of subsets of a given fixed set X {\displaystyle X} , the notion of the intersection of an empty collection of subsets of X {\displaystyle X} is well-defined. In that case, if M {\displaystyle M} is empty, its intersection is ⋂ M = ⋂ ∅ = { x ∈ X : x ∈ A for all A ∈ ∅ } {\displaystyle \bigcap M=\bigcap \varnothing =\{x\in X:x\in A{\text{ for all }}A\in \varnothing \}} . Since all x ∈ X {\displaystyle x\in X} vacuously satisfy the required condition, the intersection of the empty collection of subsets of X {\displaystyle X} is all of X . {\displaystyle X.} In formulas, ⋂ ∅ = X . {\displaystyle \bigcap \varnothing =X.} This matches the intuition that as collections of subsets become smaller, their respective intersections become larger; in the extreme case, the empty collection has an intersection equal to the whole underlying set. Also, in type theory x {\displaystyle x} is of a prescribed type τ , {\displaystyle \tau ,} so the intersection is understood to be of type s e t τ {\displaystyle \mathrm {set} \ \tau } (the type of sets whose elements are in τ {\displaystyle \tau } ), and we can define ⋂ A ∈ ∅ A {\displaystyle \bigcap _{A\in \emptyset }A} to be the universal set of s e t τ {\displaystyle \mathrm {set} \ \tau } (the set whose elements are exactly all terms of type τ {\displaystyle \tau } ). == See also == Algebra of sets – Identities and relationships involving sets Cardinality – Size of a mathematical set Complement – Set of the elements not in a given subset Intersection (Euclidean geometry) – Shape formed from points common to other shapesPages displaying short descriptions of redirect targets Intersection graph – Graph representing intersections between given sets Intersection theory – Branch of algebraic geometry List of set identities and relations – Equalities for combinations of sets Logical conjunction – Logical connective AND MinHash – Data mining technique Naive set theory – Informal set theories Symmetric difference – Elements in exactly one of two sets Union – Set of elements in any of some sets == References == == Further reading == Devlin, K. J. (1993). The Joy of Sets: Fundamentals of Contemporary Set Theory (Second ed.). New York, NY: Springer-Verlag. ISBN 3-540-94094-4. Munkres, James R. (2000). "Set Theory and Logic". Topology (Second ed.). Upper Saddle River: Prentice Hall. ISBN 0-13-181629-2. Rosen, Kenneth (2007). "Basic Structures: Sets, Functions, Sequences, and Sums". Discrete Mathematics and Its Applications (Sixth ed.). Boston: McGraw-Hill. ISBN 978-0-07-322972-0. == External links == Weisstein, Eric W. "Intersection". MathWorld.
Wikipedia/Intersection_(set_theory)
In model theory, a first-order theory is called model complete if every embedding of its models is an elementary embedding. Equivalently, every first-order formula is equivalent to a universal formula. This notion was introduced by Abraham Robinson. == Model companion and model completion == A companion of a theory T is a theory T* such that every model of T can be embedded in a model of T* and vice versa. A model companion of a theory T is a companion of T that is model complete. Robinson proved that a theory has at most one model companion. Not every theory is model-companionable, e.g. theory of groups. However if T is an ℵ 0 {\displaystyle \aleph _{0}} -categorical theory, then it always has a model companion. A model completion for a theory T is a model companion T* such that for any model M of T, the theory of T* together with the diagram of M is complete. Roughly speaking, this means every model of T is embeddable in a model of T* in a unique way. If T* is a model companion of T then the following conditions are equivalent: T* is a model completion of T T has the amalgamation property. If T also has universal axiomatization, both of the above are also equivalent to: T* has elimination of quantifiers == Examples == Any theory with elimination of quantifiers is model complete. The theory of algebraically closed fields is the model completion of the theory of fields. It is model complete but not complete. The model completion of the theory of equivalence relations is the theory of equivalence relations with infinitely many equivalence classes, each containing an infinite number of elements. The theory of real closed fields, in the language of ordered rings, is a model completion of the theory of ordered fields (or even ordered domains). The theory of real closed fields, in the language of rings, is the model companion for the theory of formally real fields, but is not a model completion. == Non-examples == The theory of dense linear orders with a first and last element is complete but not model complete. The theory of groups (in a language with symbols for the identity, product, and inverses) has the amalgamation property but does not have a model companion. == Sufficient condition for completeness of model-complete theories == If T is a model complete theory and there is a model of T that embeds into any model of T, then T is complete. == Notes == == References == Chang, Chen Chung; Keisler, H. Jerome (1990) [1973]. Model Theory. Studies in Logic and the Foundations of Mathematics (3rd ed.). Elsevier. ISBN 978-0-444-88054-3. Chang, Chen Chung; Keisler, H. Jerome (2012) [1990]. Model Theory. Dover Books on Mathematics (3rd ed.). Dover Publications. p. 672. ISBN 978-0-486-48821-9. Hirschfeld, Joram; Wheeler, William H. (1975). "Model-completions and model-companions". Forcing, Arithmetic, Division Rings. Lecture Notes in Mathematics. Vol. 454. Springer. pp. 44–54. doi:10.1007/BFb0064085. ISBN 978-3-540-07157-0. MR 0389581. Marker, David (2002). Model Theory: An Introduction. Graduate Texts in Mathematics 217. New York: Springer-Verlag. ISBN 0-387-98760-6. Saracino, D. (August 1973). "Model Companions for ℵ0-Categorical Theories". Proceedings of the American Mathematical Society. 39 (3): 591–598. Simmons, H. (1976). "Large and Small Existentially Closed Structures". Journal of Symbolic Logic. 41 (2): 379–390.
Wikipedia/Model_complete_theory
Network performance refers to measures of service quality of a network as seen by the customer. There are many different ways to measure the performance of a network, as each network is different in nature and design. Performance can also be modeled and simulated instead of measured; one example of this is using state transition diagrams to model queuing performance or to use a Network Simulator. == Performance measures == The following measures are often considered important: Bandwidth commonly measured in bits/second is the maximum rate that information can be transferred Throughput is the actual rate that information is transferred Latency the delay between the sender and the receiver decoding it, this is mainly a function of the signals travel time, and processing time at any nodes the information traverses Jitter variation in packet delay at the receiver of the information Error rate the number of corrupted bits expressed as a percentage or fraction of the total sent === Bandwidth === The available channel bandwidth and achievable signal-to-noise ratio determine the maximum possible throughput. It is not generally possible to send more data than dictated by the Shannon-Hartley Theorem. === Throughput === Throughput is the number of messages successfully delivered per unit time. Throughput is controlled by available bandwidth, as well as the available signal-to-noise ratio and hardware limitations. Throughput for the purpose of this article will be understood to be measured from the arrival of the first bit of data at the receiver, to decouple the concept of throughput from the concept of latency. For discussions of this type, the terms 'throughput' and 'bandwidth' are often used interchangeably. The Time Window is the period over which the throughput is measured. The choice of an appropriate time window will often dominate calculations of throughput, and whether latency is taken into account or not will determine whether the latency affects the throughput or not. === Latency === The speed of light imposes a minimum propagation time on all electromagnetic signals. It is not possible to reduce the latency below t = s / c m {\displaystyle t=s/c_{m}} where s is the distance and cm is the speed of light in the medium (roughly 200,000 km/s for most fiber or electrical media, depending on their velocity factor). This approximately means an additional millisecond round-trip delay (RTT) per 100 km (or 62 miles) of distance between hosts. Other delays also occur in intermediate nodes. In packet switched networks delays can occur due to queueing. === Jitter === Jitter is the undesired deviation from true periodicity of an assumed periodic signal in electronics and telecommunications, often in relation to a reference clock source. Jitter may be observed in characteristics such as the frequency of successive pulses, the signal amplitude, or phase of periodic signals. Jitter is a significant, and usually undesired, factor in the design of almost all communications links (e.g., USB, PCI-e, SATA, OC-48). In clock recovery applications it is called timing jitter. === Error rate === In digital transmission, the number of bit errors is the number of received bits of a data stream over a communication channel that have been altered due to noise, interference, distortion or bit synchronization errors. The bit error rate or bit error ratio (BER) is the number of bit errors divided by the total number of transferred bits during a studied time interval. BER is a unitless performance measure, often expressed as a percentage. The bit error probability pe is the expectation value of the BER. The BER can be considered as an approximate estimate of the bit error probability. This estimate is accurate for a long time interval and a high number of bit errors. === Interplay of factors === All of the factors above, coupled with user requirements and user perceptions, play a role in determining the perceived 'fastness' or utility, of a network connection. The relationship between throughput, latency, and user experience is most aptly understood in the context of a shared network medium, and as a scheduling problem. == Algorithms and protocols == For some systems, latency and throughput are coupled entities. In TCP/IP, latency can also directly affect throughput. In TCP connections, the large bandwidth-delay product of high latency connections, combined with relatively small TCP window sizes on many devices, effectively causes the throughput of a high latency connection to drop sharply with latency. This can be remedied with various techniques, such as increasing the TCP congestion window size, or more drastic solutions, such as packet coalescing, TCP acceleration, and forward error correction, all of which are commonly used for high latency satellite links. TCP acceleration converts the TCP packets into a stream that is similar to UDP. Because of this, the TCP acceleration software must provide its own mechanisms to ensure the reliability of the link, taking the latency and bandwidth of the link into account, and both ends of the high latency link must support the method used. In the Media Access Control (MAC) layer, performance issues such as throughput and end-to-end delay are also addressed. == Examples of latency or throughput dominated systems == Many systems can be characterized as dominated either by throughput limitations or by latency limitations in terms of end-user utility or experience. In some cases, hard limits such as the speed of light present unique problems to such systems and nothing can be done to correct this. Other systems allow for significant balancing and optimization for best user experience. === Satellite === A telecom satellite in geosynchronous orbit imposes a path length of at least 71000 km between transmitter and receiver. which means a minimum delay between message request and message receipt, or latency of 473 ms. This delay can be very noticeable and affects satellite phone service regardless of available throughput capacity. === Deep space communication === These long path length considerations are exacerbated when communicating with space probes and other long-range targets beyond Earth's atmosphere. The Deep Space Network implemented by NASA is one such system that must cope with these problems. Largely latency driven, the GAO has criticized the current architecture. Several different methods have been proposed to handle the intermittent connectivity and long delays between packets, such as delay-tolerant networking. === Even deeper space communication === At interstellar distances, the difficulties in designing radio systems that can achieve any throughput at all are massive. In these cases, maintaining communication is a bigger issue than how long that communication takes. === Offline data transport === Transportation is concerned almost entirely with throughput, which is why physical deliveries of backup tape archives are still largely done by vehicle. == See also == Bitrate Measuring network throughput Network traffic measurement Response time == Notes == == References == Rappaport, Theodore S. (2002). Wireless communications : principles and practice (2 ed.). Upper Saddle River, NJ: Prentice Hall PTR. ISBN 0-13-042232-0. Roddy, Dennis (2001). Satellite communications (3. ed.). New York [u.a.]: McGraw-Hill. ISBN 0-07-137176-1. Fall, Kevin, "A Delay-Tolerant Network Architecture for Challenged Internets", Intel Corporation, February, 2003, Doc No: IRB-TR-03-003 Government Accountability Office (GAO) report 06-445, NASA'S DEEP SPACE NETWORK: Current Management Structure is Not Conducive to Effectively Matching Resources with Future Requirements, April 27, 2006 == External links == NASA's Deep Space Network Website "It's the Latency, Stupid"
Wikipedia/Network_performance
Industrial process control (IPC) or simply process control is a system used in modern manufacturing which uses the principles of control theory and physical industrial control systems to monitor, control and optimize continuous industrial production processes using control algorithms. This ensures that the industrial machines run smoothly and safely in factories and efficiently use energy to transform raw materials into high-quality finished products with reliable consistency while reducing energy waste and economic costs, something which could not be achieved purely by human manual control. In IPC, control theory provides the theoretical framework to understand system dynamics, predict outcomes and design control strategies to ensure predetermined objectives, utilizing concepts like feedback loops, stability analysis and controller design. On the other hand, the physical apparatus of IPC, based on automation technologies, consists of several components. Firstly, a network of sensors continuously measure various process variables (such as temperature, pressure, etc.) and product quality variables. A programmable logic controller (PLC, for smaller, less complex processes) or a distributed control system (DCS, for large-scale or geographically dispersed processes) analyzes this sensor data transmitted to it, compares it to predefined setpoints using a set of instructions or a mathematical model called the control algorithm and then, in case of any deviation from these setpoints (e.g., temperature exceeding setpoint), makes quick corrective adjustments through actuators such as valves (e.g. cooling valve for temperature control), motors or heaters to guide the process back to the desired operational range. This creates a continuous closed-loop cycle of measurement, comparison, control action, and re-evaluation which guarantees that the process remains within established parameters. The HMI (Human-Machine Interface) acts as the "control panel" for the IPC system where small number of human operators can monitor the process and make informed decisions regarding adjustments. IPCs can range from controlling the temperature and level of a single process vessel (controlled environment tank for mixing, separating, reacting, or storing materials in industrial processes.) to a complete chemical processing plant with several thousand control feedback loops. IPC provides several critical benefits to manufacturing companies. By maintaining a tight control over key process variables, it helps reduce energy use, minimize waste and shorten downtime for peak efficiency and reduced costs. It ensures consistent and improved product quality with little variability, which satisfies the customers and strengthens the company's reputation. It improves safety by detecting and alerting human operators about potential issues early, thus preventing accidents, equipment failures, process disruptions and costly downtime. Analyzing trends and behaviors in the vast amounts of data collected real-time helps engineers identify areas of improvement, refine control strategies and continuously enhance production efficiency using a data-driven approach. IPC is used across a wide range of industries where precise control is important. The applications can range from controlling the temperature and level of a single process vessel, to a complete chemical processing plant with several thousand control loops. In automotive manufacturing, IPC ensures consistent quality by meticulously controlling processes like welding and painting. Mining operations are optimized with IPC monitoring ore crushing and adjusting conveyor belt speeds for maximum output. Dredging benefits from precise control of suction pressure, dredging depth and sediment discharge rate by IPC, ensuring efficient and sustainable practices. Pulp and paper production leverages IPC to regulate chemical processes (e.g., pH and bleach concentration) and automate paper machine operations to control paper sheet moisture content and drying temperature for consistent quality. In chemical plants, it ensures the safe and efficient production of chemicals by controlling temperature, pressure and reaction rates. Oil refineries use it to smoothly convert crude oil into gasoline and other petroleum products. In power plants, it helps maintain stable operating conditions necessary for a continuous electricity supply. In food and beverage production, it helps ensure consistent texture, safety and quality. Pharmaceutical companies relies on it to produce life-saving drugs safely and effectively. The development of large industrial process control systems has been instrumental in enabling the design of large high volume and complex processes, which could not be otherwise economically or safely operated. == History == Early process control breakthroughs came most frequently in the form of water control devices. Ktesibios of Alexandria is credited for inventing float valves to regulate water level of water clocks in the 3rd century BC. In the 1st century AD, Heron of Alexandria invented a water valve similar to the fill valve used in modern toilets. Later process controls inventions involved basic physics principles. In 1620, Cornelis Drebbel invented a bimetallic thermostat for controlling the temperature in a furnace. In 1681, Denis Papin discovered the pressure inside a vessel could be regulated by placing weights on top of the vessel lid. In 1745, Edmund Lee created the fantail to improve windmill efficiency; a fantail was a smaller windmill placed 90° of the larger fans to keep the face of the windmill pointed directly into the oncoming wind. With the dawn of the Industrial Revolution in the 1760s, process controls inventions were aimed to replace human operators with mechanized processes. In 1784, Oliver Evans created a water-powered flourmill which operated using buckets and screw conveyors. Henry Ford applied the same theory in 1910 when the assembly line was created to decrease human intervention in the automobile production process. For continuously variable process control it was not until 1922 that a formal control law for what we now call PID control or three-term control was first developed using theoretical analysis, by Russian American engineer Nicolas Minorsky. Minorsky was researching and designing automatic ship steering for the US Navy and based his analysis on observations of a helmsman. He noted the helmsman steered the ship based not only on the current course error, but also on past error, as well as the current rate of change; this was then given a mathematical treatment by Minorsky. His goal was stability, not general control, which simplified the problem significantly. While proportional control provided stability against small disturbances, it was insufficient for dealing with a steady disturbance, notably a stiff gale (due to steady-state error), which required adding the integral term. Finally, the derivative term was added to improve stability and control. == Development of modern process control operations == Process control of large industrial plants has evolved through many stages. Initially, control would be from panels local to the process plant. However this required a large manpower resource to attend to these dispersed panels, and there was no overall view of the process. The next logical development was the transmission of all plant measurements to a permanently-staffed central control room. Effectively this was the centralization of all the localized panels, with the advantages of lower manning levels and easier overview of the process. Often the controllers were behind the control room panels, and all automatic and manual control outputs were transmitted back to plant. However, whilst providing a central control focus, this arrangement was inflexible as each control loop had its own controller hardware, and continual operator movement within the control room was required to view different parts of the process. With the coming of electronic processors and graphic displays it became possible to replace these discrete controllers with computer-based algorithms, hosted on a network of input/output racks with their own control processors. These could be distributed around the plant, and communicate with the graphic display in the control room or rooms. The distributed control system (DCS) was born. The introduction of DCSs allowed easy interconnection and re-configuration of plant controls such as cascaded loops and interlocks, and easy interfacing with other production computer systems. It enabled sophisticated alarm handling, introduced automatic event logging, removed the need for physical records such as chart recorders, allowed the control racks to be networked and thereby located locally to plant to reduce cabling runs, and provided high level overviews of plant status and production levels. == Hierarchy == The accompanying diagram is a general model which shows functional manufacturing levels in a large process using processor and computer-based control. Referring to the diagram: Level 0 contains the field devices such as flow and temperature sensors (process value readings - PV), and final control elements (FCE), such as control valves; Level 1 contains the industrialized Input/Output (I/O) modules, and their associated distributed electronic processors; Level 2 contains the supervisory computers, which collate information from processor nodes on the system, and provide the operator control screens; Level 3 is the production control level, which does not directly control the process, but is concerned with monitoring production and monitoring targets; Level 4 is the production scheduling level. == Control model == To determine the fundamental model for any process, the inputs and outputs of the system are defined differently than for other chemical processes. The balance equations are defined by the control inputs and outputs rather than the material inputs. The control model is a set of equations used to predict the behavior of a system and can help determine what the response to change will be. The state variable (x) is a measurable variable that is a good indicator of the state of the system, such as temperature (energy balance), volume (mass balance) or concentration (component balance). Input variable (u) is a specified variable that commonly include flow rates. The entering and exiting flows are both considered control inputs. The control input can be classified as a manipulated, disturbance, or unmonitored variable. Parameters (p) are usually a physical limitation and something that is fixed for the system, such as the vessel volume or the viscosity of the material. Output (y) is the metric used to determine the behavior of the system. The control output can be classified as measured, unmeasured, or unmonitored. == Types == Processes can be characterized as batch, continuous, or hybrid. Batch applications require that specific quantities of raw materials be combined in specific ways for particular duration to produce an intermediate or end result. One example is the production of adhesives and glues, which normally require the mixing of raw materials in a heated vessel for a period of time to form a quantity of end product. Other important examples are the production of food, beverages and medicine. Batch processes are generally used to produce a relatively low to intermediate quantity of product per year (a few pounds to millions of pounds). A continuous physical system is represented through variables that are smooth and uninterrupted in time. The control of the water temperature in a heating jacket, for example, is an example of continuous process control. Some important continuous processes are the production of fuels, chemicals and plastics. Continuous processes in manufacturing are used to produce very large quantities of product per year (millions to billions of pounds). Such controls use feedback such as in the PID controller A PID Controller includes proportional, integrating, and derivative controller functions. Applications having elements of batch and continuous process control are often called hybrid applications. == Control loops == The fundamental building block of any industrial control system is the control loop, which controls just one process variable. An example is shown in the accompanying diagram, where the flow rate in a pipe is controlled by a PID controller, assisted by what is effectively a cascaded loop in the form of a valve servo-controller to ensure correct valve positioning. Some large systems may have several hundreds or thousands of control loops. In complex processes the loops are interactive, so that the operation of one loop may affect the operation of another. The system diagram for representing control loops is a Piping and instrumentation diagram. Commonly used control systems include programmable logic controller (PLC), Distributed Control System (DCS) or SCADA. A further example is shown. If a control valve were used to hold level in a tank, the level controller would compare the equivalent reading of a level sensor to the level setpoint and determine whether more or less valve opening was necessary to keep the level constant. A cascaded flow controller could then calculate the change in the valve position. == Economic advantages == The economic nature of many products manufactured in batch and continuous processes require highly efficient operation due to thin margins. The competing factor in process control is that products must meet certain specifications in order to be satisfactory. These specifications can come in two forms: a minimum and maximum for a property of the material or product, or a range within which the property must be. All loops are susceptible to disturbances and therefore a buffer must be used on process set points to ensure disturbances do not cause the material or product to go out of specifications. This buffer comes at an economic cost (i.e. additional processing, maintaining elevated or depressed process conditions, etc.). Process efficiency can be enhanced by reducing the margins necessary to ensure product specifications are met. This can be done by improving the control of the process to minimize the effect of disturbances on the process. The efficiency is improved in a two step method of narrowing the variance and shifting the target. Margins can be narrowed through various process upgrades (i.e. equipment upgrades, enhanced control methods, etc.). Once margins are narrowed, an economic analysis can be done on the process to determine how the set point target is to be shifted. Less conservative process set points lead to increased economic efficiency. Effective process control strategies increase the competitive advantage of manufacturers who employ them. == See also == == References == == Further reading == Walker, Mark John (2012-09-08). The Programmable Logic Controller: its prehistory, emergence and application (PDF) (PhD thesis). Department of Communication and Systems Faculty of Mathematics, Computing and Technology: The Open University. Archived (PDF) from the original on 2018-06-20. Retrieved 2018-06-20. == External links == A Complete Guide to Statistical Process Control The Michigan Chemical Engineering Process Dynamics and Controls Open Textbook PID control virtual laboratory, free video tutorials, on-line simulators, advanced process control schemes
Wikipedia/Industrial_process_control
In programming language theory, semantics is the rigorous mathematical study of the meaning of programming languages. Semantics assigns computational meaning to valid strings in a programming language syntax. It is closely related to, and often crosses over with, the semantics of mathematical proofs. Semantics describes the processes a computer follows when executing a program in that specific language. This can be done by describing the relationship between the input and output of a program, or giving an explanation of how the program will be executed on a certain platform, thereby creating a model of computation. == History == In 1967, Robert W. Floyd published the paper Assigning meanings to programs; his chief aim was "a rigorous standard for proofs about computer programs, including proofs of correctness, equivalence, and termination". Floyd further wrote: A semantic definition of a programming language, in our approach, is founded on a syntactic definition. It must specify which of the phrases in a syntactically correct program represent commands, and what conditions must be imposed on an interpretation in the neighborhood of each command. In 1969, Tony Hoare published a paper on Hoare logic seeded by Floyd's ideas, now sometimes collectively called axiomatic semantics. In the 1970s, the terms operational semantics and denotational semantics emerged. == Overview == The field of formal semantics encompasses all of the following: The definition of semantic models The relations between different semantic models The relations between different approaches to meaning The relation between computation and the underlying mathematical structures from fields such as logic, set theory, model theory, category theory, etc. It has close links with other areas of computer science such as programming language design, type theory, compilers and interpreters, program verification and model checking. == Approaches == There are many approaches to formal semantics; these belong to three major classes: Denotational semantics, whereby each phrase in the language is interpreted as a denotation, i.e. a conceptual meaning that can be thought of abstractly. Such denotations are often mathematical objects inhabiting a mathematical space, but it is not a requirement that they should be so. As a practical necessity, denotations are described using some form of mathematical notation, which can in turn be formalized as a denotational metalanguage. For example, denotational semantics of functional languages often translate the language into domain theory. Denotational semantic descriptions can also serve as compositional translations from a programming language into the denotational metalanguage and used as a basis for designing compilers. Operational semantics, whereby the execution of the language is described directly (rather than by translation). Operational semantics loosely corresponds to interpretation, although again the "implementation language" of the interpreter is generally a mathematical formalism. Operational semantics may define an abstract machine (such as the SECD machine), and give meaning to phrases by describing the transitions they induce on states of the machine. Alternatively, as with the pure lambda calculus, operational semantics can be defined via syntactic transformations on phrases of the language itself; Axiomatic semantics, whereby one gives meaning to phrases by describing the axioms that apply to them. Axiomatic semantics makes no distinction between a phrase's meaning and the logical formulas that describe it; its meaning is exactly what can be proven about it in some logic. The canonical example of axiomatic semantics is Hoare logic. Apart from the choice between denotational, operational, or axiomatic approaches, most variations in formal semantic systems arise from the choice of supporting mathematical formalism. == Variations == Some variations of formal semantics include the following: Action semantics is an approach that tries to modularize denotational semantics, splitting the formalization process in two layers (macro and microsemantics) and predefining three semantic entities (actions, data and yielders) to simplify the specification; Algebraic semantics is a form of axiomatic semantics based on algebraic laws for describing and reasoning about program semantics in a formal manner. It also supports denotational semantics and operational semantics; Attribute grammars define systems that systematically compute "metadata" (called attributes) for the various cases of the language's syntax. Attribute grammars can be understood as a denotational semantics where the target language is simply the original language enriched with attribute annotations. Aside from formal semantics, attribute grammars have also been used for code generation in compilers, and to augment regular or context-free grammars with context-sensitive conditions; Categorical (or "functorial") semantics uses category theory as the core mathematical formalism. Categorical semantics is usually proven to correspond to some axiomatic semantics that gives a syntactic presentation of the categorical structures. Also, denotational semantics are often instances of a general categorical semantics; Concurrency semantics is a catch-all term for any formal semantics that describes concurrent computations. Historically important concurrent formalisms have included the actor model and process calculi; Game semantics uses a metaphor inspired by game theory; Predicate transformer semantics, developed by Edsger W. Dijkstra, describes the meaning of a program fragment as the function transforming a postcondition to the precondition needed to establish it. == Describing relationships == For a variety of reasons, one might wish to describe the relationships between different formal semantics. For example: To prove that a particular operational semantics for a language satisfies the logical formulas of an axiomatic semantics for that language. Such a proof demonstrates that it is "sound" to reason about a particular (operational) interpretation strategy using a particular (axiomatic) proof system. To prove that operational semantics over a high-level machine is related by a simulation with the semantics over a low-level machine, whereby the low-level abstract machine contains more primitive operations than the high-level abstract machine definition of a given language. Such a proof demonstrates that the low-level machine "faithfully implements" the high-level machine. It is also possible to relate multiple semantics through abstractions via the theory of abstract interpretation. == See also == Computational semantics Formal semantics (logic) Formal semantics (linguistics) Ontology Ontology (information science) Semantic equivalence Semantic technology == References == == Further reading == Textbooks == External links == Aaby, Anthony (2004). Introduction to Programming Languages. Archived from the original on 2015-06-19. Semantics.
Wikipedia/Semantics_(computer_science)
In mathematics, a Boolean function is a function whose arguments and result assume values from a two-element set (usually {true, false}, {0,1} or {−1,1}). Alternative names are switching function, used especially in older computer science literature, and truth function (or logical function), used in logic. Boolean functions are the subject of Boolean algebra and switching theory. A Boolean function takes the form f : { 0 , 1 } k → { 0 , 1 } {\displaystyle f:\{0,1\}^{k}\to \{0,1\}} , where { 0 , 1 } {\displaystyle \{0,1\}} is known as the Boolean domain and k {\displaystyle k} is a non-negative integer called the arity of the function. In the case where k = 0 {\displaystyle k=0} , the function is a constant element of { 0 , 1 } {\displaystyle \{0,1\}} . A Boolean function with multiple outputs, f : { 0 , 1 } k → { 0 , 1 } m {\displaystyle f:\{0,1\}^{k}\to \{0,1\}^{m}} with m > 1 {\displaystyle m>1} is a vectorial or vector-valued Boolean function (an S-box in symmetric cryptography). There are 2 2 k {\displaystyle 2^{2^{k}}} different Boolean functions with k {\displaystyle k} arguments; equal to the number of different truth tables with 2 k {\displaystyle 2^{k}} entries. Every k {\displaystyle k} -ary Boolean function can be expressed as a propositional formula in k {\displaystyle k} variables x 1 , . . . , x k {\displaystyle x_{1},...,x_{k}} , and two propositional formulas are logically equivalent if and only if they express the same Boolean function. == Examples == The rudimentary symmetric Boolean functions (logical connectives or logic gates) are: NOT, negation or complement - which receives one input and returns true when that input is false ("not") AND or conjunction - true when all inputs are true ("both") OR or disjunction - true when any input is true ("either") XOR or exclusive disjunction - true when one of its inputs is true and the other is false ("not equal") NAND or Sheffer stroke - true when it is not the case that all inputs are true ("not both") NOR or logical nor - true when none of the inputs are true ("neither") XNOR or logical equality - true when both inputs are the same ("equal") An example of a more complicated function is the majority function (of an odd number of inputs). == Representation == A Boolean function may be specified in a variety of ways: Truth table: explicitly listing its value for all possible values of the arguments Marquand diagram: truth table values arranged in a two-dimensional grid (used in a Karnaugh map) Binary decision diagram, listing the truth table values at the bottom of a binary tree Venn diagram, depicting the truth table values as a colouring of regions of the plane Algebraically, as a propositional formula using rudimentary Boolean functions: Negation normal form, an arbitrary mix of AND and ORs of the arguments and their complements Disjunctive normal form, as an OR of ANDs of the arguments and their complements Conjunctive normal form, as an AND of ORs of the arguments and their complements Canonical normal form, a standardized formula which uniquely identifies the function: Algebraic normal form or Zhegalkin polynomial, as a XOR of ANDs of the arguments (no complements allowed) Full (canonical) disjunctive normal form, an OR of ANDs each containing every argument or complement (minterms) Full (canonical) conjunctive normal form, an AND of ORs each containing every argument or complement (maxterms) Blake canonical form, the OR of all the prime implicants of the function Boolean formulas can also be displayed as a graph: Propositional directed acyclic graph Digital circuit diagram of logic gates, a Boolean circuit And-inverter graph, using only AND and NOT In order to optimize electronic circuits, Boolean formulas can be minimized using the Quine–McCluskey algorithm or Karnaugh map. == Analysis == === Properties === A Boolean function can have a variety of properties: Constant: Is always true or always false regardless of its arguments. Monotone: for every combination of argument values, changing an argument from false to true can only cause the output to switch from false to true and not from true to false. A function is said to be unate in a certain variable if it is monotone with respect to changes in that variable. Linear: for each variable, flipping the value of the variable either always makes a difference in the truth value or never makes a difference (a parity function). Symmetric: the value does not depend on the order of its arguments. Read-once: Can be expressed with conjunction, disjunction, and negation with a single instance of each variable. Balanced: if its truth table contains an equal number of zeros and ones. The Hamming weight of the function is the number of ones in the truth table. Bent: its derivatives are all balanced (the autocorrelation spectrum is zero) Correlation immune to mth order: if the output is uncorrelated with all (linear) combinations of at most m arguments Evasive: if evaluation of the function always requires the value of all arguments A Boolean function is a Sheffer function if it can be used to create (by composition) any arbitrary Boolean function (see functional completeness) The algebraic degree of a function is the order of the highest order monomial in its algebraic normal form Circuit complexity attempts to classify Boolean functions with respect to the size or depth of circuits that can compute them. === Derived functions === A Boolean function may be decomposed using Boole's expansion theorem in positive and negative Shannon cofactors (Shannon expansion), which are the (k−1)-ary functions resulting from fixing one of the arguments (to 0 or 1). The general k-ary functions obtained by imposing a linear constraint on a set of inputs (a linear subspace) are known as subfunctions. The Boolean derivative of the function to one of the arguments is a (k−1)-ary function that is true when the output of the function is sensitive to the chosen input variable; it is the XOR of the two corresponding cofactors. A derivative and a cofactor are used in a Reed–Muller expansion. The concept can be generalized as a k-ary derivative in the direction dx, obtained as the difference (XOR) of the function at x and x + dx. The Möbius transform (or Boole–Möbius transform) of a Boolean function is the set of coefficients of its polynomial (algebraic normal form), as a function of the monomial exponent vectors. It is a self-inverse transform. It can be calculated efficiently using a butterfly algorithm ("Fast Möbius Transform"), analogous to the Fast Fourier Transform. Coincident Boolean functions are equal to their Möbius transform, i.e. their truth table (minterm) values equal their algebraic (monomial) coefficients. There are 2^2^(k−1) coincident functions of k arguments. === Cryptographic analysis === The Walsh transform of a Boolean function is a k-ary integer-valued function giving the coefficients of a decomposition into linear functions (Walsh functions), analogous to the decomposition of real-valued functions into harmonics by the Fourier transform. Its square is the power spectrum or Walsh spectrum. The Walsh coefficient of a single bit vector is a measure for the correlation of that bit with the output of the Boolean function. The maximum (in absolute value) Walsh coefficient is known as the linearity of the function. The highest number of bits (order) for which all Walsh coefficients are 0 (i.e. the subfunctions are balanced) is known as resiliency, and the function is said to be correlation immune to that order. The Walsh coefficients play a key role in linear cryptanalysis. The autocorrelation of a Boolean function is a k-ary integer-valued function giving the correlation between a certain set of changes in the inputs and the function output. For a given bit vector it is related to the Hamming weight of the derivative in that direction. The maximal autocorrelation coefficient (in absolute value) is known as the absolute indicator. If all autocorrelation coefficients are 0 (i.e. the derivatives are balanced) for a certain number of bits then the function is said to satisfy the propagation criterion to that order; if they are all zero then the function is a bent function. The autocorrelation coefficients play a key role in differential cryptanalysis. The Walsh coefficients of a Boolean function and its autocorrelation coefficients are related by the equivalent of the Wiener–Khinchin theorem, which states that the autocorrelation and the power spectrum are a Walsh transform pair. ==== Linear approximation table ==== These concepts can be extended naturally to vectorial Boolean functions by considering their output bits (coordinates) individually, or more thoroughly, by looking at the set of all linear functions of output bits, known as its components. The set of Walsh transforms of the components is known as a Linear Approximation Table (LAT) or correlation matrix; it describes the correlation between different linear combinations of input and output bits. The set of autocorrelation coefficients of the components is the autocorrelation table, related by a Walsh transform of the components to the more widely used Difference Distribution Table (DDT) which lists the correlations between differences in input and output bits (see also: S-box). == Real polynomial form == === On the unit hypercube === Any Boolean function f ( x ) : { 0 , 1 } n → { 0 , 1 } {\displaystyle f(x):\{0,1\}^{n}\rightarrow \{0,1\}} can be uniquely extended (interpolated) to the real domain by a multilinear polynomial in R n {\displaystyle \mathbb {R} ^{n}} , constructed by summing the truth table values multiplied by indicator polynomials: f ∗ ( x ) = ∑ a ∈ { 0 , 1 } n f ( a ) ∏ i : a i = 1 x i ∏ i : a i = 0 ( 1 − x i ) {\displaystyle f^{*}(x)=\sum _{a\in {\{0,1\}}^{n}}f(a)\prod _{i:a_{i}=1}x_{i}\prod _{i:a_{i}=0}(1-x_{i})} For example, the extension of the binary XOR function x ⊕ y {\displaystyle x\oplus y} is 0 ( 1 − x ) ( 1 − y ) + 1 x ( 1 − y ) + 1 ( 1 − x ) y + 0 x y {\displaystyle 0(1-x)(1-y)+1x(1-y)+1(1-x)y+0xy} which equals x + y − 2 x y {\displaystyle x+y-2xy} Some other examples are negation ( 1 − x {\displaystyle 1-x} ), AND ( x y {\displaystyle xy} ) and OR ( x + y − x y {\displaystyle x+y-xy} ). When all operands are independent (share no variables) a function's polynomial form can be found by repeatedly applying the polynomials of the operators in a Boolean formula. When the coefficients are calculated modulo 2 one obtains the algebraic normal form (Zhegalkin polynomial). Direct expressions for the coefficients of the polynomial can be derived by taking an appropriate derivative: f ∗ ( 00 ) = ( f ∗ ) ( 00 ) = f ( 00 ) f ∗ ( 01 ) = ( ∂ 1 f ∗ ) ( 00 ) = − f ( 00 ) + f ( 01 ) f ∗ ( 10 ) = ( ∂ 2 f ∗ ) ( 00 ) = − f ( 00 ) + f ( 10 ) f ∗ ( 11 ) = ( ∂ 1 ∂ 2 f ∗ ) ( 00 ) = f ( 00 ) − f ( 01 ) − f ( 10 ) + f ( 11 ) {\displaystyle {\begin{array}{lcl}f^{*}(00)&=&(f^{*})(00)&=&f(00)\\f^{*}(01)&=&(\partial _{1}f^{*})(00)&=&-f(00)+f(01)\\f^{*}(10)&=&(\partial _{2}f^{*})(00)&=&-f(00)+f(10)\\f^{*}(11)&=&(\partial _{1}\partial _{2}f^{*})(00)&=&f(00)-f(01)-f(10)+f(11)\\\end{array}}} this generalizes as the Möbius inversion of the partially ordered set of bit vectors: f ∗ ( m ) = ∑ a ⊆ m ( − 1 ) | a | + | m | f ( a ) {\displaystyle f^{*}(m)=\sum _{a\subseteq m}(-1)^{|a|+|m|}f(a)} where | a | {\displaystyle |a|} denotes the weight of the bit vector a {\displaystyle a} . Taken modulo 2, this is the Boolean Möbius transform, giving the algebraic normal form coefficients: f ^ ( m ) = ⨁ a ⊆ m f ( a ) {\displaystyle {\hat {f}}(m)=\bigoplus _{a\subseteq m}f(a)} In both cases, the sum is taken over all bit-vectors a covered by m, i.e. the "one" bits of a form a subset of the one bits of m. When the domain is restricted to the n-dimensional hypercube [ 0 , 1 ] n {\displaystyle [0,1]^{n}} , the polynomial f ∗ ( x ) : [ 0 , 1 ] n → [ 0 , 1 ] {\displaystyle f^{*}(x):[0,1]^{n}\rightarrow [0,1]} gives the probability of a positive outcome when the Boolean function f is applied to n independent random (Bernoulli) variables, with individual probabilities x. A special case of this fact is the piling-up lemma for parity functions. The polynomial form of a Boolean function can also be used as its natural extension to fuzzy logic. === On the symmetric hypercube === Often, the Boolean domain is taken as { − 1 , 1 } {\displaystyle \{-1,1\}} , with false ("0") mapping to 1 and true ("1") to −1 (see Analysis of Boolean functions). The polynomial corresponding to g ( x ) : { − 1 , 1 } n → { − 1 , 1 } {\displaystyle g(x):\{-1,1\}^{n}\rightarrow \{-1,1\}} is then given by: g ∗ ( x ) = ∑ a ∈ { − 1 , 1 } n g ( a ) ∏ i : a i = − 1 1 − x i 2 ∏ i : a i = 1 1 + x i 2 {\displaystyle g^{*}(x)=\sum _{a\in {\{-1,1\}}^{n}}g(a)\prod _{i:a_{i}=-1}{\frac {1-x_{i}}{2}}\prod _{i:a_{i}=1}{\frac {1+x_{i}}{2}}} Using the symmetric Boolean domain simplifies certain aspects of the analysis, since negation corresponds to multiplying by −1 and linear functions are monomials (XOR is multiplication). This polynomial form thus corresponds to the Walsh transform (in this context also known as Fourier transform) of the function (see above). The polynomial also has the same statistical interpretation as the one in the standard Boolean domain, except that it now deals with the expected values E ( X ) = P ( X = 1 ) − P ( X = − 1 ) ∈ [ − 1 , 1 ] {\displaystyle E(X)=P(X=1)-P(X=-1)\in [-1,1]} (see piling-up lemma for an example). == Applications == Boolean functions play a basic role in questions of complexity theory as well as the design of processors for digital computers, where they are implemented in electronic circuits using logic gates. The properties of Boolean functions are critical in cryptography, particularly in the design of symmetric key algorithms (see substitution box). In cooperative game theory, monotone Boolean functions are called simple games (voting games); this notion is applied to solve problems in social choice theory. == See also == == References == == Further reading == Crama, Yves; Hammer, Peter L. (2011), Boolean Functions: Theory, Algorithms, and Applications, Cambridge University Press, doi:10.1017/CBO9780511852008, ISBN 9780511852008 "Boolean function", Encyclopedia of Mathematics, EMS Press, 2001 [1994] Janković, Dragan; Stanković, Radomir S.; Moraga, Claudio (November 2003). "Arithmetic expressions optimisation using dual polarity property". Serbian Journal of Electrical Engineering. 1 (71–80, number 1): 71–80. doi:10.2298/SJEE0301071J. Arnold, Bradford Henry (1 January 2011). Logic and Boolean Algebra. Courier Corporation. ISBN 978-0-486-48385-6. Mano, M. M.; Ciletti, M. D. (2013), Digital Design, Pearson
Wikipedia/Boolean_function
Photograph manipulation involves the transformation or alteration of a photograph. Some photograph manipulations are considered to be skillful artwork, while others are considered to be unethical practices, especially when used to deceive. Motives for manipulating photographs include political propaganda, altering the appearance of a subject (both for better and for worse), entertainment and humor. Depending on the application and intent, some photograph manipulations are considered an art form because they involve creation of unique images and in some instances, signature expressions of art by photographic artists. For example, Ansel Adams used darkroom exposure techniques to darken and lighten photographs. Other techniques include retouching using ink or paint, airbrushing, double exposure, piecing photos or negatives together in the darkroom, and scratching instant films. Software for digital image manipulation ranges from casual to professional skillsets. One of these, Adobe Photoshop, has led to the use of the term photoshop, meaning to digitally edit an image with any program. == History and techniques == Photo manipulation dates back to some of the earliest photographs captured on glass and tin plates during the 19th century. The practice began not long after the creation of the first photograph (1825) by Joseph Nicéphore Niépce who developed heliography and made the first photographic print from a photoengraved printing plate. Traditional photographic prints can be altered using various methods and techniques that involve manipulation directly to the print, such as retouching with ink, paint, airbrushing, or scratching Polaroids during developing (Polaroid art). Negatives can be manipulated while still in the camera using double-exposure techniques, or in the darkroom by piecing photos or negatives together. Some darkroom manipulations involved techniques such as bleaching to artfully lighten or totally wash out parts of the photograph, hand coloring for aesthetic purposes, or mimicking a fine art painting. In the early 19th century, photography and the technology that made it possible were rather crude and cumbersome. While the equipment and technology progressed over time, it was not until the late 20th century that photography evolved into the digital realm. In the 20th century, digital retouching became available with Quantel computers running Paintbox in professional environments, which, alongside other contemporary packages, were effectively replaced in the market by editing software for graphic imaging, such as Adobe Photoshop and GIMP. At the onset, digital photography was considered by some to be a radical new approach and was initially rejected by photographers because of its substandard quality. The transition from film to digital has been an ongoing process, although much progress was made in the early 21st century as a result of innovation that has greatly improved digital image quality while reducing the bulk and weight of cameras and equipment. Ansel Adams used darkroom exposure techniques, burning (darkening) and dodging (lightening) a photograph. Whereas manipulating photographs with tools such as Photoshop and GIMP is generally skill-intensive and time-consuming, the 21st century has seen the arrival of image editing software powered by advanced algorithms which allow complex transformations to be mostly automated. For example, beauty filters which smooth skin tone and create more visually pleasing facial proportions (for example, by enlarging a subject's eyes) are available within a number of widely used social media apps such as Instagram and TikTok, and can be applied in real-time to live video. Such features are also available in dedicated image editing mobile applications like Facetune. Some, such as FaceApp use deep-learning algorithms to automate complex, content-aware transformations, such as changing the age or gender of the subject of a photo, or modifying their facial expression. The term deepfake was coined in 2017 to refer to real images and videos generated with deep-learning techniques. The alterations can be created for entertainment purposes, or more nefarious purposes such as spreading disinformation. Fraudulent creations can be used to conduct malicious attacks, political gains, financial crime, or fraud. More recently, deep fakes superimposing the faces of celebrities and other persons onto those of pornographic performers for the purpose of creating pornographic material has become prevalent; deepfake pornography has been criticized due to issues with lack of consent. Raw astronomical images of celestial objects are usually generated from data provided by complex digital cameras. Raw images include binary (black-and-white) or grayscale data generated in response to infrared or ultraviolet or other energy lying outside the visible light spectrum—requiring people to make technical decisions for how to transform the raw digital data into colorized pictures for human viewing. For example, in images from the James Webb Space Telescope and Hubble Space Telescope, the usual transformation is to use blue for the shortest wavelengths, red for the longest wavelengths, and green for intermediate wavelengths. Both scientific accuracy and visual appeal contribute to the decisions, for both enabling accurate analysis by scientists and providing visual interest for the public. Also, science visualization specialists sometimes stack images together, stitch observations from different instruments, enhance contrast, and remove artifacts. == Political and ethical issues == Photo manipulation has been used to deceive or persuade viewers or improve storytelling and self-expression. As early as the American Civil War, photographs were published as engravings based on more than one negative. In 1860, a photograph of the politician John Calhoun was manipulated and his body was used in another photograph with the head of the president of the United States, Abraham Lincoln. This photo credits itself as the first manipulated photo. Joseph Stalin made use of photo retouching for propaganda purposes. On May 5, 1920, his predecessor Vladimir Lenin held a speech for Soviet troops that Leon Trotsky attended. Stalin had Trotsky retouched out of a photograph showing Trotsky in attendance. In a well-known case of damnatio memoriae ("condemnation of memory") image manipulation, NKVD leader Nikolai Yezhov, after his execution in 1940, was removed from an official press photo where he was pictured with Stalin; historians subsequently nicknaming him the "Vanishing Commissar". Such censorship of images in the Soviet Union was common. The pioneer among journalists distorting photographic images for news value was Bernarr Macfadden: in the mid-1920s, his "composograph" process involved reenacting real news events with costumed body doubles and then photographing the dramatized scenes—then pasting faces of the real news-personalities (gathered from unrelated photos) onto his staged images. A photograph by Adolf Hitler's official photographer Heinrich Hoffmann was manipulated to show Hitler celebrating the outbreak of World War I in Munich. In the 1930s, artist John Heartfield used a type of photo manipulation known as the photomontage to critique Nazi propaganda. Some ethical theories have been applied to image manipulation. During a panel on the topic of ethics in image manipulation Aude Oliva theorized that categorical shifts are necessary in order for an edited image to be viewed as a manipulation. In Image Act Theory, Carson Reynolds extended speech act theory by applying it to photo editing and image manipulations. In "How to Do Things with Pictures", William J. Mitchell details the long history of photo manipulation and discusses it critically. Photo manipulation is largely considered a useful tool in modern political campaigning and photo manipulations are oftentimes used to amplify political messages and undermine political opponents. For example, on January 6, 2020, US Rep. Paul Gosar (R-Ariz.) tweeted a photo of US President Barack Obama shaking hands with Iranian President Hassan Rouhani, with the caption "The world is a better place without these guys in power." It was pointed out that this meeting never took place and in reality was a doctored photo of a meeting between President Obama and Indian Prime Minister Manmohan Singh. Gosar was criticized for attempting to spread disinformation. The photo had also been previously used in a 2015 advert for Senator Ron Johnson. In 2023, the organizers of Dublin Pride were accused of "intentionally doctoring photos" to push "propaganda" when they posted an altered image from a 1983 protest, in which the slogan "Trans rights are human rights" was added to a sign carried by a demonstrator. A spokesman for Dublin Pride defended the change, saying that the "practice of altering iconic images for campaigns is a common practice". The altered image was ultimately removed from the Dublin Pride website. === Use in journalism === A notable incident of controversial photo manipulation occurred over a photograph that was altered to fit the vertical orientation of a 1982 National Geographic magazine cover. The altered image made two Egyptian pyramids appear closer together than they actually were in the original photograph. The incident triggered a debate about the appropriateness of falsifying an image, and raised questions regarding the magazine's credibility. Shortly after the incident, Tom Kennedy, director of photography for National Geographic stated, "We no longer use that technology to manipulate elements in a photo simply to achieve a more compelling graphic effect. We regarded that afterward as a mistake, and we wouldn't repeat that mistake today." There are other incidents of questionable photo manipulation in journalism. One such incident occurred in early 2005 after Martha Stewart was released from prison. Newsweek used a photograph of Stewart's face on the body of a much slimmer woman for their cover, suggesting that Stewart had lost weight while in prison. Speaking about the incident in an interview, Lynn Staley, assistant managing editor at Newsweek said, "The piece that we commissioned was intended to show Martha as she would be, not necessarily as she is." Staley also explained that Newsweek disclosed on page 3 that the cover image of Martha Stewart was a composite. Image manipulation software has affected the level of trust many viewers once had in the aphorism "the camera never lies". Images may be manipulated for fun, aesthetic reasons, or to improve the appearance of a subject but not all image manipulation is innocuous, as evidenced by the Kerry Fonda 2004 election photo controversy. The image in question was a fraudulent composite image of John Kerry taken on June 13, 1971, and Jane Fonda taken in August 1972 sharing the same platform at a 1971 antiwar rally, the latter of which carried a fake Associated Press credit with the intent to change the public's perspective of reality. There is a growing body of writings devoted to the ethical use of digital editing in photojournalism. In the United States, for example, the National Press Photographers Association (NPPA) established a Code of Ethics which promotes the accuracy of published images, advising that photographers "do not manipulate images [...] that can mislead viewers or misrepresent subjects." Infringements of the Code are taken very seriously, especially regarding digital alteration of published photographs, as evidenced by a case in which Pulitzer Prize-nominated photographer Allan Detrich resigned his post following the revelation that a number of his photographs had been manipulated. In 2010, a Ukrainian photographer – Stepan Rudik, winner of the 3rd prize story in Sports Features – was disqualified due to violation of the rules of the World Press Photo contest. "After requesting RAW-files of the series from him, it became clear that an element had been removed from one of the original photographs." As of 2015, up to 20% of World Press Photo entries that made it to the penultimate round of the contest were disqualified after they were found to have been manipulated or post-processed with rules violations. == Retouching human subjects == A common form of photographic manipulation, particularly in advertising, fashion, boudoir, portrait, and glamour photography, involves edits intended to enhance the appearance of the subject. Common transformations include smoothing skin texture, erasing scars, pimples, and other skin blemishes, slimming the subject's body, and erasing wrinkles and folds. Commentators have raised concerns that such practices may lead to unrealistic expectations and negative body image among the audience. === Use in fashion === The photo manipulation industry has often been accused of promoting or inciting a distorted and unrealistic image of self — most specifically in younger people. The world of glamour photography is one specific industry that has been heavily involved with the use of photo manipulation (what many consider to be a concerning element as many people look up to celebrities in search of embodying the 'ideal figure'). Manipulation of a photo to alter a model's appearance can be used to change features such as skin complexion, hair color, body shape, and other features. Many of the alterations to skin involve removing blemishes through the use of features included within popular image editing programs which are designed for just such purposes. Photo editors may also alter the color of hair to remove roots or add shine. Additionally, the model's teeth and eyes may be made to look whiter than they are in reality. Makeup and piercings can even be edited into pictures to look as though the model was wearing them when the photo was taken. Through photo editing, the appearance of a model may be drastically changed to mask imperfections. In an article entitled "Confessions of a Retoucher: how the modeling industry is harming women", a professional retoucher who has worked for mega-fashion brands shares the industry's secrets. Along with fixing imperfections like skin wrinkles and smoothing features, the size of the model is manipulated by either adding or subtracting visible weight. Reverse retouching is just as common as making models skinnier, "distorting the bodies of very thin models to make them appear more robust in a process called reverse retouching. It is almost worse than making someone slimmer because the image claims you can be at an unhealthy weight but still look healthy. In reality, you can't, you have to Photoshop it". Reverse retouching includes eliminating shadows from protruding bones, adding flesh over body parts, color correcting, and removing hair generated for warmth from extreme weight loss. Professionals are saying that if an image is not labeled "not retouched", then the public can assume that photograph has been modified. As the fashion industry continues to use photos that have been manipulated to idealize body types, there is a need for education about how unreal and unhealthy these images are and the negative implications they are promoting. A digital manipulation expert, who edited and altered a lot of images for the fashion industry and wants to remain private, says it is normal to digitally manipulate a photograph of a model to make them appear thinner, regardless of actual weight. Generally, photographs are edited to remove the appearance of up to 10 kilograms (22 lb). However, in the past 20 years, the practice has changed, as more celebrities are on social media and the public is now more aware of their actual appearances; it is likely that significant alterations would be noticed. The retoucher notes that the industry's goal is to make significant income in advertising and that the unrealistic ideals cycle will continue as they have to maintain this. Starting in 2012, Seventeen magazine said they intended to no longer manipulate photos of their models. The decision was made after a 14-year-old girl, Julia Bluhm, petitioned that the magazine use a minimum of one unaltered photo in each of their spread per issue. The petition received over 84,000 signatures. === On social media === Social media apps such as Snapchat, Instagram, and TikTok enable users to manipulate photos using the back or front camera, applying pre-made filters to enhance the quality of the picture, distort themselves, or add creative elements such as text, coloring or stickers. Filters provided on social media platforms are made by social media companies or are user-generated content. Photo editing techniques include the addition of polls, GIFs, music, countdowns, donations, and links. Influencers use filters to grow engagement and boost follower activity, in order to be seen as unique, creative, or fascinating. Meta reported that over 600 million people have used an AR effect on Facebook or Instagram. Mobile phone applications such as Facetune allow users to modify their own personal images. Social media users, especially younger people, are thus exposed to an extreme amount of manipulated imagery presenting unrealistic, unachievable body ideals. For example, social media platforms such as TikTok have include filters that create an illusion of physical attributes, such as the "skinny filter" and the "perfect skin filter". Part of the idea of perfection on social media comes from Japanese culture and the word "kawaii", which translates to an overall aspect of cuteness; exerting fragile, girly, and childlike emotions. Kawaii-enhanced photos present a perception of perfection in a photo booth setting. This notion catalyzed the first selfie phone camera by Kyocera in 1999, which led to the posting of selfies during the beginnings of MySpace in the early 2000s. === In advertising === Photo manipulation has been used in advertisements for television commercials and magazines to make their products or the person look better and more appealing than how they look in reality. Some tricks that are used with photo manipulation for advertising are: fake grill marks with eye-liner, using white glue instead of milk, or using deodorant to make vegetables look glossy. === Celebrity opposition === Photo manipulation has triggered negative responses from both viewers and celebrities. This has led to celebrities refusing to have their photos retouched in support of the American Medical Association that has decided that "[we] must stop exposing impressionable children and teenagers to advertisements portraying models with body types only attainable with the help of photo editing software". These include Keira Knightley, Brad Pitt, Andy Roddick, Jessica Simpson, Lady Gaga, and Zendaya. Brad Pitt had a photographer, Chuck Close, take photos of him that emphasized his flaws. Chuck Close is known for his photos that emphasize the skin flaws of an individual. Pitt did so in an effort to speak out against media using image manipulation software and manipulating celebrities' photos in an attempt to hide their flaws. Kate Winslet spoke out against photo manipulation in media after GQ magazine altered her body, making it look unnaturally thin. 42-year-old Cate Blanchett appeared on the cover of Intelligent Life's 2012 March/April issue, makeup-free and without digital retouching for the first time. In April 2010, Britney Spears agreed to release "un-airbrushed images of herself next to the digitally altered ones". The fundamental motive behind her move was to "highlight the pressure exerted on women to look perfect". In 2014, Hungarian pop vocalist and songwriter Boggie produced two music videos that achieved global attention for its stance on whitewashing in the beauty industry: the #1 MAHASZ chart hit "Parfüm" (Hungarian version) and "Nouveau Parfum" (French version) from her self-titled album Boggie, which reached two Billboard charts (#3 Jazz Album, #17 World Music Album). In the videos, the artist is shown singing as she is extensively retouched in real-time, ending with a side-by-side comparison of her natural and manipulated images as the song fades out. === Corporate opposition === Some companies have begun to speak out against photo manipulation in advertising their products. Dove created the Dove Self-Esteem Fund and the Dove Campaign for Real Beauty to build confidence in young women, emphasizing "real beauty", or unretouched photographs, in the media. Clothing retailer Aerie's campaign #AerieREAL emphasizes that their clothes are for everyone and that their advertisements have not been retouched in any way, saying "The real you is sexy." The American Medical Association stated that it is opposed to the use of photo manipulation. Dr. McAneny made a statement that altering models to such extremes creates unrealistic expectations in children and teenagers regarding body image. He also said that the practice of digitally altering the weight of models in photographs should be stopped, so that children and teenagers are not exposed to body types that cannot be attained in reality. The American Medical Association as a whole adopted a policy to work with advertisers to work on setting up guidelines for advertisements to try to limit how much digital image manipulation is used. The goal of this policy is to limit the number of unrealistic expectations for body image in advertisements. === Government opposition === Governments are exerting pressure on advertisers, and are starting to ban photos that are too airbrushed and edited. In the United Kingdom, the Advertising Standards Authority has banned an advertisement by Lancôme featuring Julia Roberts for being misleading, stating that the flawless skin seen in the photo was too good to be true. The US is also moving in the direction of banning excessive photo manipulation where a CoverGirl model's ad was banned because it had exaggerated effects, leading to a misleading representation of the product. In 2015, France proceeded to pass a law that battles against the use of unrealistic body images and anorexia in the fashion industry. This includes modeling and photography. The models now have to show they are healthy and have a BMI of over 18 through a note from their doctor. Employers breaking this law will be fined and can serve a jail sentence of up to six months. When a creator of a photograph does not disclose that the picture is edited or retouched, no matter how small the edit, they may also receive a fine or 30% of the costs of what they used to create their ad. In 2021, Norway enacted legislation making it a requirement to label digital manipulations of the bodies of persons when depicted in advertising. Failure to do so is punishable by a fine. === Support === Some editors of magazine companies do not view manipulating their cover models as an issue. In an interview with the editor of the French magazine Marie Claire, she stated that their readers are not idiots and that they can tell when a model has been retouched. Also, some who support photo manipulation in the media state that the altered photographs are not the issue, but that it is the expectations that viewers have that they fail to meet, such as wanting to have the same body as a celebrity on the cover of their favorite magazine. === Opinion polling === A survey done by the United Kingdom-based fashion store New Look showed that 90% of the individuals surveyed would prefer seeing a wider variety of body shapes in media. This would involve them wanting to see cover models that are not all thin, but some with more curves than others. The survey also talked about how readers view the use of photo manipulation. One statistic stated that 15% of the readers believed that the cover images are accurate depictions of the model in reality. Also, they found that 33% of women who were surveyed are aiming for a body that is impossible for them to attain. Dove and People Weekly also did a survey to see how photo manipulation affects the self-esteem of females. In doing this, they found that 80% of the women surveyed felt insecure when seeing photos of celebrities in the media. Of the women surveyed who had lower self-esteem, 70% of them do not believe that their appearance is pretty or stylish enough in comparison to cover models. === Social and cultural implications === The growing popularity of image manipulation has raised concern as to whether it allows for unrealistic images to be portrayed to the public. In her article "On Photography" (1977), Susan Sontag discusses the objectivity, or lack thereof, in photography, concluding that "photographs, which fiddle with the scale of the world, themselves get reduced, blown up, cropped, retouched, doctored and tricked out". A practice widely used in the magazine industry, the use of photo manipulation on an already subjective photograph creates a constructed reality for the individual and it can become difficult to differentiate fact from fiction. With the potential to alter body image, debate continues as to whether manipulated images, particularly those in magazines, contribute to self-esteem issues in both men and women. In today's world, photo manipulation has a positive impact by developing the creativity of one's mind or maybe a negative one by removing the art and beauty of capturing something so magnificent and natural or the way it should be. According to The Huffington Post, "Photoshopping and airbrushing, many believe, are now an inherent part of the beauty industry, as are makeup, lighting and styling". In a way, these image alterations are "selling" actual people to the masses to affect responses, reactions, and emotions toward these cultural icons. == "Photoshop" as a verb == The terms "Photoshop", "photoshopped" and "photoshopping", derived from Adobe Photoshop, are ubiquitous and widely used colloquially and academically when referencing image editing software as it relates to digital manipulation and alteration of photographs. The term commonly refers to digital editing of photographs regardless of which software program is used. Trademark owner Adobe Inc. object to what they refer to as misuse of their trademarked software name, and consider it an infringement on their trademark to use terms such as "photoshopped" or "photoshopping" as a noun or verb, in possessive form or as a slang term, to prevent "genericization" or "genericide" of the company's trademark. Separately, the Free Software Foundation advises against using "photoshop" as a verb because Adobe Photoshop is proprietary software. In popular culture, the term photoshopping is sometimes associated with montages in the form of visual jokes, such as those published on Fark and in Mad magazine. Images may be propagated memetically via e-mail as humor or passed as actual news in a form of hoax. An example of the latter category is "Helicopter Shark", which was widely circulated as a so-called "National Geographic Photo of the Year" and was later revealed to be a hoax. Photoshop contests are games organized online with the goal of creating humorous images around a theme. == Gallery == == See also == == References == == External links == The dictionary definition of photograph manipulation at Wiktionary Media related to Photo manipulation at Wikimedia Commons Digital Tampering in the Media, Politics, and Law – a collection of digitally manipulated photos of political interest Hoax Photo Gallery – more manipulated photos Erased figures in Kagemni's tomb — discusses political image manipulation with an example from Ancient Egypt
Wikipedia/Photograph_manipulation
In mathematics, function application is the act of applying a function to an argument from its domain so as to obtain the corresponding value from its range. In this sense, function application can be thought of as the opposite of function abstraction. == Representation == Function application is usually depicted by juxtaposing the variable representing the function with its argument encompassed in parentheses. For example, the following expression represents the application of the function ƒ to its argument x. f ( x ) {\displaystyle f(x)} In some instances, a different notation is used where the parentheses aren't required, and function application can be expressed just by juxtaposition. For example, the following expression can be considered the same as the previous one: f x {\displaystyle f\;x} The latter notation is especially useful in combination with the currying isomorphism. Given a function f : ( X × Y ) → Z {\displaystyle f:(X\times Y)\to Z} , its application is represented as f ( x , y ) {\displaystyle f(x,y)} by the former notation and f ( x , y ) {\displaystyle f\;(x,y)} (or f ⟨ x , y ⟩ {\displaystyle f\;\langle x,y\rangle } with the argument ⟨ x , y ⟩ ∈ X × Y {\displaystyle \langle x,y\rangle \in X\times Y} written with the less common angle brackets) by the latter. However, functions in curried form f : X → ( Y → Z ) {\displaystyle f:X\to (Y\to Z)} can be represented by juxtaposing their arguments: f x y {\displaystyle f\;x\;y} , rather than f ( x ) ( y ) {\displaystyle f(x)(y)} . This relies on function application being left-associative. U+2061 FUNCTION APPLICATION (&af;, &ApplyFunction;) — a contiguity operator indicating application of a function; that is an invisible zero width character intended to distinguish concatenation meaning function application from concatenation meaning multiplication. == Set theory == In axiomatic set theory, especially Zermelo–Fraenkel set theory, a function f : X ↦ Y {\displaystyle f:X\mapsto Y} is often defined as a relation ( f ⊆ X × Y {\displaystyle f\subseteq X\times Y} ) having the property that, for any x ∈ X {\displaystyle x\in X} there is a unique y ∈ Y {\displaystyle y\in Y} such that ( x , y ) ∈ f {\displaystyle (x,y)\in f} . One is usually not content to write " ( x , y ) ∈ f {\displaystyle (x,y)\in f} " to specify that y {\displaystyle y} , and usually wishes for the more common function notation " f ( x ) = y {\displaystyle f(x)=y} ", thus function application, or more specifically, the notation " f ( x ) {\displaystyle f(x)} ", is defined by an axiom schema. Given any function f {\displaystyle f} with a given domain X {\displaystyle X} and codomain Y {\displaystyle Y} : ∀ x ∈ X , ∀ y ∈ Y ( f ( x ) = y ⟺ {\displaystyle \forall x\in X,\forall y\in Y(f(x)=y\iff } ∃ ! z ∈ Y ( ( x , z ) ∈ f ) ∧ ( x , y ) ∈ f ) {\displaystyle \exists !z\in Y((x,z)\in f)\,\land \,(x,y)\in f)} Stating "For all x {\displaystyle x} in X {\displaystyle X} and y {\displaystyle y} in Y {\displaystyle Y} , f ( x ) {\displaystyle f(x)} is equal to y {\displaystyle y} if and only if there is a unique z {\displaystyle z} in Y {\displaystyle Y} such that ( x , z ) {\displaystyle (x,z)} is in f {\displaystyle f} and ( x , y ) {\displaystyle (x,y)} is in f {\displaystyle f} ". The notation f ( x ) {\displaystyle f(x)} here being defined is a new functional predicate from the underlying logic, where each y is a term in x. Since f {\displaystyle f} , as a functional predicate, must map every object in the language, objects not in the specified domain are chosen to map to an arbitrary object, suct as the empty set. == As an operator == Function application can be defined as an operator, called apply or $ {\displaystyle \$} , by the following definition: f $ ⁡ x = f ( x ) {\displaystyle f\mathop {\,\$\,} x=f(x)} The operator may also be denoted by a backtick (`). If the operator is understood to be of low precedence and right-associative, the application operator can be used to cut down on the number of parentheses needed in an expression. For example; f ( g ( h ( j ( x ) ) ) ) {\displaystyle f(g(h(j(x))))} can be rewritten as: f $ ⁡ g $ ⁡ h $ ⁡ j $ ⁡ x {\displaystyle f\mathop {\,\$\,} g\mathop {\,\$\,} h\mathop {\,\$\,} j\mathop {\,\$\,} x} However, this is perhaps more clearly expressed by using function composition instead: ( f ∘ g ∘ h ∘ j ) ( x ) {\displaystyle (f\circ g\circ h\circ j)(x)} or even: ( f ∘ g ∘ h ∘ j ∘ x ) ( ) {\displaystyle (f\circ g\circ h\circ j\circ x)()} if one considers x {\displaystyle x} to be a constant function returning x {\displaystyle x} . == Other instances == Function application in the lambda calculus is expressed by β-reduction. The Curry–Howard correspondence relates function application to the logical rule of modus ponens. == See also == Polish notation == References ==
Wikipedia/Function_application
In computer science, a record (also called a structure, struct, or compound data type) is a composite data structure – a collection of fields, possibly of different data types, typically fixed in number and sequence. For example, a date could be stored as a record containing a numeric year field, a month field represented as a string, and a numeric day-of-month field. A circle record might contain a numeric radius and a center that is a point record containing x and y coordinates. Notable applications include the programming language record type and for row-based storage, data organized as a sequence of records, such as a database table, spreadsheet or comma-separated values (CSV) file. In general, a record type value is stored in memory and row-based storage is in mass storage. A record type is a data type that describes such values and variables. Most modern programming languages allow the programmer to define new record types. The definition includes specifying the data type of each field and an identifier (name or label) by which it can be accessed. In type theory, product types (with no field names) are generally preferred due to their simplicity, but proper record types are studied in languages such as System F-sub. Since type-theoretical records may contain first-class function-typed fields in addition to data, they can express many features of object-oriented programming. == Terminology == In the context of storage such as in a database or spreadsheet a record is often called a row and each field is called a column. In object-oriented programming, an object is a record that contains state and method fields. A record is similar to a mathematical tuple, although a tuple may or may not be considered a record, and vice versa, depending on conventions and the programming language. In the same vein, a record type can be viewed as the computer language analog of the Cartesian product of two or more mathematical sets, or the implementation of an abstract product type in a specific language. A record differs from an array in that a record's elements (fields) are determined by the definition of the record, and may be heterogeneous whereas an array is a collection of elements with the same type. The parameters of a function can be viewed collectively as the fields of a record and passing arguments to the function can be viewed as assigning the input parameters to the record fields. At a low-level, a function call includes an activation record or call frame, that contains the parameters as well as other fields such as local variables and the return address. == History == The concept of a record can be traced to various types of tables and ledgers used in accounting since remote times. The modern notion of records in computer science, with fields of well-defined type and size, was already implicit in 19th century mechanical calculators, such as Babbage's Analytical Engine. The original machine-readable medium used for data (as opposed to control) was the punch card used for records in the 1890 United States census: each punch card was a single record. Compare the journal entry from 1880 and the punch card from 1895. Records were well-established in the first half of the 20th century, when most data processing was done using punched cards. Typically, each record of a data file would be recorded on one punched card, with specific columns assigned to specific fields. Generally, a record was the smallest unit that could be read from external storage (e.g., card reader, tape, or disk). The contents of punchcard-style records were originally called "unit records" because punchcards had pre-determined document lengths. When storage systems became more advanced with the use of hard drives and magnetic tape, variable-length records became the standard. A variable-length record is a record in which the size of the record in bytes is approximately equal to the sum of the sizes of its fields. This was not possible to do before more advanced storage hardware was invented because all of the punchcards had to conform to pre-determined document lengths that the computer could read, since at the time the cards had to be physically fed into a machine. Most machine language implementations and early assembly languages did not have special syntax for records, but the concept was available (and extensively used) through the use of index registers, indirect addressing, and self-modifying code. Some early computers, such as the IBM 1620, had hardware support for delimiting records and fields, and special instructions for copying such records. The concept of records and fields was central in some early file sorting and tabulating utilities, such as IBM's Report Program Generator (RPG). COBOL was the first widespread programming language to support record types, and its record definition facilities were quite sophisticated at the time. The language allows for the definition of nested records with alphanumeric, integer, and fractional fields of arbitrary size and precision, and fields that automatically format any value assigned to them (e.g., insertion of currency signs, decimal points, and digit group separators). Each file is associated with a record variable where data is read into or written from. COBOL also provides a MOVE CORRESPONDING statement that assigns corresponding fields of two records according to their names. The early languages developed for numeric computing, such as FORTRAN (up to FORTRAN IV) and ALGOL 60, did not support record types; but later versions of those languages, such as FORTRAN 77 and ALGOL 68 did add them. The original Lisp programming language too was lacking records (except for the built-in cons cell), but its S-expressions provided an adequate surrogate. The Pascal programming language was one of the first languages to fully integrate record types with other basic types into a logically consistent type system. The PL/I language provided for COBOL-style records. The C language provides the record concept using structs. Most languages designed after Pascal (such as Ada, Modula, and Java), also supported records. Although records are not often used in their original context anymore (i.e. being used solely for the purpose of containing data), records influenced newer object-oriented programming languages and relational database management systems. Since records provided more modularity in the way data was stored and handled, they are better suited at representing complex, real-world concepts than the primitive data types provided by default in languages. This influenced later languages such as C++, Python, JavaScript, and Objective-C which address the same modularity needs of programming. Objects in these languages are essentially records with the addition of methods and inheritance, which allow programmers to manipulate the way data behaves instead of only the contents of a record. Many programmers regard records as obsolete now since object-oriented languages have features that far surpass what records are capable of. On the other hand, many programmers argue that the low overhead and ability to use records in assembly language make records still relevant when programming with low levels of abstraction. Today, the most popular languages on the TIOBE index, an indicator of the popularity of programming languages, have been influenced in some way by records due to the fact that they are object oriented. Query languages such as SQL and Object Query Language were also influenced by the concept of records. These languages allow the programmer to store sets of data, which are essentially records, in tables. This data can then be retrieved using a primary key. The tables themselves are also records which may have a foreign key: a key that references data in another table. == Record type == === Operations === Operations for a record type include: Declaration of a record type, including the position, type, and (possibly) name of each field Declaration of a record; a variable typed as a record type Construction of a record value; possibly with field value initialization Read and write record field value Comparison of two records for equality Computation of a standard hash value for the record Some languages provide facilities that enumerate the fields of a record. This facility is needed to implement certain services such as debugging, garbage collection, and serialization. It requires some degree of type polymorphism. In contexts that support record subtyping, operations include adding and removing fields of a record. A specific record type implies that a specific set of fields are present, but values of that type may contain additional fields. A record with fields x, y, and z would thus belong to the type of records with fields x and y, as would a record with fields x, y, and r. The rationale is that passing an (x,y,z) record to a function that expects an (x,y) record as argument should work, since that function will find all the fields it requires within the record. Many ways of practically implementing records in programming languages would have trouble with allowing such variability, but the matter is a central characteristic of record types in more theoretical contexts. ==== Assignment and comparison ==== Most languages allow assignment between records that have exactly the same record type (including same field types and names, in the same order). Depending on the language, however, two record data types defined separately may be regarded as distinct types even if they have exactly the same fields. Some languages may also allow assignment between records whose fields have different names, matching each field value with the corresponding field variable by their positions within the record; so that, for example, a complex number with fields called real and imag can be assigned to a 2D point record variable with fields X and Y. In this alternative, the two operands are still required to have the same sequence of field types. Some languages may also require that corresponding types have the same size and encoding as well, so that the whole record can be assigned as an uninterpreted bit string. Other languages may be more flexible in this regard, and require only that each value field can be legally assigned to the corresponding variable field; so that, for example, a short integer field can be assigned to a long integer field, or vice versa. Other languages (such as COBOL) may match fields and values by their names, rather than positions. These same possibilities apply to the comparison of two record values for equality. Some languages may also allow order comparisons ('<'and '>'), using the lexicographic order based on the comparison of individual fields. PL/I allows both of the preceding types of assignment, and also allows structure expressions, such as a = a+1; where "a" is a record, or structure in PL/I terminology. ==== Algol 68's distributive field selection ==== In Algol 68, if Pts was an array of records, each with integer fields X and Y, one could write Y of Pts to obtain an array of integers, consisting of the Y fields of all the elements of Pts. As a result, the statements Y of Pts[3] := 7 and (Y of Pts)[3] := 7 would have the same effect. ==== Pascal's "with" statement ==== In Pascal, the command with R do S would execute the command sequence S as if all the fields of record R had been declared as variables. Similarly to entering a different namespace in an object-oriented language like C#, it is no longer necessary to use the record name as a prefix to access the fields. So, instead of writing Pt.X := 5; Pt.Y := Pt.X + 3 one could write with Pt do begin X := 5; Y := X + 3 end. === Representation in memory === The representation of a record in memory varies depending on the programming language. Often, fields are stored in consecutive memory locations, in the same order as they are declared in the record type. This may result in two or more fields stored into the same word of memory; indeed, this feature is often used in systems programming to access specific bits of a word. On the other hand, most compilers will add padding fields, mostly invisible to the programmer, in order to comply with alignment constraints imposed by the machine—say, that a floating point field must occupy a single word. Some languages may implement a record as an array of addresses pointing to the fields (and, possibly, to their names and/or types). Objects in object-oriented languages are often implemented in rather complicated ways, especially in languages that allow multiple class inheritance. === Self-defining records === A self-defining record is a type of record which contains information to identify the record type and to locate information within the record. It may contain the offsets of elements; the elements can therefore be stored in any order or may be omitted. The information stored in a self-defining record can be interpreted as metadata for the record, which is similar to what one would expect to find in the UNIX metadata regarding a file, containing information such as the record's creation time and the size of the record in bytes. Alternatively, various elements of the record, each including an element identifier, can simply follow one another in any order. == Key field == A record, especially in the context of row-based storage, may include key fields that allow indexing the records of a collection. A primary key is unique throughout all stored records; only one of this key exists. In other words, no duplicate may exist for any primary key. For example, an employee file might contain employee number, name, department, and salary. The employee number will be unique in the organization and will be the primary key. Depending on the storage medium and file organization, the employee number might be indexed—that is also stored in a separate file to make the lookup faster. The department code is not necessarily unique; it may also be indexed, in which case it would be considered a secondary key, or alternate key. If it is not indexed, the entire employee file would have to be scanned to produce a listing of all employees in a specific department. Keys are usually chosen in a way that minimizes the chances of multiple values being feasibly mapped to by one key. For example, the salary field would not normally be considered usable as a key since many employees will likely have the same salary. == See also == Block (data storage) – Sequence of bits or bytes of a maximum predetermined size Composite data type – any data type which can be constructed in a program using the programming language's primitive data types and other composite typesPages displaying wikidata descriptions as a fallback Data hierarchy – Systematic organization of data Object composition – Method in computer programming of forming higher-level object types Passive data structure – Another term for record Union type – Data type that allows for values that are one of multiple different data types == References ==
Wikipedia/Record_(computer_science)
A computer network is a collection of communicating computers and other devices, such as printers and smart phones. In order to communicate, the computers and devices must be connected by wired media like copper cables, optical fibers, or by wireless communication. The devices may be connected in a variety of network topologies. In order to communicate over the network, computers use agreed-on rules, called communication protocols, over whatever medium is used. The computer network can include personal computers, servers, networking hardware, or other specialized or general-purpose hosts. They are identified by network addresses and may have hostnames. Hostnames serve as memorable labels for the nodes and are rarely changed after initial assignment. Network addresses serve for locating and identifying the nodes by communication protocols such as the Internet Protocol. Computer networks may be classified by many criteria, including the transmission medium used to carry signals, bandwidth, communications protocols to organize network traffic, the network size, the topology, traffic control mechanisms, and organizational intent. Computer networks support many applications and services, such as access to the World Wide Web, digital video and audio, shared use of application and storage servers, printers and fax machines, and use of email and instant messaging applications. == History == Computer networking may be considered a branch of computer science, computer engineering, and telecommunications, since it relies on the theoretical and practical application of the related disciplines. Computer networking was influenced by a wide array of technological developments and historical milestones. In the late 1950s, a network of computers was built for the U.S. military Semi-Automatic Ground Environment (SAGE) radar system using the Bell 101 modem. It was the first commercial modem for computers, released by AT&T Corporation in 1958. The modem allowed digital data to be transmitted over regular unconditioned telephone lines at a speed of 110 bits per second (bit/s). In 1959, Christopher Strachey filed a patent application for time-sharing in the United Kingdom and John McCarthy initiated the first project to implement time-sharing of user programs at MIT. Strachey passed the concept on to J. C. R. Licklider at the inaugural UNESCO Information Processing Conference in Paris that year. McCarthy was instrumental in the creation of three of the earliest time-sharing systems (the Compatible Time-Sharing System in 1961, the BBN Time-Sharing System in 1962, and the Dartmouth Time-Sharing System in 1963). In 1959, Anatoly Kitov proposed to the Central Committee of the Communist Party of the Soviet Union a detailed plan for the re-organization of the control of the Soviet armed forces and of the Soviet economy on the basis of a network of computing centers. Kitov's proposal was rejected, as later was the 1962 OGAS economy management network project. In 1960, the commercial airline reservation system semi-automatic business research environment (SABRE) went online with two connected mainframes. In 1963, J. C. R. Licklider sent a memorandum to office colleagues discussing the concept of the "Intergalactic Computer Network", a computer network intended to allow general communications among computer users. In 1965, Western Electric introduced the first widely used telephone switch that implemented computer control in the switching fabric. Throughout the 1960s, Paul Baran and Donald Davies independently invented the concept of packet switching for data communication between computers over a network. Baran's work addressed adaptive routing of message blocks across a distributed network, but did not include routers with software switches, nor the idea that users, rather than the network itself, would provide the reliability. Davies' hierarchical network design included high-speed routers, communication protocols and the essence of the end-to-end principle. The NPL network, a local area network at the National Physical Laboratory (United Kingdom), pioneered the implementation of the concept in 1968-69 using 768 kbit/s links. Both Baran's and Davies' inventions were seminal contributions that influenced the development of computer networks. In 1969, the first four nodes of the ARPANET were connected using 50 kbit/s circuits between the University of California at Los Angeles, the Stanford Research Institute, the University of California at Santa Barbara, and the University of Utah. Designed principally by Bob Kahn, the network's routing, flow control, software design and network control were developed by the IMP team working for Bolt Beranek & Newman. In the early 1970s, Leonard Kleinrock carried out mathematical work to model the performance of packet-switched networks, which underpinned the development of the ARPANET. His theoretical work on hierarchical routing in the late 1970s with student Farouk Kamoun remains critical to the operation of the Internet today. In 1972, commercial services were first deployed on experimental public data networks in Europe. In 1973, the French CYCLADES network, directed by Louis Pouzin was the first to make the hosts responsible for the reliable delivery of data, rather than this being a centralized service of the network itself. In 1973, Peter Kirstein put internetworking into practice at University College London (UCL), connecting the ARPANET to British academic networks, the first international heterogeneous computer network. In 1973, Robert Metcalfe wrote a formal memo at Xerox PARC describing Ethernet, a local area networking system he created with David Boggs. It was inspired by the packet radio ALOHAnet, started by Norman Abramson and Franklin Kuo at the University of Hawaii in the late 1960s. Metcalfe and Boggs, with John Shoch and Edward Taft, also developed the PARC Universal Packet for internetworking. In 1974, Vint Cerf and Bob Kahn published their seminal 1974 paper on internetworking, A Protocol for Packet Network Intercommunication. Later that year, Cerf, Yogen Dalal, and Carl Sunshine wrote the first Transmission Control Protocol (TCP) specification, RFC 675, coining the term Internet as a shorthand for internetworking. In July 1976, Metcalfe and Boggs published their paper "Ethernet: Distributed Packet Switching for Local Computer Networks" and in December 1977, together with Butler Lampson and Charles P. Thacker, they received U.S. patent 4063220A for their invention. Public data networks in Europe, North America and Japan began using X.25 in the late 1970s and interconnected with X.75. This underlying infrastructure was used for expanding TCP/IP networks in the 1980s. In 1976, John Murphy of Datapoint Corporation created ARCNET, a token-passing network first used to share storage devices. In 1977, the first long-distance fiber network was deployed by GTE in Long Beach, California. In 1979, Robert Metcalfe pursued making Ethernet an open standard. In 1980, Ethernet was upgraded from the original 2.94 Mbit/s protocol to the 10 Mbit/s protocol, which was developed by Ron Crane, Bob Garner, Roy Ogus, and Yogen Dalal. In 1995, the transmission speed capacity for Ethernet increased from 10 Mbit/s to 100 Mbit/s. By 1998, Ethernet supported transmission speeds of 1 Gbit/s. Subsequently, higher speeds of up to 400 Gbit/s were added (as of 2018). The scaling of Ethernet has been a contributing factor to its continued use. == Use == Computer networks enhance how users communicate with each other by using various electronic methods like email, instant messaging, online chat, voice and video calls, and video conferencing. Networks also enable the sharing of computing resources. For example, a user can print a document on a shared printer or use shared storage devices. Additionally, networks allow for the sharing of files and information, giving authorized users access to data stored on other computers. Distributed computing leverages resources from multiple computers across a network to perform tasks collaboratively. == Network packet == Most modern computer networks use protocols based on packet-mode transmission. A network packet is a formatted unit of data carried by a packet-switched network. Packets consist of two types of data: control information and user data (payload). The control information provides data the network needs to deliver the user data, for example, source and destination network addresses, error detection codes, and sequencing information. Typically, control information is found in packet headers and trailers, with payload data in between. With packets, the bandwidth of the transmission medium can be better shared among users than if the network were circuit switched. When one user is not sending packets, the link can be filled with packets from other users, and so the cost can be shared, with relatively little interference, provided the link is not overused. Often the route a packet needs to take through a network is not immediately available. In that case, the packet is queued and waits until a link is free. The physical link technologies of packet networks typically limit the size of packets to a certain maximum transmission unit (MTU). A longer message may be fragmented before it is transferred and once the packets arrive, they are reassembled to construct the original message. == Network topology == The physical or geographic locations of network nodes and links generally have relatively little effect on a network, but the topology of interconnections of a network can significantly affect its throughput and reliability. With many technologies, such as bus or star networks, a single failure can cause the network to fail entirely. In general, the more interconnections there are, the more robust the network is; but the more expensive it is to install. Therefore, most network diagrams are arranged by their network topology which is the map of logical interconnections of network hosts. Common topologies are: Bus network: all nodes are connected to a common medium along this medium. This was the layout used in the original Ethernet, called 10BASE5 and 10BASE2. This is still a common topology on the data link layer, although modern physical layer variants use point-to-point links instead, forming a star or a tree. Star network: all nodes are connected to a special central node. This is the typical layout found in a small switched Ethernet LAN, where each client connects to a central network switch, and logically in a wireless LAN, where each wireless client associates with the central wireless access point. Ring network: each node is connected to its left and right neighbor node, such that all nodes are connected and that each node can reach each other node by traversing nodes left- or rightwards. Token ring networks, and the Fiber Distributed Data Interface (FDDI), made use of such a topology. Mesh network: each node is connected to an arbitrary number of neighbors in such a way that there is at least one traversal from any node to any other. Fully connected network: each node is connected to every other node in the network. Tree network: nodes are arranged hierarchically. This is the natural topology for a larger Ethernet network with multiple switches and without redundant meshing. The physical layout of the nodes in a network may not necessarily reflect the network topology. As an example, with FDDI, the network topology is a ring, but the physical topology is often a star, because all neighboring connections can be routed via a central physical location. Physical layout is not completely irrelevant, however, as common ducting and equipment locations can represent single points of failure due to issues like fires, power failures and flooding. === Overlay network === An overlay network is a virtual network that is built on top of another network. Nodes in the overlay network are connected by virtual or logical links. Each link corresponds to a path, perhaps through many physical links, in the underlying network. The topology of the overlay network may (and often does) differ from that of the underlying one. For example, many peer-to-peer networks are overlay networks. They are organized as nodes of a virtual system of links that run on top of the Internet. Overlay networks have been used since the early days of networking, back when computers were connected via telephone lines using modems, even before data networks were developed. The most striking example of an overlay network is the Internet itself. The Internet itself was initially built as an overlay on the telephone network. Even today, each Internet node can communicate with virtually any other through an underlying mesh of sub-networks of wildly different topologies and technologies. Address resolution and routing are the means that allow mapping of a fully connected IP overlay network to its underlying network. Another example of an overlay network is a distributed hash table, which maps keys to nodes in the network. In this case, the underlying network is an IP network, and the overlay network is a table (actually a map) indexed by keys. Overlay networks have also been proposed as a way to improve Internet routing, such as through quality of service guarantees achieve higher-quality streaming media. Previous proposals such as IntServ, DiffServ, and IP multicast have not seen wide acceptance largely because they require modification of all routers in the network. On the other hand, an overlay network can be incrementally deployed on end-hosts running the overlay protocol software, without cooperation from Internet service providers. The overlay network has no control over how packets are routed in the underlying network between two overlay nodes, but it can control, for example, the sequence of overlay nodes that a message traverses before it reaches its destination. For example, Akamai Technologies manages an overlay network that provides reliable, efficient content delivery (a kind of multicast). Academic research includes end system multicast, resilient routing and quality of service studies, among others. == Network links == The transmission media (often referred to in the literature as the physical medium) used to link devices to form a computer network include electrical cable, optical fiber, and free space. In the OSI model, the software to handle the media is defined at layers 1 and 2 — the physical layer and the data link layer. A widely adopted family that uses copper and fiber media in local area network (LAN) technology are collectively known as Ethernet. The media and protocol standards that enable communication between networked devices over Ethernet are defined by IEEE 802.3. Wireless LAN standards use radio waves, others use infrared signals as a transmission medium. Power line communication uses a building's power cabling to transmit data. === Wired === The following classes of wired technologies are used in computer networking. Coaxial cable is widely used for cable television systems, office buildings, and other work-sites for local area networks. Transmission speed ranges from 200 million bits per second to more than 500 million bits per second. ITU-T G.hn technology uses existing home wiring (coaxial cable, phone lines and power lines) to create a high-speed local area network. Twisted pair cabling is used for wired Ethernet and other standards. It typically consists of 4 pairs of copper cabling that can be utilized for both voice and data transmission. The use of two wires twisted together helps to reduce crosstalk and electromagnetic induction. The transmission speed ranges from 2 Mbit/s to 10 Gbit/s. Twisted pair cabling comes in two forms: unshielded twisted pair (UTP) and shielded twisted-pair (STP). Each form comes in several category ratings, designed for use in various scenarios. An optical fiber is a glass fiber. It carries pulses of light that represent data via lasers and optical amplifiers. Some advantages of optical fibers over metal wires are very low transmission loss and immunity to electrical interference. Using dense wave division multiplexing, optical fibers can simultaneously carry multiple streams of data on different wavelengths of light, which greatly increases the rate that data can be sent to up to trillions of bits per second. Optic fibers can be used for long runs of cable carrying very high data rates, and are used for undersea communications cables to interconnect continents. There are two basic types of fiber optics, single-mode optical fiber (SMF) and multi-mode optical fiber (MMF). Single-mode fiber has the advantage of being able to sustain a coherent signal for dozens or even a hundred kilometers. Multimode fiber is cheaper to terminate but is limited to a few hundred or even only a few dozens of meters, depending on the data rate and cable grade. === Wireless === Network connections can be established wirelessly using radio or other electromagnetic means of communication. Terrestrial microwave – Terrestrial microwave communication uses Earth-based transmitters and receivers resembling satellite dishes. Terrestrial microwaves are in the low gigahertz range, which limits all communications to line-of-sight. Relay stations are spaced approximately 40 miles (64 km) apart. Communications satellites – Satellites also communicate via microwave. The satellites are stationed in space, typically in geosynchronous orbit 35,400 km (22,000 mi) above the equator. These Earth-orbiting systems are capable of receiving and relaying voice, data, and TV signals. Cellular networks use several radio communications technologies. The systems divide the region covered into multiple geographic areas. Each area is served by a low-power transceiver. Radio and spread spectrum technologies – Wireless LANs use a high-frequency radio technology similar to digital cellular. Wireless LANs use spread spectrum technology to enable communication between multiple devices in a limited area. IEEE 802.11 defines a common flavor of open-standards wireless radio-wave technology known as Wi-Fi. Free-space optical communication uses visible or invisible light for communications. In most cases, line-of-sight propagation is used, which limits the physical positioning of communicating devices. Extending the Internet to interplanetary dimensions via radio waves and optical means, the Interplanetary Internet. IP over Avian Carriers was a humorous April fool's Request for Comments, issued as RFC 1149. It was implemented in real life in 2001. The last two cases have a large round-trip delay time, which gives slow two-way communication but does not prevent sending large amounts of information (they can have high throughput). == Network nodes == Apart from any physical transmission media, networks are built from additional basic system building blocks, such as network interface controllers, repeaters, hubs, bridges, switches, routers, modems, and firewalls. Any particular piece of equipment will frequently contain multiple building blocks and so may perform multiple functions. === Network interfaces === A network interface controller (NIC) is computer hardware that connects the computer to the network media and has the ability to process low-level network information. For example, the NIC may have a connector for plugging in a cable, or an aerial for wireless transmission and reception, and the associated circuitry. In Ethernet networks, each NIC has a unique Media Access Control (MAC) address—usually stored in the controller's permanent memory. To avoid address conflicts between network devices, the Institute of Electrical and Electronics Engineers (IEEE) maintains and administers MAC address uniqueness. The size of an Ethernet MAC address is six octets. The three most significant octets are reserved to identify NIC manufacturers. These manufacturers, using only their assigned prefixes, uniquely assign the three least-significant octets of every Ethernet interface they produce. === Repeaters and hubs === A repeater is an electronic device that receives a network signal, cleans it of unnecessary noise and regenerates it. The signal is retransmitted at a higher power level, or to the other side of obstruction so that the signal can cover longer distances without degradation. In most twisted-pair Ethernet configurations, repeaters are required for cable that runs longer than 100 meters. With fiber optics, repeaters can be tens or even hundreds of kilometers apart. Repeaters work on the physical layer of the OSI model but still require a small amount of time to regenerate the signal. This can cause a propagation delay that affects network performance and may affect proper function. As a result, many network architectures limit the number of repeaters used in a network, e.g., the Ethernet 5-4-3 rule. An Ethernet repeater with multiple ports is known as an Ethernet hub. In addition to reconditioning and distributing network signals, a repeater hub assists with collision detection and fault isolation for the network. Hubs and repeaters in LANs have been largely obsoleted by modern network switches. === Bridges and switches === Network bridges and network switches are distinct from a hub in that they only forward frames to the ports involved in the communication whereas a hub forwards to all ports. Bridges only have two ports but a switch can be thought of as a multi-port bridge. Switches normally have numerous ports, facilitating a star topology for devices, and for cascading additional switches. Bridges and switches operate at the data link layer (layer 2) of the OSI model and bridge traffic between two or more network segments to form a single local network. Both are devices that forward frames of data between ports based on the destination MAC address in each frame. They learn the association of physical ports to MAC addresses by examining the source addresses of received frames and only forward the frame when necessary. If an unknown destination MAC is targeted, the device broadcasts the request to all ports except the source, and discovers the location from the reply. Bridges and switches divide the network's collision domain but maintain a single broadcast domain. Network segmentation through bridging and switching helps break down a large, congested network into an aggregation of smaller, more efficient networks. === Routers === A router is an internetworking device that forwards packets between networks by processing the addressing or routing information included in the packet. The routing information is often processed in conjunction with the routing table. A router uses its routing table to determine where to forward packets and does not require broadcasting packets which is inefficient for very big networks. === Modems === Modems (modulator-demodulator) are used to connect network nodes via wire not originally designed for digital network traffic, or for wireless. To do this one or more carrier signals are modulated by the digital signal to produce an analog signal that can be tailored to give the required properties for transmission. Early modems modulated audio signals sent over a standard voice telephone line. Modems are still commonly used for telephone lines, using a digital subscriber line technology and cable television systems using DOCSIS technology. === Firewalls === A firewall is a network device or software for controlling network security and access rules. Firewalls are inserted in connections between secure internal networks and potentially insecure external networks such as the Internet. Firewalls are typically configured to reject access requests from unrecognized sources while allowing actions from recognized ones. The vital role firewalls play in network security grows in parallel with the constant increase in cyber attacks. == Communication protocols == A communication protocol is a set of rules for exchanging information over a network. Communication protocols have various characteristics. They may be connection-oriented or connectionless, they may use circuit mode or packet switching, and they may use hierarchical addressing or flat addressing. In a protocol stack, often constructed per the OSI model, communications functions are divided up into protocol layers, where each layer leverages the services of the layer below it until the lowest layer controls the hardware that sends information across the media. The use of protocol layering is ubiquitous across the field of computer networking. An important example of a protocol stack is HTTP (the World Wide Web protocol) running over TCP over IP (the Internet protocols) over IEEE 802.11 (the Wi-Fi protocol). This stack is used between the wireless router and the home user's personal computer when the user is surfing the web. There are many communication protocols, a few of which are described below. === Common protocols === ==== Internet protocol suite ==== The Internet protocol suite, also called TCP/IP, is the foundation of all modern networking. It offers connection-less and connection-oriented services over an inherently unreliable network traversed by datagram transmission using Internet protocol (IP). At its core, the protocol suite defines the addressing, identification, and routing specifications for Internet Protocol Version 4 (IPv4) and for IPv6, the next generation of the protocol with a much enlarged addressing capability. The Internet protocol suite is the defining set of protocols for the Internet. ==== IEEE 802 ==== IEEE 802 is a family of IEEE standards dealing with local area networks and metropolitan area networks. The complete IEEE 802 protocol suite provides a diverse set of networking capabilities. The protocols have a flat addressing scheme. They operate mostly at layers 1 and 2 of the OSI model. For example, MAC bridging (IEEE 802.1D) deals with the routing of Ethernet packets using a Spanning Tree Protocol. IEEE 802.1Q describes VLANs, and IEEE 802.1X defines a port-based network access control protocol, which forms the basis for the authentication mechanisms used in VLANs (but it is also found in WLANs) – it is what the home user sees when the user has to enter a "wireless access key". ===== Ethernet ===== Ethernet is a family of technologies used in wired LANs. It is described by a set of standards together called IEEE 802.3 published by the Institute of Electrical and Electronics Engineers. ===== Wireless LAN ===== Wireless LAN based on the IEEE 802.11 standards, also widely known as WLAN or WiFi, is probably the most well-known member of the IEEE 802 protocol family for home users today. IEEE 802.11 shares many properties with wired Ethernet. ==== SONET/SDH ==== Synchronous optical networking (SONET) and Synchronous Digital Hierarchy (SDH) are standardized multiplexing protocols that transfer multiple digital bit streams over optical fiber using lasers. They were originally designed to transport circuit mode communications from a variety of different sources, primarily to support circuit-switched digital telephony. However, due to its protocol neutrality and transport-oriented features, SONET/SDH also was the obvious choice for transporting Asynchronous Transfer Mode (ATM) frames. ==== Asynchronous Transfer Mode ==== Asynchronous Transfer Mode (ATM) is a switching technique for telecommunication networks. It uses asynchronous time-division multiplexing and encodes data into small, fixed-sized cells. This differs from other protocols such as the Internet protocol suite or Ethernet that use variable-sized packets or frames. ATM has similarities with both circuit and packet switched networking. This makes it a good choice for a network that must handle both traditional high-throughput data traffic, and real-time, low-latency content such as voice and video. ATM uses a connection-oriented model in which a virtual circuit must be established between two endpoints before the actual data exchange begins. ATM still plays a role in the last mile, which is the connection between an Internet service provider and the home user. ==== Cellular standards ==== There are a number of different digital cellular standards, including: Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), cdmaOne, CDMA2000, Evolution-Data Optimized (EV-DO), Enhanced Data Rates for GSM Evolution (EDGE), Universal Mobile Telecommunications System (UMTS), Digital Enhanced Cordless Telecommunications (DECT), Digital AMPS (IS-136/TDMA), and Integrated Digital Enhanced Network (iDEN). === Routing === Routing is the process of selecting network paths to carry network traffic. Routing is performed for many kinds of networks, including circuit switching networks and packet switched networks. In packet-switched networks, routing protocols direct packet forwarding through intermediate nodes. Intermediate nodes are typically network hardware devices such as routers, bridges, gateways, firewalls, or switches. General-purpose computers can also forward packets and perform routing, though because they lack specialized hardware, may offer limited performance. The routing process directs forwarding on the basis of routing tables, which maintain a record of the routes to various network destinations. Most routing algorithms use only one network path at a time. Multipath routing techniques enable the use of multiple alternative paths. Routing can be contrasted with bridging in its assumption that network addresses are structured and that similar addresses imply proximity within the network. Structured addresses allow a single routing table entry to represent the route to a group of devices. In large networks, the structured addressing used by routers outperforms unstructured addressing used by bridging. Structured IP addresses are used on the Internet. Unstructured MAC addresses are used for bridging on Ethernet and similar local area networks. == Geographic scale == Networks may be characterized by many properties or features, such as physical capacity, organizational purpose, user authorization, access rights, and others. Another distinct classification method is that of the physical extent or geographic scale. === Nanoscale network === A nanoscale network has key components implemented at the nanoscale, including message carriers, and leverages physical principles that differ from macroscale communication mechanisms. Nanoscale communication extends communication to very small sensors and actuators such as those found in biological systems and also tends to operate in environments that would be too harsh for other communication techniques. === Personal area network === A personal area network (PAN) is a computer network used for communication among computers and different information technological devices close to one person. Some examples of devices that are used in a PAN are personal computers, printers, fax machines, telephones, PDAs, scanners, and video game consoles. A PAN may include wired and wireless devices. The reach of a PAN typically extends to 10 meters. A wired PAN is usually constructed with USB and FireWire connections while technologies such as Bluetooth and infrared communication typically form a wireless PAN. === Local area network === A local area network (LAN) is a network that connects computers and devices in a limited geographical area such as a home, school, office building, or closely positioned group of buildings. Wired LANs are most commonly based on Ethernet technology. Other networking technologies such as ITU-T G.hn also provide a way to create a wired LAN using existing wiring, such as coaxial cables, telephone lines, and power lines. A LAN can be connected to a wide area network (WAN) using a router. The defining characteristics of a LAN, in contrast to a WAN, include higher data transfer rates, limited geographic range, and lack of reliance on leased lines to provide connectivity. Current Ethernet or other IEEE 802.3 LAN technologies operate at data transfer rates up to and in excess of 100 Gbit/s, standardized by IEEE in 2010. === Home area network === A home area network (HAN) is a residential LAN used for communication between digital devices typically deployed in the home, usually a small number of personal computers and accessories, such as printers and mobile computing devices. An important function is the sharing of Internet access, often a broadband service through a cable Internet access or digital subscriber line (DSL) provider. === Storage area network === A storage area network (SAN) is a dedicated network that provides access to consolidated, block-level data storage. SANs are primarily used to make storage devices, such as disk arrays, tape libraries, and optical jukeboxes, accessible to servers so that the storage appears as locally attached devices to the operating system. A SAN typically has its own network of storage devices that are generally not accessible through the local area network by other devices. The cost and complexity of SANs dropped in the early 2000s to levels allowing wider adoption across both enterprise and small to medium-sized business environments. === Campus area network === A campus area network (CAN) is made up of an interconnection of LANs within a limited geographical area. The networking equipment (switches, routers) and transmission media (optical fiber, Cat5 cabling, etc.) are almost entirely owned by the campus tenant or owner (an enterprise, university, government, etc.). For example, a university campus network is likely to link a variety of campus buildings to connect academic colleges or departments, the library, and student residence halls. === Backbone network === A backbone network is part of a computer network infrastructure that provides a path for the exchange of information between different LANs or subnetworks. A backbone can tie together diverse networks within the same building, across different buildings, or over a wide area. When designing a network backbone, network performance and network congestion are critical factors to take into account. Normally, the backbone network's capacity is greater than that of the individual networks connected to it. For example, a large company might implement a backbone network to connect departments that are located around the world. The equipment that ties together the departmental networks constitutes the network backbone. Another example of a backbone network is the Internet backbone, which is a massive, global system of fiber-optic cable and optical networking that carry the bulk of data between wide area networks (WANs), metro, regional, national and transoceanic networks. === Metropolitan area network === A metropolitan area network (MAN) is a large computer network that interconnects users with computer resources in a geographic region of the size of a metropolitan area. === Wide area network === A wide area network (WAN) is a computer network that covers a large geographic area such as a city, country, or spans even intercontinental distances. A WAN uses a communications channel that combines many types of media such as telephone lines, cables, and airwaves. A WAN often makes use of transmission facilities provided by common carriers, such as telephone companies. WAN technologies generally function at the lower three layers of the OSI model: the physical layer, the data link layer, and the network layer. === Enterprise private network === An enterprise private network is a network that a single organization builds to interconnect its office locations (e.g., production sites, head offices, remote offices, shops) so they can share computer resources. === Virtual private network === A virtual private network (VPN) is an overlay network in which some of the links between nodes are carried by open connections or virtual circuits in some larger network (e.g., the Internet) instead of by physical wires. The data link layer protocols of the virtual network are said to be tunneled through the larger network. One common application is secure communications through the public Internet, but a VPN need not have explicit security features, such as authentication or content encryption. VPNs, for example, can be used to separate the traffic of different user communities over an underlying network with strong security features. VPN may have best-effort performance or may have a defined service level agreement (SLA) between the VPN customer and the VPN service provider. === Global area network === A global area network (GAN) is a network used for supporting mobile users across an arbitrary number of wireless LANs, satellite coverage areas, etc. The key challenge in mobile communications is handing off communications from one local coverage area to the next. In IEEE Project 802, this involves a succession of terrestrial wireless LANs. == Organizational scope == Networks are typically managed by the organizations that own them. Private enterprise networks may use a combination of intranets and extranets. They may also provide network access to the Internet, which has no single owner and permits virtually unlimited global connectivity. === Intranet === An intranet is a set of networks that are under the control of a single administrative entity. An intranet typically uses the Internet Protocol and IP-based tools such as web browsers and file transfer applications. The administrative entity limits the use of the intranet to its authorized users. Most commonly, an intranet is the internal LAN of an organization. A large intranet typically has at least one web server to provide users with organizational information. === Extranet === An extranet is a network that is under the administrative control of a single organization but supports a limited connection to a specific external network. For example, an organization may provide access to some aspects of its intranet to share data with its business partners or customers. These other entities are not necessarily trusted from a security standpoint. The network connection to an extranet is often, but not always, implemented via WAN technology. === Internet === An internetwork is the connection of multiple different types of computer networks to form a single computer network using higher-layer network protocols and connecting them together using routers. The Internet is the largest example of internetwork. It is a global system of interconnected governmental, academic, corporate, public, and private computer networks. It is based on the networking technologies of the Internet protocol suite. It is the successor of the Advanced Research Projects Agency Network (ARPANET) developed by DARPA of the United States Department of Defense. The Internet utilizes copper communications and an optical networking backbone to enable the World Wide Web (WWW), the Internet of things, video transfer, and a broad range of information services. Participants on the Internet use a diverse array of methods of several hundred documented, and often standardized, protocols compatible with the Internet protocol suite and the IP addressing system administered by the Internet Assigned Numbers Authority and address registries. Service providers and large enterprises exchange information about the reachability of their address spaces through the Border Gateway Protocol (BGP), forming a redundant worldwide mesh of transmission paths. === Darknet === A darknet is an overlay network, typically running on the Internet, that is only accessible through specialized software. It is an anonymizing network where connections are made only between trusted peers — sometimes called friends (F2F) — using non-standard protocols and ports. Darknets are distinct from other distributed peer-to-peer networks as sharing is anonymous (that is, IP addresses are not publicly shared), and therefore users can communicate with little fear of governmental or corporate interference. == Network service == Network services are applications hosted by servers on a computer network, to provide some functionality for members or users of the network, or to help the network itself to operate. The World Wide Web, E-mail, printing and network file sharing are examples of well-known network services. Network services such as Domain Name System (DNS) give names for IP and MAC addresses (people remember names like nm.lan better than numbers like 210.121.67.18), and Dynamic Host Configuration Protocol (DHCP) to ensure that the equipment on the network has a valid IP address. Services are usually based on a service protocol that defines the format and sequencing of messages between clients and servers of that network service. == Network performance == === Bandwidth === Bandwidth in bit/s may refer to consumed bandwidth, corresponding to achieved throughput or goodput, i.e., the average rate of successful data transfer through a communication path. The throughput is affected by processes such as bandwidth shaping, bandwidth management, bandwidth throttling, bandwidth cap and bandwidth allocation (using, for example, bandwidth allocation protocol and dynamic bandwidth allocation). === Network delay === Network delay is a design and performance characteristic of a telecommunications network. It specifies the latency for a bit of data to travel across the network from one communication endpoint to another. Delay may differ slightly, depending on the location of the specific pair of communicating endpoints. Engineers usually report both the maximum and average delay, and they divide the delay into several components, the sum of which is the total delay: Processing delay – time it takes a router to process the packet header Queuing delay – time the packet spends in routing queues Transmission delay – time it takes to push the packet's bits onto the link Propagation delay – time for a signal to propagate through the media A certain minimum level of delay is experienced by signals due to the time it takes to transmit a packet serially through a link. This delay is extended by more variable levels of delay due to network congestion. IP network delays can range from less than a microsecond to several hundred milliseconds. === Performance metrics === The parameters that affect performance typically can include throughput, jitter, bit error rate and latency. In circuit-switched networks, network performance is synonymous with the grade of service. The number of rejected calls is a measure of how well the network is performing under heavy traffic loads. Other types of performance measures can include the level of noise and echo. In an Asynchronous Transfer Mode (ATM) network, performance can be measured by line rate, quality of service (QoS), data throughput, connect time, stability, technology, modulation technique, and modem enhancements. There are many ways to measure the performance of a network, as each network is different in nature and design. Performance can also be modeled instead of measured. For example, state transition diagrams are often used to model queuing performance in a circuit-switched network. The network planner uses these diagrams to analyze how the network performs in each state, ensuring that the network is optimally designed. === Network congestion === Network congestion occurs when a link or node is subjected to a greater data load than it is rated for, resulting in a deterioration of its quality of service. When networks are congested and queues become too full, packets have to be discarded, and participants must rely on retransmission to maintain reliable communications. Typical effects of congestion include queueing delay, packet loss or the blocking of new connections. A consequence of these latter two is that incremental increases in offered load lead either to only a small increase in the network throughput or to a potential reduction in network throughput. Network protocols that use aggressive retransmissions to compensate for packet loss tend to keep systems in a state of network congestion even after the initial load is reduced to a level that would not normally induce network congestion. Thus, networks using these protocols can exhibit two stable states under the same level of load. The stable state with low throughput is known as congestive collapse. Modern networks use congestion control, congestion avoidance and traffic control techniques where endpoints typically slow down or sometimes even stop transmission entirely when the network is congested to try to avoid congestive collapse. Specific techniques include: exponential backoff in protocols such as 802.11's CSMA/CA and the original Ethernet, window reduction in TCP, and fair queueing in devices such as routers. Another method to avoid the negative effects of network congestion is implementing quality of service priority schemes allowing selected traffic to bypass congestion. Priority schemes do not solve network congestion by themselves, but they help to alleviate the effects of congestion for critical services. A third method to avoid network congestion is the explicit allocation of network resources to specific flows. One example of this is the use of Contention-Free Transmission Opportunities (CFTXOPs) in the ITU-T G.hn home networking standard. For the Internet, RFC 2914 addresses the subject of congestion control in detail. === Network resilience === Network resilience is "the ability to provide and maintain an acceptable level of service in the face of faults and challenges to normal operation." == Security == Computer networks are also used by security hackers to deploy computer viruses or computer worms on devices connected to the network, or to prevent these devices from accessing the network via a denial-of-service attack. === Network security === Network Security consists of provisions and policies adopted by the network administrator to prevent and monitor unauthorized access, misuse, modification, or denial of the computer network and its network-accessible resources. Network security is used on a variety of computer networks, both public and private, to secure daily transactions and communications among businesses, government agencies, and individuals. === Network surveillance === Network surveillance is the monitoring of data being transferred over computer networks such as the Internet. The monitoring is often done surreptitiously and may be done by or at the behest of governments, by corporations, criminal organizations, or individuals. It may or may not be legal and may or may not require authorization from a court or other independent agency. Computer and network surveillance programs are widespread today, and almost all Internet traffic is or could potentially be monitored for clues to illegal activity. Surveillance is very useful to governments and law enforcement to maintain social control, recognize and monitor threats, and prevent or investigate criminal activity. With the advent of programs such as the Total Information Awareness program, technologies such as high-speed surveillance computers and biometrics software, and laws such as the Communications Assistance For Law Enforcement Act, governments now possess an unprecedented ability to monitor the activities of citizens. However, many civil rights and privacy groups—such as Reporters Without Borders, the Electronic Frontier Foundation, and the American Civil Liberties Union—have expressed concern that increasing surveillance of citizens may lead to a mass surveillance society, with limited political and personal freedoms. Fears such as this have led to lawsuits such as Hepting v. AT&T. The hacktivist group Anonymous has hacked into government websites in protest of what it considers "draconian surveillance". === End to end encryption === End-to-end encryption (E2EE) is a digital communications paradigm of uninterrupted protection of data traveling between two communicating parties. It involves the originating party encrypting data so only the intended recipient can decrypt it, with no dependency on third parties. End-to-end encryption prevents intermediaries, such as Internet service providers or application service providers, from reading or tampering with communications. End-to-end encryption generally protects both confidentiality and integrity. Examples of end-to-end encryption include HTTPS for web traffic, PGP for email, OTR for instant messaging, ZRTP for telephony, and TETRA for radio. Typical server-based communications systems do not include end-to-end encryption. These systems can only guarantee the protection of communications between clients and servers, not between the communicating parties themselves. Examples of non-E2EE systems are Google Talk, Yahoo Messenger, Facebook, and Dropbox. The end-to-end encryption paradigm does not directly address risks at the endpoints of the communication themselves, such as the technical exploitation of clients, poor quality random number generators, or key escrow. E2EE also does not address traffic analysis, which relates to things such as the identities of the endpoints and the times and quantities of messages that are sent. === SSL/TLS === The introduction and rapid growth of e-commerce on the World Wide Web in the mid-1990s made it obvious that some form of authentication and encryption was needed. Netscape took the first shot at a new standard. At the time, the dominant web browser was Netscape Navigator. Netscape created a standard called secure socket layer (SSL). SSL requires a server with a certificate. When a client requests access to an SSL-secured server, the server sends a copy of the certificate to the client. The SSL client checks this certificate (all web browsers come with an exhaustive list of root certificates preloaded), and if the certificate checks out, the server is authenticated and the client negotiates a symmetric-key cipher for use in the session. The session is now in a very secure encrypted tunnel between the SSL server and the SSL client. == Views of networks == Users and network administrators typically have different views of their networks. Users can share printers and some servers from a workgroup, which usually means they are in the same geographic location and are on the same LAN, whereas a network administrator is responsible for keeping that network up and running. A community of interest has less of a connection of being in a local area and should be thought of as a set of arbitrarily located users who share a set of servers, and possibly also communicate via peer-to-peer technologies. Network administrators can see networks from both physical and logical perspectives. The physical perspective involves geographic locations, physical cabling, and the network elements (e.g., routers, bridges and application-layer gateways) that interconnect via the transmission media. Logical networks, called, in the TCP/IP architecture, subnets, map onto one or more transmission media. For example, a common practice in a campus of buildings is to make a set of LAN cables in each building appear to be a common subnet, using VLANs. Users and administrators are aware, to varying extents, of a network's trust and scope characteristics. Again using TCP/IP architectural terminology, an intranet is a community of interest under private administration usually by an enterprise, and is only accessible by authorized users (e.g. employees). Intranets do not have to be connected to the Internet, but generally have a limited connection. An extranet is an extension of an intranet that allows secure communications to users outside of the intranet (e.g. business partners, customers). Unofficially, the Internet is the set of users, enterprises, and content providers that are interconnected by Internet Service Providers (ISP). From an engineering viewpoint, the Internet is the set of subnets, and aggregates of subnets, that share the registered IP address space and exchange information about the reachability of those IP addresses using the Border Gateway Protocol. Typically, the human-readable names of servers are translated to IP addresses, transparently to users, via the directory function of the Domain Name System (DNS). Over the Internet, there can be business-to-business, business-to-consumer and consumer-to-consumer communications. When money or sensitive information is exchanged, the communications are apt to be protected by some form of communications security mechanism. Intranets and extranets can be securely superimposed onto the Internet, without any access by general Internet users and administrators, using secure VPN technology. == See also == == References == This article incorporates public domain material from Federal Standard 1037C. General Services Administration. Archived from the original on 2022-01-22. == Further reading == Kurose James F and Keith W. Ross: Computer Networking: A Top-Down Approach Featuring the Internet, Pearson Education 2005. William Stallings, Computer Networking with Internet Protocols and Technology, Pearson Education 2004. Dimitri Bertsekas, and Robert Gallager, "Data Networks," Prentice Hall, 1992.
Wikipedia/Computer_network
In mathematical logic, minimal axioms for Boolean algebra are assumptions which are equivalent to the axioms of Boolean algebra (or propositional calculus), chosen to be as short as possible. For example, an axiom with six NAND operations and three variables is equivalent to Boolean algebra: ( ( a ∣ b ) ∣ c ) ∣ ( a ∣ ( ( a ∣ c ) ∣ a ) ) = c {\displaystyle ((a\mid b)\mid c)\mid (a\mid ((a\mid c)\mid a))=c} where the vertical bar represents the NAND logical operation (also known as the Sheffer stroke). It is one of 25 candidate axioms for this property identified by Stephen Wolfram, by enumerating the Sheffer identities of length less or equal to 15 elements (excluding mirror images) that have no noncommutative models with four or fewer variables, and was first proven equivalent by William McCune, Branden Fitelson, and Larry Wos. MathWorld, a site associated with Wolfram, has named the axiom the "Wolfram axiom". McCune et al. also found a longer single axiom for Boolean algebra based on disjunction and negation. In 1933, Edward Vermilye Huntington identified the axiom ¬ ( ¬ x ∨ y ) ∨ ¬ ( ¬ x ∨ ¬ y ) = x {\displaystyle {\neg ({\neg x}\lor {y})}\lor {\neg ({\neg x}\lor {\neg y})}=x} as being equivalent to Boolean algebra, when combined with the commutativity of the OR operation, x ∨ y = y ∨ x {\displaystyle x\lor y=y\lor x} , and the assumption of associativity, ( x ∨ y ) ∨ z = x ∨ ( y ∨ z ) {\displaystyle (x\lor y)\lor z=x\lor (y\lor z)} . Herbert Robbins conjectured that Huntington's axiom could be replaced by ¬ ( ¬ ( x ∨ y ) ∨ ¬ ( x ∨ ¬ y ) ) = x , {\displaystyle \neg (\neg (x\lor y)\lor \neg (x\lor {\neg y}))=x,} which requires one fewer use of the logical negation operator ¬ {\displaystyle \neg } . Neither Robbins nor Huntington could prove this conjecture; nor could Alfred Tarski, who took considerable interest in it later. The conjecture was eventually proved in 1996 with the aid of theorem-proving software. This proof established that the Robbins axiom, together with associativity and commutativity, form a 3-basis for Boolean algebra. The existence of a 2-basis was established in 1967 by Carew Arthur Meredith: ¬ ( ¬ x ∨ y ) ∨ x = x , {\displaystyle \neg ({\neg x}\lor y)\lor x=x,} ¬ ( ¬ x ∨ y ) ∨ ( z ∨ y ) = y ∨ ( z ∨ x ) . {\displaystyle \neg ({\neg x}\lor y)\lor (z\lor y)=y\lor (z\lor x).} The following year, Meredith found a 2-basis in terms of the Sheffer stroke: ( x ∣ x ) ∣ ( y ∣ x ) = x , {\displaystyle (x\mid x)\mid (y\mid x)=x,} x | ( y ∣ ( x ∣ z ) ) = ( ( z ∣ y ) ∣ y ) ∣ x . {\displaystyle x|(y\mid (x\mid z))=((z\mid y)\mid y)\mid x.} In 1973, Padmanabhan and Quackenbush demonstrated a method that, in principle, would yield a 1-basis for Boolean algebra. Applying this method in a straightforward manner yielded "axioms of enormous length", thereby prompting the question of how shorter axioms might be found. This search yielded the 1-basis in terms of the Sheffer stroke given above, as well as the 1-basis ¬ ( ¬ ( ¬ ( x ∨ y ) ∨ z ) ∨ ¬ ( x ∨ ¬ ( ¬ z ∨ ¬ ( z ∨ u ) ) ) ) = z , {\displaystyle \neg (\neg (\neg (x\lor y)\lor z)\lor \neg (x\lor \neg (\neg z\lor \neg (z\lor u))))=z,} which is written in terms of OR and NOT. == References ==
Wikipedia/Minimal_axioms_for_Boolean_algebra
Computability theory, also known as recursion theory, is a branch of mathematical logic, computer science, and the theory of computation that originated in the 1930s with the study of computable functions and Turing degrees. The field has since expanded to include the study of generalized computability and definability. In these areas, computability theory overlaps with proof theory and effective descriptive set theory. Basic questions addressed by computability theory include: What does it mean for a function on the natural numbers to be computable? How can noncomputable functions be classified into a hierarchy based on their level of noncomputability? Although there is considerable overlap in terms of knowledge and methods, mathematical computability theorists study the theory of relative computability, reducibility notions, and degree structures; those in the computer science field focus on the theory of subrecursive hierarchies, formal methods, and formal languages. The study of which mathematical constructions can be effectively performed is sometimes called recursive mathematics. == Introduction == Computability theory originated in the 1930s, with the work of Kurt Gödel, Alonzo Church, Rózsa Péter, Alan Turing, Stephen Kleene, and Emil Post. The fundamental results the researchers obtained established Turing computability as the correct formalization of the informal idea of effective calculation. In 1952, these results led Kleene to coin the two names "Church's thesis": 300  and "Turing's thesis".: 376  Nowadays these are often considered as a single hypothesis, the Church–Turing thesis, which states that any function that is computable by an algorithm is a computable function. Although initially skeptical, by 1946 Gödel argued in favor of this thesis:: 84  "Tarski has stressed in his lecture (and I think justly) the great importance of the concept of general recursiveness (or Turing's computability). It seems to me that this importance is largely due to the fact that with this concept one has for the first time succeeded in giving an absolute notion to an interesting epistemological notion, i.e., one not depending on the formalism chosen.": 84  With a definition of effective calculation came the first proofs that there are problems in mathematics that cannot be effectively decided. In 1936, Church and Turing were inspired by techniques used by Gödel to prove his incompleteness theorems - in 1931, Gödel independently demonstrated that the Entscheidungsproblem is not effectively decidable. This result showed that there is no algorithmic procedure that can correctly decide whether arbitrary mathematical propositions are true or false. Many problems in mathematics have been shown to be undecidable after these initial examples were established. In 1947, Markov and Post published independent papers showing that the word problem for semigroups cannot be effectively decided. Extending this result, Pyotr Novikov and William Boone showed independently in the 1950s that the word problem for groups is not effectively solvable: there is no effective procedure that, given a word in a finitely presented group, will decide whether the element represented by the word is the identity element of the group. In 1970, Yuri Matiyasevich proved (using results of Julia Robinson) Matiyasevich's theorem, which implies that Hilbert's tenth problem has no effective solution; this problem asked whether there is an effective procedure to decide whether a Diophantine equation over the integers has a solution in the integers. == Turing computability == The main form of computability studied in the field was introduced by Turing in 1936. A set of natural numbers is said to be a computable set (also called a decidable, recursive, or Turing computable set) if there is a Turing machine that, given a number n, halts with output 1 if n is in the set and halts with output 0 if n is not in the set. A function f from natural numbers to natural numbers is a (Turing) computable, or recursive function if there is a Turing machine that, on input n, halts and returns output f(n). The use of Turing machines here is not necessary; there are many other models of computation that have the same computing power as Turing machines; for example the μ-recursive functions obtained from primitive recursion and the μ operator. The terminology for computable functions and sets is not completely standardized. The definition in terms of μ-recursive functions as well as a different definition of rekursiv functions by Gödel led to the traditional name recursive for sets and functions computable by a Turing machine. The word decidable stems from the German word Entscheidungsproblem which was used in the original papers of Turing and others. In contemporary use, the term "computable function" has various definitions: according to Nigel J. Cutland, it is a partial recursive function (which can be undefined for some inputs), while according to Robert I. Soare it is a total recursive (equivalently, general recursive) function. This article follows the second of these conventions. In 1996, Soare gave additional comments about the terminology. Not every set of natural numbers is computable. The halting problem, which is the set of (descriptions of) Turing machines that halt on input 0, is a well-known example of a noncomputable set. The existence of many noncomputable sets follows from the facts that there are only countably many Turing machines, and thus only countably many computable sets, but according to the Cantor's theorem, there are uncountably many sets of natural numbers. Although the halting problem is not computable, it is possible to simulate program execution and produce an infinite list of the programs that do halt. Thus the halting problem is an example of a computably enumerable (c.e.) set, which is a set that can be enumerated by a Turing machine (other terms for computably enumerable include recursively enumerable and semidecidable). Equivalently, a set is c.e. if and only if it is the range of some computable function. The c.e. sets, although not decidable in general, have been studied in detail in computability theory. == Areas of research == Beginning with the theory of computable sets and functions described above, the field of computability theory has grown to include the study of many closely related topics. These are not independent areas of research: each of these areas draws ideas and results from the others, and most computability theorists are familiar with the majority of them. === Relative computability and the Turing degrees === Computability theory in mathematical logic has traditionally focused on relative computability, a generalization of Turing computability defined using oracle Turing machines, introduced by Turing in 1939. An oracle Turing machine is a hypothetical device which, in addition to performing the actions of a regular Turing machine, is able to ask questions of an oracle, which is a particular set of natural numbers. The oracle machine may only ask questions of the form "Is n in the oracle set?". Each question will be immediately answered correctly, even if the oracle set is not computable. Thus an oracle machine with a noncomputable oracle will be able to compute sets that a Turing machine without an oracle cannot. Informally, a set of natural numbers A is Turing reducible to a set B if there is an oracle machine that correctly tells whether numbers are in A when run with B as the oracle set (in this case, the set A is also said to be (relatively) computable from B and recursive in B). If a set A is Turing reducible to a set B and B is Turing reducible to A then the sets are said to have the same Turing degree (also called degree of unsolvability). The Turing degree of a set gives a precise measure of how uncomputable the set is. The natural examples of sets that are not computable, including many different sets that encode variants of the halting problem, have two properties in common: They are computably enumerable, and Each can be translated into any other via a many-one reduction. That is, given such sets A and B, there is a total computable function f such that A = {x : f(x) ∈ B}. These sets are said to be many-one equivalent (or m-equivalent). Many-one reductions are "stronger" than Turing reductions: if a set A is many-one reducible to a set B, then A is Turing reducible to B, but the converse does not always hold. Although the natural examples of noncomputable sets are all many-one equivalent, it is possible to construct computably enumerable sets A and B such that A is Turing reducible to B but not many-one reducible to B. It can be shown that every computably enumerable set is many-one reducible to the halting problem, and thus the halting problem is the most complicated computably enumerable set with respect to many-one reducibility and with respect to Turing reducibility. In 1944, Post asked whether every computably enumerable set is either computable or Turing equivalent to the halting problem, that is, whether there is no computably enumerable set with a Turing degree intermediate between those two. As intermediate results, Post defined natural types of computably enumerable sets like the simple, hypersimple and hyperhypersimple sets. Post showed that these sets are strictly between the computable sets and the halting problem with respect to many-one reducibility. Post also showed that some of them are strictly intermediate under other reducibility notions stronger than Turing reducibility. But Post left open the main problem of the existence of computably enumerable sets of intermediate Turing degree; this problem became known as Post's problem. After ten years, Kleene and Post showed in 1954 that there are intermediate Turing degrees between those of the computable sets and the halting problem, but they failed to show that any of these degrees contains a computably enumerable set. Very soon after this, Friedberg and Muchnik independently solved Post's problem by establishing the existence of computably enumerable sets of intermediate degree. This groundbreaking result opened a wide study of the Turing degrees of the computably enumerable sets which turned out to possess a very complicated and non-trivial structure. There are uncountably many sets that are not computably enumerable, and the investigation of the Turing degrees of all sets is as central in computability theory as the investigation of the computably enumerable Turing degrees. Many degrees with special properties were constructed: hyperimmune-free degrees where every function computable relative to that degree is majorized by a (unrelativized) computable function; high degrees relative to which one can compute a function f which dominates every computable function g in the sense that there is a constant c depending on g such that g(x) < f(x) for all x > c; random degrees containing algorithmically random sets; 1-generic degrees of 1-generic sets; and the degrees below the halting problem of limit-computable sets. The study of arbitrary (not necessarily computably enumerable) Turing degrees involves the study of the Turing jump. Given a set A, the Turing jump of A is a set of natural numbers encoding a solution to the halting problem for oracle Turing machines running with oracle A. The Turing jump of any set is always of higher Turing degree than the original set, and a theorem of Friedburg shows that any set that computes the Halting problem can be obtained as the Turing jump of another set. Post's theorem establishes a close relationship between the Turing jump operation and the arithmetical hierarchy, which is a classification of certain subsets of the natural numbers based on their definability in arithmetic. Much recent research on Turing degrees has focused on the overall structure of the set of Turing degrees and the set of Turing degrees containing computably enumerable sets. A deep theorem of Shore and Slaman states that the function mapping a degree x to the degree of its Turing jump is definable in the partial order of the Turing degrees. A survey by Ambos-Spies and Fejer gives an overview of this research and its historical progression. === Other reducibilities === An ongoing area of research in computability theory studies reducibility relations other than Turing reducibility. Post introduced several strong reducibilities, so named because they imply truth-table reducibility. A Turing machine implementing a strong reducibility will compute a total function regardless of which oracle it is presented with. Weak reducibilities are those where a reduction process may not terminate for all oracles; Turing reducibility is one example. The strong reducibilities include: One-one reducibility: A is one-one reducible (or 1-reducible) to B if there is a total computable injective function f such that each n is in A if and only if f(n) is in B. Many-one reducibility: This is essentially one-one reducibility without the constraint that f be injective. A is many-one reducible (or m-reducible) to B if there is a total computable function f such that each n is in A if and only if f(n) is in B. Truth-table reducibility: A is truth-table reducible to B if A is Turing reducible to B via an oracle Turing machine that computes a total function regardless of the oracle it is given. Because of compactness of Cantor space, this is equivalent to saying that the reduction presents a single list of questions (depending only on the input) to the oracle simultaneously, and then having seen their answers is able to produce an output without asking additional questions regardless of the oracle's answer to the initial queries. Many variants of truth-table reducibility have also been studied. Further reducibilities (positive, disjunctive, conjunctive, linear and their weak and bounded versions) are discussed in the article Reduction (computability theory). The major research on strong reducibilities has been to compare their theories, both for the class of all computably enumerable sets as well as for the class of all subsets of the natural numbers. Furthermore, the relations between the reducibilities has been studied. For example, it is known that every Turing degree is either a truth-table degree or is the union of infinitely many truth-table degrees. Reducibilities weaker than Turing reducibility (that is, reducibilities that are implied by Turing reducibility) have also been studied. The most well known are arithmetical reducibility and hyperarithmetical reducibility. These reducibilities are closely connected to definability over the standard model of arithmetic. === Rice's theorem and the arithmetical hierarchy === Rice showed that for every nontrivial class C (which contains some but not all c.e. sets) the index set E = {e: the eth c.e. set We is in C} has the property that either the halting problem or its complement is many-one reducible to E, that is, can be mapped using a many-one reduction to E (see Rice's theorem for more detail). But, many of these index sets are even more complicated than the halting problem. These type of sets can be classified using the arithmetical hierarchy. For example, the index set FIN of the class of all finite sets is on the level Σ2, the index set REC of the class of all recursive sets is on the level Σ3, the index set COFIN of all cofinite sets is also on the level Σ3 and the index set COMP of the class of all Turing-complete sets Σ4. These hierarchy levels are defined inductively, Σn+1 contains just all sets which are computably enumerable relative to Σn; Σ1 contains the computably enumerable sets. The index sets given here are even complete for their levels, that is, all the sets in these levels can be many-one reduced to the given index sets. === Reverse mathematics === The program of reverse mathematics asks which set-existence axioms are necessary to prove particular theorems of mathematics in subsystems of second-order arithmetic. This study was initiated by Harvey Friedman and was studied in detail by Stephen Simpson and others; in 1999, Simpson gave a detailed discussion of the program. The set-existence axioms in question correspond informally to axioms saying that the powerset of the natural numbers is closed under various reducibility notions. The weakest such axiom studied in reverse mathematics is recursive comprehension, which states that the powerset of the naturals is closed under Turing reducibility. === Numberings === A numbering is an enumeration of functions; it has two parameters, e and x and outputs the value of the e-th function in the numbering on the input x. Numberings can be partial-computable although some of its members are total computable functions. Admissible numberings are those into which all others can be translated. A Friedberg numbering (named after its discoverer) is a one-one numbering of all partial-computable functions; it is necessarily not an admissible numbering. Later research dealt also with numberings of other classes like classes of computably enumerable sets. Goncharov discovered for example a class of computably enumerable sets for which the numberings fall into exactly two classes with respect to computable isomorphisms. === The priority method === Post's problem was solved with a method called the priority method; a proof using this method is called a priority argument. This method is primarily used to construct computably enumerable sets with particular properties. To use this method, the desired properties of the set to be constructed are broken up into an infinite list of goals, known as requirements, so that satisfying all the requirements will cause the set constructed to have the desired properties. Each requirement is assigned to a natural number representing the priority of the requirement; so 0 is assigned to the most important priority, 1 to the second most important, and so on. The set is then constructed in stages, each stage attempting to satisfy one of more of the requirements by either adding numbers to the set or banning numbers from the set so that the final set will satisfy the requirement. It may happen that satisfying one requirement will cause another to become unsatisfied; the priority order is used to decide what to do in such an event. Priority arguments have been employed to solve many problems in computability theory, and have been classified into a hierarchy based on their complexity. Because complex priority arguments can be technical and difficult to follow, it has traditionally been considered desirable to prove results without priority arguments, or to see if results proved with priority arguments can also be proved without them. For example, Kummer published a paper on a proof for the existence of Friedberg numberings without using the priority method. === The lattice of computably enumerable sets === When Post defined the notion of a simple set as a c.e. set with an infinite complement not containing any infinite c.e. set, he started to study the structure of the computably enumerable sets under inclusion. This lattice became a well-studied structure. Computable sets can be defined in this structure by the basic result that a set is computable if and only if the set and its complement are both computably enumerable. Infinite c.e. sets have always infinite computable subsets; but on the other hand, simple sets exist but do not always have a coinfinite computable superset. Post introduced already hypersimple and hyperhypersimple sets; later maximal sets were constructed which are c.e. sets such that every c.e. superset is either a finite variant of the given maximal set or is co-finite. Post's original motivation in the study of this lattice was to find a structural notion such that every set which satisfies this property is neither in the Turing degree of the computable sets nor in the Turing degree of the halting problem. Post did not find such a property and the solution to his problem applied priority methods instead; in 1991, Harrington and Soare found eventually such a property. === Automorphism problems === Another important question is the existence of automorphisms in computability-theoretic structures. One of these structures is that one of computably enumerable sets under inclusion modulo finite difference; in this structure, A is below B if and only if the set difference B − A is finite. Maximal sets (as defined in the previous paragraph) have the property that they cannot be automorphic to non-maximal sets, that is, if there is an automorphism of the computably enumerable sets under the structure just mentioned, then every maximal set is mapped to another maximal set. In 1974, Soare showed that also the converse holds, that is, every two maximal sets are automorphic. So the maximal sets form an orbit, that is, every automorphism preserves maximality and any two maximal sets are transformed into each other by some automorphism. Harrington gave a further example of an automorphic property: that of the creative sets, the sets which are many-one equivalent to the halting problem. Besides the lattice of computably enumerable sets, automorphisms are also studied for the structure of the Turing degrees of all sets as well as for the structure of the Turing degrees of c.e. sets. In both cases, Cooper claims to have constructed nontrivial automorphisms which map some degrees to other degrees; this construction has, however, not been verified and some colleagues believe that the construction contains errors and that the question of whether there is a nontrivial automorphism of the Turing degrees is still one of the main unsolved questions in this area. === Kolmogorov complexity === The field of Kolmogorov complexity and algorithmic randomness was developed during the 1960s and 1970s by Chaitin, Kolmogorov, Levin, Martin-Löf and Solomonoff (the names are given here in alphabetical order; much of the research was independent, and the unity of the concept of randomness was not understood at the time). The main idea is to consider a universal Turing machine U and to measure the complexity of a number (or string) x as the length of the shortest input p such that U(p) outputs x. This approach revolutionized earlier ways to determine when an infinite sequence (equivalently, characteristic function of a subset of the natural numbers) is random or not by invoking a notion of randomness for finite objects. Kolmogorov complexity became not only a subject of independent study but is also applied to other subjects as a tool for obtaining proofs. There are still many open problems in this area. === Frequency computation === This branch of computability theory analyzed the following question: For fixed m and n with 0 < m < n, for which functions A is it possible to compute for any different n inputs x1, x2, ..., xn a tuple of n numbers y1, y2, ..., yn such that at least m of the equations A(xk) = yk are true. Such sets are known as (m, n)-recursive sets. The first major result in this branch of computability theory is Trakhtenbrot's result that a set is computable if it is (m, n)-recursive for some m, n with 2m > n. On the other hand, Jockusch's semirecursive sets (which were already known informally before Jockusch introduced them 1968) are examples of a set which is (m, n)-recursive if and only if 2m < n + 1. There are uncountably many of these sets and also some computably enumerable but noncomputable sets of this type. Later, Degtev established a hierarchy of computably enumerable sets that are (1, n + 1)-recursive but not (1, n)-recursive. After a long phase of research by Russian scientists, this subject became repopularized in the west by Beigel's thesis on bounded queries, which linked frequency computation to the above-mentioned bounded reducibilities and other related notions. One of the major results was Kummer's Cardinality Theory which states that a set A is computable if and only if there is an n such that some algorithm enumerates for each tuple of n different numbers up to n many possible choices of the cardinality of this set of n numbers intersected with A; these choices must contain the true cardinality but leave out at least one false one. === Inductive inference === This is the computability-theoretic branch of learning theory. It is based on E. Mark Gold's model of learning in the limit from 1967 and has developed since then more and more models of learning. The general scenario is the following: Given a class S of computable functions, is there a learner (that is, computable functional) which outputs for any input of the form (f(0), f(1), ..., f(n)) a hypothesis. A learner M learns a function f if almost all hypotheses are the same index e of f with respect to a previously agreed on acceptable numbering of all computable functions; M learns S if M learns every f in S. Basic results are that all computably enumerable classes of functions are learnable while the class REC of all computable functions is not learnable. Many related models have been considered and also the learning of classes of computably enumerable sets from positive data is a topic studied from Gold's pioneering paper in 1967 onwards. === Generalizations of Turing computability === Computability theory includes the study of generalized notions of this field such as arithmetic reducibility, hyperarithmetical reducibility and α-recursion theory, as described by Sacks in 1990. These generalized notions include reducibilities that cannot be executed by Turing machines but are nevertheless natural generalizations of Turing reducibility. These studies include approaches to investigate the analytical hierarchy which differs from the arithmetical hierarchy by permitting quantification over sets of natural numbers in addition to quantification over individual numbers. These areas are linked to the theories of well-orderings and trees; for example the set of all indices of computable (nonbinary) trees without infinite branches is complete for level Π 1 1 {\displaystyle \Pi _{1}^{1}} of the analytical hierarchy. Both Turing reducibility and hyperarithmetical reducibility are important in the field of effective descriptive set theory. The even more general notion of degrees of constructibility is studied in set theory. === Continuous computability theory === Computability theory for digital computation is well developed. Computability theory is less well developed for analog computation that occurs in analog computers, analog signal processing, analog electronics, artificial neural networks and continuous-time control theory, modelled by differential equations and continuous dynamical systems. For example, models of computation such as the Blum–Shub–Smale machine model have formalized computation on the reals. == Relationships between definability, proof and computability == There are close relationships between the Turing degree of a set of natural numbers and the difficulty (in terms of the arithmetical hierarchy) of defining that set using a first-order formula. One such relationship is made precise by Post's theorem. A weaker relationship was demonstrated by Kurt Gödel in the proofs of his completeness theorem and incompleteness theorems. Gödel's proofs show that the set of logical consequences of an effective first-order theory is a computably enumerable set, and that if the theory is strong enough this set will be uncomputable. Similarly, Tarski's indefinability theorem can be interpreted both in terms of definability and in terms of computability. Computability theory is also linked to second-order arithmetic, a formal theory of natural numbers and sets of natural numbers. The fact that certain sets are computable or relatively computable often implies that these sets can be defined in weak subsystems of second-order arithmetic. The program of reverse mathematics uses these subsystems to measure the non-computability inherent in well known mathematical theorems. In 1999, Simpson discussed many aspects of second-order arithmetic and reverse mathematics. The field of proof theory includes the study of second-order arithmetic and Peano arithmetic, as well as formal theories of the natural numbers weaker than Peano arithmetic. One method of classifying the strength of these weak systems is by characterizing which computable functions the system can prove to be total. For example, in primitive recursive arithmetic any computable function that is provably total is actually primitive recursive, while Peano arithmetic proves that functions like the Ackermann function, which are not primitive recursive, are total. Not every total computable function is provably total in Peano arithmetic, however; an example of such a function is provided by Goodstein's theorem. == Name == The field of mathematical logic dealing with computability and its generalizations has been called "recursion theory" since its early days. Robert I. Soare, a prominent researcher in the field, has proposed that the field should be called "computability theory" instead. He argues that Turing's terminology using the word "computable" is more natural and more widely understood than the terminology using the word "recursive" introduced by Kleene. Many contemporary researchers have begun to use this alternate terminology. These researchers also use terminology such as partial computable function and computably enumerable (c.e.) set instead of partial recursive function and recursively enumerable (r.e.) set. Not all researchers have been convinced, however, as explained by Fortnow and Simpson. Some commentators argue that both the names recursion theory and computability theory fail to convey the fact that most of the objects studied in computability theory are not computable. In 1967, Rogers has suggested that a key property of computability theory is that its results and structures should be invariant under computable bijections on the natural numbers (this suggestion draws on the ideas of the Erlangen program in geometry). The idea is that a computable bijection merely renames numbers in a set, rather than indicating any structure in the set, much as a rotation of the Euclidean plane does not change any geometric aspect of lines drawn on it. Since any two infinite computable sets are linked by a computable bijection, this proposal identifies all the infinite computable sets (the finite computable sets are viewed as trivial). According to Rogers, the sets of interest in computability theory are the noncomputable sets, partitioned into equivalence classes by computable bijections of the natural numbers. == Professional organizations == The main professional organization for computability theory is the Association for Symbolic Logic, which holds several research conferences each year. The interdisciplinary research Association Computability in Europe (CiE) also organizes a series of annual conferences. == See also == Recursion (computer science) Computability logic Transcomputational problem == Notes == == References == == Further reading == Undergraduate level texts Cooper, S. Barry (2004). Computability Theory. Chapman & Hall/CRC. ISBN 1-58488-237-9. Matiyasevich, Yuri Vladimirovich (1993). Hilbert's Tenth Problem. MIT Press. ISBN 0-262-13295-8. Advanced texts Jain, Sanjay; Osherson, Daniel Nathan; Royer, James S.; Sharma, Arun (1999). Systems that learn: an introduction to learning theory (2nd ed.). Bradford Book / MIT Press. ISBN 0-262-10077-0. LCCN 98-34861. Lerman, Manuel (1983). Degrees of unsolvability. Perspectives in Mathematical Logic. Springer-Verlag. ISBN 3-540-12155-2. Nies, André (2009). Computability and Randomness. Oxford University Press. ISBN 978-0-19-923076-1. Odifreddi, Piergiorgio (1989). Classical Recursion Theory. North-Holland. ISBN 0-444-87295-7. Odifreddi, Piergiorgio (1999). Classical Recursion Theory. Vol. II. Elsevier. ISBN 0-444-50205-X. Survey papers and collections Enderton, Herbert Bruce (1977). "Elements of Recursion Theory". In Barwise, Jon (ed.). Handbook of Mathematical Logic. North-Holland. pp. 527–566. ISBN 0-7204-2285-X. Research papers and collections Burgin, Mark; Klinger, Allen (2004). "Experience, Generations, and Limits in Machine Learning". Theoretical Computer Science. 317 (1–3): 71–91. doi:10.1016/j.tcs.2003.12.005. Friedberg, Richard M. (1958). "Three theorems on recursive enumeration: I. Decomposition, II. Maximal Set, III. Enumeration without repetition". The Journal of Symbolic Logic. 23 (3): 309–316. doi:10.2307/2964290. JSTOR 2964290. S2CID 25834814. Gold, E. Mark (1967). "Language Identification in the Limit" (PDF). Information and Control. 10 (5): 447–474. doi:10.1016/s0019-9958(67)91165-5. [1] Jockusch, Carl Groos Jr. (1968). "Semirecursive sets and positive reducibility". Transactions of the American Mathematical Society. 137 (2): 420–436. doi:10.1090/S0002-9947-1968-0220595-7. JSTOR 1994957. Kleene, Stephen Cole; Post, Emil Leon (1954). "The upper semi-lattice of degrees of recursive unsolvability". Annals of Mathematics. Series 2. 59 (3): 379–407. doi:10.2307/1969708. JSTOR 1969708. Myhill, John R. Sr. (1956). "The lattice of recursively enumerable sets". The Journal of Symbolic Logic. 21: 215–220. doi:10.1017/S002248120008525X. S2CID 123260425. Post, Emil Leon (1947). "Recursive unsolvability of a problem of Thue". Journal of Symbolic Logic. 12 (1): 1–11. doi:10.2307/2267170. JSTOR 2267170. S2CID 30320278. Reprinted in Davis 1965. == External links == Association for Symbolic Logic homepage Computability in Europe homepage Archived 2011-02-17 at the Wayback Machine Webpage on Recursion Theory Course at Graduate Level with approximately 100 pages of lecture notes German language lecture notes on inductive inference
Wikipedia/Computability_theory
In logic, the monadic predicate calculus (also called monadic first-order logic) is the fragment of first-order logic in which all relation symbols in the signature are monadic (that is, they take only one argument), and there are no function symbols. All atomic formulas are thus of the form P ( x ) {\displaystyle P(x)} , where P {\displaystyle P} is a relation symbol and x {\displaystyle x} is a variable. Monadic predicate calculus can be contrasted with polyadic predicate calculus, which allows relation symbols that take two or more arguments. == Expressiveness == The absence of polyadic relation symbols severely restricts what can be expressed in the monadic predicate calculus. It is so weak that, unlike the full predicate calculus, it is decidable—there is a decision procedure that determines whether a given formula of monadic predicate calculus is logically valid (true for all nonempty domains). Adding a single binary relation symbol to monadic logic, however, results in an undecidable logic. == Relationship with term logic == The need to go beyond monadic logic was not appreciated until the work on the logic of relations, by Augustus De Morgan and Charles Sanders Peirce in the nineteenth century, and by Frege in his 1879 Begriffsschrift. Prior to the work of these three, term logic (syllogistic logic) was widely considered adequate for formal deductive reasoning. Inferences in term logic can all be represented in the monadic predicate calculus. For example the argument All dogs are mammals. No mammal is a bird. Thus, no dog is a bird. can be notated in the language of monadic predicate calculus as [ ( ∀ x D ( x ) ⇒ M ( x ) ) ∧ ¬ ( ∃ y M ( y ) ∧ B ( y ) ) ] ⇒ ¬ ( ∃ z D ( z ) ∧ B ( z ) ) {\displaystyle [(\forall x\,D(x)\Rightarrow M(x))\land \neg (\exists y\,M(y)\land B(y))]\Rightarrow \neg (\exists z\,D(z)\land B(z))} where D {\displaystyle D} , M {\displaystyle M} and B {\displaystyle B} denote the predicates of being, respectively, a dog, a mammal, and a bird. Conversely, monadic predicate calculus is not significantly more expressive than term logic. Each formula in the monadic predicate calculus is equivalent to a formula in which quantifiers appear only in closed subformulas of the form ∀ x P 1 ( x ) ∨ ⋯ ∨ P n ( x ) ∨ ¬ P 1 ′ ( x ) ∨ ⋯ ∨ ¬ P m ′ ( x ) {\displaystyle \forall x\,P_{1}(x)\lor \cdots \lor P_{n}(x)\lor \neg P'_{1}(x)\lor \cdots \lor \neg P'_{m}(x)} or ∃ x ¬ P 1 ( x ) ∧ ⋯ ∧ ¬ P n ( x ) ∧ P 1 ′ ( x ) ∧ ⋯ ∧ P m ′ ( x ) , {\displaystyle \exists x\,\neg P_{1}(x)\land \cdots \land \neg P_{n}(x)\land P'_{1}(x)\land \cdots \land P'_{m}(x),} These formulas slightly generalize the basic judgements considered in term logic. For example, this form allows statements such as "Every mammal is either a herbivore or a carnivore (or both)", ( ∀ x ¬ M ( x ) ∨ H ( x ) ∨ C ( x ) ) {\displaystyle (\forall x\,\neg M(x)\lor H(x)\lor C(x))} . Reasoning about such statements can, however, still be handled within the framework of term logic, although not by the 19 classical Aristotelian syllogisms alone. Taking propositional logic as given, every formula in the monadic predicate calculus expresses something that can likewise be formulated in term logic. On the other hand, a modern view of the problem of multiple generality in traditional logic concludes that quantifiers cannot nest usefully if there are no polyadic predicates to relate the bound variables. == Variants == The formal system described above is sometimes called the pure monadic predicate calculus, where "pure" signifies the absence of function symbols. Allowing monadic function symbols changes the logic only superficially, whereas admitting even a single binary function symbol results in an undecidable logic. Monadic second-order logic allows predicates of higher arity in formulas, but restricts second-order quantification to unary predicates, i.e. the only second-order variables allowed are subset variables. == Footnotes ==
Wikipedia/Monadic_predicate_calculus
Computer graphics deals with generating images and art with the aid of computers. Computer graphics is a core technology in digital photography, film, video games, digital art, cell phone and computer displays, and many specialized applications. A great deal of specialized hardware and software has been developed, with the displays of most devices being driven by computer graphics hardware. It is a vast and recently developed area of computer science. The phrase was coined in 1960 by computer graphics researchers Verne Hudson and William Fetter of Boeing. It is often abbreviated as CG, or typically in the context of film as computer generated imagery (CGI). The non-artistic aspects of computer graphics are the subject of computer science research. Some topics in computer graphics include user interface design, sprite graphics, raster graphics, rendering, ray tracing, geometry processing, computer animation, vector graphics, 3D modeling, shaders, GPU design, implicit surfaces, visualization, scientific computing, image processing, computational photography, scientific visualization, computational geometry and computer vision, among others. The overall methodology depends heavily on the underlying sciences of geometry, optics, physics, and perception. Computer graphics is responsible for displaying art and image data effectively and meaningfully to the consumer. It is also used for processing image data received from the physical world, such as photo and video content. Computer graphics development has had a significant impact on many types of media and has revolutionized animation, movies, advertising, and video games, in general. == Overview == The term computer graphics has been used in a broad sense to describe "almost everything on computers that is not text or sound". Typically, the term computer graphics refers to several different things: the representation and manipulation of image data by a computer the various technologies used to create and manipulate images methods for digitally synthesizing and manipulating visual content, see study of computer graphics Today, computer graphics is widespread. Such imagery is found in and on television, newspapers, weather reports, and in a variety of medical investigations and surgical procedures. A well-constructed graph can present complex statistics in a form that is easier to understand and interpret. In the media "such graphs are used to illustrate papers, reports, theses", and other presentation material. Many tools have been developed to visualize data. Computer-generated imagery can be categorized into several different types: two dimensional (2D), three dimensional (3D), and animated graphics. As technology has improved, 3D computer graphics have become more common, but 2D computer graphics are still widely used. Computer graphics has emerged as a sub-field of computer science which studies methods for digitally synthesizing and manipulating visual content. Over the past decade, other specialized fields have been developed like information visualization, and scientific visualization more concerned with "the visualization of three dimensional phenomena (architectural, meteorological, medical, biological, etc.), where the emphasis is on realistic renderings of volumes, surfaces, illumination sources, and so forth, perhaps with a dynamic (time) component". == History == The precursor sciences to the development of modern computer graphics were the advances in electrical engineering, electronics, and television that took place during the first half of the twentieth century. Screens could display art since the Lumiere brothers' use of mattes to create special effects for the earliest films dating from 1895, but such displays were limited and not interactive. The first cathode ray tube, the Braun tube, was invented in 1897 – it in turn would permit the oscilloscope and the military control panel – the more direct precursors of the field, as they provided the first two-dimensional electronic displays that responded to programmatic or user input. Nevertheless, computer graphics remained relatively unknown as a discipline until the 1950s and the post-World War II period – during which time the discipline emerged from a combination of both pure university and laboratory academic research into more advanced computers and the United States military's further development of technologies like radar, aviation, and rocketry developed during the war. New kinds of displays were needed to process the wealth of information resulting from such projects, leading to the development of computer graphics as a discipline. === 1950s === Early projects like the Whirlwind and SAGE Projects introduced the CRT as a viable display and interaction interface and introduced the light pen as an input device. Douglas T. Ross of the Whirlwind SAGE system performed a personal experiment in which he wrote a small program that captured the movement of his finger and displayed its vector (his traced name) on a display scope. One of the first interactive video games to feature recognizable, interactive graphics – Tennis for Two – was created for an oscilloscope by William Higinbotham to entertain visitors in 1958 at Brookhaven National Laboratory and simulated a tennis match. In 1959, Douglas T. Ross, while working at MIT on transforming mathematic statements into computer generated 3D machine tool vectors, created a display scope image of a Disney cartoon character. Electronics pioneer Hewlett-Packard went public in 1957 after incorporating the decade prior, and established strong ties with Stanford University through its founders, who were alumni. This began the decades-long transformation of the southern San Francisco Bay Area into the world's leading computer technology hub – now known as Silicon Valley. The field of computer graphics developed with the emergence of computer graphics hardware. Further advances in computing led to greater advancements in interactive computer graphics. In 1959, the TX-2 computer was developed at MIT's Lincoln Laboratory. The TX-2 integrated a number of new man-machine interfaces. A light pen could be used to draw sketches on the computer using Ivan Sutherland's revolutionary Sketchpad software. Using a light pen, Sketchpad allowed one to draw simple shapes on the computer screen, save them and even recall them later. The light pen itself had a small photoelectric cell in its tip. This cell emitted an electronic pulse whenever it was placed in front of a computer screen and the screen's electron gun fired directly at it. By simply timing the electronic pulse with the current location of the electron gun, it was easy to pinpoint exactly where the pen was on the screen at any given moment. Once that was determined, the computer could then draw a cursor at that location. Sutherland seemed to find the perfect solution for many of the graphics problems he faced. Even today, many standards of computer graphics interfaces got their start with this early Sketchpad program. One example of this is in drawing constraints. If one wants to draw a square for example, they do not have to worry about drawing four lines perfectly to form the edges of the box. One can simply specify that they want to draw a box, and then specify the location and size of the box. The software will then construct a perfect box, with the right dimensions and at the right location. Another example is that Sutherland's software modeled objects – not just a picture of objects. In other words, with a model of a car, one could change the size of the tires without affecting the rest of the car. It could stretch the body of car without deforming the tires. === 1960s === The phrase "computer graphics" has been credited to William Fetter, a graphic designer for Boeing in 1960. Fetter in turn attributed it to Verne Hudson, also at Boeing. In 1961 another student at MIT, Steve Russell, created another important title in the history of video games, Spacewar! Written for the DEC PDP-1, Spacewar was an instant success and copies started flowing to other PDP-1 owners and eventually DEC got a copy. The engineers at DEC used it as a diagnostic program on every new PDP-1 before shipping it. The sales force picked up on this quickly enough and when installing new units, would run the "world's first video game" for their new customers. (Higginbotham's Tennis For Two had beaten Spacewar by almost three years, but it was almost unknown outside of a research or academic setting.) At around the same time (1961–1962) in the University of Cambridge, Elizabeth Waldram wrote code to display radio-astronomy maps on a cathode ray tube. E. E. Zajac, a scientist at Bell Telephone Laboratory (BTL), created a film called "Simulation of a two-giro gravity attitude control system" in 1963. In this computer-generated film, Zajac showed how the attitude of a satellite could be altered as it orbits the Earth. He created the animation on an IBM 7090 mainframe computer. Also at BTL, Ken Knowlton, Frank Sinden, Ruth A. Weiss and Michael Noll started working in the computer graphics field. Sinden created a film called Force, Mass and Motion illustrating Newton's laws of motion in operation. Around the same time, other scientists were creating computer graphics to illustrate their research. At Lawrence Radiation Laboratory, Nelson Max created the films Flow of a Viscous Fluid and Propagation of Shock Waves in a Solid Form. Boeing Aircraft created a film called Vibration of an Aircraft. Also sometime in the early 1960s, automobiles would also provide a boost through the early work of Pierre Bézier at Renault, who used Paul de Casteljau's curves – now called Bézier curves after Bézier's work in the field – to develop 3d modeling techniques for Renault car bodies. These curves would form the foundation for much curve-modeling work in the field, as curves – unlike polygons – are mathematically complex entities to draw and model well. It was not long before major corporations started taking an interest in computer graphics. TRW, Lockheed-Georgia, General Electric and Sperry Rand are among the many companies that were getting started in computer graphics by the mid-1960s. IBM was quick to respond to this interest by releasing the IBM 2250 graphics terminal, the first commercially available graphics computer. Ralph Baer, a supervising engineer at Sanders Associates, came up with a home video game in 1966 that was later licensed to Magnavox and called the Odyssey. While very simplistic, and requiring fairly inexpensive electronic parts, it allowed the player to move points of light around on a screen. It was the first consumer computer graphics product. David C. Evans was director of engineering at Bendix Corporation's computer division from 1953 to 1962, after which he worked for the next five years as a visiting professor at Berkeley. There he continued his interest in computers and how they interfaced with people. In 1966, the University of Utah recruited Evans to form a computer science program, and computer graphics quickly became his primary interest. This new department would become the world's primary research center for computer graphics through the 1970s. Also, in 1966, Ivan Sutherland continued to innovate at MIT when he invented the first computer-controlled head-mounted display (HMD). It displayed two separate wireframe images, one for each eye. This allowed the viewer to see the computer scene in stereoscopic 3D. The heavy hardware required for supporting the display and tracker was called the Sword of Damocles because of the potential danger if it were to fall upon the wearer. After receiving his Ph.D. from MIT, Sutherland became Director of Information Processing at ARPA (Advanced Research Projects Agency), and later became a professor at Harvard. In 1967 Sutherland was recruited by Evans to join the computer science program at the University of Utah – a development which would turn that department into one of the most important research centers in graphics for nearly a decade thereafter, eventually producing some of the most important pioneers in the field. There Sutherland perfected his HMD; twenty years later, NASA would re-discover his techniques in their virtual reality research. At Utah, Sutherland and Evans were highly sought after consultants by large companies, but they were frustrated at the lack of graphics hardware available at the time, so they started formulating a plan to start their own company. In 1968, Dave Evans and Ivan Sutherland founded the first computer graphics hardware company, Evans & Sutherland. While Sutherland originally wanted the company to be located in Cambridge, Massachusetts, Salt Lake City was instead chosen due to its proximity to the professors' research group at the University of Utah. Also in 1968 Arthur Appel described the first ray casting algorithm, the first of a class of ray tracing-based rendering algorithms that have since become fundamental in achieving photorealism in graphics by modeling the paths that rays of light take from a light source, to surfaces in a scene, and into the camera. In 1969, the ACM initiated A Special Interest Group on Graphics (SIGGRAPH) which organizes conferences, graphics standards, and publications within the field of computer graphics. By 1973, the first annual SIGGRAPH conference was held, which has become one of the focuses of the organization. SIGGRAPH has grown in size and importance as the field of computer graphics has expanded over time. === 1970s === Subsequently, a number of breakthroughs in the field occurred at the University of Utah in the 1970s, which had hired Ivan Sutherland. He was paired with David C. Evans to teach an advanced computer graphics class, which contributed a great deal of founding research to the field and taught several students who would grow to found several of the industry's most important companies – namely Pixar, Silicon Graphics, and Adobe Systems. Tom Stockham led the image processing group at UU which worked closely with the computer graphics lab. One of these students was Edwin Catmull. Catmull had just come from The Boeing Company and had been working on his degree in physics. Growing up on Disney, Catmull loved animation yet quickly discovered that he did not have the talent for drawing. Now Catmull (along with many others) saw computers as the natural progression of animation and they wanted to be part of the revolution. The first computer animation that Catmull saw was his own. He created an animation of his hand opening and closing. He also pioneered texture mapping to paint textures on three-dimensional models in 1974, now considered one of the fundamental techniques in 3D modeling. It became one of his goals to produce a feature-length motion picture using computer graphics – a goal he would achieve two decades later after his founding role in Pixar. In the same class, Fred Parke created an animation of his wife's face. The two animations were included in the 1976 feature film Futureworld. As the UU computer graphics laboratory was attracting people from all over, John Warnock was another of those early pioneers; he later founded Adobe Systems and created a revolution in the publishing world with his PostScript page description language. Adobe would go on later to create the industry standard photo editing software in Adobe Photoshop and a prominent movie industry special effects program in Adobe After Effects. James Clark was also there; he later founded Silicon Graphics, a maker of advanced rendering systems that would dominate the field of high-end graphics until the early 1990s. A major advance in 3D computer graphics was created at UU by these early pioneers – hidden surface determination. In order to draw a representation of a 3D object on the screen, the computer must determine which surfaces are "behind" the object from the viewer's perspective, and thus should be "hidden" when the computer creates (or renders) the image. The 3D Core Graphics System (or Core) was the first graphical standard to be developed. A group of 25 experts of the ACM Special Interest Group SIGGRAPH developed this "conceptual framework". The specifications were published in 1977, and it became a foundation for many future developments in the field. Also in the 1970s, Henri Gouraud, Jim Blinn and Bui Tuong Phong contributed to the foundations of shading in CGI via the development of the Gouraud shading and Blinn–Phong shading models, allowing graphics to move beyond a "flat" look to a look more accurately portraying depth. Jim Blinn also innovated further in 1978 by introducing bump mapping, a technique for simulating uneven surfaces, and the predecessor to many more advanced kinds of mapping used today. The modern videogame arcade as is known today was birthed in the 1970s, with the first arcade games using real-time 2D sprite graphics. Pong in 1972 was one of the first hit arcade cabinet games. Speed Race in 1974 featured sprites moving along a vertically scrolling road. Gun Fight in 1975 featured human-looking animated characters, while Space Invaders in 1978 featured a large number of animated figures on screen; both used a specialized barrel shifter circuit made from discrete chips to help their Intel 8080 microprocessor animate their framebuffer graphics. === 1980s === The 1980s began to see the commercialization of computer graphics. As the home computer proliferated, a subject which had previously been an academics-only discipline was adopted by a much larger audience, and the number of computer graphics developers increased significantly. In the early 1980s, metal–oxide–semiconductor (MOS) very-large-scale integration (VLSI) technology led to the availability of 16-bit central processing unit (CPU) microprocessors and the first graphics processing unit (GPU) chips, which began to revolutionize computer graphics, enabling high-resolution graphics for computer graphics terminals as well as personal computer (PC) systems. NEC's μPD7220 was the first GPU, fabricated on a fully integrated NMOS VLSI chip. It supported up to 1024x1024 resolution, and laid the foundations for the emerging PC graphics market. It was used in a number of graphics cards, and was licensed for clones such as the Intel 82720, the first of Intel's graphics processing units. MOS memory also became cheaper in the early 1980s, enabling the development of affordable framebuffer memory, notably video RAM (VRAM) introduced by Texas Instruments (TI) in the mid-1980s. In 1984, Hitachi released the ARTC HD63484, the first complementary MOS (CMOS) GPU. It was capable of displaying high-resolution in color mode and up to 4K resolution in monochrome mode, and it was used in a number of graphics cards and terminals during the late 1980s. In 1986, TI introduced the TMS34010, the first fully programmable MOS graphics processor. Computer graphics terminals during this decade became increasingly intelligent, semi-standalone and standalone workstations. Graphics and application processing were increasingly migrated to the intelligence in the workstation, rather than continuing to rely on central mainframe and minicomputers. Typical of the early move to high-resolution computer graphics, intelligent workstations for the computer-aided engineering market were the Orca 1000, 2000 and 3000 workstations, developed by Orcatech of Ottawa, a spin-off from Bell-Northern Research, and led by David Pearson, an early workstation pioneer. The Orca 3000 was based on the 16-bit Motorola 68000 microprocessor and AMD bit-slice processors, and had Unix as its operating system. It was targeted squarely at the sophisticated end of the design engineering sector. Artists and graphic designers began to see the personal computer, particularly the Amiga and Macintosh, as a serious design tool, one that could save time and draw more accurately than other methods. The Macintosh remains a highly popular tool for computer graphics among graphic design studios and businesses. Modern computers, dating from the 1980s, often use graphical user interfaces (GUI) to present data and information with symbols, icons and pictures, rather than text. Graphics are one of the five key elements of multimedia technology. In the field of realistic rendering, Japan's Osaka University developed the LINKS-1 Computer Graphics System, a supercomputer that used up to 257 Zilog Z8001 microprocessors, in 1982, for the purpose of rendering realistic 3D computer graphics. According to the Information Processing Society of Japan: "The core of 3D image rendering is calculating the luminance of each pixel making up a rendered surface from the given viewpoint, light source, and object position. The LINKS-1 system was developed to realize an image rendering methodology in which each pixel could be parallel processed independently using ray tracing. By developing a new software methodology specifically for high-speed image rendering, LINKS-1 was able to rapidly render highly realistic images." The LINKS-1 was the world's most powerful computer, as of 1984. Also in the field of realistic rendering, the general rendering equation of David Immel and James Kajiya was developed in 1986 – an important step towards implementing global illumination, which is necessary to pursue photorealism in computer graphics. The continuing popularity of Star Wars and other science fiction franchises were relevant in cinematic CGI at this time, as Lucasfilm and Industrial Light & Magic became known as the "go-to" house by many other studios for topnotch computer graphics in film. Important advances in chroma keying ("bluescreening", etc.) were made for the later films of the original trilogy. Two other pieces of video would also outlast the era as historically relevant: Dire Straits' iconic, near-fully-CGI video for their song "Money for Nothing" in 1985, which popularized CGI among music fans of that era, and a scene from Young Sherlock Holmes the same year featuring the first fully CGI character in a feature movie (an animated stained-glass knight). In 1988, the first shaders – small programs designed specifically to do shading as a separate algorithm – were developed by Pixar, which had already spun off from Industrial Light & Magic as a separate entity – though the public would not see the results of such technological progress until the next decade. In the late 1980s, Silicon Graphics (SGI) computers were used to create some of the first fully computer-generated short films at Pixar, and Silicon Graphics machines were considered a high-water mark for the field during the decade. The 1980s is also called the golden era of videogames; millions-selling systems from Atari, Nintendo and Sega, among other companies, exposed computer graphics for the first time to a new, young, and impressionable audience – as did MS-DOS-based personal computers, Apple IIs, Macs, and Amigas, all of which also allowed users to program their own games if skilled enough. For the arcades, advances were made in commercial, real-time 3D graphics. In 1988, the first dedicated real-time 3D graphics boards were introduced for arcades, with the Namco System 21 and Taito Air System. On the professional side, Evans & Sutherland and SGI developed 3D raster graphics hardware that directly influenced the later single-chip graphics processing unit (GPU), a technology where a separate and very powerful chip is used in parallel processing with a CPU to optimize graphics. The decade also saw computer graphics applied to many additional professional markets, including location-based entertainment and education with the E&S Digistar, vehicle design, vehicle simulation, and chemistry. === 1990s === The 1990s' highlight was the emergence of 3D modeling on a mass scale and an rise in the quality of CGI generally. Home computers became able to take on rendering tasks that previously had been limited to workstations costing thousands of dollars; as 3D modelers became available for home systems, the popularity of Silicon Graphics workstations declined and powerful Microsoft Windows and Apple Macintosh machines running Autodesk products like 3D Studio or other home rendering software ascended in importance. By the end of the decade, the GPU would begin its rise to the prominence it still enjoys today. The field began to see the first rendered graphics that could truly pass as photorealistic to the untrained eye (though they could not yet do so with a trained CGI artist) and 3D graphics became far more popular in gaming, multimedia, and animation. At the end of the 1980s and the beginning of the nineties were created, in France, the very first computer graphics TV series: La Vie des bêtes by studio Mac Guff Ligne (1988), Les Fables Géométriques (1989–1991) by studio Fantôme, and Quarxs, the first HDTV computer graphics series by Maurice Benayoun and François Schuiten (studio Z-A production, 1990–1993). In film, Pixar began its serious commercial rise in this era under Edwin Catmull, with its first major film release, in 1995 – Toy Story – a critical and commercial success of nine-figure magnitude. The studio to invent the programmable shader would go on to have many animated hits, and its work on prerendered video animation is still considered an industry leader and research trail breaker. In video games, in 1992, Virtua Racing, running on the Sega Model 1 arcade system board, laid the foundations for fully 3D racing games and popularized real-time 3D polygonal graphics among a wider audience in the video game industry. The Sega Model 2 in 1993 and Sega Model 3 in 1996 subsequently pushed the boundaries of commercial, real-time 3D graphics. Back on the PC, Wolfenstein 3D, Doom and Quake, three of the first massively popular 3D first-person shooter games, were released by id Software to critical and popular acclaim during this decade using a rendering engine innovated primarily by John Carmack. The Sony PlayStation, Sega Saturn, and Nintendo 64, among other consoles, sold in the millions and popularized 3D graphics for home gamers. Certain late-1990s first-generation 3D titles became seen as influential in popularizing 3D graphics among console users, such as platform games Super Mario 64 and The Legend of Zelda: Ocarina of Time, and early 3D fighting games like Virtua Fighter, Battle Arena Toshinden, and Tekken. Technology and algorithms for rendering continued to improve greatly. In 1996, Krishnamurty and Levoy invented normal mapping – an improvement on Jim Blinn's bump mapping. 1999 saw Nvidia release the seminal GeForce 256, the first home video card billed as a graphics processing unit or GPU, which in its own words contained "integrated transform, lighting, triangle setup/clipping, and rendering engines". By the end of the decade, computers adopted common frameworks for graphics processing such as DirectX and OpenGL. Since then, computer graphics have only become more detailed and realistic, due to more powerful graphics hardware and 3D modeling software. AMD also became a leading developer of graphics boards in this decade, creating a "duopoly" in the field which exists this day. === 2000s === CGI became ubiquitous in earnest during this era. Video games and CGI cinema had spread the reach of computer graphics to the mainstream by the late 1990s and continued to do so at an accelerated pace in the 2000s. CGI was also adopted en masse for television advertisements widely in the late 1990s and 2000s, and so became familiar to a massive audience. The continued rise and increasing sophistication of the graphics processing unit were crucial to this decade, and 3D rendering capabilities became a standard feature as 3D-graphics GPUs became considered a necessity for desktop computer makers to offer. The Nvidia GeForce line of graphics cards dominated the market in the early decade with occasional significant competing presence from ATI. As the decade progressed, even low-end machines usually contained a 3D-capable GPU of some kind as Nvidia and AMD both introduced low-priced chipsets and continued to dominate the market. Shaders which had been introduced in the 1980s to perform specialized processing on the GPU would by the end of the decade become supported on most consumer hardware, speeding up graphics considerably and allowing for greatly improved texture and shading in computer graphics via the widespread adoption of normal mapping, bump mapping, and a variety of other techniques allowing the simulation of a great amount of detail. Computer graphics used in films and video games gradually began to be realistic to the point of entering the uncanny valley. CGI movies proliferated, with traditional animated cartoon films like Ice Age and Madagascar as well as numerous Pixar offerings like Finding Nemo dominating the box office in this field. The Final Fantasy: The Spirits Within, released in 2001, was the first fully computer-generated feature film to use photorealistic CGI characters and be fully made with motion capture. The film was not a box-office success, however. Some commentators have suggested this may be partly because the lead CGI characters had facial features which fell into the "uncanny valley". Other animated films like The Polar Express drew attention at this time as well. Star Wars also resurfaced with its prequel trilogy and the effects continued to set a bar for CGI in film. In videogames, the Sony PlayStation 2 and 3, the Microsoft Xbox line of consoles, and offerings from Nintendo such as the GameCube maintained a large following, as did the Windows PC. Marquee CGI-heavy titles like the series of Grand Theft Auto, Assassin's Creed, Final Fantasy, BioShock, Kingdom Hearts, Mirror's Edge and dozens of others continued to approach photorealism, grow the video game industry and impress, until that industry's revenues became comparable to those of movies. Microsoft made a decision to expose DirectX more easily to the independent developer world with the XNA program, but it was not a success. DirectX itself remained a commercial success, however. OpenGL continued to mature as well, and it and DirectX improved greatly; the second-generation shader languages HLSL and GLSL began to be popular in this decade. In scientific computing, the GPGPU technique to pass large amounts of data bidirectionally between a GPU and CPU was invented; speeding up analysis on many kinds of bioinformatics and molecular biology experiments. The technique has also been used for Bitcoin mining and has applications in computer vision. === 2010s === In the 2010s, CGI has been nearly ubiquitous in video, pre-rendered graphics are nearly scientifically photorealistic, and real-time graphics on a suitably high-end system may simulate photorealism to the untrained eye. Texture mapping has matured into a multistage process with many layers; generally, it is not uncommon to implement texture mapping, bump mapping or isosurfaces or normal mapping, lighting maps including specular highlights and reflection techniques, and shadow volumes into one rendering engine using shaders, which are maturing considerably. Shaders are now very nearly a necessity for advanced work in the field, providing considerable complexity in manipulating pixels, vertices, and textures on a per-element basis, and countless possible effects. Their shader languages HLSL and GLSL are active fields of research and development. Physically based rendering or PBR, which implements many maps and performs advanced calculation to simulate real optic light flow, is an active research area as well, along with advanced areas like ambient occlusion, subsurface scattering, Rayleigh scattering, photon mapping, ray-tracing and many others. Experiments into the processing power required to provide graphics in real time at ultra-high-resolution modes like 4K Ultra HD begun, though beyond reach of all but the highest-end hardware. In cinema, most animated movies are CGI now; many animated CGI films are made per year, but few, if any, attempt photorealism due to continuing fears of the uncanny valley. Most are 3D cartoons. In videogames, the Microsoft Xbox One, Sony PlayStation 4, and Nintendo Switch dominated the home space and were all capable of advanced 3D graphics; Windows was still one of the most active gaming platforms as well. === 2020s === In the 2020s', advances in ray-tracing technology allowed it to be used for real-time rendering, as well as AI-powered graphics for generating or upscaling While ray-tracing existed before, Nvidia was the first to push for ray-tracing with ray-tracing cores, as well as for AI with DLSS and Tensor cores. AMD followed suit with the same; FSR, Tensor cores and ray-tracing cores. == Image types == === Two-dimensional === 2D computer graphics are the computer-based generation of digital images—mostly from models, such as digital image, and by techniques specific to them. 2D computer graphics are mainly used in applications that were originally developed upon traditional printing and drawing technologies such as typography. In those applications, the two-dimensional image is not just a representation of a real-world object, but an independent artifact with added semantic value; two-dimensional models are therefore preferred because they give more direct control of the image than 3D computer graphics, whose approach is more akin to photography than to typography. ==== Pixel art ==== A large form of digital art, pixel art is created through the use of raster graphics software, where images are edited on the pixel level. Graphics in most old (or relatively limited) computer and video games, graphing calculator games, and many mobile phone games are mostly pixel art. ==== Sprite graphics ==== A sprite is a two-dimensional image or animation that is integrated into a larger scene. Initially including just graphical objects handled separately from the memory bitmap of a video display, this now includes various manners of graphical overlays. Originally, sprites were a method of integrating unrelated bitmaps so that they appeared to be part of the normal bitmap on a screen, such as creating an animated character that can be moved on a screen without altering the data defining the overall screen. Such sprites can be created by either electronic circuitry or software. In circuitry, a hardware sprite is a hardware construct that employs custom DMA channels to integrate visual elements with the main screen in that it super-imposes two discrete video sources. Software can simulate this through specialized rendering methods. ==== Vector graphics ==== Vector graphics formats are complementary to raster graphics. Raster graphics is the representation of images as an array of pixels and is typically used for the representation of photographic images. Vector graphics consists of encoding information about shapes and colors that comprise the image, which can allow for more flexibility in rendering. There are instances when working with vector tools and formats is best practice, and instances when working with raster tools and formats is best practice. There are times when both formats come together. An understanding of the advantages and limitations of each technology and the relationship between them is most likely to result in efficient and effective use of tools. ==== Generative machine-learning models ==== Since the mid-2010s, as a result of advances in deep neural networks, models have been created which take as input a natural language description and produces as output an image matching that description. Text-to-image models generally combine a language model, which transforms the input text into a latent representation, and a generative image model, which produces an image conditioned on that representation. The most effective models have generally been trained on massive amounts of image and text data scraped from the web. By 2022, the best of these models, for example Dall-E 2 and Stable Diffusion, are able to create images in a range of styles, ranging from imitations of living artists to near-photorealistic, in a matter of seconds, given powerful enough hardware. === Three-dimensional === 3D graphics, compared to 2D graphics, are graphics that use a three-dimensional representation of geometric data. For the purpose of performance, this is stored in the computer. This includes images that may be for later display or for real-time viewing. Despite these differences, 3D computer graphics rely on similar algorithms as 2D computer graphics do in the frame and raster graphics (like in 2D) in the final rendered display. In computer graphics software, the distinction between 2D and 3D is occasionally blurred; 2D applications may use 3D techniques to achieve effects such as lighting, and primarily 3D may use 2D rendering techniques. 3D computer graphics are the same as 3D models. The model is contained within the graphical data file, apart from the rendering. However, there are differences that include the 3D model being the representation of any 3D object. Until visually displayed, a model is not graphic. Due to printing, 3D models are not only confined to virtual space. 3D rendering is how a model can be displayed. Also can be used in non-graphical computer simulations and calculations. === Computer animation === Computer animation is the art of creating moving images via the use of computers. It is a subfield of computer graphics and animation. Increasingly it is created by means of 3D computer graphics, though 2D computer graphics are still widely used for stylistic, low bandwidth, and faster real-time rendering needs. Sometimes the target of the animation is the computer itself, but sometimes the target is another medium, such as film. It is also referred to as CGI (Computer-generated imagery or computer-generated imaging), especially when used in films. Virtual entities may contain and be controlled by assorted attributes, such as transform values (location, orientation, and scale) stored in an object's transformation matrix. Animation is the change of an attribute over time. Multiple methods of achieving animation exist; the rudimentary form is based on the creation and editing of keyframes, each storing a value at a given time, per attribute to be animated. The 2D/3D graphics software will change with each keyframe, creating an editable curve of a value mapped over time, in which results in animation. Other methods of animation include procedural and expression-based techniques: the former consolidates related elements of animated entities into sets of attributes, useful for creating particle effects and crowd simulations; the latter allows an evaluated result returned from a user-defined logical expression, coupled with mathematics, to automate animation in a predictable way (convenient for controlling bone behavior beyond what a hierarchy offers in skeletal system set up). To create the illusion of movement, an image is displayed on the computer screen then quickly replaced by a new image that is similar to the previous image, but shifted slightly. This technique is identical to the illusion of movement in television and motion pictures. == Concepts and principles == Images are typically created by devices such as cameras, mirrors, lenses, telescopes, microscopes, etc. Digital images include both vector images and raster images, but raster images are more commonly used. === Pixel === In digital imaging, a pixel (or picture element) is a single point in a raster image. Pixels are placed on a regular 2-dimensional grid, and are often represented using dots or squares. Each pixel is a sample of an original image, where more samples typically provide a more accurate representation of the original. The intensity of each pixel is variable; in color systems, each pixel typically has three subpixels such as red, green, and blue. Graphics are visual representations on a surface, such as a computer screen. Examples are photographs, drawing, graphics designs, maps, engineering drawings, or other images. Graphics often combine text and illustration. Graphic design may consist of the deliberate selection, creation, or arrangement of typography alone, as in a brochure, flier, poster, web site, or book without any other element. Clarity or effective communication may be the objective, association with other cultural elements may be sought, or merely, the creation of a distinctive style. === Primitives === Primitives are basic units which a graphics system may combine to create more complex images or models. Examples would be sprites and character maps in 2D video games, geometric primitives in CAD, or polygons or triangles in 3D rendering. Primitives may be supported in hardware for efficient rendering, or the building blocks provided by a graphics application. === Rendering === Rendering is the generation of a 2D image from a 3D model by means of computer programs. A scene file contains objects in a strictly defined language or data structure; it would contain geometry, viewpoint, texturing, lighting, and shading information as a description of the virtual scene. The data contained in the scene file is then passed to a rendering program to be processed and output to a digital image or raster graphics image file. The rendering program is usually built into the computer graphics software, though others are available as plug-ins or entirely separate programs. The term "rendering" may be by analogy with an "artist's rendering" of a scene. Although the technical details of rendering methods vary, the general challenges to overcome in producing a 2D image from a 3D representation stored in a scene file are outlined as the graphics pipeline along a rendering device, such as a GPU. A GPU is a device able to assist the CPU in calculations. If a scene is to look relatively realistic and predictable under virtual lighting, the rendering software should solve the rendering equation. The rendering equation does not account for all lighting phenomena, but is a general lighting model for computer-generated imagery. 'Rendering' is also used to describe the process of calculating effects in a video editing file to produce final video output. 3D projection 3D projection is a method of mapping three dimensional points to a two dimensional plane. As most current methods for displaying graphical data are based on planar two dimensional media, the use of this type of projection is widespread. This method is used in most real-time 3D applications and typically uses rasterization to produce the final image. Ray tracing Ray tracing is a technique from the family of image order algorithms for generating an image by tracing the path of light through pixels in an image plane. The technique is capable of producing a high degree of photorealism; usually higher than that of typical scanline rendering methods, but at a greater computational cost. Shading Shading refers to depicting depth in 3D models or illustrations by varying levels of darkness. It is a process used in drawing for depicting levels of darkness on paper by applying media more densely or with a darker shade for darker areas, and less densely or with a lighter shade for lighter areas. There are various techniques of shading including cross hatching where perpendicular lines of varying closeness are drawn in a grid pattern to shade an area. The closer the lines are together, the darker the area appears. Likewise, the farther apart the lines are, the lighter the area appears. The term has been recently generalized to mean that shaders are applied. Texture mapping Texture mapping is a method for adding detail, surface texture, or colour to a computer-generated graphic or 3D model. Its application to 3D graphics was pioneered by Edwin Catmull in 1974. A texture map is applied (mapped) to the surface of a shape, or polygon. This process is akin to applying patterned paper to a plain white box. Multitexturing is the use of more than one texture at a time on a polygon. Procedural textures (created from adjusting parameters of an underlying algorithm that produces an output texture), and bitmap textures (created in an image editing application or imported from a digital camera) are, generally speaking, common methods of implementing texture definition on 3D models in computer graphics software, while intended placement of textures onto a model's surface often requires a technique known as UV mapping (arbitrary, manual layout of texture coordinates) for polygon surfaces, while non-uniform rational B-spline (NURB) surfaces have their own intrinsic parameterization used as texture coordinates. Texture mapping as a discipline also encompasses techniques for creating normal maps and bump maps that correspond to a texture to simulate height and specular maps to help simulate shine and light reflections, as well as environment mapping to simulate mirror-like reflectivity, also called gloss. Anti-aliasing Rendering resolution-independent entities (such as 3D models) for viewing on a raster (pixel-based) device such as a liquid-crystal display or CRT television inevitably causes aliasing artifacts mostly along geometric edges and the boundaries of texture details; these artifacts are informally called "jaggies". Anti-aliasing methods rectify such problems, resulting in imagery more pleasing to the viewer, but can be somewhat computationally expensive. Various anti-aliasing algorithms (such as supersampling) are able to be employed, then customized for the most efficient rendering performance versus quality of the resultant imagery; a graphics artist should consider this trade-off if anti-aliasing methods are to be used. A pre-anti-aliased bitmap texture being displayed on a screen (or screen location) at a resolution different from the resolution of the texture itself (such as a textured model in the distance from the virtual camera) will exhibit aliasing artifacts, while any procedurally defined texture will always show aliasing artifacts as they are resolution-independent; techniques such as mipmapping and texture filtering help to solve texture-related aliasing problems. === Volume rendering === Volume rendering is a technique used to display a 2D projection of a 3D discretely sampled data set. A typical 3D data set is a group of 2D slice images acquired by a CT or MRI scanner. Usually these are acquired in a regular pattern (e.g., one slice every millimeter) and usually have a regular number of image pixels in a regular pattern. This is an example of a regular volumetric grid, with each volume element, or voxel represented by a single value that is obtained by sampling the immediate area surrounding the voxel. === 3D modeling === 3D modeling is the process of developing a mathematical, wireframe representation of any three-dimensional object, called a "3D model", via specialized software. Models may be created automatically or manually; the manual modeling process of preparing geometric data for 3D computer graphics is similar to plastic arts such as sculpting. 3D models may be created using multiple approaches: use of NURBs to generate accurate and smooth surface patches, polygonal mesh modeling (manipulation of faceted geometry), or polygonal mesh subdivision (advanced tessellation of polygons, resulting in smooth surfaces similar to NURB models). A 3D model can be displayed as a two-dimensional image through a process called 3D rendering, used in a computer simulation of physical phenomena, or animated directly for other purposes. The model can also be physically created using 3D Printing devices. == Pioneers in computer graphics == === Charles Csuri === Charles Csuri was a pioneer in computer animation and digital fine art and created the first computer art in 1964. Csuri was recognized by Smithsonian as the father of digital art and computer animation, and as a pioneer of computer animation by the Museum of Modern Art (MoMA) and Association for Computing Machinery-SIGGRAPH. === Donald P. Greenberg === Donald P. Greenberg is a leading innovator in computer graphics. Greenberg has authored hundreds of articles and served as a teacher and mentor to many prominent computer graphic artists, animators, and researchers such as Robert L. Cook, Marc Levoy, Brian A. Barsky, and Wayne Lytle. Many of his former students have won Academy Awards for technical achievements and several have won the SIGGRAPH Achievement Award. Greenberg was the founding director of the NSF Center for Computer Graphics and Scientific Visualization. === A. Michael Noll === Noll was one of the first researchers to use a digital computer to create artistic patterns and to formalize the use of random processes in the creation of visual arts. He began creating digital art in 1962, making him one of the earliest digital artists. In 1965, Noll along with Frieder Nake and Georg Nees were the first to publicly exhibit their computer art. During April 1965, the Howard Wise Gallery exhibited Noll's computer art along with random-dot patterns by Bela Julesz. === Jack Elton Bresenham === Jack Bresenham is a former professor of computer science. He developed the Bresenham's line algorithm, his most well-known invention in 1962. He retired from 27 years of service at IBM as a Senior Technical Staff Member, taught for 16 years at Winthrop University and has nine patents. === Other pioneers === Pierre Bézier Jim Blinn John Carmack Paul de Casteljau Ed Catmull Frank Crow James D. Foley William Fetter Henry Fuchs Henri Gouraud Charles Loop Nadia Magnenat Thalmann Benoit Mandelbrot Martin Newell Fred Parke Bui Tuong Phong Steve Russell Daniel J. Sandin Alvy Ray Smith Bob Sproull Ivan Sutherland Daniel Thalmann Johnson K. Yan Andries van Dam John Warnock J. Turner Whitted Lance Williams Jim Kajiya James H. Clark === Organizations === SIGGRAPH GDC Bell Telephone Laboratories Link Flight Simulation, division of Singer Company United States Armed Forces, particularly the Whirlwind computer and SAGE Project Boeing Eurographics Evans and Sutherland IBM Renault NYIT The computer science department of the University of Utah Lucasfilm and Industrial Light & Magic Autodesk Adobe Systems Pixar Silicon Graphics, Khronos Group & OpenGL The DirectX division at Microsoft Nvidia AMD (ATI Technologies) == Study of computer graphics == The study of computer graphics is a sub-field of computer science which studies methods for digitally synthesizing and manipulating visual content. Although the term often refers to three-dimensional computer graphics, it also encompasses two-dimensional graphics and image processing. As an academic discipline, computer graphics studies the manipulation of visual and geometric information using computational techniques. It focuses on the mathematical and computational foundations of image generation and processing rather than purely aesthetic issues. Computer graphics is often differentiated from the field of visualization, although the two fields have many similarities. == Applications == Computer graphics may be used in the following areas: Augmented reality Computational biology Computational photography Computational physics Computer-aided design Computing Design Digital art Education Extended reality Graphic design Infographics Information visualization Mixed reality Motion graphics Rational drug design Simulation Scientific visualization Special effects for cinema Video games Virtual reality Web3D == See also == Computer representation of surfaces Glossary of computer graphics == Notes == == References == == Further reading == L. Ammeraal and K. Zhang (2007). Computer Graphics for Java Programmers, Second Edition, John-Wiley & Sons, ISBN 978-0-470-03160-5. David Rogers (1998). Procedural Elements for Computer Graphics. McGraw-Hill. James D. Foley, Andries Van Dam, Steven K. Feiner and John F. Hughes (1995). Computer Graphics: Principles and Practice. Addison-Wesley. Donald Hearn and M. Pauline Baker (1994). Computer Graphics. Prentice-Hall. Francis S. Hill (2001). Computer Graphics. Prentice Hall. John Lewell (1985). Computer Graphics: A Survey of Current Techniques and Applications. Van Nostrand Reinhold. Jeffrey J. McConnell (2006). Computer Graphics: Theory Into Practice. Jones & Bartlett Publishers. R. D. Parslow, R. W. Prowse, Richard Elliot Green (1969). Computer Graphics: Techniques and Applications. Peter Shirley and others. (2005). Fundamentals of computer graphics. A.K. Peters, Ltd. M. Slater, A. Steed, Y. Chrysantho (2002). Computer graphics and virtual environments: from realism to real-time. Addison-Wesley. Wolfgang Höhl (2008): Interactive environments with open-source software, Springer Wien New York, ISBN 3-211-79169-8 == External links == A Critical History of Computer Graphics and Animation (archived 5 April 2007) History of Computer Graphics series of articles (archived 2 March 2007) Computer Graphics research at UC Berkeley Thomas Dreher: History of Computer Art, chap. IV.2 Computer Animation History of Computer Graphics on RUS
Wikipedia/Computer_graphics
Network architecture is the design of a computer network. It is a framework for the specification of a network's physical components and their functional organization and configuration, its operational principles and procedures, as well as communication protocols used. In telecommunications, the specification of a network architecture may also include a detailed description of products and services delivered via a communications network, as well as detailed rate and billing structures under which services are compensated. The network architecture of the Internet is predominantly expressed by its use of the Internet protocol suite, rather than a specific model for interconnecting networks or nodes in the network, or the usage of specific types of hardware links. == OSI model == The Open Systems Interconnection model (OSI model) defines and codifies the concept of layered network architecture. Abstraction layers are used to subdivide a communications system further into smaller manageable parts. A layer is a collection of similar functions that provide services to the layer above it and receives services from the layer below it. On each layer, an instance provides services to the instances at the layer above and requests services from the layer below. == Distributed computing == In distributed computing, the network architecture often describes the structure and classification of a distributed application architecture, as the participating nodes in a distributed application are often referred to as a network. For example, the applications architecture of the public switched telephone network (PSTN) has been termed the Intelligent Network. There are a number of specific classifications but all lie on a continuum between the dumb network (e.g. the Internet) and the intelligent network (e.g. the PSTN). A popular example of such usage of the term in distributed applications, as well as permanent virtual circuits, is the organization of nodes in peer-to-peer (P2P) services and networks. P2P networks usually implement overlay networks running over an underlying physical or logical network. These overlay networks may implement certain organizational structures of the nodes according to several distinct models, the network architecture of the system. == See also == Network topology Spawning networks == References == This article incorporates public domain material from Federal Standard 1037C. General Services Administration. Archived from the original on 2022-01-22. (in support of MIL-STD-188). == External links == Computer Network Architects at the US Department of Labor
Wikipedia/Network_architecture
In mathematics, the Elementary Theory of the Category of Sets or ETCS is a set of axioms for set theory proposed by William Lawvere in 1964. Although it was originally stated in the language of category theory, as Leinster pointed out, the axioms can be stated without references to category theory. ETCS is a basic example of structural set theory, an approach to set theory that emphasizes sets as abstract structures (as opposed to collections of elements). == Axioms == Informally, the axioms are as follows: (here, set, function and composition of functions are primitives) Composition of functions is associative and has identities. There is a set with exactly one element. There is an empty set. A function is determined by its effect on elements. A Cartesian product exists for a pair of sets. Given sets X {\displaystyle X} and Y {\displaystyle Y} , there is a set of all functions from X {\displaystyle X} to Y {\displaystyle Y} . Given f : X → Y {\displaystyle f:X\to Y} and an element y ∈ Y {\displaystyle y\in Y} , the pre-image f − 1 ( y ) {\displaystyle f^{-1}(y)} is defined. The subsets of a set X {\displaystyle X} correspond to the functions X → { 0 , 1 } {\displaystyle X\to \{0,1\}} . The natural numbers form a set. (weak axiom of choice) Every surjection has a right inverse (i.e., a section). The resulting theory is weaker than ZFC. If the axiom schema of replacement is added as another axiom, the resulting theory is equivalent to ZFC. == References == Leinster, Tom (1 May 2014). "Rethinking Set Theory". The American Mathematical Monthly. doi:10.4169/amer.math.monthly.121.05.403. JSTOR 10.4169/amer.math.monthly.121.05.403. A post about the paper at the n-category café. Clive Newstead, An Elementary Theory of the Category of Sets at the n-Category Café == Further reading == ETCS in nLab ZFC and ETCS: Elementary Theory of the Category of Sets Tom Leinster, Axiomatic Set Theory 1: Introduction at the n-Category Café How would set theory research be affected by using ETCS instead of ZFC?
Wikipedia/Elementary_Theory_of_the_Category_of_Sets
Naive set theory is any of several theories of sets used in the discussion of the foundations of mathematics. Unlike axiomatic set theories, which are defined using formal logic, naive set theory is defined informally, in natural language. It describes the aspects of mathematical sets familiar in discrete mathematics (for example Venn diagrams and symbolic reasoning about their Boolean algebra), and suffices for the everyday use of set theory concepts in contemporary mathematics. Sets are of great importance in mathematics; in modern formal treatments, most mathematical objects (numbers, relations, functions, etc.) are defined in terms of sets. Naive set theory suffices for many purposes, while also serving as a stepping stone towards more formal treatments. == Method == A naive theory in the sense of "naive set theory" is a non-formalized theory, that is, a theory that uses natural language to describe sets and operations on sets. Such theory treats sets as platonic absolute objects. The words and, or, if ... then, not, for some, for every are treated as in ordinary mathematics. As a matter of convenience, use of naive set theory and its formalism prevails even in higher mathematics – including in more formal settings of set theory itself. The first development of set theory was a naive set theory. It was created at the end of the 19th century by Georg Cantor as part of his study of infinite sets and developed as a formal but inconsistent system by Gottlob Frege in his Grundgesetze der Arithmetik. Naive set theory may refer to several very distinct notions. It may refer to Informal presentation of an axiomatic set theory, e.g. as in Naive Set Theory by Paul Halmos. Early or later versions of Georg Cantor's theory and other informal systems. Decidedly inconsistent theories (whether axiomatic or not), such as a theory of Gottlob Frege that yielded Russell's paradox, and theories of Giuseppe Peano and Richard Dedekind. === Paradoxes === The assumption that any property may be used to form a set, without restriction, leads to paradoxes. One common example is Russell's paradox: there is no set consisting of "all sets that do not contain themselves". Thus consistent systems of (either naive or formal) set theory must include some limitations on the principles which can be used to form sets. === Cantor's theory === Some believe that Georg Cantor's set theory was not actually implicated in the set-theoretic paradoxes (see Frápolli 1991). One difficulty in determining this with certainty is that Cantor did not provide an axiomatization of his system. By 1899, Cantor was aware of some of the paradoxes following from unrestricted interpretation of his theory, for instance Cantor's paradox and the Burali-Forti paradox, and did not believe that they discredited his theory. Cantor's paradox can actually be derived from the above (false) assumption—that any property P(x) may be used to form a set—using for P(x) "x is a cardinal number". Frege explicitly axiomatized a theory in which a formalized version of naive set theory can be interpreted, and it is this formal theory which Bertrand Russell actually addressed when he presented his paradox, not necessarily a theory Cantor—who, as mentioned, was aware of several paradoxes—presumably had in mind. === Axiomatic theories === Axiomatic set theory was developed in response to these early attempts to understand sets, with the goal of determining precisely what operations were allowed and when. === Consistency === A naive set theory is not necessarily inconsistent, if it correctly specifies the sets allowed to be considered. This can be done by the means of definitions, which are implicit axioms. It is possible to state all the axioms explicitly, as in the case of Halmos' Naive Set Theory, which is actually an informal presentation of the usual axiomatic Zermelo–Fraenkel set theory. It is "naive" in that the language and notations are those of ordinary informal mathematics, and in that it does not deal with consistency or completeness of the axiom system. Likewise, an axiomatic set theory is not necessarily consistent: not necessarily free of paradoxes. It follows from Gödel's incompleteness theorems that a sufficiently complicated first-order logic system (which includes most common axiomatic set theories) cannot be proved consistent from within the theory itself – unless it is actually inconsistent. However, the common axiomatic systems are generally believed to be consistent; by their axioms they do exclude some paradoxes, like Russell's paradox. Based on Gödel's theorem, it is just not known – and never can be – if there are no paradoxes at all in these theories or in any sufficiently complicated first-order set theory, again, unless such theories are actually inconsistent. It should be mentioned, however, that results in proof theoretical ordinal analysis are sometimes interpreted as consistency proofs. The term naive set theory is still today also used in some literature to refer to the set theories studied by Frege and Cantor, rather than to the informal counterparts of modern axiomatic set theory. === Utility === The choice between an axiomatic approach and other approaches is largely a matter of convenience. In everyday mathematics the best choice may be informal use of axiomatic set theory. References to particular axioms typically then occur only when demanded by tradition, e.g. the axiom of choice is often mentioned when used. Likewise, formal proofs occur only when warranted by exceptional circumstances. This informal usage of axiomatic set theory can have (depending on notation) precisely the appearance of naive set theory as outlined below. It is considerably easier to read and write (in the formulation of most statements, proofs, and lines of discussion) and is less error-prone than a strictly formal approach. == Sets, membership and equality == In naive set theory, a set is described as a well-defined collection of objects. These objects are called the elements or members of the set. Objects can be anything: numbers, people, other sets, etc. For instance, 4 is a member of the set of all even integers. Clearly, the set of even numbers is infinitely large; there is no requirement that a set be finite. The definition of sets goes back to Georg Cantor. He wrote in his 1915 article Beiträge zur Begründung der transfiniten Mengenlehre: Unter einer 'Menge' verstehen wir jede Zusammenfassung M von bestimmten wohlunterschiedenen Objekten unserer Anschauung oder unseres Denkens (welche die 'Elemente' von M genannt werden) zu einem Ganzen. A set is a gathering together into a whole of definite, distinct objects of our perception or of our thought—which are called elements of the set. === Note on consistency === It does not follow from this definition how sets can be formed, and what operations on sets again will produce a set. The term "well-defined" in "well-defined collection of objects" cannot, by itself, guarantee the consistency and unambiguity of what exactly constitutes and what does not constitute a set. Attempting to achieve this would be the realm of axiomatic set theory or of axiomatic class theory. The problem, in this context, with informally formulated set theories, not derived from (and implying) any particular axiomatic theory, is that there may be several widely differing formalized versions, that have both different sets and different rules for how new sets may be formed, that all conform to the original informal definition. For example, Cantor's verbatim definition allows for considerable freedom in what constitutes a set. On the other hand, it is unlikely that Cantor was particularly interested in sets containing cats and dogs, but rather only in sets containing purely mathematical objects. An example of such a class of sets could be the von Neumann universe. But even when fixing the class of sets under consideration, it is not always clear which rules for set formation are allowed without introducing paradoxes. For the purpose of fixing the discussion below, the term "well-defined" should instead be interpreted as an intention, with either implicit or explicit rules (axioms or definitions), to rule out inconsistencies. The purpose is to keep the often deep and difficult issues of consistency away from the, usually simpler, context at hand. An explicit ruling out of all conceivable inconsistencies (paradoxes) cannot be achieved for an axiomatic set theory anyway, due to Gödel's second incompleteness theorem, so this does not at all hamper the utility of naive set theory as compared to axiomatic set theory in the simple contexts considered below. It merely simplifies the discussion. Consistency is henceforth taken for granted unless explicitly mentioned. === Membership === If x is a member of a set A, then it is also said that x belongs to A, or that x is in A. This is denoted by x ∈ A. The symbol ∈ is a derivation from the lowercase Greek letter epsilon, "ε", introduced by Giuseppe Peano in 1889 and is the first letter of the word ἐστί (means "is"). The symbol ∉ is often used to write x ∉ A, meaning "x is not in A". === Equality === Two sets A and B are defined to be equal when they have precisely the same elements, that is, if every element of A is an element of B and every element of B is an element of A. (See axiom of extensionality.) Thus a set is completely determined by its elements; the description is immaterial. For example, the set with elements 2, 3, and 5 is equal to the set of all prime numbers less than 6. If the sets A and B are equal, this is denoted symbolically as A = B (as usual). === Empty set === The empty set, denoted as ∅ {\displaystyle \varnothing } and sometimes { } {\displaystyle \{\}} , is a set with no members at all. Because a set is determined completely by its elements, there can be only one empty set. (See axiom of empty set.) Although the empty set has no members, it can be a member of other sets. Thus ∅ ≠ { ∅ } {\displaystyle \varnothing \neq \{\varnothing \}} , because the former has no members and the latter has one member. == Specifying sets == The simplest way to describe a set is to list its elements between curly braces (known as defining a set extensionally). Thus {1, 2} denotes the set whose only elements are 1 and 2. (See axiom of pairing.) Note the following points: The order of elements is immaterial; for example, {1, 2} = {2, 1}. Repetition (multiplicity) of elements is irrelevant; for example, {1, 2, 2} = {1, 1, 1, 2} = {1, 2}. (These are consequences of the definition of equality in the previous section.) This notation can be informally abused by saying something like {dogs} to indicate the set of all dogs, but this example would usually be read by mathematicians as "the set containing the single element dogs". An extreme (but correct) example of this notation is {}, which denotes the empty set. The notation {x : P(x)}, or sometimes {x |P(x)}, is used to denote the set containing all objects for which the condition P holds (known as defining a set intensionally). For example, {x | x ∈ R} denotes the set of real numbers, {x | x has blonde hair} denotes the set of everything with blonde hair. This notation is called set-builder notation (or "set comprehension", particularly in the context of Functional programming). Some variants of set builder notation are: {x ∈ A | P(x)} denotes the set of all x that are already members of A such that the condition P holds for x. For example, if Z is the set of integers, then {x ∈ Z | x is even} is the set of all even integers. (See axiom of specification.) {F(x) | x ∈ A} denotes the set of all objects obtained by putting members of the set A into the formula F. For example, {2x | x ∈ Z} is again the set of all even integers. (See axiom of replacement.) {F(x) | P(x)} is the most general form of set builder notation. For example, {x′s owner | x is a dog} is the set of all dog owners. == Subsets == Given two sets A and B, A is a subset of B if every element of A is also an element of B. In particular, each set B is a subset of itself; a subset of B that is not equal to B is called a proper subset. If A is a subset of B, then one can also say that B is a superset of A, that A is contained in B, or that B contains A. In symbols, A ⊆ B means that A is a subset of B, and B ⊇ A means that B is a superset of A. Some authors use the symbols ⊂ and ⊃ for subsets, and others use these symbols only for proper subsets. For clarity, one can explicitly use the symbols ⊊ and ⊋ to indicate non-equality. As an illustration, let R be the set of real numbers, let Z be the set of integers, let O be the set of odd integers, and let P be the set of current or former U.S. Presidents. Then O is a subset of Z, Z is a subset of R, and (hence) O is a subset of R, where in all cases subset may even be read as proper subset. Not all sets are comparable in this way. For example, it is not the case either that R is a subset of P nor that P is a subset of R. It follows immediately from the definition of equality of sets above that, given two sets A and B, A = B if and only if A ⊆ B and B ⊆ A. In fact this is often given as the definition of equality. Usually when trying to prove that two sets are equal, one aims to show these two inclusions. The empty set is a subset of every set (the statement that all elements of the empty set are also members of any set A is vacuously true). The set of all subsets of a given set A is called the power set of A and is denoted by 2 A {\displaystyle 2^{A}} or P ( A ) {\displaystyle P(A)} ; the "P" is sometimes in a script font: ⁠ ℘ ( A ) {\displaystyle \wp (A)} ⁠. If the set A has n elements, then P ( A ) {\displaystyle P(A)} will have 2 n {\displaystyle 2^{n}} elements. == Universal sets and absolute complements == In certain contexts, one may consider all sets under consideration as being subsets of some given universal set. For instance, when investigating properties of the real numbers R (and subsets of R), R may be taken as the universal set. A true universal set is not included in standard set theory (see Paradoxes below), but is included in some non-standard set theories. Given a universal set U and a subset A of U, the complement of A (in U) is defined as AC := {x ∈ U | x ∉ A}. In other words, AC ("A-complement"; sometimes simply A', "A-prime" ) is the set of all members of U which are not members of A. Thus with R, Z and O defined as in the section on subsets, if Z is the universal set, then OC is the set of even integers, while if R is the universal set, then OC is the set of all real numbers that are either even integers or not integers at all. == Unions, intersections, and relative complements == Given two sets A and B, their union is the set consisting of all objects which are elements of A or of B or of both (see axiom of union). It is denoted by A ∪ B. The intersection of A and B is the set of all objects which are both in A and in B. It is denoted by A ∩ B. Finally, the relative complement of B relative to A, also known as the set theoretic difference of A and B, is the set of all objects that belong to A but not to B. It is written as A ∖ B or A − B. Symbolically, these are respectively A ∪ B := {x | (x ∈ A) ∨ (x ∈ B)}; A ∩ B := {x | (x ∈ A) ∧ (x ∈ B)} = {x ∈ A | x ∈ B} = {x ∈ B | x ∈ A}; A ∖ B := {x | (x ∈ A) ∧ ¬ (x ∈ B) } = {x ∈ A | ¬ (x ∈ B)}. The set B doesn't have to be a subset of A for A ∖ B to make sense; this is the difference between the relative complement and the absolute complement (AC = U ∖ A) from the previous section. To illustrate these ideas, let A be the set of left-handed people, and let B be the set of people with blond hair. Then A ∩ B is the set of all left-handed blond-haired people, while A ∪ B is the set of all people who are left-handed or blond-haired or both. A ∖ B, on the other hand, is the set of all people that are left-handed but not blond-haired, while B ∖ A is the set of all people who have blond hair but aren't left-handed. Now let E be the set of all human beings, and let F be the set of all living things over 1000 years old. What is E ∩ F in this case? No living human being is over 1000 years old, so E ∩ F must be the empty set {}. For any set A, the power set P ( A ) {\displaystyle P(A)} is a Boolean algebra under the operations of union and intersection. == Ordered pairs and Cartesian products == Intuitively, an ordered pair is simply a collection of two objects such that one can be distinguished as the first element and the other as the second element, and having the fundamental property that, two ordered pairs are equal if and only if their first elements are equal and their second elements are equal. Formally, an ordered pair with first coordinate a, and second coordinate b, usually denoted by (a, b), can be defined as the set { { a } , { a , b } } . {\displaystyle \{\{a\},\{a,b\}\}.} It follows that, two ordered pairs (a,b) and (c,d) are equal if and only if a = c and b = d. Alternatively, an ordered pair can be formally thought of as a set {a,b} with a total order. (The notation (a, b) is also used to denote an open interval on the real number line, but the context should make it clear which meaning is intended. Otherwise, the notation ]a, b[ may be used to denote the open interval whereas (a, b) is used for the ordered pair). If A and B are sets, then the Cartesian product (or simply product) is defined to be: A × B = {(a,b) | a ∈ A and b ∈ B}. That is, A × B is the set of all ordered pairs whose first coordinate is an element of A and whose second coordinate is an element of B. This definition may be extended to a set A × B × C of ordered triples, and more generally to sets of ordered n-tuples for any positive integer n. It is even possible to define infinite Cartesian products, but this requires a more recondite definition of the product. Cartesian products were first developed by René Descartes in the context of analytic geometry. If R denotes the set of all real numbers, then R2 := R × R represents the Euclidean plane and R3 := R × R × R represents three-dimensional Euclidean space. == Some important sets == There are some ubiquitous sets for which the notation is almost universal. Some of these are listed below. In the list, a, b, and c refer to natural numbers, and r and s are real numbers. Natural numbers are used for counting. A blackboard bold capital N ( N {\displaystyle \mathbb {N} } ) often represents this set. Integers appear as solutions for x in equations like x + a = b. A blackboard bold capital Z ( Z {\displaystyle \mathbb {Z} } ) often represents this set (from the German Zahlen, meaning numbers). Rational numbers appear as solutions to equations like a + bx = c. A blackboard bold capital Q ( Q {\displaystyle \mathbb {Q} } ) often represents this set (for quotient, because R is used for the set of real numbers). Algebraic numbers appear as solutions to polynomial equations (with integer coefficients) and may involve radicals (including i = − 1 {\displaystyle i={\sqrt {-1\,}}} ) and certain other irrational numbers. A Q with an overline ( Q ¯ {\displaystyle {\overline {\mathbb {Q} }}} ) often represents this set. The overline denotes the operation of algebraic closure. Real numbers represent the "real line" and include all numbers that can be approximated by rationals. These numbers may be rational or algebraic but may also be transcendental numbers, which cannot appear as solutions to polynomial equations with rational coefficients. A blackboard bold capital R ( R {\displaystyle \mathbb {R} } ) often represents this set. Complex numbers are sums of a real and an imaginary number: r + s i {\displaystyle r+s\,i} . Here either r {\displaystyle r} or s {\displaystyle s} (or both) can be zero; thus, the set of real numbers and the set of strictly imaginary numbers are subsets of the set of complex numbers, which form an algebraic closure for the set of real numbers, meaning that every polynomial with coefficients in R {\displaystyle \mathbb {R} } has at least one root in this set. A blackboard bold capital C ( C {\displaystyle \mathbb {C} } ) often represents this set. Note that since a number r + s i {\displaystyle r+s\,i} can be identified with a point ( r , s ) {\displaystyle (r,s)} in the plane, C {\displaystyle \mathbb {C} } is basically "the same" as the Cartesian product R × R {\displaystyle \mathbb {R} \times \mathbb {R} } ("the same" meaning that any point in one determines a unique point in the other and for the result of calculations, it doesn't matter which one is used for the calculation, as long as multiplication rule is appropriate for C {\displaystyle \mathbb {C} } ). == Paradoxes in early set theory == The unrestricted formation principle of sets referred to as the axiom schema of unrestricted comprehension, is the source of several early appearing paradoxes: Y = {x | x is an ordinal} led, in the year 1897, to the Burali-Forti paradox, the first published antinomy. Y = {x | x is a cardinal} produced Cantor's paradox in 1897. Y = {x | {} = {}} yielded Cantor's second antinomy in the year 1899. Here the property P is true for all x, whatever x may be, so Y would be a universal set, containing everything. Y = {x | x ∉ x}, i.e. the set of all sets that do not contain themselves as elements, gave Russell's paradox in 1902. If the axiom schema of unrestricted comprehension is weakened to the axiom schema of specification or axiom schema of separation, then all the above paradoxes disappear. There is a corollary. With the axiom schema of separation as an axiom of the theory, it follows, as a theorem of the theory: Or, more spectacularly (Halmos' phrasing): There is no universe. Proof: Suppose that it exists and call it U. Now apply the axiom schema of separation with X = U and for P(x) use x ∉ x. This leads to Russell's paradox again. Hence U cannot exist in this theory. Related to the above constructions is formation of the set Y = {x | (x ∈ x) → {} ≠ {}}, where the statement following the implication certainly is false. It follows, from the definition of Y, using the usual inference rules (and some afterthought when reading the proof in the linked article below) both that Y ∈ Y → {} ≠ {} and Y ∈ Y holds, hence {} ≠ {}. This is Curry's paradox. It is (perhaps surprisingly) not the possibility of x ∈ x that is problematic. It is again the axiom schema of unrestricted comprehension allowing (x ∈ x) → {} ≠ {} for P(x). With the axiom schema of specification instead of unrestricted comprehension, the conclusion Y ∈ Y does not hold and hence {} ≠ {} is not a logical consequence. Nonetheless, the possibility of x ∈ x is often removed explicitly or, e.g. in ZFC, implicitly, by demanding the axiom of regularity to hold. One consequence of it is or, in other words, no set is an element of itself. The axiom schema of separation is simply too weak (while unrestricted comprehension is a very strong axiom—too strong for set theory) to develop set theory with its usual operations and constructions outlined above. The axiom of regularity is of a restrictive nature as well. Therefore, one is led to the formulation of other axioms to guarantee the existence of enough sets to form a set theory. Some of these have been described informally above and many others are possible. Not all conceivable axioms can be combined freely into consistent theories. For example, the axiom of choice of ZFC is incompatible with the conceivable "every set of reals is Lebesgue measurable". The former implies the latter is false. == See also == Algebra of sets Axiomatic set theory Internal set theory List of set identities and relations Set theory Set (mathematics) Partially ordered set == Notes == == References == Bourbaki, N., Elements of the History of Mathematics, John Meldrum (trans.), Springer-Verlag, Berlin, Germany, 1994. Cantor, Georg (1874), "Ueber eine Eigenschaft des Inbegriffes aller reellen algebraischen Zahlen", J. Reine Angew. Math., 1874 (77): 258–262, doi:10.1515/crll.1874.77.258, S2CID 124035379; see also pdf version Devlin, K.J., The Joy of Sets: Fundamentals of Contemporary Set Theory, 2nd edition, Springer-Verlag, New York, NY, 1993. María J. Frápolli|Frápolli, María J., 1991, "Is Cantorian set theory an iterative conception of set?". Modern Logic, v. 1 n. 4, 1991, 302–318. Frege, Gottlob (1893), Grundgesetze der Arithmetik, vol. 1, Jena{{citation}}: CS1 maint: location missing publisher (link) Halmos, Paul (1960). Naive Set Theory. Princeton, NJ: D. Van Nostrand Company. Halmos, Paul (1974). Naive Set Theory (Reprint ed.). New York: Springer-Verlag. ISBN 0-387-90092-6. Halmos, Paul (2011). Naive Set Theory (Paperback ed.). Mansfield Centre, CN: D. Van Nostrand Company. ISBN 978-1-61427-131-4. Jech, Thomas (2002). Set theory, third millennium edition (revised and expanded). Springer. ISBN 3-540-44085-2. Kelley, J.L., General Topology, Van Nostrand Reinhold, New York, NY, 1955. van Heijenoort, J., From Frege to Gödel, A Source Book in Mathematical Logic, 1879-1931, Harvard University Press, Cambridge, MA, 1967. Reprinted with corrections, 1977. ISBN 0-674-32449-8. Meschkowski, Herbert [in German]; Nilson, Winfried (1991), Georg Cantor: Briefe. Edited by the authors., Berlin: Springer, ISBN 3-540-50621-7 Peano, Giuseppe (1889), Arithmetices Principies nova Methoda exposita, Turin{{citation}}: CS1 maint: location missing publisher (link) Zermelo, Ernst (1932), Georg Cantor: Gesammelte Abhandlungen mathematischen und philosophischen Inhalts. Mit erläuternden Anmerkungen sowie mit Ergänzungen aus dem Briefwechsel Cantor-Dedekind. Edited by the author., Berlin: Springer == External links == Beginnings of set theory page at St. Andrews Earliest Known Uses of Some of the Words of Mathematics (S)
Wikipedia/Naive_set_theory
In the area of mathematical logic and computer science known as type theory, a kind is the type of a type constructor or, less commonly, the type of a higher-order type operator (type constructor). A kind system is essentially a simply typed lambda calculus "one level up", endowed with a primitive type, denoted ∗ {\displaystyle *} and called "type", which is the kind of any data type which does not need any type parameters. A kind is sometimes confusingly described as the "type of a (data) type", but it is actually more of an arity specifier. Syntactically, it is natural to consider polymorphic data types to be type constructors, thus non-polymorphic types to be nullary type constructors. But all nullary constructors, thus all monomorphic types, have the same, simplest kind; namely ∗ {\displaystyle *} . Since higher-order type operators are uncommon in programming languages, in most programming practice, kinds are used to distinguish between data types and the types of constructors which are used to implement parametric polymorphism. Kinds appear, either explicitly or implicitly, in languages whose type systems account for parametric polymorphism in a programmatically accessible way, such as C++, Haskell, and Scala. == Examples == ∗ {\displaystyle *} , pronounced "type", is the kind of all data types seen as nullary type constructors, and also called proper types in this context. This normally includes function types in functional programming languages. ∗ → ∗ {\displaystyle *\rightarrow *} is the kind of a unary type constructor, e.g., of a list type constructor. ∗ → ∗ → ∗ {\displaystyle *\rightarrow *\rightarrow *} is the kind of a binary type constructor (via currying), e.g., of a pair type constructor, and also that of a function type constructor (not to be confused with the result of its application, which itself is a function type, thus of kind ∗ {\displaystyle *} ) ( ∗ → ∗ ) → ∗ {\displaystyle (*\rightarrow *)\rightarrow *} is the kind of a higher-order type operator from unary type constructors to proper types. == Kinds in Haskell == Haskell documentation uses the same arrow for both function types and kinds. The kind system of Haskell 98 includes exactly two kinds: ∗ {\displaystyle *} , pronounced "type" is the kind of all data types. k 1 → k 2 {\displaystyle k_{1}\rightarrow k_{2}} is the kind of a unary type constructor, which takes a type of kind k 1 {\displaystyle k_{1}} and produces a type of kind k 2 {\displaystyle k_{2}} . An inhabited type (as proper types are called in Haskell) is a type which has values. For example, ignoring type classes which complicate the picture, 4 is a value of type Int, while [1, 2, 3] is a value of type [Int] (list of Ints). Therefore, Int and [Int] have kind ∗ {\displaystyle *} , but so does any function type, for example Int -> Bool or even Int -> Int -> Bool. A type constructor takes one or more type arguments, and produces a data type when enough arguments are supplied, i.e. it supports partial application thanks to currying. This is how Haskell achieves parametric types. For example, the type [] (list) is a type constructor - it takes a single argument to specify the type of the elements of the list. Hence, [Int] (list of Ints), [Float] (list of Floats) and even [[Int]] (list of lists of Ints) are valid applications of the [] type constructor. Therefore, [] is a type of kind ∗ → ∗ {\displaystyle *\rightarrow *} . Because Int has kind ∗ {\displaystyle *} , applying [] to it results in [Int], of kind ∗ {\displaystyle *} . The 2-tuple constructor (,) has kind ∗ → ∗ → ∗ {\displaystyle *\rightarrow *\rightarrow *} , the 3-tuple constructor (,,) has kind ∗ → ∗ → ∗ → ∗ {\displaystyle *\rightarrow *\rightarrow *\rightarrow *} and so on. === Kind inference === Standard Haskell does not allow polymorphic kinds, in contrast to parametric polymorphism on types, which Haskell supports. For example: the kind of z could be anything, including ∗ {\displaystyle *} , but also ∗ → ∗ {\displaystyle *\rightarrow *} etc. Haskell by default will always infer kinds to be ∗ {\displaystyle *} , unless the type explicitly indicates otherwise (see below). Therefore the type checker will reject this use of Tree: because the kind of [], ∗ → ∗ {\displaystyle *\rightarrow *} does not match the expected kind for z, which is always ∗ {\displaystyle *} . Higher-order type operators are allowed however. For example: has kind ( ∗ → ∗ ) → ∗ → ∗ {\displaystyle (*\rightarrow *)\rightarrow *\rightarrow *} , i.e. unt is expected to be a unary data constructor, which gets applied to its argument, which must be a type, and returns another type. Glasgow Haskell Compiler (GHC) has the extension PolyKinds, which, together with KindSignatures, allows polymorphic kinds. For example: Since GHC 8.0.1, types and kinds are merged. == See also == System F-omega Pure type system == References ==
Wikipedia/Kind_(type_theory)
This article contains a discussion of paradoxes of set theory. As with most mathematical paradoxes, they generally reveal surprising and counter-intuitive mathematical results, rather than actual logical contradictions within modern axiomatic set theory. == Basics == === Cardinal numbers === Set theory as conceived by Georg Cantor assumes the existence of infinite sets. As this assumption cannot be proved from first principles it has been introduced into axiomatic set theory by the axiom of infinity, which asserts the existence of the set N of natural numbers. Every infinite set which can be enumerated by natural numbers is the same size (cardinality) as N, and is said to be countable. Examples of countably infinite sets are the natural numbers, the even numbers, the prime numbers, and also all the rational numbers, i.e., the fractions. These sets have in common the cardinal number |N| = ℵ 0 {\displaystyle \aleph _{0}} (aleph-nought), a number greater than every natural number. Cardinal numbers can be defined as follows. Define two sets to have the same size by: there exists a bijection between the two sets (a one-to-one correspondence between the elements). Then a cardinal number is, by definition, a class consisting of all sets of the same size. To have the same size is an equivalence relation, and the cardinal numbers are the equivalence classes. === Ordinal numbers === Besides the cardinality, which describes the size of a set, ordered sets also form a subject of set theory. The axiom of choice guarantees that every set can be well-ordered, which means that a total order can be imposed on its elements such that every nonempty subset has a first element with respect to that order. The order of a well-ordered set is described by an ordinal number. For instance, 3 is the ordinal number of the set {0, 1, 2} with the usual order 0 < 1 < 2; and ω is the ordinal number of the set of all natural numbers ordered the usual way. Neglecting the order, we are left with the cardinal number |N| = |ω| = ℵ 0 {\displaystyle \aleph _{0}} . Ordinal numbers can be defined with the same method used for cardinal numbers. Define two well-ordered sets to have the same order type by: there exists a bijection between the two sets respecting the order: smaller elements are mapped to smaller elements. Then an ordinal number is, by definition, a class consisting of all well-ordered sets of the same order type. To have the same order type is an equivalence relation on the class of well-ordered sets, and the ordinal numbers are the equivalence classes. Two sets of the same order type have the same cardinality. The converse is not true in general for infinite sets: it is possible to impose different well-orderings on the set of natural numbers that give rise to different ordinal numbers. There is a natural ordering on the ordinals, which is itself a well-ordering. Given any ordinal α, one can consider the set of all ordinals less than α. This set turns out to have ordinal number α. This observation is used for a different way of introducing the ordinals, in which an ordinal is equated with the set of all smaller ordinals. This form of ordinal number is thus a canonical representative of the earlier form of equivalence class. === Power sets === All subsets of a set S (all possible choices of its elements) form the power set P(S). Georg Cantor proved that the power set is always larger than the set, i.e., |P(S)| > |S|. A special case of Cantor's theorem is that the set of all real numbers R cannot be enumerated by natural numbers, that is, R is uncountable: |R| > |N|. == Paradoxes of the infinite sets == Instead of relying on ambiguous descriptions such as "that which cannot be enlarged" or "increasing without bound", set theory provides definitions for the term infinite set to give an unambiguous meaning to phrases such as "the set of all natural numbers is infinite". Just as for finite sets, the theory makes further definitions which allow us to consistently compare two infinite sets as regards whether one set is "larger than", "smaller than", or "the same size as" the other. But not every intuition regarding the size of finite sets applies to the size of infinite sets, leading to various apparently paradoxical results regarding enumeration, size, measure and order. === Paradoxes of enumeration === Before set theory was introduced, the notion of the size of a set had been problematic. It had been discussed by Galileo Galilei and Bernard Bolzano, among others. Are there as many natural numbers as squares of natural numbers when measured by the method of enumeration? The answer is yes, because for every natural number n there is a square number n2, and likewise the other way around. The answer is no, because the squares are a proper subset of the naturals: every square is a natural number but there are natural numbers, like 2, which are not squares of natural numbers. The issue can be settled by defining the size of a set in terms of its cardinality. Since a bijection exists between the two sets, they have the same cardinality by definition. Hilbert's paradox of the Grand Hotel illustrates more paradoxes of enumeration. === Je le vois, mais je ne crois pas === "I see it but I don't believe," Cantor wrote to Richard Dedekind after proving that the set of points of a square has the same cardinality as that of the points on just an edge of the square: the cardinality of the continuum. This demonstrates that the "size" of sets as defined by cardinality alone is not the only useful way of comparing sets. Measure theory provides a more nuanced theory of size that conforms to our intuition that length and area are incompatible measures of size. The evidence strongly suggests that Cantor was quite confident in the result itself and that his comment to Dedekind refers instead to his then-still-lingering concerns about the validity of his proof of it. Nevertheless, Cantor's remark would also serve nicely to express the surprise that so many mathematicians after him have experienced on first encountering a result that is so counter-intuitive. === Paradoxes of well-ordering === In 1904 Ernst Zermelo proved by means of the axiom of choice (which was introduced for this reason) that every set can be well-ordered. In 1963 Paul J. Cohen showed that in Zermelo–Fraenkel set theory without the axiom of choice it is not possible to prove the existence of a well-ordering of the real numbers. However, the ability to well order any set allows certain constructions to be performed that have been called paradoxical. One example is the Banach–Tarski paradox, a theorem widely considered to be nonintuitive. It states that it is possible to decompose a ball of a fixed radius into a finite number of pieces and then move and reassemble those pieces by ordinary translations and rotations (with no scaling) to obtain two copies from the one original copy. The construction of these pieces requires the axiom of choice; the pieces are not simple regions of the ball, but complicated subsets. == Paradoxes of the Supertask == In set theory, an infinite set is not considered to be created by some mathematical process such as "adding one element" that is then carried out "an infinite number of times". Instead, a particular infinite set (such as the set of all natural numbers) is said to already exist, "by fiat", as an assumption or an axiom. Given this infinite set, other infinite sets are then proven to exist as well, as a logical consequence. But it is still a natural philosophical question to contemplate some physical action that actually completes after an infinite number of discrete steps; and the interpretation of this question using set theory gives rise to the paradoxes of the supertask. === The diary of Tristram Shandy === Tristram Shandy, the hero of a novel by Laurence Sterne, writes his autobiography so conscientiously that it takes him one year to lay down the events of one day. If he is mortal he can never terminate; but if he lived forever then no part of his diary would remain unwritten, for to each day of his life a year devoted to that day's description would correspond. === The Ross-Littlewood paradox === An increased version of this type of paradox shifts the infinitely remote finish to a finite time. Fill a huge reservoir with balls enumerated by numbers 1 to 10 and take off ball number 1. Then add the balls enumerated by numbers 11 to 20 and take off number 2. Continue to add balls enumerated by numbers 10n - 9 to 10n and to remove ball number n for all natural numbers n = 3, 4, 5, .... Let the first transaction last half an hour, let the second transaction last quarter an hour, and so on, so that all transactions are finished after one hour. Obviously the set of balls in the reservoir increases without bound. Nevertheless, after one hour the reservoir is empty because for every ball the time of removal is known. The paradox is further increased by the significance of the removal sequence. If the balls are not removed in the sequence 1, 2, 3, ... but in the sequence 1, 11, 21, ... after one hour infinitely many balls populate the reservoir, although the same amount of material as before has been moved. == Paradoxes of proof and definability == For all its usefulness in resolving questions regarding infinite sets, naive set theory has some fatal flaws. In particular, it is prey to logical paradoxes such as those exposed by Russell's paradox. The discovery of these paradoxes revealed that not all sets which can be described in the language of naive set theory can actually be said to exist without creating a contradiction. The 20th century saw a resolution to these paradoxes in the development of the various axiomatizations of set theories such as ZFC and NBG in common use today. However, the gap between the very formalized and symbolic language of these theories and our typical informal use of mathematical language results in various paradoxical situations, as well as the philosophical question of exactly what it is that such formal systems actually propose to be talking about. === Early paradoxes: the set of all sets === In 1897 the Italian mathematician Cesare Burali-Forti discovered that there is no set containing all ordinal numbers. As every ordinal number is defined by a set of smaller ordinal numbers, the well-ordered set Ω of all ordinal numbers (if it exists) fits the definition and is itself an ordinal. On the other hand, no ordinal number can contain itself, so Ω cannot be an ordinal. Therefore, the set of all ordinal numbers cannot exist. By the end of the 19th century Cantor was aware of the non-existence of the set of all cardinal numbers and the set of all ordinal numbers. In letters to David Hilbert and Richard Dedekind he wrote about inconsistent sets, the elements of which cannot be thought of as being all together, and he used this result to prove that every consistent set has a cardinal number. After all this, the version of the "set of all sets" paradox conceived by Bertrand Russell in 1903 led to a serious crisis in set theory. Russell recognized that the statement x = x is true for every set, and thus the set of all sets is defined by {x | x = x}. In 1906 he constructed several paradox sets, the most famous of which is the set of all sets which do not contain themselves. Russell himself explained this abstract idea by means of some very concrete pictures. One example, known as the Barber paradox, states: The male barber who shaves all and only men who do not shave themselves has to shave himself only if he does not shave himself. There are close similarities between Russell's paradox in set theory and the Grelling–Nelson paradox, which demonstrates a paradox in natural language. === Paradoxes by change of language === ==== König's paradox ==== In 1905, the Hungarian mathematician Julius König published a paradox based on the fact that there are only countably many finite definitions. If we imagine the real numbers as a well-ordered set, those real numbers which can be finitely defined form a subset. Hence in this well-order there should be a first real number that is not finitely definable. This is paradoxical, because this real number has just been finitely defined by the last sentence. This leads to a contradiction in naive set theory. This paradox is avoided in axiomatic set theory. Although it is possible to represent a proposition about a set as a set, by a system of codes known as Gödel numbers, there is no formula φ ( a , x ) {\displaystyle \varphi (a,x)} in the language of set theory which holds exactly when a {\displaystyle a} is a code for a finite proposition about a set, x {\displaystyle x} is a set, and a {\displaystyle a} holds for x {\displaystyle x} . This result is known as Tarski's indefinability theorem; it applies to a wide class of formal systems including all commonly studied axiomatizations of set theory. ==== Richard's paradox ==== In the same year the French mathematician Jules Richard used a variant of Cantor's diagonal method to obtain another contradiction in naive set theory. Consider the set A of all finite agglomerations of words. The set E of all finite definitions of real numbers is a subset of A. As A is countable, so is E. Let p be the nth decimal of the nth real number defined by the set E; we form a number N having zero for the integral part and p + 1 for the nth decimal if p is not equal either to 8 or 9, and unity if p is equal to 8 or 9. This number N is not defined by the set E because it differs from any finitely defined real number, namely from the nth number by the nth digit. But N has been defined by a finite number of words in this paragraph. It should therefore be in the set E. That is a contradiction. As with König's paradox, this paradox cannot be formalized in axiomatic set theory because it requires the ability to tell whether a description applies to a particular set (or, equivalently, to tell whether a formula is actually the definition of a single set). === Paradox of Löwenheim and Skolem === Based upon work of the German mathematician Leopold Löwenheim (1915) the Norwegian logician Thoralf Skolem showed in 1922 that every consistent theory of first-order predicate calculus, such as set theory, has an at most countable model. However, Cantor's theorem proves that there are uncountable sets. The root of this seeming paradox is that the countability or noncountability of a set is not always absolute, but can depend on the model in which the cardinality is measured. It is possible for a set to be uncountable in one model of set theory but countable in a larger model (because the bijections that establish countability are in the larger model but not the smaller one). == See also == Proof of impossibility Berry paradox == Notes == == References == G. Cantor: Gesammelte Abhandlungen mathematischen und philosophischen Inhalts, E. Zermelo (Ed.), Olms, Hildesheim 1966. H. Meschkowski, W. Nilson: Georg Cantor - Briefe, Springer, Berlin 1991. A. Fraenkel: Einleitung in die Mengenlehre, Springer, Berlin 1923. A. A. Fraenkel, A. Levy: Abstract Set Theory, North Holland, Amsterdam 1976. F. Hausdorff: Grundzüge der Mengenlehre, Chelsea, New York 1965. B. Russell: The principles of mathematics I, Cambridge 1903. B. Russell: On some difficulties in the theory of transfinite numbers and order types, Proc. London Math. Soc. (2) 4 (1907) 29-53. P. J. Cohen: Set Theory and the Continuum Hypothesis, Benjamin, New York 1966. S. Wagon: The Banach–Tarski Paradox, Cambridge University Press, Cambridge 1985. A. N. Whitehead, B. Russell: Principia Mathematica I, Cambridge Univ. Press, Cambridge 1910, p. 64. E. Zermelo: Neuer Beweis für die Möglichkeit einer Wohlordnung, Math. Ann. 65 (1908) p. 107-128. == External links == Principia Mathematica Definability paradoxes by Timothy Gowers "Russell's Paradox". Internet Encyclopedia of Philosophy. "Russell-Myhill Paradox". Internet Encyclopedia of Philosophy.
Wikipedia/Paradoxes_of_set_theory
Networking hardware, also known as network equipment or computer networking devices, are electronic devices that are required for communication and interaction between devices on a computer network. Specifically, they mediate data transmission in a computer network. Units which are the last receiver or generate data are called hosts, end systems or data terminal equipment. == Range == Networking devices includes a broad range of equipment which can be classified as core network components which interconnect other network components, hybrid components which can be found in the core or border of a network and hardware or software components which typically sit on the connection point of different networks. One of the most common types of networking hardware today is a copper-based Ethernet adapter which is a standard inclusion on most modern computer systems. Wireless networking has become increasingly popular, especially for portable and handheld devices. Other networking hardware used in computers includes data center equipment (such as file servers, database servers and storage areas), network services (such as DNS, DHCP, email, etc.) as well as devices which assure content delivery. Taking a wider view, mobile phones, tablet computers and devices associated with the internet of things may also be considered networking hardware. As technology advances and IP-based networks are integrated into building infrastructure and household utilities, network hardware will become an ambiguous term owing to the vastly increasing number of network-capable endpoints. == Specific devices == Network hardware can be classified by its location and role in the network. === Core === Core network components interconnect other network components. Gateway: an interface providing a compatibility between networks by converting transmission speeds, protocols, codes, or security measures. Router: a networking device that forwards data packets between computer networks. Routers perform the "traffic directing" functions on the Internet. A data packet is typically forwarded from one router to another through the networks that constitute the internetwork until it reaches its destination node. It works on OSI layer 3. Switch: a multi-port device that connects devices together at the same or different speeds on a computer network, by using packet switching to receive, process and forward data to the destination device. Unlike less advanced network hubs, a network switch forwards data only to one or multiple devices that need to receive it, rather than broadcasting the same data out of each of its ports. It works on OSI layer 2. Bridge: a device that connects multiple network segments. It works on OSI layers 1 and 2. Repeater: an electronic device that receives a signal and retransmits it at a higher level or higher power, or onto the other side of an obstruction, so that the signal can cover longer distances. Repeater hub: for connecting multiple Ethernet devices together at the same speed, making them act as a single network segment. It has multiple input/output (I/O) ports, in which a signal introduced at the input of any port appears at the output of every port except the original incoming. A hub works at the physical layer (layer 1) of the OSI model and all devices form a single collision domain. Repeater hubs also participate in collision detection, forwarding a jam signal to all ports if they detect a collision. Hubs are now largely obsolete, having been replaced by network switches except in very old installations or specialized applications. Wireless access point Structured cabling === Hybrid === Hybrid components can be found in the core or border of a network. Multilayer switch: a switch that, in addition to switching on OSI layer 2, provides functionality at higher protocol layers. Protocol converter: a hardware device that converts between two different types of transmission, for interoperation. Bridge router (brouter): a device that works as a bridge and as a router. The brouter routes packets for known protocols and simply forwards all other packets as a bridge would. === Border === Hardware or software components which typically sit on the connection point of different networks (for example, between an internal network and an external network) include: Proxy server: computer network service which allows clients to make indirect network connections to other network services. Firewall: a piece of hardware or software put on the network to prevent some communications forbidden by the network policy. A firewall typically establishes a barrier between a trusted, secure internal network and another outside network, such as the Internet, that is assumed to not be secure or trusted. Network address translator (NAT): network service (provided as hardware or as software) that converts internal to external network addresses and vice versa. Residential gateway: interface between a WAN connection to an Internet service provider and the home network. Terminal server: connects devices with a serial port to a local area network. === End stations === Other hardware devices used for establishing networks or dial-up connections include: Network interface controller (NIC): a device connecting a computer to a computer network. Wireless network interface controller: a device connecting the attached computer to a radio-based computer network. Modem: device that modulates an analog "carrier" signal (such as sound) to encode digital information, and that also demodulates such a carrier signal to decode the transmitted information. Used (for example) when a computer communicates with another computer over a telephone network. ISDN terminal adapter (TA): a specialized gateway for ISDN. Line driver: a device to increase transmission distance by amplifying the signal; used in base-band networks only. == See also == == References == == External links == USF Explanation of network hardware
Wikipedia/Networking_hardware
In mathematics, the successor function or successor operation sends a natural number to the next one. The successor function is denoted by S, so S(n) = n + 1. For example, S(1) = 2 and S(2) = 3. The successor function is one of the basic components used to build a primitive recursive function. Successor operations are also known as zeration in the context of a zeroth hyperoperation: H0(a, b) = 1 + b. In this context, the extension of zeration is addition, which is defined as repeated succession. == Overview == The successor function is part of the formal language used to state the Peano axioms, which formalise the structure of the natural numbers. In this formalisation, the successor function is a primitive operation on the natural numbers, in terms of which the standard natural numbers and addition are defined. For example, 1 is defined to be S(0), and addition on natural numbers is defined recursively by: This can be used to compute the addition of any two natural numbers. For example, 5 + 2 = 5 + S(1) = S(5 + 1) = S(5 + S(0)) = S(S(5 + 0)) = S(S(5)) = S(6) = 7. Several constructions of the natural numbers within set theory have been proposed. For example, John von Neumann constructs the number 0 as the empty set {}, and the successor of n, S(n), as the set n ∪ {n}. The axiom of infinity then guarantees the existence of a set that contains 0 and is closed with respect to S. The smallest such set is denoted by N, and its members are called natural numbers. The successor function is the level-0 foundation of the infinite Grzegorczyk hierarchy of hyperoperations, used to build addition, multiplication, exponentiation, tetration, etc. It was studied in 1986 in an investigation involving generalization of the pattern for hyperoperations. It is also one of the primitive functions used in the characterization of computability by recursive functions. == See also == Successor ordinal Successor cardinal Increment and decrement operators Sequence == References == Paul R. Halmos (1968). Naive Set Theory. Nostrand.
Wikipedia/Successor_function
The Journal of Functional Programming is a peer-reviewed scientific journal covering the design, implementation, and application of functional programming languages, spanning the range from mathematical theory to industrial practice. Topics covered include functional languages and extensions, implementation techniques, reasoning and proof, program transformation and synthesis, type systems, type theory, language-based security, memory management, parallelism and applications. The journal is of interest to computer scientists, software engineers, programming language researchers, and mathematicians interested in the logical foundations of programming. Philip Wadler was editor-in-chief from 1990 to 2004. The journal is indexed in Zentralblatt MATH. As of 2022, the journal is published as open access: the journal articles are available online without a subscription. Author's institutions are expected to cover the journal costs: as of 2022, the article processing charge is GBP 1,250 per article. == See also == International Conference on Functional Programming Higher-Order and Symbolic Computation == References == == External links == Official website
Wikipedia/Journal_of_Functional_Programming
In mathematical logic, a theory is categorical if it has exactly one model (up to isomorphism). Such a theory can be viewed as defining its model, uniquely characterizing the model's structure. In first-order logic, only theories with a finite model can be categorical. Higher-order logic contains categorical theories with an infinite model. For example, the second-order Peano axioms are categorical, having a unique model whose domain is the set of natural numbers N . {\displaystyle \mathbb {N} .} In model theory, the notion of a categorical theory is refined with respect to cardinality. A theory is κ-categorical (or categorical in κ) if it has exactly one model of cardinality κ up to isomorphism. Morley's categoricity theorem is a theorem of Michael D. Morley (1965) stating that if a first-order theory in a countable language is categorical in some uncountable cardinality, then it is categorical in all uncountable cardinalities. Saharon Shelah (1974) extended Morley's theorem to uncountable languages: if the language has cardinality κ and a theory is categorical in some uncountable cardinal greater than or equal to κ then it is categorical in all cardinalities greater than κ. == History and motivation == Oswald Veblen in 1904 defined a theory to be categorical if all of its models are isomorphic. It follows from the definition above and the Löwenheim–Skolem theorem that any first-order theory with a model of infinite cardinality cannot be categorical. One is then immediately led to the more subtle notion of κ-categoricity, which asks: for which cardinals κ is there exactly one model of cardinality κ of the given theory T up to isomorphism? This is a deep question and significant progress was only made in 1954 when Jerzy Łoś noticed that, at least for complete theories T over countable languages with at least one infinite model, he could only find three ways for T to be κ-categorical at some κ: T is totally categorical, i.e. T is κ-categorical for all infinite cardinals κ. T is uncountably categorical, i.e. T is κ-categorical if and only if κ is an uncountable cardinal. T is countably categorical, i.e. T is κ-categorical if and only if κ is a countable cardinal. In other words, he observed that, in all the cases he could think of, κ-categoricity at any one uncountable cardinal implied κ-categoricity at all other uncountable cardinals. This observation spurred a great amount of research into the 1960s, eventually culminating in Michael Morley's famous result that these are in fact the only possibilities. The theory was subsequently extended and refined by Saharon Shelah in the 1970s and beyond, leading to stability theory and Shelah's more general programme of classification theory. == Examples == There are not many natural examples of theories that are categorical in some uncountable cardinal. The known examples include: Pure identity theory (with no functions, constants, predicates other than "=", or axioms). The classic example is the theory of algebraically closed fields of a given characteristic. Categoricity does not say that all algebraically closed fields of characteristic 0 as large as the complex numbers C are the same as C; it only asserts that they are isomorphic as fields to C. It follows that although the completed p-adic closures Cp are all isomorphic as fields to C, they may (and in fact do) have completely different topological and analytic properties. The theory of algebraically closed fields of a given characteristic is not categorical in ω (the countable infinite cardinal); there are models of transcendence degree 0, 1, 2, ..., ω. Vector spaces over a given countable field. This includes abelian groups of given prime exponent (essentially the same as vector spaces over a finite field) and divisible torsion-free abelian groups (essentially the same as vector spaces over the rationals). The theory of the set of natural numbers with a successor function. There are also examples of theories that are categorical in ω but not categorical in uncountable cardinals. The simplest example is the theory of an equivalence relation with exactly two equivalence classes, both of which are infinite. Another example is the theory of dense linear orders with no endpoints; Cantor proved that any such countable linear order is isomorphic to the rational numbers: see Cantor's isomorphism theorem. == Properties == Every categorical theory is complete. However, the converse does not hold. Any theory T categorical in some infinite cardinal κ is very close to being complete. More precisely, the Łoś–Vaught test states that if a satisfiable theory has no finite models and is categorical in some infinite cardinal κ at least equal to the cardinality of its language, then the theory is complete. The reason is that all infinite models are first-order equivalent to some model of cardinal κ by the Löwenheim–Skolem theorem, and so are all equivalent as the theory is categorical in κ. Therefore, the theory is complete as all models are equivalent. The assumption that the theory have no finite models is necessary. == See also == Spectrum of a theory == Notes == == References == Chang, Chen Chung; Keisler, H. Jerome (1990) [1973], Model Theory, Studies in Logic and the Foundations of Mathematics, Elsevier, ISBN 978-0-444-88054-3 Corcoran, John (1980), "Categoricity", History and Philosophy of Logic, 1 (1–2): 187–207, doi:10.1080/01445348008837010 Hodges, Wilfrid, "First-order Model Theory", The Stanford Encyclopedia of Philosophy (Summer 2005 Edition), Edward N. Zalta (ed.). Marker, David (2002), Model theory: An introduction, Graduate Texts in Mathematics, vol. 217, New York, NY: Springer-Verlag, ISBN 0-387-98760-6, Zbl 1003.03034 Monk, J. Donald (1976), Mathematical Logic, Springer-Verlag, doi:10.1007/978-1-4684-9452-5, ISBN 978-1-4684-9454-9 Morley, Michael (1965), "Categoricity in Power", Transactions of the American Mathematical Society, 114 (2), American Mathematical Society, Vol. 114, No. 2: 514–538, doi:10.2307/1994188, ISSN 0002-9947, JSTOR 1994188 Palyutin, E.A. (2001) [1994], "Categoricity in cardinality", Encyclopedia of Mathematics, EMS Press Shelah, Saharon (1974), "Categoricity of uncountable theories", Proceedings of the Tarski Symposium (Proc. Sympos. Pure Math., Vol. XXV, Univ. of California, Berkeley, Calif., 1971), Proceedings of Symposia in Pure Mathematics, vol. 25, Providence, R.I.: American Mathematical Society, pp. 187–203, doi:10.1090/pspum/025/0373874, ISBN 9780821814253, MR 0373874 Shelah, Saharon (1990) [1978], Classification theory and the number of nonisomorphic models, Studies in Logic and the Foundations of Mathematics (2nd ed.), Elsevier, ISBN 978-0-444-70260-9 (IX, 1.19, pg.49) Veblen, Oswald (1904), "A System of Axioms for Geometry", Transactions of the American Mathematical Society, 5 (3), American Mathematical Society, Vol. 5, No. 3: 343–384, doi:10.2307/1986462, ISSN 0002-9947, JSTOR 1986462
Wikipedia/Categorical_theory
Concurrency refers to the ability of a system to execute multiple tasks through simultaneous execution or time-sharing (context switching), sharing resources and managing interactions. Concurrency improves responsiveness, throughput, and scalability in modern computing, including: Operating systems and embedded systems Distributed systems, parallel computing, and high-performance computing Database systems, web applications, and cloud computing == Related concepts == Concurrency is a broader concept that encompasses several related ideas, including: Parallelism (simultaneous execution on multiple processing units). Parallelism executes tasks independently on multiple CPU cores. Concurrency allows for multiple threads of control at the program level, which can use parallelism or time-slicing to perform these tasks. Programs may exhibit parallelism only, concurrency only, both parallelism and concurrency, neither. Multi-threading and multi-processing (shared system resources) Synchronization (coordinating access to shared resources) Coordination (managing interactions between concurrent tasks) Concurrency Control (ensuring data consistency and integrity) Inter-process Communication (IPC, facilitating information exchange) == Issues == Because computations in a concurrent system can interact with each other while being executed, the number of possible execution paths in the system can be extremely large, and the resulting outcome can be indeterminate. Concurrent use of shared resources can be a source of indeterminacy leading to issues such as deadlocks, and resource starvation. Design of concurrent systems often entails finding reliable techniques for coordinating their execution, data exchange, memory allocation, and execution scheduling to minimize response time and maximise throughput. == Theory == Concurrency theory has been an active field of research in theoretical computer science. One of the first proposals was Carl Adam Petri's seminal work on Petri nets in the early 1960s. In the years since, a wide variety of formalisms have been developed for modeling and reasoning about concurrency. === Models === A number of formalisms for modeling and understanding concurrent systems have been developed, including: The parallel random-access machine The actor model Computational bridging models such as the bulk synchronous parallel (BSP) model Petri nets Process calculi Calculus of communicating systems (CCS) Communicating sequential processes (CSP) model π-calculus Tuple spaces, e.g., Linda Simple Concurrent Object-Oriented Programming (SCOOP) Reo Coordination Language Trace monoids Some of these models of concurrency are primarily intended to support reasoning and specification, while others can be used through the entire development cycle, including design, implementation, proof, testing and simulation of concurrent systems. Some of these are based on message passing, while others have different mechanisms for concurrency. The proliferation of different models of concurrency has motivated some researchers to develop ways to unify these different theoretical models. For example, Lee and Sangiovanni-Vincentelli have demonstrated that a so-called "tagged-signal" model can be used to provide a common framework for defining the denotational semantics of a variety of different models of concurrency, while Nielsen, Sassone, and Winskel have demonstrated that category theory can be used to provide a similar unified understanding of different models. The Concurrency Representation Theorem in the actor model provides a fairly general way to represent concurrent systems that are closed in the sense that they do not receive communications from outside. (Other concurrency systems, e.g., process calculi can be modeled in the actor model using a two-phase commit protocol.) The mathematical denotation denoted by a closed system S is constructed increasingly better approximations from an initial behavior called ⊥S using a behavior approximating function progressionS to construct a denotation (meaning ) for S as follows: DenoteS ≡ ⊔i∈ω progressionSi(⊥S) In this way, S can be mathematically characterized in terms of all its possible behaviors. === Logics === Various types of temporal logic can be used to help reason about concurrent systems. Some of these logics, such as linear temporal logic and computation tree logic, allow assertions to be made about the sequences of states that a concurrent system can pass through. Others, such as action computational tree logic, Hennessy–Milner logic, and Lamport's temporal logic of actions, build their assertions from sequences of actions (changes in state). The principal application of these logics is in writing specifications for concurrent systems. == Practice == Concurrent programming encompasses programming languages and algorithms used to implement concurrent systems. Concurrent programming is usually considered to be more general than parallel programming because it can involve arbitrary and dynamic patterns of communication and interaction, whereas parallel systems generally have a predefined and well-structured communications pattern. The base goals of concurrent programming include correctness, performance and robustness. Concurrent systems such as Operating systems and Database management systems are generally designed to operate indefinitely, including automatic recovery from failure, and not terminate unexpectedly (see Concurrency control). Some concurrent systems implement a form of transparent concurrency, in which concurrent computational entities may compete for and share a single resource, but the complexities of this competition and sharing are shielded from the programmer. Because they use shared resources, concurrent systems in general require the inclusion of some kind of arbiter somewhere in their implementation (often in the underlying hardware), to control access to those resources. The use of arbiters introduces the possibility of indeterminacy in concurrent computation which has major implications for practice including correctness and performance. For example, arbitration introduces unbounded nondeterminism which raises issues with model checking because it causes explosion in the state space and can even cause models to have an infinite number of states. Some concurrent programming models include coprocesses and deterministic concurrency. In these models, threads of control explicitly yield their timeslices, either to the system or to another process. == See also == Dining philosophers problem Chu space Client–server network nodes Clojure Cluster nodes Concurrency control Concurrent computing Concurrent object-oriented programming Concurrency pattern Construction and Analysis of Distributed Processes (CADP) D (programming language) Distributed system Elixir (programming language) Erlang (programming language) Go (programming language) Gordon Pask International Conference on Concurrency Theory (CONCUR) OpenMP Parallel computing Partitioned global address space Pony (programming language) Processes Ptolemy Project Rust (programming language) Sheaf (mathematics) Threads X10 (programming language) Structured concurrency == References == == Further reading == Lynch, Nancy A. (1996). Distributed Algorithms. Morgan Kaufmann. ISBN 978-1-55860-348-6. Tanenbaum, Andrew S.; Van Steen, Maarten (2002). Distributed Systems: Principles and Paradigms. Prentice Hall. ISBN 978-0-13-088893-8. Kurki-Suonio, Reino (2005). A Practical Theory of Reactive Systems. Springer. ISBN 978-3-540-23342-8. Garg, Vijay K. (2002). Elements of Distributed Computing. Wiley-IEEE Press. ISBN 978-0-471-03600-5. Magee, Jeff; Kramer, Jeff (2006). Concurrency: State Models and Java Programming. Wiley. ISBN 978-0-470-09355-9. Distefano, S., & Bruneo, D. (2015). Quantitative assessments of distributed systems: Methodologies and techniques (1st ed.). Somerset: John Wiley & Sons Inc.ISBN 9781119131144 Bhattacharyya, S. S. (2013;2014;). Handbook of signal processing systems (Second;2;2nd 2013; ed.). New York, NY: Springer.10.1007/978-1-4614-6859-2 ISBN 9781461468592 Wolter, K. (2012;2014;). Resilience assessment and evaluation of computing systems (1. Aufl.;1; ed.). London;Berlin;: Springer. ISBN 9783642290329 == External links == Process Algebra Diary - Prof. Luca Aceto's blog on Concurrency Theory Concurrent Systems at The WWW Virtual Library Concurrency patterns presentation given at scaleconf
Wikipedia/Concurrency_(computer_science)
See also Naive set theory for the mathematical topic. Naive Set Theory is a mathematics textbook by Paul Halmos providing an undergraduate introduction to set theory. Originally published by Van Nostrand in 1960, it was reprinted in the Springer-Verlag Undergraduate Texts in Mathematics series in 1974. It is on the list of 173 books essential for undergraduate math libraries. While the title states that the set theory presented is 'naive', which is usually taken to mean without formal axioms, the book does introduce a system of axioms equivalent to that of ZFC set theory except the Axiom of foundation. It also gives correct and rigorous definitions for many basic concepts. Where it differs from a "true" axiomatic set theory book is its character: there are no discussions of axiomatic minutiae, and there is next to nothing about advanced topics such as large cardinals or forcing. Instead, it tries to be intelligible to someone who has never thought about set theory before. Halmos later stated that it was the fastest book he wrote, taking about six months, and that the book "wrote itself". == Axioms used in the book == The statements of the axioms given below are as they appear in the book, with section references, and with explanatory commentary on each one. The "principal primitive (undefined) concept of belonging" (that is, set membership) is the starting point, where " x {\displaystyle x} belongs to A {\displaystyle A} " is written in the usual notation as x ∈ A {\displaystyle x\in A} . Here x {\displaystyle x} and A {\displaystyle A} are both sets, with the notational distinction of upper/lower case a purely stylistic choice. The axioms govern the properties of this relation between sets. 1. Axiom of Extension (Section 1): two sets are equal if and only if they have the same elements. This guarantees that the membership and (logical) equality relations interact appropriately. 2. Axiom of Specification (Section 2): To every set A {\displaystyle A} and every condition S ( x ) {\displaystyle S(x)} there corresponds a set B {\displaystyle B} whose elements are precisely those elements of A {\displaystyle A} for which S ( x ) {\displaystyle S(x)} holds. This is more properly an axiom schema (that is, each condition S ( x ) {\displaystyle S(x)} gives rise to an axiom). "Condition" here means a "sentence" in which the variable x {\displaystyle x} (ranging over all sets) is a free variable. "Sentences" are defined as being built up from smaller sentences using first order logical operations (and, or, not), including quantifiers ("there exists", "for all"), and with atomic (i.e. basic starting) sentences x ∈ A {\displaystyle x\in A} and A = B {\displaystyle A=B} . This schema is used in 4.-7. below to cut down the set that is stated to exist to the set containing precisely the intended elements, rather than some larger set with extraneous elements. For example, the axiom of pairing applied to the sets A {\displaystyle A} and B {\displaystyle B} only guarantees there is some set X {\displaystyle X} such that A ∈ X {\displaystyle A\in X} and B ∈ X {\displaystyle B\in X} . Specification can be used to then construct the set { A , B } {\displaystyle \{A,B\}} with just those elements. 3. Set existence (Section 3): There exists a set. Not specified as an named axiom, but instead stated to be "officially assumed". This assumption is not necessary once the axiom of infinity is adopted later, which also specifies the existence of a set (with a certain property). The existence of any set at all is used to show the empty set exists using the axiom of specification. 4. Axiom of pairing (Section 3): For any two sets there exists a set that they both belong to. This is used to show that the singleton { A } {\displaystyle \{A\}} containing a given set A {\displaystyle A} exists. 5. Axiom of unions (Section 4): For every collection of sets there exists a set that contains all the elements that belong to at least one set of the given collection. In Section 1 Halmos writes that "to avoid terminological monotony, we shall sometimes say collection instead of set." Hence this axiom is equivalent to the usual form of the axiom of unions (given the axiom of specification, as noted above). From the axioms so far Halmos gives a construction of intersections of sets, and the usual Boolean operations on sets are described and their properties proved. 6. Axiom of powers (Section 5): For each set there exists a collection of sets that contains among its elements all the subsets of the given set. Again (noting that "collection" means "set") using the axiom (schema) of specification we can cut down to get the power set P ( A ) {\displaystyle P(A)} of a set A {\displaystyle A} , whose elements are precisely the subsets of A {\displaystyle A} . The axioms so far are used to construct the cartesian product of sets. 7. Axiom of infinity (Section 11): There exists a set containing 0 and containing the successor of each of its elements. The set 0 := ∅ {\displaystyle 0:=\emptyset } . The successor of a set x {\displaystyle x} is defined to be the set x + := x ∪ { x } {\displaystyle x^{+}:=x\cup \{x\}} . For example: { a , b } + = { a , b , { a , b } } {\displaystyle \{a,b\}^{+}=\{a,b,\{a,b\}\}} . This axiom ensures the existence of a set containing 0 {\displaystyle 0} and hence { 0 } {\displaystyle \{0\}} , and hence { 0 , { 0 } } {\displaystyle \{0,\{0\}\}} and so on. This implies that there is a set containing all the elements of the first infinite von Neumann ordinal ω {\displaystyle \omega } . And another application of the axiom (schema) of specification means ω {\displaystyle \omega } itself is a set. 8. Axiom of choice (Section 15): The Cartesian product of a non-empty family of non-empty sets is non-empty. This is one of many equivalents to the axiom of choice. Note here that "family" is defined to be a function f : I → X {\displaystyle f\colon I\to X} , with the intuitive idea that the sets of the family are the sets f ( i ) {\displaystyle f(i)} for i {\displaystyle i} ranging over the set I {\displaystyle I} , and in usual notation this axiom says that there is at least one element in ∏ i ∈ I f ( i ) {\displaystyle \prod _{i\in I}f(i)} , as long as f ( i ) ≠ ∅ {\displaystyle f(i)\neq \emptyset } for all i ∈ I ≠ ∅ {\displaystyle i\in I\neq \emptyset } . 9. Axiom of substitution (Section 19): If S ( a , b ) {\displaystyle S(a,b)} is a sentence such that for each a {\displaystyle a} in a set A {\displaystyle A} the set { b : S ( a , b ) } {\displaystyle \{b:S(a,b)\}} can be formed, then there exists a function F {\displaystyle F} with domain A {\displaystyle A} such that F ( a ) = { b : S ( a , b ) } {\displaystyle F(a)=\{b:S(a,b)\}} for each a {\displaystyle a} in A {\displaystyle A} . A function F : A → X {\displaystyle F\colon A\to X} is defined to be a functional relation (i.e. a certain subset of A × X {\displaystyle A\times X} ), not as a certain type of set of ordered pairs, as in ZFC, for instance. This 'axiom' is essentially the axiom schema of collection, which, given the other axioms, is equivalent to the axiom schema of replacement. It is the collection schema rather than replacement, because 1) S ( a , b ) {\displaystyle S(a,b)} is a class relation instead of a class function and 2) the function F {\displaystyle F} is not specified to have codomain precisely the set { F ( a ) : a ∈ A } {\displaystyle \{F(a):a\in A\}} , but merely some set X ⊇ { F ( a ) : a ∈ A } {\displaystyle X\supseteq \{F(a):a\in A\}} . This axiom is used in the book to a) construct limit von Neumann ordinals after the first infinite ordinal ω {\displaystyle \omega } , and b) prove that every well-ordered set is order isomorphic to a unique von Neumann ordinal. == Relation to other axiom systems for set theory == Note that axioms 1.-9. are equivalent to the axiom system of ZFC-Foundation (that is ZFC without the Foundation axiom), since as noted above, Halmos' axiom (schema) of substitution is equivalent to the axiom schema of replacement, in the presence of the other axioms. Additionally, axioms 1.-8. are nearly exactly those of Zermelo set theory ZC; the only difference being that the set existence assumption is replaced in ZC by the existence of the empty set, and the existence of singletons is stated outright for ZC, rather than proved, as above. Additionally, the infinite set that is asserted to exist by the axiom of infinity is not the one that Zermelo originally postulated,[a] but Halmos' version is sometimes silently substituted for it in treatments of Zermelo set theory. That the axiom (schema) of substitution is stated last and so late in the book is testament to how much elementary set theory—and indeed mathematics more generally—can be done without it. As a very simple example of what is is needed for, the von Neumann ordinal ω + ω {\displaystyle \omega +\omega } (that is, the second limit ordinal) cannot be proved to be a set using only axioms 1.-8., even though sets with well-orderings with this order type can be constructed from these axioms. For instance ω × { 1 } ∪ ω × { 2 } {\displaystyle \omega \times \{1\}\cup \omega \times \{2\}} , with an ordering placing all elements of the first copy of ω {\displaystyle \omega } less than the second. Working with von Neumann ordinals in place of generic well-orderings has technical advantages, not least the fact every well-ordering is order isomorphic to a unique von Neumann ordinal. As noted above, the book omits the Axiom of Foundation (also known as the Axiom of Regularity). Halmos repeatedly dances around the issue of whether or not a set can contain itself. p. 1: "a set may also be an element of some other set" (emphasis added) p. 3: "is A ∈ A {\displaystyle A\in A} ever true? It is certainly not true of any reasonable set that anyone has ever seen." p. 6: " B ∈ B {\displaystyle B\in B} ... unlikely, but not obviously impossible" But Halmos does let us prove that there are certain sets that cannot contain themselves. p. 44: Halmos lets us prove that ω ∉ ω {\displaystyle \omega \not \in \omega } . For if ω ∈ ω {\displaystyle \omega \in \omega } , then ω ∖ { ω } {\displaystyle \omega \setminus \{\omega \}} would still be a successor set, because ω ≠ ∅ {\displaystyle \omega \not =\emptyset } and ω {\displaystyle \omega } is not the successor of any natural number. But ω {\displaystyle \omega } is not a subset of ω ∖ { ω } {\displaystyle \omega \setminus \{\omega \}} , contradicting the definition of ω {\displaystyle \omega } as a subset of every successor set. p. 47: Halmos proves the lemma that "no natural number is a subset of any of its elements." This lets us prove that no natural number can contain itself. For if n ∈ n {\displaystyle n\in n} , where n {\displaystyle n} is a natural number, then n ⊂ n ∈ n {\displaystyle n\subset n\in n} , which contradicts the lemma. p. 75: "An ordinal number is defined as a well ordered set α {\displaystyle \alpha } such that s ( ξ ) = ξ {\displaystyle s(\xi )=\xi } for all ξ {\displaystyle \xi } in α {\displaystyle \alpha } ; here s ( ξ ) {\displaystyle s(\xi )} is, as before, the initial segment { η ∈ α : {\displaystyle \{\eta \in \alpha :} η < ξ {\displaystyle \eta <\xi } }." The well ordering is defined as follows: if ξ {\displaystyle \xi } and η {\displaystyle \eta } are elements of an ordinal number α {\displaystyle \alpha } , then ξ < η {\displaystyle \xi <\eta } means ξ ∈ η {\displaystyle \xi \in \eta } (pp. 75-76). By his choice of the symbol < {\displaystyle <} instead of ≤ {\displaystyle \leq } , Halmos implies that the well ordering < {\displaystyle <} is strict (pp. 55-56). This definition of < {\displaystyle <} makes it impossible to have ξ ∈ ξ {\displaystyle \xi \in \xi } , where ξ {\displaystyle \xi } is an element of an ordinal number. That's because ξ ∈ ξ {\displaystyle \xi \in \xi } means ξ < ξ {\displaystyle \xi <\xi } , which implies ξ ≠ ξ {\displaystyle \xi \not =\xi } (because < is strict), which is impossible. p. 75: the above definition of an ordinal number also makes it impossible to have α ∈ α {\displaystyle \alpha \in \alpha } , where α {\displaystyle \alpha } is an ordinal number. That's because α ∈ α {\displaystyle \alpha \in \alpha } implies α = s ( α ) {\displaystyle \alpha =s(\alpha )} . This gives us α ∈ α = s ( α ) = { η ∈ α : η < α } {\displaystyle \alpha \in \alpha =s(\alpha )=\{\eta \in \alpha :\eta <\alpha \}} , which implies α < α {\displaystyle \alpha <\alpha } , which implies α ≠ α {\displaystyle \alpha \not =\alpha } (because < {\displaystyle <} is strict), which is impossible. == Errata == p. 4, line 18: “Cain and Abel” should be “Seth, Cain and Abel”. p. 30, line 10: " x {\displaystyle x} onto y {\displaystyle y} " should be " x {\displaystyle x} into y {\displaystyle y} ". p, 66, line 16: "Consider, for example, the set E {\displaystyle E} of all those pairs ( a , b ) {\displaystyle (a,b)} for which ( 1 , 1 ) ≤ ( a , b ) {\displaystyle (1,1)\leq (a,b)} ; the set E {\displaystyle E} has ( 1 , 1 ) {\displaystyle (1,1)} for its least element.": the statement is not true, since ( 2 , 2 ) ≤ ( 1 , 1 ) {\displaystyle (2,2)\leq (1,1)} . In fact ( 2 × 2 + 1 ) × 2 1 = 10 ≤ ( 2 × 1 + 1 ) × 2 2 = 12 {\displaystyle (2\times 2+1)\times 2^{1}=10\leq (2\times 1+1)\times 2^{2}=12} . p. 73, line 19: "for each z {\displaystyle z} in X {\displaystyle X} " should be "for each a {\displaystyle a} in X {\displaystyle X} ". p. 75, line 3: "if and only if x ∈ F ( n ) {\displaystyle x\in F(n)} " should be "if and only if x = { b : S ( n , b ) } {\displaystyle x=\{b:S(n,b)\}} ". p, 100, line 11: "then c a r d X ∼ c a r d Y {\displaystyle \mathrm {card} \ X\sim \mathrm {card} \ Y} " should be "then c a r d X = c a r d Y {\displaystyle \mathrm {card} \ X=\mathrm {card} \ Y} ". == See also == List of important publications in mathematics == Notes == == Bibliography == Halmos, Paul, Naive Set Theory. Princeton, NJ: D. Van Nostrand Company, 1960. Reprinted by Springer-Verlag, New York, 1974. ISBN 0-387-90092-6 (Springer-Verlag edition). Reprinted by Martino Fine Books, 2011. ISBN 978-1-61427-131-4 (Paperback edition); 2017 Dover reprint ISBN 9780486814872; doi:10.1007/978-1-4757-1645-0. == References ==
Wikipedia/Naive_Set_Theory_(book)
Reinforcement learning (RL) is an interdisciplinary area of machine learning and optimal control concerned with how an intelligent agent should take actions in a dynamic environment in order to maximize a reward signal. Reinforcement learning is one of the three basic machine learning paradigms, alongside supervised learning and unsupervised learning. Reinforcement learning differs from supervised learning in not needing labelled input-output pairs to be presented, and in not needing sub-optimal actions to be explicitly corrected. Instead, the focus is on finding a balance between exploration (of uncharted territory) and exploitation (of current knowledge) with the goal of maximizing the cumulative reward (the feedback of which might be incomplete or delayed). The search for this balance is known as the exploration–exploitation dilemma. The environment is typically stated in the form of a Markov decision process (MDP), as many reinforcement learning algorithms use dynamic programming techniques. The main difference between classical dynamic programming methods and reinforcement learning algorithms is that the latter do not assume knowledge of an exact mathematical model of the Markov decision process, and they target large MDPs where exact methods become infeasible. == Principles == Due to its generality, reinforcement learning is studied in many disciplines, such as game theory, control theory, operations research, information theory, simulation-based optimization, multi-agent systems, swarm intelligence, and statistics. In the operations research and control literature, RL is called approximate dynamic programming, or neuro-dynamic programming. The problems of interest in RL have also been studied in the theory of optimal control, which is concerned mostly with the existence and characterization of optimal solutions, and algorithms for their exact computation, and less with learning or approximation (particularly in the absence of a mathematical model of the environment). Basic reinforcement learning is modeled as a Markov decision process: A set of environment and agent states (the state space), S {\displaystyle {\mathcal {S}}} ; A set of actions (the action space), A {\displaystyle {\mathcal {A}}} , of the agent; P a ( s , s ′ ) = Pr ( S t + 1 = s ′ ∣ S t = s , A t = a ) {\displaystyle P_{a}(s,s')=\Pr(S_{t+1}=s'\mid S_{t}=s,A_{t}=a)} , the transition probability (at time t {\displaystyle t} ) from state s {\displaystyle s} to state s ′ {\displaystyle s'} under action a {\displaystyle a} . R a ( s , s ′ ) {\displaystyle R_{a}(s,s')} , the immediate reward after transition from s {\displaystyle s} to s ′ {\displaystyle s'} under action a {\displaystyle a} . The purpose of reinforcement learning is for the agent to learn an optimal (or near-optimal) policy that maximizes the reward function or other user-provided reinforcement signal that accumulates from immediate rewards. This is similar to processes that appear to occur in animal psychology. For example, biological brains are hardwired to interpret signals such as pain and hunger as negative reinforcements, and interpret pleasure and food intake as positive reinforcements. In some circumstances, animals learn to adopt behaviors that optimize these rewards. This suggests that animals are capable of reinforcement learning. A basic reinforcement learning agent interacts with its environment in discrete time steps. At each time step t, the agent receives the current state S t {\displaystyle S_{t}} and reward R t {\displaystyle R_{t}} . It then chooses an action A t {\displaystyle A_{t}} from the set of available actions, which is subsequently sent to the environment. The environment moves to a new state S t + 1 {\displaystyle S_{t+1}} and the reward R t + 1 {\displaystyle R_{t+1}} associated with the transition ( S t , A t , S t + 1 ) {\displaystyle (S_{t},A_{t},S_{t+1})} is determined. The goal of a reinforcement learning agent is to learn a policy: π : S × A → [ 0 , 1 ] {\displaystyle \pi :{\mathcal {S}}\times {\mathcal {A}}\rightarrow [0,1]} , π ( s , a ) = Pr ( A t = a ∣ S t = s ) {\displaystyle \pi (s,a)=\Pr(A_{t}=a\mid S_{t}=s)} that maximizes the expected cumulative reward. Formulating the problem as a Markov decision process assumes the agent directly observes the current environmental state; in this case, the problem is said to have full observability. If the agent only has access to a subset of states, or if the observed states are corrupted by noise, the agent is said to have partial observability, and formally the problem must be formulated as a partially observable Markov decision process. In both cases, the set of actions available to the agent can be restricted. For example, the state of an account balance could be restricted to be positive; if the current value of the state is 3 and the state transition attempts to reduce the value by 4, the transition will not be allowed. When the agent's performance is compared to that of an agent that acts optimally, the difference in performance yields the notion of regret. In order to act near optimally, the agent must reason about long-term consequences of its actions (i.e., maximize future rewards), although the immediate reward associated with this might be negative. Thus, reinforcement learning is particularly well-suited to problems that include a long-term versus short-term reward trade-off. It has been applied successfully to various problems, including energy storage, robot control, photovoltaic generators, backgammon, checkers, Go (AlphaGo), and autonomous driving systems. Two elements make reinforcement learning powerful: the use of samples to optimize performance, and the use of function approximation to deal with large environments. Thanks to these two key components, RL can be used in large environments in the following situations: A model of the environment is known, but an analytic solution is not available; Only a simulation model of the environment is given (the subject of simulation-based optimization); The only way to collect information about the environment is to interact with it. The first two of these problems could be considered planning problems (since some form of model is available), while the last one could be considered to be a genuine learning problem. However, reinforcement learning converts both planning problems to machine learning problems. == Exploration == The exploration vs. exploitation trade-off has been most thoroughly studied through the multi-armed bandit problem and for finite state space Markov decision processes in Burnetas and Katehakis (1997). Reinforcement learning requires clever exploration mechanisms; randomly selecting actions, without reference to an estimated probability distribution, shows poor performance. The case of (small) finite Markov decision processes is relatively well understood. However, due to the lack of algorithms that scale well with the number of states (or scale to problems with infinite state spaces), simple exploration methods are the most practical. One such method is ε {\displaystyle \varepsilon } -greedy, where 0 < ε < 1 {\displaystyle 0<\varepsilon <1} is a parameter controlling the amount of exploration vs. exploitation. With probability 1 − ε {\displaystyle 1-\varepsilon } , exploitation is chosen, and the agent chooses the action that it believes has the best long-term effect (ties between actions are broken uniformly at random). Alternatively, with probability ε {\displaystyle \varepsilon } , exploration is chosen, and the action is chosen uniformly at random. ε {\displaystyle \varepsilon } is usually a fixed parameter but can be adjusted either according to a schedule (making the agent explore progressively less), or adaptively based on heuristics. == Algorithms for control learning == Even if the issue of exploration is disregarded and even if the state was observable (assumed hereafter), the problem remains to use past experience to find out which actions lead to higher cumulative rewards. === Criterion of optimality === ==== Policy ==== The agent's action selection is modeled as a map called policy: π : A × S → [ 0 , 1 ] {\displaystyle \pi :{\mathcal {A}}\times {\mathcal {S}}\rightarrow [0,1]} π ( a , s ) = Pr ( A t = a ∣ S t = s ) {\displaystyle \pi (a,s)=\Pr(A_{t}=a\mid S_{t}=s)} The policy map gives the probability of taking action a {\displaystyle a} when in state s {\displaystyle s} .: 61  There are also deterministic policies π {\displaystyle \pi } for which π ( s ) {\displaystyle \pi (s)} denotes the action that should be played at state s {\displaystyle s} . ==== State-value function ==== The state-value function V π ( s ) {\displaystyle V_{\pi }(s)} is defined as, expected discounted return starting with state s {\displaystyle s} , i.e. S 0 = s {\displaystyle S_{0}=s} , and successively following policy π {\displaystyle \pi } . Hence, roughly speaking, the value function estimates "how good" it is to be in a given state.: 60  V π ( s ) = E ⁡ [ G ∣ S 0 = s ] = E ⁡ [ ∑ t = 0 ∞ γ t R t + 1 ∣ S 0 = s ] , {\displaystyle V_{\pi }(s)=\operatorname {\mathbb {E} } [G\mid S_{0}=s]=\operatorname {\mathbb {E} } \left[\sum _{t=0}^{\infty }\gamma ^{t}R_{t+1}\mid S_{0}=s\right],} where the random variable G {\displaystyle G} denotes the discounted return, and is defined as the sum of future discounted rewards: G = ∑ t = 0 ∞ γ t R t + 1 = R 1 + γ R 2 + γ 2 R 3 + … , {\displaystyle G=\sum _{t=0}^{\infty }\gamma ^{t}R_{t+1}=R_{1}+\gamma R_{2}+\gamma ^{2}R_{3}+\dots ,} where R t + 1 {\displaystyle R_{t+1}} is the reward for transitioning from state S t {\displaystyle S_{t}} to S t + 1 {\displaystyle S_{t+1}} , 0 ≤ γ < 1 {\displaystyle 0\leq \gamma <1} is the discount rate. γ {\displaystyle \gamma } is less than 1, so rewards in the distant future are weighted less than rewards in the immediate future. The algorithm must find a policy with maximum expected discounted return. From the theory of Markov decision processes it is known that, without loss of generality, the search can be restricted to the set of so-called stationary policies. A policy is stationary if the action-distribution returned by it depends only on the last state visited (from the observation agent's history). The search can be further restricted to deterministic stationary policies. A deterministic stationary policy deterministically selects actions based on the current state. Since any such policy can be identified with a mapping from the set of states to the set of actions, these policies can be identified with such mappings with no loss of generality. === Brute force === The brute force approach entails two steps: For each possible policy, sample returns while following it Choose the policy with the largest expected discounted return One problem with this is that the number of policies can be large, or even infinite. Another is that the variance of the returns may be large, which requires many samples to accurately estimate the discounted return of each policy. These problems can be ameliorated if we assume some structure and allow samples generated from one policy to influence the estimates made for others. The two main approaches for achieving this are value function estimation and direct policy search. === Value function === Value function approaches attempt to find a policy that maximizes the discounted return by maintaining a set of estimates of expected discounted returns E ⁡ [ G ] {\displaystyle \operatorname {\mathbb {E} } [G]} for some policy (usually either the "current" [on-policy] or the optimal [off-policy] one). These methods rely on the theory of Markov decision processes, where optimality is defined in a sense stronger than the one above: A policy is optimal if it achieves the best-expected discounted return from any initial state (i.e., initial distributions play no role in this definition). Again, an optimal policy can always be found among stationary policies. To define optimality in a formal manner, define the state-value of a policy π {\displaystyle \pi } by V π ( s ) = E ⁡ [ G ∣ s , π ] , {\displaystyle V^{\pi }(s)=\operatorname {\mathbb {E} } [G\mid s,\pi ],} where G {\displaystyle G} stands for the discounted return associated with following π {\displaystyle \pi } from the initial state s {\displaystyle s} . Defining V ∗ ( s ) {\displaystyle V^{*}(s)} as the maximum possible state-value of V π ( s ) {\displaystyle V^{\pi }(s)} , where π {\displaystyle \pi } is allowed to change, V ∗ ( s ) = max π V π ( s ) . {\displaystyle V^{*}(s)=\max _{\pi }V^{\pi }(s).} A policy that achieves these optimal state-values in each state is called optimal. Clearly, a policy that is optimal in this sense is also optimal in the sense that it maximizes the expected discounted return, since V ∗ ( s ) = max π E [ G ∣ s , π ] {\displaystyle V^{*}(s)=\max _{\pi }\mathbb {E} [G\mid s,\pi ]} , where s {\displaystyle s} is a state randomly sampled from the distribution μ {\displaystyle \mu } of initial states (so μ ( s ) = Pr ( S 0 = s ) {\displaystyle \mu (s)=\Pr(S_{0}=s)} ). Although state-values suffice to define optimality, it is useful to define action-values. Given a state s {\displaystyle s} , an action a {\displaystyle a} and a policy π {\displaystyle \pi } , the action-value of the pair ( s , a ) {\displaystyle (s,a)} under π {\displaystyle \pi } is defined by Q π ( s , a ) = E ⁡ [ G ∣ s , a , π ] , {\displaystyle Q^{\pi }(s,a)=\operatorname {\mathbb {E} } [G\mid s,a,\pi ],\,} where G {\displaystyle G} now stands for the random discounted return associated with first taking action a {\displaystyle a} in state s {\displaystyle s} and following π {\displaystyle \pi } , thereafter. The theory of Markov decision processes states that if π ∗ {\displaystyle \pi ^{*}} is an optimal policy, we act optimally (take the optimal action) by choosing the action from Q π ∗ ( s , ⋅ ) {\displaystyle Q^{\pi ^{*}}(s,\cdot )} with the highest action-value at each state, s {\displaystyle s} . The action-value function of such an optimal policy ( Q π ∗ {\displaystyle Q^{\pi ^{*}}} ) is called the optimal action-value function and is commonly denoted by Q ∗ {\displaystyle Q^{*}} . In summary, the knowledge of the optimal action-value function alone suffices to know how to act optimally. Assuming full knowledge of the Markov decision process, the two basic approaches to compute the optimal action-value function are value iteration and policy iteration. Both algorithms compute a sequence of functions Q k {\displaystyle Q_{k}} ( k = 0 , 1 , 2 , … {\displaystyle k=0,1,2,\ldots } ) that converge to Q ∗ {\displaystyle Q^{*}} . Computing these functions involves computing expectations over the whole state-space, which is impractical for all but the smallest (finite) Markov decision processes. In reinforcement learning methods, expectations are approximated by averaging over samples and using function approximation techniques to cope with the need to represent value functions over large state-action spaces. ==== Monte Carlo methods ==== Monte Carlo methods are used to solve reinforcement learning problems by averaging sample returns. Unlike methods that require full knowledge of the environment's dynamics, Monte Carlo methods rely solely on actual or simulated experience—sequences of states, actions, and rewards obtained from interaction with an environment. This makes them applicable in situations where the complete dynamics are unknown. Learning from actual experience does not require prior knowledge of the environment and can still lead to optimal behavior. When using simulated experience, only a model capable of generating sample transitions is required, rather than a full specification of transition probabilities, which is necessary for dynamic programming methods. Monte Carlo methods apply to episodic tasks, where experience is divided into episodes that eventually terminate. Policy and value function updates occur only after the completion of an episode, making these methods incremental on an episode-by-episode basis, though not on a step-by-step (online) basis. The term "Monte Carlo" generally refers to any method involving random sampling; however, in this context, it specifically refers to methods that compute averages from complete returns, rather than partial returns. These methods function similarly to the bandit algorithms, in which returns are averaged for each state-action pair. The key difference is that actions taken in one state affect the returns of subsequent states within the same episode, making the problem non-stationary. To address this non-stationarity, Monte Carlo methods use the framework of general policy iteration (GPI). While dynamic programming computes value functions using full knowledge of the Markov decision process (MDP), Monte Carlo methods learn these functions through sample returns. The value functions and policies interact similarly to dynamic programming to achieve optimality, first addressing the prediction problem and then extending to policy improvement and control, all based on sampled experience. ==== Temporal difference methods ==== The first problem is corrected by allowing the procedure to change the policy (at some or all states) before the values settle. This too may be problematic as it might prevent convergence. Most current algorithms do this, giving rise to the class of generalized policy iteration algorithms. Many actor-critic methods belong to this category. The second issue can be corrected by allowing trajectories to contribute to any state-action pair in them. This may also help to some extent with the third problem, although a better solution when returns have high variance is Sutton's temporal difference (TD) methods that are based on the recursive Bellman equation. The computation in TD methods can be incremental (when after each transition the memory is changed and the transition is thrown away), or batch (when the transitions are batched and the estimates are computed once based on the batch). Batch methods, such as the least-squares temporal difference method, may use the information in the samples better, while incremental methods are the only choice when batch methods are infeasible due to their high computational or memory complexity. Some methods try to combine the two approaches. Methods based on temporal differences also overcome the fourth issue. Another problem specific to TD comes from their reliance on the recursive Bellman equation. Most TD methods have a so-called λ {\displaystyle \lambda } parameter ( 0 ≤ λ ≤ 1 ) {\displaystyle (0\leq \lambda \leq 1)} that can continuously interpolate between Monte Carlo methods that do not rely on the Bellman equations and the basic TD methods that rely entirely on the Bellman equations. This can be effective in palliating this issue. ==== Function approximation methods ==== In order to address the fifth issue, function approximation methods are used. Linear function approximation starts with a mapping ϕ {\displaystyle \phi } that assigns a finite-dimensional vector to each state-action pair. Then, the action values of a state-action pair ( s , a ) {\displaystyle (s,a)} are obtained by linearly combining the components of ϕ ( s , a ) {\displaystyle \phi (s,a)} with some weights θ {\displaystyle \theta } : Q ( s , a ) = ∑ i = 1 d θ i ϕ i ( s , a ) . {\displaystyle Q(s,a)=\sum _{i=1}^{d}\theta _{i}\phi _{i}(s,a).} The algorithms then adjust the weights, instead of adjusting the values associated with the individual state-action pairs. Methods based on ideas from nonparametric statistics (which can be seen to construct their own features) have been explored. Value iteration can also be used as a starting point, giving rise to the Q-learning algorithm and its many variants. Including Deep Q-learning methods when a neural network is used to represent Q, with various applications in stochastic search problems. The problem with using action-values is that they may need highly precise estimates of the competing action values that can be hard to obtain when the returns are noisy, though this problem is mitigated to some extent by temporal difference methods. Using the so-called compatible function approximation method compromises generality and efficiency. === Direct policy search === An alternative method is to search directly in (some subset of) the policy space, in which case the problem becomes a case of stochastic optimization. The two approaches available are gradient-based and gradient-free methods. Gradient-based methods (policy gradient methods) start with a mapping from a finite-dimensional (parameter) space to the space of policies: given the parameter vector θ {\displaystyle \theta } , let π θ {\displaystyle \pi _{\theta }} denote the policy associated to θ {\displaystyle \theta } . Defining the performance function by ρ ( θ ) = ρ π θ {\displaystyle \rho (\theta )=\rho ^{\pi _{\theta }}} under mild conditions this function will be differentiable as a function of the parameter vector θ {\displaystyle \theta } . If the gradient of ρ {\displaystyle \rho } was known, one could use gradient ascent. Since an analytic expression for the gradient is not available, only a noisy estimate is available. Such an estimate can be constructed in many ways, giving rise to algorithms such as Williams's REINFORCE method (which is known as the likelihood ratio method in the simulation-based optimization literature). A large class of methods avoids relying on gradient information. These include simulated annealing, cross-entropy search or methods of evolutionary computation. Many gradient-free methods can achieve (in theory and in the limit) a global optimum. Policy search methods may converge slowly given noisy data. For example, this happens in episodic problems when the trajectories are long and the variance of the returns is large. Value-function based methods that rely on temporal differences might help in this case. In recent years, actor–critic methods have been proposed and performed well on various problems. Policy search methods have been used in the robotics context. Many policy search methods may get stuck in local optima (as they are based on local search). === Model-based algorithms === Finally, all of the above methods can be combined with algorithms that first learn a model of the Markov decision process, the probability of each next state given an action taken from an existing state. For instance, the Dyna algorithm learns a model from experience, and uses that to provide more modelled transitions for a value function, in addition to the real transitions. Such methods can sometimes be extended to use of non-parametric models, such as when the transitions are simply stored and "replayed" to the learning algorithm. Model-based methods can be more computationally intensive than model-free approaches, and their utility can be limited by the extent to which the Markov decision process can be learnt. There are other ways to use models than to update a value function. For instance, in model predictive control the model is used to update the behavior directly. == Theory == Both the asymptotic and finite-sample behaviors of most algorithms are well understood. Algorithms with provably good online performance (addressing the exploration issue) are known. Efficient exploration of Markov decision processes is given in Burnetas and Katehakis (1997). Finite-time performance bounds have also appeared for many algorithms, but these bounds are expected to be rather loose and thus more work is needed to better understand the relative advantages and limitations. For incremental algorithms, asymptotic convergence issues have been settled. Temporal-difference-based algorithms converge under a wider set of conditions than was previously possible (for example, when used with arbitrary, smooth function approximation). == Research == Research topics include: actor-critic architecture actor-critic-scenery architecture adaptive methods that work with fewer (or no) parameters under a large number of conditions bug detection in software projects continuous learning combinations with logic-based frameworks exploration in large Markov decision processes entity-based reinforcement learning human feedback interaction between implicit and explicit learning in skill acquisition intrinsic motivation which differentiates information-seeking, curiosity-type behaviours from task-dependent goal-directed behaviours large-scale empirical evaluations large (or continuous) action spaces modular and hierarchical reinforcement learning multiagent/distributed reinforcement learning is a topic of interest. Applications are expanding. occupant-centric control optimization of computing resources partial information (e.g., using predictive state representation) reward function based on maximising novel information sample-based planning (e.g., based on Monte Carlo tree search). securities trading transfer learning TD learning modeling dopamine-based learning in the brain. Dopaminergic projections from the substantia nigra to the basal ganglia function are the prediction error. value-function and policy search methods == Comparison of key algorithms == The following table lists the key algorithms for learning a policy depending on several criteria: The algorithm can be on-policy (it performs policy updates using trajectories sampled via the current policy) or off-policy. The action space may be discrete (e.g. the action space could be "going up", "going left", "going right", "going down", "stay") or continuous (e.g. moving the arm with a given angle). The state space may be discrete (e.g. the agent could be in a cell in a grid) or continuous (e.g. the agent could be located at a given position in the plane). === Associative reinforcement learning === Associative reinforcement learning tasks combine facets of stochastic learning automata tasks and supervised learning pattern classification tasks. In associative reinforcement learning tasks, the learning system interacts in a closed loop with its environment. === Deep reinforcement learning === This approach extends reinforcement learning by using a deep neural network and without explicitly designing the state space. The work on learning ATARI games by Google DeepMind increased attention to deep reinforcement learning or end-to-end reinforcement learning. === Adversarial deep reinforcement learning === Adversarial deep reinforcement learning is an active area of research in reinforcement learning focusing on vulnerabilities of learned policies. In this research area some studies initially showed that reinforcement learning policies are susceptible to imperceptible adversarial manipulations. While some methods have been proposed to overcome these susceptibilities, in the most recent studies it has been shown that these proposed solutions are far from providing an accurate representation of current vulnerabilities of deep reinforcement learning policies. === Fuzzy reinforcement learning === By introducing fuzzy inference in reinforcement learning, approximating the state-action value function with fuzzy rules in continuous space becomes possible. The IF - THEN form of fuzzy rules make this approach suitable for expressing the results in a form close to natural language. Extending FRL with Fuzzy Rule Interpolation allows the use of reduced size sparse fuzzy rule-bases to emphasize cardinal rules (most important state-action values). === Inverse reinforcement learning === In inverse reinforcement learning (IRL), no reward function is given. Instead, the reward function is inferred given an observed behavior from an expert. The idea is to mimic observed behavior, which is often optimal or close to optimal. One popular IRL paradigm is named maximum entropy inverse reinforcement learning (MaxEnt IRL). MaxEnt IRL estimates the parameters of a linear model of the reward function by maximizing the entropy of the probability distribution of observed trajectories subject to constraints related to matching expected feature counts. Recently it has been shown that MaxEnt IRL is a particular case of a more general framework named random utility inverse reinforcement learning (RU-IRL). RU-IRL is based on random utility theory and Markov decision processes. While prior IRL approaches assume that the apparent random behavior of an observed agent is due to it following a random policy, RU-IRL assumes that the observed agent follows a deterministic policy but randomness in observed behavior is due to the fact that an observer only has partial access to the features the observed agent uses in decision making. The utility function is modeled as a random variable to account for the ignorance of the observer regarding the features the observed agent actually considers in its utility function. === Multi-objective reinforcement learning === Multi-objective reinforcement learning (MORL) is a form of reinforcement learning concerned with conflicting alternatives. It is distinct from multi-objective optimization in that it is concerned with agents acting in environments. === Safe reinforcement learning === Safe reinforcement learning (SRL) can be defined as the process of learning policies that maximize the expectation of the return in problems in which it is important to ensure reasonable system performance and/or respect safety constraints during the learning and/or deployment processes. An alternative approach is risk-averse reinforcement learning, where instead of the expected return, a risk-measure of the return is optimized, such as the conditional value at risk (CVaR). In addition to mitigating risk, the CVaR objective increases robustness to model uncertainties. However, CVaR optimization in risk-averse RL requires special care, to prevent gradient bias and blindness to success. === Self-reinforcement learning === Self-reinforcement learning (or self-learning), is a learning paradigm which does not use the concept of immediate reward R a ( s , s ′ ) {\displaystyle R_{a}(s,s')} after transition from s {\displaystyle s} to s ′ {\displaystyle s'} with action a {\displaystyle a} . It does not use an external reinforcement, it only uses the agent internal self-reinforcement. The internal self-reinforcement is provided by mechanism of feelings and emotions. In the learning process emotions are backpropagated by a mechanism of secondary reinforcement. The learning equation does not include the immediate reward, it only includes the state evaluation. The self-reinforcement algorithm updates a memory matrix W = | | w ( a , s ) | | {\displaystyle W=||w(a,s)||} such that in each iteration executes the following machine learning routine: In situation s {\displaystyle s} perform action a {\displaystyle a} . Receive a consequence situation s ′ {\displaystyle s'} . Compute state evaluation v ( s ′ ) {\displaystyle v(s')} of how good is to be in the consequence situation s ′ {\displaystyle s'} . Update crossbar memory w ′ ( a , s ) = w ( a , s ) + v ( s ′ ) {\displaystyle w'(a,s)=w(a,s)+v(s')} . Initial conditions of the memory are received as input from the genetic environment. It is a system with only one input (situation), and only one output (action, or behavior). Self-reinforcement (self-learning) was introduced in 1982 along with a neural network capable of self-reinforcement learning, named Crossbar Adaptive Array (CAA). The CAA computes, in a crossbar fashion, both decisions about actions and emotions (feelings) about consequence states. The system is driven by the interaction between cognition and emotion. === Reinforcement Learning in Natural Language Processing === In recent years, Reinforcement learning has become a significant concept in Natural Language Processing (NLP), where tasks are often sequential decision-making rather than static classification. Reinforcement learning is where an agent take actions in an environment to maximize the accumulation of rewards. This framework is best fit for many NLP tasks, including dialogue generation, text summarization, and machine translation, where the quality of the output depends on optimizing long-term or human-centered goals rather than the prediction of single correct label. Early application of RL in NLP emerged in dialogue systems, where conversation was determined as a series of actions optimized for fluency and coherence. These early attempts, including policy gradient and sequence-level training techniques, laid a foundation for the broader application of reinforcement learning to other areas of NLP. A major breakthrough happened with the introduction of Reinforcement Learning from Human Feedback (RLHF), a method in which human feedbacks are used to train a reward model that guides the RL agent. Unlike traditional rule-based or supervised systems, RLHF allows models to align their behavior with human judgments on complex and subjective tasks. This technique was initially used in the development of InstructGPT, an effective language model trained to follow human instructions and later in ChatGPT which incorporates RLHF for improving output responses and ensuring safety. More recently, researchers have explored the use of offline RL in NLP to improve dialogue systems without the need of live human interaction. These methods optimize for user engagement, coherence, and diversity based on past conversation logs and pre-trained reward models. == Statistical comparison of reinforcement learning algorithms == Efficient comparison of RL algorithms is essential for research, deployment and monitoring of RL systems. To compare different algorithms on a given environment, an agent can be trained for each algorithm. Since the performance is sensitive to implementation details, all algorithms should be implemented as closely as possible to each other. After the training is finished, the agents can be run on a sample of test episodes, and their scores (returns) can be compared. Since episodes are typically assumed to be i.i.d, standard statistical tools can be used for hypothesis testing, such as T-test and permutation test. This requires to accumulate all the rewards within an episode into a single number—the episodic return. However, this causes a loss of information, as different time-steps are averaged together, possibly with different levels of noise. Whenever the noise level varies across the episode, the statistical power can be improved significantly, by weighting the rewards according to their estimated noise. == Challenges and Limitations == Despite significant advancements, reinforcement learning (RL) continues to face several challenges and limitations that hinder its widespread application in real-world scenarios. === Sample Inefficiency === RL algorithms often require a large number of interactions with the environment to learn effective policies, leading to high computational costs and time-intensive to train the agent. For instance, OpenAI's Dota-playing bot utilized thousands of years of simulated gameplay to achieve human-level performance. Techniques like experience replay and curriculum learning have been proposed to deprive sample inefficiency, but these techniques add more complexity and are not always sufficient for real-world applications. === Stability and Convergence Issues === Training RL models, particularly for deep neural network-based models, can be unstable and prone to divergence. A small change in the policy or environment can lead to extreme fluctuations in performance, making it difficult to achieve consistent results. This instability is further enhanced in the case of the continuous or high-dimensional action space, where the learning step becomes more complex and less predictable. === Generalization and Transferability === The RL agents trained in specific environments often struggle to generalize their learned policies to new, unseen scenarios. This is the major setback preventing the application of RL to dynamic real-world environments where adaptability is crucial. The challenge is to develop such algorithms that can transfer knowledge across tasks and environments without extensive retraining. === Bias and Reward Function Issues === Designing appropriate reward functions is critical in RL because poorly designed reward functions can lead to unintended behaviors. In addition, RL systems trained on biased data may perpetuate existing biases and lead to discriminatory or unfair outcomes. Both of these issues requires careful consideration of reward structures and data sources to ensure fairness and desired behaviors. == See also == == References == == Further reading == Annaswamy, Anuradha M. (3 May 2023). "Adaptive Control and Intersections with Reinforcement Learning". Annual Review of Control, Robotics, and Autonomous Systems. 6 (1): 65–93. doi:10.1146/annurev-control-062922-090153. ISSN 2573-5144. S2CID 255702873. Auer, Peter; Jaksch, Thomas; Ortner, Ronald (2010). "Near-optimal regret bounds for reinforcement learning". Journal of Machine Learning Research. 11: 1563–1600. Bertsekas, Dimitri P. (2023) [2019]. REINFORCEMENT LEARNING AND OPTIMAL CONTROL (1st ed.). Athena Scientific. ISBN 978-1-886-52939-7. Busoniu, Lucian; Babuska, Robert; De Schutter, Bart; Ernst, Damien (2010). Reinforcement Learning and Dynamic Programming using Function Approximators. Taylor & Francis CRC Press. ISBN 978-1-4398-2108-4. François-Lavet, Vincent; Henderson, Peter; Islam, Riashat; Bellemare, Marc G.; Pineau, Joelle (2018). "An Introduction to Deep Reinforcement Learning". Foundations and Trends in Machine Learning. 11 (3–4): 219–354. arXiv:1811.12560. Bibcode:2018arXiv181112560F. doi:10.1561/2200000071. S2CID 54434537. Li, Shengbo Eben (2023). Reinforcement Learning for Sequential Decision and Optimal Control (1st ed.). Springer Verlag, Singapore. doi:10.1007/978-981-19-7784-8. ISBN 978-9-811-97783-1. Powell, Warren (2011). Approximate dynamic programming: solving the curses of dimensionality. Wiley-Interscience. Archived from the original on 2016-07-31. Retrieved 2010-09-08. Sutton, Richard S. (1988). "Learning to predict by the method of temporal differences". Machine Learning. 3: 9–44. doi:10.1007/BF00115009. Sutton, Richard S.; Barto, Andrew G. (2018) [1998]. Reinforcement Learning: An Introduction (2nd ed.). MIT Press. ISBN 978-0-262-03924-6. Szita, Istvan; Szepesvari, Csaba (2010). "Model-based Reinforcement Learning with Nearly Tight Exploration Complexity Bounds" (PDF). ICML 2010. Omnipress. pp. 1031–1038. Archived from the original (PDF) on 2010-07-14. == External links == Dissecting Reinforcement Learning Series of blog post on reinforcement learning with Python code A (Long) Peek into Reinforcement Learning
Wikipedia/Reinforcement_learning
In set theory, the union (denoted by ∪) of a collection of sets is the set of all elements in the collection. It is one of the fundamental operations through which sets can be combined and related to each other. A nullary union refers to a union of zero (⁠ 0 {\displaystyle 0} ⁠) sets and it is by definition equal to the empty set. For explanation of the symbols used in this article, refer to the table of mathematical symbols. == Binary union == The union of two sets A and B is the set of elements which are in A, in B, or in both A and B. In set-builder notation, A ∪ B = { x : x ∈ A or x ∈ B } {\displaystyle A\cup B=\{x:x\in A{\text{ or }}x\in B\}} . For example, if A = {1, 3, 5, 7} and B = {1, 2, 4, 6, 7} then A ∪ B = {1, 2, 3, 4, 5, 6, 7}. A more elaborate example (involving two infinite sets) is: A = {x is an even integer larger than 1} B = {x is an odd integer larger than 1} A ∪ B = { 2 , 3 , 4 , 5 , 6 , … } {\displaystyle A\cup B=\{2,3,4,5,6,\dots \}} As another example, the number 9 is not contained in the union of the set of prime numbers {2, 3, 5, 7, 11, ...} and the set of even numbers {2, 4, 6, 8, 10, ...}, because 9 is neither prime nor even. Sets cannot have duplicate elements, so the union of the sets {1, 2, 3} and {2, 3, 4} is {1, 2, 3, 4}. Multiple occurrences of identical elements have no effect on the cardinality of a set or its contents. === Finite unions === One can take the union of several sets simultaneously. For example, the union of three sets A, B, and C contains all elements of A, all elements of B, and all elements of C, and nothing else. Thus, x is an element of A ∪ B ∪ C if and only if x is in at least one of A, B, and C. A finite union is the union of a finite number of sets; the phrase does not imply that the union set is a finite set. == Notation == The notation for the general concept can vary considerably. For a finite union of sets S 1 , S 2 , S 3 , … , S n {\displaystyle S_{1},S_{2},S_{3},\dots ,S_{n}} one often writes S 1 ∪ S 2 ∪ S 3 ∪ ⋯ ∪ S n {\displaystyle S_{1}\cup S_{2}\cup S_{3}\cup \dots \cup S_{n}} or ⋃ i = 1 n S i {\textstyle \bigcup _{i=1}^{n}S_{i}} . Various common notations for arbitrary unions include ⋃ M {\textstyle \bigcup \mathbf {M} } , ⋃ A ∈ M A {\textstyle \bigcup _{A\in \mathbf {M} }A} , and ⋃ i ∈ I A i {\textstyle \bigcup _{i\in I}A_{i}} . The last of these notations refers to the union of the collection { A i : i ∈ I } {\displaystyle \left\{A_{i}:i\in I\right\}} , where I is an index set and A i {\displaystyle A_{i}} is a set for every ⁠ i ∈ I {\displaystyle i\in I} ⁠. In the case that the index set I is the set of natural numbers, one uses the notation ⋃ i = 1 ∞ A i {\textstyle \bigcup _{i=1}^{\infty }A_{i}} , which is analogous to that of the infinite sums in series. When the symbol "∪" is placed before other symbols (instead of between them), it is usually rendered as a larger size. === Notation encoding === In Unicode, union is represented by the character U+222A ∪ UNION. In TeX, ∪ {\displaystyle \cup } is rendered from \cup and ⋃ {\textstyle \bigcup } is rendered from \bigcup. == Arbitrary union == The most general notion is the union of an arbitrary collection of sets, sometimes called an infinitary union. If M is a set or class whose elements are sets, then x is an element of the union of M if and only if there is at least one element A of M such that x is an element of A. In symbols: x ∈ ⋃ M ⟺ ∃ A ∈ M , x ∈ A . {\displaystyle x\in \bigcup \mathbf {M} \iff \exists A\in \mathbf {M} ,\ x\in A.} This idea subsumes the preceding sections—for example, A ∪ B ∪ C is the union of the collection {A, B, C}. Also, if M is the empty collection, then the union of M is the empty set. === Formal derivation === In Zermelo–Fraenkel set theory (ZFC) and other set theories, the ability to take the arbitrary union of any sets is granted by the axiom of union, which states that, given any set of sets A {\displaystyle A} , there exists a set B {\displaystyle B} , whose elements are exactly those of the elements of A {\displaystyle A} . Sometimes this axiom is less specific, where there exists a B {\displaystyle B} which contains the elements of the elements of A {\displaystyle A} , but may be larger. For example if A = { { 1 } , { 2 } } , {\displaystyle A=\{\{1\},\{2\}\},} then it may be that B = { 1 , 2 , 3 } {\displaystyle B=\{1,2,3\}} since B {\displaystyle B} contains 1 and 2. This can be fixed by using the axiom of specification to get the subset of B {\displaystyle B} whose elements are exactly those of the elements of A {\displaystyle A} . Then one can use the axiom of extensionality to show that this set is unique. For readability, define the binary predicate Union ⁡ ( X , Y ) {\displaystyle \operatorname {Union} (X,Y)} meaning " X {\displaystyle X} is the union of Y {\displaystyle Y} " or " X = ⋃ Y {\displaystyle X=\bigcup Y} " as: Union ⁡ ( X , Y ) ⟺ ∀ x ( x ∈ X ⟺ ∃ y ∈ Y ( x ∈ y ) ) {\displaystyle \operatorname {Union} (X,Y)\iff \forall x(x\in X\iff \exists y\in Y(x\in y))} Then, one can prove the statement "for all Y {\displaystyle Y} , there is a unique X {\displaystyle X} , such that X {\displaystyle X} is the union of Y {\displaystyle Y} ": ∀ Y ∃ ! X ( Union ⁡ ( X , Y ) ) {\displaystyle \forall Y\,\exists !X(\operatorname {Union} (X,Y))} Then, one can use an extension by definition to add the union operator ⋃ A {\displaystyle \bigcup A} to the language of ZFC as: B = ⋃ A ⟺ Union ⁡ ( B , A ) ⟺ ∀ x ( x ∈ B ⟺ ∃ y ∈ Y ( x ∈ y ) ) {\displaystyle {\begin{aligned}B=\bigcup A&\iff \operatorname {Union} (B,A)\\&\iff \forall x(x\in B\iff \exists y\in Y(x\in y))\end{aligned}}} or equivalently: x ∈ ⋃ A ⟺ ∃ y ∈ A ( x ∈ y ) {\displaystyle x\in \bigcup A\iff \exists y\in A\,(x\in y)} After the union operator has been defined, the binary union A ∪ B {\displaystyle A\cup B} can be defined by showing there exists a unique set C = { A , B } {\displaystyle C=\{A,B\}} using the axiom of pairing, and defining A ∪ B = ⋃ { A , B } {\displaystyle A\cup B=\bigcup \{A,B\}} . Then, finite unions can be defined inductively as: ⋃ i = 1 0 A i = ∅ , and ⋃ i = 1 n A i = ( ⋃ i = 1 n − 1 A i ) ∪ A n {\displaystyle \bigcup _{i=1}^{0}A_{i}=\varnothing {\text{, and }}\bigcup _{i=1}^{n}A_{i}=\left(\bigcup _{i=1}^{n-1}A_{i}\right)\cup A_{n}} == Algebraic properties == Binary union is an associative operation; that is, for any sets ⁠ A , B , and C {\displaystyle A,B,{\text{ and }}C} ⁠, A ∪ ( B ∪ C ) = ( A ∪ B ) ∪ C . {\displaystyle A\cup (B\cup C)=(A\cup B)\cup C.} Thus, the parentheses may be omitted without ambiguity: either of the above can be written as ⁠ A ∪ B ∪ C {\displaystyle A\cup B\cup C} ⁠. Also, union is commutative, so the sets can be written in any order. The empty set is an identity element for the operation of union. That is, ⁠ A ∪ ∅ = A {\displaystyle A\cup \varnothing =A} ⁠, for any set ⁠ A {\displaystyle A} ⁠. Also, the union operation is idempotent: ⁠ A ∪ A = A {\displaystyle A\cup A=A} ⁠. All these properties follow from analogous facts about logical disjunction. Intersection distributes over union A ∩ ( B ∪ C ) = ( A ∩ B ) ∪ ( A ∩ C ) {\displaystyle A\cap (B\cup C)=(A\cap B)\cup (A\cap C)} and union distributes over intersection A ∪ ( B ∩ C ) = ( A ∪ B ) ∩ ( A ∪ C ) . {\displaystyle A\cup (B\cap C)=(A\cup B)\cap (A\cup C).} The power set of a set ⁠ U {\displaystyle U} ⁠, together with the operations given by union, intersection, and complementation, is a Boolean algebra. In this Boolean algebra, union can be expressed in terms of intersection and complementation by the formula A ∪ B = ( A ∁ ∩ B ∁ ) ∁ , {\displaystyle A\cup B=(A^{\complement }\cap B^{\complement })^{\complement },} where the superscript ∁ {\displaystyle {}^{\complement }} denotes the complement in the universal set ⁠ U {\displaystyle U} ⁠. Alternatively, intersection can be expressed in terms of union and complementation in a similar way: A ∩ B = ( A ∁ ∪ B ∁ ) ∁ {\displaystyle A\cap B=(A^{\complement }\cup B^{\complement })^{\complement }} . These two expressions together are called De Morgan's laws. == History and etymology == The english word union comes from the term in middle French meaning "coming together", which comes from the post-classical Latin unionem, "oneness". The original term for union in set theory was Vereinigung (in german), which was introduced in 1895 by Georg Cantor. The english use of union of two sets in mathematics began to be used by at least 1912, used by James Pierpont. The symbol ∪ {\displaystyle \cup } used for union in mathematics was introduced by Giuseppe Peano in his Arithmetices principia in 1889, along with the notations for intersection ∩ {\displaystyle \cap } , set membership ∈ {\displaystyle \in } , and subsets ⊂ {\displaystyle \subset } . == See also == Algebra of sets – Identities and relationships involving sets Alternation (formal language theory) – in formal language theory and pattern matching, the union of two sets of strings or patternsPages displaying wikidata descriptions as a fallback − the union of sets of strings Axiom of union – Concept in axiomatic set theory Disjoint union – In mathematics, operation on sets Inclusion–exclusion principle – Counting technique in combinatorics Intersection (set theory) – Set of elements common to all of some sets Iterated binary operation – Repeated application of an operation to a sequence List of set identities and relations – Equalities for combinations of sets Naive set theory – Informal set theories Symmetric difference – Elements in exactly one of two sets == Notes == == External links == "Union of sets", Encyclopedia of Mathematics, EMS Press, 2001 [1994] Infinite Union and Intersection at ProvenMath De Morgan's laws formally proven from the axioms of set theory.
Wikipedia/Union_(set_theory)
In computer science, the expressive power (also called expressiveness or expressivity) of a language is the breadth of ideas that can be represented and communicated in that language. The more expressive a language is, the greater the variety and quantity of ideas it can be used to represent. For example, the Web Ontology Language expression language profile (OWL2 EL) lacks ideas (such as negation) that can be expressed in OWL2 RL (rule language). OWL2 EL may therefore be said to have less expressive power than OWL2 RL. These restrictions allow for more efficient (polynomial time) reasoning in OWL2 EL than in OWL2 RL. So OWL2 EL trades some expressive power for more efficient reasoning (processing of the knowledge representation language). == Information description == The term expressive power may be used with a range of meaning. It may mean a measure of the ideas expressible in that language: regardless of ease (theoretical expressivity) concisely and readily (practical expressivity) The first sense dominates in areas of mathematics and logic that deal with the formal description of languages and their meaning, such as formal language theory, mathematical logic and process algebra. In informal discussions, the term often refers to the second sense, or to both. This is often the case when discussing programming languages. Efforts have been made to formalize these informal uses of the term. The notion of expressive power is always relative to a particular kind of thing that the language in question can describe, and the term is normally used when comparing languages that describe the same kind of things, or at least comparable kinds of things. The design of languages and formalisms involves a trade-off between expressive power and analyzability. The more a formalism can express, the harder it becomes to understand what instances of the formalism say. Decision problems become harder to answer or completely undecidable. == Examples == === In formal language theory === Formal language theory mostly studies formalisms to describe sets of strings, such as context-free grammars and regular expressions. Each instance of a formalism, e.g. each grammar and each regular expression, describes a particular set of strings. In this context, the expressive power of a formalism is the set of sets of strings its instances describe, and comparing expressive power is a matter of comparing these sets. An important yardstick for describing the relative expressive power of formalisms in this area is the Chomsky hierarchy. It says, for instance, that regular expressions, nondeterministic finite automata and regular grammars have equal expressive power, while that of context-free grammars is greater; what this means is that the sets of sets of strings described by the first three formalisms are equal, and a proper subset of the set of sets of strings described by context-free grammars. In this area, the cost of expressive power is a central topic of study. It is known, for instance, that deciding whether two arbitrary regular expressions describe the same set of strings is hard, while doing the same for arbitrary context-free grammars is completely impossible. However, it can still be efficiently decided whether any given string is in the set. For more expressive formalisms, this problem can be harder, or even undecidable. For a Turing complete formalism, such as arbitrary formal grammars, not only this problem, but every nontrivial property regarding the set of strings they describe is undecidable, a fact known as Rice's Theorem. There are some results on conciseness as well; for instance, nondeterministic finite automata and regular grammars are more concise than regular expressions, in the sense that the latter can be translated to the former without a blowup in size (i.e. in O(1)), while the reverse is not possible. Similar considerations apply to formalisms that describe not sets of strings, but sets of trees (e.g. XML schema languages), of graphs, or other structures. === In database theory === Database theory is concerned, among other things, with database queries, e.g. formulas that, given the contents of a database, specify certain information to be extracted from it. In the predominant relational database paradigm, the contents of a database are described as a finite set of finite mathematical relations; Boolean queries, that always yield true or false, are formulated in first-order logic. It turns out that first-order logic is lacking in expressive power: it cannot express certain types of Boolean queries, e.g. queries involving transitive closure. However, adding expressive power must be done with care: it must still remain possible to evaluate queries with reasonable efficiency, which is not the case, e.g., for second-order logic. Consequently, a literature sprang up in which many query languages and language constructs were compared on the basis of expressive power and efficiency, e.g. various versions of Datalog. Similar considerations apply for query languages on other types of data, e.g. XML query languages such as XQuery. == See also == Extensible programming Semantic spectrum Turing tarpit == References ==
Wikipedia/Expressive_power_(computer_science)
Inferences are steps in logical reasoning, moving from premises to logical consequences; etymologically, the word infer means to "carry forward". Inference is theoretically traditionally divided into deduction and induction, a distinction that in Europe dates at least to Aristotle (300s BC). Deduction is inference deriving logical conclusions from premises known or assumed to be true, with the laws of valid inference being studied in logic. Induction is inference from particular evidence to a universal conclusion. A third type of inference is sometimes distinguished, notably by Charles Sanders Peirce, contradistinguishing abduction from induction. Various fields study how inference is done in practice. Human inference (i.e. how humans draw conclusions) is traditionally studied within the fields of logic, argumentation studies, and cognitive psychology; artificial intelligence researchers develop automated inference systems to emulate human inference. Statistical inference uses mathematics to draw conclusions in the presence of uncertainty. This generalizes deterministic reasoning, with the absence of uncertainty as a special case. Statistical inference uses quantitative or qualitative (categorical) data which may be subject to random variations. == Definition == The process by which a conclusion is inferred from multiple observations is called inductive reasoning. The conclusion may be correct or incorrect, or correct to within a certain degree of accuracy, or correct in certain situations. Conclusions inferred from multiple observations may be tested by additional observations. This definition is disputable (due to its lack of clarity. Ref: Oxford English dictionary: "induction ... 3. Logic the inference of a general law from particular instances." ) The definition given thus applies only when the "conclusion" is general. Two possible definitions of "inference" are: A conclusion reached on the basis of evidence and reasoning. The process of reaching such a conclusion. == Examples == === Example for definition #1 === Ancient Greek philosophers defined a number of syllogisms, correct three part inferences, that can be used as building blocks for more complex reasoning. We begin with a famous example: All humans are mortal. All Greeks are humans. All Greeks are mortal. The reader can check that the premises and conclusion are true, but logic is concerned with inference: does the truth of the conclusion follow from that of the premises? The validity of an inference depends on the form of the inference. That is, the word "valid" does not refer to the truth of the premises or the conclusion, but rather to the form of the inference. An inference can be valid even if the parts are false, and can be invalid even if some parts are true. But a valid form with true premises will always have a true conclusion. For example, consider the form of the following symbological track: All meat comes from animals. All beef is meat. Therefore, all beef comes from animals. If the premises are true, then the conclusion is necessarily true, too. Now we turn to an invalid form. All A are B. All C are B. Therefore, all C are A. To show that this form is invalid, we demonstrate how it can lead from true premises to a false conclusion. All apples are fruit. (True) All bananas are fruit. (True) Therefore, all bananas are apples. (False) A valid argument with a false premise may lead to a false conclusion, (this and the following examples do not follow the Greek syllogism): All tall people are French. (False) John Lennon was tall. (True) Therefore, John Lennon was French. (False) When a valid argument is used to derive a false conclusion from a false premise, the inference is valid because it follows the form of a correct inference. A valid argument can also be used to derive a true conclusion from a false premise: All tall people are musicians. (Valid, False) John Lennon was tall. (Valid, True) Therefore, John Lennon was a musician. (Valid, True) In this case we have one false premise and one true premise where a true conclusion has been inferred. === Example for definition #2 === Evidence: It is the early 1950s and you are an American stationed in the Soviet Union. You read in the Moscow newspaper that a soccer team from a small city in Siberia starts winning game after game. The team even defeats the Moscow team. Inference: The small city in Siberia is not a small city anymore. The Soviets are working on their own nuclear or high-value secret weapons program. Knowns: The Soviet Union is a command economy: people and material are told where to go and what to do. The small city was remote and historically had never distinguished itself; its soccer season was typically short because of the weather. Explanation: In a command economy, people and material are moved where they are needed. Large cities might field good teams due to the greater availability of high quality players; and teams that can practice longer (possibly due to sunnier weather and better facilities) can reasonably be expected to be better. In addition, you put your best and brightest in places where they can do the most good—such as on high-value weapons programs. It is an anomaly for a small city to field such a good team. The anomaly indirectly described a condition by which the observer inferred a new meaningful pattern—that the small city was no longer small. Why would you put a large city of your best and brightest in the middle of nowhere? To hide them, of course. == Incorrect inference == An incorrect inference is known as a fallacy. Philosophers who study informal logic have compiled large lists of them, and cognitive psychologists have documented many biases in human reasoning that favor incorrect reasoning. == Applications == === Inference engines === AI systems first provided automated logical inference and these were once extremely popular research topics, leading to industrial applications under the form of expert systems and later business rule engines. More recent work on automated theorem proving has had a stronger basis in formal logic. An inference system's job is to extend a knowledge base automatically. The knowledge base (KB) is a set of propositions that represent what the system knows about the world. Several techniques can be used by that system to extend KB by means of valid inferences. An additional requirement is that the conclusions the system arrives at are relevant to its task. Additionally, the term 'inference' has also been applied to the process of generating predictions from trained neural networks. In this context, an 'inference engine' refers to the system or hardware performing these operations. This type of inference is widely used in applications ranging from image recognition to natural language processing. ==== Prolog engine ==== Prolog (for "Programming in Logic") is a programming language based on a subset of predicate calculus. Its main job is to check whether a certain proposition can be inferred from a KB (knowledge base) using an algorithm called backward chaining. Let us return to our Socrates syllogism. We enter into our Knowledge Base the following piece of code: mortal(X) :- man(X). man(socrates). ( Here :- can be read as "if". Generally, if P → {\displaystyle \to } Q (if P then Q) then in Prolog we would code Q:-P (Q if P).) This states that all men are mortal and that Socrates is a man. Now we can ask the Prolog system about Socrates: ?- mortal(socrates). (where ?- signifies a query: Can mortal(socrates). be deduced from the KB using the rules) gives the answer "Yes". On the other hand, asking the Prolog system the following: ?- mortal(plato). gives the answer "No". This is because Prolog does not know anything about Plato, and hence defaults to any property about Plato being false (the so-called closed world assumption). Finally ?- mortal(X) (Is anything mortal) would result in "Yes" (and in some implementations: "Yes": X=socrates) Prolog can be used for vastly more complicated inference tasks. See the corresponding article for further examples. === Semantic web === Recently automatic reasoners found in semantic web a new field of application. Being based upon description logic, knowledge expressed using one variant of OWL can be logically processed, i.e., inferences can be made upon it. === Bayesian statistics and probability logic === Philosophers and scientists who follow the Bayesian framework for inference use the mathematical rules of probability to find this best explanation. The Bayesian view has a number of desirable features—one of them is that it embeds deductive (certain) logic as a subset (this prompts some writers to call Bayesian probability "probability logic", following E. T. Jaynes). Bayesians identify probabilities with degrees of beliefs, with certainly true propositions having probability 1, and certainly false propositions having probability 0. To say that "it's going to rain tomorrow" has a 0.9 probability is to say that you consider the possibility of rain tomorrow as extremely likely. Through the rules of probability, the probability of a conclusion and of alternatives can be calculated. The best explanation is most often identified with the most probable (see Bayesian decision theory). A central rule of Bayesian inference is Bayes' theorem. === Fuzzy logic === === Non-monotonic logic === A relation of inference is monotonic if the addition of premises does not undermine previously reached conclusions; otherwise the relation is non-monotonic. Deductive inference is monotonic: if a conclusion is reached on the basis of a certain set of premises, then that conclusion still holds if more premises are added. By contrast, everyday reasoning is mostly non-monotonic because it involves risk: we jump to conclusions from deductively insufficient premises. We know when it is worth or even necessary (e.g. in medical diagnosis) to take the risk. Yet we are also aware that such inference is defeasible—that new information may undermine old conclusions. Various kinds of defeasible but remarkably successful inference have traditionally captured the attention of philosophers (theories of induction, Peirce's theory of abduction, inference to the best explanation, etc.). More recently logicians have begun to approach the phenomenon from a formal point of view. The result is a large body of theories at the interface of philosophy, logic and artificial intelligence. == See also == A priori and a posteriori – Two types of knowledge, justification, or argument Abductive reasoning – Inference seeking the simplest and most likely explanation Deductive reasoning – Form of reasoning Inductive reasoning – Method of logical reasoning Entailment – Relationship where one statement follows from anotherPages displaying short descriptions of redirect targets Epilogism Analogy – Cognitive process of transferring information or meaning from a particular subject to another Axiom system – Mathematical term; concerning axioms used to derive theoremsPages displaying short descriptions of redirect targets Axiom – Statement that is taken to be true Immediate inference – Logical inference from a single statement Inferential programming Inquiry – Any process that has the aim of augmenting knowledge, resolving doubt, or solving a problem Logic – Study of correct reasoning Logic of information Logical assertion – Statement in a metalanguagePages displaying short descriptions of redirect targets Logical graph – Type of diagrammatic notation for propositional logicPages displaying short descriptions of redirect targets Rule of inference – Method of deriving conclusions List of rules of inference Theorem – In mathematics, a statement that has been proven Transduction (machine learning) – Type of statistical inference == References == == Further reading == Inductive inference: Carnap, Rudolf; Jeffrey, Richard C., eds. (1971). Studies in Inductive Logic and Probability. Vol. 1. The University of California Press. Jeffrey, Richard C., ed. (1980). Studies in Inductive Logic and Probability. Vol. 2. The University of California Press. ISBN 9780520038264. Angluin, Dana (1976). An Application of the Theory of Computational Complexity to the Study of Inductive Inference (Ph.D.). University of California at Berkeley. Angluin, Dana (1980). "Inductive Inference of Formal Languages from Positive Data". Information and Control. 45 (2): 117–135. doi:10.1016/s0019-9958(80)90285-5. Angluin, Dana; Smith, Carl H. (September 1983). "Inductive Inference: Theory and Methods" (PDF). Computing Surveys. 15 (3): 237–269. doi:10.1145/356914.356918. S2CID 3209224. Gabbay, Dov M.; Hartmann, Stephan; Woods, John, eds. (2009). Inductive Logic. Handbook of the History of Logic. Vol. 10. Elsevier. ISBN 978-0-444-52936-7. Goodman, Nelson (1983). Fact, Fiction, and Forecast. Harvard University Press. ISBN 9780674290716. Abductive inference: O'Rourke, P.; Josephson, J., eds. (1997). Automated abduction: Inference to the best explanation. AAAI Press. Psillos, Stathis (2009). "An Explorer upon Untrodden Ground". In Gabbay, Dov M.; Hartmann, Stephan; Woods, John (eds.). An Explorer upon Untrodden Ground: Peirce on Abduction (PDF). Handbook of the History of Logic. Vol. 10. Elsevier. pp. 117–152. doi:10.1016/B978-0-444-52936-7.50004-5. ISBN 978-0-444-52936-7. Ray, Oliver (December 2005). Hybrid Abductive Inductive Learning (Ph.D.). University of London, Imperial College. CiteSeerX 10.1.1.66.1877. Psychological investigations about human reasoning: deductive: Johnson-Laird, Philip Nicholas; Byrne, Ruth M. J. (1992). Deduction. Erlbaum. Byrne, Ruth M. J.; Johnson-Laird, P. N. (2009). ""If" and the Problems of Conditional Reasoning" (PDF). Trends in Cognitive Sciences. 13 (7): 282–287. doi:10.1016/j.tics.2009.04.003. PMID 19540792. S2CID 657803. Archived from the original (PDF) on 7 April 2014. Retrieved 9 August 2013. Knauff, Markus; Fangmeier, Thomas; Ruff, Christian C.; Johnson-Laird, P. N. (2003). "Reasoning, Models, and Images: Behavioral Measures and Cortical Activity" (PDF). Journal of Cognitive Neuroscience. 15 (4): 559–573. CiteSeerX 10.1.1.318.6615. doi:10.1162/089892903321662949. hdl:11858/00-001M-0000-0013-DC8B-C. PMID 12803967. S2CID 782228. Archived from the original (PDF) on 18 May 2015. Retrieved 9 August 2013. Johnson-Laird, Philip N. (1995). Gazzaniga, M. S. (ed.). Mental Models, Deductive Reasoning, and the Brain (PDF). MIT Press. pp. 999–1008. Khemlani, Sangeet; Johnson-Laird, P. N. (2008). "Illusory Inferences about Embedded Disjunctions" (PDF). Proceedings of the 30th Annual Conference of the Cognitive Science Society. Washington/DC. pp. 2128–2133. statistical: McCloy, Rachel; Byrne, Ruth M. J.; Johnson-Laird, Philip N. (2009). "Understanding Cumulative Risk" (PDF). The Quarterly Journal of Experimental Psychology. 63 (3): 499–515. doi:10.1080/17470210903024784. PMID 19591080. S2CID 7741180. Archived from the original (PDF) on 18 May 2015. Retrieved 9 August 2013. Johnson-Laird, Philip N. (1994). "Mental Models and Probabilistic Thinking" (PDF). Cognition. 50 (1–3): 189–209. doi:10.1016/0010-0277(94)90028-0. PMID 8039361. S2CID 9439284., analogical: Burns, B. D. (1996). "Meta-Analogical Transfer: Transfer Between Episodes of Analogical Reasoning". Journal of Experimental Psychology: Learning, Memory, and Cognition. 22 (4): 1032–1048. doi:10.1037/0278-7393.22.4.1032. spatial: Jahn, Georg; Knauff, Markus; Johnson-Laird, P. N. (2007). "Preferred mental models in reasoning about spatial relations" (PDF). Memory & Cognition. 35 (8): 2075–2087. doi:10.3758/bf03192939. PMID 18265622. S2CID 25356700. Knauff, Markus; Johnson-Laird, P. N. (2002). "Visual imagery can impede reasoning" (PDF). Memory & Cognition. 30 (3): 363–371. doi:10.3758/bf03194937. PMID 12061757. S2CID 7330724. Waltz, James A.; Knowlton, Barbara J.; Holyoak, Keith J.; Boone, Kyle B.; Mishkin, Fred S.; de Menezes Santos, Marcia; Thomas, Carmen R.; Miller, Bruce L. (March 1999). "A System for Relational Reasoning in Human Prefrontal Cortex". Psychological Science. 10 (2): 119–125. doi:10.1111/1467-9280.00118. S2CID 44019775. moral: Bucciarelli, Monica; Khemlani, Sangeet; Johnson-Laird, P. N. (February 2008). "The Psychology of Moral Reasoning" (PDF). Judgment and Decision Making. 3 (2): 121–139. doi:10.1017/S1930297500001479. S2CID 327124. == External links == Inference at PhilPapers Inference example and definition Inference at the Indiana Philosophy Ontology Project
Wikipedia/Inference
Free choice is a phenomenon in natural language where a linguistic disjunction appears to receive a logical conjunctive interpretation when it interacts with a modal operator. For example, the following English sentences can be interpreted to mean that the addressee can watch a movie and that they can also play video games, depending on their preference: You can watch a movie or play video games. You can watch a movie or you can play video games. Free choice inferences are a major topic of research in formal semantics and philosophical logic because they are not valid in classical systems of modal logic. If they were valid, then the semantics of natural language would validate the Free Choice Principle. Free Choice Principle: ◊ ( P ∨ Q ) → ( ◊ P ∧ ◊ Q ) {\displaystyle \Diamond (P\lor Q)\rightarrow (\Diamond P\land \Diamond Q)} This symbolic logic formula above is not valid in classical modal logic: Adding this principle as an axiom to standard modal logics would allow one to conclude ◊ Q {\displaystyle \Diamond Q} from ◊ P {\displaystyle \Diamond P} , for any P {\displaystyle P} and Q {\displaystyle Q} . This observation is known as the Paradox of Free Choice. To resolve this paradox, some researchers have proposed analyses of free choice within nonclassical frameworks such as dynamic semantics, linear logic, alternative semantics, and inquisitive semantics. Others have proposed ways of deriving free choice inferences as scalar implicatures which arise on the basis of classical lexical entries for disjunction and modality. Free choice inferences are most widely studied for deontic modals, but also arise with other flavors of modality as well as imperatives, conditionals, and other kinds of operators. Indefinite noun phrases give rise to a similar inference which is also referred to as "free choice" though researchers disagree as to whether it forms a natural class with disjunctive free choice. == See also == Deontic logic Disjunction Hans Kamp Modal logic Ross's paradox Simplification of disjunctive antecedents Sluicing == Notes ==
Wikipedia/Free_choice_inference
In mathematics, an indicator function or a characteristic function of a subset of a set is a function that maps elements of the subset to one, and all other elements to zero. That is, if A is a subset of some set X, then the indicator function of A is the function 1 A {\displaystyle \mathbf {1} _{A}} defined by 1 A ( x ) = 1 {\displaystyle \mathbf {1} _{A}\!(x)=1} if x ∈ A , {\displaystyle x\in A,} and 1 A ( x ) = 0 {\displaystyle \mathbf {1} _{A}\!(x)=0} otherwise. Other common notations are 𝟙A and χ A . {\displaystyle \chi _{A}.} The indicator function of A is the Iverson bracket of the property of belonging to A; that is, 1 A ( x ) = [ x ∈ A ] . {\displaystyle \mathbf {1} _{A}(x)=\left[\ x\in A\ \right].} For example, the Dirichlet function is the indicator function of the rational numbers as a subset of the real numbers. == Definition == Given an arbitrary set X, the indicator function of a subset A of X is the function 1 A : X ↦ { 0 , 1 } {\displaystyle \mathbf {1} _{A}\colon X\mapsto \{0,1\}} defined by 1 A ( x ) = { 1 if x ∈ A 0 if x ∉ A . {\displaystyle \operatorname {\mathbf {1} } _{A}\!(x)={\begin{cases}1&{\text{if }}x\in A\\0&{\text{if }}x\notin A\,.\end{cases}}} The Iverson bracket provides the equivalent notation [ x ∈ A ] {\displaystyle \left[\ x\in A\ \right]} or ⟦ x ∈ A ⟧, that can be used instead of 1 A ( x ) . {\displaystyle \mathbf {1} _{A}\!(x).} The function 1 A {\displaystyle \mathbf {1} _{A}} is sometimes denoted 𝟙A, IA, χA or even just A. == Notation and terminology == The notation χ A {\displaystyle \chi _{A}} is also used to denote the characteristic function in convex analysis, which is defined as if using the reciprocal of the standard definition of the indicator function. A related concept in statistics is that of a dummy variable. (This must not be confused with "dummy variables" as that term is usually used in mathematics, also called a bound variable.) The term "characteristic function" has an unrelated meaning in classic probability theory. For this reason, traditional probabilists use the term indicator function for the function defined here almost exclusively, while mathematicians in other fields are more likely to use the term characteristic function to describe the function that indicates membership in a set. In fuzzy logic and modern many-valued logic, predicates are the characteristic functions of a probability distribution. That is, the strict true/false valuation of the predicate is replaced by a quantity interpreted as the degree of truth. == Basic properties == The indicator or characteristic function of a subset A of some set X maps elements of X to the codomain { 0 , 1 } . {\displaystyle \{0,\,1\}.} This mapping is surjective only when A is a non-empty proper subset of X. If A = X , {\displaystyle A=X,} then 1 A ≡ 1. {\displaystyle \mathbf {1} _{A}\equiv 1.} By a similar argument, if A = ∅ {\displaystyle A=\emptyset } then 1 A ≡ 0. {\displaystyle \mathbf {1} _{A}\equiv 0.} If A {\displaystyle A} and B {\displaystyle B} are two subsets of X , {\displaystyle X,} then 1 A ∩ B ( x ) = min { 1 A ( x ) , 1 B ( x ) } = 1 A ( x ) ⋅ 1 B ( x ) , 1 A ∪ B ( x ) = max { 1 A ( x ) , 1 B ( x ) } = 1 A ( x ) + 1 B ( x ) − 1 A ( x ) ⋅ 1 B ( x ) , {\displaystyle {\begin{aligned}\mathbf {1} _{A\cap B}(x)~&=~\min {\bigl \{}\mathbf {1} _{A}(x),\ \mathbf {1} _{B}(x){\bigr \}}~~=~\mathbf {1} _{A}(x)\cdot \mathbf {1} _{B}(x),\\\mathbf {1} _{A\cup B}(x)~&=~\max {\bigl \{}\mathbf {1} _{A}(x),\ \mathbf {1} _{B}(x){\bigr \}}~=~\mathbf {1} _{A}(x)+\mathbf {1} _{B}(x)-\mathbf {1} _{A}(x)\cdot \mathbf {1} _{B}(x)\,,\end{aligned}}} and the indicator function of the complement of A {\displaystyle A} i.e. A ∁ {\displaystyle A^{\complement }} is: 1 A ∁ = 1 − 1 A . {\displaystyle \mathbf {1} _{A^{\complement }}=1-\mathbf {1} _{A}.} More generally, suppose A 1 , … , A n {\displaystyle A_{1},\dotsc ,A_{n}} is a collection of subsets of X. For any x ∈ X : {\displaystyle x\in X:} ∏ k ∈ I ( 1 − 1 A k ( x ) ) {\displaystyle \prod _{k\in I}\left(\ 1-\mathbf {1} _{A_{k}}\!\left(x\right)\ \right)} is a product of 0s and 1s. This product has the value 1 at precisely those x ∈ X {\displaystyle x\in X} that belong to none of the sets A k {\displaystyle A_{k}} and is 0 otherwise. That is ∏ k ∈ I ( 1 − 1 A k ) = 1 X − ⋃ k A k = 1 − 1 ⋃ k A k . {\displaystyle \prod _{k\in I}(1-\mathbf {1} _{A_{k}})=\mathbf {1} _{X-\bigcup _{k}A_{k}}=1-\mathbf {1} _{\bigcup _{k}A_{k}}.} Expanding the product on the left hand side, 1 ⋃ k A k = 1 − ∑ F ⊆ { 1 , 2 , … , n } ( − 1 ) | F | 1 ⋂ F A k = ∑ ∅ ≠ F ⊆ { 1 , 2 , … , n } ( − 1 ) | F | + 1 1 ⋂ F A k {\displaystyle \mathbf {1} _{\bigcup _{k}A_{k}}=1-\sum _{F\subseteq \{1,2,\dotsc ,n\}}(-1)^{|F|}\mathbf {1} _{\bigcap _{F}A_{k}}=\sum _{\emptyset \neq F\subseteq \{1,2,\dotsc ,n\}}(-1)^{|F|+1}\mathbf {1} _{\bigcap _{F}A_{k}}} where | F | {\displaystyle |F|} is the cardinality of F. This is one form of the principle of inclusion-exclusion. As suggested by the previous example, the indicator function is a useful notational device in combinatorics. The notation is used in other places as well, for instance in probability theory: if X is a probability space with probability measure P {\displaystyle \mathbb {P} } and A is a measurable set, then 1 A {\displaystyle \mathbf {1} _{A}} becomes a random variable whose expected value is equal to the probability of A: E X ⁡ { 1 A ( x ) } = ∫ X 1 A ( x ) d P ⁡ ( x ) = ∫ A d P ⁡ ( x ) = P ⁡ ( A ) . {\displaystyle \operatorname {\mathbb {E} } _{X}\left\{\ \mathbf {1} _{A}(x)\ \right\}\ =\ \int _{X}\mathbf {1} _{A}(x)\ \operatorname {d\ \mathbb {P} } (x)=\int _{A}\operatorname {d\ \mathbb {P} } (x)=\operatorname {\mathbb {P} } (A).} This identity is used in a simple proof of Markov's inequality. In many cases, such as order theory, the inverse of the indicator function may be defined. This is commonly called the generalized Möbius function, as a generalization of the inverse of the indicator function in elementary number theory, the Möbius function. (See paragraph below about the use of the inverse in classical recursion theory.) == Mean, variance and covariance == Given a probability space ( Ω , F , P ) {\displaystyle \textstyle (\Omega ,{\mathcal {F}},\operatorname {P} )} with A ∈ F , {\displaystyle A\in {\mathcal {F}},} the indicator random variable 1 A : Ω → R {\displaystyle \mathbf {1} _{A}\colon \Omega \rightarrow \mathbb {R} } is defined by 1 A ( ω ) = 1 {\displaystyle \mathbf {1} _{A}(\omega )=1} if ω ∈ A , {\displaystyle \omega \in A,} otherwise 1 A ( ω ) = 0. {\displaystyle \mathbf {1} _{A}(\omega )=0.} Mean E ⁡ ( 1 A ( ω ) ) = P ⁡ ( A ) {\displaystyle \ \operatorname {\mathbb {E} } (\mathbf {1} _{A}(\omega ))=\operatorname {\mathbb {P} } (A)\ } (also called "Fundamental Bridge"). Variance Var ⁡ ( 1 A ( ω ) ) = P ⁡ ( A ) ( 1 − P ⁡ ( A ) ) . {\displaystyle \ \operatorname {Var} (\mathbf {1} _{A}(\omega ))=\operatorname {\mathbb {P} } (A)(1-\operatorname {\mathbb {P} } (A)).} Covariance Cov ⁡ ( 1 A ( ω ) , 1 B ( ω ) ) = P ⁡ ( A ∩ B ) − P ⁡ ( A ) P ⁡ ( B ) . {\displaystyle \ \operatorname {Cov} (\mathbf {1} _{A}(\omega ),\mathbf {1} _{B}(\omega ))=\operatorname {\mathbb {P} } (A\cap B)-\operatorname {\mathbb {P} } (A)\operatorname {\mathbb {P} } (B).} == Characteristic function in recursion theory, Gödel's and Kleene's representing function == Kurt Gödel described the representing function in his 1934 paper "On undecidable propositions of formal mathematical systems" (the symbol "¬" indicates logical inversion, i.e. "NOT"):: 42  There shall correspond to each class or relation R a representing function ϕ ( x 1 , … x n ) = 0 {\displaystyle \phi (x_{1},\ldots x_{n})=0} if R ( x 1 , … x n ) {\displaystyle R(x_{1},\ldots x_{n})} and ϕ ( x 1 , … x n ) = 1 {\displaystyle \phi (x_{1},\ldots x_{n})=1} if ¬ R ( x 1 , … x n ) . {\displaystyle \neg R(x_{1},\ldots x_{n}).} Kleene offers up the same definition in the context of the primitive recursive functions as a function φ of a predicate P takes on values 0 if the predicate is true and 1 if the predicate is false. For example, because the product of characteristic functions ϕ 1 ∗ ϕ 2 ∗ ⋯ ∗ ϕ n = 0 {\displaystyle \phi _{1}*\phi _{2}*\cdots *\phi _{n}=0} whenever any one of the functions equals 0, it plays the role of logical OR: IF ϕ 1 = 0 {\displaystyle \phi _{1}=0\ } OR ϕ 2 = 0 {\displaystyle \ \phi _{2}=0} OR ... OR ϕ n = 0 {\displaystyle \phi _{n}=0} THEN their product is 0. What appears to the modern reader as the representing function's logical inversion, i.e. the representing function is 0 when the function R is "true" or satisfied", plays a useful role in Kleene's definition of the logical functions OR, AND, and IMPLY,: 228  the bounded-: 228  and unbounded-: 279 ff  mu operators and the CASE function.: 229  == Characteristic function in fuzzy set theory == In classical mathematics, characteristic functions of sets only take values 1 (members) or 0 (non-members). In fuzzy set theory, characteristic functions are generalized to take value in the real unit interval [0, 1], or more generally, in some algebra or structure (usually required to be at least a poset or lattice). Such generalized characteristic functions are more usually called membership functions, and the corresponding "sets" are called fuzzy sets. Fuzzy sets model the gradual change in the membership degree seen in many real-world predicates like "tall", "warm", etc. == Smoothness == In general, the indicator function of a set is not smooth; it is continuous if and only if its support is a connected component. In the algebraic geometry of finite fields, however, every affine variety admits a (Zariski) continuous indicator function. Given a finite set of functions f α ∈ F q [ x 1 , … , x n ] {\displaystyle f_{\alpha }\in \mathbb {F} _{q}\left[\ x_{1},\ldots ,x_{n}\right]} let V = { x ∈ F q n : f α ( x ) = 0 } {\displaystyle V={\bigl \{}\ x\in \mathbb {F} _{q}^{n}:f_{\alpha }(x)=0\ {\bigr \}}} be their vanishing locus. Then, the function P ( x ) = ∏ ( 1 − f α ( x ) q − 1 ) {\textstyle \mathbb {P} (x)=\prod \left(\ 1-f_{\alpha }(x)^{q-1}\right)} acts as an indicator function for V . {\displaystyle V.} If x ∈ V {\displaystyle x\in V} then P ( x ) = 1 , {\displaystyle \mathbb {P} (x)=1,} otherwise, for some f α , {\displaystyle f_{\alpha },} we have f α ( x ) ≠ 0 {\displaystyle f_{\alpha }(x)\neq 0} which implies that f α ( x ) q − 1 = 1 , {\displaystyle f_{\alpha }(x)^{q-1}=1,} hence P ( x ) = 0. {\displaystyle \mathbb {P} (x)=0.} Although indicator functions are not smooth, they admit weak derivatives. For example, consider Heaviside step function H ( x ) ≡ I ( x > 0 ) {\displaystyle H(x)\equiv \operatorname {\mathbb {I} } \!{\bigl (}x>0{\bigr )}} The distributional derivative of the Heaviside step function is equal to the Dirac delta function, i.e. d H ( x ) d x = δ ( x ) {\displaystyle {\frac {\mathrm {d} H(x)}{\mathrm {d} x}}=\delta (x)} and similarly the distributional derivative of G ( x ) := I ( x < 0 ) {\displaystyle G(x):=\operatorname {\mathbb {I} } \!{\bigl (}x<0{\bigr )}} is d G ( x ) d x = − δ ( x ) . {\displaystyle {\frac {\mathrm {d} G(x)}{\mathrm {d} x}}=-\delta (x).} Thus the derivative of the Heaviside step function can be seen as the inward normal derivative at the boundary of the domain given by the positive half-line. In higher dimensions, the derivative naturally generalises to the inward normal derivative, while the Heaviside step function naturally generalises to the indicator function of some domain D. The surface of D will be denoted by S. Proceeding, it can be derived that the inward normal derivative of the indicator gives rise to a surface delta function, which can be indicated by δ S ( x ) {\displaystyle \delta _{S}(\mathbf {x} )} : δ S ( x ) = − n x ⋅ ∇ x I ( x ∈ D ) {\displaystyle \delta _{S}(\mathbf {x} )=-\mathbf {n} _{x}\cdot \nabla _{x}\operatorname {\mathbb {I} } \!{\bigl (}\ \mathbf {x} \in D\ {\bigr )}\ } where n is the outward normal of the surface S. This 'surface delta function' has the following property: − ∫ R n f ( x ) n x ⋅ ∇ x I ( x ∈ D ) d n ⁡ x = ∮ S f ( β ) d n − 1 ⁡ β . {\displaystyle -\int _{\mathbb {R} ^{n}}f(\mathbf {x} )\,\mathbf {n} _{x}\cdot \nabla _{x}\operatorname {\mathbb {I} } \!{\bigl (}\ \mathbf {x} \in D\ {\bigr )}\;\operatorname {d} ^{n}\mathbf {x} =\oint _{S}\,f(\mathbf {\beta } )\;\operatorname {d} ^{n-1}\mathbf {\beta } .} By setting the function f equal to one, it follows that the inward normal derivative of the indicator integrates to the numerical value of the surface area S. == See also == == Notes == == References == == Sources ==
Wikipedia/Indicator_function
Boolean algebras are models of the equational theory of two values; this definition is equivalent to the lattice and ring definitions. Boolean algebra is a mathematically rich branch of abstract algebra. Stanford Encyclopaedia of Philosophy defines Boolean algebra as 'the algebra of two-valued logic with only sentential connectives, or equivalently of algebras of sets under union and complementation.' Just as group theory deals with groups, and linear algebra with vector spaces, Boolean algebras are models of the equational theory of the two values 0 and 1 (whose interpretation need not be numerical). Common to Boolean algebras, groups, and vector spaces is the notion of an algebraic structure, a set closed under some operations satisfying certain equations. Just as there are basic examples of groups, such as the group Z {\displaystyle \mathbb {Z} } of integers and the symmetric group Sn of permutations of n objects, there are also basic examples of Boolean algebras such as the following. The algebra of binary digits or bits 0 and 1 under the logical operations including disjunction, conjunction, and negation. Applications include the propositional calculus and the theory of digital circuits. The algebra of sets under the set operations including union, intersection, and complement. Applications are far-reaching because set theory is the standard foundations of mathematics. Boolean algebra thus permits applying the methods of abstract algebra to mathematical logic and digital logic. Unlike groups of finite order, which exhibit complexity and diversity and whose first-order theory is decidable only in special cases, all finite Boolean algebras share the same theorems and have a decidable first-order theory. Instead, the intricacies of Boolean algebra are divided between the structure of infinite algebras and the algorithmic complexity of their syntactic structure. == Definition == Boolean algebra treats the equational theory of the maximal two-element finitary algebra, called the Boolean prototype, and the models of that theory, called Boolean algebras. These terms are defined as follows. An algebra is a family of operations on a set, called the underlying set of the algebra. We take the underlying set of the Boolean prototype to be {0,1}. An algebra is finitary when each of its operations takes only finitely many arguments. For the prototype each argument of an operation is either 0 or 1, as is the result of the operation. The maximal such algebra consists of all finitary operations on {0,1}. The number of arguments taken by each operation is called the arity of the operation. An operation on {0,1} of arity n, or n-ary operation, can be applied to any of 2n possible values for its n arguments. For each choice of arguments, the operation may return 0 or 1, whence there are 22n n-ary operations. The prototype therefore has two operations taking no arguments, called zeroary or nullary operations, namely zero and one. It has four unary operations, two of which are constant operations, another is the identity, and the most commonly used one, called negation, returns the opposite of its argument: 1 if 0, 0 if 1. It has sixteen binary operations; again two of these are constant, another returns its first argument, yet another returns its second, one is called conjunction and returns 1 if both arguments are 1 and otherwise 0, another is called disjunction and returns 0 if both arguments are 0 and otherwise 1, and so on. The number of (n+1)-ary operations in the prototype is the square of the number of n-ary operations, so there are 162 = 256 ternary operations, 2562 = 65,536 quaternary operations, and so on. A family is indexed by an index set. In the case of a family of operations forming an algebra, the indices are called operation symbols, constituting the language of that algebra. The operation indexed by each symbol is called the denotation or interpretation of that symbol. Each operation symbol specifies the arity of its interpretation, whence all possible interpretations of a symbol have the same arity. In general it is possible for an algebra to interpret distinct symbols with the same operation, but this is not the case for the prototype, whose symbols are in one-one correspondence with its operations. The prototype therefore has 22n n-ary operation symbols, called the Boolean operation symbols and forming the language of Boolean algebra. Only a few operations have conventional symbols, such as ¬ for negation, ∧ for conjunction, and ∨ for disjunction. It is convenient to consider the i-th n-ary symbol to be nfi as done below in the section on truth tables. An equational theory in a given language consists of equations between terms built up from variables using symbols of that language. Typical equations in the language of Boolean algebra are x∧y = y∧x, x∧x = x, x∧¬x = y∧¬y, and x∧y = x. An algebra satisfies an equation when the equation holds for all possible values of its variables in that algebra when the operation symbols are interpreted as specified by that algebra. The laws of Boolean algebra are the equations in the language of Boolean algebra satisfied by the prototype. The first three of the above examples are Boolean laws, but not the fourth since 1∧0 ≠ 1. The equational theory of an algebra is the set of all equations satisfied by the algebra. The laws of Boolean algebra therefore constitute the equational theory of the Boolean prototype. A model of a theory is an algebra interpreting the operation symbols in the language of the theory and satisfying the equations of the theory. A Boolean algebra is any model of the laws of Boolean algebra. That is, a Boolean algebra is a set and a family of operations thereon interpreting the Boolean operation symbols and satisfying the same laws as the Boolean prototype. If we define a homologue of an algebra to be a model of the equational theory of that algebra, then a Boolean algebra can be defined as any homologue of the prototype. Example 1. The Boolean prototype is a Boolean algebra, since trivially it satisfies its own laws. It is thus the prototypical Boolean algebra. We did not call it that initially in order to avoid any appearance of circularity in the definition. == Basis == The operations need not be all explicitly stated. A basis is any set from which the remaining operations can be obtained by composition. A "Boolean algebra" may be defined from any of several different bases. Three bases for Boolean algebra are in common use, the lattice basis, the ring basis, and the Sheffer stroke or NAND basis. These bases impart respectively a logical, an arithmetical, and a parsimonious character to the subject. The lattice basis originated in the 19th century with the work of Boole, Peirce, and others seeking an algebraic formalization of logical thought processes. The ring basis emerged in the 20th century with the work of Zhegalkin and Stone and became the basis of choice for algebraists coming to the subject from a background in abstract algebra. Most treatments of Boolean algebra assume the lattice basis, a notable exception being Halmos[1963] whose linear algebra background evidently endeared the ring basis to him. Since all finitary operations on {0,1} can be defined in terms of the Sheffer stroke NAND (or its dual NOR), the resulting economical basis has become the basis of choice for analyzing digital circuits, in particular gate arrays in digital electronics. The common elements of the lattice and ring bases are the constants 0 and 1, and an associative commutative binary operation, called meet x∧y in the lattice basis, and multiplication xy in the ring basis. The distinction is only terminological. The lattice basis has the further operations of join, x∨y, and complement, ¬x. The ring basis has instead the arithmetic operation x⊕y of addition (the symbol ⊕ is used in preference to + because the latter is sometimes given the Boolean reading of join). To be a basis is to yield all other operations by composition, whence any two bases must be intertranslatable. The lattice basis translates x∨y to the ring basis as x⊕y⊕xy, and ¬x as x⊕1. Conversely the ring basis translates x⊕y to the lattice basis as (x∨y)∧¬(x∧y). Both of these bases allow Boolean algebras to be defined via a subset of the equational properties of the Boolean operations. For the lattice basis, it suffices to define a Boolean algebra as a distributive lattice satisfying x∧¬x = 0 and x∨¬x = 1, called a complemented distributive lattice. The ring basis turns a Boolean algebra into a Boolean ring, namely a ring satisfying x2 = x. Emil Post gave a necessary and sufficient condition for a set of operations to be a basis for the nonzeroary Boolean operations. A nontrivial property is one shared by some but not all operations making up a basis. Post listed five nontrivial properties of operations, identifiable with the five Post's classes, each preserved by composition, and showed that a set of operations formed a basis if, for each property, the set contained an operation lacking that property. (The converse of Post's theorem, extending "if" to "if and only if," is the easy observation that a property from among these five holding of every operation in a candidate basis will also hold of every operation formed by composition from that candidate, whence by nontriviality of that property the candidate will fail to be a basis.) Post's five properties are: monotone, no 0-1 input transition can cause a 1-0 output transition; affine, representable with Zhegalkin polynomials that lack bilinear or higher terms, e.g. x⊕y⊕1 but not xy; self-dual, so that complementing all inputs complements the output, as with x, or the median operator xy⊕yz⊕zx, or their negations; strict (mapping the all-zeros input to zero); costrict (mapping all-ones to one). The NAND (dually NOR) operation lacks all these, thus forming a basis by itself. == Truth tables == The finitary operations on {0,1} may be exhibited as truth tables, thinking of 0 and 1 as the truth values false and true. They can be laid out in a uniform and application-independent way that allows us to name, or at least number, them individually. These names provide a convenient shorthand for the Boolean operations. The names of the n-ary operations are binary numbers of 2n bits. There being 22n such operations, one cannot ask for a more succinct nomenclature. Note that each finitary operation can be called a switching function. This layout and associated naming of operations is illustrated here in full for arities from 0 to 2. These tables continue at higher arities, with 2n rows at arity n, each row giving a valuation or binding of the n variables x0,...xn−1 and each column headed nfi giving the value nfi(x0,...,xn−1) of the i-th n-ary operation at that valuation. The operations include the variables, for example 1f2 is x0 while 2f10 is x0 (as two copies of its unary counterpart) and 2f12 is x1 (with no unary counterpart). Negation or complement ¬x0 appears as 1f1 and again as 2f5, along with 2f3 (¬x1, which did not appear at arity 1), disjunction or union x0∨x1 as 2f14, conjunction or intersection x0∧x1 as 2f8, implication x0→x1 as 2f13, exclusive-or symmetric difference x0⊕x1 as 2f6, set difference x0−x1 as 2f2, and so on. As a minor detail important more for its form than its content, the operations of an algebra are traditionally organized as a list. Although we are here indexing the operations of a Boolean algebra by the finitary operations on {0,1}, the truth-table presentation above serendipitously orders the operations first by arity and second by the layout of the tables for each arity. This permits organizing the set of all Boolean operations in the traditional list format. The list order for the operations of a given arity is determined by the following two rules. (i) The i-th row in the left half of the table is the binary representation of i with its least significant or 0-th bit on the left ("little-endian" order, originally proposed by Alan Turing, so it would not be unreasonable to call it Turing order). (ii) The j-th column in the right half of the table is the binary representation of j, again in little-endian order. In effect the subscript of the operation is the truth table of that operation. By analogy with Gödel numbering of computable functions one might call this numbering of the Boolean operations the Boole numbering. When programming in C or Java, bitwise disjunction is denoted x|y, conjunction x&y, and negation ~x. A program can therefore represent for example the operation x∧(y∨z) in these languages as x&(y|z), having previously set x = 0xaa, y = 0xcc, and z = 0xf0 (the "0x" indicates that the following constant is to be read in hexadecimal or base 16), either by assignment to variables or defined as macros. These one-byte (eight-bit) constants correspond to the columns for the input variables in the extension of the above tables to three variables. This technique is almost universally used in raster graphics hardware to provide a flexible variety of ways of combining and masking images, the typical operations being ternary and acting simultaneously on source, destination, and mask bits. == Examples == === Bit vectors === Example 2. All bit vectors of a given length form a Boolean algebra "pointwise", meaning that any n-ary Boolean operation can be applied to n bit vectors one bit position at a time. For example, the ternary OR of three bit vectors each of length 4 is the bit vector of length 4 formed by or-ing the three bits in each of the four bit positions, thus 0100∨1000∨1001 = 1101. Another example is the truth tables above for the n-ary operations, whose columns are all the bit vectors of length 2n and which therefore can be combined pointwise whence the n-ary operations form a Boolean algebra. This works equally well for bit vectors of finite and infinite length, the only rule being that the bit positions all be indexed by the same set in order that "corresponding position" be well defined. The atoms of such an algebra are the bit vectors containing exactly one 1. In general the atoms of a Boolean algebra are those elements x such that x∧y has only two possible values, x or 0. === Power set algebra === Example 3. The power set algebra, the set 2W of all subsets of a given set W. This is just Example 2 in disguise, with W serving to index the bit positions. Any subset X of W can be viewed as the bit vector having 1's in just those bit positions indexed by elements of X. Thus the all-zero vector is the empty subset of W while the all-ones vector is W itself, these being the constants 0 and 1 respectively of the power set algebra. The counterpart of disjunction x∨y is union X∪Y, while that of conjunction x∧y is intersection X∩Y. Negation ¬x becomes ~X, complement relative to W. There is also set difference X\Y = X∩~Y, symmetric difference (X\Y)∪(Y\X), ternary union X∪Y∪Z, and so on. The atoms here are the singletons, those subsets with exactly one element. Examples 2 and 3 are special cases of a general construct of algebra called direct product, applicable not just to Boolean algebras but all kinds of algebra including groups, rings, etc. The direct product of any family Bi of Boolean algebras where i ranges over some index set I (not necessarily finite or even countable) is a Boolean algebra consisting of all I-tuples (...xi,...) whose i-th element is taken from Bi. The operations of a direct product are the corresponding operations of the constituent algebras acting within their respective coordinates; in particular operation nfj of the product operates on n I-tuples by applying operation nfj of Bi to the n elements in the i-th coordinate of the n tuples, for all i in I. When all the algebras being multiplied together in this way are the same algebra A we call the direct product a direct power of A. The Boolean algebra of all 32-bit bit vectors is the two-element Boolean algebra raised to the 32nd power, or power set algebra of a 32-element set, denoted 232. The Boolean algebra of all sets of integers is 2Z. All Boolean algebras we have exhibited thus far have been direct powers of the two-element Boolean algebra, justifying the name "power set algebra". === Representation theorems === It can be shown that every finite Boolean algebra is isomorphic to some power set algebra. Hence the cardinality (number of elements) of a finite Boolean algebra is a power of 2, namely one of 1,2,4,8,...,2n,... This is called a representation theorem as it gives insight into the nature of finite Boolean algebras by giving a representation of them as power set algebras. This representation theorem does not extend to infinite Boolean algebras: although every power set algebra is a Boolean algebra, not every Boolean algebra need be isomorphic to a power set algebra. In particular, whereas there can be no countably infinite power set algebras (the smallest infinite power set algebra is the power set algebra 2N of sets of natural numbers, shown by Cantor to be uncountable), there exist various countably infinite Boolean algebras. To go beyond power set algebras we need another construct. A subalgebra of an algebra A is any subset of A closed under the operations of A. Every subalgebra of a Boolean algebra A must still satisfy the equations holding of A, since any violation would constitute a violation for A itself. Hence every subalgebra of a Boolean algebra is a Boolean algebra. A subalgebra of a power set algebra is called a field of sets; equivalently a field of sets is a set of subsets of some set W including the empty set and W and closed under finite union and complement with respect to W (and hence also under finite intersection). Birkhoff's [1935] representation theorem for Boolean algebras states that every Boolean algebra is isomorphic to a field of sets. Now Birkhoff's HSP theorem for varieties can be stated as, every class of models of the equational theory of a class C of algebras is the Homomorphic image of a Subalgebra of a direct Product of algebras of C. Normally all three of H, S, and P are needed; what the first of these two Birkhoff theorems shows is that for the special case of the variety of Boolean algebras Homomorphism can be replaced by Isomorphism. Birkhoff's HSP theorem for varieties in general therefore becomes Birkhoff's ISP theorem for the variety of Boolean algebras. === Other examples === It is convenient when talking about a set X of natural numbers to view it as a sequence x0,x1,x2,... of bits, with xi = 1 if and only if i ∈ X. This viewpoint will make it easier to talk about subalgebras of the power set algebra 2N, which this viewpoint makes the Boolean algebra of all sequences of bits. It also fits well with the columns of a truth table: when a column is read from top to bottom it constitutes a sequence of bits, but at the same time it can be viewed as the set of those valuations (assignments to variables in the left half of the table) at which the function represented by that column evaluates to 1. Example 4. Ultimately constant sequences. Any Boolean combination of ultimately constant sequences is ultimately constant; hence these form a Boolean algebra. We can identify these with the integers by viewing the ultimately-zero sequences as nonnegative binary numerals (bit 0 of the sequence being the low-order bit) and the ultimately-one sequences as negative binary numerals (think two's complement arithmetic with the all-ones sequence being −1). This makes the integers a Boolean algebra, with union being bit-wise OR and complement being −x−1. There are only countably many integers, so this infinite Boolean algebra is countable. The atoms are the powers of two, namely 1,2,4,.... Another way of describing this algebra is as the set of all finite and cofinite sets of natural numbers, with the ultimately all-ones sequences corresponding to the cofinite sets, those sets omitting only finitely many natural numbers. Example 5. Periodic sequence. A sequence is called periodic when there exists some number n > 0, called a witness to periodicity, such that xi = xi+n for all i ≥ 0. The period of a periodic sequence is its least witness. Negation leaves period unchanged, while the disjunction of two periodic sequences is periodic, with period at most the least common multiple of the periods of the two arguments (the period can be as small as 1, as happens with the union of any sequence and its complement). Hence the periodic sequences form a Boolean algebra. Example 5 resembles Example 4 in being countable, but differs in being atomless. The latter is because the conjunction of any nonzero periodic sequence x with a sequence of coprime period (greater than 1) is neither 0 nor x. It can be shown that all countably infinite atomless Boolean algebras are isomorphic, that is, up to isomorphism there is only one such algebra. Example 6. Periodic sequence with period a power of two. This is a proper subalgebra of Example 5 (a proper subalgebra equals the intersection of itself with its algebra). These can be understood as the finitary operations, with the first period of such a sequence giving the truth table of the operation it represents. For example, the truth table of x0 in the table of binary operations, namely 2f10, has period 2 (and so can be recognized as using only the first variable) even though 12 of the binary operations have period 4. When the period is 2n the operation only depends on the first n variables, the sense in which the operation is finitary. This example is also a countably infinite atomless Boolean algebra. Hence Example 5 is isomorphic to a proper subalgebra of itself! Example 6, and hence Example 5, constitutes the free Boolean algebra on countably many generators, meaning the Boolean algebra of all finitary operations on a countably infinite set of generators or variables. Example 7. Ultimately periodic sequences, sequences that become periodic after an initial finite bout of lawlessness. They constitute a proper extension of Example 5 (meaning that Example 5 is a proper subalgebra of Example 7) and also of Example 4, since constant sequences are periodic with period one. Sequences may vary as to when they settle down, but any finite set of sequences will all eventually settle down no later than their slowest-to-settle member, whence ultimately periodic sequences are closed under all Boolean operations and so form a Boolean algebra. This example has the same atoms and coatoms as Example 4, whence it is not atomless and therefore not isomorphic to Example 5/6. However it contains an infinite atomless subalgebra, namely Example 5, and so is not isomorphic to Example 4, every subalgebra of which must be a Boolean algebra of finite sets and their complements and therefore atomic. This example is isomorphic to the direct product of Examples 4 and 5, furnishing another description of it. Example 8. The direct product of a Periodic Sequence (Example 5) with any finite but nontrivial Boolean algebra. (The trivial one-element Boolean algebra is the unique finite atomless Boolean algebra.) This resembles Example 7 in having both atoms and an atomless subalgebra, but differs in having only finitely many atoms. Example 8 is in fact an infinite family of examples, one for each possible finite number of atoms. These examples by no means exhaust the possible Boolean algebras, even the countable ones. Indeed, there are uncountably many nonisomorphic countable Boolean algebras, which Jussi Ketonen [1978] classified completely in terms of invariants representable by certain hereditarily countable sets. == Boolean algebras of Boolean operations == The n-ary Boolean operations themselves constitute a power set algebra 2W, namely when W is taken to be the set of 2n valuations of the n inputs. In terms of the naming system of operations nfi where i in binary is a column of a truth table, the columns can be combined with Boolean operations of any arity to produce other columns present in the table. That is, we can apply any Boolean operation of arity m to m Boolean operations of arity n to yield a Boolean operation of arity n, for any m and n. The practical significance of this convention for both software and hardware is that n-ary Boolean operations can be represented as words of the appropriate length. For example, each of the 256 ternary Boolean operations can be represented as an unsigned byte. The available logical operations such as AND and OR can then be used to form new operations. If we take x, y, and z (dispensing with subscripted variables for now) to be 10101010, 11001100, and 11110000 respectively (170, 204, and 240 in decimal, 0xaa, 0xcc, and 0xf0 in hexadecimal), their pairwise conjunctions are x∧y = 10001000, y∧z = 11000000, and z∧x = 10100000, while their pairwise disjunctions are x∨y = 11101110, y∨z = 11111100, and z∨x = 11111010. The disjunction of the three conjunctions is 11101000, which also happens to be the conjunction of three disjunctions. We have thus calculated, with a dozen or so logical operations on bytes, that the two ternary operations ( x ∧ y ) ∨ ( y ∧ z ) ∨ ( z ∧ x ) {\displaystyle (x\land y)\lor (y\land z)\lor (z\land x)} and ( x ∨ y ) ∧ ( y ∨ z ) ∧ ( z ∨ x ) {\displaystyle (x\lor y)\land (y\lor z)\land (z\lor x)} are actually the same operation. That is, we have proved the equational identity ( x ∧ y ) ∨ ( y ∧ z ) ∨ ( z ∧ x ) = ( x ∨ y ) ∧ ( y ∨ z ) ∧ ( z ∨ x ) {\displaystyle (x\land y)\lor (y\land z)\lor (z\land x)=(x\lor y)\land (y\lor z)\land (z\lor x)} , for the two-element Boolean algebra. By the definition of "Boolean algebra" this identity must therefore hold in every Boolean algebra. This ternary operation incidentally formed the basis for Grau's [1947] ternary Boolean algebras, which he axiomatized in terms of this operation and negation. The operation is symmetric, meaning that its value is independent of any of the 3! = 6 permutations of its arguments. The two halves of its truth table 11101000 are the truth tables for ∨, 1110, and ∧, 1000, so the operation can be phrased as if z then x∨y else x∧y. Since it is symmetric it can equally well be phrased as either of if x then y∨z else y∧z, or if y then z∨x else z∧x. Viewed as a labeling of the 8-vertex 3-cube, the upper half is labeled 1 and the lower half 0; for this reason it has been called the median operator, with the evident generalization to any odd number of variables (odd in order to avoid the tie when exactly half the variables are 0). == Axiomatizing Boolean algebras == The technique we just used to prove an identity of Boolean algebra can be generalized to all identities in a systematic way that can be taken as a sound and complete axiomatization of, or axiomatic system for, the equational laws of Boolean logic. The customary formulation of an axiom system consists of a set of axioms that "prime the pump" with some initial identities, along with a set of inference rules for inferring the remaining identities from the axioms and previously proved identities. In principle it is desirable to have finitely many axioms; however as a practical matter it is not necessary since it is just as effective to have a finite axiom schema having infinitely many instances each of which when used in a proof can readily be verified to be a legal instance, the approach we follow here. Boolean identities are assertions of the form s = t where s and t are n-ary terms, by which we shall mean here terms whose variables are limited to x0 through xn-1. An n-ary term is either an atom or an application. An application mfi(t0,...,tm-1) is a pair consisting of an m-ary operation mfi and a list or m-tuple (t0,...,tm-1) of m n-ary terms called operands. Associated with every term is a natural number called its height. Atoms are of zero height, while applications are of height one plus the height of their highest operand. Now what is an atom? Conventionally an atom is either a constant (0 or 1) or a variable xi where 0 ≤ i < n. For the proof technique here it is convenient to define atoms instead to be n-ary operations nfi, which although treated here as atoms nevertheless mean the same as ordinary terms of the exact form nfi(x0,...,xn-1) (exact in that the variables must listed in the order shown without repetition or omission). This is not a restriction because atoms of this form include all the ordinary atoms, namely the constants 0 and 1, which arise here as the n-ary operations nf0 and nf−1 for each n (abbreviating 22n−1 to −1), and the variables x0,...,xn-1 as can be seen from the truth tables where x0 appears as both the unary operation 1f2 and the binary operation 2f10 while x1 appears as 2f12. The following axiom schema and three inference rules axiomatize the Boolean algebra of n-ary terms. A1. mfi(nfj0,...,nfjm-1) = nfioĵ where (ioĵ)v = iĵv, with ĵ being j transpose, defined by (ĵv)u = (ju)v. R1. With no premises infer t = t. R2. From s = u and t = u infer s = t where s, t, and u are n-ary terms. R3. From s0 = t0 , ... , sm-1 = tm-1 infer mfi(s0,...,sm-1) = mfi(t0,...,tm-1), where all terms si, ti are n-ary. The meaning of the side condition on A1 is that ioĵ is that 2n-bit number whose v-th bit is the ĵv-th bit of i, where the ranges of each quantity are u: m, v: 2n, ju: 22n, and ĵv: 2m. (So j is an m-tuple of 2n-bit numbers while ĵ as the transpose of j is a 2n-tuple of m-bit numbers. Both j and ĵ therefore contain m2n bits.) A1 is an axiom schema rather than an axiom by virtue of containing metavariables, namely m, i, n, and j0 through jm-1. The actual axioms of the axiomatization are obtained by setting the metavariables to specific values. For example, if we take m = n = i = j0 = 1, we can compute the two bits of ioĵ from i1 = 0 and i0 = 1, so ioĵ = 2 (or 10 when written as a two-bit number). The resulting instance, namely 1f1(1f1) = 1f2, expresses the familiar axiom ¬¬x = x of double negation. Rule R3 then allows us to infer ¬¬¬x = ¬x by taking s0 to be 1f1(1f1) or ¬¬x0, t0 to be 1f2 or x0, and mfi to be 1f1 or ¬. For each m and n there are only finitely many axioms instantiating A1, namely 22m × (22n)m. Each instance is specified by 2m+m2n bits. We treat R1 as an inference rule, even though it is like an axiom in having no premises, because it is a domain-independent rule along with R2 and R3 common to all equational axiomatizations, whether of groups, rings, or any other variety. The only entity specific to Boolean algebras is axiom schema A1. In this way when talking about different equational theories we can push the rules to one side as being independent of the particular theories, and confine attention to the axioms as the only part of the axiom system characterizing the particular equational theory at hand. This axiomatization is complete, meaning that every Boolean law s = t is provable in this system. One first shows by induction on the height of s that every Boolean law for which t is atomic is provable, using R1 for the base case (since distinct atoms are never equal) and A1 and R3 for the induction step (s an application). This proof strategy amounts to a recursive procedure for evaluating s to yield an atom. Then to prove s = t in the general case when t may be an application, use the fact that if s = t is an identity then s and t must evaluate to the same atom, call it u. So first prove s = u and t = u as above, that is, evaluate s and t using A1, R1, and R3, and then invoke R2 to infer s = t. In A1, if we view the number nm as the function type m→n, and mn as the application m(n), we can reinterpret the numbers i, j, ĵ, and ioĵ as functions of type i: (m→2)→2, j: m→((n→2)→2), ĵ: (n→2)→(m→2), and ioĵ: (n→2)→2. The definition (ioĵ)v = iĵv in A1 then translates to (ioĵ)(v) = i(ĵ(v)), that is, ioĵ is defined to be composition of i and ĵ understood as functions. So the content of A1 amounts to defining term application to be essentially composition, modulo the need to transpose the m-tuple j to make the types match up suitably for composition. This composition is the one in Lawvere's previously mentioned category of power sets and their functions. In this way we have translated the commuting diagrams of that category, as the equational theory of Boolean algebras, into the equational consequences of A1 as the logical representation of that particular composition law. == Underlying lattice structure == Underlying every Boolean algebra B is a partially ordered set or poset (B,≤). The partial order relation is defined by x ≤ y just when x = x∧y, or equivalently when y = x∨y. Given a set X of elements of a Boolean algebra, an upper bound on X is an element y such that for every element x of X, x ≤ y, while a lower bound on X is an element y such that for every element x of X, y ≤ x. A sup of X is a least upper bound on X, namely an upper bound on X that is less or equal to every upper bound on X. Dually an inf of X is a greatest lower bound on X. The sup of x and y always exists in the underlying poset of a Boolean algebra, being x∨y, and likewise their inf exists, namely x∧y. The empty sup is 0 (the bottom element) and the empty inf is 1 (top). It follows that every finite set has both a sup and an inf. Infinite subsets of a Boolean algebra may or may not have a sup and/or an inf; in a power set algebra they always do. Any poset (B,≤) such that every pair x,y of elements has both a sup and an inf is called a lattice. We write x∨y for the sup and x∧y for the inf. The underlying poset of a Boolean algebra always forms a lattice. The lattice is said to be distributive when x∧(y∨z) = (x∧y)∨(x∧z), or equivalently when x∨(y∧z) = (x∨y)∧(x∨z), since either law implies the other in a lattice. These are laws of Boolean algebra whence the underlying poset of a Boolean algebra forms a distributive lattice. Given a lattice with a bottom element 0 and a top element 1, a pair x,y of elements is called complementary when x∧y = 0 and x∨y = 1, and we then say that y is a complement of x and vice versa. Any element x of a distributive lattice with top and bottom can have at most one complement. When every element of a lattice has a complement the lattice is called complemented. It follows that in a complemented distributive lattice, the complement of an element always exists and is unique, making complement a unary operation. Furthermore, every complemented distributive lattice forms a Boolean algebra, and conversely every Boolean algebra forms a complemented distributive lattice. This provides an alternative definition of a Boolean algebra, namely as any complemented distributive lattice. Each of these three properties can be axiomatized with finitely many equations, whence these equations taken together constitute a finite axiomatization of the equational theory of Boolean algebras. In a class of algebras defined as all the models of a set of equations, it is usually the case that some algebras of the class satisfy more equations than just those needed to qualify them for the class. The class of Boolean algebras is unusual in that, with a single exception, every Boolean algebra satisfies exactly the Boolean identities and no more. The exception is the one-element Boolean algebra, which necessarily satisfies every equation, even x = y, and is therefore sometimes referred to as the inconsistent Boolean algebra. == Boolean homomorphisms == A Boolean homomorphism is a function h: A→B between Boolean algebras A,B such that for every Boolean operation mfi: h ( m f i ( x 0 , . . . , x m − 1 ) ) = m f i ( h ( x 0 , . . . , x m − 1 ) ) {\displaystyle h(^{m}\!f_{i}(x_{0},...,x_{m-1}))={}^{m}\!f_{i}(h(x_{0},...,x_{m-1}))} The category Bool of Boolean algebras has as objects all Boolean algebras and as morphisms the Boolean homomorphisms between them. There exists a unique homomorphism from the two-element Boolean algebra 2 to every Boolean algebra, since homomorphisms must preserve the two constants and those are the only elements of 2. A Boolean algebra with this property is called an initial Boolean algebra. It can be shown that any two initial Boolean algebras are isomorphic, so up to isomorphism 2 is the initial Boolean algebra. In the other direction, there may exist many homomorphisms from a Boolean algebra B to 2. Any such homomorphism partitions B into those elements mapped to 1 and those to 0. The subset of B consisting of the former is called an ultrafilter of B. When B is finite its ultrafilters pair up with its atoms; one atom is mapped to 1 and the rest to 0. Each ultrafilter of B thus consists of an atom of B and all the elements above it; hence exactly half the elements of B are in the ultrafilter, and there as many ultrafilters as atoms. For infinite Boolean algebras the notion of ultrafilter becomes considerably more delicate. The elements greater than or equal to an atom always form an ultrafilter, but so do many other sets; for example, in the Boolean algebra of finite and cofinite sets of integers, the cofinite sets form an ultrafilter even though none of them are atoms. Likewise, the powerset of the integers has among its ultrafilters the set of all subsets containing a given integer; there are countably many of these "standard" ultrafilters, which may be identified with the integers themselves, but there are uncountably many more "nonstandard" ultrafilters. These form the basis for nonstandard analysis, providing representations for such classically inconsistent objects as infinitesimals and delta functions. == Infinitary extensions == Recall the definition of sup and inf from the section above on the underlying partial order of a Boolean algebra. A complete Boolean algebra is one every subset of which has both a sup and an inf, even the infinite subsets. Gaifman [1964] and Hales [1964] independently showed that infinite free complete Boolean algebras do not exist. This suggests that a logic with set-sized-infinitary operations may have class-many terms—just as a logic with finitary operations may have infinitely many terms. There is however another approach to introducing infinitary Boolean operations: simply drop "finitary" from the definition of Boolean algebra. A model of the equational theory of the algebra of all operations on {0,1} of arity up to the cardinality of the model is called a complete atomic Boolean algebra, or CABA. (In place of this awkward restriction on arity we could allow any arity, leading to a different awkwardness, that the signature would then be larger than any set, that is, a proper class. One benefit of the latter approach is that it simplifies the definition of homomorphism between CABAs of different cardinality.) Such an algebra can be defined equivalently as a complete Boolean algebra that is atomic, meaning that every element is a sup of some set of atoms. Free CABAs exist for all cardinalities of a set V of generators, namely the power set algebra 22V, this being the obvious generalization of the finite free Boolean algebras. This neatly rescues infinitary Boolean logic from the fate the Gaifman–Hales result seemed to consign it to. The nonexistence of free complete Boolean algebras can be traced to failure to extend the equations of Boolean logic suitably to all laws that should hold for infinitary conjunction and disjunction, in particular the neglect of distributivity in the definition of complete Boolean algebra. A complete Boolean algebra is called completely distributive when arbitrary conjunctions distribute over arbitrary disjunctions and vice versa. A Boolean algebra is a CABA if and only if it is complete and completely distributive, giving a third definition of CABA. A fourth definition is as any Boolean algebra isomorphic to a power set algebra. A complete homomorphism is one that preserves all sups that exist, not just the finite sups, and likewise for infs. The category CABA of all CABAs and their complete homomorphisms is dual to the category of sets and their functions, meaning that it is equivalent to the opposite of that category (the category resulting from reversing all morphisms). Things are not so simple for the category Bool of Boolean algebras and their homomorphisms, which Marshall Stone showed in effect (though he lacked both the language and the conceptual framework to make the duality explicit) to be dual to the category of totally disconnected compact Hausdorff spaces, subsequently called Stone spaces. Another infinitary class intermediate between Boolean algebras and complete Boolean algebras is the notion of a sigma-algebra. This is defined analogously to complete Boolean algebras, but with sups and infs limited to countable arity. That is, a sigma-algebra is a Boolean algebra with all countable sups and infs. Because the sups and infs are of bounded cardinality, unlike the situation with complete Boolean algebras, the Gaifman-Hales result does not apply and free sigma-algebras do exist. Unlike the situation with CABAs however, the free countably generated sigma algebra is not a power set algebra. == Other definitions of Boolean algebra == We have already encountered several definitions of Boolean algebra, as a model of the equational theory of the two-element algebra, as a complemented distributive lattice, as a Boolean ring, and as a product-preserving functor from a certain category (Lawvere). Two more definitions worth mentioning are:. Stone (1936) A Boolean algebra is the set of all clopen sets of a topological space. It is no limitation to require the space to be a totally disconnected compact Hausdorff space, or Stone space, that is, every Boolean algebra arises in this way, up to isomorphism. Moreover, if the two Boolean algebras formed as the clopen sets of two Stone spaces are isomorphic, so are the Stone spaces themselves, which is not the case for arbitrary topological spaces. This is just the reverse direction of the duality mentioned earlier from Boolean algebras to Stone spaces. This definition is fleshed out by the next definition. Johnstone (1982) A Boolean algebra is a filtered colimit of finite Boolean algebras. (The circularity in this definition can be removed by replacing "finite Boolean algebra" by "finite power set" equipped with the Boolean operations standardly interpreted for power sets.) To put this in perspective, infinite sets arise as filtered colimits of finite sets, infinite CABAs as filtered limits of finite power set algebras, and infinite Stone spaces as filtered limits of finite sets. Thus if one starts with the finite sets and asks how these generalize to infinite objects, there are two ways: "adding" them gives ordinary or inductive sets while "multiplying" them gives Stone spaces or profinite sets. The same choice exists for finite power set algebras as the duals of finite sets: addition yields Boolean algebras as inductive objects while multiplication yields CABAs or power set algebras as profinite objects. A characteristic distinguishing feature is that the underlying topology of objects so constructed, when defined so as to be Hausdorff, is discrete for inductive objects and compact for profinite objects. The topology of finite Hausdorff spaces is always both discrete and compact, whereas for infinite spaces "discrete"' and "compact" are mutually exclusive. Thus when generalizing finite algebras (of any kind, not just Boolean) to infinite ones, "discrete" and "compact" part company, and one must choose which one to retain. The general rule, for both finite and infinite algebras, is that finitary algebras are discrete, whereas their duals are compact and feature infinitary operations. Between these two extremes, there are many intermediate infinite Boolean algebras whose topology is neither discrete nor compact. == See also == == References == Birkhoff, Garrett (1935). "On the structure of abstract algebras". Mathematical Proceedings of the Cambridge Philosophical Society. 31 (4): 433–454. Bibcode:1935PCPS...31..433B. doi:10.1017/s0305004100013463. ISSN 0008-1981. S2CID 121173630. Boole, George (2003) [1854]. An Investigation of the Laws of Thought. Prometheus Books. ISBN 978-1-59102-089-9. Dwinger, Philip (1971). Introduction to Boolean algebras. Würzburg: Physica Verlag. Gaifman, Haim (1964). "Infinite Boolean Polynomials, I". Fundamenta Mathematicae. 54 (3): 229–250. doi:10.4064/fm-54-3-229-250. ISSN 0016-2736. Givant, Steven; Halmos, Paul (2009). Introduction to Boolean Algebras. Undergraduate Texts in Mathematics. Springer. ISBN 978-0-387-40293-2. Grau, A.A. (1947). "Ternary Boolean algebra". Bull. Am. Math. Soc. 33 (6): 567–572. doi:10.1090/S0002-9904-1947-08834-0. Hales, Alfred W. (1964). "On the Non-Existence of Free Complete Boolean Algebras". Fundamenta Mathematicae. 54: 45–66. doi:10.4064/fm-54-1-45-66. ISSN 0016-2736. Halmos, Paul (1963). Lectures on Boolean Algebras. van Nostrand. ISBN 0-387-90094-2. {{cite book}}: ISBN / Date incompatibility (help) Givant, Steven; Halmos, Paul (1998). Logic as Algebra. Dolciani Mathematical Exposition. Mathematical Association of America. ISBN 978-0-883-85327-6. Johnstone, Peter T. (1982). Stone Spaces. Cambridge, UK: Cambridge University Press. ISBN 978-0-521-33779-3. Ketonen, Jussi (1978). "The structure of countable Boolean algebras". Annals of Mathematics. 108 (1): 41–89. doi:10.2307/1970929. JSTOR 1970929. Koppelberg, Sabine (1989) "General Theory of Boolean Algebras" in Monk, J. Donald, and Bonnet, Robert, eds., Handbook of Boolean Algebras, Vol. 1. North Holland. ISBN 978-0-444-70261-6. Peirce, C. S. (1989) Writings of Charles S. Peirce: A Chronological Edition: 1879–1884. Kloesel, C. J. W., ed. Indianapolis: Indiana University Press. ISBN 978-0-253-37204-8. Lawvere, F. William (1963). "Functorial semantics of algebraic theories". Proceedings of the National Academy of Sciences. 50 (5): 869–873. Bibcode:1963PNAS...50..869L. doi:10.1073/pnas.50.5.869. PMC 221940. PMID 16591125. Schröder, Ernst (1890–1910). Vorlesungen über die Algebra der Logik (exakte Logik), I–III. Leipzig: B.G. Teubner. Sikorski, Roman (1969). Boolean Algebras (3rd. ed.). Berlin: Springer-Verlag. ISBN 978-0-387-04469-9. Stone, M. H. (1936). "The Theory of Representation for Boolean Algebras". Transactions of the American Mathematical Society. 40 (1): 37–111. doi:10.2307/1989664. ISSN 0002-9947. JSTOR 1989664. Tarski, Alfred (1983). Logic, Semantics, Metamathematics, Corcoran, J., ed. Hackett. 1956 1st edition edited and translated by J. H. Woodger, Oxford Uni. Press. Includes English translations of the following two articles: Tarski, Alfred (1929). "Sur les classes closes par rapport à certaines opérations élémentaires". Fundamenta Mathematicae. 16: 195–97. ISSN 0016-2736. Tarski, Alfred (1935). "Zur Grundlegung der Booleschen Algebra, I". Fundamenta Mathematicae. 24: 177–98. doi:10.4064/fm-24-1-177-198. ISSN 0016-2736. Vladimirov, D.A. (1969). булевы алгебры (Boolean algebras, in Russian, German translation Boolesche Algebren 1974). Nauka (German translation Akademie-Verlag). == References ==
Wikipedia/Boolean_algebras_canonically_defined
In mathematical logic, the lambda calculus (also written as λ-calculus) is a formal system for expressing computation based on function abstraction and application using variable binding and substitution. Untyped lambda calculus, the topic of this article, is a universal machine, a model of computation that can be used to simulate any Turing machine (and vice versa). It was introduced by the mathematician Alonzo Church in the 1930s as part of his research into the foundations of mathematics. In 1936, Church found a formulation which was logically consistent, and documented it in 1940. Lambda calculus consists of constructing lambda terms and performing reduction operations on them. A term is defined as any valid lambda calculus expression. In the simplest form of lambda calculus, terms are built using only the following rules: x {\textstyle x} : A variable is a character or string representing a parameter. ( λ x . M ) {\textstyle (\lambda x.M)} : A lambda abstraction is a function definition, taking as input the bound variable x {\displaystyle x} (between the λ and the punctum/dot .) and returning the body M {\textstyle M} . ( M N ) {\textstyle (M\ N)} : An application, applying a function M {\textstyle M} to an argument N {\textstyle N} . Both M {\textstyle M} and N {\textstyle N} are lambda terms. The reduction operations include: ( λ x . M [ x ] ) → ( λ y . M [ y ] ) {\textstyle (\lambda x.M[x])\rightarrow (\lambda y.M[y])} : α-conversion, renaming the bound variables in the expression. Used to avoid name collisions. ( ( λ x . M ) N ) → ( M [ x := N ] ) {\textstyle ((\lambda x.M)\ N)\rightarrow (M[x:=N])} : β-reduction, replacing the bound variables with the argument expression in the body of the abstraction. If De Bruijn indexing is used, then α-conversion is no longer required as there will be no name collisions. If repeated application of the reduction steps eventually terminates, then by the Church–Rosser theorem it will produce a β-normal form. Variable names are not needed if using a universal lambda function, such as Iota and Jot, which can create any function behavior by calling it on itself in various combinations. == Explanation and applications == Lambda calculus is Turing complete, that is, it is a universal model of computation that can be used to simulate any Turing machine. Its namesake, the Greek letter lambda (λ), is used in lambda expressions and lambda terms to denote binding a variable in a function. Lambda calculus may be untyped or typed. In typed lambda calculus, functions can be applied only if they are capable of accepting the given input's "type" of data. Typed lambda calculi are strictly weaker than the untyped lambda calculus, which is the primary subject of this article, in the sense that typed lambda calculi can express less than the untyped calculus can. On the other hand, typed lambda calculi allow more things to be proven. For example, in simply typed lambda calculus, it is a theorem that every evaluation strategy terminates for every simply typed lambda-term, whereas evaluation of untyped lambda-terms need not terminate (see below). One reason there are many different typed lambda calculi has been the desire to do more (of what the untyped calculus can do) without giving up on being able to prove strong theorems about the calculus. Lambda calculus has applications in many different areas in mathematics, philosophy, linguistics, and computer science. Lambda calculus has played an important role in the development of the theory of programming languages. Functional programming languages implement lambda calculus. Lambda calculus is also a current research topic in category theory. == History == Lambda calculus was introduced by mathematician Alonzo Church in the 1930s as part of an investigation into the foundations of mathematics. The original system was shown to be logically inconsistent in 1935 when Stephen Kleene and J. B. Rosser developed the Kleene–Rosser paradox. Subsequently, in 1936 Church isolated and published just the portion relevant to computation, what is now called the untyped lambda calculus. In 1940, he also introduced a computationally weaker, but logically consistent system, known as the simply typed lambda calculus. Until the 1960s when its relation to programming languages was clarified, the lambda calculus was only a formalism. Thanks to Richard Montague and other linguists' applications in the semantics of natural language, the lambda calculus has begun to enjoy a respectable place in both linguistics and computer science. === Origin of the λ symbol === There is some uncertainty over the reason for Church's use of the Greek letter lambda (λ) as the notation for function-abstraction in the lambda calculus, perhaps in part due to conflicting explanations by Church himself. According to Cardone and Hindley (2006): By the way, why did Church choose the notation "λ"? In [an unpublished 1964 letter to Harald Dickson] he stated clearly that it came from the notation " x ^ {\displaystyle {\hat {x}}} " used for class-abstraction by Whitehead and Russell, by first modifying " x ^ {\displaystyle {\hat {x}}} " to " ∧ x {\displaystyle \land x} " to distinguish function-abstraction from class-abstraction, and then changing " ∧ {\displaystyle \land } " to "λ" for ease of printing. This origin was also reported in [Rosser, 1984, p.338]. On the other hand, in his later years Church told two enquirers that the choice was more accidental: a symbol was needed and λ just happened to be chosen. Dana Scott has also addressed this question in various public lectures. Scott recounts that he once posed a question about the origin of the lambda symbol to Church's former student and son-in-law John W. Addison Jr., who then wrote his father-in-law a postcard: Dear Professor Church, Russell had the iota operator, Hilbert had the epsilon operator. Why did you choose lambda for your operator? According to Scott, Church's entire response consisted of returning the postcard with the following annotation: "eeny, meeny, miny, moe". == Informal description == === Motivation === Computable functions are a fundamental concept within computer science and mathematics. The lambda calculus provides simple semantics for computation which are useful for formally studying properties of computation. The lambda calculus incorporates two simplifications that make its semantics simple. The first simplification is that the lambda calculus treats functions "anonymously"; it does not give them explicit names. For example, the function s q u a r e _ s u m ⁡ ( x , y ) = x 2 + y 2 {\displaystyle \operatorname {square\_sum} (x,y)=x^{2}+y^{2}} can be rewritten in anonymous form as ( x , y ) ↦ x 2 + y 2 {\displaystyle (x,y)\mapsto x^{2}+y^{2}} (which is read as "a tuple of x and y is mapped to x 2 + y 2 {\textstyle x^{2}+y^{2}} "). Similarly, the function id ⁡ ( x ) = x {\displaystyle \operatorname {id} (x)=x} can be rewritten in anonymous form as x ↦ x {\displaystyle x\mapsto x} where the input is simply mapped to itself. The second simplification is that the lambda calculus only uses functions of a single input. An ordinary function that requires two inputs, for instance the s q u a r e _ s u m {\textstyle \operatorname {square\_sum} } function, can be reworked into an equivalent function that accepts a single input, and as output returns another function, that in turn accepts a single input. For example, ( x , y ) ↦ x 2 + y 2 {\displaystyle (x,y)\mapsto x^{2}+y^{2}} can be reworked into x ↦ ( y ↦ x 2 + y 2 ) {\displaystyle x\mapsto (y\mapsto x^{2}+y^{2})} This method, known as currying, transforms a function that takes multiple arguments into a chain of functions each with a single argument. Function application of the s q u a r e _ s u m {\textstyle \operatorname {square\_sum} } function to the arguments (5, 2), yields at once ( ( x , y ) ↦ x 2 + y 2 ) ( 5 , 2 ) {\textstyle ((x,y)\mapsto x^{2}+y^{2})(5,2)} = 5 2 + 2 2 {\textstyle =5^{2}+2^{2}} = 29 {\textstyle =29} , whereas evaluation of the curried version requires one more step ( ( x ↦ ( y ↦ x 2 + y 2 ) ) ( 5 ) ) ( 2 ) {\textstyle {\Bigl (}{\bigl (}x\mapsto (y\mapsto x^{2}+y^{2}){\bigr )}(5){\Bigr )}(2)} = ( y ↦ 5 2 + y 2 ) ( 2 ) {\textstyle =(y\mapsto 5^{2}+y^{2})(2)} // the definition of x {\displaystyle x} has been used with 5 {\displaystyle 5} in the inner expression. This is like β-reduction. = 5 2 + 2 2 {\textstyle =5^{2}+2^{2}} // the definition of y {\displaystyle y} has been used with 2 {\displaystyle 2} . Again, similar to β-reduction. = 29 {\textstyle =29} to arrive at the same result. === The lambda calculus === The lambda calculus consists of a language of lambda terms, that are defined by a certain formal syntax, and a set of transformation rules for manipulating the lambda terms. These transformation rules can be viewed as an equational theory or as an operational definition. As described above, having no names, all functions in the lambda calculus are anonymous functions. They only accept one input variable, so currying is used to implement functions of several variables. ==== Lambda terms ==== The syntax of the lambda calculus defines some expressions as valid lambda calculus expressions and some as invalid, just as some strings of characters are valid computer programs and some are not. A valid lambda calculus expression is called a "lambda term". The following three rules give an inductive definition that can be applied to build all syntactically valid lambda terms: variable x is itself a valid lambda term. if t is a lambda term, and x is a variable, then ( λ x . t ) {\displaystyle (\lambda x.t)} is a lambda term (called an abstraction); if t and s are lambda terms, then ( t s ) {\displaystyle (ts)} is a lambda term (called an application). Nothing else is a lambda term. That is, a lambda term is valid if and only if it can be obtained by repeated application of these three rules. For convenience, some parentheses can be omitted when writing a lambda term. For example, the outermost parentheses are usually not written. See § Notation, below, for an explicit description of which parentheses are optional. It is also common to extend the syntax presented here with additional operations, which allows making sense of terms such as λ x . x 2 . {\displaystyle \lambda x.x^{2}.} The focus of this article is the pure lambda calculus without extensions, but lambda terms extended with arithmetic operations are used for explanatory purposes. An abstraction λ x . t {\displaystyle \lambda x.t} denotes an § anonymous function that takes a single input x and returns t. For example, λ x . ( x 2 + 2 ) {\displaystyle \lambda x.(x^{2}+2)} is an abstraction representing the function f {\displaystyle f} defined by f ( x ) = x 2 + 2 , {\displaystyle f(x)=x^{2}+2,} using the term x 2 + 2 {\displaystyle x^{2}+2} for t. The name f {\displaystyle f} is superfluous when using abstraction. The syntax ( λ x . t ) {\displaystyle (\lambda x.t)} binds the variable x in the term t. The definition of a function with an abstraction merely "sets up" the function but does not invoke it. An application t s {\displaystyle ts} represents the application of a function t to an input s, that is, it represents the act of calling function t on input s to produce t ( s ) {\displaystyle t(s)} . A lambda term may refer to a variable that has not been bound, such as the term λ x . ( x + y ) {\displaystyle \lambda x.(x+y)} (which represents the function definition f ( x ) = x + y {\displaystyle f(x)=x+y} ). In this term, the variable y has not been defined and is considered an unknown. The abstraction λ x . ( x + y ) {\displaystyle \lambda x.(x+y)} is a syntactically valid term and represents a function that adds its input to the yet-unknown y. Parentheses may be used and might be needed to disambiguate terms. For example, λ x . ( ( λ x . x ) x ) {\displaystyle \lambda x.((\lambda x.x)x)} is of form λ x . B {\displaystyle \lambda x.B} and is therefore an abstraction, while ( λ x . ( λ x . x ) ) x {\displaystyle (\lambda x.(\lambda x.x))x} is of form M N {\displaystyle MN} and is therefore an application. The examples 1 and 2 denote different terms, differing only in where the parentheses are placed. They have different meanings: example 1 is a function definition, while example 2 is a function application. The lambda variable x is a placeholder in both examples. Here, example 1 defines a function λ x . B {\displaystyle \lambda x.B} , where B {\displaystyle B} is ( λ x . x ) x {\displaystyle (\lambda x.x)x} , an anonymous function ( λ x . x ) {\displaystyle (\lambda x.x)} , with input x {\displaystyle x} ; while example 2, M {\displaystyle M} N {\displaystyle N} , is M applied to N, where M {\displaystyle M} is the lambda term ( λ x . ( λ x . x ) ) {\displaystyle (\lambda x.(\lambda x.x))} being applied to the input N {\displaystyle N} which is x {\displaystyle x} . Both examples 1 and 2 would evaluate to the identity function λ x . x {\displaystyle \lambda x.x} . ==== Functions that operate on functions ==== In lambda calculus, functions are taken to be 'first class values', so functions may be used as the inputs, or be returned as outputs from other functions. For example, the lambda term λ x . x {\displaystyle \lambda x.x} represents the identity function, x ↦ x {\displaystyle x\mapsto x} . Further, λ x . y {\displaystyle \lambda x.y} represents the constant function x ↦ y {\displaystyle x\mapsto y} , the function that always returns y {\displaystyle y} , no matter the input. As an example of a function operating on functions, the function composition can be defined as λ f . λ g . λ x . ( f ( g x ) ) {\displaystyle \lambda f.\lambda g.\lambda x.(f(gx))} . There are several notions of "equivalence" and "reduction" that allow lambda terms to be "reduced" to "equivalent" lambda terms. ==== Alpha equivalence ==== A basic form of equivalence, definable on lambda terms, is alpha equivalence. It captures the intuition that the particular choice of a bound variable, in an abstraction, does not (usually) matter. For instance, λ x . x {\displaystyle \lambda x.x} and λ y . y {\displaystyle \lambda y.y} are alpha-equivalent lambda terms, and they both represent the same function (the identity function). The terms x {\displaystyle x} and y {\displaystyle y} are not alpha-equivalent, because they are not bound in an abstraction. In many presentations, it is usual to identify alpha-equivalent lambda terms. The following definitions are necessary in order to be able to define β-reduction: ==== Free variables ==== The free variables of a term are those variables not bound by an abstraction. The set of free variables of an expression is defined inductively: The free variables of x {\displaystyle x} are just x {\displaystyle x} The set of free variables of λ x . t {\displaystyle \lambda x.t} is the set of free variables of t {\displaystyle t} , but with x {\displaystyle x} removed The set of free variables of t s {\displaystyle ts} is the union of the set of free variables of t {\displaystyle t} and the set of free variables of s {\displaystyle s} . For example, the lambda term representing the identity λ x . x {\displaystyle \lambda x.x} has no free variables, but the function λ x . y x {\displaystyle \lambda x.yx} has a single free variable, y {\displaystyle y} . ==== Capture-avoiding substitutions ==== Suppose t {\displaystyle t} , s {\displaystyle s} and r {\displaystyle r} are lambda terms, and x {\displaystyle x} and y {\displaystyle y} are variables. The notation t [ x := r ] {\displaystyle t[x:=r]} indicates substitution of r {\displaystyle r} for x {\displaystyle x} in t {\displaystyle t} in a capture-avoiding manner. This is defined so that: x [ x := r ] = r {\displaystyle x[x:=r]=r} ; with r {\displaystyle r} substituted for x {\displaystyle x} , x {\displaystyle x} becomes r {\displaystyle r} y [ x := r ] = y {\displaystyle y[x:=r]=y} if x ≠ y {\displaystyle x\neq y} ; with r {\displaystyle r} substituted for x {\displaystyle x} , y {\displaystyle y} (which is not x {\displaystyle x} ) remains y {\displaystyle y} ( t s ) [ x := r ] = ( t [ x := r ] ) ( s [ x := r ] ) {\displaystyle (ts)[x:=r]=(t[x:=r])(s[x:=r])} ; substitution distributes to both sides of an application ( λ x . t ) [ x := r ] = λ x . t {\displaystyle (\lambda x.t)[x:=r]=\lambda x.t} ; a variable bound by an abstraction is not subject to substitution; substituting such variable leaves the abstraction unchanged ( λ y . t ) [ x := r ] = λ y . ( t [ x := r ] ) {\displaystyle (\lambda y.t)[x:=r]=\lambda y.(t[x:=r])} if x ≠ y {\displaystyle x\neq y} and y {\displaystyle y} does not appear among the free variables of r {\displaystyle r} ( y {\displaystyle y} is said to be "fresh" for r {\displaystyle r} ) ; substituting a variable which is not bound by an abstraction proceeds in the abstraction's body, provided that the abstracted variable y {\displaystyle y} is "fresh" for the substitution term r {\displaystyle r} . For example, ( λ x . x ) [ y := y ] = λ x . ( x [ y := y ] ) = λ x . x {\displaystyle (\lambda x.x)[y:=y]=\lambda x.(x[y:=y])=\lambda x.x} , and ( ( λ x . y ) x ) [ x := y ] = ( ( λ x . y ) [ x := y ] ) ( x [ x := y ] ) = ( λ x . y ) y {\displaystyle ((\lambda x.y)x)[x:=y]=((\lambda x.y)[x:=y])(x[x:=y])=(\lambda x.y)y} . The freshness condition (requiring that y {\displaystyle y} is not in the free variables of r {\displaystyle r} ) is crucial in order to ensure that substitution does not change the meaning of functions. For example, a substitution that ignores the freshness condition could lead to errors: ( λ x . y ) [ y := x ] = λ x . ( y [ y := x ] ) = λ x . x {\displaystyle (\lambda x.y)[y:=x]=\lambda x.(y[y:=x])=\lambda x.x} . This erroneous substitution would turn the constant function λ x . y {\displaystyle \lambda x.y} into the identity λ x . x {\displaystyle \lambda x.x} . In general, failure to meet the freshness condition can be remedied by alpha-renaming first, with a suitable fresh variable. For example, switching back to our correct notion of substitution, in ( λ x . y ) [ y := x ] {\displaystyle (\lambda x.y)[y:=x]} the abstraction can be renamed with a fresh variable z {\displaystyle z} , to obtain ( λ z . y ) [ y := x ] = λ z . ( y [ y := x ] ) = λ z . x {\displaystyle (\lambda z.y)[y:=x]=\lambda z.(y[y:=x])=\lambda z.x} , and the meaning of the function is preserved by substitution. ==== β-reduction ==== The β-reduction rule states that an application of the form ( λ x . t ) s {\displaystyle (\lambda x.t)s} reduces to the term t [ x := s ] {\displaystyle t[x:=s]} . The notation ( λ x . t ) s → t [ x := s ] {\displaystyle (\lambda x.t)s\to t[x:=s]} is used to indicate that ( λ x . t ) s {\displaystyle (\lambda x.t)s} β-reduces to t [ x := s ] {\displaystyle t[x:=s]} . For example, for every s {\displaystyle s} , ( λ x . x ) s → x [ x := s ] = s {\displaystyle (\lambda x.x)s\to x[x:=s]=s} . This demonstrates that λ x . x {\displaystyle \lambda x.x} really is the identity. Similarly, ( λ x . y ) s → y [ x := s ] = y {\displaystyle (\lambda x.y)s\to y[x:=s]=y} , which demonstrates that λ x . y {\displaystyle \lambda x.y} is a constant function. The lambda calculus may be seen as an idealized version of a functional programming language, like Haskell or Standard ML. Under this view, β-reduction corresponds to a computational step. This step can be repeated by additional β-reductions until there are no more applications left to reduce. In the untyped lambda calculus, as presented here, this reduction process may not terminate. For instance, consider the term Ω = ( λ x . x x ) ( λ x . x x ) {\displaystyle \Omega =(\lambda x.xx)(\lambda x.xx)} . Here ( λ x . x x ) ( λ x . x x ) → ( x x ) [ x := λ x . x x ] = ( x [ x := λ x . x x ] ) ( x [ x := λ x . x x ] ) = ( λ x . x x ) ( λ x . x x ) {\displaystyle (\lambda x.xx)(\lambda x.xx)\to (xx)[x:=\lambda x.xx]=(x[x:=\lambda x.xx])(x[x:=\lambda x.xx])=(\lambda x.xx)(\lambda x.xx)} . That is, the term reduces to itself in a single β-reduction, and therefore the reduction process will never terminate. Another aspect of the untyped lambda calculus is that it does not distinguish between different kinds of data. For instance, it may be desirable to write a function that only operates on numbers. However, in the untyped lambda calculus, there is no way to prevent a function from being applied to truth values, strings, or other non-number objects. == Formal definition == === Definition === Lambda expressions are composed of: variables v1, v2, ...; the abstraction symbols λ (lambda) and . (dot); parentheses (). The set of lambda expressions, Λ, can be defined inductively: If x is a variable, then x ∈ Λ. If x is a variable and M ∈ Λ, then (λx.M) ∈ Λ. If M, N ∈ Λ, then (M N) ∈ Λ. Instances of rule 2 are known as abstractions and instances of rule 3 are known as applications. See § reducible expression This set of rules may be written in Backus–Naur form as: === Notation === To keep the notation of lambda expressions uncluttered, the following conventions are usually applied: Outermost parentheses are dropped: M N instead of (M N). Applications are assumed to be left associative: M N P may be written instead of ((M N) P). When all variables are single-letter, the space in applications may be omitted: MNP instead of M N P. The body of an abstraction extends as far right as possible: λx.M N means λx.(M N) and not (λx.M) N. A sequence of abstractions is contracted: λx.λy.λz.N is abbreviated as λxyz.N. === Free and bound variables === The abstraction operator, λ, is said to bind its variable wherever it occurs in the body of the abstraction. Variables that fall within the scope of an abstraction are said to be bound. In an expression λx.M, the part λx is often called binder, as a hint that the variable x is getting bound by prepending λx to M. All other variables are called free. For example, in the expression λy.x x y, y is a bound variable and x is a free variable. Also a variable is bound by its nearest abstraction. In the following example the single occurrence of x in the expression is bound by the second lambda: λx.y (λx.z x). The set of free variables of a lambda expression, M, is denoted as FV(M) and is defined by recursion on the structure of the terms, as follows: FV(x) = {x}, where x is a variable. FV(λx.M) = FV(M) \ {x}. FV(M N) = FV(M) ∪ FV(N). An expression that contains no free variables is said to be closed. Closed lambda expressions are also known as combinators and are equivalent to terms in combinatory logic. == Reduction == The meaning of lambda expressions is defined by how expressions can be reduced. There are three kinds of reduction: α-conversion: changing bound variables; β-reduction: applying functions to their arguments; η-conversion: expressing extensionality. We also speak of the resulting equivalences: two expressions are α-equivalent, if they can be α-converted into the same expression. β-equivalence and η-equivalence are defined similarly. The term redex, short for reducible expression, refers to subterms that can be reduced by one of the reduction rules. For example, (λx.M) N is a β-redex in expressing the substitution of N for x in M. The expression to which a redex reduces is called its reduct; the reduct of (λx.M) N is M[x := N]. If x is not free in M, λx.M x is also an η-redex, with a reduct of M. === α-conversion === α-conversion (alpha-conversion), sometimes known as α-renaming, allows bound variable names to be changed. For example, α-conversion of λx.x might yield λy.y. Terms that differ only by α-conversion are called α-equivalent. Frequently, in uses of lambda calculus, α-equivalent terms are considered to be equivalent. The precise rules for α-conversion are not completely trivial. First, when α-converting an abstraction, the only variable occurrences that are renamed are those that are bound to the same abstraction. For example, an α-conversion of λx.λx.x could result in λy.λx.x, but it could not result in λy.λx.y. The latter has a different meaning from the original. This is analogous to the programming notion of variable shadowing. Second, α-conversion is not possible if it would result in a variable getting captured by a different abstraction. For example, if we replace x with y in λx.λy.x, we get λy.λy.y, which is not at all the same. In programming languages with static scope, α-conversion can be used to make name resolution simpler by ensuring that no variable name masks a name in a containing scope (see α-renaming to make name resolution trivial). In the De Bruijn index notation, any two α-equivalent terms are syntactically identical. ==== Substitution ==== Substitution, written M[x := N], is the process of replacing all free occurrences of the variable x in the expression M with expression N. Substitution on terms of the lambda calculus is defined by recursion on the structure of terms, as follows (note: x and y are only variables while M and N are any lambda expression): x[x := N] = N y[x := N] = y, if x ≠ y (M1 M2)[x := N] = M1[x := N] M2[x := N] (λx.M)[x := N] = λx.M (λy.M)[x := N] = λy.(M[x := N]), if x ≠ y and y ∉ FV(N) See above for the FV To substitute into an abstraction, it is sometimes necessary to α-convert the expression. For example, it is not correct for (λx.y)[y := x] to result in λx.x, because the substituted x was supposed to be free but ended up being bound. The correct substitution in this case is λz.x, up to α-equivalence. Substitution is defined uniquely up to α-equivalence. See Capture-avoiding substitutions above. === β-reduction === β-reduction (beta reduction) captures the idea of function application. β-reduction is defined in terms of substitution: the β-reduction of (λx.M) N is M[x := N]. For example, assuming some encoding of 2, 7, ×, we have the following β-reduction: (λn.n × 2) 7 → 7 × 2. β-reduction can be seen to be the same as the concept of local reducibility in natural deduction, via the Curry–Howard isomorphism. === η-conversion === η-conversion (eta conversion) expresses the idea of extensionality, which in this context is that two functions are the same if and only if they give the same result for all arguments. η-conversion converts between λx.f x and f whenever x does not appear free in f. η-reduction changes λx.f x to f, and η-expansion changes f to λx.f x, under the same requirement that x does not appear free in f. η-conversion can be seen to be the same as the concept of local completeness in natural deduction, via the Curry–Howard isomorphism. == Normal forms and confluence == For the untyped lambda calculus, β-reduction as a rewriting rule is neither strongly normalising nor weakly normalising. However, it can be shown that β-reduction is confluent when working up to α-conversion (i.e. we consider two normal forms to be equal if it is possible to α-convert one into the other). Therefore, both strongly normalising terms and weakly normalising terms have a unique normal form. For strongly normalising terms, any reduction strategy is guaranteed to yield the normal form, whereas for weakly normalising terms, some reduction strategies may fail to find it. == Encoding datatypes == The basic lambda calculus may be used to model arithmetic, Booleans, data structures, and recursion, as illustrated in the following sub-sections i, ii, iii, and § iv. === Arithmetic in lambda calculus === There are several possible ways to define the natural numbers in lambda calculus, but by far the most common are the Church numerals, which can be defined as follows: 0 := λf.λx.x 1 := λf.λx.f x 2 := λf.λx.f (f x) 3 := λf.λx.f (f (f x)) and so on. Or using the alternative syntax presented above in Notation: 0 := λfx.x 1 := λfx.f x 2 := λfx.f (f x) 3 := λfx.f (f (f x)) A Church numeral is a higher-order function—it takes a single-argument function f, and returns another single-argument function. The Church numeral n is a function that takes a function f as argument and returns the n-th composition of f, i.e. the function f composed with itself n times. This is denoted f(n) and is in fact the n-th power of f (considered as an operator); f(0) is defined to be the identity function. Such repeated compositions (of a single function f) obey the laws of exponents, which is why these numerals can be used for arithmetic. (In Church's original lambda calculus, the formal parameter of a lambda expression was required to occur at least once in the function body, which made the above definition of 0 impossible.) One way of thinking about the Church numeral n, which is often useful when analysing programs, is as an instruction 'repeat n times'. For example, using the PAIR and NIL functions defined below, one can define a function that constructs a (linked) list of n elements all equal to x by repeating 'prepend another x element' n times, starting from an empty list. The lambda term is λn.λx.n (PAIR x) NIL By varying what is being repeated, and varying what argument that function being repeated is applied to, a great many different effects can be achieved. We can define a successor function, which takes a Church numeral n and returns n + 1 by adding another application of f, where '(mf)x' means the function 'f' is applied 'm' times on 'x': SUCC := λn.λf.λx.f (n f x) Because the m-th composition of f composed with the n-th composition of f gives the m+n-th composition of f, addition can be defined as follows: PLUS := λm.λn.λf.λx.m f (n f x) PLUS can be thought of as a function taking two natural numbers as arguments and returning a natural number; it can be verified that PLUS 2 3 and 5 are β-equivalent lambda expressions. Since adding m to a number n can be accomplished by adding 1 m times, an alternative definition is: PLUS := λm.λn.m SUCC n Similarly, multiplication can be defined as MULT := λm.λn.λf.m (n f) Alternatively MULT := λm.λn.m (PLUS n) 0 since multiplying m and n is the same as repeating the add n function m times and then applying it to zero. Exponentiation has a rather simple rendering in Church numerals, namely POW := λb.λe.e b The predecessor function defined by PRED n = n − 1 for a positive integer n and PRED 0 = 0 is considerably more difficult. The formula PRED := λn.λf.λx.n (λg.λh.h (g f)) (λu.x) (λu.u) can be validated by showing inductively that if T denotes (λg.λh.h (g f)), then T(n)(λu.x) = (λh.h(f(n−1)(x))) for n > 0. Two other definitions of PRED are given below, one using conditionals and the other using pairs. With the predecessor function, subtraction is straightforward. Defining SUB := λm.λn.n PRED m, SUB m n yields m − n when m > n and 0 otherwise. === Logic and predicates === By convention, the following two definitions (known as Church Booleans) are used for the Boolean values TRUE and FALSE: TRUE := λx.λy.x FALSE := λx.λy.y Then, with these two lambda terms, we can define some logic operators (these are just possible formulations; other expressions could be equally correct): AND := λp.λq.p q p OR := λp.λq.p p q NOT := λp.p FALSE TRUE IFTHENELSE := λp.λa.λb.p a b We are now able to compute some logic functions, for example: AND TRUE FALSE ≡ (λp.λq.p q p) TRUE FALSE →β TRUE FALSE TRUE ≡ (λx.λy.x) FALSE TRUE →β FALSE and we see that AND TRUE FALSE is equivalent to FALSE. A predicate is a function that returns a Boolean value. The most fundamental predicate is ISZERO, which returns TRUE if its argument is the Church numeral 0, but FALSE if its argument were any other Church numeral: ISZERO := λn.n (λx.FALSE) TRUE The following predicate tests whether the first argument is less-than-or-equal-to the second: LEQ := λm.λn.ISZERO (SUB m n), and since m = n, if LEQ m n and LEQ n m, it is straightforward to build a predicate for numerical equality. The availability of predicates and the above definition of TRUE and FALSE make it convenient to write "if-then-else" expressions in lambda calculus. For example, the predecessor function can be defined as: PRED := λn.n (λg.λk.ISZERO (g 1) k (PLUS (g k) 1)) (λv.0) 0 which can be verified by showing inductively that n (λg.λk.ISZERO (g 1) k (PLUS (g k) 1)) (λv.0) is the add n − 1 function for n > 0. === Pairs === A pair (2-tuple) can be defined in terms of TRUE and FALSE, by using the Church encoding for pairs. For example, PAIR encapsulates the pair (x,y), FIRST returns the first element of the pair, and SECOND returns the second. PAIR := λx.λy.λf.f x y FIRST := λp.p TRUE SECOND := λp.p FALSE NIL := λx.TRUE NULL := λp.p (λx.λy.FALSE) A linked list can be defined as either NIL for the empty list, or the PAIR of an element and a smaller list. The predicate NULL tests for the value NIL. (Alternatively, with NIL := FALSE, the construct l (λh.λt.λz.deal_with_head_h_and_tail_t) (deal_with_nil) obviates the need for an explicit NULL test). As an example of the use of pairs, the shift-and-increment function that maps (m, n) to (n, n + 1) can be defined as Φ := λx.PAIR (SECOND x) (SUCC (SECOND x)) which allows us to give perhaps the most transparent version of the predecessor function: PRED := λn.FIRST (n Φ (PAIR 0 0)). == Additional programming techniques == There is a considerable body of programming idioms for lambda calculus. Many of these were originally developed in the context of using lambda calculus as a foundation for programming language semantics, effectively using lambda calculus as a low-level programming language. Because several programming languages include the lambda calculus (or something very similar) as a fragment, these techniques also see use in practical programming, but may then be perceived as obscure or foreign. === Named constants === In lambda calculus, a library would take the form of a collection of previously defined functions, which as lambda-terms are merely particular constants. The pure lambda calculus does not have a concept of named constants since all atomic lambda-terms are variables, but one can emulate having named constants by setting aside a variable as the name of the constant, using abstraction to bind that variable in the main body, and apply that abstraction to the intended definition. Thus to use f to mean N (some explicit lambda-term) in M (another lambda-term, the "main program"), one can say (λf.M) N Authors often introduce syntactic sugar, such as let, to permit writing the above in the more intuitive order let f = N in M By chaining such definitions, one can write a lambda calculus "program" as zero or more function definitions, followed by one lambda-term using those functions that constitutes the main body of the program. A notable restriction of this let is that the name f may not be referenced in N, for N is outside the scope of the abstraction binding f, which is M; this means a recursive function definition cannot be written with let. The letrec construction would allow writing recursive function definitions, where the scope of the abstraction binding f includes N as well as M. Or self-application a-la that which leads to Y combinator could be used. === Recursion and fixed points === Recursion is when a function invokes itself. What would a value be which were to represent such a function? It has to refer to itself somehow inside itself, just as the definition refers to itself inside itself. If this value were to contain itself by value, it would have to be of infinite size, which is impossible. Other notations, which support recursion natively, overcome this by referring to the function by name inside its definition. Lambda calculus cannot express this, since in it there simply are no names for terms to begin with, only arguments' names, i.e. parameters in abstractions. Thus, a lambda expression can receive itself as its argument and refer to (a copy of) itself via the corresponding parameter's name. This will work fine in case it was indeed called with itself as an argument. For example, (λx.x x) E = (E E) will express recursion when E is an abstraction which is applying its parameter to itself inside its body to express a recursive call. Since this parameter receives E as its value, its self-application will be the same (E E) again. As a concrete example, consider the factorial function F(n), recursively defined by F(n) = 1, if n = 0; else n × F(n − 1). In the lambda expression which is to represent this function, a parameter (typically the first one) will be assumed to receive the lambda expression itself as its value, so that calling it with itself as its first argument will amount to the recursive call. Thus to achieve recursion, the intended-as-self-referencing argument (called s here, reminiscent of "self", or "self-applying") must always be passed to itself within the function body at a recursive call point: E := λs. λn.(1, if n = 0; else n × (s s (n−1))) with s s n = F n = E E n to hold, so s = E and F := (λx.x x) E = E E and we have F = E E = λn.(1, if n = 0; else n × (E E (n−1))) Here s s becomes the same (E E) inside the result of the application (E E), and using the same function for a call is the definition of what recursion is. The self-application achieves replication here, passing the function's lambda expression on to the next invocation as an argument value, making it available to be referenced there by the parameter name s to be called via the self-application s s, again and again as needed, each time re-creating the lambda-term F = E E. The application is an additional step just as the name lookup would be. It has the same delaying effect. Instead of having F inside itself as a whole up-front, delaying its re-creation until the next call makes its existence possible by having two finite lambda-terms E inside it re-create it on the fly later as needed. This self-applicational approach solves it, but requires re-writing each recursive call as a self-application. We would like to have a generic solution, without the need for any re-writes: G := λr. λn.(1, if n = 0; else n × (r (n−1))) with r x = F x = G r x to hold, so r = G r =: FIX G and F := FIX G where FIX g = (r where r = g r) = g (FIX g) so that FIX G = G (FIX G) = (λn.(1, if n = 0; else n × ((FIX G) (n−1)))) Given a lambda term with first argument representing recursive call (e.g. G here), the fixed-point combinator FIX will return a self-replicating lambda expression representing the recursive function (here, F). The function does not need to be explicitly passed to itself at any point, for the self-replication is arranged in advance, when it is created, to be done each time it is called. Thus the original lambda expression (FIX G) is re-created inside itself, at call-point, achieving self-reference. In fact, there are many possible definitions for this FIX operator, the simplest of them being: Y := λg.(λx.g (x x)) (λx.g (x x)) In the lambda calculus, Y g is a fixed-point of g, as it expands to: Y g ~> (λh.(λx.h (x x)) (λx.h (x x))) g ~> (λx.g (x x)) (λx.g (x x)) ~> g ((λx.g (x x)) (λx.g (x x))) <~ g (Y g) Now, to perform the recursive call to the factorial function for an argument n, we would simply call (Y G) n. Given n = 4, for example, this gives: Every recursively defined function can be seen as a fixed point of some suitably defined higher order function (also known as functional) closing over the recursive call with an extra argument. Therefore, using Y, every recursive function can be expressed as a lambda expression. In particular, we can now cleanly define the subtraction, multiplication, and comparison predicates of natural numbers, using recursion. When Y combinator is coded directly in a strict programming language, the applicative order of evaluation used in such languages will cause an attempt to fully expand the internal self-application ( x x ) {\displaystyle (xx)} prematurely, causing stack overflow or, in case of tail call optimization, indefinite looping. A delayed variant of Y, the Z combinator, can be used in such languages. It has the internal self-application hidden behind an extra abstraction through eta-expansion, as ( λ v . x x v ) {\displaystyle (\lambda v.xxv)} , thus preventing its premature expansion: Z = λ f . ( λ x . f ( λ v . x x v ) ) ( λ x . f ( λ v . x x v ) ) . {\displaystyle Z=\lambda f.(\lambda x.f(\lambda v.xxv))\ (\lambda x.f(\lambda v.xxv))\ .} === Standard terms === Certain terms have commonly accepted names: I := λx.x S := λx.λy.λz.x z (y z) K := λx.λy.x B := λx.λy.λz.x (y z) C := λx.λy.λz.x z y W := λx.λy.x y y ω or Δ or U := λx.x x Ω := ω ω I is the identity function. SK and BCKW form complete combinator calculus systems that can express any lambda term - see the next section. Ω is UU, the smallest term that has no normal form. YI is another such term. Y is standard and defined above, and can also be defined as Y=BU(CBU), so that Yg=g(Yg). TRUE and FALSE defined above are commonly abbreviated as T and F. === Abstraction elimination === If N is a lambda-term without abstraction, but possibly containing named constants (combinators), then there exists a lambda-term T(x,N) which is equivalent to λx.N but lacks abstraction (except as part of the named constants, if these are considered non-atomic). This can also be viewed as anonymising variables, as T(x,N) removes all occurrences of x from N, while still allowing argument values to be substituted into the positions where N contains an x. The conversion function T can be defined by: T(x, x) := I T(x, N) := K N if x is not free in N. T(x, M N) := S T(x, M) T(x, N) In either case, a term of the form T(x,N) P can reduce by having the initial combinator I, K, or S grab the argument P, just like β-reduction of (λx.N) P would do. I returns that argument. K throws the argument away, just like (λx.N) would do if x has no free occurrence in N. S passes the argument on to both subterms of the application, and then applies the result of the first to the result of the second. The combinators B and C are similar to S, but pass the argument on to only one subterm of an application (B to the "argument" subterm and C to the "function" subterm), thus saving a subsequent K if there is no occurrence of x in one subterm. In comparison to B and C, the S combinator actually conflates two functionalities: rearranging arguments, and duplicating an argument so that it may be used in two places. The W combinator does only the latter, yielding the B, C, K, W system as an alternative to SKI combinator calculus. == Typed lambda calculus == A typed lambda calculus is a typed formalism that uses the lambda-symbol ( λ {\displaystyle \lambda } ) to denote anonymous function abstraction. In this context, types are usually objects of a syntactic nature that are assigned to lambda terms; the exact nature of a type depends on the calculus considered (see Kinds of typed lambda calculi). From a certain point of view, typed lambda calculi can be seen as refinements of the untyped lambda calculus but from another point of view, they can also be considered the more fundamental theory and untyped lambda calculus a special case with only one type. Typed lambda calculi are foundational programming languages and are the base of typed functional programming languages such as ML and Haskell and, more indirectly, typed imperative programming languages. Typed lambda calculi play an important role in the design of type systems for programming languages; here typability usually captures desirable properties of the program, e.g., the program will not cause a memory access violation. Typed lambda calculi are closely related to mathematical logic and proof theory via the Curry–Howard isomorphism and they can be considered as the internal language of classes of categories, e.g., the simply typed lambda calculus is the language of a Cartesian closed category (CCC). == Reduction strategies == Whether a term is normalising or not, and how much work needs to be done in normalising it if it is, depends to a large extent on the reduction strategy used. Common lambda calculus reduction strategies include: Normal order The leftmost outermost redex is reduced first. That is, whenever possible, arguments are substituted into the body of an abstraction before the arguments are reduced. If a term has a beta-normal form, normal order reduction will always reach that normal form. Applicative order The leftmost innermost redex is reduced first. As a consequence, a function's arguments are always reduced before they are substituted into the function. Unlike normal order reduction, applicative order reduction may fail to find the beta-normal form of an expression, even if such a normal form exists. For example, the term ( λ x . y ( λ z . ( z z ) λ z . ( z z ) ) ) {\displaystyle (\;\lambda x.y\;\;(\lambda z.(zz)\;\lambda z.(zz))\;)} is reduced to itself by applicative order, while normal order reduces it to its beta-normal form y {\displaystyle y} . Full β-reductions Any redex can be reduced at any time. This means essentially the lack of any particular reduction strategy—with regard to reducibility, "all bets are off". Weak reduction strategies do not reduce under lambda abstractions: Call by value Like applicative order, but no reductions are performed inside abstractions. This is similar to the evaluation order of strict languages like C: the arguments to a function are evaluated before calling the function, and function bodies are not even partially evaluated until the arguments are substituted in. Call by name Like normal order, but no reductions are performed inside abstractions. For example, λx.(λy.y)x is in normal form according to this strategy, although it contains the redex (λy.y)x. Strategies with sharing reduce computations that are "the same" in parallel: Optimal reduction As normal order, but computations that have the same label are reduced simultaneously. Call by need As call by name (hence weak), but function applications that would duplicate terms instead name the argument. The argument may be evaluated "when needed", at which point the name binding is updated with the reduced value. This can save time compared to normal order evaluation. == Computability == There is no algorithm that takes as input any two lambda expressions and outputs TRUE or FALSE depending on whether one expression reduces to the other. More precisely, no computable function can decide the question. This was historically the first problem for which undecidability could be proven. As usual for such a proof, computable means computable by any model of computation that is Turing complete. In fact computability can itself be defined via the lambda calculus: a function F: N → N of natural numbers is a computable function if and only if there exists a lambda expression f such that for every pair of x, y in N, F(x)=y if and only if f x =β y, where x and y are the Church numerals corresponding to x and y, respectively and =β meaning equivalence with β-reduction. See the Church–Turing thesis for other approaches to defining computability and their equivalence. Church's proof of uncomputability first reduces the problem to determining whether a given lambda expression has a normal form. Then he assumes that this predicate is computable, and can hence be expressed in lambda calculus. Building on earlier work by Kleene and constructing a Gödel numbering for lambda expressions, he constructs a lambda expression e that closely follows the proof of Gödel's first incompleteness theorem. If e is applied to its own Gödel number, a contradiction results. == Complexity == The notion of computational complexity for the lambda calculus is a bit tricky, because the cost of a β-reduction may vary depending on how it is implemented. To be precise, one must somehow find the location of all of the occurrences of the bound variable V in the expression E, implying a time cost, or one must keep track of the locations of free variables in some way, implying a space cost. A naïve search for the locations of V in E is O(n) in the length n of E. Director strings were an early approach that traded this time cost for a quadratic space usage. More generally this has led to the study of systems that use explicit substitution. In 2014, it was shown that the number of β-reduction steps taken by normal order reduction to reduce a term is a reasonable time cost model, that is, the reduction can be simulated on a Turing machine in time polynomially proportional to the number of steps. This was a long-standing open problem, due to size explosion, the existence of lambda terms which grow exponentially in size for each β-reduction. The result gets around this by working with a compact shared representation. The result makes clear that the amount of space needed to evaluate a lambda term is not proportional to the size of the term during reduction. It is not currently known what a good measure of space complexity would be. An unreasonable model does not necessarily mean inefficient. Optimal reduction reduces all computations with the same label in one step, avoiding duplicated work, but the number of parallel β-reduction steps to reduce a given term to normal form is approximately linear in the size of the term. This is far too small to be a reasonable cost measure, as any Turing machine may be encoded in the lambda calculus in size linearly proportional to the size of the Turing machine. The true cost of reducing lambda terms is not due to β-reduction per se but rather the handling of the duplication of redexes during β-reduction. It is not known if optimal reduction implementations are reasonable when measured with respect to a reasonable cost model such as the number of leftmost-outermost steps to normal form, but it has been shown for fragments of the lambda calculus that the optimal reduction algorithm is efficient and has at most a quadratic overhead compared to leftmost-outermost. In addition the BOHM prototype implementation of optimal reduction outperformed both Caml Light and Haskell on pure lambda terms. == Lambda calculus and programming languages == As pointed out by Peter Landin's 1965 paper "A Correspondence between ALGOL 60 and Church's Lambda-notation", sequential procedural programming languages can be understood in terms of the lambda calculus, which provides the basic mechanisms for procedural abstraction and procedure (subprogram) application. === Anonymous functions === For example, in Python the "square" function can be expressed as a lambda expression as follows: The above example is an expression that evaluates to a first-class function. The symbol lambda creates an anonymous function, given a list of parameter names, x – just a single argument in this case, and an expression that is evaluated as the body of the function, x**2. Anonymous functions are sometimes called lambda expressions. For example, Pascal and many other imperative languages have long supported passing subprograms as arguments to other subprograms through the mechanism of function pointers. However, function pointers are an insufficient condition for functions to be first class datatypes, because a function is a first class datatype if and only if new instances of the function can be created at runtime. Such runtime creation of functions is supported in Smalltalk, JavaScript, Wolfram Language, and more recently in Scala, Eiffel (as agents), C# (as delegates) and C++11, among others. === Parallelism and concurrency === The Church–Rosser property of the lambda calculus means that evaluation (β-reduction) can be carried out in any order, even in parallel. This means that various nondeterministic evaluation strategies are relevant. However, the lambda calculus does not offer any explicit constructs for parallelism. One can add constructs such as futures to the lambda calculus. Other process calculi have been developed for describing communication and concurrency. == Semantics == The fact that lambda calculus terms act as functions on other lambda calculus terms, and even on themselves, led to questions about the semantics of the lambda calculus. Could a sensible meaning be assigned to lambda calculus terms? The natural semantics was to find a set D isomorphic to the function space D → D, of functions on itself. However, no nontrivial such D can exist, by cardinality constraints because the set of all functions from D to D has greater cardinality than D, unless D is a singleton set. In the 1970s, Dana Scott showed that if only continuous functions were considered, a set or domain D with the required property could be found, thus providing a model for the lambda calculus. This work also formed the basis for the denotational semantics of programming languages. == Variations and extensions == These extensions are in the lambda cube: Typed lambda calculus – Lambda calculus with typed variables (and functions) System F – A typed lambda calculus with type-variables Calculus of constructions – A typed lambda calculus with types as first-class values These formal systems are extensions of lambda calculus that are not in the lambda cube: Binary lambda calculus – A version of lambda calculus with binary input/output (I/O), a binary encoding of terms, and a designated universal machine. Lambda-mu calculus – An extension of the lambda calculus for treating classical logic These formal systems are variations of lambda calculus: Kappa calculus – A first-order analogue of lambda calculus These formal systems are related to lambda calculus: Combinatory logic – A notation for mathematical logic without variables SKI combinator calculus – A computational system based on the S, K and I combinators, equivalent to lambda calculus, but reducible without variable substitutions == See also == == Further reading == Abelson, Harold & Gerald Jay Sussman. Structure and Interpretation of Computer Programs. The MIT Press. ISBN 0-262-51087-1. Barendregt, Hendrik Pieter Introduction to Lambda Calculus. Barendregt, Hendrik Pieter, The Impact of the Lambda Calculus in Logic and Computer Science. The Bulletin of Symbolic Logic, Volume 3, Number 2, June 1997. Barendregt, Hendrik Pieter, The Type Free Lambda Calculus pp1091–1132 of Handbook of Mathematical Logic, North-Holland (1977) ISBN 0-7204-2285-X Cardone, Felice and Hindley, J. Roger, 2006. History of Lambda-calculus and Combinatory Logic Archived 2021-05-06 at the Wayback Machine. In Gabbay and Woods (eds.), Handbook of the History of Logic, vol. 5. Elsevier. Church, Alonzo, An unsolvable problem of elementary number theory, American Journal of Mathematics, 58 (1936), pp. 345–363. This paper contains the proof that the equivalence of lambda expressions is in general not decidable. Church, Alonzo (1941). The Calculi of Lambda-Conversion. Princeton: Princeton University Press. Retrieved 2020-04-14. (ISBN 978-0-691-08394-0) Frink Jr., Orrin (1944). "Review: The Calculi of Lambda-Conversion by Alonzo Church" (PDF). Bulletin of the American Mathematical Society. 50 (3): 169–172. doi:10.1090/s0002-9904-1944-08090-7. Kleene, Stephen, A theory of positive integers in formal logic, American Journal of Mathematics, 57 (1935), pp. 153–173 and 219–244. Contains the lambda calculus definitions of several familiar functions. Landin, Peter, A Correspondence Between ALGOL 60 and Church's Lambda-Notation, Communications of the ACM, vol. 8, no. 2 (1965), pages 89–101. Available from the ACM site. A classic paper highlighting the importance of lambda calculus as a basis for programming languages. Larson, Jim, An Introduction to Lambda Calculus and Scheme. A gentle introduction for programmers. Michaelson, Greg (10 April 2013). An Introduction to Functional Programming Through Lambda Calculus. Courier Corporation. ISBN 978-0-486-28029-5. Schalk, A. and Simmons, H. (2005) An introduction to λ-calculi and arithmetic with a decent selection of exercises. Notes for a course in the Mathematical Logic MSc at Manchester University. de Queiroz, Ruy J.G.B. (2008). "On Reduction Rules, Meaning-as-Use and Proof-Theoretic Semantics". Studia Logica. 90 (2): 211–247. doi:10.1007/s11225-008-9150-5. S2CID 11321602. A paper giving a formal underpinning to the idea of 'meaning-is-use' which, even if based on proofs, it is different from proof-theoretic semantics as in the Dummett–Prawitz tradition since it takes reduction as the rules giving meaning. Hankin, Chris, An Introduction to Lambda Calculi for Computer Scientists, ISBN 0954300653 Monographs/textbooks for graduate students Sørensen, Morten Heine and Urzyczyn, Paweł (2006), Lectures on the Curry–Howard isomorphism, Elsevier, ISBN 0-444-52077-5 is a recent monograph that covers the main topics of lambda calculus from the type-free variety, to most typed lambda calculi, including more recent developments like pure type systems and the lambda cube. It does not cover subtyping extensions. Pierce, Benjamin (2002), Types and Programming Languages, MIT Press, ISBN 0-262-16209-1 covers lambda calculi from a practical type system perspective; some topics like dependent types are only mentioned, but subtyping is an important topic. Documents A Short Introduction to the Lambda Calculus-(PDF) by Achim Jung A timeline of lambda calculus-(PDF) by Dana Scott A Tutorial Introduction to the Lambda Calculus-(PDF) by Raúl Rojas Lecture Notes on the Lambda Calculus-(PDF) by Peter Selinger Graphic lambda calculus by Marius Buliga Lambda Calculus as a Workflow Model by Peter Kelly, Paul Coddington, and Andrew Wendelborn; mentions graph reduction as a common means of evaluating lambda expressions and discusses the applicability of lambda calculus for distributed computing (due to the Church–Rosser property, which enables parallel graph reduction for lambda expressions). == Notes == == References == Some parts of this article are based on material from FOLDOC, used with permission. == External links == Graham Hutton, Lambda Calculus, a short (12 minutes) Computerphile video on the Lambda Calculus Helmut Brandl, Step by Step Introduction to Lambda Calculus "Lambda-calculus", Encyclopedia of Mathematics, EMS Press, 2001 [1994] David C. Keenan, To Dissect a Mockingbird: A Graphical Notation for the Lambda Calculus with Animated Reduction L. Allison, Some executable λ-calculus examples Georg P. Loczewski, The Lambda Calculus and A++ Bret Victor, Alligator Eggs: A Puzzle Game Based on Lambda Calculus Lambda Calculus Archived 2012-10-14 at the Wayback Machine on Safalra's Website Archived 2021-05-02 at the Wayback Machine LCI Lambda Interpreter a simple yet powerful pure calculus interpreter Lambda Calculus links on Lambda-the-Ultimate Mike Thyer, Lambda Animator, a graphical Java applet demonstrating alternative reduction strategies. Implementing the Lambda calculus using C++ Templates Shane Steinert-Threlkeld, "Lambda Calculi", Internet Encyclopedia of Philosophy Anton Salikhmetov, Macro Lambda Calculus
Wikipedia/Lambda_calculus
In mathematics, the domain of a function is the set of inputs accepted by the function. It is sometimes denoted by dom ⁡ ( f ) {\displaystyle \operatorname {dom} (f)} or dom ⁡ f {\displaystyle \operatorname {dom} f} , where f is the function. In layman's terms, the domain of a function can generally be thought of as "what x can be". More precisely, given a function f : X → Y {\displaystyle f\colon X\to Y} , the domain of f is X. In modern mathematical language, the domain is part of the definition of a function rather than a property of it. In the special case that X and Y are both sets of real numbers, the function f can be graphed in the Cartesian coordinate system. In this case, the domain is represented on the x-axis of the graph, as the projection of the graph of the function onto the x-axis. For a function f : X → Y {\displaystyle f\colon X\to Y} , the set Y is called the codomain: the set to which all outputs must belong. The set of specific outputs the function assigns to elements of X is called its range or image. The image of f is a subset of Y, shown as the yellow oval in the accompanying diagram. Any function can be restricted to a subset of its domain. The restriction of f : X → Y {\displaystyle f\colon X\to Y} to A {\displaystyle A} , where A ⊆ X {\displaystyle A\subseteq X} , is written as f | A : A → Y {\displaystyle \left.f\right|_{A}\colon A\to Y} . == Natural domain == If a real function f is given by a formula, it may be not defined for some values of the variable. In this case, it is a partial function, and the set of real numbers on which the formula can be evaluated to a real number is called the natural domain or domain of definition of f. In many contexts, a partial function is called simply a function, and its natural domain is called simply its domain. === Examples === The function f {\displaystyle f} defined by f ( x ) = 1 x {\displaystyle f(x)={\frac {1}{x}}} cannot be evaluated at 0. Therefore, the natural domain of f {\displaystyle f} is the set of real numbers excluding 0, which can be denoted by R ∖ { 0 } {\displaystyle \mathbb {R} \setminus \{0\}} or { x ∈ R : x ≠ 0 } {\displaystyle \{x\in \mathbb {R} :x\neq 0\}} . The piecewise function f {\displaystyle f} defined by f ( x ) = { 1 / x x ≠ 0 0 x = 0 , {\displaystyle f(x)={\begin{cases}1/x&x\not =0\\0&x=0\end{cases}},} has as its natural domain the set R {\displaystyle \mathbb {R} } of real numbers. The square root function f ( x ) = x {\displaystyle f(x)={\sqrt {x}}} has as its natural domain the set of non-negative real numbers, which can be denoted by R ≥ 0 {\displaystyle \mathbb {R} _{\geq 0}} , the interval [ 0 , ∞ ) {\displaystyle [0,\infty )} , or { x ∈ R : x ≥ 0 } {\displaystyle \{x\in \mathbb {R} :x\geq 0\}} . The tangent function, denoted tan {\displaystyle \tan } , has as its natural domain the set of all real numbers which are not of the form π 2 + k π {\displaystyle {\tfrac {\pi }{2}}+k\pi } for some integer k {\displaystyle k} , which can be written as R ∖ { π 2 + k π : k ∈ Z } {\displaystyle \mathbb {R} \setminus \{{\tfrac {\pi }{2}}+k\pi :k\in \mathbb {Z} \}} . == Other uses == The term domain is also commonly used in a different sense in mathematical analysis: a domain is a non-empty connected open set in a topological space. In particular, in real and complex analysis, a domain is a non-empty connected open subset of the real coordinate space R n {\displaystyle \mathbb {R} ^{n}} or the complex coordinate space C n . {\displaystyle \mathbb {C} ^{n}.} Sometimes such a domain is used as the domain of a function, although functions may be defined on more general sets. The two concepts are sometimes conflated as in, for example, the study of partial differential equations: in that case, a domain is the open connected subset of R n {\displaystyle \mathbb {R} ^{n}} where a problem is posed, making it both an analysis-style domain and also the domain of the unknown function(s) sought. == Set theoretical notions == For example, it is sometimes convenient in set theory to permit the domain of a function to be a proper class X, in which case there is formally no such thing as a triple (X, Y, G). With such a definition, functions do not have a domain, although some authors still use it informally after introducing a function in the form f: X → Y. == See also == Argument of a function Attribute domain Bijection, injection and surjection Codomain Domain decomposition Effective domain Endofunction Image (mathematics) Lipschitz domain Naive set theory Range of a function Support (mathematics) == Notes == == References == Bourbaki, Nicolas (1970). Théorie des ensembles. Éléments de mathématique. Springer. ISBN 9783540340348. Eccles, Peter J. (11 December 1997). An Introduction to Mathematical Reasoning: Numbers, Sets and Functions. Cambridge University Press. ISBN 978-0-521-59718-0. Mac Lane, Saunders (25 September 1998). Categories for the Working Mathematician. Springer Science & Business Media. ISBN 978-0-387-98403-2. Scott, Dana S.; Jech, Thomas J. (31 December 1971). Axiomatic Set Theory, Part 1. American Mathematical Soc. ISBN 978-0-8218-0245-8. Sharma, A. K. (2010). Introduction To Set Theory. Discovery Publishing House. ISBN 978-81-7141-877-0. Stewart, Ian; Tall, David (1977). The Foundations of Mathematics. Oxford University Press. ISBN 978-0-19-853165-4.
Wikipedia/Domain_of_a_function
In the mathematical field of set theory, an ultrafilter on a set X {\displaystyle X} is a maximal filter on the set X . {\displaystyle X.} In other words, it is a collection of subsets of X {\displaystyle X} that satisfies the definition of a filter on X {\displaystyle X} and that is maximal with respect to inclusion, in the sense that there does not exist a strictly larger collection of subsets of X {\displaystyle X} that is also a filter. (In the above, by definition a filter on a set does not contain the empty set.) Equivalently, an ultrafilter on the set X {\displaystyle X} can also be characterized as a filter on X {\displaystyle X} with the property that for every subset A {\displaystyle A} of X {\displaystyle X} either A {\displaystyle A} or its complement X ∖ A {\displaystyle X\setminus A} belongs to the ultrafilter. Ultrafilters on sets are an important special instance of ultrafilters on partially ordered sets, where the partially ordered set consists of the power set ℘ ( X ) {\displaystyle \wp (X)} and the partial order is subset inclusion ⊆ . {\displaystyle \,\subseteq .} This article deals specifically with ultrafilters on a set and does not cover the more general notion. There are two types of ultrafilter on a set. A principal ultrafilter on X {\displaystyle X} is the collection of all subsets of X {\displaystyle X} that contain a fixed element x ∈ X {\displaystyle x\in X} . The ultrafilters that are not principal are the free ultrafilters. The existence of free ultrafilters on any infinite set is implied by the ultrafilter lemma, which can be proven in ZFC. On the other hand, there exists models of ZF where every ultrafilter on a set is principal. Ultrafilters have many applications in set theory, model theory, and topology.: 186  Usually, only free ultrafilters lead to non-trivial constructions. For example, an ultraproduct modulo a principal ultrafilter is always isomorphic to one of the factors, while an ultraproduct modulo a free ultrafilter usually has a more complex structure. == Definitions == Given an arbitrary set X , {\displaystyle X,} an ultrafilter on X {\displaystyle X} is a non-empty family U {\displaystyle U} of subsets of X {\displaystyle X} such that: Proper or non-degenerate: The empty set is not an element of U . {\displaystyle U.} Upward closed in X {\displaystyle X} : If A ∈ U {\displaystyle A\in U} and if B ⊆ X {\displaystyle B\subseteq X} is any superset of A {\displaystyle A} (that is, if A ⊆ B ⊆ X {\displaystyle A\subseteq B\subseteq X} ) then B ∈ U . {\displaystyle B\in U.} π−system: If A {\displaystyle A} and B {\displaystyle B} are elements of U {\displaystyle U} then so is their intersection A ∩ B . {\displaystyle A\cap B.} If A ⊆ X {\displaystyle A\subseteq X} then either A {\displaystyle A} or its complement X ∖ A {\displaystyle X\setminus A} is an element of U . {\displaystyle U.} Properties (1), (2), and (3) are the defining properties of a filter on X . {\displaystyle X.} Some authors do not include non-degeneracy (which is property (1) above) in their definition of "filter". However, the definition of "ultrafilter" (and also of "prefilter" and "filter subbase") always includes non-degeneracy as a defining condition. This article requires that all filters be proper although a filter might be described as "proper" for emphasis. A filter subbase is a non-empty family of sets that has the finite intersection property (i.e. all finite intersections are non-empty). Equivalently, a filter subbase is a non-empty family of sets that is contained in some (proper) filter. The smallest (relative to ⊆ {\displaystyle \subseteq } ) filter containing a given filter subbase is said to be generated by the filter subbase. The upward closure in X {\displaystyle X} of a family of sets P {\displaystyle P} is the set P ↑ X := { S : A ⊆ S ⊆ X for some A ∈ P } . {\displaystyle P^{\uparrow X}:=\{S:A\subseteq S\subseteq X{\text{ for some }}A\in P\}.} A prefilter or filter base is a non-empty and proper (i.e. ∅ ∉ P {\displaystyle \varnothing \not \in P} ) family of sets P {\displaystyle P} that is downward directed, which means that if B , C ∈ P {\displaystyle B,C\in P} then there exists some A ∈ P {\displaystyle A\in P} such that A ⊆ B ∩ C . {\displaystyle A\subseteq B\cap C.} Equivalently, a prefilter is any family of sets P {\displaystyle P} whose upward closure P ↑ X {\displaystyle P^{\uparrow X}} is a filter, in which case this filter is called the filter generated by P {\displaystyle P} and P {\displaystyle P} is said to be a filter base for P ↑ X . {\displaystyle P^{\uparrow X}.} The dual in X {\displaystyle X} of a family of sets P {\displaystyle P} is the set X ∖ P := { X ∖ B : B ∈ P } . {\displaystyle X\setminus P:=\{X\setminus B:B\in P\}.} For example, the dual of the power set ℘ ( X ) {\displaystyle \wp (X)} is itself: X ∖ ℘ ( X ) = ℘ ( X ) . {\displaystyle X\setminus \wp (X)=\wp (X).} A family of sets is a proper filter on X {\displaystyle X} if and only if its dual is a proper ideal on X {\displaystyle X} ("proper" means not equal to the power set). == Generalization to ultra prefilters == A family U ≠ ∅ {\displaystyle U\neq \varnothing } of subsets of X {\displaystyle X} is called ultra if ∅ ∉ U {\displaystyle \varnothing \not \in U} and any of the following equivalent conditions are satisfied: For every set S ⊆ X {\displaystyle S\subseteq X} there exists some set B ∈ U {\displaystyle B\in U} such that B ⊆ S {\displaystyle B\subseteq S} or B ⊆ X ∖ S {\displaystyle B\subseteq X\setminus S} (or equivalently, such that B ∩ S {\displaystyle B\cap S} equals B {\displaystyle B} or ∅ {\displaystyle \varnothing } ). For every set S ⊆ ⋃ B ∈ U B {\displaystyle S\subseteq {\textstyle \bigcup \limits _{B\in U}}B} there exists some set B ∈ U {\displaystyle B\in U} such that B ∩ S {\displaystyle B\cap S} equals B {\displaystyle B} or ∅ . {\displaystyle \varnothing .} Here, ⋃ B ∈ U B {\displaystyle {\textstyle \bigcup \limits _{B\in U}}B} is defined to be the union of all sets in U . {\displaystyle U.} This characterization of " U {\displaystyle U} is ultra" does not depend on the set X , {\displaystyle X,} so mentioning the set X {\displaystyle X} is optional when using the term "ultra." For every set S {\displaystyle S} (not necessarily even a subset of X {\displaystyle X} ) there exists some set B ∈ U {\displaystyle B\in U} such that B ∩ S {\displaystyle B\cap S} equals B {\displaystyle B} or ∅ . {\displaystyle \varnothing .} If U {\displaystyle U} satisfies this condition then so does every superset V ⊇ U . {\displaystyle V\supseteq U.} In particular, a set V {\displaystyle V} is ultra if and only if ∅ ∉ V {\displaystyle \varnothing \not \in V} and V {\displaystyle V} contains as a subset some ultra family of sets. A filter subbase that is ultra is necessarily a prefilter. The ultra property can now be used to define both ultrafilters and ultra prefilters: An ultra prefilter is a prefilter that is ultra. Equivalently, it is a filter subbase that is ultra. An ultrafilter on X {\displaystyle X} is a (proper) filter on X {\displaystyle X} that is ultra. Equivalently, it is any filter on X {\displaystyle X} that is generated by an ultra prefilter. Ultra prefilters as maximal prefilters To characterize ultra prefilters in terms of "maximality," the following relation is needed. Given two families of sets M {\displaystyle M} and N , {\displaystyle N,} the family M {\displaystyle M} is said to be coarser than N , {\displaystyle N,} and N {\displaystyle N} is finer than and subordinate to M , {\displaystyle M,} written M ≤ N {\displaystyle M\leq N} or N ⊢ M, if for every C ∈ M , {\displaystyle C\in M,} there is some F ∈ N {\displaystyle F\in N} such that F ⊆ C . {\displaystyle F\subseteq C.} The families M {\displaystyle M} and N {\displaystyle N} are called equivalent if M ≤ N {\displaystyle M\leq N} and N ≤ M . {\displaystyle N\leq M.} The families M {\displaystyle M} and N {\displaystyle N} are comparable if one of these sets is finer than the other. The subordination relationship, i.e. ≥ , {\displaystyle \,\geq ,\,} is a preorder so the above definition of "equivalent" does form an equivalence relation. If M ⊆ N {\displaystyle M\subseteq N} then M ≤ N {\displaystyle M\leq N} but the converse does not hold in general. However, if N {\displaystyle N} is upward closed, such as a filter, then M ≤ N {\displaystyle M\leq N} if and only if M ⊆ N . {\displaystyle M\subseteq N.} Every prefilter is equivalent to the filter that it generates. This shows that it is possible for filters to be equivalent to sets that are not filters. If two families of sets M {\displaystyle M} and N {\displaystyle N} are equivalent then either both M {\displaystyle M} and N {\displaystyle N} are ultra (resp. prefilters, filter subbases) or otherwise neither one of them is ultra (resp. a prefilter, a filter subbase). In particular, if a filter subbase is not also a prefilter, then it is not equivalent to the filter or prefilter that it generates. If M {\displaystyle M} and N {\displaystyle N} are both filters on X {\displaystyle X} then M {\displaystyle M} and N {\displaystyle N} are equivalent if and only if M = N . {\displaystyle M=N.} If a proper filter (resp. ultrafilter) is equivalent to a family of sets M {\displaystyle M} then M {\displaystyle M} is necessarily a prefilter (resp. ultra prefilter). Using the following characterization, it is possible to define prefilters (resp. ultra prefilters) using only the concept of filters (resp. ultrafilters) and subordination: An arbitrary family of sets is a prefilter if and only it is equivalent to a (proper) filter. An arbitrary family of sets is an ultra prefilter if and only it is equivalent to an ultrafilter. A maximal prefilter on X {\displaystyle X} is a prefilter U ⊆ ℘ ( X ) {\displaystyle U\subseteq \wp (X)} that satisfies any of the following equivalent conditions: U {\displaystyle U} is ultra. U {\displaystyle U} is maximal on Prefilters ⁡ ( X ) {\displaystyle \operatorname {Prefilters} (X)} with respect to ≤ , {\displaystyle \,\leq ,} meaning that if P ∈ Prefilters ⁡ ( X ) {\displaystyle P\in \operatorname {Prefilters} (X)} satisfies U ≤ P {\displaystyle U\leq P} then P ≤ U . {\displaystyle P\leq U.} There is no prefilter properly subordinate to U . {\displaystyle U.} If a (proper) filter F {\displaystyle F} on X {\displaystyle X} satisfies U ≤ F {\displaystyle U\leq F} then F ≤ U . {\displaystyle F\leq U.} The filter on X {\displaystyle X} generated by U {\displaystyle U} is ultra. == Characterizations == There are no ultrafilters on the empty set, so it is henceforth assumed that X {\displaystyle X} is nonempty. A filter subbase U {\displaystyle U} on X {\displaystyle X} is an ultrafilter on X {\displaystyle X} if and only if any of the following equivalent conditions hold: for any S ⊆ X , {\displaystyle S\subseteq X,} either S ∈ U {\displaystyle S\in U} or X ∖ S ∈ U . {\displaystyle X\setminus S\in U.} U {\displaystyle U} is a maximal filter subbase on X , {\displaystyle X,} meaning that if F {\displaystyle F} is any filter subbase on X {\displaystyle X} then U ⊆ F {\displaystyle U\subseteq F} implies U = F . {\displaystyle U=F.} A (proper) filter U {\displaystyle U} on X {\displaystyle X} is an ultrafilter on X {\displaystyle X} if and only if any of the following equivalent conditions hold: U {\displaystyle U} is ultra; U {\displaystyle U} is generated by an ultra prefilter; For any subset S ⊆ X , {\displaystyle S\subseteq X,} S ∈ U {\displaystyle S\in U} or X ∖ S ∈ U . {\displaystyle X\setminus S\in U.} So an ultrafilter U {\displaystyle U} decides for every S ⊆ X {\displaystyle S\subseteq X} whether S {\displaystyle S} is "large" (i.e. S ∈ U {\displaystyle S\in U} ) or "small" (i.e. X ∖ S ∈ U {\displaystyle X\setminus S\in U} ). For each subset A ⊆ X , {\displaystyle A\subseteq X,} either A {\displaystyle A} is in U {\displaystyle U} or ( X ∖ A {\displaystyle X\setminus A} ) is. U ∪ ( X ∖ U ) = ℘ ( X ) . {\displaystyle U\cup (X\setminus U)=\wp (X).} This condition can be restated as: ℘ ( X ) {\displaystyle \wp (X)} is partitioned by U {\displaystyle U} and its dual X ∖ U . {\displaystyle X\setminus U.} The sets P {\displaystyle P} and X ∖ P {\displaystyle X\setminus P} are disjoint for all prefilters P {\displaystyle P} on X . {\displaystyle X.} ℘ ( X ) ∖ U = { S ∈ ℘ ( X ) : S ∉ U } {\displaystyle \wp (X)\setminus U=\left\{S\in \wp (X):S\not \in U\right\}} is an ideal on X . {\displaystyle X.} For any finite family S 1 , … , S n {\displaystyle S_{1},\ldots ,S_{n}} of subsets of X {\displaystyle X} (where n ≥ 1 {\displaystyle n\geq 1} ), if S 1 ∪ ⋯ ∪ S n ∈ U {\displaystyle S_{1}\cup \cdots \cup S_{n}\in U} then S i ∈ U {\displaystyle S_{i}\in U} for some index i . {\displaystyle i.} In words, a "large" set cannot be a finite union of sets none of which is large. For any R , S ⊆ X , {\displaystyle R,S\subseteq X,} if R ∪ S = X {\displaystyle R\cup S=X} then R ∈ U {\displaystyle R\in U} or S ∈ U . {\displaystyle S\in U.} For any R , S ⊆ X , {\displaystyle R,S\subseteq X,} if R ∪ S ∈ U {\displaystyle R\cup S\in U} then R ∈ U {\displaystyle R\in U} or S ∈ U {\displaystyle S\in U} (a filter with this property is called a prime filter). For any R , S ⊆ X , {\displaystyle R,S\subseteq X,} if R ∪ S ∈ U {\displaystyle R\cup S\in U} and R ∩ S = ∅ {\displaystyle R\cap S=\varnothing } then either R ∈ U {\displaystyle R\in U} or S ∈ U . {\displaystyle S\in U.} U {\displaystyle U} is a maximal filter; that is, if F {\displaystyle F} is a filter on X {\displaystyle X} such that U ⊆ F {\displaystyle U\subseteq F} then U = F . {\displaystyle U=F.} Equivalently, U {\displaystyle U} is a maximal filter if there is no filter F {\displaystyle F} on X {\displaystyle X} that contains U {\displaystyle U} as a proper subset (that is, no filter is strictly finer than U {\displaystyle U} ). === Grills and filter-grills === If B ⊆ ℘ ( X ) {\displaystyle {\mathcal {B}}\subseteq \wp (X)} then its grill on X {\displaystyle X} is the family B # X := { S ⊆ X : S ∩ B ≠ ∅ for all B ∈ B } {\displaystyle {\mathcal {B}}^{\#X}:=\{S\subseteq X~:~S\cap B\neq \varnothing {\text{ for all }}B\in {\mathcal {B}}\}} where B # {\displaystyle {\mathcal {B}}^{\#}} may be written if X {\displaystyle X} is clear from context. If F {\displaystyle {\mathcal {F}}} is a filter then F # {\displaystyle {\mathcal {F}}^{\#}} is the set of positive sets with respect to F {\displaystyle {\mathcal {F}}} and is usually written as F + {\displaystyle {\mathcal {F}}^{+}} . For example, ∅ # = ℘ ( X ) {\displaystyle \varnothing ^{\#}=\wp (X)} and if ∅ ∈ B {\displaystyle \varnothing \in {\mathcal {B}}} then B # = ∅ . {\displaystyle {\mathcal {B}}^{\#}=\varnothing .} If A ⊆ B {\displaystyle {\mathcal {A}}\subseteq {\mathcal {B}}} then B # ⊆ A # {\displaystyle {\mathcal {B}}^{\#}\subseteq {\mathcal {A}}^{\#}} and moreover, if B {\displaystyle {\mathcal {B}}} is a filter subbase then B ⊆ B # . {\displaystyle {\mathcal {B}}\subseteq {\mathcal {B}}^{\#}.} The grill B # X {\displaystyle {\mathcal {B}}^{\#X}} is upward closed in X {\displaystyle X} if and only if ∅ ∉ B , {\displaystyle \varnothing \not \in {\mathcal {B}},} which will henceforth be assumed. Moreover, B # # = B ↑ X {\displaystyle {\mathcal {B}}^{\#\#}={\mathcal {B}}^{\uparrow X}} so that B {\displaystyle {\mathcal {B}}} is upward closed in X {\displaystyle X} if and only if B # # = B . {\displaystyle {\mathcal {B}}^{\#\#}={\mathcal {B}}.} The grill of a filter on X {\displaystyle X} is called a filter-grill on X . {\displaystyle X.} For any ∅ ≠ B ⊆ ℘ ( X ) , {\displaystyle \varnothing \neq {\mathcal {B}}\subseteq \wp (X),} B {\displaystyle {\mathcal {B}}} is a filter-grill on X {\displaystyle X} if and only if (1) B {\displaystyle {\mathcal {B}}} is upward closed in X {\displaystyle X} and (2) for all sets R {\displaystyle R} and S , {\displaystyle S,} if R ∪ S ∈ B {\displaystyle R\cup S\in {\mathcal {B}}} then R ∈ B {\displaystyle R\in {\mathcal {B}}} or S ∈ B . {\displaystyle S\in {\mathcal {B}}.} The grill operation F ↦ F # X {\displaystyle {\mathcal {F}}\mapsto {\mathcal {F}}^{\#X}} induces a bijection ∙ # X : Filters ⁡ ( X ) → FilterGrills ⁡ ( X ) {\displaystyle {\bullet }^{\#X}~:~\operatorname {Filters} (X)\to \operatorname {FilterGrills} (X)} whose inverse is also given by F ↦ F # X . {\displaystyle {\mathcal {F}}\mapsto {\mathcal {F}}^{\#X}.} If F ∈ Filters ⁡ ( X ) {\displaystyle {\mathcal {F}}\in \operatorname {Filters} (X)} then F {\displaystyle {\mathcal {F}}} is a filter-grill on X {\displaystyle X} if and only if F = F # X , {\displaystyle {\mathcal {F}}={\mathcal {F}}^{\#X},} or equivalently, if and only if F {\displaystyle {\mathcal {F}}} is an ultrafilter on X . {\displaystyle X.} That is, a filter on X {\displaystyle X} is a filter-grill if and only if it is ultra. For any non-empty F ⊆ ℘ ( X ) , {\displaystyle {\mathcal {F}}\subseteq \wp (X),} F {\displaystyle {\mathcal {F}}} is both a filter on X {\displaystyle X} and a filter-grill on X {\displaystyle X} if and only if (1) ∅ ∉ F {\displaystyle \varnothing \not \in {\mathcal {F}}} and (2) for all R , S ⊆ X , {\displaystyle R,S\subseteq X,} the following equivalences hold: R ∪ S ∈ F {\displaystyle R\cup S\in {\mathcal {F}}} if and only if R , S ∈ F {\displaystyle R,S\in {\mathcal {F}}} if and only if R ∩ S ∈ F . {\displaystyle R\cap S\in {\mathcal {F}}.} === Free or principal === If P {\displaystyle P} is any non-empty family of sets then the Kernel of P {\displaystyle P} is the intersection of all sets in P : {\displaystyle P:} ker ⁡ P := ⋂ B ∈ P B . {\displaystyle \operatorname {ker} P:=\bigcap _{B\in P}B.} A non-empty family of sets P {\displaystyle P} is called: free if ker ⁡ P = ∅ {\displaystyle \operatorname {ker} P=\varnothing } and fixed otherwise (that is, if ker ⁡ P ≠ ∅ {\displaystyle \operatorname {ker} P\neq \varnothing } ). principal if ker ⁡ P ∈ P . {\displaystyle \operatorname {ker} P\in P.} principal at a point if ker ⁡ P ∈ P {\displaystyle \operatorname {ker} P\in P} and ker ⁡ P {\displaystyle \operatorname {ker} P} is a singleton set; in this case, if ker ⁡ P = { x } {\displaystyle \operatorname {ker} P=\{x\}} then P {\displaystyle P} is said to be principal at x . {\displaystyle x.} If a family of sets P {\displaystyle P} is fixed then P {\displaystyle P} is ultra if and only if some element of P {\displaystyle P} is a singleton set, in which case P {\displaystyle P} will necessarily be a prefilter. Every principal prefilter is fixed, so a principal prefilter P {\displaystyle P} is ultra if and only if ker ⁡ P {\displaystyle \operatorname {ker} P} is a singleton set. A singleton set is ultra if and only if its sole element is also a singleton set. The next theorem shows that every ultrafilter falls into one of two categories: either it is free or else it is a principal filter generated by a single point. Every filter on X {\displaystyle X} that is principal at a single point is an ultrafilter, and if in addition X {\displaystyle X} is finite, then there are no ultrafilters on X {\displaystyle X} other than these. In particular, if a set X {\displaystyle X} has finite cardinality n < ∞ , {\displaystyle n<\infty ,} then there are exactly n {\displaystyle n} ultrafilters on X {\displaystyle X} and those are the ultrafilters generated by each singleton subset of X . {\displaystyle X.} Consequently, free ultrafilters can only exist on an infinite set. == Examples, properties, and sufficient conditions == If X {\displaystyle X} is an infinite set then there are as many ultrafilters over X {\displaystyle X} as there are families of subsets of X ; {\displaystyle X;} explicitly, if X {\displaystyle X} has infinite cardinality κ {\displaystyle \kappa } then the set of ultrafilters over X {\displaystyle X} has the same cardinality as ℘ ( ℘ ( X ) ) ; {\displaystyle \wp (\wp (X));} that cardinality being 2 2 κ . {\displaystyle 2^{2^{\kappa }}.} If U {\displaystyle U} and S {\displaystyle S} are families of sets such that U {\displaystyle U} is ultra, ∅ ∉ S , {\displaystyle \varnothing \not \in S,} and U ≤ S , {\displaystyle U\leq S,} then S {\displaystyle S} is necessarily ultra. A filter subbase U {\displaystyle U} that is not a prefilter cannot be ultra; but it is nevertheless still possible for the prefilter and filter generated by U {\displaystyle U} to be ultra. Suppose U ⊆ ℘ ( X ) {\displaystyle U\subseteq \wp (X)} is ultra and Y {\displaystyle Y} is a set. The trace U | Y := { B ∩ Y : B ∈ U } {\displaystyle U\vert _{Y}:=\{B\cap Y:B\in U\}} is ultra if and only if it does not contain the empty set. Furthermore, at least one of the sets U | Y ∖ { ∅ } {\displaystyle U\vert _{Y}\setminus \{\varnothing \}} and U | X ∖ Y ∖ { ∅ } {\displaystyle U\vert _{X\setminus Y}\setminus \{\varnothing \}} will be ultra (this result extends to any finite partition of X {\displaystyle X} ). If F 1 , … , F n {\displaystyle F_{1},\ldots ,F_{n}} are filters on X , {\displaystyle X,} U {\displaystyle U} is an ultrafilter on X , {\displaystyle X,} and F 1 ∩ ⋯ ∩ F n ≤ U , {\displaystyle F_{1}\cap \cdots \cap F_{n}\leq U,} then there is some F i {\displaystyle F_{i}} that satisfies F i ≤ U . {\displaystyle F_{i}\leq U.} This result is not necessarily true for an infinite family of filters. The image under a map f : X → Y {\displaystyle f:X\to Y} of an ultra set U ⊆ ℘ ( X ) {\displaystyle U\subseteq \wp (X)} is again ultra and if U {\displaystyle U} is an ultra prefilter then so is f ( U ) . {\displaystyle f(U).} The property of being ultra is preserved under bijections. However, the preimage of an ultrafilter is not necessarily ultra, not even if the map is surjective. For example, if X {\displaystyle X} has more than one point and if the range of f : X → Y {\displaystyle f:X\to Y} consists of a single point { y } {\displaystyle \{y\}} then { y } {\displaystyle \{y\}} is an ultra prefilter on Y {\displaystyle Y} but its preimage is not ultra. Alternatively, if U {\displaystyle U} is a principal filter generated by a point in Y ∖ f ( X ) {\displaystyle Y\setminus f(X)} then the preimage of U {\displaystyle U} contains the empty set and so is not ultra. The elementary filter induced by an infinite sequence, all of whose points are distinct, is not an ultrafilter. If n = 2 , {\displaystyle n=2,} then U n {\displaystyle U_{n}} denotes the set consisting all subsets of X {\displaystyle X} having cardinality n , {\displaystyle n,} and if X {\displaystyle X} contains at least 2 n − 1 {\displaystyle 2n-1} ( = 3 {\displaystyle =3} ) distinct points, then U n {\displaystyle U_{n}} is ultra but it is not contained in any prefilter. This example generalizes to any integer n > 1 {\displaystyle n>1} and also to n = 1 {\displaystyle n=1} if X {\displaystyle X} contains more than one element. Ultra sets that are not also prefilters are rarely used. For every S ⊆ X × X {\displaystyle S\subseteq X\times X} and every a ∈ X , {\displaystyle a\in X,} let S | { a } × X := { y ∈ X : ( a , y ) ∈ S } . {\displaystyle S{\big \vert }_{\{a\}\times X}:=\{y\in X~:~(a,y)\in S\}.} If U {\displaystyle {\mathcal {U}}} is an ultrafilter on X {\displaystyle X} then the set of all S ⊆ X × X {\displaystyle S\subseteq X\times X} such that { a ∈ X : S | { a } × X ∈ U } ∈ U {\displaystyle \left\{a\in X~:~S{\big \vert }_{\{a\}\times X}\in {\mathcal {U}}\right\}\in {\mathcal {U}}} is an ultrafilter on X × X . {\displaystyle X\times X.} === Monad structure === The functor associating to any set X {\displaystyle X} the set of U ( X ) {\displaystyle U(X)} of all ultrafilters on X {\displaystyle X} forms a monad called the ultrafilter monad. The unit map X → U ( X ) {\displaystyle X\to U(X)} sends any element x ∈ X {\displaystyle x\in X} to the principal ultrafilter given by x . {\displaystyle x.} This ultrafilter monad is the codensity monad of the inclusion of the category of finite sets into the category of all sets, which gives a conceptual explanation of this monad. Similarly, the ultraproduct monad is the codensity monad of the inclusion of the category of finite families of sets into the category of all families of set. So in this sense, ultraproducts are categorically inevitable. == The ultrafilter lemma == The ultrafilter lemma was first proved by Alfred Tarski in 1930. The ultrafilter lemma is equivalent to each of the following statements: For every prefilter on a set X , {\displaystyle X,} there exists a maximal prefilter on X {\displaystyle X} subordinate to it. Every proper filter subbase on a set X {\displaystyle X} is contained in some ultrafilter on X . {\displaystyle X.} A consequence of the ultrafilter lemma is that every filter is equal to the intersection of all ultrafilters containing it. The following results can be proven using the ultrafilter lemma. A free ultrafilter exists on a set X {\displaystyle X} if and only if X {\displaystyle X} is infinite. Every proper filter is equal to the intersection of all ultrafilters containing it. Since there are filters that are not ultra, this shows that the intersection of a family of ultrafilters need not be ultra. A family of sets F ≠ ∅ {\displaystyle \mathbb {F} \neq \varnothing } can be extended to a free ultrafilter if and only if the intersection of any finite family of elements of F {\displaystyle \mathbb {F} } is infinite. === Relationships to other statements under ZF === Throughout this section, ZF refers to Zermelo–Fraenkel set theory and ZFC refers to ZF with the Axiom of Choice (AC). The ultrafilter lemma is independent of ZF. That is, there exist models in which the axioms of ZF hold but the ultrafilter lemma does not. There also exist models of ZF in which every ultrafilter is necessarily principal. Every filter that contains a singleton set is necessarily an ultrafilter and given x ∈ X , {\displaystyle x\in X,} the definition of the discrete ultrafilter { S ⊆ X : x ∈ S } {\displaystyle \{S\subseteq X:x\in S\}} does not require more than ZF. If X {\displaystyle X} is finite then every ultrafilter is a discrete filter at a point; consequently, free ultrafilters can only exist on infinite sets. In particular, if X {\displaystyle X} is finite then the ultrafilter lemma can be proven from the axioms ZF. The existence of free ultrafilter on infinite sets can be proven if the axiom of choice is assumed. More generally, the ultrafilter lemma can be proven by using the axiom of choice, which in brief states that any Cartesian product of non-empty sets is non-empty. Under ZF, the axiom of choice is, in particular, equivalent to (a) Zorn's lemma, (b) Tychonoff's theorem, (c) the weak form of the vector basis theorem (which states that every vector space has a basis), (d) the strong form of the vector basis theorem, and other statements. However, the ultrafilter lemma is strictly weaker than the axiom of choice. While free ultrafilters can be proven to exist, it is not possible to construct an explicit example of a free ultrafilter (using only ZF and the ultrafilter lemma); that is, free ultrafilters are intangible. Alfred Tarski proved that under ZFC, the cardinality of the set of all free ultrafilters on an infinite set X {\displaystyle X} is equal to the cardinality of ℘ ( ℘ ( X ) ) , {\displaystyle \wp (\wp (X)),} where ℘ ( X ) {\displaystyle \wp (X)} denotes the power set of X . {\displaystyle X.} Other authors attribute this discovery to Bedřich Pospíšil (following a combinatorial argument from Fichtenholz, and Kantorovitch, improved by Hausdorff). Under ZF, the axiom of choice can be used to prove both the ultrafilter lemma and the Krein–Milman theorem; conversely, under ZF, the ultrafilter lemma together with the Krein–Milman theorem can prove the axiom of choice. ==== Statements that cannot be deduced ==== The ultrafilter lemma is a relatively weak axiom. For example, each of the statements in the following list can not be deduced from ZF together with only the ultrafilter lemma: A countable union of countable sets is a countable set. The axiom of countable choice (ACC). The axiom of dependent choice (ADC). ==== Equivalent statements ==== Under ZF, the ultrafilter lemma is equivalent to each of the following statements: The Boolean prime ideal theorem (BPIT). Stone's representation theorem for Boolean algebras. Any product of Boolean spaces is a Boolean space. Boolean Prime Ideal Existence Theorem: Every nondegenerate Boolean algebra has a prime ideal. Tychonoff's theorem for Hausdorff spaces: Any product of compact Hausdorff spaces is compact. If { 0 , 1 } {\displaystyle \{0,1\}} is endowed with the discrete topology then for any set I , {\displaystyle I,} the product space { 0 , 1 } I {\displaystyle \{0,1\}^{I}} is compact. Each of the following versions of the Banach-Alaoglu theorem is equivalent to the ultrafilter lemma: Any equicontinuous set of scalar-valued maps on a topological vector space (TVS) is relatively compact in the weak-* topology (that is, it is contained in some weak-* compact set). The polar of any neighborhood of the origin in a TVS X {\displaystyle X} is a weak-* compact subset of its continuous dual space. The closed unit ball in the continuous dual space of any normed space is weak-* compact. If the normed space is separable then the ultrafilter lemma is sufficient but not necessary to prove this statement. A topological space X {\displaystyle X} is compact if every ultrafilter on X {\displaystyle X} converges to some limit. A topological space X {\displaystyle X} is compact if and only if every ultrafilter on X {\displaystyle X} converges to some limit. The addition of the words "and only if" is the only difference between this statement and the one immediately above it. The Alexander subbase theorem. The Ultranet lemma: Every net has a universal subnet. By definition, a net in X {\displaystyle X} is called an ultranet or an universal net if for every subset S ⊆ X , {\displaystyle S\subseteq X,} the net is eventually in S {\displaystyle S} or in X ∖ S . {\displaystyle X\setminus S.} A topological space X {\displaystyle X} is compact if and only if every ultranet on X {\displaystyle X} converges to some limit. If the words "and only if" are removed then the resulting statement remains equivalent to the ultrafilter lemma. A convergence space X {\displaystyle X} is compact if every ultrafilter on X {\displaystyle X} converges. A uniform space is compact if it is complete and totally bounded. The Stone–Čech compactification Theorem. Each of the following versions of the compactness theorem is equivalent to the ultrafilter lemma: If Σ {\displaystyle \Sigma } is a set of first-order sentences such that every finite subset of Σ {\displaystyle \Sigma } has a model, then Σ {\displaystyle \Sigma } has a model. If Σ {\displaystyle \Sigma } is a set of zero-order sentences such that every finite subset of Σ {\displaystyle \Sigma } has a model, then Σ {\displaystyle \Sigma } has a model. The completeness theorem: If Σ {\displaystyle \Sigma } is a set of zero-order sentences that is syntactically consistent, then it has a model (that is, it is semantically consistent). ==== Weaker statements ==== Any statement that can be deduced from the ultrafilter lemma (together with ZF) is said to be weaker than the ultrafilter lemma. A weaker statement is said to be strictly weaker if under ZF, it is not equivalent to the ultrafilter lemma. Under ZF, the ultrafilter lemma implies each of the following statements: The Axiom of Choice for Finite sets (ACF): Given I ≠ ∅ {\displaystyle I\neq \varnothing } and a family ( X i ) i ∈ I {\displaystyle \left(X_{i}\right)_{i\in I}} of non-empty finite sets, their product ∏ i ∈ I X i {\displaystyle {\textstyle \prod \limits _{i\in I}}X_{i}} is not empty. A countable union of finite sets is a countable set. However, ZF with the ultrafilter lemma is too weak to prove that a countable union of countable sets is a countable set. The Hahn–Banach theorem. In ZF, the Hahn–Banach theorem is strictly weaker than the ultrafilter lemma. The Banach–Tarski paradox. In fact, under ZF, the Banach–Tarski paradox can be deduced from the Hahn–Banach theorem, which is strictly weaker than the Ultrafilter Lemma. Every set can be linearly ordered. Every field has a unique algebraic closure. Non-trivial ultraproducts exist. The weak ultrafilter theorem: A free ultrafilter exists on N . {\displaystyle \mathbb {N} .} Under ZF, the weak ultrafilter theorem does not imply the ultrafilter lemma; that is, it is strictly weaker than the ultrafilter lemma. There exists a free ultrafilter on every infinite set; This statement is actually strictly weaker than the ultrafilter lemma. ZF alone does not even imply that there exists a non-principal ultrafilter on some set. == Completeness == The completeness of an ultrafilter U {\displaystyle U} on a powerset is the smallest cardinal κ such that there are κ elements of U {\displaystyle U} whose intersection is not in U . {\displaystyle U.} The definition of an ultrafilter implies that the completeness of any powerset ultrafilter is at least ℵ 0 {\displaystyle \aleph _{0}} . An ultrafilter whose completeness is greater than ℵ 0 {\displaystyle \aleph _{0}} —that is, the intersection of any countable collection of elements of U {\displaystyle U} is still in U {\displaystyle U} —is called countably complete or σ-complete. The completeness of a countably complete nonprincipal ultrafilter on a powerset is always a measurable cardinal. == Ordering on ultrafilters == The Rudin–Keisler ordering (named after Mary Ellen Rudin and Howard Jerome Keisler) is a preorder on the class of powerset ultrafilters defined as follows: if U {\displaystyle U} is an ultrafilter on ℘ ( X ) , {\displaystyle \wp (X),} and V {\displaystyle V} an ultrafilter on ℘ ( Y ) , {\displaystyle \wp (Y),} then V ≤ R K U {\displaystyle V\leq {}_{RK}U} if there exists a function f : X → Y {\displaystyle f:X\to Y} such that C ∈ V {\displaystyle C\in V} if and only if f − 1 [ C ] ∈ U {\displaystyle f^{-1}[C]\in U} for every subset C ⊆ Y . {\displaystyle C\subseteq Y.} Ultrafilters U {\displaystyle U} and V {\displaystyle V} are called Rudin–Keisler equivalent, denoted U ≡RK V, if there exist sets A ∈ U {\displaystyle A\in U} and B ∈ V {\displaystyle B\in V} and a bijection f : A → B {\displaystyle f:A\to B} that satisfies the condition above. (If X {\displaystyle X} and Y {\displaystyle Y} have the same cardinality, the definition can be simplified by fixing A = X , {\displaystyle A=X,} B = Y . {\displaystyle B=Y.} ) It is known that ≡RK is the kernel of ≤RK, i.e., that U ≡RK V if and only if U ≤ R K V {\displaystyle U\leq {}_{RK}V} and V ≤ R K U . {\displaystyle V\leq {}_{RK}U.} == Ultrafilters on ℘(ω) == There are several special properties that an ultrafilter on ℘ ( ω ) , {\displaystyle \wp (\omega ),} where ω {\displaystyle \omega } extends the natural numbers, may possess, which prove useful in various areas of set theory and topology. A non-principal ultrafilter U {\displaystyle U} is called a P-point (or weakly selective) if for every partition { C n : n < ω } {\displaystyle \left\{C_{n}:n<\omega \right\}} of ω {\displaystyle \omega } such that for all n < ω , {\displaystyle n<\omega ,} C n ∉ U , {\displaystyle C_{n}\not \in U,} there exists some A ∈ U {\displaystyle A\in U} such that A ∩ C n {\displaystyle A\cap C_{n}} is a finite set for each n . {\displaystyle n.} A non-principal ultrafilter U {\displaystyle U} is called Ramsey (or selective) if for every partition { C n : n < ω } {\displaystyle \left\{C_{n}:n<\omega \right\}} of ω {\displaystyle \omega } such that for all n < ω , {\displaystyle n<\omega ,} C n ∉ U , {\displaystyle C_{n}\not \in U,} there exists some A ∈ U {\displaystyle A\in U} such that A ∩ C n {\displaystyle A\cap C_{n}} is a singleton set for each n . {\displaystyle n.} It is a trivial observation that all Ramsey ultrafilters are P-points. Walter Rudin proved that the continuum hypothesis implies the existence of Ramsey ultrafilters. In fact, many hypotheses imply the existence of Ramsey ultrafilters, including Martin's axiom. Saharon Shelah later showed that it is consistent that there are no P-point ultrafilters. Therefore, the existence of these types of ultrafilters is independent of ZFC. P-points are called as such because they are topological P-points in the usual topology of the space βω \ ω of non-principal ultrafilters. The name Ramsey comes from Ramsey's theorem. To see why, one can prove that an ultrafilter is Ramsey if and only if for every 2-coloring of [ ω ] 2 {\displaystyle [\omega ]^{2}} there exists an element of the ultrafilter that has a homogeneous color. An ultrafilter on ℘ ( ω ) {\displaystyle \wp (\omega )} is Ramsey if and only if it is minimal in the Rudin–Keisler ordering of non-principal powerset ultrafilters. == See also == Extender (set theory) – in set theory, a system of ultrafilters representing an elementary embedding witnessing large cardinal propertiesPages displaying wikidata descriptions as a fallback Filter (mathematics) – In mathematics, a special subset of a partially ordered set Filter (set theory) – Family of sets representing "large" sets Filters in topology – Use of filters to describe and characterize all basic topological notions and results. Łoś's theorem – Mathematical constructionPages displaying short descriptions of redirect targets Ultrafilter – Maximal proper filter Universal net – Generalization of a sequence of pointsPages displaying short descriptions of redirect targets == Notes == Proofs == References == == Bibliography == Arkhangel'skii, Alexander Vladimirovich; Ponomarev, V.I. (1984). Fundamentals of General Topology: Problems and Exercises. Mathematics and Its Applications. Vol. 13. Dordrecht Boston: D. Reidel. ISBN 978-90-277-1355-1. OCLC 9944489. Bourbaki, Nicolas (1989) [1966]. General Topology: Chapters 1–4 [Topologie Générale]. Éléments de mathématique. Berlin New York: Springer Science & Business Media. ISBN 978-3-540-64241-1. OCLC 18588129. Dixmier, Jacques (1984). General Topology. Undergraduate Texts in Mathematics. Translated by Berberian, S. K. New York: Springer-Verlag. ISBN 978-0-387-90972-1. OCLC 10277303. Dolecki, Szymon; Mynard, Frédéric (2016). Convergence Foundations Of Topology. New Jersey: World Scientific Publishing Company. ISBN 978-981-4571-52-4. OCLC 945169917. Dugundji, James (1966). Topology. Boston: Allyn and Bacon. ISBN 978-0-697-06889-7. OCLC 395340485. Császár, Ákos (1978). General topology. Translated by Császár, Klára. Bristol England: Adam Hilger Ltd. ISBN 0-85274-275-4. OCLC 4146011. Jech, Thomas (2006). Set Theory: The Third Millennium Edition, Revised and Expanded. Berlin New York: Springer Science & Business Media. ISBN 978-3-540-44085-7. OCLC 50422939. Joshi, K. D. (1983). Introduction to General Topology. New York: John Wiley and Sons Ltd. ISBN 978-0-85226-444-7. OCLC 9218750. Narici, Lawrence; Beckenstein, Edward (2011). Topological Vector Spaces. Pure and applied mathematics (Second ed.). Boca Raton, FL: CRC Press. ISBN 978-1584888666. OCLC 144216834. Schechter, Eric (1996). Handbook of Analysis and Its Foundations. San Diego, CA: Academic Press. ISBN 978-0-12-622760-4. OCLC 175294365. Schubert, Horst (1968). Topology. London: Macdonald & Co. ISBN 978-0-356-02077-8. OCLC 463753. == Further reading == Comfort, W. W. (1977). "Ultrafilters: some old and some new results" (PDF). Bulletin of the American Mathematical Society. 83 (4): 417–455. doi:10.1090/S0002-9904-1977-14316-4. ISSN 0002-9904. MR 0454893. Comfort, W. W.; Negrepontis, S. (1974), The theory of ultrafilters, Berlin, New York: Springer-Verlag, MR 0396267 Ultrafilter at the nLab
Wikipedia/Ultrafilter_(set_theory)
Automata theory is the study of abstract machines and automata, as well as the computational problems that can be solved using them. It is a theory in theoretical computer science with close connections to cognitive science and mathematical logic. The word automata comes from the Greek word αὐτόματος, which means "self-acting, self-willed, self-moving". An automaton (automata in plural) is an abstract self-propelled computing device which follows a predetermined sequence of operations automatically. An automaton with a finite number of states is called a finite automaton (FA) or finite-state machine (FSM). The figure on the right illustrates a finite-state machine, which is a well-known type of automaton. This automaton consists of states (represented in the figure by circles) and transitions (represented by arrows). As the automaton sees a symbol of input, it makes a transition (or jump) to another state, according to its transition function, which takes the previous state and current input symbol as its arguments. Automata theory is closely related to formal language theory. In this context, automata are used as finite representations of formal languages that may be infinite. Automata are often classified by the class of formal languages they can recognize, as in the Chomsky hierarchy, which describes a nesting relationship between major classes of automata. Automata play a major role in the theory of computation, compiler construction, artificial intelligence, parsing and formal verification. == History == The theory of abstract automata was developed in the mid-20th century in connection with finite automata. Automata theory was initially considered a branch of mathematical systems theory, studying the behavior of discrete-parameter systems. Early work in automata theory differed from previous work on systems by using abstract algebra to describe information systems rather than differential calculus to describe material systems. The theory of the finite-state transducer was developed under different names by different research communities. The earlier concept of Turing machine was also included in the discipline along with new forms of infinite-state automata, such as pushdown automata. 1956 saw the publication of Automata Studies, which collected work by scientists including Claude Shannon, W. Ross Ashby, John von Neumann, Marvin Minsky, Edward F. Moore, and Stephen Cole Kleene. With the publication of this volume, "automata theory emerged as a relatively autonomous discipline". The book included Kleene's description of the set of regular events, or regular languages, and a relatively stable measure of complexity in Turing machine programs by Shannon. In the same year, Noam Chomsky described the Chomsky hierarchy, a correspondence between automata and formal grammars, and Ross Ashby published An Introduction to Cybernetics, an accessible textbook explaining automata and information using basic set theory. The study of linear bounded automata led to the Myhill–Nerode theorem, which gives a necessary and sufficient condition for a formal language to be regular, and an exact count of the number of states in a minimal machine for the language. The pumping lemma for regular languages, also useful in regularity proofs, was proven in this period by Michael O. Rabin and Dana Scott, along with the computational equivalence of deterministic and nondeterministic finite automata. In the 1960s, a body of algebraic results known as "structure theory" or "algebraic decomposition theory" emerged, which dealt with the realization of sequential machines from smaller machines by interconnection. While any finite automaton can be simulated using a universal gate set, this requires that the simulating circuit contain loops of arbitrary complexity. Structure theory deals with the "loop-free" realizability of machines. The theory of computational complexity also took shape in the 1960s. By the end of the decade, automata theory came to be seen as "the pure mathematics of computer science". == Automata == What follows is a general definition of an automaton, which restricts a broader definition of a system to one viewed as acting in discrete time-steps, with its state behavior and outputs defined at each step by unchanging functions of only its state and input. === Informal description === An automaton runs when it is given some sequence of inputs in discrete (individual) time steps (or just steps). An automaton processes one input picked from a set of symbols or letters, which is called an input alphabet. The symbols received by the automaton as input at any step are a sequence of symbols called words. An automaton has a set of states. At each moment during a run of the automaton, the automaton is in one of its states. When the automaton receives new input, it moves to another state (or transitions) based on a transition function that takes the previous state and current input symbol as parameters. At the same time, another function called the output function produces symbols from the output alphabet, also according to the previous state and current input symbol. The automaton reads the symbols of the input word and transitions between states until the word is read completely, if it is finite in length, at which point the automaton halts. A state at which the automaton halts is called the final state. To investigate the possible state/input/output sequences in an automaton using formal language theory, a machine can be assigned a starting state and a set of accepting states. Then, depending on whether a run starting from the starting state ends in an accepting state, the automaton can be said to accept or reject an input sequence. The set of all the words accepted by an automaton is called the language recognized by the automaton. A familiar example of a machine recognizing a language is an electronic lock, which accepts or rejects attempts to enter the correct code. === Formal definition === Automaton An automaton can be represented formally by a quintuple M = ⟨ Σ , Γ , Q , δ , λ ⟩ {\displaystyle M=\langle \Sigma ,\Gamma ,Q,\delta ,\lambda \rangle } , where: Σ {\displaystyle \Sigma } is a finite set of symbols, called the input alphabet of the automaton, Γ {\displaystyle \Gamma } is another finite set of symbols, called the output alphabet of the automaton, Q {\displaystyle Q} is a set of states, δ {\displaystyle \delta } is the next-state function or transition function δ : Q × Σ → Q {\displaystyle \delta :Q\times \Sigma \to Q} mapping state-input pairs to successor states, λ {\displaystyle \lambda } is the next-output function λ : Q × Σ → Γ {\displaystyle \lambda :Q\times \Sigma \to \Gamma } mapping state-input pairs to outputs. If Q {\displaystyle Q} is finite, then M {\displaystyle M} is a finite automaton. Input word An automaton reads a finite string of symbols a 1 a 2 . . . a n {\displaystyle a_{1}a_{2}...a_{n}} , where a i ∈ Σ {\displaystyle a_{i}\in \Sigma } , which is called an input word. The set of all words is denoted by Σ ∗ {\displaystyle \Sigma ^{*}} . Run A sequence of states q 0 , q 1 , . . . , q n {\displaystyle q_{0},q_{1},...,q_{n}} , where q i ∈ Q {\displaystyle q_{i}\in Q} such that q i = δ ( q i − 1 , a i ) {\displaystyle q_{i}=\delta (q_{i-1},a_{i})} for 0 < i ≤ n {\displaystyle 0<i\leq n} , is a run of the automaton on an input a 1 a 2 . . . a n ∈ Σ ∗ {\displaystyle a_{1}a_{2}...a_{n}\in \Sigma ^{*}} starting from state q 0 {\displaystyle q_{0}} . In other words, at first the automaton is at the start state q 0 {\displaystyle q_{0}} , and receives input a 1 {\displaystyle a_{1}} . For a 1 {\displaystyle a_{1}} and every following a i {\displaystyle a_{i}} in the input string, the automaton picks the next state q i {\displaystyle q_{i}} according to the transition function δ ( q i − 1 , a i ) {\displaystyle \delta (q_{i-1},a_{i})} , until the last symbol a n {\displaystyle a_{n}} has been read, leaving the machine in the final state of the run, q n {\displaystyle q_{n}} . Similarly, at each step, the automaton emits an output symbol according to the output function λ ( q i − 1 , a i ) {\displaystyle \lambda (q_{i-1},a_{i})} . The transition function δ {\displaystyle \delta } is extended inductively into δ ¯ : Q × Σ ∗ → Q {\displaystyle {\overline {\delta }}:Q\times \Sigma ^{*}\to Q} to describe the machine's behavior when fed whole input words. For the empty string ε {\displaystyle \varepsilon } , δ ¯ ( q , ε ) = q {\displaystyle {\overline {\delta }}(q,\varepsilon )=q} for all states q {\displaystyle q} , and for strings w a {\displaystyle wa} where a {\displaystyle a} is the last symbol and w {\displaystyle w} is the (possibly empty) rest of the string, δ ¯ ( q , w a ) = δ ( δ ¯ ( q , w ) , a ) {\displaystyle {\overline {\delta }}(q,wa)=\delta ({\overline {\delta }}(q,w),a)} . The output function λ {\displaystyle \lambda } may be extended similarly into λ ¯ ( q , w ) {\displaystyle {\overline {\lambda }}(q,w)} , which gives the complete output of the machine when run on word w {\displaystyle w} from state q {\displaystyle q} . Acceptor In order to study an automaton with the theory of formal languages, an automaton may be considered as an acceptor, replacing the output alphabet and function Γ {\displaystyle \Gamma } and λ {\displaystyle \lambda } with q 0 ∈ Q {\displaystyle q_{0}\in Q} , a designated start state, and F {\displaystyle F} , a set of states of Q {\displaystyle Q} (i.e. F ⊆ Q {\displaystyle F\subseteq Q} ) called accept states. This allows the following to be defined: Accepting word A word w = a 1 a 2 . . . a n ∈ Σ ∗ {\displaystyle w=a_{1}a_{2}...a_{n}\in \Sigma ^{*}} is an accepting word for the automaton if δ ¯ ( q 0 , w ) ∈ F {\displaystyle {\overline {\delta }}(q_{0},w)\in F} , that is, if after consuming the whole string w {\displaystyle w} the machine is in an accept state. Recognized language The language L ⊆ Σ ∗ {\displaystyle L\subseteq \Sigma ^{*}} recognized by an automaton is the set of all the words that are accepted by the automaton, L = { w ∈ Σ ∗ | δ ¯ ( q 0 , w ) ∈ F } {\displaystyle L=\{w\in \Sigma ^{*}\ |\ {\overline {\delta }}(q_{0},w)\in F\}} . Recognizable languages The recognizable languages are the set of languages that are recognized by some automaton. For finite automata the recognizable languages are regular languages. For different types of automata, the recognizable languages are different. == Variant definitions of automata == Automata are defined to study useful machines under mathematical formalism. So the definition of an automaton is open to variations according to the "real world machine" that we want to model using the automaton. People have studied many variations of automata. The following are some popular variations in the definition of different components of automata. Input Finite input: An automaton that accepts only finite sequences of symbols. The above introductory definition only encompasses finite words. Infinite input: An automaton that accepts infinite words (ω-words). Such automata are called ω-automata. Tree input: The input may be a tree of symbols instead of sequence of symbols. In this case after reading each symbol, the automaton reads all the successor symbols in the input tree. It is said that the automaton makes one copy of itself for each successor and each such copy starts running on one of the successor symbols from the state according to the transition relation of the automaton. Such an automaton is called a tree automaton. Infinite tree input : The two extensions above can be combined, so the automaton reads a tree structure with (in)finite branches. Such an automaton is called an infinite tree automaton. States Single state: An automaton with one state, also called a combinational circuit, performs a transformation which may implement combinational logic. Finite states: An automaton that contains only a finite number of states. Infinite states: An automaton that may not have a finite number of states, or even a countable number of states. Different kinds of abstract memory may be used to give such machines finite descriptions. Stack memory: An automaton may also contain some extra memory in the form of a stack in which symbols can be pushed and popped. This kind of automaton is called a pushdown automaton. Queue memory: An automaton may have memory in the form of a queue. Such a machine is called queue machine and is Turing-complete. Tape memory: The inputs and outputs of automata are often described as input and output tapes. Some machines have additional working tapes, including the Turing machine, linear bounded automaton, and log-space transducer. Transition function Deterministic: For a given current state and an input symbol, if an automaton can only jump to one and only one state then it is a deterministic automaton. Nondeterministic: An automaton that, after reading an input symbol, may jump into any of a number of states, as licensed by its transition relation. The term transition function is replaced by transition relation: The automaton non-deterministically decides to jump into one of the allowed choices. Such automata are called nondeterministic automata. Alternation: This idea is quite similar to tree automata but orthogonal. The automaton may run its multiple copies on the same next read symbol. Such automata are called alternating automata. The acceptance condition must be satisfied on all runs of such copies to accept the input. Two-wayness: Automata may read their input from left to right, or they may be allowed to move back-and-forth on the input, in a way similar to a Turing machine. Automata which can move back-and-forth on the input are called two-way finite automata. Acceptance condition Acceptance of finite words: Same as described in the informal definition above. Acceptance of infinite words: an ω-automaton cannot have final states, as infinite words never terminate. Rather, acceptance of the word is decided by looking at the infinite sequence of visited states during the run. Probabilistic acceptance: An automaton need not strictly accept or reject an input. It may accept the input with some probability between zero and one. For example, quantum finite automata, geometric automata and metric automata have probabilistic acceptance. Different combinations of the above variations produce many classes of automata. Automata theory is a subject matter that studies properties of various types of automata. For example, the following questions are studied about a given type of automata. Which class of formal languages is recognizable by some type of automata? (Recognizable languages) Are certain automata closed under union, intersection, or complementation of formal languages? (Closure properties) How expressive is a type of automata in terms of recognizing a class of formal languages? And, their relative expressive power? (Language hierarchy) Automata theory also studies the existence or nonexistence of any effective algorithms to solve problems similar to the following list: Does an automaton accept at least one input word? (Emptiness checking) Is it possible to transform a given non-deterministic automaton into a deterministic automaton without changing the language recognized? (Determinization) For a given formal language, what is the smallest automaton that recognizes it? (Minimization) == Types of automata == The following is an incomplete list of types of automata. === Discrete, continuous, and hybrid automata === Normally automata theory describes the states of abstract machines but there are discrete automata, analog automata or continuous automata, or hybrid discrete-continuous automata, which use digital data, analog data or continuous time, or digital and analog data, respectively. == Hierarchy in terms of powers == The following is an incomplete hierarchy in terms of powers of different types of virtual machines. The hierarchy reflects the nested categories of languages the machines are able to accept. == Applications == Each model in automata theory plays important roles in several applied areas. Finite automata are used in text processing, compilers, and hardware design. Context-free grammar (CFGs) are used in programming languages and artificial intelligence. Originally, CFGs were used in the study of human languages. Cellular automata are used in the field of artificial life, the most famous example being John Conway's Game of Life. Some other examples which could be explained using automata theory in biology include mollusk and pine cone growth and pigmentation patterns. Going further, a theory suggesting that the whole universe is computed by some sort of a discrete automaton, is advocated by some scientists. The idea originated in the work of Konrad Zuse, and was popularized in America by Edward Fredkin. Automata also appear in the theory of finite fields: the set of irreducible polynomials that can be written as composition of degree two polynomials is in fact a regular language. Another problem for which automata can be used is the induction of regular languages. == Automata simulators == Automata simulators are pedagogical tools used to teach, learn and research automata theory. An automata simulator takes as input the description of an automaton and then simulates its working for an arbitrary input string. The description of the automaton can be entered in several ways. An automaton can be defined in a symbolic language or its specification may be entered in a predesigned form or its transition diagram may be drawn by clicking and dragging the mouse. Well known automata simulators include Turing's World, JFLAP, VAS, TAGS and SimStudio. == Category-theoretic models == One can define several distinct categories of automata following the automata classification into different types described in the previous section. The mathematical category of deterministic automata, sequential machines or sequential automata, and Turing machines with automata homomorphisms defining the arrows between automata is a Cartesian closed category, it has both categorical limits and colimits. An automata homomorphism maps a quintuple of an automaton Ai onto the quintuple of another automaton Aj. Automata homomorphisms can also be considered as automata transformations or as semigroup homomorphisms, when the state space, S, of the automaton is defined as a semigroup Sg. Monoids are also considered as a suitable setting for automata in monoidal categories. Categories of variable automata One could also define a variable automaton, in the sense of Norbert Wiener in his book on The Human Use of Human Beings via the endomorphisms A i → A i {\displaystyle A_{i}\to A_{i}} . Then one can show that such variable automata homomorphisms form a mathematical group. In the case of non-deterministic, or other complex kinds of automata, the latter set of endomorphisms may become, however, a variable automaton groupoid. Therefore, in the most general case, categories of variable automata of any kind are categories of groupoids or groupoid categories. Moreover, the category of reversible automata is then a 2-category, and also a subcategory of the 2-category of groupoids, or the groupoid category. == See also == Boolean differential calculus Petri net == References == == Further reading == Hopcroft, John E.; Motwani, Rajeev; Ullman, Jeffrey D. (2006) [1979]. Introduction to Automata Theory, Languages, and Computation (3rd ed.). Addison-Wesley. ISBN 0-321-45536-3. Sipser, Michael (1997). Introduction to the Theory of Computation (1st ed.). PWS Publishing. ISBN 978-0-534-94728-6. (accessible to patrons with print disabilities) Part One: Automata and Languages, chapters 1–2, pp. 29–122. Section 4.1: Decidable Languages, pp. 152–159. Section 5.1: Undecidable Problems from Language Theory, pp. 172–183. Elaine Rich (2008). Automata, Computability and Complexity: Theory and Applications. Pearson. ISBN 978-0-13-228806-4. Salomaa, Arto (1985). Computation and automata. Encyclopedia of Mathematics and Its Applications. Vol. 25. Cambridge University Press. ISBN 978-0-521-30245-6. Zbl 0565.68046. Anderson, James A. (2006). Automata theory with modern applications. With contributions by Tom Head. Cambridge: Cambridge University Press. ISBN 978-0-521-61324-8. Zbl 1127.68049. Conway, J.H. (1971). Regular algebra and finite machines. Chapman and Hall Mathematics Series. London: Chapman & Hall. Zbl 0231.94041. John M. Howie (1991) Automata and Languages, Clarendon Press ISBN 0-19-853424-8 MR1254435 Sakarovitch, Jacques (2009). Elements of automata theory. Translated from the French by Reuben Thomas. Cambridge University Press. ISBN 978-0-521-84425-3. Zbl 1188.68177. James P. Schmeiser; David T. Barnard (1995). Producing a top-down parse order with bottom-up parsing. Elsevier North-Holland. Igor Aleksander; F. Keith Hanna (1975). Automata Theory: An Engineering Approach. New York: Crane Russak. ISBN 978-0-8448-0657-0. Marvin Minsky (1967). Computation: Finite and infinite machines. Princeton, N.J.: Prentice Hall. John C. Martin (2011). Introduction to Languages and The Theory of Computation. New York: McGraw Hill. ISBN 978-0-07-319146-1. == External links == dk.brics.automaton libfa
Wikipedia/Automata_theory
Application security (short AppSec) includes all tasks that introduce a secure software development life cycle to development teams. Its final goal is to improve security practices and, through that, to find, fix and preferably prevent security issues within applications. It encompasses the whole application life cycle from requirements analysis, design, implementation, verification as well as maintenance. Web application security is a branch of information security that deals specifically with the security of websites, web applications, and web services. At a high level, web application security draws on the principles of application security but applies them specifically to the internet and web systems. The application security also concentrates on mobile apps and their security which includes iOS and Android Applications Web Application Security Tools are specialized tools for working with HTTP traffic, e.g., Web application firewalls. == Approaches == Different approaches will find different subsets of the security vulnerabilities lurking in an application and are most effective at different times in the software lifecycle. They each represent different tradeoffs of time, effort, cost and vulnerabilities found. Design review. Before code is written the application's architecture and design can be reviewed for security problems. A common technique in this phase is the creation of a threat model. Whitebox security review, or code review. This is a security engineer deeply understanding the application through manually reviewing the source code and noticing security flaws. Through comprehension of the application, vulnerabilities unique to the application can be found. Blackbox security audit. This is only through the use of an application testing it for security vulnerabilities, no source code is required. Automated Tooling. Many security tools can be automated through inclusion into the development or testing environment. Examples of those are automated DAST/SAST tools that are integrated into code editor or CI/CD platforms. Coordinated vulnerability platforms. These are hacker-powered application security solutions offered by many websites and software developers by which individuals can receive recognition and compensation for reporting bugs. == Security threats == The Open Worldwide Application Security Project (OWASP) provides free and open resources. It is led by a non-profit called The OWASP Foundation. The OWASP Top 10 - 2017 results from recent research based on comprehensive data compiled from over 40 partner organizations. This data revealed approximately 2.3 million vulnerabilities across over 50,000 applications. According to the OWASP Top 10 - 2021, the ten most critical web application security risks include: Broken access control Cryptographic failures Injection Insecure design Security misconfiguration Vulnerable and outdated components Identification and authentification failures Software and data integrity failures Security logging and monitoring failures* Server-side request forgery (SSRF)* == Security controls == The OWASP Top 10 Proactive Controls 2024 is a list of security techniques every software architect and developer should know and heed. The current list contains: Implement access control Use cryptography the proper way Validate all input & handle exceptions Address security from the start Secure by default configurations Keep your components secure Implement digital identity Use browser security features Implement security logging and monitoring Stop server-side request forgery == Tooling for security testing == Security testing techniques scour for vulnerabilities or security holes in applications. These vulnerabilities leave applications open to exploitation. Ideally, security testing is implemented throughout the entire software development life cycle (SDLC) so that vulnerabilities may be addressed in a timely and thorough manner. There are many kinds of automated tools for identifying vulnerabilities in applications. Common tool categories used for identifying application vulnerabilities include: Static application security testing (SAST) analyzes source code for security vulnerabilities during an application's development. Compared to DAST, SAST can be utilized even before the application is in an executable state. As SAST has access to the full source code it is a white-box approach. This can yield more detailed results but can result in many false positives that need to be manually verified. Dynamic application security testing (DAST, often called vulnerability scanners) automatically detects vulnerabilities by crawling and analyzing websites. This method is highly scalable, easily integrated and quick. DAST tools are well suited for dealing with low-level attacks such as injection flaws but are not well suited to detect high-level flaws, e.g., logic or business logic flaws. Fuzzing tools are commonly used for input testing. Interactive application security testing (IAST) assesses applications from within using software instrumentation. This combines the strengths of both SAST and DAST methods as well as providing access to code, HTTP traffic, library information, backend connections and configuration information. Some IAST products require the application to be attacked, while others can be used during normal quality assurance testing. Runtime application self-protection augments existing applications to provide intrusion detection and prevention from within an application runtime. Dependency scanners (also called software composition analysis) try to detect the usage of software components with known vulnerabilities. These tools can either work on-demand, e.g., during the source code build process, or periodically. == Security standards and regulations == CERT Secure Coding standard ISO/IEC 27034-1:2011 Information technology — Security techniques — Application security -- Part 1: Overview and concepts ISO/IEC TR 24772:2013 Information technology — Programming languages — Guidance to avoiding vulnerabilities in programming languages through language selection and use NIST Special Publication 800-53 OWASP ASVS: Web Application Security Verification Standard == See also == Common Weakness Enumeration Data security Mobile security OWASP Microsoft Security Development Lifecycle Usable security == References ==
Wikipedia/Application_security
A modeling language is any artificial language that can be used to express data, information or knowledge or systems in a structure that is defined by a consistent set of rules. The rules are used for interpretation of the meaning of components in the structure of a programming language. == Overview == A modeling language can be graphical or textual. Graphical modeling languages use a diagram technique with named symbols that represent concepts and lines that connect the symbols and represent relationships and various other graphical notation to represent constraints. Textual modeling languages may use standardized keywords accompanied by parameters or natural language terms and phrases to make computer-interpretable expressions. An example of a graphical modeling language and a corresponding textual modeling language is EXPRESS. Not all modeling languages are executable, and for those that are, the use of them doesn't necessarily mean that programmers are no longer required. On the contrary, executable modeling languages are intended to amplify the productivity of skilled programmers, so that they can address more challenging problems, such as parallel computing and distributed systems. A large number of modeling languages appear in the literature. == Type of modeling languages == === Graphical types === Example of graphical modeling languages in the field of computer science, project management and systems engineering: Behavior Trees are a formal, graphical modeling language used primarily in systems and software engineering. Commonly used to unambiguously represent the hundreds or even thousands of natural language requirements that are typically used to express the stakeholder needs for a large-scale software-integrated system. Business Process Modeling Notation (BPMN, and the XML form BPML) is an example of a Process Modeling language. C-K theory consists of a modeling language for design processes. DRAKON is a general-purpose algorithmic modeling language for specifying software-intensive systems, a schematic representation of an algorithm or a stepwise process, and a family of programming languages. EXPRESS and EXPRESS-G (ISO 10303-11) is an international standard general-purpose data modeling language. Extended Enterprise Modeling Language (EEML) is commonly used for business process modeling across a number of layers. Flowchart is a schematic representation of an algorithm or a stepwise process. Fundamental Modeling Concepts (FMC) modeling language for software-intensive systems. IDEF is a family of modeling languages, which include IDEF0 for functional modeling, IDEF1X for information modeling, IDEF3 for business process modeling, IDEF4 for Object-Oriented Design and IDEF5 for modeling ontologies. Jackson Structured Programming (JSP) is a method for structured programming based on correspondences between data stream structure and program structure. LePUS3 is an object-oriented visual Design Description Language and a formal specification language that is suitable primarily for modeling large object-oriented (Java, C++, C#) programs and design patterns. Lifecycle Modeling Language is an open-standard language for systems engineering that supports the full system lifecycle: conceptual, utilization, support and retirement stages. Object-Role Modeling (ORM) in the field of software engineering is a method for conceptual modeling, and can be used as a tool for information and rules analysis. Petri nets use variations on exactly one diagramming technique and topology, namely the bipartite graph. The simplicity of its basic user interface easily enabled extensive tool support over the years, particularly in the areas of model checking, graphically oriented simulation, and software verification. Southbeach Notation is a visual modeling language used to describe situations in terms of agents that are considered useful or harmful from the modeler's perspective. The notation shows how the agents interact with each other and whether this interaction improves or worsens the situation. Specification and Description Language (SDL) is a specification language targeted at the unambiguous specification and description of the behavior of reactive and distributed systems. SysML is a Domain-Specific Modeling language for systems engineering that is defined as a UML profile (customization). Unified Modeling Language (UML) is a general-purpose modeling language that is an industry standard for specifying software-intensive systems. UML 2.0, the current version, supports thirteen different diagram techniques, and has widespread tool support. FLINT — language which allows a high-level description of normative systems. Service-oriented modeling framework (SOMF) is a holistic language for designing enterprise and application level architecture models in the space of enterprise architecture, virtualization, service-oriented architecture (SOA), cloud computing, and more. Architecture description language (ADL) is a language used to describe and represent the systems architecture of a system. Architecture Analysis & Design Language (AADL) is a modeling language that supports early and repeated analyses of a system's architecture with respect to performance-critical properties through an extendable notation, a tool framework, and precisely defined semantics. Examples of graphical modeling languages in other fields of science. EAST-ADL is a Domain-Specific Modeling language dedicated to automotive system design. Energy Systems Language (ESL), a language that aims to model ecological energetics & global economics. IEC 61499 defines Domain-Specific Modeling language dedicated to distribute industrial process measurement and control systems. === Textual types === Information models can also be expressed in formalized natural languages, such as Gellish. Gellish has natural language variants such as Gellish Formal English and Gellish Formal Dutch (Gellish Formeel Nederlands), etc. Gellish Formal English is an information representation language or semantic modeling language that is defined in the Gellish English Dictionary-Taxonomy, which has the form of a Taxonomy-Ontology (similarly for Dutch). Gellish Formal English is not only suitable to express knowledge, requirements and dictionaries, taxonomies and ontologies, but also information about individual things. All that information is expressed in one language and therefore it can all be integrated, independent of the question whether it is stored in central or distributed or in federated databases. Information models in Gellish Formal English consists of collections of Gellish Formal English expressions, that use natural language terms and formalized phrases. For example, a geographic information model might consist of a number of Gellish Formal English expressions, such as: - the Eiffel tower <is located in> Paris - Paris <is classified as a> city whereas information requirements and knowledge can be expressed for example as follows: - tower <shall be located in a> geographical area - city <is a kind of> geographical area Such Gellish Formal English expressions use names of concepts (such as "city") and phrases that represent relation types (such as ⟨is located in⟩ and ⟨is classified as a⟩) that should be selected from the Gellish English Dictionary-Taxonomy (or of your own domain dictionary). The Gellish English Dictionary-Taxonomy enables the creation of semantically rich information models, because the dictionary contains more than 600 standard relation types and contains definitions of more than 40000 concepts. An information model in Gellish can express facts or make statements, queries and answers. === More specific types === In the field of computer science recently more specific types of modeling languages have emerged. ==== Algebraic ==== Algebraic Modeling Languages (AML) are high-level programming languages for describing and solving high complexity problems for large scale mathematical computation (i.e. large scale optimization type problems). One particular advantage of AMLs like AIMMS, AMPL, GAMS, Gekko, Mosel, OPL, MiniZinc, and OptimJ is the similarity of its syntax to the mathematical notation of optimization problems. This allows for a very concise and readable definition of problems in the domain of optimization, which is supported by certain language elements like sets, indices, algebraic expressions, powerful sparse index and data handling variables, constraints with arbitrary names. The algebraic formulation of a model does not contain any hints how to process it. ==== Behavioral ==== Behavioral languages are designed to describe the observable behavior of complex systems consisting of components that execute concurrently. These languages focus on the description of key concepts such as: concurrency, nondeterminism, synchronization, and communication. The semantic foundations of Behavioral languages are process calculus or process algebra. ==== Discipline-specific ==== A discipline-specific modeling (DspM) language is focused on deliverables affiliated with a specific software development life cycle stage. Therefore, such language offers a distinct vocabulary, syntax, and notation for each stage, such as discovery, analysis, design, architecture, contraction, etc. For example, for the analysis phase of a project, the modeler employs specific analysis notation to deliver an analysis proposition diagram. During the design phase, however, logical design notation is used to depict the relationship between software entities. In addition, the discipline-specific modeling language best practices does not preclude practitioners from combining the various notations in a single diagram. ==== Domain-specific ==== Domain-specific modeling (DSM) is a software engineering methodology for designing and developing systems, most often IT systems such as computer software. It involves the systematic use of a graphical domain-specific language (DSL) to represent the various facets of a system. DSM languages tend to support higher-level abstractions than General-purpose modeling languages, so they require less effort and fewer low-level details to specify a given system. ==== Framework-specific ==== A framework-specific modeling language (FSML) is a kind of domain-specific modeling language which is designed for an object-oriented application framework. FSMLs define framework-provided abstractions as FSML concepts and decompose the abstractions into features. The features represent implementation steps or choices. A FSML concept can be configured by selecting features and providing values for features. Such a concept configuration represents how the concept should be implemented in the code. In other words, concept configuration describes how the framework should be completed in order to create the implementation of the concept. ==== Information and knowledge modeling ==== Linked data and ontology engineering require 'host languages' to represent entities and the relations between them, constraints between the properties of entities and relations, and metadata attributes. JSON-LD and RDF are two major (and semantically almost equivalent) languages in this context, primarily because they support statement reification and contextualisation which are essential properties to support the higher-order logic needed to reason about models. Model transformation is a common example of such reasoning. ==== Object-oriented ==== Object modeling languages are modeling languages based on a standardized set of symbols and ways of arranging them to model (part of) an object oriented software design or system design. Some organizations use them extensively in combination with a software development methodology to progress from initial specification to an implementation plan and to communicate that plan to an entire team of developers and stakeholders. Because a modeling language is visual and at a higher-level of abstraction than code, using models encourages the generation of a shared vision that may prevent problems of differing interpretation later in development. Often software modeling tools are used to construct these models, which may then be capable of automatic translation to code. ==== Virtual reality ==== Virtual Reality Modeling Language (VRML), before 1995 known as the Virtual Reality Markup Language is a standard file format for representing 3-dimensional (3D) interactive vector graphics, designed particularly with the World Wide Web in mind. ==== Others ==== Architecture Description Language Face Modeling Language Generative Modelling Language Java Modeling Language Promela Rebeca Modeling Language Service Modeling Language Web Services Modeling Language X3D == Applications == Various kinds of modeling languages are applied in different disciplines, including computer science, information management, business process modeling, software engineering, and systems engineering. Modeling languages can be used to specify: system requirements, structures and behaviors. Modeling languages are intended to be used to precisely specify systems so that stakeholders (e.g., customers, operators, analysts, designers) can better understand the system being modeled. The more mature modeling languages are precise, consistent and executable. Informal diagramming techniques applied with drawing tools are expected to produce useful pictorial representations of system requirements, structures and behaviors, which can be useful for communication, design, and problem solving but cannot be used programmatically.: 539  Executable modeling languages applied with proper tool support, however, are expected to automate system verification and validation, simulation and code generation from the same representations. == Quality == A review of modelling languages is essential to be able to assign which languages are appropriate for different modelling settings. In the term settings we include stakeholders, domain and the knowledge connected. Assessing the language quality is a means that aims to achieve better models. === Framework for evaluation === Here language quality is stated in accordance with the SEQUAL framework for quality of models developed by Krogstie, Sindre and Lindland (2003), since this is a framework that connects the language quality to a framework for general model quality. Five areas are used in this framework to describe language quality and these are supposed to express both the conceptual as well as the visual notation of the language. We will not go into a thorough explanation of the underlying quality framework of models but concentrate on the areas used to explain the language quality framework. ==== Domain appropriateness ==== The framework states the ability to represent the domain as domain appropriateness. The statement appropriateness can be a bit vague, but in this particular context it means able to express. You should ideally only be able to express things that are in the domain but be powerful enough to include everything that is in the domain. This requirement might seem a bit strict, but the aim is to get a visually expressed model which includes everything relevant to the domain and excludes everything not appropriate for the domain. To achieve this, the language has to have a good distinction of which notations and syntaxes that are advantageous to present. ==== Participant appropriateness ==== To evaluate the participant appropriateness we try to identify how well the language expresses the knowledge held by the stakeholders. This involves challenges since a stakeholder's knowledge is subjective. The knowledge of the stakeholder is both tacit and explicit. Both types of knowledge are of dynamic character. In this framework only the explicit type of knowledge is taken into account. The language should to a large extent express all the explicit knowledge of the stakeholders relevant to the domain. ==== Modeller appropriateness ==== Last paragraph stated that knowledge of the stakeholders should be presented in a good way. In addition it is imperative that the language should be able to express all possible explicit knowledge of the stakeholders. No knowledge should be left unexpressed due to lacks in the language. ==== Comprehensibility appropriateness ==== Comprehensibility appropriateness makes sure that the social actors understand the model due to a consistent use of the language. To achieve this the framework includes a set of criteria. The general importance that these express is that the language should be flexible, easy to organize and easy to distinguish different parts of the language internally as well as from other languages. In addition to this, the goal should be as simple as possible and that each symbol in the language has a unique representation. This is in connection to also to the structure of the development requirements. . ==== Tool appropriateness ==== To ensure that the domain actually modelled is usable for analyzing and further processing, the language has to ensure that it is possible to reason in an automatic way. To achieve this it has to include formal syntax and semantics. Another advantage by formalizing is the ability to discover errors in an early stage. It is not always that the language best fitted for the technical actors is the same as for the social actors. ==== Organizational appropriateness ==== The language used is appropriate for the organizational context, e.g. that the language is standardized within the organization, or that it is supported by tools that are chosen as standard in the organization. == See also == == References == == Further reading == John Krogstie (2003) "Evaluating UML using a generic quality framework" . SINTEF Telecom and Informatics and IDI, NTNU, Norway Krogstie and Sølvsberg (2003). Information Systems Engineering: Conceptual Modeling in a Quality Perspective. Institute of computer and information sciences.\ Anna Gunhild Nysetvold and John Krogstie (2005). "Assessing business processing modeling languages using a generic quality framework". Institute of computer and information sciences. == External links == Fundamental Modeling Concepts Software Modeling Languages Portal BIP -- Incremental Component-based Construction of Real-time Systems Gellish Formal English
Wikipedia/Modeling_language
Programming language theory (PLT) is a branch of computer science that deals with the design, implementation, analysis, characterization, and classification of formal languages known as programming languages. Programming language theory is closely related to other fields including linguistics, mathematics, and software engineering. == History == In some ways, the history of programming language theory predates even the development of programming languages. The lambda calculus, developed by Alonzo Church and Stephen Cole Kleene in the 1930s, is considered by some to be the world's first programming language, even though it was intended to model computation rather than being a means for programmers to describe algorithms to a computer system. Many modern functional programming languages have been described as providing a "thin veneer" over the lambda calculus, and many are described easily in terms of it. The first programming language to be invented was Plankalkül, which was designed by Konrad Zuse in the 1940s, but not publicly known until 1972, and not implemented until 1998. The first widely known and successful high-level programming language was FORTRAN (for Formula Translation), developed from 1954 to 1957 by a team of IBM researchers led by John Backus. The success of FORTRAN led to the formation of a committee of scientists to develop a "universal" computer language; the result of their effort was ALGOL 58. Separately, John McCarthy of Massachusetts Institute of Technology (MIT) developed Lisp, the first language with origins in academia to be successful. With the success of these initial efforts, programming languages became an active topic of research in the 1960s and beyond. === Timeline === Some other key events in the history of programming language theory since then: 1950s Noam Chomsky developed the Chomsky hierarchy in the field of linguistics, a discovery which has directly impacted programming language theory and other branches of computer science. 1960s In 1962, the Simula language was developed by Ole-Johan Dahl and Kristen Nygaard; it is widely considered to be the first example of an object-oriented programming language; Simula also introduced the concept of coroutines. In 1964, Peter Landin is the first to realize Church's lambda calculus can be used to model programming languages. He introduces the SECD machine which "interprets" lambda expressions. In 1965, Landin introduces the J operator, essentially a form of continuation. In 1966, Landin introduces ISWIM, an abstract computer programming language in his article The Next 700 Programming Languages. It is influential in the design of languages leading to the Haskell language. In 1966, Corrado Böhm introduced the language CUCH (Curry-Church). In 1967, Christopher Strachey publishes his influential set of lecture notes Fundamental Concepts in Programming Languages, introducing the terminology R-values, L-values, parametric polymorphism, and ad hoc polymorphism. In 1969, J. Roger Hindley publishes The Principal Type-Scheme of an Object in Combinatory Logic, later generalized into the Hindley–Milner type inference algorithm. In 1969, Tony Hoare introduces the Hoare logic, a form of axiomatic semantics. In 1969, William Alvin Howard observed that a "high-level" proof system, referred to as natural deduction, can be directly interpreted in its intuitionistic version as a typed variant of the model of computation known as lambda calculus. This became known as the Curry–Howard correspondence. 1970s In 1970, Dana Scott first publishes his work on denotational semantics. In 1972, logic programming and Prolog were developed thus allowing computer programs to be expressed as mathematical logic. A team of scientists at Xerox PARC led by Alan Kay develop Smalltalk, an object-oriented language widely known for its innovative development environment. In 1974, John C. Reynolds discovers System F. It had already been discovered in 1971 by the mathematical logician Jean-Yves Girard. From 1975, Gerald Jay Sussman and Guy Steele develop the Scheme language, a Lisp dialect incorporating lexical scoping, a unified namespace, and elements from the actor model including first-class continuations. Backus, at the 1977 Turing Award lecture, assailed the current state of industrial languages and proposed a new class of programming languages now known as function-level programming languages. In 1977, Gordon Plotkin introduces Programming Computable Functions, an abstract typed functional language. In 1978, Robin Milner introduces the Hindley–Milner type system inference algorithm for ML language. Type theory became applied as a discipline to programming languages, this application has led to great advances in type theory over the years. 1980s In 1981, Gordon Plotkin publishes his paper on structured operational semantics. In 1988, Gilles Kahn published his paper on natural semantics. There emerged process calculi, such as the Calculus of Communicating Systems of Robin Milner, and the Communicating sequential processes model of C. A. R. Hoare, as well as similar models of concurrency such as the actor model of Carl Hewitt. In 1985, the release of Miranda sparks an academic interest in lazy-evaluated purely functional programming languages. A committee was formed to define an open standard resulting in the release of the Haskell 1.0 standard in 1990. Bertrand Meyer created the methodology design by contract and incorporated it into the Eiffel language. 1990s Gregor Kiczales, Jim Des Rivieres and Daniel G. Bobrow published the book The Art of the Metaobject Protocol. Eugenio Moggi and Philip Wadler introduced the use of monads for structuring programs written in functional programming languages. == Sub-disciplines and related fields == There are several fields of study that either lie within programming language theory, or which have a profound influence on it; many of these have considerable overlap. In addition, PLT makes use of many other branches of mathematics, including computability theory, category theory, and set theory. === Formal semantics === Formal semantics is the formal specification of the behaviour of computer programs and programming languages. Three common approaches to describe the semantics or "meaning" of a computer program are denotational semantics, operational semantics and axiomatic semantics. === Type theory === Type theory is the study of type systems; which are "a tractable syntactic method for proving the absence of certain program behaviors by classifying phrases according to the kinds of values they compute". Many programming languages are distinguished by the characteristics of their type systems. === Program analysis and transformation === Program analysis is the general problem of examining a program and determining key characteristics (such as the absence of classes of program errors). Program transformation is the process of transforming a program in one form (language) to another form. === Comparative programming language analysis === Comparative programming language analysis seeks to classify languages into different types based on their characteristics; broad categories of languages are often known as programming paradigms. === Generic and metaprogramming === Metaprogramming is the generation of higher-order programs which, when executed, produce programs (possibly in a different language, or in a subset of the original language) as a result. === Domain-specific languages === Domain-specific languages are those constructed to efficiently solve problems in a given domain, or part of such. === Compiler construction === Compiler theory is the theory of writing compilers (or more generally, translators); programs that translate a program written in one language into another form. The actions of a compiler are traditionally broken up into syntax analysis (scanning and parsing), semantic analysis (determining what a program should do), optimization (improving the performance of a program as indicated by some metric; typically execution speed) and code generation (generation and output of an equivalent program in some target language; often the instruction set architecture of a central processing unit (CPU)). === Run-time systems === Run-time systems refer to the development of programming language runtime environments and their components, including virtual machines, garbage collection, and foreign function interfaces. == Journals, publications, and conferences == Conferences are the primary venue for presenting research in programming languages. The most well known conferences include the Symposium on Principles of Programming Languages (POPL), Programming Language Design and Implementation (PLDI), the International Conference on Functional Programming (ICFP), the international conference on Object-Oriented Programming, Systems, Languages & Applications (OOPSLA) and the International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS). Notable journals that publish PLT research include the ACM Transactions on Programming Languages and Systems (TOPLAS), Journal of Functional Programming (JFP), Journal of Functional and Logic Programming, and Higher-Order and Symbolic Computation. == See also == SIGPLAN Very high-level programming language == References == == Further reading == Abadi, Martín and Cardelli, Luca. A Theory of Objects. Springer-Verlag. Michael J. C. Gordon. Programming Language Theory and Its Implementation. Prentice Hall. Gunter, Carl and Mitchell, John C. (eds.). Theoretical Aspects of Object Oriented Programming Languages: Types, Semantics, and Language Design. MIT Press. Harper, Robert. Practical Foundations for Programming Languages. Draft version. Knuth, Donald E. (2003). Selected Papers on Computer Languages. Stanford, California: Center for the Study of Language and Information. Mitchell, John C. Foundations for Programming Languages. Mitchell, John C. Introduction to Programming Language Theory. O'Hearn, Peter. W. and Tennent, Robert. D. (1997). ALGOL-like Languages. Progress in Theoretical Computer Science. Birkhauser, Boston. Pierce, Benjamin C. (2002). Types and Programming Languages. MIT Press. Pierce, Benjamin C. Advanced Topics in Types and Programming Languages. Pierce, Benjamin C. et al. (2010). Software Foundations. == External links == Lambda the Ultimate, a community weblog for professional discussion and repository of documents on programming language theory. Great Works in Programming Languages. Collected by Benjamin C. Pierce (University of Pennsylvania). Classic Papers in Programming Languages and Logic. Collected by Karl Crary (Carnegie Mellon University). Programming Language Research. Directory by Mark Leone. λ-Calculus: Then & Now by Dana S. Scott for the ACM Turing Centenary Celebration Grand Challenges in Programming Languages. Panel session at POPL 2009.
Wikipedia/Programming_language_theory
In computer programming, an anonymous function (function literal, expression or block) is a function definition that is not bound to an identifier. Anonymous functions are often arguments being passed to higher-order functions or used for constructing the result of a higher-order function that needs to return a function. If the function is only used once, or a limited number of times, an anonymous function may be syntactically lighter than using a named function. Anonymous functions are ubiquitous in functional programming languages and other languages with first-class functions, where they fulfil the same role for the function type as literals do for other data types. Anonymous functions originate in the work of Alonzo Church in his invention of the lambda calculus, in which all functions are anonymous, in 1936, before electronic computers. In several programming languages, anonymous functions are introduced using the keyword lambda, and anonymous functions are often referred to as lambdas or lambda abstractions. Anonymous functions have been a feature of programming languages since Lisp in 1958, and a growing number of modern programming languages support anonymous functions. == Names == The names "lambda abstraction", "lambda function", and "lambda expression" refer to the notation of function abstraction in lambda calculus, where the usual function f(x) = M would be written (λx.M), and where M is an expression that uses x. Compare to the Python syntax of lambda x: M. The name "arrow function" refers to the mathematical "maps to" symbol, x ↦ M. Compare to the JavaScript syntax of x => M. == Uses == Anonymous functions can be used for containing functionality that need not be named and possibly for short-term use. Some notable examples include closures and currying. The use of anonymous functions is a matter of style. Using them is never the only way to solve a problem; each anonymous function could instead be defined as a named function and called by name. Anonymous functions often provide a briefer notation than defining named functions. In languages that do not permit the definition of named functions in local scopes, anonymous functions may provide encapsulation via localized scope, however the code in the body of such anonymous function may not be re-usable, or amenable to separate testing. Short/simple anonymous functions used in expressions may be easier to read and understand than separately defined named functions, though without a descriptive name they may be more difficult to understand. In some programming languages, anonymous functions are commonly implemented for very specific purposes such as binding events to callbacks or instantiating the function for particular values, which may be more efficient in a Dynamic programming language, more readable, and less error-prone than calling a named function. The following examples are written in Python 3. === Sorting === When attempting to sort in a non-standard way, it may be easier to contain the sorting logic as an anonymous function instead of creating a named function. Most languages provide a generic sort function that implements a sort algorithm that will sort arbitrary objects. This function usually accepts an arbitrary function that determines how to compare whether two elements are equal or if one is greater or less than the other. Consider this Python code sorting a list of strings by length of the string: The anonymous function in this example is the lambda expression: The anonymous function accepts one argument, x, and returns the length of its argument, which is then used by the sort() method as the criteria for sorting. Basic syntax of a lambda function in Python is The expression returned by the lambda function can be assigned to a variable and used in the code at multiple places. Another example would be sorting items in a list by the name of their class (in Python, everything has a class): Note that 11.2 has class name "float", 10 has class name "int", and 'number' has class name "str". The sorted order is "float", "int", then "str". === Closures === Closures are functions evaluated in an environment containing bound variables. The following example binds the variable "threshold" in an anonymous function that compares the input to the threshold. This can be used as a sort of generator of comparison functions: It would be impractical to create a function for every possible comparison function and may be too inconvenient to keep the threshold around for further use. Regardless of the reason why a closure is used, the anonymous function is the entity that contains the functionality that does the comparing. === Currying === Currying is the process of changing a function so that rather than taking multiple inputs, it takes a single input and returns a function which accepts the second input, and so forth. In this example, a function that performs division by any integer is transformed into one that performs division by a set integer. While the use of anonymous functions is perhaps not common with currying, it still can be used. In the above example, the function divisor generates functions with a specified divisor. The functions half and third curry the divide function with a fixed divisor. The divisor function also forms a closure by binding the variable d. === Higher-order functions === A higher-order function is a function that takes a function as an argument or returns one as a result. This is commonly used to customize the behavior of a generically defined function, often a looping construct or recursion scheme. Anonymous functions are a convenient way to specify such function arguments. The following examples are in Python 3. ==== Map ==== The map function performs a function call on each element of a list. The following example squares every element in an array with an anonymous function. The anonymous function accepts an argument and multiplies it by itself (squares it). The above form is discouraged by the creators of the language, who maintain that the form presented below has the same meaning and is more aligned with the philosophy of the language: ==== Filter ==== The filter function returns all elements from a list that evaluate True when passed to a certain function. The anonymous function checks if the argument passed to it is even. The same as with map, the form below is considered more appropriate: ==== Fold ==== A fold function runs over all elements in a structure (for lists usually left-to-right, a "left fold", called reduce in Python), accumulating a value as it goes. This can be used to combine all elements of a structure into one value, for example: This performs ( ( ( 1 × 2 ) × 3 ) × 4 ) × 5 = 120. {\displaystyle \left(\left(\left(1\times 2\right)\times 3\right)\times 4\right)\times 5=120.} The anonymous function here is the multiplication of the two arguments. The result of a fold need not be one value. Instead, both map and filter can be created using fold. In map, the value that is accumulated is a new list, containing the results of applying a function to each element of the original list. In filter, the value that is accumulated is a new list containing only those elements that match the given condition. == List of languages == The following is a list of programming languages that support unnamed anonymous functions fully, or partly as some variant, or not at all. This table shows some general trends. First, the languages that do not support anonymous functions (C, Pascal, Object Pascal) are all statically typed languages. However, statically typed languages can support anonymous functions. For example, the ML languages are statically typed and fundamentally include anonymous functions, and Delphi, a dialect of Object Pascal, has been extended to support anonymous functions, as has C++ (by the C++11 standard). Second, the languages that treat functions as first-class functions (Dylan, Haskell, JavaScript, Lisp, ML, Perl, Python, Ruby, Scheme) generally have anonymous function support so that functions can be defined and passed around as easily as other data types. == Examples of anonymous functions == == See also == First-class function Lambda calculus definition == References == == External links == Anonymous Methods - When Should They Be Used? (blog about anonymous function in Delphi) Compiling Lambda Expressions: Scala vs. Java 8 php anonymous functions php anonymous functions Lambda functions in various programming languages Functions in Go
Wikipedia/Anonymous_function
In mathematics and computer science, an algorithm ( ) is a finite sequence of mathematically rigorous instructions, typically used to solve a class of specific problems or to perform a computation. Algorithms are used as specifications for performing calculations and data processing. More advanced algorithms can use conditionals to divert the code execution through various routes (referred to as automated decision-making) and deduce valid inferences (referred to as automated reasoning). In contrast, a heuristic is an approach to solving problems without well-defined correct or optimal results. For example, although social media recommender systems are commonly called "algorithms", they actually rely on heuristics as there is no truly "correct" recommendation. As an effective method, an algorithm can be expressed within a finite amount of space and time and in a well-defined formal language for calculating a function. Starting from an initial state and initial input (perhaps empty), the instructions describe a computation that, when executed, proceeds through a finite number of well-defined successive states, eventually producing "output" and terminating at a final ending state. The transition from one state to the next is not necessarily deterministic; some algorithms, known as randomized algorithms, incorporate random input. == Etymology == Around 825 AD, Persian scientist and polymath Muḥammad ibn Mūsā al-Khwārizmī wrote kitāb al-ḥisāb al-hindī ("Book of Indian computation") and kitab al-jam' wa'l-tafriq al-ḥisāb al-hindī ("Addition and subtraction in Indian arithmetic"). In the early 12th century, Latin translations of these texts involving the Hindu–Arabic numeral system and arithmetic appeared, for example Liber Alghoarismi de practica arismetrice, attributed to John of Seville, and Liber Algorismi de numero Indorum, attributed to Adelard of Bath. Here, alghoarismi or algorismi is the Latinization of Al-Khwarizmi's name; the text starts with the phrase Dixit Algorismi, or "Thus spoke Al-Khwarizmi". The word algorism in English came to mean the use of place-value notation in calculations; it occurs in the Ancrene Wisse from circa 1225. By the time Geoffrey Chaucer wrote The Canterbury Tales in the late 14th century, he used a variant of the same word in describing augrym stones, stones used for place-value calculation. In the 15th century, under the influence of the Greek word ἀριθμός (arithmos, "number"; cf. "arithmetic"), the Latin word was altered to algorithmus. By 1596, this form of the word was used in English, as algorithm, by Thomas Hood. == Definition == One informal definition is "a set of rules that precisely defines a sequence of operations", which would include all computer programs (including programs that do not perform numeric calculations), and any prescribed bureaucratic procedure or cook-book recipe. In general, a program is an algorithm only if it stops eventually—even though infinite loops may sometimes prove desirable. Boolos, Jeffrey & 1974, 1999 define an algorithm to be an explicit set of instructions for determining an output, that can be followed by a computing machine or a human who could only carry out specific elementary operations on symbols. Most algorithms are intended to be implemented as computer programs. However, algorithms are also implemented by other means, such as in a biological neural network (for example, the human brain performing arithmetic or an insect looking for food), in an electrical circuit, or a mechanical device. == History == === Ancient algorithms === Step-by-step procedures for solving mathematical problems have been recorded since antiquity. This includes in Babylonian mathematics (around 2500 BC), Egyptian mathematics (around 1550 BC), Indian mathematics (around 800 BC and later), the Ifa Oracle (around 500 BC), Greek mathematics (around 240 BC), Chinese mathematics (around 200 BC and later), and Arabic mathematics (around 800 AD). The earliest evidence of algorithms is found in ancient Mesopotamian mathematics. A Sumerian clay tablet found in Shuruppak near Baghdad and dated to c. 2500 BC describes the earliest division algorithm. During the Hammurabi dynasty c. 1800 – c. 1600 BC, Babylonian clay tablets described algorithms for computing formulas. Algorithms were also used in Babylonian astronomy. Babylonian clay tablets describe and employ algorithmic procedures to compute the time and place of significant astronomical events. Algorithms for arithmetic are also found in ancient Egyptian mathematics, dating back to the Rhind Mathematical Papyrus c. 1550 BC. Algorithms were later used in ancient Hellenistic mathematics. Two examples are the Sieve of Eratosthenes, which was described in the Introduction to Arithmetic by Nicomachus,: Ch 9.2  and the Euclidean algorithm, which was first described in Euclid's Elements (c. 300 BC).: Ch 9.1 Examples of ancient Indian mathematics included the Shulba Sutras, the Kerala School, and the Brāhmasphuṭasiddhānta. The first cryptographic algorithm for deciphering encrypted code was developed by Al-Kindi, a 9th-century Arab mathematician, in A Manuscript On Deciphering Cryptographic Messages. He gave the first description of cryptanalysis by frequency analysis, the earliest codebreaking algorithm. === Computers === ==== Weight-driven clocks ==== Bolter credits the invention of the weight-driven clock as "the key invention [of Europe in the Middle Ages]," specifically the verge escapement mechanism producing the tick and tock of a mechanical clock. "The accurate automatic machine" led immediately to "mechanical automata" in the 13th century and "computational machines"—the difference and analytical engines of Charles Babbage and Ada Lovelace in the mid-19th century. Lovelace designed the first algorithm intended for processing on a computer, Babbage's analytical engine, which is the first device considered a real Turing-complete computer instead of just a calculator. Although the full implementation of Babbage's second device was not realized for decades after her lifetime, Lovelace has been called "history's first programmer". ==== Electromechanical relay ==== Bell and Newell (1971) write that the Jacquard loom, a precursor to Hollerith cards (punch cards), and "telephone switching technologies" led to the development of the first computers. By the mid-19th century, the telegraph, the precursor of the telephone, was in use throughout the world. By the late 19th century, the ticker tape (c. 1870s) was in use, as were Hollerith cards (c. 1890). Then came the teleprinter (c. 1910) with its punched-paper use of Baudot code on tape. Telephone-switching networks of electromechanical relays were invented in 1835. These led to the invention of the digital adding device by George Stibitz in 1937. While working in Bell Laboratories, he observed the "burdensome" use of mechanical calculators with gears. "He went home one evening in 1937 intending to test his idea... When the tinkering was over, Stibitz had constructed a binary adding device". === Formalization === In 1928, a partial formalization of the modern concept of algorithms began with attempts to solve the Entscheidungsproblem (decision problem) posed by David Hilbert. Later formalizations were framed as attempts to define "effective calculability" or "effective method". Those formalizations included the Gödel–Herbrand–Kleene recursive functions of 1930, 1934 and 1935, Alonzo Church's lambda calculus of 1936, Emil Post's Formulation 1 of 1936, and Alan Turing's Turing machines of 1936–37 and 1939. == Representations == Algorithms can be expressed in many kinds of notation, including natural languages, pseudocode, flowcharts, drakon-charts, programming languages or control tables (processed by interpreters). Natural language expressions of algorithms tend to be verbose and ambiguous and are rarely used for complex or technical algorithms. Pseudocode, flowcharts, drakon-charts, and control tables are structured expressions of algorithms that avoid common ambiguities of natural language. Programming languages are primarily for expressing algorithms in a computer-executable form but are also used to define or document algorithms. === Turing machines === There are many possible representations and Turing machine programs can be expressed as a sequence of machine tables (see finite-state machine, state-transition table, and control table for more), as flowcharts and drakon-charts (see state diagram for more), as a form of rudimentary machine code or assembly code called "sets of quadruples", and more. Algorithm representations can also be classified into three accepted levels of Turing machine description: high-level description, implementation description, and formal description. A high-level description describes the qualities of the algorithm itself, ignoring how it is implemented on the Turing machine. An implementation description describes the general manner in which the machine moves its head and stores data to carry out the algorithm, but does not give exact states. In the most detail, a formal description gives the exact state table and list of transitions of the Turing machine. === Flowchart representation === The graphical aid called a flowchart offers a way to describe and document an algorithm (and a computer program corresponding to it). It has four primary symbols: arrows showing program flow, rectangles (SEQUENCE, GOTO), diamonds (IF-THEN-ELSE), and dots (OR-tie). Sub-structures can "nest" in rectangles, but only if a single exit occurs from the superstructure. == Algorithmic analysis == It is often important to know how much time, storage, or other cost an algorithm may require. Methods have been developed for the analysis of algorithms to obtain such quantitative answers (estimates); for example, an algorithm that adds up the elements of a list of n numbers would have a time requirement of ⁠ O ( n ) {\displaystyle O(n)} ⁠, using big O notation. The algorithm only needs to remember two values: the sum of all the elements so far, and its current position in the input list. If the space required to store the input numbers is not counted, it has a space requirement of ⁠ O ( 1 ) {\displaystyle O(1)} ⁠, otherwise ⁠ O ( n ) {\displaystyle O(n)} ⁠ is required. Different algorithms may complete the same task with a different set of instructions in less or more time, space, or 'effort' than others. For example, a binary search algorithm (with cost ⁠ O ( log ⁡ n ) {\displaystyle O(\log n)} ⁠) outperforms a sequential search (cost ⁠ O ( n ) {\displaystyle O(n)} ⁠ ) when used for table lookups on sorted lists or arrays. === Formal versus empirical === The analysis, and study of algorithms is a discipline of computer science. Algorithms are often studied abstractly, without referencing any specific programming language or implementation. Algorithm analysis resembles other mathematical disciplines as it focuses on the algorithm's properties, not implementation. Pseudocode is typical for analysis as it is a simple and general representation. Most algorithms are implemented on particular hardware/software platforms and their algorithmic efficiency is tested using real code. The efficiency of a particular algorithm may be insignificant for many "one-off" problems but it may be critical for algorithms designed for fast interactive, commercial, or long-life scientific usage. Scaling from small n to large n frequently exposes inefficient algorithms that are otherwise benign. Empirical testing is useful for uncovering unexpected interactions that affect performance. Benchmarks may be used to compare before/after potential improvements to an algorithm after program optimization. Empirical tests cannot replace formal analysis, though, and are non-trivial to perform fairly. === Execution efficiency === To illustrate the potential improvements possible even in well-established algorithms, a recent significant innovation, relating to FFT algorithms (used heavily in the field of image processing), can decrease processing time up to 1,000 times for applications like medical imaging. In general, speed improvements depend on special properties of the problem, which are very common in practical applications. Speedups of this magnitude enable computing devices that make extensive use of image processing (like digital cameras and medical equipment) to consume less power. === Best Case and Worst Case === The best case of an algorithm refers to the scenario or input for which the algorithm or data structure takes the least time and resources to complete its tasks. The worst case of an algorithm is the case that causes the algorithm or data structure to consume the maximum period of time and computational resources. == Design == Algorithm design is a method or mathematical process for problem-solving and engineering algorithms. The design of algorithms is part of many solution theories, such as divide-and-conquer or dynamic programming within operation research. Techniques for designing and implementing algorithm designs are also called algorithm design patterns, with examples including the template method pattern and the decorator pattern. One of the most important aspects of algorithm design is resource (run-time, memory usage) efficiency; the big O notation is used to describe e.g., an algorithm's run-time growth as the size of its input increases. === Structured programming === Per the Church–Turing thesis, any algorithm can be computed by any Turing complete model. Turing completeness only requires four instruction types—conditional GOTO, unconditional GOTO, assignment, HALT. However, Kemeny and Kurtz observe that, while "undisciplined" use of unconditional GOTOs and conditional IF-THEN GOTOs can result in "spaghetti code", a programmer can write structured programs using only these instructions; on the other hand "it is also possible, and not too hard, to write badly structured programs in a structured language". Tausworthe augments the three Böhm-Jacopini canonical structures: SEQUENCE, IF-THEN-ELSE, and WHILE-DO, with two more: DO-WHILE and CASE. An additional benefit of a structured program is that it lends itself to proofs of correctness using mathematical induction. == Legal status == By themselves, algorithms are not usually patentable. In the United States, a claim consisting solely of simple manipulations of abstract concepts, numbers, or signals does not constitute "processes" (USPTO 2006), so algorithms are not patentable (as in Gottschalk v. Benson). However practical applications of algorithms are sometimes patentable. For example, in Diamond v. Diehr, the application of a simple feedback algorithm to aid in the curing of synthetic rubber was deemed patentable. The patenting of software is controversial, and there are criticized patents involving algorithms, especially data compression algorithms, such as Unisys's LZW patent. Additionally, some cryptographic algorithms have export restrictions (see export of cryptography). == Classification == === By implementation === Recursion A recursive algorithm invokes itself repeatedly until meeting a termination condition and is a common functional programming method. Iterative algorithms use repetitions such as loops or data structures like stacks to solve problems. Problems may be suited for one implementation or the other. The Tower of Hanoi is a puzzle commonly solved using recursive implementation. Every recursive version has an equivalent (but possibly more or less complex) iterative version, and vice versa. Serial, parallel or distributed Algorithms are usually discussed with the assumption that computers execute one instruction of an algorithm at a time on serial computers. Serial algorithms are designed for these environments, unlike parallel or distributed algorithms. Parallel algorithms take advantage of computer architectures where multiple processors can work on a problem at the same time. Distributed algorithms use multiple machines connected via a computer network. Parallel and distributed algorithms divide the problem into subproblems and collect the results back together. Resource consumption in these algorithms is not only processor cycles on each processor but also the communication overhead between the processors. Some sorting algorithms can be parallelized efficiently, but their communication overhead is expensive. Iterative algorithms are generally parallelizable, but some problems have no parallel algorithms and are called inherently serial problems. Deterministic or non-deterministic Deterministic algorithms solve the problem with exact decisions at every step; whereas non-deterministic algorithms solve problems via guessing. Guesses are typically made more accurate through the use of heuristics. Exact or approximate While many algorithms reach an exact solution, approximation algorithms seek an approximation that is close to the true solution. Such algorithms have practical value for many hard problems. For example, the Knapsack problem, where there is a set of items, and the goal is to pack the knapsack to get the maximum total value. Each item has some weight and some value. The total weight that can be carried is no more than some fixed number X. So, the solution must consider the weights of items as well as their value. Quantum algorithm Quantum algorithms run on a realistic model of quantum computation. The term is usually used for those algorithms that seem inherently quantum or use some essential feature of Quantum computing such as quantum superposition or quantum entanglement. === By design paradigm === Another way of classifying algorithms is by their design methodology or paradigm. Some common paradigms are: Brute-force or exhaustive search Brute force is a problem-solving method of systematically trying every possible option until the optimal solution is found. This approach can be very time-consuming, testing every possible combination of variables. It is often used when other methods are unavailable or too complex. Brute force can solve a variety of problems, including finding the shortest path between two points and cracking passwords. Divide and conquer A divide-and-conquer algorithm repeatedly reduces a problem to one or more smaller instances of itself (usually recursively) until the instances are small enough to solve easily. Merge sorting is an example of divide and conquer, where an unordered list is repeatedly split into smaller lists, which are sorted in the same way and then merged. In a simpler variant of divide and conquer called prune and search or decrease-and-conquer algorithm, which solves one smaller instance of itself, and does not require a merge step. An example of a prune and search algorithm is the binary search algorithm. Search and enumeration Many problems (such as playing chess) can be modelled as problems on graphs. A graph exploration algorithm specifies rules for moving around a graph and is useful for such problems. This category also includes search algorithms, branch and bound enumeration, and backtracking. Randomized algorithm Such algorithms make some choices randomly (or pseudo-randomly). They find approximate solutions when finding exact solutions may be impractical (see heuristic method below). For some problems, the fastest approximations must involve some randomness. Whether randomized algorithms with polynomial time complexity can be the fastest algorithm for some problems is an open question known as the P versus NP problem. There are two large classes of such algorithms: Monte Carlo algorithms return a correct answer with high probability. E.g. RP is the subclass of these that run in polynomial time. Las Vegas algorithms always return the correct answer, but their running time is only probabilistically bound, e.g. ZPP. Reduction of complexity This technique transforms difficult problems into better-known problems solvable with (hopefully) asymptotically optimal algorithms. The goal is to find a reducing algorithm whose complexity is not dominated by the resulting reduced algorithms. For example, one selection algorithm finds the median of an unsorted list by first sorting the list (the expensive portion), and then pulling out the middle element in the sorted list (the cheap portion). This technique is also known as transform and conquer. Back tracking In this approach, multiple solutions are built incrementally and abandoned when it is determined that they cannot lead to a valid full solution. === Optimization problems === For optimization problems there is a more specific classification of algorithms; an algorithm for such problems may fall into one or more of the general categories described above as well as into one of the following: Linear programming When searching for optimal solutions to a linear function bound by linear equality and inequality constraints, the constraints can be used directly to produce optimal solutions. There are algorithms that can solve any problem in this category, such as the popular simplex algorithm. Problems that can be solved with linear programming include the maximum flow problem for directed graphs. If a problem also requires that any of the unknowns be integers, then it is classified in integer programming. A linear programming algorithm can solve such a problem if it can be proved that all restrictions for integer values are superficial, i.e., the solutions satisfy these restrictions anyway. In the general case, a specialized algorithm or an algorithm that finds approximate solutions is used, depending on the difficulty of the problem. Dynamic programming When a problem shows optimal substructures—meaning the optimal solution can be constructed from optimal solutions to subproblems—and overlapping subproblems, meaning the same subproblems are used to solve many different problem instances, a quicker approach called dynamic programming avoids recomputing solutions. For example, Floyd–Warshall algorithm, the shortest path between a start and goal vertex in a weighted graph can be found using the shortest path to the goal from all adjacent vertices. Dynamic programming and memoization go together. Unlike divide and conquer, dynamic programming subproblems often overlap. The difference between dynamic programming and simple recursion is the caching or memoization of recursive calls. When subproblems are independent and do not repeat, memoization does not help; hence dynamic programming is not applicable to all complex problems. Using memoization dynamic programming reduces the complexity of many problems from exponential to polynomial. The greedy method Greedy algorithms, similarly to a dynamic programming, work by examining substructures, in this case not of the problem but of a given solution. Such algorithms start with some solution and improve it by making small modifications. For some problems, they always find the optimal solution but for others they may stop at local optima. The most popular use of greedy algorithms is finding minimal spanning trees of graphs without negative cycles. Huffman Tree, Kruskal, Prim, Sollin are greedy algorithms that can solve this optimization problem. The heuristic method In optimization problems, heuristic algorithms find solutions close to the optimal solution when finding the optimal solution is impractical. These algorithms get closer and closer to the optimal solution as they progress. In principle, if run for an infinite amount of time, they will find the optimal solution. They can ideally find a solution very close to the optimal solution in a relatively short time. These algorithms include local search, tabu search, simulated annealing, and genetic algorithms. Some, like simulated annealing, are non-deterministic algorithms while others, like tabu search, are deterministic. When a bound on the error of the non-optimal solution is known, the algorithm is further categorized as an approximation algorithm. == Examples == One of the simplest algorithms finds the largest number in a list of numbers of random order. Finding the solution requires looking at every number in the list. From this follows a simple algorithm, which can be described in plain English as: High-level description: If a set of numbers is empty, then there is no highest number. Assume the first number in the set is the largest. For each remaining number in the set: if this number is greater than the current largest, it becomes the new largest. When there are no unchecked numbers left in the set, consider the current largest number to be the largest in the set. (Quasi-)formal description: Written in prose but much closer to the high-level language of a computer program, the following is the more formal coding of the algorithm in pseudocode or pidgin code: == See also == == Notes == == Bibliography == Zaslavsky, C. (1970). Mathematics of the Yoruba People and of Their Neighbors in Southern Nigeria. The Two-Year College Mathematics Journal, 1(2), 76–99. https://doi.org/10.2307/3027363 == Further reading == == External links == "Algorithm". Encyclopedia of Mathematics. EMS Press. 2001 [1994]. Weisstein, Eric W. "Algorithm". MathWorld. Dictionary of Algorithms and Data Structures – National Institute of Standards and Technology Algorithm repositories The Stony Brook Algorithm Repository – State University of New York at Stony Brook Collected Algorithms of the ACM – Associations for Computing Machinery The Stanford GraphBase Archived December 6, 2015, at the Wayback Machine – Stanford University
Wikipedia/Algorithm_design
In computer science, and more specifically in computability theory and computational complexity theory, a model of computation is a model which describes how an output of a mathematical function is computed given an input. A model describes how units of computations, memories, and communications are organized. The computational complexity of an algorithm can be measured given a model of computation. Using a model allows studying the performance of algorithms independently of the variations that are specific to particular implementations and specific technology. == Categories == Models of computation can be classified into three categories: sequential models, functional models, and concurrent models. === Sequential models === Sequential models include: Finite-state machines Post machines (Post–Turing machines and tag machines). Pushdown automata Register machines Random-access machines Turing machines Decision tree model External memory model === Functional models === Functional models include: Abstract rewriting systems Combinatory logic General recursive functions Lambda calculus === Concurrent models === Concurrent models include: Actor model Cellular automaton Interaction nets Kahn process networks Logic gates and digital circuits Petri nets Process calculus Synchronous Data Flow Some of these models have both deterministic and nondeterministic variants. Nondeterministic models correspond to limits of certain sequences of finite computers, but do not correspond to any subset of finite computers; they are used in the study of computational complexity of algorithms. Models differ in their expressive power; for example, each function that can be computed by a finite-state machine can also be computed by a Turing machine, but not vice versa. == Uses == In the field of runtime analysis of algorithms, it is common to specify a computational model in terms of primitive operations allowed which have unit cost, or simply unit-cost operations. A commonly used example is the random-access machine, which has unit cost for read and write access to all of its memory cells. In this respect, it differs from the above-mentioned Turing machine model. == See also == Stack machine (0-operand machine) Accumulator machine (1-operand machine) Register machine (2,3,... operand machine) Random-access machine Abstract machine Cell-probe model Robertson–Webb query model Chomsky hierarchy Turing completeness == References == == Further reading == Fernández, Maribel (2009). Models of Computation: An Introduction to Computability Theory. Undergraduate Topics in Computer Science. Springer. ISBN 978-1-84882-433-1. Savage, John E. (1998). Models Of Computation: Exploring the Power of Computing. Addison-Wesley. ISBN 978-0201895391.
Wikipedia/Model_of_computation
A discourse relation (also coherence relation or rhetorical relation) is a description of how two segments of discourse are logically and/or structurally connected to one another. A widely upheld position is that in coherent discourse, every individual utterance is connected by a discourse relation with a context element, e.g., another segment that corresponds to one or more utterances. An alternative view is that discourse relations correspond to the sense (semantic meaning or pragmatic function) of discourse connectives (discourse markers, discourse cues, e.g., conjunctions, certain adverbs), so that every discourse connective elicits at least one discourse relation. Both views converge to some extent in that the same underlying inventory of discourse relations is assumed. There is no general agreement on the exact inventory of discourse relations, but current inventories are specific to theories or frameworks. With ISO/TS 24617-5 (Semantic annotation framework; Part 5: Discourse structure, SemAF-DS), a standard has been proposed, but it is not widely used in existing annotations or by tools. Yet another proposal to derive at a generalized discourse relation inventory is the cognitive approach to coherence relations (CCR), which reduces discourse relations to a combination of five parameters. In addition to a discourse relation inventory, some (but not all) theories postulate structural constraints on discourse relations, and if paratactic (coordinate) or hypotactic (subordinate) relations are distinguished that hold across two or more text spans, coherence in discourse can be modelled as a tree (as in RST, see below) or over a tree (as in SDRT, see below). == Hobbs's coherence relations == In a series of seminal papers, Jerry Hobbs investigated the interplay of discourse relations and coherence since the late 1970s. His work has been the basis for most subsequent theories and annotation frameworks of discourse relations. He proposed the following relations: occasion (change of state) evaluation (why something was said) relations to listener's prior knowledge background (provide background for another utterance) explanation expansion relations (expand the discourse in place) parallel elaboration contrast generalization exemplification violated expectation == Rhetorical Structure Theory (RST) == Introduced in 1987, Rhetorical Structure Theory (RST) uses rhetorical relations as a systematic way for an analyst to annotate a given text. An analysis is usually built by reading the text and constructing a tree using the relations. RST has been designed as a framework for the principled annotation discourse, driven by theoretical considerations, but with an applied perspective. There is some variation among RST relations in different applications and annotated corpora, but the core inventory formulated by Mann and Thompson (1987) is generally considered as the basis. == Segmented Discourse Representation Theory (SDRT) == In its original motivation, SDRT attempts to complement Discourse Representation Theory (DRT) with RST-style discourse relations. Asher and Lascarides (2003) categorize SDRT discourse relations into several classes: Content-level relations Text structuring relations Divergent relations Metatalk relations Metatalk relations include: Consequence*(α,β) Explanation*(α,β) Explanation*q(α,β) Result*(α,β) == Penn Discourse Treebank (PDTB) == In the early days of computational discourse, the study of discourse relations was closely entangled with the study of discourse structure, so that theories such as RST and SDRT effectively postulate tree structures. (SDRT permits relations between independent nodes in a tree, but the tree still defines accessibility domains.) For practical annotation, however, this was felt to be a disadvantage because discourse relations could only be annotated after the global coherence of a particular text has been understood, and annotators disagreed widely (as already observed by Mann and Thompson 1987). For theoretical reasons, the tree model was criticized because at least some types of discourse relations (especially what Hobbs referred to as elaboration) was apparently not constrained by tree structures but could connect elements disconnected in the tree (Knott et al. 2001). This has been the motivation to perform the annotation of discourse relations independently from discourse structure, and this "shallow" model of discourse coherence could be annotated from local context alone. The most prominent of these models has been the Penn Discourse Treebank (PDTB). PDTB is focusing on the annotation of discourse cues (discourse markers, discourse connectives), which are assigned an internal argument (to which the discourse marker is attached), an external argument (target or attachment point of the relation) and a sense (discourse relation). Both arguments are defined as the smallest string that expresses the meaning of the utterances to be connected. Unlike RST and SDRT, PDTB does not postulate any structural constraints on discourse relations, but only defines a limit for the search space for a possible external argument. Starting with PDTB v.2.0, also implicit cues have been annotated, i.e., for utterances without discourse markers, annotators were asked to decide whether and which known discourse cue could be inserted and what its form, arguments and discourse relation would be. In practice, PDTB is widely used for creating discourse resources. In comparison to RST and SDRT, it provides less information. == See also == Speech act Contrast (linguistics) == Notes and references == == Bibliography == Asher, Nicholas and Alex Lascarides (2003). Logics of Conversation. Studies in Natural Language Processing. Cambridge University Press. ISBN 0-521-65058-5 Pitler, Emily and others (2008). "Easily Identifiable Discourse Relations". University of Pennsylvania Department of Computer and Information Science Technical Report No. MS-CIS-08-24. Grosz, Barbara J. and Candice L. Sidner (1986). "Attention, Intentions, and the Structure of Discourse". Computational Linguistics 12: 175–204. [aka DSM] Alistair Knott, 'An Algorithmic Framework for Specifying the Semantics of Discourse Relations', Computational Intelligence 16 (2000). Mann, William C. and Sandra A .Thompson (1988). "Rhetorical Structure Theory: A theory of text organization". Text 8: 243–281. [aka RST] == External links == Rhetorical Structure Theory — RST website, created by William C. Mann, maintained by Maite Taboada
Wikipedia/Segmented_discourse_representation_theory
Solid modeling (or solid modelling) is a consistent set of principles for mathematical and computer modeling of three-dimensional shapes (solids). Solid modeling is distinguished within the broader related areas of geometric modeling and computer graphics, such as 3D modeling, by its emphasis on physical fidelity. Together, the principles of geometric and solid modeling form the foundation of 3D-computer-aided design, and in general, support the creation, exchange, visualization, animation, interrogation, and annotation of digital models of physical objects. == Overview == The use of solid modeling techniques allows for the automation process of several difficult engineering calculations that are carried out as a part of the design process. Simulation, planning, and verification of processes such as machining and assembly were one of the main catalysts for the development of solid modeling. More recently, the range of supported manufacturing applications has been greatly expanded to include sheet metal manufacturing, injection molding, welding, pipe routing, etc. Beyond traditional manufacturing, solid modeling techniques serve as the foundation for rapid prototyping, digital data archival and reverse engineering by reconstructing solids from sampled points on physical objects, mechanical analysis using finite elements, motion planning and NC path verification, kinematic and dynamic analysis of mechanisms, and so on. A central problem in all these applications is the ability to effectively represent and manipulate three-dimensional geometry in a fashion that is consistent with the physical behavior of real artifacts. Solid modeling research and development has effectively addressed many of these issues, and continues to be a central focus of computer-aided engineering. == Mathematical foundations == The notion of solid modeling as practised today relies on the specific need for informational completeness in mechanical geometric modeling systems, in the sense that any computer model should support all geometric queries that may be asked of its corresponding physical object. The requirement implicitly recognizes the possibility of several computer representations of the same physical object as long as any two such representations are consistent. It is impossible to computationally verify informational completeness of a representation unless the notion of a physical object is defined in terms of computable mathematical properties and independent of any particular representation. Such reasoning led to the development of the modeling paradigm that has shaped the field of solid modeling as we know it today. All manufactured components have finite size and well behaved boundaries, so initially the focus was on mathematically modeling rigid parts made of homogeneous isotropic material that could be added or removed. These postulated properties can be translated into properties of regions, subsets of three-dimensional Euclidean space. The two common approaches to define "solidity" rely on point-set topology and algebraic topology respectively. Both models specify how solids can be built from simple pieces or cells. According to the continuum point-set model of solidity, all the points of any X ⊂ R 3 {\displaystyle \mathbb {R} ^{3}} can be classified according to their neighborhoods with respect to X as interior, exterior, or boundary points. Assuming R 3 {\displaystyle \mathbb {R} ^{3}} is endowed with the typical Euclidean metric, a neighborhood of a point p ∈X takes the form of an open ball. For X to be considered solid, every neighborhood of any p ∈X must be consistently three dimensional; points with lower-dimensional neighborhoods indicate a lack of solidity. Dimensional homogeneity of neighborhoods is guaranteed for the class of closed regular sets, defined as sets equal to the closure of their interior. Any X ⊂ R 3 {\displaystyle \mathbb {R} ^{3}} can be turned into a closed regular set or "regularized" by taking the closure of its interior, and thus the modeling space of solids is mathematically defined to be the space of closed regular subsets of R 3 {\displaystyle \mathbb {R} ^{3}} (by the Heine-Borel theorem it is implied that all solids are compact sets). In addition, solids are required to be closed under the Boolean operations of set union, intersection, and difference (to guarantee solidity after material addition and removal). Applying the standard Boolean operations to closed regular sets may not produce a closed regular set, but this problem can be solved by regularizing the result of applying the standard Boolean operations. The regularized set operations are denoted ∪∗, ∩∗, and −∗. The combinatorial characterization of a set X ⊂ R 3 {\displaystyle \mathbb {R} ^{3}} as a solid involves representing X as an orientable cell complex so that the cells provide finite spatial addresses for points in an otherwise innumerable continuum. The class of semi-analytic bounded subsets of Euclidean space is closed under Boolean operations (standard and regularized) and exhibits the additional property that every semi-analytic set can be stratified into a collection of disjoint cells of dimensions 0,1,2,3. A triangulation of a semi-analytic set into a collection of points, line segments, triangular faces, and tetrahedral elements is an example of a stratification that is commonly used. The combinatorial model of solidity is then summarized by saying that in addition to being semi-analytic bounded subsets, solids are three-dimensional topological polyhedra, specifically three-dimensional orientable manifolds with boundary. In particular this implies the Euler characteristic of the combinatorial boundary of the polyhedron is 2. The combinatorial manifold model of solidity also guarantees the boundary of a solid separates space into exactly two components as a consequence of the Jordan-Brouwer theorem, thus eliminating sets with non-manifold neighborhoods that are deemed impossible to manufacture. The point-set and combinatorial models of solids are entirely consistent with each other, can be used interchangeably, relying on continuum or combinatorial properties as needed, and can be extended to n dimensions. The key property that facilitates this consistency is that the class of closed regular subsets of R n {\displaystyle \mathbb {R} ^{n}} coincides precisely with homogeneously n-dimensional topological polyhedra. Therefore, every n-dimensional solid may be unambiguously represented by its boundary and the boundary has the combinatorial structure of an n−1-dimensional polyhedron having homogeneously n−1-dimensional neighborhoods. == Solid representation schemes == Based on assumed mathematical properties, any scheme of representing solids is a method for capturing information about the class of semi-analytic subsets of Euclidean space. This means all representations are different ways of organizing the same geometric and topological data in the form of a data structure. All representation schemes are organized in terms of a finite number of operations on a set of primitives. Therefore, the modeling space of any particular representation is finite, and any single representation scheme may not completely suffice to represent all types of solids. For example, solids defined via combinations of regularized Boolean operations cannot necessarily be represented as the sweep of a primitive moving according to a space trajectory, except in very simple cases. This forces modern geometric modeling systems to maintain several representation schemes of solids and also facilitate efficient conversion between representation schemes. Below is a list of techniques used to create or represent solid models. Modern modeling software may use a combination of these schemes to represent a solid. === Primitive instancing === This scheme is based on notion of families of object, each member of a family distinguishable from the other by a few parameters. Each object family is called a generic primitive, and individual objects within a family are called primitive instances. For example, a family of bolts is a generic primitive, and a single bolt specified by a particular set of parameters is a primitive instance. The distinguishing characteristic of pure parameterized instancing schemes is the lack of means for combining instances to create new structures which represent new and more complex objects. The other main drawback of this scheme is the difficulty of writing algorithms for computing properties of represented solids. A considerable amount of family-specific information must be built into the algorithms and therefore each generic primitive must be treated as a special case, allowing no uniform overall treatment. === Spatial occupancy enumeration === This scheme is essentially a list of spatial cells occupied by the solid. The cells, also called voxels are cubes of a fixed size and are arranged in a fixed spatial grid (other polyhedral arrangements are also possible but cubes are the simplest). Each cell may be represented by the coordinates of a single point, such as the cell's centroid. Usually a specific scanning order is imposed and the corresponding ordered set of coordinates is called a spatial array. Spatial arrays are unambiguous and unique solid representations but are too verbose for use as 'master' or definitional representations. They can, however, represent coarse approximations of parts and can be used to improve the performance of geometric algorithms, especially when used in conjunction with other representations such as constructive solid geometry. === Cell decomposition === This scheme follows from the combinatoric (algebraic topological) descriptions of solids detailed above. A solid can be represented by its decomposition into several cells. Spatial occupancy enumeration schemes are a particular case of cell decompositions where all the cells are cubical and lie in a regular grid. Cell decompositions provide convenient ways for computing certain topological properties of solids such as its connectedness (number of pieces) and genus (number of holes). Cell decompositions in the form of triangulations are the representations used in 3D finite elements for the numerical solution of partial differential equations. Other cell decompositions such as a Whitney regular stratification or Morse decompositions may be used for applications in robot motion planning. === Surface mesh modeling === Similar to boundary representation, the surface of the object is represented. However, rather than complex data structures and NURBS, a simple surface mesh of vertices and edges is used. Surface meshes can be structured (as in triangular meshes in STL files or quad meshes with horizontal and vertical rings of quadrilaterals), or unstructured meshes with randomly grouped triangles and higher level polygons. === Constructive solid geometry === Constructive solid geometry (CSG) is a family of schemes for representing rigid solids as Boolean constructions or combinations of primitives via the regularized set operations discussed above. CSG and boundary representations are currently the most important representation schemes for solids. CSG representations take the form of ordered binary trees where non-terminal nodes represent either rigid transformations (orientation preserving isometries) or regularized set operations. Terminal nodes are primitive leaves that represent closed regular sets. The semantics of CSG representations is clear. Each subtree represents a set resulting from applying the indicated transformations/regularized set operations on the set represented by the primitive leaves of the subtree. CSG representations are particularly useful for capturing design intent in the form of features corresponding to material addition or removal (bosses, holes, pockets etc.). The attractive properties of CSG include conciseness, guaranteed validity of solids, computationally convenient Boolean algebraic properties, and natural control of a solid's shape in terms of high level parameters defining the solid's primitives and their positions and orientations. The relatively simple data structure and elegant recursive algorithms have further contributed to the popularity of CSG. === Sweeping === The basic notion embodied in sweeping schemes is simple. A set moving through space may trace or sweep out volume (a solid) that may be represented by the moving set and its trajectory. Such a representation is important in the context of applications such as detecting the material removed from a cutter as it moves along a specified trajectory, computing dynamic interference of two solids undergoing relative motion, motion planning, and even in computer graphics applications such as tracing the motions of a brush moved on a canvas. Most commercial CAD systems provide (limited) functionality for constructing swept solids mostly in the form of a two dimensional cross section moving on a space trajectory transversal to the section. However, current research has shown several approximations of three dimensional shapes moving across one parameter, and even multi-parameter motions. === Implicit representation === A very general method of defining a set of points X is to specify a predicate that can be evaluated at any point in space. In other words, X is defined implicitly to consist of all the points that satisfy the condition specified by the predicate. The simplest form of a predicate is the condition on the sign of a real valued function resulting in the familiar representation of sets by equalities and inequalities. For example, if f = a x + b y + c z + d {\displaystyle f=ax+by+cz+d} the conditions f ( p ) = 0 {\displaystyle f(p)=0} , f ( p ) > 0 {\displaystyle f(p)>0} , and f ( p ) < 0 {\displaystyle f(p)<0} represent, respectively, a plane and two open linear halfspaces. More complex functional primitives may be defined by Boolean combinations of simpler predicates. Furthermore, the theory of R-functions allow conversions of such representations into a single function inequality for any closed semi analytic set. Such a representation can be converted to a boundary representation using polygonization algorithms, for example, the marching cubes algorithm. === Parametric and feature-based modeling === Features are defined to be parametric shapes associated with attributes such as intrinsic geometric parameters (length, width, depth etc.), position and orientation, geometric tolerances, material properties, and references to other features. Features also provide access to related production processes and resource models. Thus, features have a semantically higher level than primitive closed regular sets. Features are generally expected to form a basis for linking CAD with downstream manufacturing applications, and also for organizing databases for design data reuse. Parametric feature based modeling is frequently combined with constructive binary solid geometry (CSG) to fully describe systems of complex objects in engineering. == History of solid modelers == The historical development of solid modelers has to be seen in context of the whole history of CAD, the key milestones being the development of the research system BUILD followed by its commercial spin-off Romulus which went on to influence the development of Parasolid, ACIS and Solid Modeling Solutions. One of the first CAD developers in the Commonwealth of Independent States (CIS), ASCON began internal development of its own solid modeler in the 1990s. In November 2012, the mathematical division of ASCON became a separate company, and was named C3D Labs. It was assigned the task of developing the C3D geometric modeling kernel as a standalone product – the only commercial 3D modeling kernel from Russia. Other contributions came from Mäntylä, with his GWB and from the GPM project which contributed, among other things, hybrid modeling techniques at the beginning of the 1980s. This is also when the Programming Language of Solid Modeling PLaSM was conceived at the University of Rome. == Computer-aided design == The modeling of solids is only the minimum requirement of a CAD system's capabilities. Solid modelers have become commonplace in engineering departments in the last ten years due to faster computers and competitive software pricing. Solid modeling software creates a virtual 3D representation of components for machine design and analysis. A typical graphical user interface includes programmable macros, keyboard shortcuts and dynamic model manipulation. The ability to dynamically re-orient the model, in real-time shaded 3-D, is emphasized and helps the designer maintain a mental 3-D image. A solid part model generally consists of a group of features, added one at a time, until the model is complete. Engineering solid models are built mostly with sketcher-based features; 2-D sketches that are swept along a path to become 3-D. These may be cuts, or extrusions for example. Design work on components is usually done within the context of the whole product using assembly modeling methods. An assembly model incorporates references to individual part models that comprise the product. Another type of modeling technique is 'surfacing' (Freeform surface modeling). Here, surfaces are defined, trimmed and merged, and filled to make solid. The surfaces are usually defined with datum curves in space and a variety of complex commands. Surfacing is more difficult, but better applicable to some manufacturing techniques, like injection molding. Solid models for injection molded parts usually have both surfacing and sketcher based features. Engineering drawings can be created semi-automatically and reference the solid models. === Parametric modeling === Parametric modeling uses parameters to define a model (dimensions, for example). Examples of parameters are: dimensions used to create model features, material density, formulas to describe swept features, imported data (that describe a reference surface, for example). The parameter may be modified later, and the model will update to reflect the modification. Typically, there is a relationship between parts, assemblies, and drawings. A part consists of multiple features, and an assembly consists of multiple parts. Drawings can be made from either parts or assemblies. Example: A shaft is created by extruding a circle 100 mm. A hub is assembled to the end of the shaft. Later, the shaft is modified to be 200 mm long (click on the shaft, select the length dimension, modify to 200). When the model is updated the shaft will be 200 mm long, the hub will relocate to the end of the shaft to which it was assembled, and the engineering drawings and mass properties will reflect all changes automatically. Related to parameters, but slightly different, are constraints. Constraints are relationships between entities that make up a particular shape. For a window, the sides might be defined as being parallel, and of the same length. Parametric modeling is obvious and intuitive. But for the first three decades of CAD this was not the case. Modification meant re-draw, or add a new cut or protrusion on top of old ones. Dimensions on engineering drawings were created, instead of shown. Parametric modeling is very powerful, but requires more skill in model creation. A complicated model for an injection molded part may have a thousand features, and modifying an early feature may cause later features to fail. Skillfully created parametric models are easier to maintain and modify. Parametric modeling also lends itself to data re-use. A whole family of capscrews can be contained in one model, for example. === Medical solid modeling === Modern computed axial tomography and magnetic resonance imaging scanners can be used to create solid models of internal body features called voxel-based models, with images generated using volume rendering. Optical 3D scanners can be used to create point clouds or polygon mesh models of external body features. Uses of medical solid modeling; Visualization Visualization of specific body tissues (just blood vessels and tumor, for example) Designing prosthetics, orthotics, and other medical and dental devices (this is sometimes called mass customization) Creating polygon mesh models for rapid prototyping (to aid surgeons preparing for difficult surgeries, for example) Combining polygon mesh models with CAD solid modeling (design of hip replacement parts, for example) Computational analysis of complex biological processes, e.g. air flow, blood flow Computational simulation of new medical devices and implants in vivo If the use goes beyond visualization of the scan data, processes like image segmentation and image-based meshing will be necessary to generate an accurate and realistic geometrical description of the scan data. === Engineering === Because CAD programs running on computers "understand" the true geometry comprising complex shapes, many attributes of/for a 3‑D solid, such as its center of gravity, volume, and mass, can be quickly calculated. For instance, the cube with rounded edges shown at the top of this article measures 8.4 mm from flat to flat. Despite its many radii and the shallow pyramid on each of its six faces, its properties are readily calculated for the designer, as shown in the screenshot at right. == See also == Wire frame modelling Free-surface modelling Computational geometry Computer graphics Engineering drawing Euler boundary representation List of CAx companies PLaSM – Programming Language of Solid Modeling. Technical drawing == References == == External links == sgCore C++/C# library The Solid Modeling Association
Wikipedia/Solid_modeling
In computer science, formal methods are mathematically rigorous techniques for the specification, development, analysis, and verification of software and hardware systems. The use of formal methods for software and hardware design is motivated by the expectation that, as in other engineering disciplines, performing appropriate mathematical analysis can contribute to the reliability and robustness of a design. Formal methods employ a variety of theoretical computer science fundamentals, including logic calculi, formal languages, automata theory, control theory, program semantics, type systems, and type theory. == Uses == Formal methods can be applied at various points through the development process. === Specification === Formal methods may be used to give a formal description of the system to be developed, at whatever level of detail desired. Further formal methods may depend on this specification to synthesize a program or to verify the correctness of a system. Alternatively, specification may be the only stage in which formal methods is used. By writing a specification, ambiguities in the informal requirements can be discovered and resolved. Additionally, engineers can use a formal specification as a reference to guide their development processes. The need for formal specification systems has been noted for years. In the ALGOL 58 report, John Backus presented a formal notation for describing programming language syntax, later named Backus normal form then renamed Backus–Naur form (BNF). Backus also wrote that a formal description of the meaning of syntactically valid ALGOL programs was not completed in time for inclusion in the report, stating that it "will be included in a subsequent paper." However, no paper describing the formal semantics was ever released. === Synthesis === Program synthesis is the process of automatically creating a program that conforms to a specification. Deductive synthesis approaches rely on a complete formal specification of the program, whereas inductive approaches infer the specification from examples. Synthesizers perform a search over the space of possible programs to find a program consistent with the specification. Because of the size of this search space, developing efficient search algorithms is one of the major challenges in program synthesis. === Verification === Formal verification is the use of software tools to prove properties of a formal specification, or to prove that a formal model of a system implementation satisfies its specification. Once a formal specification has been developed, the specification may be used as the basis for proving properties of the specification, and by inference, properties of the system implementation. ==== Sign-off verification ==== Sign-off verification is the use of a formal verification tool that is highly trusted. Such a tool can replace traditional verification methods (the tool may even be certified). ==== Human-directed proof ==== Sometimes, the motivation for proving the correctness of a system is not the obvious need for reassurance of the correctness of the system, but a desire to understand the system better. Consequently, some proofs of correctness are produced in the style of mathematical proof: handwritten (or typeset) using natural language, using a level of informality common to such proofs. A "good" proof is one that is readable and understandable by other human readers. Critics of such approaches point out that the ambiguity inherent in natural language allows errors to be undetected in such proofs; often, subtle errors can be present in the low-level details typically overlooked by such proofs. Additionally, the work involved in producing such a good proof requires a high level of mathematical sophistication and expertise. ==== Automated proof ==== In contrast, there is increasing interest in producing proofs of correctness of such systems by automated means. Automated techniques fall into three general categories: Automated theorem proving, in which a system attempts to produce a formal proof from scratch, given a description of the system, a set of logical axioms, and a set of inference rules. Model checking, in which a system verifies certain properties by means of an exhaustive search of all possible states that a system could enter during its execution. Abstract interpretation, in which a system verifies an over-approximation of a behavioural property of the program, using a fixpoint computation over a (possibly complete) lattice representing it. Some automated theorem provers require guidance as to which properties are "interesting" enough to pursue, while others work without human intervention. Model checkers can quickly get bogged down in checking millions of uninteresting states if not given a sufficiently abstract model. Proponents of such systems argue that the results have greater mathematical certainty than human-produced proofs, since all the tedious details have been algorithmically verified. The training required to use such systems is also less than that required to produce good mathematical proofs by hand, making the techniques accessible to a wider variety of practitioners. Critics note that some of those systems are like oracles: they make a pronouncement of truth, yet give no explanation of that truth. There is also the problem of "verifying the verifier"; if the program that aids in the verification is itself unproven, there may be reason to doubt the soundness of the produced results. Some modern model checking tools produce a "proof log" detailing each step in their proof, making it possible to perform, given suitable tools, independent verification. The main feature of the abstract interpretation approach is that it provides a sound analysis, i.e. no false negatives are returned. Moreover, it is efficiently scalable, by tuning the abstract domain representing the property to be analyzed, and by applying widening operators to get fast convergence. == Techniques == Formal methods includes a number of different techniques. === Specification languages === The design of a computing system can be expressed using a specification language, which is a formal language that includes a proof system. Using this proof system, formal verification tools can reason about the specification and establish that a system adheres to the specification. === Binary decision diagrams === A binary decision diagram is a data structure that represents a Boolean function. If a Boolean formula P {\displaystyle {\mathcal {P}}} expresses that an execution of a program conforms to the specification, a binary decision diagram can be used to determine if P {\displaystyle {\mathcal {P}}} is a tautology; that is, it always evaluates to TRUE. If this is the case, then the program always conforms to the specification. === SAT solvers === A SAT solver is a program that can solve the Boolean satisfiability problem, the problem of finding an assignment of variables that makes a given propositional formula evaluate to true. If a Boolean formula P {\displaystyle {\mathcal {P}}} expresses that a specific execution of a program conforms to the specification, then determining that ¬ P {\displaystyle \neg {\mathcal {P}}} is unsatisfiable is equivalent to determining that all executions conform to the specification. SAT solvers are often used in bounded model checking, but can also be used in unbounded model checking. == Applications == Formal methods are applied in different areas of hardware and software, including routers, Ethernet switches, routing protocols, security applications, and operating system microkernels such as seL4. There are several examples in which they have been used to verify the functionality of the hardware and software used in data centres. IBM used ACL2, a theorem prover, in the AMD x86 processor development process. Intel uses such methods to verify its hardware and firmware (permanent software programmed into a read-only memory). Dansk Datamatik Center used formal methods in the 1980s to develop a compiler system for the Ada programming language that went on to become a long-lived commercial product. There are several other projects of NASA in which formal methods are applied, such as Next Generation Air Transportation System, Unmanned Aircraft System integration in National Airspace System, and Airborne Coordinated Conflict Resolution and Detection (ACCoRD). B-Method with Atelier B, is used to develop safety automatisms for the various subways installed throughout the world by Alstom and Siemens, and also for Common Criteria certification and the development of system models by ATMEL and STMicroelectronics. Formal verification has been frequently used in hardware by most of the well-known hardware vendors, such as IBM, Intel, and AMD. There are many areas of hardware, where Intel have used formal methods to verify the working of the products, such as parameterized verification of cache-coherent protocol, Intel Core i7 processor execution engine validation (using theorem proving, BDDs, and symbolic evaluation), optimization for Intel IA-64 architecture using HOL light theorem prover, and verification of high-performance dual-port gigabit Ethernet controller with support for PCI express protocol and Intel advance management technology using Cadence. Similarly, IBM has used formal methods in the verification of power gates, registers, and functional verification of the IBM Power7 microprocessor. == In software development == In software development, formal methods are mathematical approaches to solving software (and hardware) problems at the requirements, specification, and design levels. Formal methods are most likely to be applied to safety-critical or security-critical software and systems, such as avionics software. Software safety assurance standards, such as DO-178C allows the usage of formal methods through supplementation, and Common Criteria mandates formal methods at the highest levels of categorization. For sequential software, examples of formal methods include the B-Method, the specification languages used in automated theorem proving, RAISE, and the Z notation. In functional programming, property-based testing has allowed the mathematical specification and testing (if not exhaustive testing) of the expected behaviour of individual functions. The Object Constraint Language (and specializations such as Java Modeling Language) has allowed object-oriented systems to be formally specified, if not necessarily formally verified. For concurrent software and systems, Petri nets, process algebra, and finite-state machines (which are based on automata theory; see also virtual finite state machine or event driven finite state machine) allow executable software specification and can be used to build up and validate application behaviour. Another approach to formal methods in software development is to write a specification in some form of logic—usually a variation of first-order logic—and then to directly execute the logic as though it were a program. The OWL language, based on description logic, is an example. There is also work on mapping some version of English (or another natural language) automatically to and from logic, as well as executing the logic directly. Examples are Attempto Controlled English, and Internet Business Logic, which do not seek to control the vocabulary or syntax. A feature of systems that support bidirectional English–logic mapping and direct execution of the logic is that they can be made to explain their results, in English, at the business or scientific level. == Semi-formal methods == Semi-formal methods are formalisms and languages that are not considered fully "formal". It defers the task of completing the semantics to a later stage, which is then done either by human interpretation or by interpretation through software like code or test case generators. Some practitioners believe that the formal methods community has overemphasized full formalization of a specification or design. They contend that the expressiveness of the languages involved, as well as the complexity of the systems being modelled, make full formalization a difficult and expensive task. As an alternative, various lightweight formal methods, which emphasize partial specification and focused application, have been proposed. Examples of this lightweight approach to formal methods include the Alloy object modelling notation, Denney's synthesis of some aspects of the Z notation with use case driven development, and the CSK VDM Tools. == Formal methods and notations == There are a variety of formal methods and notations available. === Specification languages === Abstract State Machines (ASMs) A Computational Logic for Applicative Common Lisp (ACL2) Actor model Alloy ANSI/ISO C Specification Language (ACSL) Autonomic System Specification Language (ASSL) B-Method CADP Common Algebraic Specification Language (CASL) Esterel Java Modeling Language (JML) Knowledge Based Software Assistant (KBSA) Lustre mCRL2 Perfect Developer Petri nets Predicative programming Process calculi CSP LOTOS π-calculus RAISE Rebeca Modeling Language SPARK Ada Specification and Description Language TLA+ USL VDM VDM-SL VDM++ Z notation === Model checkers === ESBMC MALPAS Software Static Analysis Toolset – an industrial-strength model checker used for formal proof of safety-critical systems PAT – a free model checker, simulator and refinement checker for concurrent systems and CSP extensions (e.g., shared variables, arrays, fairness) SPIN UPPAAL == Solvers and competitions == Many problems in formal methods are NP-hard, but can be solved in cases arising in practice. For example, the Boolean satisfiability problem is NP-complete by the Cook–Levin theorem, but SAT solvers can solve a variety of large instances. There are "solvers" for a variety of problems that arise in formal methods, and there are many periodic competitions to evaluate the state-of-the-art in solving such problems. The SAT competition is a yearly competition that compares SAT solvers. SAT solvers are used in formal methods tools such as Alloy. CASC is a yearly competition of automated theorem provers. SMT-COMP is a yearly competition of SMT solvers, which are applied to formal verification. CHC-COMP is a yearly competition of solvers of constrained Horn clauses, which have applications to formal verification. QBFEVAL is a biennial competition of solvers for true quantified Boolean formulas, which have applications to model checking. SV-COMP is an annual competition for software verification tools. SyGuS-COMP is an annual competition for program synthesis tools. == Organizations == BCS-FACS Formal Methods Europe Z User Group == See also == Abstract interpretation Automated theorem proving Design by contract Formal methods people Formal science Formal specification Formal verification Formal system Methodism Methodology Model checking Scientific method Software engineering Specification language == References == == Further reading == == External links == Formal Methods Europe (FME) Formal Methods Wiki Formal methods from Foldoc Archival material Formal method keyword on Microsoft Academic Search via Archive.org Evidence on Formal Methods uses and impact on Industry supported by the DEPLOY Archived 2012-06-08 at the Wayback Machine project (EU FP7) in Archive.org
Wikipedia/Formal_methods
Rendering is the process of generating a photorealistic or non-photorealistic image from input data such as 3D models. The word "rendering" (in one of its senses) originally meant the task performed by an artist when depicting a real or imaginary thing (the finished artwork is also called a "rendering"). Today, to "render" commonly means to generate an image or video from a precise description (often created by an artist) using a computer program. A software application or component that performs rendering is called a rendering engine, render engine, rendering system, graphics engine, or simply a renderer. A distinction is made between real-time rendering, in which images are generated and displayed immediately (ideally fast enough to give the impression of motion or animation), and offline rendering (sometimes called pre-rendering) in which images, or film or video frames, are generated for later viewing. Offline rendering can use a slower and higher-quality renderer. Interactive applications such as games must primarily use real-time rendering, although they may incorporate pre-rendered content. Rendering can produce images of scenes or objects defined using coordinates in 3D space, seen from a particular viewpoint. Such 3D rendering uses knowledge and ideas from optics, the study of visual perception, mathematics, and software engineering, and it has applications such as video games, simulators, visual effects for films and television, design visualization, and medical diagnosis. Realistic 3D rendering requires modeling the propagation of light in an environment, e.g. by applying the rendering equation. Real-time rendering uses high-performance rasterization algorithms that process a list of shapes and determine which pixels are covered by each shape. When more realism is required (e.g. for architectural visualization or visual effects) slower pixel-by-pixel algorithms such as ray tracing are used instead. (Ray tracing can also be used selectively during rasterized rendering to improve the realism of lighting and reflections.) A type of ray tracing called path tracing is currently the most common technique for photorealistic rendering. Path tracing is also popular for generating high-quality non-photorealistic images, such as frames for 3D animated films. Both rasterization and ray tracing can be sped up ("accelerated") by specially designed microprocessors called GPUs. Rasterization algorithms are also used to render images containing only 2D shapes such as polygons and text. Applications of this type of rendering include digital illustration, graphic design, 2D animation, desktop publishing and the display of user interfaces. Historically, rendering was called image synthesis: xxi  but today this term is likely to mean AI image generation. The term "neural rendering" is sometimes used when a neural network is the primary means of generating an image but some degree of control over the output image is provided. Neural networks can also assist rendering without replacing traditional algorithms, e.g. by removing noise from path traced images. == Features == === Photorealistic rendering === A large proportion of computer graphics research has worked towards producing images that resemble photographs. Fundamental techniques that make this possible were invented in the 1980s, but at the end of the decade, photorealism for complex scenes was still considered a distant goal.: x  Today, photorealism is routinely achievable for offline rendering, but remains difficult for real-time rendering.: 1–2  In order to produce realistic images, rendering must simulate how light travels from light sources, is reflected, refracted, and scattered (often many times) by objects in the scene, passes through a camera lens, and finally reaches the film or sensor of the camera. The physics used in these simulations is primarily geometrical optics, in which particles of light follow (usually straight) lines called rays, but in some situations (such as when rendering thin films, like the surface of soap bubbles) the wave nature of light must be taken into account. Effects that may need to be simulated include: Shadows, including both shadows with sharp edges and soft shadows with umbra and penumbra Reflections in mirrors and smooth surfaces, as well as rough or rippled reflective surfaces Refraction – the bending of light when it crosses a boundary between two transparent materials such as air and glass. The amount of bending varies with the wavelength of the light, which may cause colored fringes or "rainbows" to appear. Volumetric effects – Absorption and scattering when light travels through partially transparent or translucent substances (called participating media because they modify the light rather than simply allow rays to pass through): 140  Caustics – bright patches, sometimes with distinct filaments and a folded or twisted appearance, resulting when light is reflected or refracted before illuminating an object.: 109  In realistic scenes, objects are illuminated both by light that arrives directly from a light source (after passing mostly unimpeded through air), and light that has bounced off other objects in the scene. The simulation of this complex lighting is called global illumination. In the past, indirect lighting was often faked (especially when rendering animated films) by placing additional hidden lights in the scene, but today path tracing is used to render it accurately.: 3 : 108  For true photorealism, the camera used to take the photograph must be simulated. The thin lens approximation allows combining perspective projection with depth of field (and bokeh) emulation. Camera lens simulations can be made more realistic by modeling the way light is refracted by the components of the lens. Motion blur is often simulated if film or video frames are being rendered. Simulated lens flare and bloom are sometimes added to make the image appear subjectively brighter (although the design of real cameras tries to reduce these effects).: 12.4  Realistic rendering uses mathematical descriptions of how different surface materials reflect light, called reflectance models or (when physically plausible) bidirectional reflectance distribution functions (BRDFs). Rendering materials such as marble, plant leaves, and human skin requires simulating an effect called subsurface scattering, in which a portion of the light travels into the material, is scattered, and then travels back out again.: 143  The way color, and properties such as roughness, vary over a surface can be represented efficiently using texture mapping.: 6.1  === Other styles of 3D rendering === For some applications (including early stages of 3D modeling), simplified rendering styles such as wireframe rendering may be appropriate, particularly when the material and surface details have not been defined and only the shape of an object is known.: 5.3  Games and other real-time applications may use simpler and less realistic rendering techniques as an artistic or design choice, or to allow higher frame rates on lower-end hardware. Orthographic and isometric projections can be used for a stylized effect or to ensure that parallel lines are depicted as parallel in CAD rendering.: 4.7 : 3.7  Non-photorealistic rendering (NPR) uses techniques like edge detection and posterization to produce 3D images that resemble technical illustrations, cartoons, or other styles of drawing or painting.: ch 15  == Inputs == Before a 3D scene or 2D image can be rendered, it must be described in a way that the rendering software can understand. Historically, inputs for both 2D and 3D rendering were usually text files, which are easier than binary files for humans to edit and debug. For 3D graphics, text formats have largely been supplanted by more efficient binary formats, and by APIs which allow interactive applications to communicate directly with a rendering component without generating a file on disk (although a scene description is usually still created in memory prior to rendering).: 1.2, 3.2.6, 3.3.1, 3.3.7  Traditional rendering algorithms use geometric descriptions of 3D scenes or 2D images. Applications and algorithms that render visualizations of data scanned from the real world, or scientific simulations, may require different types of input data. The PostScript format (which is often credited with the rise of desktop publishing) provides a standardized, interoperable way to describe 2D graphics and page layout. The Scalable Vector Graphics (SVG) format is also text-based, and the PDF format uses the PostScript language internally. In contrast, although many 3D graphics file formats have been standardized (including text-based formats such as VRML and X3D), different rendering applications typically use formats tailored to their needs, and this has led to a proliferation of proprietary and open formats, with binary files being more common.: 3.2.3, 3.2.5, 3.3.7 : vii : 16.5.2.  === 2D vector graphics === A vector graphics image description may include: Coordinates and curvature information for line segments, arcs, and Bézier curves (which may be used as boundaries of filled shapes) Center coordinates, width, and height (or bounding rectangle coordinates) of basic shapes such as rectangles, circles and ellipses Color, width and pattern (such as dashed or dotted) for rendering lines Colors, patterns, and gradients for filling shapes Bitmap image data (either embedded or in an external file) along with scale and position information Text to be rendered (along with size, position, orientation, color, and font) Clipping information, if only part of a shape or bitmap image should be rendered Transparency and compositing information for rendering overlapping shapes Color space information, allowing the image to be rendered consistently on different displays and printers === 3D geometry === A geometric scene description may include:: Ch. 4-7, 8.7  Size, position, and orientation of geometric primitives such as spheres and cones (which may be combined in various ways to create more complex objects) Vertex coordinates and surface normal vectors for meshes of triangles or polygons (often rendered as smooth surfaces by subdividing the mesh) Transformations for positioning, rotating, and scaling objects within a scene (allowing parts of the scene to use different local coordinate systems). "Camera" information describing how the scene is being viewed (position, direction, focal length, and field of view) Light information (location, type, brightness, and color) Optical properties of surfaces, such as albedo, roughness, and refractive index, Optical properties of media through which light passes (transparent solids, liquids, clouds, smoke), e.g. absorption and scattering cross sections Bitmap image data used as texture maps for surfaces Small scripts or programs for generating complex 3D shapes or scenes procedurally Description of how object and camera locations and other information change over time, for rendering an animation Many file formats exist for storing individual 3D objects or "models". These can be imported into a larger scene, or loaded on-demand by rendering software or games. A realistic scene may require hundreds of items like household objects, vehicles, and trees, and 3D artists often utilize large libraries of models. In game production, these models (along with other data such as textures, audio files, and animations) are referred to as "assets".: Ch. 4  === Volumetric data === Scientific and engineering visualization often requires rendering volumetric data generated by 3D scans or simulations. Perhaps the most common source of such data is medical CT and MRI scans, which need to be rendered for diagnosis. Volumetric data can be extremely large, and requires specialized data formats to store it efficiently, particularly if the volume is sparse (with empty regions that do not contain data).: 14.3.1  Before rendering, level sets for volumetric data can be extracted and converted into a mesh of triangles, e.g. by using the marching cubes algorithm. Algorithms have also been developed that work directly with volumetric data, for example to render realistic depictions of the way light is scattered and absorbed by clouds and smoke, and this type of volumetric rendering is used extensively in visual effects for movies. When rendering lower-resolution volumetric data without interpolation, the individual cubes or "voxels" may be visible, an effect sometimes used deliberately for game graphics.: 4.6 : 13.10, Ch. 14, 16.1  === Photogrammetry and scanning === Photographs of real world objects can be incorporated into a rendered scene by using them as textures for 3D objects. Photos of a scene can also be stitched together to create panoramic images or environment maps, which allow the scene to be rendered very efficiently but only from a single viewpoint. Scanning of real objects and scenes using structured light or lidar produces point clouds consisting of the coordinates of millions of individual points in space, sometimes along with color information. These point clouds may either be rendered directly or converted into meshes before rendering. (Note: "point cloud" sometimes also refers to a minimalist rendering style that can be used for any 3D geometry, similar to wireframe rendering.): 13.3, 13.9 : 1.3  === Neural approximations and light fields === A more recent, experimental approach is description of scenes using radiance fields which define the color, intensity, and direction of incoming light at each point in space. (This is conceptually similar to, but not identical to, the light field recorded by a hologram.) For any useful resolution, the amount of data in a radiance field is so large that it is impractical to represent it directly as volumetric data, and an approximation function must be found. Neural networks are typically used to generate and evaluate these approximations, sometimes using video frames, or a collection of photographs of a scene taken at different angles, as "training data". Algorithms related to neural networks have recently been used to find approximations of a scene as 3D Gaussians. The resulting representation is similar to a point cloud, except that it uses fuzzy, partially-transparent blobs of varying dimensions and orientations instead of points. As with neural radiance fields, these approximations are often generated from photographs or video frames. == Outputs == The output of rendering may be displayed immediately on the screen (many times a second, in the case of real-time rendering such as games) or saved in a raster graphics file format such as JPEG or PNG. High-end rendering applications commonly use the OpenEXR file format, which can represent finer gradations of colors and high dynamic range lighting, allowing tone mapping or other adjustments to be applied afterwards without loss of quality.: Ch. 14, Ap. B  Quickly rendered animations can be saved directly as video files, but for high-quality rendering, individual frames (which may be rendered by different computers in a cluster or render farm and may take hours or even days to render) are output as separate files and combined later into a video clip.: 1.5, 3.11, 8.11  The output of a renderer sometimes includes more than just RGB color values. For example, the spectrum can be sampled using multiple wavelengths of light, or additional information such as depth (distance from camera) or the material of each point in the image can be included (this data can be used during compositing or when generating texture maps for real-time rendering, or used to assist in removing noise from a path-traced image). Transparency information can be included, allowing rendered foreground objects to be composited with photographs or video. It is also sometimes useful to store the contributions of different lights, or of specular and diffuse lighting, as separate channels, so lighting can be adjusted after rendering. The OpenEXR format allows storing many channels of data in a single file. Renderers such as Blender and Pixar RenderMan support a large variety of configurable values called Arbitrary Output Variables (AOVs).: Ch. 14, Ap. B  == Techniques == Choosing how to render a 3D scene usually involves trade-offs between speed, memory usage, and realism (although realism is not always desired). The algorithms developed over the years follow a loose progression, with more advanced methods becoming practical as computing power and memory capacity increased. Multiple techniques may be used for a single final image. An important distinction is between image order algorithms, which iterate over pixels in the image, and object order algorithms, which iterate over objects in the scene. For simple scenes, object order is usually more efficient, as there are fewer objects than pixels.: Ch. 4  2D vector graphics The vector displays of the 1960s-1970s used deflection of an electron beam to draw line segments directly on the screen. Nowadays, vector graphics are rendered by rasterization algorithms that also support filled shapes. In principle, any 2D vector graphics renderer can be used to render 3D objects by first projecting them onto a 2D image plane. : 93, 431, 505, 553  3D rasterization Adapts 2D rasterization algorithms so they can be used more efficiently for 3D rendering, handling hidden surface removal via scanline or z-buffer techniques. Different realistic or stylized effects can be obtained by coloring the pixels covered by the objects in different ways. Surfaces are typically divided into meshes of triangles before being rasterized. Rasterization is usually synonymous with "object order" rendering (as described above).: 560-561, 575-590 : 8.5 : Ch. 9  Ray casting Uses geometric formulas to compute the first object that a ray intersects.: 8  It can be used to implement "image order" rendering by casting a ray for each pixel, and finding a corresponding point in the scene. Ray casting is a fundamental operation used for both graphical and non-graphical purposes,: 6  e.g. determining whether a point is in shadow, or checking what an enemy can see in a game. Ray tracing Simulates the bouncing paths of light caused by specular reflection and refraction, requiring a varying number of ray casting operations for each path. Advanced forms use Monte Carlo techniques to render effects such as area lights, depth of field, blurry reflections, and soft shadows, but computing global illumination is usually in the domain of path tracing.: 9-13  Radiosity A finite element analysis approach that breaks surfaces in the scene into pieces, and estimates the amount of light that each piece receives from light sources, or indirectly from other surfaces. Once the irradiance of each surface is known, the scene can be rendered using rasterization or ray tracing.: 888-890, 1044-1045  Path tracing Uses Monte Carlo integration with a simplified form of ray tracing, computing the average brightness of a sample of the possible paths that a photon could take when traveling from a light source to the camera (for some images, thousands of paths need to be sampled per pixel: 8 ). It was introduced as a statistically unbiased way to solve the rendering equation, giving ray tracing a rigorous mathematical foundation.: 11-13  Each of the above approaches has many variations, and there is some overlap. Path tracing may be considered either a distinct technique or a particular type of ray tracing.: 846, 1021  Note that the usage of terminology related to ray tracing and path tracing has changed significantly over time.: 7  Ray marching is a family of algorithms, used by ray casting, for finding intersections between a ray and a complex object, such as a volumetric dataset or a surface defined by a signed distance function. It is not, by itself, a rendering method, but it can be incorporated into ray tracing and path tracing, and is used by rasterization to implement screen-space reflection and other effects.: 13  A technique called photon mapping traces paths of photons from a light source to an object, accumulating data about irradiance which is then used during conventional ray tracing or path tracing.: 1037-1039  Rendering a scene using only rays traced from the light source to the camera is impractical, even though it corresponds more closely to reality, because a huge number of photons would need to be simulated, only a tiny fraction of which actually hit the camera.: 7-9 : 587  Some authors call conventional ray tracing "backward" ray tracing because it traces the paths of photons backwards from the camera to the light source, and call following paths from the light source (as in photon mapping) "forward" ray tracing.: 7-9  However, sometimes the meaning of these terms is reversed. Tracing rays starting at the light source can also be called particle tracing or light tracing, which avoids this ambiguity.: 92 : 4.5.4  Real-time rendering, including video game graphics, typically uses rasterization, but increasingly combines it with ray tracing and path tracing.: 2  To enable realistic global illumination, real-time rendering often relies on pre-rendered ("baked") lighting for stationary objects. For moving objects, it may use a technique called light probes, in which lighting is recorded by rendering omnidirectional views of the scene at chosen points in space (often points on a grid to allow easier interpolation). These are similar to environment maps, but typically use a very low resolution or an approximation such as spherical harmonics. (Note: Blender uses the term 'light probes' for a more general class of pre-recorded lighting data, including reflection maps.) === Rasterization === The term rasterization (in a broad sense) encompasses many techniques used for 2D rendering and real-time 3D rendering. 3D animated films were rendered by rasterization before ray tracing and path tracing became practical. A renderer combines rasterization with geometry processing (which is not specific to rasterization) and pixel processing which computes the RGB color values to be placed in the framebuffer for display.: 2.1 : 9  The main tasks of rasterization (including pixel processing) are:: 2, 3.8, 23.1.1  Determining which pixels are covered by each geometric shape in the 3D scene or 2D image (this is the actual rasterization step, in the strictest sense) Blending between colors and depths defined at the vertices of shapes, e.g. using barycentric coordinates (interpolation) Determining if parts of shapes are hidden by other shapes, due to 2D layering or 3D depth (hidden surface removal) Evaluating a function for each pixel covered by a shape (shading) Smoothing edges of shapes so pixels are less visible (anti-aliasing) Blending overlapping transparent shapes (compositing) 3D rasterization is typically part of a graphics pipeline in which an application provides lists of triangles to be rendered, and the rendering system transforms and projects their coordinates, determines which triangles are potentially visible in the viewport, and performs the above rasterization and pixel processing tasks before displaying the final result on the screen.: 2.1 : 9  Historically, 3D rasterization used algorithms like the Warnock algorithm and scanline rendering (also called "scan-conversion"), which can handle arbitrary polygons and can rasterize many shapes simultaneously. Although such algorithms are still important for 2D rendering, 3D rendering now usually divides shapes into triangles and rasterizes them individually using simpler methods.: 456, 561–569  High-performance algorithms exist for rasterizing 2D lines, including anti-aliased lines, as well as ellipses and filled triangles. An important special case of 2D rasterization is text rendering, which requires careful anti-aliasing and rounding of coordinates to avoid distorting the letterforms and preserve spacing, density, and sharpness.: 9.1.1  After 3D coordinates have been projected onto the image plane, rasterization is primarily a 2D problem, but the 3rd dimension necessitates hidden surface removal. Early computer graphics used geometric algorithms or ray casting to remove the hidden portions of shapes, or used the painter's algorithm, which sorts shapes by depth (distance from camera) and renders them from back to front. Depth sorting was later avoided by incorporating depth comparison into the scanline rendering algorithm. The z-buffer algorithm performs the comparisons indirectly by including a depth or "z" value in the framebuffer. A pixel is only covered by a shape if that shape's z value is lower (indicating closer to the camera) than the z value currently in the buffer. The z-buffer requires additional memory (an expensive resource at the time it was invented) but simplifies the rasterization code and permits multiple passes. Memory is now faster and more plentiful, and a z-buffer is almost always used for real-time rendering.: 553–570 : 2.5.2  A drawback of the basic z-buffer algorithm is that each pixel ends up either entirely covered by a single object or filled with the background color, causing jagged edges in the final image. Early anti-aliasing approaches addressed this by detecting when a pixel is partially covered by a shape, and calculating the covered area. The A-buffer (and other supersampling and multi-sampling techniques) solve the problem less precisely but with higher performance. For real-time 3D graphics, it has become common to use complicated heuristics (and even neural-networks) to perform anti-aliasing.: 9.3 : 5.4.2  In 3D rasterization, color is usually determined by a pixel shader or fragment shader, a small program that is run for each pixel. The shader does not (or cannot) directly access 3D data for the entire scene (this would be very slow, and would result in an algorithm similar to ray tracing) and a variety of techniques have been developed to render effects like shadows and reflections using only texture mapping and multiple passes.: 17.8  Older and more basic 3D rasterization implementations did not support shaders, and used simple shading techniques such as flat shading (lighting is computed once for each triangle, which is then rendered entirely in one color), Gouraud shading (lighting is computed using normal vectors defined at vertices and then colors are interpolated across each triangle), or Phong shading (normal vectors are interpolated across each triangle and lighting is computed for each pixel).: 9.2  Until relatively recently, Pixar used rasterization for rendering its animated films. Unlike the renderers commonly used for real-time graphics, the Reyes rendering system in Pixar's RenderMan software was optimized for rendering very small (pixel-sized) polygons, and incorporated stochastic sampling techniques more typically associated with ray tracing.: 2, 6.3  === Ray casting === One of the simplest ways to render a 3D scene is to test if a ray starting at the viewpoint (the "eye" or "camera") intersects any of the geometric shapes in the scene, repeating this test using a different ray direction for each pixel. This method, called ray casting, was important in early computer graphics, and is a fundamental building block for more advanced algorithms. Ray casting can be used to render shapes defined by constructive solid geometry (CSG) operations.: 8-9 : 246–249  Early ray casting experiments include the work of Arthur Appel in the 1960s. Appel rendered shadows by casting an additional ray from each visible surface point towards a light source. He also tried rendering the density of illumination by casting random rays from the light source towards the object and plotting the intersection points (similar to the later technique called photon mapping). When rendering scenes containing many objects, testing the intersection of a ray with every object becomes very expensive. Special data structures are used to speed up this process by allowing large numbers of objects to be excluded quickly (such as objects behind the camera). These structures are analogous to database indexes for finding the relevant objects. The most common are the bounding volume hierarchy (BVH), which stores a pre-computed bounding box or sphere for each branch of a tree of objects, and the k-d tree which recursively divides space into two parts. Recent GPUs include hardware acceleration for BVH intersection tests. K-d trees are a special case of binary space partitioning, which was frequently used in early computer graphics (it can also generate a rasterization order for the painter's algorithm). Octrees, another historically popular technique, are still often used for volumetric data.: 16–17 : 36.2  Geometric formulas are sufficient for finding the intersection of a ray with shapes like spheres, polygons, and polyhedra, but for most curved surfaces there is no analytic solution, or the intersection is difficult to compute accurately using limited precision floating point numbers. Root-finding algorithms such as Newton's method can sometimes be used. To avoid these complications, curved surfaces are often approximated as meshes of triangles. Volume rendering (e.g. rendering clouds and smoke), and some surfaces such as fractals, may require ray marching instead of basic ray casting.: 13 : 14, 17.3  === Ray tracing === Ray casting can be used to render an image by tracing light rays backwards from a simulated camera. After finding a point on a surface where a ray originated, another ray is traced towards the light source to determine if anything is casting a shadow on that point. If not, a reflectance model (such as Lambertian reflectance for matte surfaces, or the Phong reflection model for glossy surfaces) is used to compute the probability that a photon arriving from the light would be reflected towards the camera, and this is multiplied by the brightness of the light to determine the pixel brightness. If there are multiple light sources, brightness contributions of the lights are added together. For color images, calculations are repeated for multiple wavelengths of light (e.g. red, green, and blue).: 11.2.2 : 8  Classical ray tracing (also called Whitted-style or recursive ray tracing) extends this method so it can render mirrors and transparent objects. If a ray traced backwards from the camera originates at a point on a mirror, the reflection formula from geometric optics is used to calculate the direction the reflected ray came from, and another ray is cast backwards in that direction. If a ray originates at a transparent surface, rays are cast backwards for both reflected and refracted rays (using Snell's law to compute the refracted direction), and so ray tracing needs to support a branching "tree" of rays. In simple implementations, a recursive function is called to trace each ray.: 11.2.2 : 9  Ray tracing usually performs anti-aliasing by taking the average of multiple samples for each pixel. It may also use multiple samples for effects like depth of field and motion blur. If evenly-spaced ray directions or times are used for each of these features, many rays are required, and some aliasing will remain. Cook-style, stochastic, or Monte Carlo ray tracing avoids this problem by using random sampling instead of evenly-spaced samples. This type of ray tracing is commonly called distributed ray tracing, or distribution ray tracing because it samples rays from probability distributions. Distribution ray tracing can also render realistic "soft" shadows from large lights by using a random sample of points on the light when testing for shadowing, and it can simulate chromatic aberration by sampling multiple wavelengths from the spectrum of light.: 10 : 25  Real surface materials reflect small amounts of light in almost every direction because they have small (or microscopic) bumps and grooves. A distribution ray tracer can simulate this by sampling possible ray directions, which allows rendering blurry reflections from glossy and metallic surfaces. However, if this procedure is repeated recursively to simulate realistic indirect lighting, and if more than one sample is taken at each surface point, the tree of rays quickly becomes huge. Another kind of ray tracing, called path tracing, handles indirect light more efficiently, avoiding branching, and ensures that the distribution of all possible paths from a light source to the camera is sampled in an unbiased way.: 25–27  Ray tracing was often used for rendering reflections in animated films, until path tracing became standard for film rendering. Films such as Shrek 2 and Monsters University also used distribution ray tracing or path tracing to precompute indirect illumination for a scene or frame prior to rendering it using rasterization.: 118–121  Advances in GPU technology have made real-time ray tracing possible in games, although it is currently almost always used in combination with rasterization.: 2  This enables visual effects that are difficult with only rasterization, including reflection from curved surfaces and interreflective objects,: 305  and shadows that are accurate over a wide range of distances and surface orientations.: 159-160  Ray tracing support is included in recent versions of the graphics APIs used by games, such as DirectX, Metal, and Vulkan. Ray tracing has been used to render simulated black holes, and the appearance of objects moving at close to the speed of light, by taking spacetime curvature and relativistic effects into account during light ray simulation. === Radiosity === Radiosity (named after the radiometric quantity of the same name) is a method for rendering objects illuminated by light bouncing off rough or matte surfaces. This type of illumination is called indirect light, environment lighting, diffuse lighting, or diffuse interreflection, and the problem of rendering it realistically is called global illumination. Rasterization and basic forms of ray tracing (other than distribution ray tracing and path tracing) can only roughly approximate indirect light, e.g. by adding a uniform "ambient" lighting amount chosen by the artist. Radiosity techniques are also suited to rendering scenes with area lights such as rectangular fluorescent lighting panels, which are difficult for rasterization and traditional ray tracing. Radiosity is considered a physically-based method, meaning that it aims to simulate the flow of light in an environment using equations and experimental data from physics, however it often assumes that all surfaces are opaque and perfectly Lambertian, which reduces realism and limits its applicability.: 10, 11.2.1 : 888, 893 : 6  In the original radiosity method (first proposed in 1984) now called classical radiosity, surfaces and lights in the scene are split into pieces called patches, a process called meshing (this step makes it a finite element method). The rendering code must then determine what fraction of the light being emitted or diffusely reflected (scattered) by each patch is received by each other patch. These fractions are called form factors or view factors (first used in engineering to model radiative heat transfer). The form factors are multiplied by the albedo of the receiving surface and put in a matrix. The lighting in the scene can then be expressed as a matrix equation (or equivalently a system of linear equations) that can be solved by methods from linear algebra.: 46 : 888, 896  Solving the radiosity equation gives the total amount of light emitted and reflected by each patch, which is divided by area to get a value called radiosity that can be used when rasterizing or ray tracing to determine the color of pixels corresponding to visible parts of the patch. For real-time rendering, this value (or more commonly the irradiance, which does not depend on local surface albedo) can be pre-computed and stored in a texture (called an irradiance map) or stored as vertex data for 3D models. This feature was used in architectural visualization software to allow real-time walk-throughs of a building interior after computing the lighting.: 890 : 11.5.1 : 332  The large size of the matrices used in classical radiosity (the square of the number of patches) causes problems for realistic scenes. Practical implementations may use Jacobi or Gauss-Seidel iterations, which is equivalent (at least in the Jacobi case) to simulating the propagation of light one bounce at a time until the amount of light remaining (not yet absorbed by surfaces) is insignificant. The number of iterations (bounces) required is dependent on the scene, not the number of patches, so the total work is proportional to the square of the number of patches (in contrast, solving the matrix equation using Gaussian elimination requires work proportional to the cube of the number of patches). Form factors may be recomputed when they are needed, to avoid storing a complete matrix in memory.: 901, 907  The quality of rendering is often determined by the size of the patches, e.g. very fine meshes are needed to depict the edges of shadows accurately. An important improvement is hierarchical radiosity, which uses a coarser mesh (larger patches) for simulating the transfer of light between surfaces that are far away from one another, and adaptively sub-divides the patches as needed. This allows radiosity to be used for much larger and more complex scenes.: 975, 939  Alternative and extended versions of the radiosity method support non-Lambertian surfaces, such as glossy surfaces and mirrors, and sometimes use volumes or "clusters" of objects as well as surface patches. Stochastic or Monte Carlo radiosity uses random sampling in various ways, e.g. taking samples of incident light instead of integrating over all patches, which can improve performance but adds noise (this noise can be reduced by using deterministic iterations as a final step, unlike path tracing noise). Simplified and partially precomputed versions of radiosity are widely used for real-time rendering, combined with techniques such as octree radiosity that store approximations of the light field.: 979, 982 : 49 : 11.5  === Path tracing === As part of the approach known as physically based rendering, path tracing has become the dominant technique for rendering realistic scenes, including effects for movies. For example, the popular open source 3D software Blender uses path tracing in its Cycles renderer. Images produced using path tracing for global illumination are generally noisier than when using radiosity (the main competing algorithm for realistic lighting), but radiosity can be difficult to apply to complex scenes and is prone to artifacts that arise from using a tessellated representation of irradiance.: 975-976, 1045  Like distributed ray tracing, path tracing is a kind of stochastic or randomized ray tracing that uses Monte Carlo or Quasi-Monte Carlo integration. It was proposed and named in 1986 by Jim Kajiya in the same paper as the rendering equation. Kajiya observed that much of the complexity of distributed ray tracing could be avoided by only tracing a single path from the camera at a time (in Kajiya's implementation, this "no branching" rule was broken by tracing additional rays from each surface intersection point to randomly chosen points on each light source). Kajiya suggested reducing the noise present in the output images by using stratified sampling and importance sampling for making random decisions such as choosing which ray to follow at each step of a path. Even with these techniques, path tracing would not have been practical for film rendering, using computers available at the time, because the computational cost of generating enough samples to reduce variance to an acceptable level was too high. Monster House, the first feature film rendered entirely using path tracing, was not released until 20 years later. In its basic form, path tracing is inefficient (requiring too many samples) for rendering caustics and scenes where light enters indirectly through narrow spaces. Attempts were made to address these weaknesses in the 1990s. Bidirectional path tracing has similarities to photon mapping, tracing rays from the light source and the camera separately, and then finding ways to connect these paths (but unlike photon mapping it usually samples new light paths for each pixel rather than using the same cached data for all pixels). Metropolis light transport samples paths by modifying paths that were previously traced, spending more time exploring paths that are similar to other "bright" paths, which increases the chance of discovering even brighter paths. Multiple importance sampling provides a way to reduce variance when combining samples from more than one sampling method, particularly when some samples are much noisier than the others. This later work was summarized and expanded upon in Eric Veach's 1997 PhD thesis, which helped raise interest in path tracing in the computer graphics community. The Arnold renderer, first released in 1998, proved that path tracing was practical for rendering frames for films, and that there was a demand for unbiased and physically based rendering in the film industry; other commercial and open source path tracing renderers began appearing. Computational cost was addressed by rapid advances in CPU and cluster performance. Path tracing's relative simplicity and its nature as a Monte Carlo method (sampling hundreds or thousands of paths per pixel) have made it attractive to implement on a GPU, especially on recent GPUs that support ray tracing acceleration technology such as Nvidia's RTX and OptiX. However bidirectional path tracing and Metropolis light transport are more difficult to implement efficiently on a GPU. Research into improving path tracing continues. Many variations of bidirectional path tracing and Metropolis light transport have been explored, and ways of combining path tracing with photon mapping. Recent path guiding approaches construct approximations of the light field probability distribution in each volume of space, so paths can be sampled more effectively. Techniques have been developed to denoise the output of path tracing, reducing the number of paths required to achieve acceptable quality, at the risk of losing some detail or introducing small-scale artifacts that are more objectionable than noise; neural networks are now widely used for this purpose. === Neural rendering === Neural rendering is a rendering method using artificial neural networks. Neural rendering includes image-based rendering methods that are used to reconstruct 3D models from 2-dimensional images. One of these methods are photogrammetry, which is a method in which a collection of images from multiple angles of an object are turned into a 3D model. There have also been recent developments in generating and rendering 3D models from text and coarse paintings by notably Nvidia, Google and various other companies. == Scientific and mathematical basis == The implementation of a realistic renderer always has some basic element of physical simulation or emulation – some computation which resembles or abstracts a real physical process. The term "physically based" indicates the use of physical models and approximations that are more general and widely accepted outside rendering. A particular set of related techniques have gradually become established in the rendering community. The basic concepts are moderately straightforward, but intractable to calculate; and a single elegant algorithm or approach has been elusive for more general purpose renderers. In order to meet demands of robustness, accuracy and practicality, an implementation will be a complex combination of different techniques. Rendering research is concerned with both the adaptation of scientific models and their efficient application. Mathematics used in rendering includes: linear algebra, calculus, numerical mathematics, signal processing, and Monte Carlo methods. === The rendering equation === This is the key academic/theoretical concept in rendering. It serves as the most abstract formal expression of the non-perceptual aspect of rendering. All more complete algorithms can be seen as solutions to particular formulations of this equation. L o ( x , ω ) = L e ( x , ω ) + ∫ Ω L i ( x , ω ′ ) f r ( x , ω ′ , ω ) ( ω ′ ⋅ n ) d ω ′ {\displaystyle L_{o}(x,\omega )=L_{e}(x,\omega )+\int _{\Omega }L_{i}(x,\omega ')f_{r}(x,\omega ',\omega )(\omega '\cdot n)\,\mathrm {d} \omega '} Meaning: at a particular position and direction, the outgoing light (Lo) is the sum of the emitted light (Le) and the reflected light. The reflected light being the sum of the incoming light (Li) from all directions, multiplied by the surface reflection and incoming angle. By connecting outward light to inward light, via an interaction point, this equation stands for the whole 'light transport' – all the movement of light – in a scene. === The bidirectional reflectance distribution function === The bidirectional reflectance distribution function (BRDF) expresses a simple model of light interaction with a surface as follows: f r ( x , ω ′ , ω ) = d L r ( x , ω ) L i ( x , ω ′ ) ( ω ′ ⋅ n → ) d ω ′ {\displaystyle f_{r}(x,\omega ',\omega )={\frac {\mathrm {d} L_{r}(x,\omega )}{L_{i}(x,\omega ')(\omega '\cdot {\vec {n}})\mathrm {d} \omega '}}} Light interaction is often approximated by the even simpler models: diffuse reflection and specular reflection, although both can ALSO be BRDFs. === Geometric optics === Rendering is practically exclusively concerned with the particle aspect of light physics – known as geometrical optics. Treating light, at its basic level, as particles bouncing around is a simplification, but appropriate: the wave aspects of light are negligible in most scenes, and are significantly more difficult to simulate. Notable wave aspect phenomena include diffraction (as seen in the colours of CDs and DVDs) and polarisation (as seen in LCDs). Both types of effect, if needed, are made by appearance-oriented adjustment of the reflection model. === Visual perception === Though it receives less attention, an understanding of human visual perception is valuable to rendering. This is mainly because image displays and human perception have restricted ranges. A renderer can simulate a wide range of light brightness and color, but current displays – movie screen, computer monitor, etc. – cannot handle so much, and something must be discarded or compressed. Human perception also has limits, and so does not need to be given large-range images to create realism. This can help solve the problem of fitting images into displays, and, furthermore, suggest what short-cuts could be used in the rendering simulation, since certain subtleties will not be noticeable. This related subject is tone mapping. === Sampling and filtering === One problem that any rendering system must deal with, no matter which approach it takes, is the sampling problem. Essentially, the rendering process tries to depict a continuous function from image space to colors by using a finite number of pixels. As a consequence of the Nyquist–Shannon sampling theorem (or Kotelnikov theorem), any spatial waveform that can be displayed must consist of at least two pixels, which is proportional to image resolution. In simpler terms, this expresses the idea that an image cannot display details, peaks or troughs in color or intensity, that are smaller than one pixel. If a naive rendering algorithm is used without any filtering, high frequencies in the image function will cause ugly aliasing to be present in the final image. Aliasing typically manifests itself as jaggies, or jagged edges on objects where the pixel grid is visible. In order to remove aliasing, all rendering algorithms (if they are to produce good-looking images) must use some kind of low-pass filter on the image function to remove high frequencies, a process called antialiasing. == Hardware == Rendering is usually limited by available computing power and memory bandwidth, and so specialized hardware has been developed to speed it up ("accelerate" it), particularly for real-time rendering. Hardware features such as a framebuffer for raster graphics are required to display the output of rendering smoothly in real time. === History === In the era of vector monitors (also called calligraphic displays), a display processing unit (DPU) was a dedicated CPU or coprocessor that maintained a list of visual elements and redrew them continuously on the screen by controlling an electron beam. Advanced DPUs such as Evans & Sutherland's Line Drawing System-1 (and later models produced into the 1980s) incorporated 3D coordinate transformation features to accelerate rendering of wire-frame images.: 93–94, 404–421  Evans & Sutherland also made the Digistar planetarium projection system, which was a vector display that could render both stars and wire-frame graphics (the vector-based Digistar and Digistar II were used in many planetariums, and a few may still be in operation). A Digistar prototype was used for rendering 3D star fields for the film Star Trek II: The Wrath of Khan – some of the first 3D computer graphics sequences ever seen in a feature film. Shaded 3D graphics rendering in the 1970s and early 1980s was usually implemented on general-purpose computers, such as the PDP-10 used by researchers at the University of Utah. It was difficult to speed up using specialized hardware because it involves a pipeline of complex steps, requiring data addressing, decision-making, and computation capabilities typically only provided by CPUs (although dedicated circuits for speeding up particular operations were proposed ). Supercomputers or specially designed multi-CPU computers or clusters were sometimes used for ray tracing. In 1981, James H. Clark and Marc Hannah designed the Geometry Engine, a VLSI chip for performing some of the steps of the 3D rasterization pipeline, and started the company Silicon Graphics (SGI) to commercialize this technology. Home computers and game consoles in the 1980s contained graphics coprocessors that were capable of scrolling and filling areas of the display, and drawing sprites and lines, though they were not useful for rendering realistic images. Towards the end of the 1980s PC graphics cards and arcade games with 3D rendering acceleration began to appear, and in the 1990s such technology became commonplace. Today, even low-power mobile processors typically incorporate 3D graphics acceleration features. === GPUs === The 3D graphics accelerators of the 1990s evolved into modern GPUs. GPUs are general-purpose processors, like CPUs, but they are designed for tasks that can be broken into many small, similar, mostly independent sub-tasks (such as rendering individual pixels) and performed in parallel. This means that a GPU can speed up any rendering algorithm that can be split into subtasks in this way, in contrast to 1990s 3D accelerators which were only designed to speed up specific rasterization algorithms and simple shading and lighting effects (although tricks could be used to perform more general computations).: ch3  Due to their origins, GPUs typically still provide specialized hardware acceleration for some steps of a traditional 3D rasterization pipeline, including hidden surface removal using a z-buffer, and texture mapping with mipmaps, but these features are no longer always used.: ch3  Recent GPUs have features to accelerate finding the intersections of rays with a bounding volume hierarchy, to help speed up all variants of ray tracing and path tracing, as well as neural network acceleration features sometimes useful for rendering. GPUs are usually integrated with high-bandwidth memory systems to support the read and write bandwidth requirements of high-resolution, real-time rendering, particularly when multiple passes are required to render a frame, however memory latency may be higher than on a CPU, which can be a problem if the critical path in an algorithm involves many memory accesses. GPU design accepts high latency as inevitable (in part because a large number of threads are sharing the memory bus) and attempts to "hide" it by efficiently switching between threads, so a different thread can be performing computations while the first thread is waiting for a read or write to complete.: ch3  Rendering algorithms will run efficiently on a GPU only if they can be implemented using small groups of threads that perform mostly the same operations. As an example of code that meets this requirement: when rendering a small square of pixels in a simple ray-traced image, all threads will likely be intersecting rays with the same object and performing the same lighting computations. For performance and architectural reasons, GPUs run groups of around 16-64 threads called warps or wavefronts in lock-step (all threads in the group are executing the same instructions at the same time). If not all threads in the group need to run particular blocks of code (due to conditions) then some threads will be idle, or the results of their computations will be discarded, causing degraded performance.: ch3  == Chronology of algorithms and techniques == The following is a rough timeline of frequently mentioned rendering techniques, including areas of current research. Note that even in cases where an idea was named in a specific paper, there were almost always multiple researchers or teams working in the same area (including earlier related work). When a method is first proposed it is often very inefficient, and it takes additional research and practical efforts to turn it into a useful technique.: 887  The list focuses on academic research and does not include hardware. (For more history see #External links, as well as Computer graphics#History and Golden age of arcade video games#Technology.) == See also == == References == == Further reading == == External links == SIGGRAPH – the ACMs special interest group in graphics – the largest academic and professional association and conference vintage3d.org "The way to home 3d" – Extensive history of computer graphics hardware, including research, commercialization, and video games and consoles
Wikipedia/Rendering_(computer_graphics)
A network scheduler, also called packet scheduler, queueing discipline (qdisc) or queueing algorithm, is an arbiter on a node in a packet switching communication network. It manages the sequence of network packets in the transmit and receive queues of the protocol stack and network interface controller. There are several network schedulers available for the different operating systems, that implement many of the existing network scheduling algorithms. The network scheduler logic decides which network packet to forward next. The network scheduler is associated with a queuing system, storing the network packets temporarily until they are transmitted. Systems may have a single or multiple queues in which case each may hold the packets of one flow, classification, or priority. In some cases it may not be possible to schedule all transmissions within the constraints of the system. In these cases the network scheduler is responsible for deciding which traffic to forward and what gets dropped. == Terminology and responsibilities == A network scheduler may have responsibility in implementation of specific network traffic control initiatives. Network traffic control is an umbrella term for all measures aimed at reducing network congestion, latency and packet loss. Specifically, active queue management (AQM) is the selective dropping of queued network packets to achieve the larger goal of preventing excessive network congestion. The scheduler must choose which packets to drop. Traffic shaping smooths the bandwidth requirements of traffic flows by delaying transmission packets when they are queued in bursts. The scheduler decides the timing for the transmitted packets. Quality of service (QoS) is the prioritization of traffic based on service class (Differentiated services) or reserved connection (Integrated services). == Algorithms == In the course of time, many network queueing disciplines have been developed. Each of these provides specific reordering or dropping of network packets inside various transmit or receive buffers. Queuing disciplines are commonly used as attempts to compensate for various networking conditions, like reducing the latency for certain classes of network packets, and are generally used as part of QoS measures. Classful queueing disciplines allow the creation of classes, which work like branches on a tree. Rules can then be set to filter packets into each class. Each class can itself have assigned other classful or classless queueing discipline. Classless queueing disciplines do not allow adding more queueing disciplines to it. Examples of algorithms suitable for managing network traffic include: Several of the above have been implemented as Linux kernel modules and are freely available. == Bufferbloat == Bufferbloat is a phenomenon in packet-switched networks in which excess buffering of packets causes high latency and packet delay variation. Bufferbloat can be addressed by a network scheduler that strategically discards packets to avoid an unnecessarily high buffering backlog. Examples include CoDel, FQ-CoDel and random early detection. == Implementations == === Linux kernel === The Linux kernel packet scheduler is an integral part of the Linux kernel's network stack and manages the transmit and receive ring buffers of all NICs. The packet scheduler is configured using the utility called tc (short for traffic control). As the default queuing discipline, the packet scheduler uses a FIFO implementation called pfifo_fast, although systemd since its version 217 changes the default queuing discipline to fq_codel. The ifconfig and ip utilities enable system administrators to configure the buffer sizes txqueuelen and rxqueuelen for each device separately in terms of number of Ethernet frames regardless of their size. The Linux kernel's network stack contains several other buffers, which are not managed by the network scheduler. Berkeley Packet Filter filters can be attached to the packet scheduler's classifiers. The eBPF functionality brought by version 4.1 of the Linux kernel in 2015 extends the classic BPF programmable classifiers to eBPF. These can be compiled using the LLVM eBPF backend and loaded into a running kernel using the tc utility. === BSD and OpenBSD === ALTQ is the implementation of a network scheduler for BSDs. As of OpenBSD version 5.5 ALTQ was replaced by the HFSC scheduler. === Cell-Free Network Scheduling === Schedulers in communication networks manage resource allocation, including packet prioritization, timing, and resource distribution. Advanced implementations increasingly leverage artificial intelligence to address the complexities of modern network configurations. For instance, a supervised neural network (NN)-based scheduler has been introduced in cell-free networks to efficiently handle interactions between multiple radio units (RUs) and user equipment (UEs). This approach reduces computational complexity while optimizing latency, throughput, and resource allocation, making it a promising solution for beyond-5G networks. == See also == Queueing theory Statistical time-division multiplexing Type of service == Notes == == References ==
Wikipedia/Network_scheduler
In mathematical logic, a theory is complete if it is consistent and for every closed formula in the theory's language, either that formula or its negation is provable. That is, for every sentence φ , {\displaystyle \varphi ,} the theory T {\displaystyle T} contains the sentence or its negation but not both (that is, either T ⊢ φ {\displaystyle T\vdash \varphi } or T ⊢ ¬ φ {\displaystyle T\vdash \neg \varphi } ). Recursively axiomatizable first-order theories that are consistent and rich enough to allow general mathematical reasoning to be formulated cannot be complete, as demonstrated by Gödel's first incompleteness theorem. This sense of complete is distinct from the notion of a complete logic, which asserts that for every theory that can be formulated in the logic, all semantically valid statements are provable theorems (for an appropriate sense of "semantically valid"). Gödel's completeness theorem is about this latter kind of completeness. Complete theories are closed under a number of conditions internally modelling the T-schema: For a set of formulas S {\displaystyle S} : A ∧ B ∈ S {\displaystyle A\land B\in S} if and only if A ∈ S {\displaystyle A\in S} and B ∈ S {\displaystyle B\in S} , For a set of formulas S {\displaystyle S} : A ∨ B ∈ S {\displaystyle A\lor B\in S} if and only if A ∈ S {\displaystyle A\in S} or B ∈ S {\displaystyle B\in S} . Maximal consistent sets are a fundamental tool in the model theory of classical logic and modal logic. Their existence in a given case is usually a straightforward consequence of Zorn's lemma, based on the idea that a contradiction involves use of only finitely many premises. In the case of modal logics, the collection of maximal consistent sets extending a theory T (closed under the necessitation rule) can be given the structure of a model of T, called the canonical model. == Examples == Some examples of complete theories are: Presburger arithmetic Tarski's axioms for Euclidean geometry The theory of dense linear orders without endpoints The theory of algebraically closed fields of a given characteristic The theory of real closed fields Every uncountably categorical countable theory Every countably categorical countable theory A group of three elements True arithmetic or any other elementary diagram == See also == Lindenbaum's lemma Łoś–Vaught test == References == Mendelson, Elliott (1997). Introduction to Mathematical Logic (Fourth ed.). Chapman & Hall. p. 86. ISBN 978-0-412-80830-2.
Wikipedia/Complete_theory
A semantic theory of truth is a theory of truth in the philosophy of language which holds that truth is a property of sentences. == Origin == The semantic conception of truth, which is related in different ways to both the correspondence and deflationary conceptions, is due to work by Polish logician Alfred Tarski. Tarski, in "On the Concept of Truth in Formal Languages" (1935), attempted to formulate a new theory of truth in order to resolve the liar paradox. In the course of this he made several metamathematical discoveries, most notably Tarski's undefinability theorem using the same formal technique Kurt Gödel used in his incompleteness theorems. Roughly, this states that a truth-predicate satisfying Convention T for the sentences of a given language cannot be defined within that language. == Tarski's theory of truth == To formulate linguistic theories without semantic paradoxes such as the liar paradox, it is generally necessary to distinguish the language that one is talking about (the object language) from the language that one is using to do the talking (the metalanguage). In the following, quoted text is use of the object language, while unquoted text is use of the metalanguage; a quoted sentence (such as "P") is always the metalanguage's name for a sentence, such that this name is simply the sentence P rendered in the object language. In this way, the metalanguage can be used to talk about the object language; Tarski's theory of truth (Alfred Tarski 1935) demanded that the object language be contained in the metalanguage. Tarski's material adequacy condition, also known as Convention T, holds that any viable theory of truth must entail, for every sentence "P", a sentence of the following form (known as "form (T)"): (1) "P" is true if, and only if, P. For example, (2) 'snow is white' is true if and only if snow is white. These sentences (1 and 2, etc.) have come to be called the "T-sentences". The reason they look trivial is that the object language and the metalanguage are both English; here is an example where the object language is German and the metalanguage is English: (3) 'Schnee ist weiß' is true if and only if snow is white. It is important to note that as Tarski originally formulated it, this theory applies only to formal languages, cf. also semantics of first-order logic. He gave a number of reasons for not extending his theory to natural languages, including the problem that there is no systematic way of deciding whether a given sentence of a natural language is well-formed, and that a natural language is closed (that is, it can describe the semantic characteristics of its own elements). But Tarski's approach was extended by Davidson into an approach to theories of meaning for natural languages, which involves treating "truth" as a primitive, rather than a defined, concept. (See truth-conditional semantics.) Tarski developed the theory to give an inductive definition of truth as follows. (See T-schema) For a language L containing ¬ ("not"), ∧ ("and"), ∨ ("or"), ∀ ("for all"), and ∃ ("there exists"), Tarski's inductive definition of truth looks like this: (1) A primitive statement "A" is true if, and only if, A. (2) "¬A" is true if, and only if, "A" is not true. (3) "A∧B" is true if, and only if, "A" is true and "B" is true. (4) "A∨B" is true if, and only if, "A" is true or "B" is true or ("A" is true and "B" is true). (5) "∀x(Fx)" is true if, and only if, for all objects x, "Fx" is true. (6) "∃x(Fx)" is true if, and only if, there is an object x for which "Fx" is true. These explain how the truth conditions of complex sentences (built up from connectives and quantifiers) can be reduced to the truth conditions of their constituents. The simplest constituents are atomic sentences. A contemporary semantic definition of truth would define truth for the atomic sentences as follows: An atomic sentence F(x1,...,xn) is true (relative to an assignment of values to the variables x1, ..., xn)) if the corresponding values of variables bear the relation expressed by the predicate F. Tarski himself defined truth for atomic sentences in a variant way that does not use any technical terms from semantics, such as the "expressed by" above. This is because he wanted to define these semantic terms in the context of truth. Therefore it would be circular to use one of them in the definition of truth itself. Tarski's semantic conception of truth plays an important role in modern logic and also in contemporary philosophy of language. It is a rather controversial point whether Tarski's semantic theory should be counted either as a correspondence theory or as a deflationary theory. == Kripke's theory of truth == Kripke's theory of truth (Saul Kripke 1975) is based on partial logic (a logic of partially defined truth predicates instead of Tarski's logic of totally defined truth predicates) with the strong Kleene evaluation scheme. == See also == Disquotational principle Semantics of logic T-schema Triune continuum paradigm == References == == Further reading == Simon Blackburn and Keith Simmons, eds., 1999. Truth. Oxford University Press, ISBN 0-19-875250-4. Michael K Butler, 2017. Deflationism and Semantic Theories of Truth. Pendlebury Press, ISBN 0993594549. Wilfrid Hodges, 2001. Tarski's truth definitions. In the Stanford Encyclopedia of Philosophy. Richard Kirkham, 1992. Theories of Truth. Bradford Books, ISBN 0-262-61108-2. Saul Kripke, 1975. "Outline of a Theory of Truth". Journal of Philosophy, 72: 690–716. Alfred Tarski, 1935. "The Concept of Truth in Formalized Languages". Logic, Semantics, Metamathematics, Indianapolis: Hackett 1983, 2nd edition, 152–278. Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4. == External links == Semantic Theory of Truth, Internet Encyclopedia of Philosophy Tarski's Truth Definitions (an entry of Stanford Encyclopedia of Philosophy) Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4.
Wikipedia/Semantic_theory_of_truth
Finite model theory is a subarea of model theory. Model theory is the branch of logic which deals with the relation between a formal language (syntax) and its interpretations (semantics). Finite model theory is a restriction of model theory to interpretations on finite structures, which have a finite universe. Since many central theorems of model theory do not hold when restricted to finite structures, finite model theory is quite different from model theory in its methods of proof. Central results of classical model theory that fail for finite structures under finite model theory include the compactness theorem, Gödel's completeness theorem, and the method of ultraproducts for first-order logic (FO). These invalidities all follow from Trakhtenbrot's theorem. While model theory has many applications to mathematical algebra, finite model theory became an "unusually effective" instrument in computer science. In other words: "In the history of mathematical logic most interest has concentrated on infinite structures. [...] Yet, the objects computers have and hold are always finite. To study computation we need a theory of finite structures." Thus the main application areas of finite model theory are: descriptive complexity theory, database theory and formal language theory. == Axiomatisability == A common motivating question in finite model theory is whether a given class of structures can be described in a given language. For instance, one might ask whether the class of cyclic graphs can be distinguished among graphs by a FO sentence, which can also be phrased as asking whether cyclicity is FO-expressible. A single finite structure can always be axiomatized in first-order logic, where axiomatized in a language L means described uniquely up to isomorphism by a single L-sentence. Similarly, any finite collection of finite structures can always be axiomatized in first-order logic. Some, but not all, infinite collections of finite structures can also be axiomatized by a single first-order sentence. === Characterisation of a single structure === Is a language L expressive enough to axiomatize a single finite structure S? ==== Problem ==== A structure like (1) in the figure can be described by FO sentences in the logic of graphs like Every node has an edge to another node: ∀ x ∃ y G ( x , y ) . {\displaystyle \forall _{x}\exists _{y}G(x,y).} No node has an edge to itself: ∀ x , y ( G ( x , y ) ⇒ x ≠ y ) . {\displaystyle \forall _{x,y}(G(x,y)\Rightarrow x\neq y).} There is at least one node that is connected to all others: ∃ x ∀ y ( x ≠ y ⇒ G ( x , y ) ) . {\displaystyle \exists _{x}\forall _{y}(x\neq y\Rightarrow G(x,y)).} However, these properties do not axiomatize the structure, since for structure (1') the above properties hold as well, yet structures (1) and (1') are not isomorphic. Informally the question is whether by adding enough properties, these properties together describe exactly (1) and are valid (all together) for no other structure (up to isomorphism). ==== Approach ==== For a single finite structure it is always possible to precisely describe the structure by a single FO sentence. The principle is illustrated here for a structure with one binary relation R {\displaystyle R} and without constants: say that there are at least n {\displaystyle n} elements: φ 1 = ⋀ i ≠ j ¬ ( x i = x j ) {\displaystyle \varphi _{1}=\bigwedge _{i\neq j}\neg (x_{i}=x_{j})} say that there are at most n {\displaystyle n} elements: φ 2 = ∀ y ⋁ i ( x i = y ) {\displaystyle \varphi _{2}=\forall _{y}\bigvee _{i}(x_{i}=y)} state every element of the relation R {\displaystyle R} : φ 3 = ⋀ ( a i , a j ) ∈ R R ( x i , x j ) {\displaystyle \varphi _{3}=\bigwedge _{(a_{i},a_{j})\in R}R(x_{i},x_{j})} state every non-element of the relation R {\displaystyle R} : φ 4 = ⋀ ( a i , a j ) ∉ R ¬ R ( x i , x j ) {\displaystyle \varphi _{4}=\bigwedge _{(a_{i},a_{j})\notin R}\neg R(x_{i},x_{j})} all for the same tuple x 1 . . x n {\displaystyle x_{1}..x_{n}} , yielding the FO sentence ∃ x 1 … ∃ x n ( φ 1 ∧ φ 2 ∧ φ 3 ∧ φ 4 ) {\displaystyle \exists _{x_{1}}\dots \exists _{x_{n}}(\varphi _{1}\land \varphi _{2}\land \varphi _{3}\land \varphi _{4})} . ==== Extension to a fixed number of structures ==== The method of describing a single structure by means of a first-order sentence can easily be extended for any fixed number of structures. A unique description can be obtained by the disjunction of the descriptions for each structure. For instance, for two structures A {\displaystyle A} and B {\displaystyle B} with defining sentences φ A {\displaystyle \varphi _{A}} and φ B {\displaystyle \varphi _{B}} this would be φ A ∨ φ B . {\displaystyle \varphi _{A}\lor \varphi _{B}.} ==== Extension to an infinite structure ==== By definition, a set containing an infinite structure falls outside the area that FMT deals with. Note that infinite structures can never be discriminated in FO, because of the Löwenheim–Skolem theorem, which implies that no first-order theory with an infinite model can have a unique model up to isomorphism. The most famous example is probably Skolem's theorem, that there is a countable non-standard model of arithmetic. === Characterisation of a class of structures === Is a language L expressive enough to describe exactly (up to isomorphism) those finite structures that have certain property P? ==== Problem ==== The descriptions given so far all specify the number of elements of the universe. Unfortunately most interesting sets of structures are not restricted to a certain size, like all graphs that are trees, are connected or are acyclic. Thus to discriminate a finite number of structures is of special importance. ==== Approach ==== Instead of a general statement, the following is a sketch of a methodology to differentiate between structures that can and cannot be discriminated. ==== Example ==== We want to show that the property that the size of an ordered structure A = (A, ≤) is even, can not be expressed in FO. The idea is to pick A ∈ EVEN and B ∉ EVEN, where EVEN is the class of all structures of even size. We start with two ordered structures A2 and B2 with universes A2 = {1, 2, 3, 4} and B2 = {1, 2, 3}. Obviously A2 ∈ EVEN and B2 ∉ EVEN. For m = 2, we can now show* that in a 2-move Ehrenfeucht–Fraïssé game on A2 and B2 the duplicator always wins, and thus A2 and B2 cannot be discriminated in FO[2], i.e. A 2 ⊨ α ⟺ B 2 ⊨ α {\displaystyle \mathbf {A} _{2}\models \alpha \iff \mathbf {B} _{2}\models \alpha } for every α ∈ FO[2]. Next we have to scale the structures up by increasing m. For example, for m = 3 we must find an A3 and B3 such that the duplicator always wins the 3-move game. This can be achieved by A3 = {1, ..., 8} and B3 = {1, ..., 7}. More generally, we can choose Am = {1, ..., 2m} and Bm = {1, ..., 2m−1}; for any m the duplicator always wins the m-move game for this pair of structures*. Thus EVEN on finite ordered structures cannot be expressed in FO. (*) Note that the proof of the result of the Ehrenfeucht–Fraïssé game has been omitted, since it is not the main focus here. == Zero-one laws == Glebskiĭ et al. (1969) and, independently, Fagin (1976) proved a zero–one law for first-order sentences in finite models; Fagin's proof used the compactness theorem. According to this result, every first-order sentence in a relational signature σ {\displaystyle \sigma } is either almost always true or almost always false in finite σ {\displaystyle \sigma } -structures. That is, let S be a fixed first-order sentence, and choose a random σ {\displaystyle \sigma } -structure G n {\displaystyle G_{n}} with domain { 1 , … , n } {\displaystyle \{1,\dots ,n\}} , uniformly among all σ {\displaystyle \sigma } -structures with domain { 1 , … , n } {\displaystyle \{1,\dots ,n\}} . Then in the limit as n tends to infinity, the probability that Gn models S will tend either to zero or to one: lim n → ∞ Pr ⁡ [ G n ⊨ S ] ∈ { 0 , 1 } . {\displaystyle \lim _{n\to \infty }\operatorname {Pr} [G_{n}\models S]\in \{0,1\}.} The problem of determining whether a given sentence has probability tending to zero or to one is PSPACE-complete. A similar analysis has been performed for more expressive logics than first-order logic. The 0-1 law has been shown to hold for sentences in FO(LFP), first-order logic augmented with a least fixed point operator, and more generally for sentences in the infinitary logic L ∞ ω ω {\displaystyle L_{\infty \omega }^{\omega }} , which allows for potentially arbitrarily long conjunctions and disjunctions. Another important variant is the unlabelled 0-1 law, where instead of considering the fraction of structures with domain { 1 , … , n } {\displaystyle \{1,\dots ,n\}} , one considers the fraction of isomorphism classes of structures with n elements. This fraction is well-defined, since any two isomorphic structures satisfy the same sentences. The unlabelled 0-1 law also holds for L ∞ ω ω {\displaystyle L_{\infty \omega }^{\omega }} and therefore in particular for FO(LFP) and first-order logic. == Descriptive complexity theory == An important goal of finite model theory is the characterisation of complexity classes by the type of logic needed to express the languages in them. For example, PH, the union of all complexity classes in the polynomial hierarchy, is precisely the class of languages expressible by statements of second-order logic. This connection between complexity and the logic of finite structures allows results to be transferred easily from one area to the other, facilitating new proof methods and providing additional evidence that the main complexity classes are somehow "natural" and not tied to the specific abstract machines used to define them. Specifically, each logical system produces a set of queries expressible in it. The queries – when restricted to finite structures – correspond to the computational problems of traditional complexity theory. Some well-known complexity classes are captured by logical languages as follows: In the presence of a linear order, first-order logic with a commutative, transitive closure operator added yields L, problems solvable in logarithmic space. In the presence of a linear order, first-order logic with a transitive closure operator yields NL, the problems solvable in nondeterministic logarithmic space. In the presence of a linear order, first-order logic with a least fixed point operator gives P, the problems solvable in deterministic polynomial time. On all finite structures (regardless of whether they are ordered), Existential second-order logic gives NP (Fagin's theorem). == Applications == === Database theory === A substantial fragment of SQL (namely that which is effectively relational algebra) is based on first-order logic (more precisely can be translated in domain relational calculus by means of Codd's theorem), as the following example illustrates: Think of a database table "GIRLS" with the columns "FIRST_NAME" and "LAST_NAME". This corresponds to a binary relation, say G(f, l) on FIRST_NAME × LAST_NAME. The FO query l : G ( 'Judy' , l ) {\displaystyle {l:G({\text{'Judy'}},l)}} , which returns all the last names where the first name is 'Judy', would look in SQL like this: Notice, we assume here, that all last names appear only once (or we should use SELECT DISTINCT since we assume that relations and answers are sets, not bags). Next we want to make a more complex statement. Therefore, in addition to the "GIRLS" table we have a table "BOYS" also with the columns "FIRST_NAME" and "LAST_NAME". Now we want to query the last names of all the girls that have the same last name as at least one of the boys. The FO query is ( f , l ) : ∃ h ( G ( f , l ) ∧ B ( h , l ) ) {\displaystyle {(f,l):\exists h(G(f,l)\land B(h,l))}} , and the corresponding SQL statement is: Notice that in order to express the "∧" we introduced the new language element "IN" with a subsequent select statement. This makes the language more expressive for the price of higher difficulty to learn and implement. This is a common trade-off in formal language design. The way shown above ("IN") is by far not the only one to extend the language. An alternative way is e.g. to introduce a "JOIN" operator, that is: First-order logic is too restrictive for some database applications, for instance because of its inability to express transitive closure. This has led to more powerful constructs being added to database query languages, such as recursive WITH in SQL:1999. More expressive logics, like fixpoint logics, have therefore been studied in finite model theory because of their relevance to database theory and applications. === Querying and search === Narrative data contains no defined relations. Thus the logical structure of text search queries can be expressed in propositional logic, like in: ("Java" AND NOT "island") OR ("C#" AND NOT "music") Note that the challenges in full text search are different from database querying, like ranking of results. == History == Trakhtenbrot 1950: failure of completeness theorem in first-order logic Scholz 1952: characterisation of spectra in first-order logic Fagin 1974: the set of all properties expressible in existential second-order logic is precisely the complexity class NP Chandra, Harel 1979/80: fixed-point first-order logic extension for database query languages capable of expressing transitive closure -> queries as central objects of FMT Immerman, Vardi 1982: fixed-point logic over ordered structures captures PTIME -> descriptive complexity (Immerman–Szelepcsényi theorem) Ebbinghaus, Flum 1995: first comprehensive book "Finite Model Theory" Abiteboul, Hull, Vianu 1995: book "Foundations of Databases" Immerman 1999: book "Descriptive Complexity" Kuper, Libkin, Paredaens 2000: book "Constraint Databases" Darmstadt 2005/ Aachen 2006: first international workshops on "Algorithmic Model Theory" == Citations == == References == Ebbinghaus, Heinz-Dieter; Flum, Jörg (1995). Finite Model Theory. Springer. ISBN 978-3-540-60149-4. Fagin, Ronald (1976). "Probabilities on Finite Models". The Journal of Symbolic Logic. 41 (1): 50–58. doi:10.2307/2272945. JSTOR 2272945. Glebskiĭ, Yu V.; Kogan, D. I.; Liogon'kiĭ, M. I.; Talanov, V. A. (1969). "Объем и доля выполнимости формул узкого исчисления предикатов" [Volume and fraction of satisfiability of formulae of the first-order predicate calculus]. Kibernetika. 5 (2): 17–27. Also available as;"Range and degree of realizability of formulas in the restricted predicate calculus". Cybernetics. 5 (2): 142–154. 1972. doi:10.1007/BF01071084. Libkin, Leonid (2004). Elements of Finite Model Theory. Springer. ISBN 3-540-21202-7. Abiteboul, Serge; Hull, Richard; Vianu, Victor (1995). Foundations of Databases. Addison-Wesley. ISBN 0-201-53771-0. Immerman, Neil (1999). Descriptive Complexity. New York: Springer. ISBN 0-387-98600-6. == Further reading == Grädel, Erich; Kolaitis, Phokion G.; Libkin, Leonid; Maarten, Marx; Spencer, Joel; Vardi, Moshe Y.; Venema, Yde; Weinstein, Scott (2007). Finite model theory and its applications. Texts in Theoretical Computer Science. An EATCS Series. Berlin: Springer-Verlag. ISBN 978-3-540-00428-8. Zbl 1133.03001. == External links == Libkin, Leonid (2009). "The finite model theory toolbox of a database theoretician". PODS 2009: Proceedings of the twenty-eighth ACM SIGACT–SIGMOD symposium on Principles of database systems. pp. 65–76. doi:10.1145/1559795.1559807. Also suitable as a general introduction and overview. Leonid Libkin. Introductory chapter of "Elements of Finite Model Theory" Archived 2015-09-24 at the Wayback Machine. Motivates three main application areas: databases, complexity and formal languages. Jouko Väänänen. A Short Course on Finite Model Theory. Department of Mathematics, University of Helsinki. Based on lectures from 1993 to 1994. Anuj Dawar. Infinite and Finite Model Theory, slides, University of Cambridge, 2002. "Algorithmic Model Theory". RWTH Aachen. Archived from the original on 17 July 2012. Retrieved 7 November 2013. Includes a list of open FMT problems.
Wikipedia/Finite_model_theory
A semantic theory of truth is a theory of truth in the philosophy of language which holds that truth is a property of sentences. == Origin == The semantic conception of truth, which is related in different ways to both the correspondence and deflationary conceptions, is due to work by Polish logician Alfred Tarski. Tarski, in "On the Concept of Truth in Formal Languages" (1935), attempted to formulate a new theory of truth in order to resolve the liar paradox. In the course of this he made several metamathematical discoveries, most notably Tarski's undefinability theorem using the same formal technique Kurt Gödel used in his incompleteness theorems. Roughly, this states that a truth-predicate satisfying Convention T for the sentences of a given language cannot be defined within that language. == Tarski's theory of truth == To formulate linguistic theories without semantic paradoxes such as the liar paradox, it is generally necessary to distinguish the language that one is talking about (the object language) from the language that one is using to do the talking (the metalanguage). In the following, quoted text is use of the object language, while unquoted text is use of the metalanguage; a quoted sentence (such as "P") is always the metalanguage's name for a sentence, such that this name is simply the sentence P rendered in the object language. In this way, the metalanguage can be used to talk about the object language; Tarski's theory of truth (Alfred Tarski 1935) demanded that the object language be contained in the metalanguage. Tarski's material adequacy condition, also known as Convention T, holds that any viable theory of truth must entail, for every sentence "P", a sentence of the following form (known as "form (T)"): (1) "P" is true if, and only if, P. For example, (2) 'snow is white' is true if and only if snow is white. These sentences (1 and 2, etc.) have come to be called the "T-sentences". The reason they look trivial is that the object language and the metalanguage are both English; here is an example where the object language is German and the metalanguage is English: (3) 'Schnee ist weiß' is true if and only if snow is white. It is important to note that as Tarski originally formulated it, this theory applies only to formal languages, cf. also semantics of first-order logic. He gave a number of reasons for not extending his theory to natural languages, including the problem that there is no systematic way of deciding whether a given sentence of a natural language is well-formed, and that a natural language is closed (that is, it can describe the semantic characteristics of its own elements). But Tarski's approach was extended by Davidson into an approach to theories of meaning for natural languages, which involves treating "truth" as a primitive, rather than a defined, concept. (See truth-conditional semantics.) Tarski developed the theory to give an inductive definition of truth as follows. (See T-schema) For a language L containing ¬ ("not"), ∧ ("and"), ∨ ("or"), ∀ ("for all"), and ∃ ("there exists"), Tarski's inductive definition of truth looks like this: (1) A primitive statement "A" is true if, and only if, A. (2) "¬A" is true if, and only if, "A" is not true. (3) "A∧B" is true if, and only if, "A" is true and "B" is true. (4) "A∨B" is true if, and only if, "A" is true or "B" is true or ("A" is true and "B" is true). (5) "∀x(Fx)" is true if, and only if, for all objects x, "Fx" is true. (6) "∃x(Fx)" is true if, and only if, there is an object x for which "Fx" is true. These explain how the truth conditions of complex sentences (built up from connectives and quantifiers) can be reduced to the truth conditions of their constituents. The simplest constituents are atomic sentences. A contemporary semantic definition of truth would define truth for the atomic sentences as follows: An atomic sentence F(x1,...,xn) is true (relative to an assignment of values to the variables x1, ..., xn)) if the corresponding values of variables bear the relation expressed by the predicate F. Tarski himself defined truth for atomic sentences in a variant way that does not use any technical terms from semantics, such as the "expressed by" above. This is because he wanted to define these semantic terms in the context of truth. Therefore it would be circular to use one of them in the definition of truth itself. Tarski's semantic conception of truth plays an important role in modern logic and also in contemporary philosophy of language. It is a rather controversial point whether Tarski's semantic theory should be counted either as a correspondence theory or as a deflationary theory. == Kripke's theory of truth == Kripke's theory of truth (Saul Kripke 1975) is based on partial logic (a logic of partially defined truth predicates instead of Tarski's logic of totally defined truth predicates) with the strong Kleene evaluation scheme. == See also == Disquotational principle Semantics of logic T-schema Triune continuum paradigm == References == == Further reading == Simon Blackburn and Keith Simmons, eds., 1999. Truth. Oxford University Press, ISBN 0-19-875250-4. Michael K Butler, 2017. Deflationism and Semantic Theories of Truth. Pendlebury Press, ISBN 0993594549. Wilfrid Hodges, 2001. Tarski's truth definitions. In the Stanford Encyclopedia of Philosophy. Richard Kirkham, 1992. Theories of Truth. Bradford Books, ISBN 0-262-61108-2. Saul Kripke, 1975. "Outline of a Theory of Truth". Journal of Philosophy, 72: 690–716. Alfred Tarski, 1935. "The Concept of Truth in Formalized Languages". Logic, Semantics, Metamathematics, Indianapolis: Hackett 1983, 2nd edition, 152–278. Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4. == External links == Semantic Theory of Truth, Internet Encyclopedia of Philosophy Tarski's Truth Definitions (an entry of Stanford Encyclopedia of Philosophy) Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4.
Wikipedia/Kripke's_theory_of_truth
Rules of inference are ways of deriving conclusions from premises. They are integral parts of formal logic, serving as norms of the logical structure of valid arguments. If an argument with true premises follows a rule of inference then the conclusion cannot be false. Modus ponens, an influential rule of inference, connects two premises of the form "if P {\displaystyle P} then Q {\displaystyle Q} " and " P {\displaystyle P} " to the conclusion " Q {\displaystyle Q} ", as in the argument "If it rains, then the ground is wet. It rains. Therefore, the ground is wet." There are many other rules of inference for different patterns of valid arguments, such as modus tollens, disjunctive syllogism, constructive dilemma, and existential generalization. Rules of inference include rules of implication, which operate only in one direction from premises to conclusions, and rules of replacement, which state that two expressions are equivalent and can be freely swapped. Rules of inference contrast with formal fallacies—invalid argument forms involving logical errors. Rules of inference belong to logical systems, and distinct logical systems use different rules of inference. Propositional logic examines the inferential patterns of simple and compound propositions. First-order logic extends propositional logic by articulating the internal structure of propositions. It introduces new rules of inference governing how this internal structure affects valid arguments. Modal logics explore concepts like possibility and necessity, examining the inferential structure of these concepts. Intuitionistic, paraconsistent, and many-valued logics propose alternative inferential patterns that differ from the traditionally dominant approach associated with classical logic. Various formalisms are used to express logical systems. Some employ many intuitive rules of inference to reflect how people naturally reason while others provide minimalistic frameworks to represent foundational principles without redundancy. Rules of inference are relevant to many areas, such as proofs in mathematics and automated reasoning in computer science. Their conceptual and psychological underpinnings are studied by philosophers of logic and cognitive psychologists. == Definition == A rule of inference is a way of drawing a conclusion from a set of premises. Also called inference rule and transformation rule, it is a norm of correct inferences that can be used to guide reasoning, justify conclusions, and criticize arguments. As part of deductive logic, rules of inference are argument forms that preserve the truth of the premises, meaning that the conclusion is always true if the premises are true. An inference is deductively correct or valid if it follows a valid rule of inference. Whether this is the case depends only on the form or syntactical structure of the premises and the conclusion. As a result, the actual content or concrete meaning of the statements does not affect validity. For instance, modus ponens is a rule of inference that connects two premises of the form "if P {\displaystyle P} then Q {\displaystyle Q} " and " P {\displaystyle P} " to the conclusion " Q {\displaystyle Q} ", where P {\displaystyle P} and Q {\displaystyle Q} stand for statements. Any argument with this form is valid, independent of the specific meanings of P {\displaystyle P} and Q {\displaystyle Q} , such as the argument "If it rains, then the ground is wet. It rains. Therefore, the ground is wet". In addition to modus ponens, there are many other rules of inference, such as modus tollens, disjunctive syllogism, hypothetical syllogism, constructive dilemma, and destructive dilemma. There are different formats to represent rules of inference. A common approach is to use a new line for each premise and separate the premises from the conclusion using a horizontal line. With this format, modus ponens is written as: P → Q P Q {\displaystyle {\begin{array}{l}P\to Q\\P\\\hline Q\end{array}}} Some logicians employ the therefore sign ( ∴ {\displaystyle \therefore } ) together or instead of the horizontal line to indicate where the conclusion begins. The sequent notation, a different approach, uses a single line in which the premises are separated by commas and connected to the conclusion with the turnstile symbol ( ⊢ {\displaystyle \vdash } ), as in P → Q , P ⊢ Q {\displaystyle P\to Q,P\vdash Q} . The letters P {\displaystyle P} and Q {\displaystyle Q} in these formulas are so-called metavariables: they stand for any simple or compound proposition. Rules of inference belong to logical systems and distinct logical systems may use different rules of inference. For example, universal instantiation is a rule of inference in the system of first-order logic but not in propositional logic. Rules of inference play a central role in proofs as explicit procedures for arriving at a new line of a proof based on the preceding lines. Proofs involve a series of inferential steps and often use various rules of inference to establish the theorem they intend to demonstrate. Rules of inference are definitory rules—rules about which inferences are allowed. They contrast with strategic rules, which govern the inferential steps needed to prove a certain theorem from a specific set of premises. Mastering definitory rules by itself is not sufficient for effective reasoning since they provide little guidance on how to reach the intended conclusion. As standards or procedures governing the transformation of symbolic expressions, rules of inference are similar to mathematical functions taking premises as input and producing a conclusion as output. According to one interpretation, rules of inference are inherent in logical operators found in statements, making the meaning and function of these operators explicit without adding any additional information. Logicians distinguish two types of rules of inference: rules of implication and rules of replacement. Rules of implication, like modus ponens, operate only in one direction, meaning that the conclusion can be deduced from the premises but the premises cannot be deduced from the conclusion. Rules of replacement, by contrast, operate in both directions, stating that two expressions are equivalent and can be freely replaced with each other. In classical logic, for example, a proposition ( P {\displaystyle P} ) is equivalent to the negation of its negation ( ¬ ¬ P {\displaystyle \lnot \lnot P} ). As a result, one can infer one from the other in either direction, making it a rule of replacement. Other rules of replacement include De Morgan's laws as well as the commutative and associative properties of conjunction and disjunction. While rules of implication apply only to complete statements, rules of replacement can be applied to any part of a compound statement. One of the earliest discussions of formal rules of inference is found in antiquity in Aristotle's logic. His explanations of valid and invalid syllogisms were further refined in medieval and early modern philosophy. The development of symbolic logic in the 19th century led to the formulation of many additional rules of inference belonging to classical propositional and first-order logic. In the 20th and 21st centuries, logicians developed various non-classical systems of logic with alternative rules of inference. == Basic concepts == Rules of inference describe the structure of arguments, which consist of premises that support a conclusion. Premises and conclusions are statements or propositions about what is true. For instance, the assertion "The door is open." is a statement that is either true or false, while the question "Is the door open?" and the command "Open the door!" are not statements and have no truth value. An inference is a step of reasoning from premises to a conclusion while an argument is the outward expression of an inference. Logic is the study of correct reasoning and examines how to distinguish good from bad arguments. Deductive logic is the branch of logic that investigates the strongest arguments, called deductively valid arguments, for which the conclusion cannot be false if all the premises are true. This is expressed by saying that the conclusion is a logical consequence of the premises. Rules of inference belong to deductive logic and describe argument forms that fulfill this requirement. In order to precisely assess whether an argument follows a rule of inference, logicians use formal languages to express statements in a rigorous manner, similar to mathematical formulas. They combine formal languages with rules of inference to construct formal systems—frameworks for formulating propositions and drawing conclusions. Different formal systems may employ different formal languages or different rules of inference. The basic rules of inference within a formal system can often be expanded by introducing new rules of inference, known as admissible rules. Admissible rules do not change which arguments in a formal system are valid but can simplify proofs. If an admissible rule can be expressed through a combination of the system's basic rules, it is called a derived or derivable rule. Statements that can be deduced in a formal system are called theorems of this formal system. Widely-used systems of logic include propositional logic, first-order logic, and modal logic. Rules of inference only ensure that the conclusion is true if the premises are true. An argument with false premises can still be valid, but its conclusion could be false. For example, the argument "If pigs can fly, then the sky is purple. Pigs can fly. Therefore, the sky is purple." is valid because it follows modus ponens, even though it contains false premises. A valid argument is called sound argument if all premises are true. Rules of inference are closely related to tautologies. In logic, a tautology is a statement that is true only because of the logical vocabulary it uses, independent of the meanings of its non-logical vocabulary. For example, the statement "if the tree is green and the sky is blue then the tree is green" is true independently of the meanings of terms like tree and green, making it a tautology. Every argument following a rule of inference can be transformed into a tautology. This is achieved by forming a conjunction (and) of all premises and connecting it through implication (if ... then ...) to the conclusion, thereby combining all the individual statements of the argument into a single statement. For example, the valid argument "The tree is green and the sky is blue. Therefore, the tree is green." can be transformed into the tautology "if the tree is green and the sky is blue then the tree is green". Rules of inference are also closely related to laws of thought, which are basic principles of logic that can take the form tautologies. For example, the law of identity asserts that each entity is identical to itself. Other traditional laws of thought include the law of non-contradiction and the law of excluded middle. Rules of inference are not the only way to demonstrate that an argument is valid. Alternative methods include the use of truth tables, which applies to propositional logic, and truth trees, which can also be employed in first-order logic. == Systems of logic == === Classical === ==== Propositional logic ==== Propositional logic examines the inferential patterns of simple and compound propositions. It uses letters, such as P {\displaystyle P} and Q {\displaystyle Q} , to represent simple propositions. Compound propositions are formed by modifying or combining simple propositions with logical operators, such as ¬ {\displaystyle \lnot } (not), ∧ {\displaystyle \land } (and), ∨ {\displaystyle \lor } (or), and → {\displaystyle \to } (if ... then ...). For example, if P {\displaystyle P} stands for the statement "it is raining" and Q {\displaystyle Q} stands for the statement "the streets are wet", then ¬ P {\displaystyle \lnot P} expresses "it is not raining" and P → Q {\displaystyle P\to Q} expresses "if it is raining then the streets are wet". These logical operators are truth-functional, meaning that the truth value of a compound proposition depends only on the truth values of the simple propositions composing it. For instance, the compound proposition P ∧ Q {\displaystyle P\land Q} is only true if both P {\displaystyle P} and Q {\displaystyle Q} are true; in all other cases, it is false. Propositional logic is not concerned with the concrete meaning of propositions other than their truth values. Key rules of inference in propositional logic are modus ponens, modus tollens, hypothetical syllogism, disjunctive syllogism, and double negation elimination. Further rules include conjunction introduction, conjunction elimination, disjunction introduction, disjunction elimination, constructive dilemma, destructive dilemma, absorption, and De Morgan's laws. ==== First-order logic ==== First-order logic also employs the logical operators from propositional logic but includes additional devices to articulate the internal structure of propositions. Basic propositions in first-order logic consist of a predicate, symbolized with uppercase letters like P {\displaystyle P} and Q {\displaystyle Q} , which is applied to singular terms, symbolized with lowercase letters like a {\displaystyle a} and b {\displaystyle b} . For example, if a {\displaystyle a} stands for "Aristotle" and P {\displaystyle P} stands for "is a philosopher", the formula P ( a ) {\displaystyle P(a)} means that "Aristotle is a philosopher". Another innovation of first-order logic is the use of the quantifiers ∃ {\displaystyle \exists } and ∀ {\displaystyle \forall } , which express that a predicate applies to some or all individuals. For instance, the formula ∃ x P ( x ) {\displaystyle \exists xP(x)} expresses that philosophers exist while ∀ x P ( x ) {\displaystyle \forall xP(x)} expresses that everyone is a philosopher. The rules of inference from propositional logic are also valid in first-order logic. Additionally, first-order logic introduces new rules of inference that govern the role of singular terms, predicates, and quantifiers in arguments. Key rules of inference are universal instantiation and existential generalization. Other rules of inference include universal generalization and existential instantiation. === Modal logics === Modal logics are formal systems that extend propositional logic and first-order logic with additional logical operators. Alethic modal logic introduces the operator ◊ {\displaystyle \Diamond } to express that something is possible and the operator ◻ {\displaystyle \Box } to express that something is necessary. For example, if the P {\displaystyle P} means that "Parvati works", then ◊ P {\displaystyle \Diamond P} means that "It is possible that Parvati works" while ◻ P {\displaystyle \Box P} means that "It is necessary that Parvati works". These two operators are related by a rule of replacement stating that ◻ P {\displaystyle \Box P} is equivalent to ¬ ◊ ¬ P {\displaystyle \lnot \Diamond \lnot P} . In other words: if something is necessarily true then it is not possible that it is not true. Further rules of inference include the necessitation rule, which asserts that a statement is necessarily true if it is provable in a formal system without any additional premises, and the distribution axiom, which allows one to derive ◊ P → ◊ Q {\displaystyle \Diamond P\to \Diamond Q} from ◊ ( P → Q ) {\displaystyle \Diamond (P\to Q)} . These rules of inference belong to system K, a weak form of modal logic with only the most basic rules of inference. Many formal systems of alethic modal logic include additional rules of inference, such as system T, which allows one to deduce P {\displaystyle P} from ◻ P {\displaystyle \Box P} . Non-alethic systems of modal logic introduce operators that behave like ◊ {\displaystyle \Diamond } and ◻ {\displaystyle \Box } in alethic modal logic, following similar rules of inference but with different meanings. Deontic logic is one type of non-alethic logic. It uses the operator P {\displaystyle P} to express that an action is permitted and the operator O {\displaystyle O} to express that an action is required, where P {\displaystyle P} behaves similarly to ◊ {\displaystyle \Diamond } and O {\displaystyle O} behaves similarly to ◻ {\displaystyle \Box } . For instance, the rule of replacement in alethic modal logic asserting that ◻ Q {\displaystyle \Box Q} is equivalent to ¬ ◊ ¬ Q {\displaystyle \lnot \Diamond \lnot Q} also applies to deontic logic. As a result, one can deduce from O Q {\displaystyle OQ} (e.g. Quinn has an obligation to help) that ¬ P ¬ Q {\displaystyle \lnot P\lnot Q} (e.g. Quinn is not permitted not to help). Other systems of modal logic include temporal modal logic, which has operators for what is always or sometimes the case, as well as doxastic and epistemic modal logics, which have operators for what people believe and know. === Others === Many other systems of logic have been proposed. One of the earliest systems is Aristotelian logic, according to which each statement is made up of two terms, a subject and a predicate, connected by a copula. For example, the statement "all humans are mortal" has the subject "all humans", the predicate "mortal", and the copula "is". All rules of inference in Aristotelian logic have the form of syllogisms, which consist of two premises and a conclusion. For instance, the Barbara rule of inference describes the validity of arguments of the form "All men are mortal. All Greeks are men. Therefore, all Greeks are mortal." Second-order logic extends first-order logic by allowing quantifiers to apply to predicates in addition to singular terms. For example, to express that the individuals Adam ( a {\displaystyle a} ) and Bianca ( b {\displaystyle b} ) share a property, one can use the formula ∃ X ( X ( a ) ∧ X ( b ) ) {\displaystyle \exists X(X(a)\land X(b))} . Second-order logic also comes with new rules of inference. For instance, one can infer P ( a ) {\displaystyle P(a)} (Adam is a philosopher) from ∀ X X ( a ) {\displaystyle \forall XX(a)} (every property applies to Adam). Intuitionistic logic is a non-classical variant of propositional and first-order logic. It shares with them many rules of inference, such as modus ponens, but excludes certain rules. For example, in classical logic, one can infer P {\displaystyle P} from ¬ ¬ P {\displaystyle \lnot \lnot P} using the rule of double negation elimination. However, in intuitionistic logic, this inference is invalid. As a result, every theorem that can be deduced in intuitionistic logic can also be deduced in classical logic, but some theorems provable in classical logic cannot be proven in intuitionistic logic. Paraconsistent logics revise classical logic to allow the existence of contradictions. In logic, a contradiction happens if the same proposition is both affirmed and denied, meaning that a formal system contains both P {\displaystyle P} and ¬ P {\displaystyle \lnot P} as theorems. Classical logic prohibits contradictions because classical rules of inference lead to the principle of explosion, an admissible rule of inference that makes it possible to infer Q {\displaystyle Q} from the premises P {\displaystyle P} and ¬ P {\displaystyle \lnot P} . Since Q {\displaystyle Q} is unrelated to P {\displaystyle P} , any arbitrary statement can be deduced from a contradiction, making the affected systems useless for deciding what is true and false. Paraconsistent logics solve this problem by modifying the rules of inference in such a way that the principle of explosion is not an admissible rule of inference. As a result, it is possible to reason about inconsistent information without deriving absurd conclusions. Many-valued logics modify classical logic by introducing additional truth values. In classical logic, a proposition is either true or false with nothing in between. In many-valued logics, some propositions are neither true nor false. Kleene logic, for example, is a three-valued logic that introduces the additional truth value undefined to describe situations where information is incomplete or uncertain. Many-valued logics have adjusted rules of inference to accommodate the additional truth values. For instance, the classical rule of replacement stating that P → Q {\displaystyle P\to Q} is equivalent to ¬ P ∨ Q {\displaystyle \lnot P\lor Q} is invalid in many three-valued systems. == Formalisms == Various formalisms or proof systems have been suggested as distinct ways of codifying reasoning and demonstrating the validity of arguments. Unlike different systems of logic, these formalisms do not impact what can be proven; they only influence how proofs are formulated. Influential frameworks include natural deduction systems, Hilbert systems, and sequent calculi. Natural deduction systems aim to reflect how people naturally reason by introducing many intuitive rules of inference to make logical derivations more accessible. They break complex arguments into simple steps, often using subproofs based on temporary premises. The rules of inference in natural deduction target specific logical operators, governing how an operator can be added with introduction rules or removed with elimination rules. For example, the rule of conjunction introduction asserts that one can infer P ∧ Q {\displaystyle P\land Q} from the premises P {\displaystyle P} and Q {\displaystyle Q} , thereby producing a conclusion with the conjunction operator from premises that do not contain it. Conversely, the rule of conjunction elimination asserts that one can infer P {\displaystyle P} from P ∧ Q {\displaystyle P\land Q} , thereby producing a conclusion that no longer includes the conjunction operator. Similar rules of inference are disjunction introduction and elimination, implication introduction and elimination, negation introduction and elimination, and biconditional introduction and elimination. As a result, systems of natural deduction usually include many rules of inference. Hilbert systems, by contrast, aim to provide a minimal and efficient framework of logical reasoning by including as few rules of inference as possible. Many Hilbert systems only have modus ponens as the sole rule of inference. To ensure that all theorems can be deduced from this minimal foundation, they introduce axiom schemes. An axiom scheme is a template to create axioms or true statements. It uses metavariables, which are placeholders that can be replaced by specific terms or formulas to generate an infinite number of true statements. For example, propositional logic can be defined with the following three axiom schemes: (1) P → ( Q → P ) {\displaystyle P\to (Q\to P)} , (2) ( P → ( Q → R ) ) → ( ( P → Q ) → ( P → R ) ) {\displaystyle (P\to (Q\to R))\to ((P\to Q)\to (P\to R))} , and (3) ( ¬ P → ¬ Q ) → ( Q → P ) {\displaystyle (\lnot P\to \lnot Q)\to (Q\to P)} . To formulate proofs, logicians create new statements from axiom schemes and then apply modus ponens to these statements to derive conclusions. Compared to natural deduction, this procedure tends to be less intuitive since its heavy reliance on symbolic manipulation can obscure the underlying logical reasoning. Sequent calculi, another approach, introduce sequents as formal representations of arguments. A sequent has the form A 1 , … , A m ⊢ B 1 , … , B n {\displaystyle A_{1},\dots ,A_{m}\vdash B_{1},\dots ,B_{n}} , where A i {\displaystyle A_{i}} and B i {\displaystyle B_{i}} stand for propositions. Sequents are conditional assertions stating that at least one B i {\displaystyle B_{i}} is true if all A i {\displaystyle A_{i}} are true. Rules of inference operate on sequents to produce additional sequents. Sequent calculi define two rules of inference for each logical operator: one to introduce it on the left side of a sequent and another to introduce it on the right side. For example, through the rule for introducing the operator ¬ {\displaystyle \lnot } on the left side, one can infer ¬ R , P ⊢ Q {\displaystyle \lnot R,P\vdash Q} from P ⊢ Q , R {\displaystyle P\vdash Q,R} . The cut rule, an additional rule of inference, makes it possible to simplify sequents by removing certain propositions. == Formal fallacies == While rules of inference describe valid patterns of deductive reasoning, formal fallacies are invalid argument forms that involve logical errors. The premises of a formal fallacy do not properly support its conclusion: the conclusion can be false even if all premises are true. Formal fallacies often mimic the structure of valid rules of inference and can thereby mislead people into unknowingly committing them and accepting their conclusions. The formal fallacy of affirming the consequent concludes P {\displaystyle P} from the premises P → Q {\displaystyle P\to Q} and Q {\displaystyle Q} , as in the argument "If Leo is a cat, then Leo is an animal. Leo is an animal. Therefore, Leo is a cat." This fallacy resembles valid inferences following modus ponens, with the key difference that the fallacy swaps the second premise and the conclusion. The formal fallacy of denying the antecedent concludes ¬ Q {\displaystyle \lnot Q} from the premises P → Q {\displaystyle P\to Q} and ¬ P {\displaystyle \lnot P} , as in the argument "If Laya saw the movie, then Laya had fun. Laya did not see the movie. Therefore, Laya did not have fun." This fallacy resembles valid inferences following modus tollens, with the key difference that the fallacy swaps the second premise and the conclusion. Other formal fallacies include affirming a disjunct, the existential fallacy, and the fallacy of the undistributed middle. == In various fields == Rules of inference are relevant to many fields, especially the formal sciences, such as mathematics and computer science, where they are used to prove theorems. Mathematical proofs often start with a set of axioms to describe the logical relationships between mathematical constructs. To establish theorems, mathematicians apply rules of inference to these axioms, aiming to demonstrate that the theorems are logical consequences. Mathematical logic, a subfield of mathematics and logic, uses mathematical methods and frameworks to study rules of inference and other logical concepts. Computer science also relies on deductive reasoning, employing rules of inference to establish theorems and validate algorithms. Logic programming frameworks, such as Prolog, allow developers to represent knowledge and use computation to draw inferences and solve problems. These frameworks often include an automated theorem prover, a program that uses rules of inference to generate or verify proofs automatically. Expert systems utilize automated reasoning to simulate the decision-making processes of human experts in specific fields, such as medical diagnosis, and assist in complex problem-solving tasks. They have a knowledge base to represent the facts and rules of the field and use an inference engine to extract relevant information and respond to user queries. Rules of inference are central to the philosophy of logic regarding the contrast between deductive-theoretic and model-theoretic conceptions of logical consequence. Logical consequence, a fundamental concept in logic, is the relation between the premises of a deductively valid argument and its conclusion. Conceptions of logical consequence explain the nature of this relation and the conditions under which it exists. The deductive-theoretic conception relies on rules of inference, arguing that logical consequence means that the conclusion can be deduced from the premises through a series of inferential steps. The model-theoretic conception, by contrast, focuses on how the non-logical vocabulary of statements can be interpreted. According to this view, logical consequence means that no counterexamples are possible: under no interpretation are the premises true and the conclusion false. Cognitive psychologists study mental processes, including logical reasoning. They are interested in how humans use rules of inference to draw conclusions, examining the factors that influence correctness and efficiency. They observe that humans are better at using some rules of inference than others. For example, the rate of successful inferences is higher for modus ponens than for modus tollens. A related topic focuses on biases that lead individuals to mistake formal fallacies for valid arguments. For instance, fallacies of the types affirming the consequent and denying the antecedent are often mistakenly accepted as valid. The assessment of arguments also depends on the concrete meaning of the propositions: individuals are more likely to accept a fallacy if its conclusion sounds plausible. == See also == Immediate inference Inference objection Law of thought List of rules of inference Logical truth Structural rule == References == === Notes === === Citations === === Sources ===
Wikipedia/Rule_of_inference
In set theory and its applications throughout mathematics, a class is a collection of sets (or sometimes other mathematical objects) that can be unambiguously defined by a property that all its members share. Classes act as a way to have set-like collections while differing from sets so as to avoid paradoxes, especially Russell's paradox (see § Paradoxes). The precise definition of "class" depends on foundational context. In work on Zermelo–Fraenkel set theory, the notion of class is informal, whereas other set theories, such as von Neumann–Bernays–Gödel set theory, axiomatize the notion of "proper class", e.g., as entities that are not members of another entity. A class that is not a set (informally in Zermelo–Fraenkel) is called a proper class, and a class that is a set is sometimes called a small class. For instance, the class of all ordinal numbers, and the class of all sets, are proper classes in many formal systems. In Quine's set-theoretical writing, the phrase "ultimate class" is often used instead of the phrase "proper class" emphasising that in the systems he considers, certain classes cannot be members, and are thus the final term in any membership chain to which they belong. Outside set theory, the word "class" is sometimes used synonymously with "set". This usage dates from a historical period where classes and sets were not distinguished as they are in modern set-theoretic terminology. Many discussions of "classes" in the 19th century and earlier are really referring to sets, or rather perhaps take place without considering that certain classes can fail to be sets. == Examples == The collection of all algebraic structures of a given type will usually be a proper class. Examples include the class of all groups, the class of all vector spaces, and many others. In category theory, a category whose collection of objects forms a proper class (or whose collection of morphisms forms a proper class) is called a large category. The surreal numbers are a proper class of objects that have the properties of a field. Within set theory, many collections of sets turn out to be proper classes. Examples include the class of all sets (the universal class), the class of all ordinal numbers, and the class of all cardinal numbers. One way to prove that a class is proper is to place it in bijection with the class of all ordinal numbers. This method is used, for example, in the proof that there is no free complete lattice on three or more generators. == Paradoxes == The paradoxes of naive set theory can be explained in terms of the inconsistent tacit assumption that "all classes are sets". With a rigorous foundation, these paradoxes instead suggest proofs that certain classes are proper (i.e., that they are not sets). For example, Russell's paradox suggests a proof that the class of all sets which do not contain themselves is proper, and the Burali-Forti paradox suggests that the class of all ordinal numbers is proper. The paradoxes do not arise with classes because there is no notion of classes containing classes. Otherwise, one could, for example, define a class of all classes that do not contain themselves, which would lead to a Russell paradox for classes. A conglomerate, on the other hand, can have proper classes as members. == Classes in formal set theories == ZF set theory does not formalize the notion of classes, so each formula with classes must be reduced syntactically to a formula without classes. For example, one can reduce the formula A = { x ∣ x = x } {\displaystyle A=\{x\mid x=x\}} to ∀ x ( x ∈ A ↔ x = x ) {\displaystyle \forall x(x\in A\leftrightarrow x=x)} . For a class A {\displaystyle A} and a set variable symbol x {\displaystyle x} , it is necessary to be able to expand each of the formulas x ∈ A {\displaystyle x\in A} , x = A {\displaystyle x=A} , A ∈ x {\displaystyle A\in x} , and A = x {\displaystyle A=x} into a formula without an occurrence of a class.p. 339 Semantically, in a metalanguage, the classes can be described as equivalence classes of logical formulas: If A {\displaystyle {\mathcal {A}}} is a structure interpreting ZF, then the object language "class-builder expression" { x ∣ ϕ } {\displaystyle \{x\mid \phi \}} is interpreted in A {\displaystyle {\mathcal {A}}} by the collection of all the elements from the domain of A {\displaystyle {\mathcal {A}}} on which λ x ϕ {\displaystyle \lambda x\phi } holds; thus, the class can be described as the set of all predicates equivalent to ϕ {\displaystyle \phi } (which includes ϕ {\displaystyle \phi } itself). In particular, one can identify the "class of all sets" with the set of all predicates equivalent to x = x {\displaystyle x=x} . Because classes do not have any formal status in the theory of ZF, the axioms of ZF do not immediately apply to classes. However, if an inaccessible cardinal κ {\displaystyle \kappa } is assumed, then the sets of smaller rank form a model of ZF (a Grothendieck universe), and its subsets can be thought of as "classes". In ZF, the concept of a function can also be generalised to classes. A class function is not a function in the usual sense, since it is not a set; it is rather a formula Φ ( x , y ) {\displaystyle \Phi (x,y)} with the property that for any set x {\displaystyle x} there is no more than one set y {\displaystyle y} such that the pair ( x , y ) {\displaystyle (x,y)} satisfies Φ {\displaystyle \Phi } . For example, the class function mapping each set to its powerset may be expressed as the formula y = P ( x ) {\displaystyle y={\mathcal {P}}(x)} . The fact that the ordered pair ( x , y ) {\displaystyle (x,y)} satisfies Φ {\displaystyle \Phi } may be expressed with the shorthand notation Φ ( x ) = y {\displaystyle \Phi (x)=y} . Another approach is taken by the von Neumann–Bernays–Gödel axioms (NBG); classes are the basic objects in this theory, and a set is then defined to be a class that is an element of some other class. However, the class existence axioms of NBG are restricted so that they only quantify over sets, rather than over all classes. This causes NBG to be a conservative extension of ZFC. Morse–Kelley set theory admits proper classes as basic objects, like NBG, but also allows quantification over all proper classes in its class existence axioms. This causes MK to be strictly stronger than both NBG and ZFC. In other set theories, such as New Foundations or the theory of semisets, the concept of "proper class" still makes sense (not all classes are sets) but the criterion of sethood is not closed under subsets. For example, any set theory with a universal set has proper classes which are subclasses of sets. == Notes == == References == Jech, Thomas (2003), Set Theory, Springer Monographs in Mathematics (third millennium ed.), Berlin, New York: Springer-Verlag, ISBN 978-3-540-44085-7 Levy, A. (1979), Basic Set Theory, Berlin, New York: Springer-Verlag Smullyan, Raymond M.; Fitting, Melvin (2010), Set Theory And The Continuum Problem, Dover Publications, ISBN 978-0-486-47484-7 Monk, Donald J. (1969), Introduction to Set Theory, McGraw-Hill Book Co., ISBN 9780070427150 == External links == Weisstein, Eric W., "Set Class", MathWorld
Wikipedia/Class_(set_theory)
Logic for Computable Functions (LCF) is an interactive automated theorem prover developed at Stanford and Edinburgh by Robin Milner and collaborators in early 1970s, based on the theoretical foundation of logic of computable functions previously proposed by Dana Scott. Work on the LCF system introduced the general-purpose programming language ML to allow users to write theorem-proving tactics, supporting algebraic data types, parametric polymorphism, abstract data types, and exceptions. == Basic idea == Theorems in the system are terms of a special "theorem" abstract data type. The general mechanism of abstract data types of ML ensures that theorems are derived using only the inference rules given by the operations of the theorem abstract type. Users can write arbitrarily complex ML programs to compute theorems; the validity of theorems does not depend on the complexity of such programs, but follows from the soundness of the abstract data type implementation and the correctness of the ML compiler. == Advantages == The LCF approach provides similar trustworthiness to systems that generate explicit proof certificates but without the need to store proof objects in memory. The Theorem data type can be easily implemented to optionally store proof objects, depending on the system's run-time configuration, so it generalizes the basic proof-generation approach. The design decision to use a general-purpose programming language for developing theorems means that, depending on the complexity of programs written, it is possible to use the same language to write step-by-step proofs, decision procedures, or theorem provers. == Disadvantages == === Trusted computing base === The implementation of the underlying ML compiler adds to the trusted computing base. Work on CakeML resulted in a formally verified ML compiler, alleviating some of these concerns. === Efficiency and complexity of proof procedures === Theorem proving often benefits from decision procedures and theorem proving algorithms, whose correctness has been extensively analyzed. A straightforward way of implementing these procedures in an LCF approach requires such procedures to always derive outcomes from the axioms, lemmas, and inference rules of the system, as opposed to directly computing the outcome. A potentially more efficient approach is to use reflection to prove that a function operating on formulas always gives correct result. == Influences == Among subsequent implementations is Cambridge LCF. Later systems simplified the logic to use total instead of partial functions, leading to HOL, HOL Light, and the Isabelle proof assistant that supports various logics. As of 2019, the Isabelle proof assistant still contains an implementation of an LCF logic, Isabelle/LCF. == Notes == == References ==
Wikipedia/Logic_for_Computable_Functions
In functional programming, monads are a way to structure computations as a sequence of steps, where each step not only produces a value but also some extra information about the computation, such as a potential failure, non-determinism, or side effect. More formally, a monad is a type constructor M equipped with two operations, return : <A>(a : A) -> M(A) which lifts a value into the monadic context, and bind : <A,B>(m_a : M(A), f : A -> M(B)) -> M(B) which chains monadic computations. In simpler terms, monads can be thought of as interfaces implemented on type constructors, that allow for functions to abstract over various type constructor variants that implement monad (e.g. Option, List, etc.). Both the concept of a monad and the term originally come from category theory, where a monad is defined as an endofunctor with additional structure. Research beginning in the late 1980s and early 1990s established that monads could bring seemingly disparate computer-science problems under a unified, functional model. Category theory also provides a few formal requirements, known as the monad laws, which should be satisfied by any monad and can be used to verify monadic code. Since monads make semantics explicit for a kind of computation, they can also be used to implement convenient language features. Some languages, such as Haskell, even offer pre-built definitions in their core libraries for the general monad structure and common instances. == Overview == "For a monad m, a value of type m a represents having access to a value of type a within the context of the monad." —C. A. McCann More exactly, a monad can be used where unrestricted access to a value is inappropriate for reasons specific to the scenario. In the case of the Maybe monad, it is because the value may not exist. In the case of the IO monad, it is because the value may not be known yet, such as when the monad represents user input that will only be provided after a prompt is displayed. In all cases the scenarios in which access makes sense are captured by the bind operation defined for the monad; for the Maybe monad a value is bound only if it exists, and for the IO monad a value is bound only after the previous operations in the sequence have been performed. A monad can be created by defining a type constructor M and two operations: return :: a -> M a (often also called unit), which receives a value of type a and wraps it into a monadic value of type M a, and bind :: (M a) -> (a -> M b) -> (M b) (typically represented as >>=), which receives a monadic value of type M a and a function f that accepts values of the base type a. Bind unwraps a, applies f to it, and can process the result of f as a monadic value M b. (An alternative but equivalent construct using the join function instead of the bind operator can be found in the later section § Derivation from functors.) With these elements, the programmer composes a sequence of function calls (a "pipeline") with several bind operators chained together in an expression. Each function call transforms its input plain-type value, and the bind operator handles the returned monadic value, which is fed into the next step in the sequence. Typically, the bind operator >>= may contain code unique to the monad that performs additional computation steps not available in the function received as a parameter. Between each pair of composed function calls, the bind operator can inject into the monadic value m a some additional information that is not accessible within the function f, and pass it along down the pipeline. It can also exert finer control of the flow of execution, for example by calling the function only under some conditions, or executing the function calls in a particular order. === An example: Maybe === One example of a monad is the Maybe type. Undefined null results are one particular pain point that many procedural languages don't provide specific tools for dealing with, requiring use of the null object pattern or checks to test for invalid values at each operation to handle undefined values. This causes bugs and makes it harder to build robust software that gracefully handles errors. The Maybe type forces the programmer to deal with these potentially undefined results by explicitly defining the two states of a result: Just ⌑result⌑, or Nothing. For example the programmer might be constructing a parser, which is to return an intermediate result, or else signal a condition which the parser has detected, and which the programmer must also handle. With just a little extra functional spice on top, this Maybe type transforms into a fully-featured monad.: 12.3 pages 148–151  In most languages, the Maybe monad is also known as an option type, which is just a type that marks whether or not it contains a value. Typically they are expressed as some kind of enumerated type. In the Rust programming language it is called Option<T> and variants of this type can either be a value of generic type T, or the empty variant: None. Option<T> can also be understood as a "wrapping" type, and this is where its connection to monads comes in. In languages with some form of the Maybe type, there are functions that aid in their use such as composing monadic functions with each other and testing if a Maybe contains a value. In the following hard-coded example, a Maybe type is used as a result of functions that may fail, in this case the type returns nothing if there is a divide-by-zero.One such way to test whether or not a Maybe contains a value is to use if statements.Other languages may have pattern matchingMonads can compose functions that return Maybe, putting them together. A concrete example might have one function take in several Maybe parameters, and return a single Maybe whose value is Nothing when any of the parameters are Nothing, as in the following: Instead of repeating Some expressions, we can use something called a bind operator. (also known as "map", "flatmap", or "shove": 2205s ). This operation takes a monad and a function that returns a monad and runs the function on the inner value of the passed monad, returning the monad from the function.In Haskell, there is an operator bind, or (>>=) that allows for this monadic composition in a more elegant form similar to function composition.: 150–151  With >>= available, chainable_division can be expressed much more succinctly with the help of anonymous functions (i.e. lambdas). Notice in the expression below how the two nested lambdas each operate on the wrapped value in the passed Maybe monad using the bind operator.: 93  What has been shown so far is basically a monad, but to be more concise, the following is a strict list of qualities necessary for a monad as defined by the following section. Monadic Type A type (Maybe): 148–151  Unit operation A type converter (Just(x)): 93  Bind operation A combinator for monadic functions ( >>= or .flatMap()): 150–151  These are the 3 things necessary to form a monad. Other monads may embody different logical processes, and some may have additional properties, but all of them will have these three similar components. === Definition === The more common definition for a monad in functional programming, used in the above example, is actually based on a Kleisli triple ⟨T, η, μ⟩ rather than category theory's standard definition. The two constructs turn out to be mathematically equivalent, however, so either definition will yield a valid monad. Given any well-defined basic types T and U, a monad consists of three parts: A type constructor M that builds up a monadic type M T A type converter, often called unit or return, that embeds an object x in the monad: A combinator, typically called bind (as in binding a variable) and represented with an infix operator >>= or a method called flatMap, that unwraps a monadic variable, then inserts it into a monadic function/expression, resulting in a new monadic value: To fully qualify as a monad though, these three parts must also respect a few laws: unit is a left-identity for bind: unit is also a right-identity for bind: bind is essentially associative: Algebraically, this means any monad both gives rise to a category (called the Kleisli category) and a monoid in the category of functors (from values to computations), with monadic composition as a binary operator in the monoid: 2450s  and unit as identity in the monoid. === Usage === The value of the monad pattern goes beyond merely condensing code and providing a link to mathematical reasoning. Whatever language or default programming paradigm a developer uses, following the monad pattern brings many of the benefits of purely functional programming. By reifying a specific kind of computation, a monad not only encapsulates the tedious details of that computational pattern, but it does so in a declarative way, improving the code's clarity. As monadic values explicitly represent not only computed values, but computed effects, a monadic expression can be replaced with its value in referentially transparent positions, much like pure expressions can be, allowing for many techniques and optimizations based on rewriting. Typically, programmers will use bind to chain monadic functions into a sequence, which has led some to describe monads as "programmable semicolons", a reference to how many imperative languages use semicolons to separate statements. However, monads do not actually order computations; even in languages that use them as central features, simpler function composition can arrange steps within a program. A monad's general utility rather lies in simplifying a program's structure and improving separation of concerns through abstraction. The monad structure can also be seen as a uniquely mathematical and compile time variation on the decorator pattern. Some monads can pass along extra data that is inaccessible to functions, and some even exert finer control over execution, for example only calling a function under certain conditions. Because they let application programmers implement domain logic while offloading boilerplate code onto pre-developed modules, monads can even be considered a tool for aspect-oriented programming. One other noteworthy use for monads is isolating side-effects, like input/output or mutable state, in otherwise purely functional code. Even purely functional languages can still implement these "impure" computations without monads, via an intricate mix of function composition and continuation-passing style (CPS) in particular. With monads though, much of this scaffolding can be abstracted away, essentially by taking each recurring pattern in CPS code and bundling it into a distinct monad. If a language does not support monads by default, it is still possible to implement the pattern, often without much difficulty. When translated from category-theory to programming terms, the monad structure is a generic concept and can be defined directly in any language that supports an equivalent feature for bounded polymorphism. A concept's ability to remain agnostic about operational details while working on underlying types is powerful, but the unique features and stringent behavior of monads set them apart from other concepts. == Applications == Discussions of specific monads will typically focus on solving a narrow implementation problem since a given monad represents a specific computational form. In some situations though, an application can even meet its high-level goals by using appropriate monads within its core logic. Here are just a few applications that have monads at the heart of their designs: The Parsec parser library uses monads to combine simpler parsing rules into more complex ones, and is particularly useful for smaller domain-specific languages. xmonad is a tiling window manager centered on the zipper data structure, which itself can be treated monadically as a specific case of delimited continuations. LINQ by Microsoft provides a query language for the .NET Framework that is heavily influenced by functional programming concepts, including core operators for composing queries monadically. ZipperFS is a simple, experimental file system that also uses the zipper structure primarily to implement its features. The Reactive extensions framework essentially provides a (co)monadic interface to data streams that realizes the observer pattern. == History == The term "monad" in programming dates to the APL and J programming languages, which do tend toward being purely functional. However, in those languages, "monad" is only shorthand for a function taking one parameter (a function with two parameters being a "dyad", and so on). The mathematician Roger Godement was the first to formulate the concept of a monad (dubbing it a "standard construction") in the late 1950s, though the term "monad" that came to dominate was popularized by category-theorist Saunders Mac Lane. The form defined above using bind, however, was originally described in 1965 by mathematician Heinrich Kleisli in order to prove that any monad could be characterized as an adjunction between two (covariant) functors. Starting in the 1980s, a vague notion of the monad pattern began to surface in the computer science community. According to programming language researcher Philip Wadler, computer scientist John C. Reynolds anticipated several facets of it in the 1970s and early 1980s, when he discussed the value of continuation-passing style, of category theory as a rich source for formal semantics, and of the type distinction between values and computations. The research language Opal, which was actively designed up until 1990, also effectively based I/O on a monadic type, but the connection was not realized at the time. The computer scientist Eugenio Moggi was the first to explicitly link the monad of category theory to functional programming, in a conference paper in 1989, followed by a more refined journal submission in 1991. In earlier work, several computer scientists had advanced using category theory to provide semantics for the lambda calculus. Moggi's key insight was that a real-world program is not just a function from values to other values, but rather a transformation that forms computations on those values. When formalized in category-theoretic terms, this leads to the conclusion that monads are the structure to represent these computations. Several others popularized and built on this idea, including Philip Wadler and Simon Peyton Jones, both of whom were involved in the specification of Haskell. In particular, Haskell used a problematic "lazy stream" model up through v1.2 to reconcile I/O with lazy evaluation, until switching over to a more flexible monadic interface. The Haskell community would go on to apply monads to many problems in functional programming, and in the 2010s, researchers working with Haskell eventually recognized that monads are applicative functors; and that both monads and arrows are monoids. At first, programming with monads was largely confined to Haskell and its derivatives, but as functional programming has influenced other paradigms, many languages have incorporated a monad pattern (in spirit if not in name). Formulations now exist in Scheme, Perl, Python, Racket, Clojure, Scala, F#, and have also been considered for a new ML standard. == Analysis == One benefit of the monad pattern is bringing mathematical precision on the composition of computations. Not only can the monad laws be used to check an instance's validity, but features from related structures (like functors) can be used through subtyping. === Verifying the monad laws === Returning to the Maybe example, its components were declared to make up a monad, but no proof was given that it satisfies the monad laws. This can be rectified by plugging the specifics of Maybe into one side of the general laws, then algebraically building a chain of equalities to reach the other side: Law 1: eta(a) >>= f(x) ⇔ (Just a) >>= f(x) ⇔ f(a) Law 2: ma >>= eta(x) ⇔ ma if ma is (Just a) then eta(a) ⇔ Just a else or Nothing ⇔ Nothing end if Law 3: (ma >>= f(x)) >>= g(y) ⇔ ma >>= (f(x) >>= g(y)) if (ma >>= f(x)) is (Just b) then if ma is (Just a) then g(ma >>= f(x)) (f(x) >>= g(y)) a else else Nothing Nothing end if end if ⇔ if ma is (Just a) and f(a) is (Just b) then (g ∘ f) a else if ma is (Just a) and f(a) is Nothing then Nothing else Nothing end if === Derivation from functors === Though rarer in computer science, one can use category theory directly, which defines a monad as a functor with two additional natural transformations. So to begin, a structure requires a higher-order function (or "functional") named map to qualify as a functor: This is not always a major issue, however, especially when a monad is derived from a pre-existing functor, whereupon the monad inherits map automatically. (For historical reasons, this map is instead called fmap in Haskell.) A monad's first transformation is actually the same unit from the Kleisli triple, but following the hierarchy of structures closely, it turns out unit characterizes an applicative functor, an intermediate structure between a monad and a basic functor. In the applicative context, unit is sometimes referred to as pure but is still the same function. What does differ in this construction is the law unit must satisfy; as bind is not defined, the constraint is given in terms of map instead: The final leap from applicative functor to monad comes with the second transformation, the join function (in category theory this is a natural transformation usually called μ), which "flattens" nested applications of the monad: As the characteristic function, join must also satisfy three variations on the monad laws: Regardless of whether a developer defines a direct monad or a Kleisli triple, the underlying structure will be the same, and the forms can be derived from each other easily: === Another example: List === The List monad naturally demonstrates how deriving a monad from a simpler functor can come in handy. In many languages, a list structure comes pre-defined along with some basic features, so a List type constructor and append operator (represented with ++ for infix notation) are assumed as already given here. Embedding a plain value in a list is also trivial in most languages: unit(x) = [x] From here, applying a function iteratively with a list comprehension may seem like an easy choice for bind and converting lists to a full monad. The difficulty with this approach is that bind expects monadic functions, which in this case will output lists themselves; as more functions are applied, layers of nested lists will accumulate, requiring more than a basic comprehension. However, a procedure to apply any simple function over the whole list, in other words map, is straightforward: (map φ) xlist = [ φ(x1), φ(x2), ..., φ(xn) ] Now, these two procedures already promote List to an applicative functor. To fully qualify as a monad, only a correct notion of join to flatten repeated structure is needed, but for lists, that just means unwrapping an outer list to append the inner ones that contain values: join(xlistlist) = join([xlist1, xlist2, ..., xlistn]) = xlist1 ++ xlist2 ++ ... ++ xlistn The resulting monad is not only a list, but one that automatically resizes and condenses itself as functions are applied. bind can now also be derived with just a formula, then used to feed List values through a pipeline of monadic functions: (xlist >>= f) = join ∘ (map f) xlist One application for this monadic list is representing nondeterministic computation. List can hold results for all execution paths in an algorithm, then condense itself at each step to "forget" which paths led to which results (a sometimes important distinction from deterministic, exhaustive algorithms). Another benefit is that checks can be embedded in the monad; specific paths can be pruned transparently at their first point of failure, with no need to rewrite functions in the pipeline. A second situation where List shines is composing multivalued functions. For instance, the nth complex root of a number should yield n distinct complex numbers, but if another mth root is then taken of those results, the final m•n values should be identical to the output of the m•nth root. List completely automates this issue away, condensing the results from each step into a flat, mathematically correct list. == Techniques == Monads present opportunities for interesting techniques beyond just organizing program logic. Monads can lay the groundwork for useful syntactic features while their high-level and mathematical nature enable significant abstraction. === Syntactic sugar do-notation === Although using bind openly often makes sense, many programmers prefer a syntax that mimics imperative statements (called do-notation in Haskell, perform-notation in OCaml, computation expressions in F#, and for comprehension in Scala). This is only syntactic sugar that disguises a monadic pipeline as a code block; the compiler will then quietly translate these expressions into underlying functional code. Translating the add function from the Maybe into Haskell can show this feature in action. A non-monadic version of add in Haskell looks like this: In monadic Haskell, return is the standard name for unit, plus lambda expressions must be handled explicitly, but even with these technicalities, the Maybe monad makes for a cleaner definition: With do-notation though, this can be distilled even further into a very intuitive sequence: A second example shows how Maybe can be used in an entirely different language: F#. With computation expressions, a "safe division" function that returns None for an undefined operand or division by zero can be written as: At build-time, the compiler will internally "de-sugar" this function into a denser chain of bind calls: For a last example, even the general monad laws themselves can be expressed in do-notation: === General interface === Every monad needs a specific implementation that meets the monad laws, but other aspects like the relation to other structures or standard idioms within a language are shared by all monads. As a result, a language or library may provide a general Monad interface with function prototypes, subtyping relationships, and other general facts. Besides providing a head-start to development and guaranteeing a new monad inherits features from a supertype (such as functors), checking a monad's design against the interface adds another layer of quality control. === Operators === Monadic code can often be simplified even further through the judicious use of operators. The map functional can be especially helpful since it works on more than just ad-hoc monadic functions; so long as a monadic function should work analogously to a predefined operator, map can be used to instantly "lift" the simpler operator into a monadic one. With this technique, the definition of add from the Maybe example could be distilled into: add(mx,my) = map (+) The process could be taken even one step further by defining add not just for Maybe, but for the whole Monad interface. By doing this, any new monad that matches the structure interface and implements its own map will immediately inherit a lifted version of add too. The only change to the function needed is generalizing the type signature: add : (Monad Number, Monad Number) → Monad Number Another monadic operator that is also useful for analysis is monadic composition (represented as infix >=> here), which allows chaining monadic functions in a more mathematical style: (f >=> g)(x) = f(x) >>= g With this operator, the monad laws can be written in terms of functions alone, highlighting the correspondence to associativity and existence of an identity: (unit >=> g) ↔ g (f >=> unit) ↔ f (f >=> g) >=> h ↔ f >=> (g >=> h) In turn, the above shows the meaning of the "do" block in Haskell: do _p <- f(x) _q <- g(_p) h(_q) ↔ ( f >=> g >=> h )(x) == More examples == === Identity monad === The simplest monad is the Identity monad, which just annotates plain values and functions to satisfy the monad laws: newtype Id T = T unit(x) = x (x >>= f) = f(x) Identity does actually have valid uses though, such as providing a base case for recursive monad transformers. It can also be used to perform basic variable assignment within an imperative-style block. === Collections === Any collection with a proper append is already a monoid, but it turns out that List is not the only collection that also has a well-defined join and qualifies as a monad. One can even mutate List into these other monadic collections by simply imposing special properties on append: === IO monad (Haskell) === As already mentioned, pure code should not have unmanaged side effects, but that does not preclude a program from explicitly describing and managing effects. This idea is central to Haskell's IO monad, where an object of type IO a can be seen as describing an action to be performed in the world, optionally providing information about the world of type a. An action that provides no information about the world has the type IO (), "providing" the dummy value (). When a programmer binds an IO value to a function, the function computes the next action to be performed based on the information about the world provided by the previous action (input from users, files, etc.). Most significantly, because the value of the IO monad can only be bound to a function that computes another IO monad, the bind function imposes a discipline of a sequence of actions where the result of an action can only be provided to a function that will compute the next action to perform. This means that actions which do not need to be performed never are, and actions that do need to be performed have a well defined sequence. For example, Haskell has several functions for acting on the wider file system, including one that checks whether a file exists and another that deletes a file. Their two type signatures are: The first is interested in whether a given file really exists, and as a result, outputs a Boolean value within the IO monad. The second function, on the other hand, is only concerned with acting on the file system so the IO container it outputs is empty. IO is not limited just to file I/O though; it even allows for user I/O, and along with imperative syntax sugar, can mimic a typical "Hello, World!" program: Desugared, this translates into the following monadic pipeline (>> in Haskell is just a variant of bind for when only monadic effects matter and the underlying result can be discarded): === Writer monad (JavaScript) === Another common situation is keeping a log file or otherwise reporting a program's progress. Sometimes, a programmer may want to log even more specific, technical data for later profiling or debugging. The Writer monad can handle these tasks by generating auxiliary output that accumulates step-by-step. To show how the monad pattern is not restricted to primarily functional languages, this example implements a Writer monad in JavaScript. First, an array (with nested tails) allows constructing the Writer type as a linked list. The underlying output value will live in position 0 of the array, and position 1 will implicitly hold a chain of auxiliary notes: Defining unit is also very simple: Only unit is needed to define simple functions that output Writer objects with debugging notes: A true monad still requires bind, but for Writer, this amounts simply to concatenating a function's output to the monad's linked list: The sample functions can now be chained together using bind, but defining a version of monadic composition (called pipelog here) allows applying these functions even more succinctly: The final result is a clean separation of concerns between stepping through computations and logging them to audit later: === Environment monad === An environment monad (also called a reader monad and a function monad) allows a computation to depend on values from a shared environment. The monad type constructor maps a type T to functions of type E → T, where E is the type of the shared environment. The monad functions are: return : T → E → T = t ↦ e ↦ t bind : ( E → T ) → ( T → E → T ′ ) → E → T ′ = r ↦ f ↦ e ↦ f ( r e ) e {\displaystyle {\begin{array}{ll}{\text{return}}\colon &T\rightarrow E\rightarrow T=t\mapsto e\mapsto t\\{\text{bind}}\colon &(E\rightarrow T)\rightarrow (T\rightarrow E\rightarrow T')\rightarrow E\rightarrow T'=r\mapsto f\mapsto e\mapsto f\,(r\,e)\,e\end{array}}} The following monadic operations are useful: ask : E → E = id E local : ( E → E ) → ( E → T ) → E → T = f ↦ c ↦ e ↦ c ( f e ) {\displaystyle {\begin{array}{ll}{\text{ask}}\colon &E\rightarrow E={\text{id}}_{E}\\{\text{local}}\colon &(E\rightarrow E)\rightarrow (E\rightarrow T)\rightarrow E\rightarrow T=f\mapsto c\mapsto e\mapsto c\,(f\,e)\end{array}}} The ask operation is used to retrieve the current context, while local executes a computation in a modified subcontext. As in a state monad, computations in the environment monad may be invoked by simply providing an environment value and applying it to an instance of the monad. Formally, a value in an environment monad is equivalent to a function with an additional, anonymous argument; return and bind are equivalent to the K and S combinators, respectively, in the SKI combinator calculus. === State monads === A state monad allows a programmer to attach state information of any type to a calculation. Given any value type, the corresponding type in the state monad is a function which accepts a state, then outputs a new state (of type s) along with a return value (of type t). This is similar to an environment monad, except that it also returns a new state, and thus allows modeling a mutable environment. Note that this monad takes a type parameter, the type of the state information. The monad operations are defined as follows: Useful state operations include: Another operation applies a state monad to a given initial state: do-blocks in a state monad are sequences of operations that can examine and update the state data. Informally, a state monad of state type S maps the type of return values T into functions of type S → T × S {\displaystyle S\rightarrow T\times S} , where S is the underlying state. The return and bind function are: return : T → S → T × S = t ↦ s ↦ ( t , s ) bind : ( S → T × S ) → ( T → S → T ′ × S ) → S → T ′ × S = m ↦ k ↦ s ↦ ( k t s ′ ) where ( t , s ′ ) = m s {\displaystyle {\begin{array}{ll}{\text{return}}\colon &T\rightarrow S\rightarrow T\times S=t\mapsto s\mapsto (t,s)\\{\text{bind}}\colon &(S\rightarrow T\times S)\rightarrow (T\rightarrow S\rightarrow T'\times S)\rightarrow S\rightarrow T'\times S\ =m\mapsto k\mapsto s\mapsto (k\ t\ s')\quad {\text{where}}\;(t,s')=m\,s\end{array}}} . From the category theory point of view, a state monad is derived from the adjunction between the product functor and the exponential functor, which exists in any cartesian closed category by definition. === Continuation monad === A continuation monad with return type R maps type T into functions of type ( T → R ) → R {\displaystyle \left(T\rightarrow R\right)\rightarrow R} . It is used to model continuation-passing style. The return and bind functions are as follows: return : T → ( T → R ) → R = t ↦ f ↦ f t bind : ( ( T → R ) → R ) → ( T → ( T ′ → R ) → R ) → ( T ′ → R ) → R = c ↦ f ↦ k ↦ c ( t ↦ f t k ) {\displaystyle {\begin{array}{ll}{\text{return}}\colon &T\rightarrow \left(T\rightarrow R\right)\rightarrow R=t\mapsto f\mapsto f\,t\\{\text{bind}}\colon &\left(\left(T\rightarrow R\right)\rightarrow R\right)\rightarrow \left(T\rightarrow \left(T'\rightarrow R\right)\rightarrow R\right)\rightarrow \left(T'\rightarrow R\right)\rightarrow R=c\mapsto f\mapsto k\mapsto c\,\left(t\mapsto f\,t\,k\right)\end{array}}} The call-with-current-continuation function is defined as follows: call/cc : ( ( T → ( T ′ → R ) → R ) → ( T → R ) → R ) → ( T → R ) → R = f ↦ k ↦ ( f ( t ↦ x ↦ k t ) k ) {\displaystyle {\text{call/cc}}\colon \ \left(\left(T\rightarrow \left(T'\rightarrow R\right)\rightarrow R\right)\rightarrow \left(T\rightarrow R\right)\rightarrow R\right)\rightarrow \left(T\rightarrow R\right)\rightarrow R=f\mapsto k\mapsto \left(f\left(t\mapsto x\mapsto k\,t\right)\,k\right)} === Program logging === The following code is pseudocode. Suppose we have two functions foo and bar, with types That is, both functions take in an integer and return another integer. Then we can apply the functions in succession like so: Where the result is the result of foo applied to the result of bar applied to x. But suppose we are debugging our program, and we would like to add logging messages to foo and bar. So we change the types as so: So that both functions return a tuple, with the result of the application as the integer, and a logging message with information about the applied function and all the previously applied functions as the string. Unfortunately, this means we can no longer compose foo and bar, as their input type int is not compatible with their output type int * string. And although we can again gain composability by modifying the types of each function to be int * string -> int * string, this would require us to add boilerplate code to each function to extract the integer from the tuple, which would get tedious as the number of such functions increases. Instead, let us define a helper function to abstract away this boilerplate for us: bind takes in an integer and string tuple, then takes in a function (like foo) that maps from an integer to an integer and string tuple. Its output is an integer and string tuple, which is the result of applying the input function to the integer within the input integer and string tuple. In this way, we only need to write boilerplate code to extract the integer from the tuple once, in bind. Now we have regained some composability. For example: Where (x,s) is an integer and string tuple. To make the benefits even clearer, let us define an infix operator as an alias for bind: So that t >>= f is the same as bind t f. Then the above example becomes: Finally, we define a new function to avoid writing (x, "") every time we wish to create an empty logging message, where "" is the empty string. Which wraps x in the tuple described above. The result is a pipeline for logging messages: That allows us to more easily log the effects of bar and foo on x. int * string denotes a pseudo-coded monadic value. bind and return are analogous to the corresponding functions of the same name. In fact, int * string, bind, and return form a monad. === Additive monads === An additive monad is a monad endowed with an additional closed, associative, binary operator mplus and an identity element under mplus, called mzero. The Maybe monad can be considered additive, with Nothing as mzero and a variation on the OR operator as mplus. List is also an additive monad, with the empty list [] acting as mzero and the concatenation operator ++ as mplus. Intuitively, mzero represents a monadic wrapper with no value from an underlying type, but is also considered a "zero" (rather than a "one") since it acts as an absorber for bind, returning mzero whenever bound to a monadic function. This property is two-sided, and bind will also return mzero when any value is bound to a monadic zero function. In category-theoretic terms, an additive monad qualifies once as a monoid over monadic functions with bind (as all monads do), and again over monadic values via mplus. === Free monads === Sometimes, the general outline of a monad may be useful, but no simple pattern recommends one monad or another. This is where a free monad comes in; as a free object in the category of monads, it can represent monadic structure without any specific constraints beyond the monad laws themselves. Just as a free monoid concatenates elements without evaluation, a free monad allows chaining computations with markers to satisfy the type system, but otherwise imposes no deeper semantics itself. For example, by working entirely through the Just and Nothing markers, the Maybe monad is in fact a free monad. The List monad, on the other hand, is not a free monad since it brings extra, specific facts about lists (like append) into its definition. One last example is an abstract free monad: Free monads, however, are not restricted to a linked-list like in this example, and can be built around other structures like trees. Using free monads intentionally may seem impractical at first, but their formal nature is particularly well-suited for syntactic problems. A free monad can be used to track syntax and type while leaving semantics for later, and has found use in parsers and interpreters as a result. Others have applied them to more dynamic, operational problems too, such as providing iteratees within a language. === Comonads === Besides generating monads with extra properties, for any given monad, one can also define a comonad. Conceptually, if monads represent computations built up from underlying values, then comonads can be seen as reductions back down to values. Monadic code, in a sense, cannot be fully "unpacked"; once a value is wrapped within a monad, it remains quarantined there along with any side-effects (a good thing in purely functional programming). Sometimes though, a problem is more about consuming contextual data, which comonads can model explicitly. Technically, a comonad is the categorical dual of a monad, which loosely means that it will have the same required components, only with the direction of the type signatures reversed. Starting from the bind-centric monad definition, a comonad consists of: A type constructor W that marks the higher-order type W T The dual of unit, called counit here, extracts the underlying value from the comonad: counit(wa) : W T → T A reversal of bind (also represented with =>>) that extends a chain of reducing functions: (wa =>> f) : (W U, W U → T) → W T extend and counit must also satisfy duals of the monad laws: counit ∘ ( (wa =>> f) → wb ) ↔ f(wa) → b wa =>> counit ↔ wa wa ( (=>> f(wx = wa)) → wb (=>> g(wy = wb)) → wc ) ↔ ( wa (=>> f(wx = wa)) → wb ) (=>> g(wy = wb)) → wc Analogous to monads, comonads can also be derived from functors using a dual of join: duplicate takes an already comonadic value and wraps it in another layer of comonadic structure: duplicate(wa) : W T → W (W T) While operations like extend are reversed, however, a comonad does not reverse functions it acts on, and consequently, comonads are still functors with map, not cofunctors. The alternate definition with duplicate, counit, and map must also respect its own comonad laws: ((map duplicate) ∘ duplicate) wa ↔ (duplicate ∘ duplicate) wa ↔ wwwa ((map counit) ∘ duplicate) wa ↔ (counit ∘ duplicate) wa ↔ wa ((map map φ) ∘ duplicate) wa ↔ (duplicate ∘ (map φ)) wa ↔ wwb And as with monads, the two forms can be converted automatically: (map φ) wa ↔ wa =>> (φ ∘ counit) wx duplicate wa ↔ wa =>> wx wa =>> f(wx) ↔ ((map f) ∘ duplicate) wa A simple example is the Product comonad, which outputs values based on an input value and shared environment data. In fact, the Product comonad is just the dual of the Writer monad and effectively the same as the Reader monad (both discussed below). Product and Reader differ only in which function signatures they accept, and how they complement those functions by wrapping or unwrapping values. A less trivial example is the Stream comonad, which can be used to represent data streams and attach filters to the incoming signals with extend. In fact, while not as popular as monads, researchers have found comonads particularly useful for stream processing and modeling dataflow programming. Due to their strict definitions, however, one cannot simply move objects back and forth between monads and comonads. As an even higher abstraction, arrows can subsume both structures, but finding more granular ways to combine monadic and comonadic code is an active area of research. == See also == Alternatives for modeling computations: Effect systems (particularly algebraic effect handlers) are a different way to describe side effects as types Uniqueness types are a third approach to handling side-effects in functional languages Related design concepts: Aspect-oriented programming emphasizes separating out ancillary bookkeeping code to improve modularity and simplicity Inversion of control is the abstract principle of calling specific functions from an overarching framework Type classes are a specific language feature used to implement monads and other structures in Haskell The decorator pattern is a more concrete, ad-hoc way to achieve similar benefits in object-oriented programming Generalizations of monads: Applicative functors generalize from monads by keeping only unit and laws relating it to map Arrows use additional structure to bring plain functions and monads under a single interface Monad transformers act on distinct monads to combine them modularly == Notes == == References == == External links == HaskellWiki references: "All About Monads" (originally by Jeff Newbern) — A comprehensive discussion of all the common monads and how they work in Haskell; includes the "mechanized assembly line" analogy. "Typeclassopedia" (originally by Brent Yorgey) — A detailed exposition of how the leading typeclasses in Haskell, including monads, interrelate. Tutorials: "A Fistful of Monads" (from the online Haskell textbook Learn You a Haskell for Great Good! — A chapter introducing monads from the starting-point of functor and applicative functor typeclasses, including examples. "For a Few Monads More" — A second chapter explaining more details and examples, including a Probability monad for Markov chains. "Functors, Applicatives, And Monads In Pictures (by Aditya Bhargava) — A quick, humorous, and visual tutorial on monads. Interesting cases: "UNIX pipes as IO monads" (by Oleg Kiselyov) — A short essay explaining how Unix pipes are effectively monadic. Pro Scala: Monadic Design Patterns for the Web (by Gregory Meredith) — An unpublished, full-length manuscript on how to improve many facets of web development in Scala with monads.
Wikipedia/Monad_(functional_programming)
The simply typed lambda calculus (⁠ λ → {\displaystyle \lambda ^{\to }} ⁠), a form of type theory, is a typed interpretation of the lambda calculus with only one type constructor (⁠ → {\displaystyle \to } ⁠) that builds function types. It is the canonical and simplest example of a typed lambda calculus. The simply typed lambda calculus was originally introduced by Alonzo Church in 1940 as an attempt to avoid paradoxical use of the untyped lambda calculus. The term simple type is also used to refer to extensions of the simply typed lambda calculus with constructs such as products, coproducts or natural numbers (System T) or even full recursion (like PCF). In contrast, systems that introduce polymorphic types (like System F) or dependent types (like the Logical Framework) are not considered simply typed. The simple types, except for full recursion, are still considered simple because the Church encodings of such structures can be done using only → {\displaystyle \to } and suitable type variables, while polymorphism and dependency cannot. == Syntax == In the 1930s Alonzo Church sought to use the logistic method: his lambda calculus, as a formal language based on symbolic expressions, consisted of a denumerably infinite series of axioms and variables, but also a finite set of primitive symbols, denoting abstraction and scope, as well as four constants: negation, disjunction, universal quantification, and selection respectively; and also, a finite set of rules I to VI. This finite set of rules included rule V modus ponens as well as IV and VI for substitution and generalization respectively. Rules I to III are known as alpha, beta, and eta conversion in the lambda calculus. Church sought to use English only as a syntax language (that is, a metamathematical language) for describing symbolic expressions with no interpretations. In 1940 Church settled on a subscript notation for denoting the type in a symbolic expression. In his presentation, Church used only two base types: o {\displaystyle o} for "the type of propositions" and ι {\displaystyle \iota } for "the type of individuals". The type o {\displaystyle o} has no term constants, whereas ι {\displaystyle \iota } has one term constant. Frequently the calculus with only one base type, usually ⁠ o {\displaystyle o} ⁠, is considered. The Greek letter subscripts ⁠ α {\displaystyle \alpha } ⁠, ⁠ β {\displaystyle \beta } ⁠, etc. denote type variables; the parenthesized subscripted ( α β ) {\displaystyle (\alpha \beta )} denotes the function type ⁠ β → α {\displaystyle \beta \to \alpha } ⁠. Church 1940 p.58 used 'arrow or ⁠ → {\displaystyle \to } ⁠' to denote stands for, or is an abbreviation for. By the 1970s stand-alone arrow notation was in use; for example in this article non-subscripted symbols σ {\displaystyle \sigma } and τ {\displaystyle \tau } can range over types. The infinite number of axioms were then seen to be a consequence of applying rules I to VI to the types (see Peano axioms). Informally, the function type σ → τ {\displaystyle \sigma \to \tau } refers to the type of functions that, given an input of type ⁠ σ {\displaystyle \sigma } ⁠, produce an output of type ⁠ τ {\displaystyle \tau } ⁠. By convention, → {\displaystyle \to } associates to the right: σ → τ → ρ {\displaystyle \sigma \to \tau \to \rho } is read as ⁠ σ → ( τ → ρ ) {\displaystyle \sigma \to (\tau \to \rho )} ⁠. To define the types, a set of base types, ⁠ B {\displaystyle B} ⁠, must first be defined. These are sometimes called atomic types or type constants. With this fixed, the syntax of types is: τ ::= τ → τ ∣ T w h e r e T ∈ B . {\displaystyle \tau ::=\tau \to \tau \mid T\quad \mathrm {where} \quad T\in B.} For example, ⁠ B = { a , b } {\displaystyle B=\{a,b\}} ⁠, generates an infinite set of types starting with ⁠ a {\displaystyle a} ⁠, ⁠ b {\displaystyle b} ⁠, ⁠ a → a {\displaystyle a\to a} ⁠, ⁠ a → b {\displaystyle a\to b} ⁠, ⁠ b → b {\displaystyle b\to b} ⁠, ⁠ b → a {\displaystyle b\to a} ⁠, ⁠ a → ( a → a ) {\displaystyle a\to (a\to a)} ⁠, ..., ⁠ ( b → a ) → ( a → b ) {\displaystyle (b\to a)\to (a\to b)} ⁠, ... A set of term constants is also fixed for the base types. For example, it might be assumed that one of the base types is nat, and its term constants could be the natural numbers. The syntax of the simply typed lambda calculus is essentially that of the lambda calculus itself. The term x : τ {\displaystyle x{\mathbin {:}}\tau } denotes that the variable x {\displaystyle x} is of type ⁠ τ {\displaystyle \tau } ⁠. The term syntax, in Backus–Naur form, is variable reference, abstractions, application, or constant: e ::= x ∣ λ x : τ . e ∣ e e ∣ c {\displaystyle e::=x\mid \lambda x{\mathbin {:}}\tau .e\mid e\,e\mid c} where c {\displaystyle c} is a term constant. A variable reference x {\displaystyle x} is bound if it is inside of an abstraction binding ⁠ x {\displaystyle x} ⁠. A term is closed if there are no unbound variables. In comparison, the syntax of untyped lambda calculus has no such typing or term constants: e ::= x ∣ λ x . e ∣ e e {\displaystyle e::=x\mid \lambda x.e\mid e\,e} Whereas in typed lambda calculus every abstraction (i.e. function) must specify the type of its argument. == Typing rules == To define the set of well-typed lambda terms of a given type, one defines a typing relation between terms and types. First, one introduces typing contexts, or typing environments Γ , Δ , … {\displaystyle \Gamma ,\Delta ,\dots } , which are sets of typing assumptions. A typing assumption has the form ⁠ x : σ {\displaystyle x{\mathbin {:}}\sigma } ⁠, meaning variable x {\displaystyle x} has type ⁠ σ {\displaystyle \sigma } ⁠. The typing relation Γ ⊢ e : σ {\displaystyle \Gamma \vdash e{\mathbin {:}}\sigma } indicates that e {\displaystyle e} is a term of type σ {\displaystyle \sigma } in context ⁠ Γ {\displaystyle \Gamma } ⁠. In this case e {\displaystyle e} is said to be well-typed (having type ⁠ σ {\displaystyle \sigma } ⁠). Instances of the typing relation are called typing judgments. The validity of a typing judgment is shown by providing a typing derivation, constructed using typing rules (wherein the premises above the line allow us to derive the conclusion below the line). Simply typed lambda calculus uses these rules: In words, If x {\displaystyle x} has type σ {\displaystyle \sigma } in the context, then x {\displaystyle x} has type ⁠ σ {\displaystyle \sigma } ⁠. Term constants have the appropriate base types. If, in a certain context with x {\displaystyle x} having type ⁠ σ {\displaystyle \sigma } ⁠, e {\displaystyle e} has type ⁠ τ {\displaystyle \tau } ⁠, then, in the same context without ⁠ x {\displaystyle x} ⁠, ⁠ λ x : σ . e {\displaystyle \lambda x{\mathbin {:}}\sigma .~e} ⁠ has type ⁠ σ → τ {\displaystyle \sigma \to \tau } ⁠. If, in a certain context, e 1 {\displaystyle e_{1}} has type ⁠ σ → τ {\displaystyle \sigma \to \tau } ⁠, and e 2 {\displaystyle e_{2}} has type ⁠ σ {\displaystyle \sigma } ⁠, then e 1 e 2 {\displaystyle e_{1}~e_{2}} has type ⁠ τ {\displaystyle \tau } ⁠. Examples of closed terms, i.e. terms typable in the empty context, are: For every type ⁠ τ {\displaystyle \tau } ⁠, a term λ x : τ . x : τ → τ {\displaystyle \lambda x{\mathbin {:}}\tau .x{\mathbin {:}}\tau \to \tau } (identity function/I-combinator), For types ⁠ σ , τ {\displaystyle \sigma ,\tau } ⁠, a term λ x : σ . λ y : τ . x : σ → τ → σ {\displaystyle \lambda x{\mathbin {:}}\sigma .\lambda y{\mathbin {:}}\tau .x{\mathbin {:}}\sigma \to \tau \to \sigma } (the K-combinator), and For types ⁠ τ , τ ′ , τ ″ {\displaystyle \tau ,\tau ',\tau ''} ⁠, a term λ x : τ → τ ′ → τ ″ . λ y : τ → τ ′ . λ z : τ . x z ( y z ) : ( τ → τ ′ → τ ″ ) → ( τ → τ ′ ) → τ → τ ″ {\displaystyle \lambda x{\mathbin {:}}\tau \to \tau '\to \tau ''.\lambda y{\mathbin {:}}\tau \to \tau '.\lambda z{\mathbin {:}}\tau .xz(yz):(\tau \to \tau '\to \tau '')\to (\tau \to \tau ')\to \tau \to \tau ''} (the S-combinator). These are the typed lambda calculus representations of the basic combinators of combinatory logic. Each type τ {\displaystyle \tau } is assigned an order, a number ⁠ o ( τ ) {\displaystyle o(\tau )} ⁠. For base types, ⁠ o ( T ) = 0 {\displaystyle o(T)=0} ⁠; for function types, ⁠ o ( σ → τ ) = max ( o ( σ ) + 1 , o ( τ ) ) {\displaystyle o(\sigma \to \tau )={\mbox{max}}(o(\sigma )+1,o(\tau ))} ⁠. That is, the order of a type measures the depth of the most left-nested arrow. Hence: o ( ι → ι → ι ) = 1 {\displaystyle o(\iota \to \iota \to \iota )=1} o ( ( ι → ι ) → ι ) = 2 {\displaystyle o((\iota \to \iota )\to \iota )=2} == Semantics == === Intrinsic vs. extrinsic interpretations === Broadly speaking, there are two different ways of assigning meaning to the simply typed lambda calculus, as to typed languages more generally, variously called intrinsic vs. extrinsic, ontological vs. semantical, or Church-style vs. Curry-style. An intrinsic semantics only assigns meaning to well-typed terms, or more precisely, assigns meaning directly to typing derivations. This has the effect that terms differing only by type annotations can nonetheless be assigned different meanings. For example, the identity term λ x : i n t . x {\displaystyle \lambda x{\mathbin {:}}{\mathtt {int}}.~x} on integers and the identity term λ x : b o o l . x {\displaystyle \lambda x{\mathbin {:}}{\mathtt {bool}}.~x} on booleans may mean different things. (The classic intended interpretations are the identity function on integers and the identity function on boolean values.) In contrast, an extrinsic semantics assigns meaning to terms regardless of typing, as they would be interpreted in an untyped language. In this view, λ x : i n t . x {\displaystyle \lambda x{\mathbin {:}}{\mathtt {int}}.~x} and λ x : b o o l . x {\displaystyle \lambda x{\mathbin {:}}{\mathtt {bool}}.~x} mean the same thing (i.e., the same thing as ⁠ λ x . x {\displaystyle \lambda x.~x} ⁠). The distinction between intrinsic and extrinsic semantics is sometimes associated with the presence or absence of annotations on lambda abstractions, but strictly speaking this usage is imprecise. It is possible to define an extrinsic semantics on annotated terms simply by ignoring the types (i.e., through type erasure), as it is possible to give an intrinsic semantics on unannotated terms when the types can be deduced from context (i.e., through type inference). The essential difference between intrinsic and extrinsic approaches is just whether the typing rules are viewed as defining the language, or as a formalism for verifying properties of a more primitive underlying language. Most of the different semantic interpretations discussed below can be seen through either an intrinsic or extrinsic perspective. === Equational theory === The simply typed lambda calculus (STLC) has the same equational theory of βη-equivalence as untyped lambda calculus, but subject to type restrictions. The equation for beta reduction ( λ x : σ . t ) u = β t [ x := u ] {\displaystyle (\lambda x{\mathbin {:}}\sigma .~t)\,u=_{\beta }t[x:=u]} holds in context Γ {\displaystyle \Gamma } whenever Γ , x : σ ⊢ t : τ {\displaystyle \Gamma ,x{\mathbin {:}}\sigma \vdash t{\mathbin {:}}\tau } and ⁠ Γ ⊢ u : σ {\displaystyle \Gamma \vdash u{\mathbin {:}}\sigma } ⁠, while the equation for eta reduction λ x : σ . t x = η t {\displaystyle \lambda x{\mathbin {:}}\sigma .~t\,x=_{\eta }t} holds whenever Γ ⊢ t : σ → τ {\displaystyle \Gamma \vdash t{:}\sigma \to \tau } and x {\displaystyle x} does not appear free in ⁠ t {\displaystyle t} ⁠. The advantage of typed lambda calculus is that STLC allows potentially nonterminating computations to be cut short (that is, reduced). === Operational semantics === Likewise, the operational semantics of simply typed lambda calculus can be fixed as for the untyped lambda calculus, using call by name, call by value, or other evaluation strategies. As for any typed language, type safety is a fundamental property of all of these evaluation strategies. Additionally, the strong normalization property described below implies that any evaluation strategy will terminate on all simply typed terms. === Categorical semantics === The simply typed lambda calculus enriched with product types, pairing and projection operators (with β η {\displaystyle \beta \eta } -equivalence) is the internal language of Cartesian closed categories (CCCs), as was first observed by Joachim Lambek. Given any CCC, the basic types of the corresponding lambda calculus are the objects, and the terms are the morphisms. Conversely, the simply typed lambda calculus with product types and pairing operators over a collection of base types and given terms forms a CCC whose objects are the types, and morphisms are equivalence classes of terms. There are typing rules for pairing, projection, and a unit term. Given two terms s : σ {\displaystyle s{\mathbin {:}}\sigma } and ⁠ t : τ {\displaystyle t{\mathbin {:}}\tau } ⁠, the term ( s , t ) {\displaystyle (s,t)} has type ⁠ σ × τ {\displaystyle \sigma \times \tau } ⁠. Likewise, if one has a term ⁠ u : τ 1 × τ 2 {\displaystyle u{\mathbin {:}}\tau _{1}\times \tau _{2}} ⁠, then there are terms π 1 ( u ) : τ 1 {\displaystyle \pi _{1}(u){\mathbin {:}}\tau _{1}} and π 2 ( u ) : τ 2 {\displaystyle \pi _{2}(u){\mathbin {:}}\tau _{2}} where the π i {\displaystyle \pi _{i}} correspond to the projections of the Cartesian product. The unit term, of type 1, written as ( ) {\displaystyle ()} and vocalized as 'nil', is the final object. The equational theory is extended likewise, so that one has π 1 ( s : σ , t : τ ) = s : σ {\displaystyle \pi _{1}(s{\mathbin {:}}\sigma ,t{\mathbin {:}}\tau )=s{\mathbin {:}}\sigma } π 2 ( s : σ , t : τ ) = t : τ {\displaystyle \pi _{2}(s{\mathbin {:}}\sigma ,t{\mathbin {:}}\tau )=t{\mathbin {:}}\tau } ( π 1 ( u : σ × τ ) , π 2 ( u : σ × τ ) ) = u : σ × τ {\displaystyle (\pi _{1}(u{\mathbin {:}}\sigma \times \tau ),\pi _{2}(u{\mathbin {:}}\sigma \times \tau ))=u{\mathbin {:}}\sigma \times \tau } t : 1 = ( ) {\displaystyle t{\mathbin {:}}1=()} This last is read as "if t has type 1, then it reduces to nil". The above can then be turned into a category by taking the types as the objects. The morphisms σ → τ {\displaystyle \sigma \to \tau } are equivalence classes of pairs ( x : σ , t : τ ) {\displaystyle (x{\mathbin {:}}\sigma ,t{\mathbin {:}}\tau )} where x is a variable (of type ⁠ σ {\displaystyle \sigma } ⁠) and t is a term (of type ⁠ τ {\displaystyle \tau } ⁠), having no free variables in it, except for (optionally) x. The set of terms in the language is the closure of this set of terms under the operations of abstraction and application. This correspondence can be extended to include "language homomorphisms" and functors between the category of Cartesian closed categories, and the category of simply typed lambda theories. Part of this correspondence can be extended to closed symmetric monoidal categories by using a linear type system. === Proof-theoretic semantics === The simply typed lambda calculus is closely related to the implicational fragment of propositional intuitionistic logic, i.e., the implicational propositional calculus, via the Curry–Howard isomorphism: terms correspond precisely to proofs in natural deduction, and inhabited types are exactly the tautologies of this logic. From his logistic method Church 1940 p.58 laid out an axiom schema, p. 60, which Henkin 1949 filled in with type domains (e.g. the natural numbers, the real numbers, etc.). Henkin 1996 p. 146 described how Church's logistic method could seek to provide a foundation for mathematics (Peano arithmetic and real analysis), via model theory. == Alternative syntaxes == The presentation given above is not the only way of defining the syntax of the simply typed lambda calculus. One alternative is to remove type annotations entirely (so that the syntax is identical to the untyped lambda calculus), while ensuring that terms are well-typed via Hindley–Milner type inference. The inference algorithm is terminating, sound, and complete: whenever a term is typable, the algorithm computes its type. More precisely, it computes the term's principal type, since often an unannotated term (such as ⁠ λ x . x {\displaystyle \lambda x.~x} ⁠) may have more than one type (⁠ i n t → i n t {\displaystyle {\mathtt {int}}\to {\mathtt {int}}} ⁠, ⁠ b o o l → b o o l {\displaystyle {\mathtt {bool}}\to {\mathtt {bool}}} ⁠, etc., which are all instances of the principal type ⁠ α → α {\displaystyle \alpha \to \alpha } ⁠). Another alternative presentation of simply typed lambda calculus is based on bidirectional type checking, which requires more type annotations than Hindley–Milner inference but is easier to describe. The type system is divided into two judgments, representing both checking and synthesis, written Γ ⊢ e ⇐ τ {\displaystyle \Gamma \vdash e\Leftarrow \tau } and Γ ⊢ e ⇒ τ {\displaystyle \Gamma \vdash e\Rightarrow \tau } respectively. Operationally, the three components ⁠ Γ {\displaystyle \Gamma } ⁠, ⁠ e {\displaystyle e} ⁠, and τ {\displaystyle \tau } are all inputs to the checking judgment ⁠ Γ ⊢ e ⇐ τ {\displaystyle \Gamma \vdash e\Leftarrow \tau } ⁠, whereas the synthesis judgment Γ ⊢ e ⇒ τ {\displaystyle \Gamma \vdash e\Rightarrow \tau } only takes Γ {\displaystyle \Gamma } and e {\displaystyle e} as inputs, producing the type τ {\displaystyle \tau } as output. These judgments are derived via the following rules: Observe that rules [1]–[4] are nearly identical to rules (1)–(4) above, except for the careful choice of checking or synthesis judgments. These choices can be explained like so: If x : σ {\displaystyle x{\mathbin {:}}\sigma } is in the context, we can synthesize type σ {\displaystyle \sigma } for ⁠ x {\displaystyle x} ⁠. The types of term constants are fixed and can be synthesized. To check that λ x . e {\displaystyle \lambda x.~e} has type σ → τ {\displaystyle \sigma \to \tau } in some context, we extend the context with x : σ {\displaystyle x{\mathbin {:}}\sigma } and check that e {\displaystyle e} has type ⁠ τ {\displaystyle \tau } ⁠. If e 1 {\displaystyle e_{1}} synthesizes type σ → τ {\displaystyle \sigma \to \tau } (in some context), and e 2 {\displaystyle e_{2}} checks against type σ {\displaystyle \sigma } (in the same context), then e 1 e 2 {\displaystyle e_{1}~e_{2}} synthesizes type ⁠ τ {\displaystyle \tau } ⁠. Observe that the rules for synthesis are read top-to-bottom, whereas the rules for checking are read bottom-to-top. Note in particular that we do not need any annotation on the lambda abstraction in rule [3], because the type of the bound variable can be deduced from the type at which we check the function. Finally, we explain rules [5] and [6] as follows: To check that e {\displaystyle e} has type ⁠ τ {\displaystyle \tau } ⁠, it suffices to synthesize type ⁠ τ {\displaystyle \tau } ⁠. If e {\displaystyle e} checks against type ⁠ τ {\displaystyle \tau } ⁠, then the explicitly annotated term ( e : τ ) {\displaystyle (e{\mathbin {:}}\tau )} synthesizes ⁠ τ {\displaystyle \tau } ⁠. Because of these last two rules coercing between synthesis and checking, it is easy to see that any well-typed but unannotated term can be checked in the bidirectional system, so long as we insert "enough" type annotations. And in fact, annotations are needed only at β-redexes. == General observations == Given the standard semantics, the simply typed lambda calculus is strongly normalizing: every sequence of reductions eventually terminates. This is because recursion is not allowed by the typing rules: it is impossible to find types for fixed-point combinators and the looping term ⁠ Ω = ( λ x . x x ) ( λ x . x x ) {\displaystyle \Omega =(\lambda x.~x~x)(\lambda x.~x~x)} ⁠. Recursion can be added to the language by either having a special operator f i x α {\displaystyle {\mathtt {fix}}_{\alpha }} of type ( α → α ) → α {\displaystyle (\alpha \to \alpha )\to \alpha } or adding general recursive types, though both eliminate strong normalization. Unlike the untyped lambda calculus, the simply typed lambda calculus is not Turing complete. All programs in the simply typed lambda calculus halt. For the untyped lambda calculus, there are programs that do not halt, and moreover there is no general decision procedure that can determine whether a program halts. == Important results == Tait showed in 1967 that β {\displaystyle \beta } -reduction is strongly normalizing. As a corollary β η {\displaystyle \beta \eta } -equivalence is decidable. Statman showed in 1979 that the normalisation problem is not elementary recursive, a proof that was later simplified by Mairson. The problem is known to be in the set E 4 {\displaystyle {\mathcal {E}}^{4}} of the Grzegorczyk hierarchy. A purely semantic normalisation proof (see normalisation by evaluation) was given by Berger and Schwichtenberg in 1991. The unification problem for β η {\displaystyle \beta \eta } -equivalence is undecidable. Huet showed in 1973 that 3rd order unification is undecidable and this was improved upon by Baxter in 1978 then by Goldfarb in 1981 by showing that 2nd order unification is already undecidable. A proof that higher order matching (unification where only one term contains existential variables) is decidable was announced by Colin Stirling in 2006, and a full proof was published in 2009. We can encode natural numbers by terms of the type ( o → o ) → ( o → o ) {\displaystyle (o\to o)\to (o\to o)} (Church numerals). Schwichtenberg showed in 1975 that in λ → {\displaystyle \lambda ^{\to }} exactly the extended polynomials are representable as functions over Church numerals; these are roughly the polynomials closed up under a conditional operator. A full model of λ → {\displaystyle \lambda ^{\to }} is given by interpreting base types as sets and function types by the set-theoretic function space. Friedman showed in 1975 that this interpretation is complete for β η {\displaystyle \beta \eta } -equivalence, if the base types are interpreted by infinite sets. Statman showed in 1983 that β η {\displaystyle \beta \eta } -equivalence is the maximal equivalence that is typically ambiguous, i.e. closed under type substitutions (Statman's Typical Ambiguity Theorem). A corollary of this is that the finite model property holds, i.e. finite sets are sufficient to distinguish terms that are not identified by β η {\displaystyle \beta \eta } -equivalence. Plotkin introduced logical relations in 1973 to characterize the elements of a model that are definable by lambda terms. In 1993 Jung and Tiuryn showed that a general form of logical relation (Kripke logical relations with varying arity) exactly characterizes lambda definability. Plotkin and Statman conjectured that it is decidable whether a given element of a model generated from finite sets is definable by a lambda term (Plotkin–Statman conjecture). The conjecture was shown to be false by Loader in 2001. == Notes == == References == H. Barendregt, Lambda Calculi with Types, Handbook of Logic in Computer Science, Volume II, Oxford University Press, 1993. ISBN 0-19-853761-1. == External links == Loader, Ralph (February 1998). "Notes on Simply Typed Lambda Calculus". "Church's Type Theory" entry in the Stanford Encyclopedia of Philosophy
Wikipedia/Simply_typed_lambda_calculus
The following system is Mendelson's (1997, 289–293) ST type theory. ST is equivalent with Russell's ramified theory plus the Axiom of reducibility. The domain of quantification is partitioned into an ascending hierarchy of types, with all individuals assigned a type. Quantified variables range over only one type; hence the underlying logic is first-order logic. ST is "simple" (relative to the type theory of Principia Mathematica) primarily because all members of the domain and codomain of any relation must be of the same type. There is a lowest type, whose individuals have no members and are members of the second lowest type. Individuals of the lowest type correspond to the urelements of certain set theories. Each type has a next higher type, analogous to the notion of successor in Peano arithmetic. While ST is silent as to whether there is a maximal type, a transfinite number of types poses no difficulty. These facts, reminiscent of the Peano axioms, make it convenient and conventional to assign a natural number to each type, starting with 0 for the lowest type. But type theory does not require a prior definition of the naturals. The symbols peculiar to ST are primed variables and infix operator ∈ {\displaystyle \in } . In any given formula, unprimed variables all have the same type, while primed variables ( x ′ {\displaystyle x'} ) range over the next higher type. The atomic formulas of ST are of two forms, x = y {\displaystyle x=y} (identity) and y ∈ x ′ {\displaystyle y\in x'} . The infix-operator symbol ∈ {\displaystyle \in } suggests the intended interpretation, set membership. All variables appearing in the definition of identity and in the axioms Extensionality and Comprehension, range over individuals of one of two consecutive types. Only unprimed variables (ranging over the "lower" type) can appear to the left of ' ∈ {\displaystyle \in } ', whereas to its right, only primed variables (ranging over the "higher" type) can appear. The first-order formulation of ST rules out quantifying over types. Hence each pair of consecutive types requires its own axiom of Extensionality and of Comprehension, which is possible if Extensionality and Comprehension below are taken as axiom schemata "ranging over" types. Identity, defined by x = y ↔ ∀ z ′ [ x ∈ z ′ ↔ y ∈ z ′ ] {\displaystyle x=y\leftrightarrow \forall z'[x\in z'\leftrightarrow y\in z']} . Extensionality. An axiom schema. ∀ x [ x ∈ y ′ ↔ x ∈ z ′ ] → [ y ′ = z ′ ] {\displaystyle \forall x[x\in y'\leftrightarrow x\in z']\rightarrow [y'=z']} . Let Φ ( x ) {\displaystyle \Phi (x)} denote any first-order formula containing the free variable x {\displaystyle x} . Comprehension. An axiom schema. ∃ z ′ ∀ x [ x ∈ z ′ ↔ Φ ( x ) ] {\displaystyle \exists z'\forall x[x\in z'\leftrightarrow \Phi (x)]} . Remark. Any collection of elements of the same type may form an object of the next higher type. Comprehension is schematic with respect to Φ ( x ) {\displaystyle \Phi (x)} as well as to types. Infinity. There exists a nonempty binary relation R {\displaystyle R} over the individuals of the lowest type, that is irreflexive, transitive, and strongly connected: ∀ x , y [ x ≠ y → [ x R y ∨ y R x ] ] {\displaystyle \forall x,y[x\neq y\rightarrow [xRy\vee yRx]]} and with codomain contained in domain. Remark. Infinity is the only true axiom of ST and is entirely mathematical in nature. It asserts that R {\displaystyle R} is a strict total order, with a codomain contained in its domain. If 0 is assigned to the lowest type, the type of R {\displaystyle R} is 3. Infinity can be satisfied only if the (co)domain of R {\displaystyle R} is infinite, thus forcing the existence of an infinite set. If relations are defined in terms of ordered pairs, this axiom requires a prior definition of ordered pair; the Kuratowski definition, adapted to ST, will do. The literature does not explain why the usual axiom of infinity (there exists an inductive set) of ZFC of other set theories could not be married to ST. ST reveals how type theory can be made very similar to axiomatic set theory. Moreover, the more elaborate ontology of ST, grounded in what is now called the "iterative conception of set," makes for axiom (schemata) that are far simpler than those of conventional set theories, such as ZFC, with simpler ontologies. Set theories whose point of departure is type theory, but whose axioms, ontology, and terminology differ from the above, include New Foundations and Scott–Potter set theory. == Formulations based on equality == Church's type theory has been extensively studied by two of Church's students, Leon Henkin and Peter B. Andrews. Since ST is a higher order logic, and in higher order logics one can define propositional connectives in terms of logical equivalence and quantifiers, in 1963 Henkin developed a formulation of ST based on equality, but in which he restricted attention to propositional types. This was simplified later that year by Andrews in his theory Q0. In this respect ST can be seen as a particular kind of a higher-order logic, classified by P.T. Johnstone in Sketches of an Elephant, as having a lambda-signature, that is a higher-order signature that contains no relations, and uses only products and arrows (function types) as type constructors. Furthermore, as Johnstone put it, ST is "logic-free" in the sense that it contains no logical connectives or quantifiers in its formulae. == See also == Type theory == References ==
Wikipedia/ST_type_theory
In mathematics and theoretical computer science, a type theory is the formal presentation of a specific type system. Type theory is the academic study of type systems. Some type theories serve as alternatives to set theory as a foundation of mathematics. Two influential type theories that have been proposed as foundations are: Typed λ-calculus of Alonzo Church Intuitionistic type theory of Per Martin-Löf Most computerized proof-writing systems use a type theory for their foundation. A common one is Thierry Coquand's Calculus of Inductive Constructions. == History == Type theory was created to avoid paradoxes in naive set theory and formal logic, such as Russell's paradox which demonstrates that, without proper axioms, it is possible to define the set of all sets that are not members of themselves; this set both contains itself and does not contain itself. Between 1902 and 1908, Bertrand Russell proposed various solutions to this problem. By 1908, Russell arrived at a ramified theory of types together with an axiom of reducibility, both of which appeared in Whitehead and Russell's Principia Mathematica published in 1910, 1912, and 1913. This system avoided contradictions suggested in Russell's paradox by creating a hierarchy of types and then assigning each concrete mathematical entity to a specific type. Entities of a given type were built exclusively of subtypes of that type, thus preventing an entity from being defined using itself. This resolution of Russell's paradox is similar to approaches taken in other formal systems, such as Zermelo-Fraenkel set theory. Type theory is particularly popular in conjunction with Alonzo Church's lambda calculus. One notable early example of type theory is Church's simply typed lambda calculus. Church's theory of types helped the formal system avoid the Kleene–Rosser paradox that afflicted the original untyped lambda calculus. Church demonstrated that it could serve as a foundation of mathematics and it was referred to as a higher-order logic. In the modern literature, "type theory" refers to a typed system based around lambda calculus. One influential system is Per Martin-Löf's intuitionistic type theory, which was proposed as a foundation for constructive mathematics. Another is Thierry Coquand's calculus of constructions, which is used as the foundation by Rocq (previously known as Coq), Lean, and other computer proof assistants. Type theory is an active area of research, one direction being the development of homotopy type theory. == Applications == === Mathematical foundations === The first computer proof assistant, called Automath, used type theory to encode mathematics on a computer. Martin-Löf specifically developed intuitionistic type theory to encode all mathematics to serve as a new foundation for mathematics. There is ongoing research into mathematical foundations using homotopy type theory. Mathematicians working in category theory already had difficulty working with the widely accepted foundation of Zermelo–Fraenkel set theory. This led to proposals such as Lawvere's Elementary Theory of the Category of Sets (ETCS). Homotopy type theory continues in this line using type theory. Researchers are exploring connections between dependent types (especially the identity type) and algebraic topology (specifically homotopy). === Proof assistants === Much of the current research into type theory is driven by proof checkers, interactive proof assistants, and automated theorem provers. Most of these systems use a type theory as the mathematical foundation for encoding proofs, which is not surprising, given the close connection between type theory and programming languages: LF is used by Twelf, often to define other type theories; many type theories which fall under higher-order logic are used by the HOL family of provers and PVS; computational type theory is used by NuPRL; calculus of constructions and its derivatives are used by Rocq (previously known as Coq), Matita, and Lean; UTT (Luo's Unified Theory of dependent Types) is used by Agda which is both a programming language and proof assistant Many type theories are supported by LEGO and Isabelle. Isabelle also supports foundations besides type theories, such as ZFC. Mizar is an example of a proof system that only supports set theory. === Programming languages === Any static program analysis, such as the type checking algorithms in the semantic analysis phase of compiler, has a connection to type theory. A prime example is Agda, a programming language which uses UTT (Luo's Unified Theory of dependent Types) for its type system. The programming language ML was developed for manipulating type theories (see LCF) and its own type system was heavily influenced by them. === Linguistics === Type theory is also widely used in formal theories of semantics of natural languages, especially Montague grammar and its descendants. In particular, categorial grammars and pregroup grammars extensively use type constructors to define the types (noun, verb, etc.) of words. The most common construction takes the basic types e {\displaystyle e} and t {\displaystyle t} for individuals and truth-values, respectively, and defines the set of types recursively as follows: if a {\displaystyle a} and b {\displaystyle b} are types, then so is ⟨ a , b ⟩ {\displaystyle \langle a,b\rangle } ; nothing except the basic types, and what can be constructed from them by means of the previous clause are types. A complex type ⟨ a , b ⟩ {\displaystyle \langle a,b\rangle } is the type of functions from entities of type a {\displaystyle a} to entities of type b {\displaystyle b} . Thus one has types like ⟨ e , t ⟩ {\displaystyle \langle e,t\rangle } which are interpreted as elements of the set of functions from entities to truth-values, i.e. indicator functions of sets of entities. An expression of type ⟨ ⟨ e , t ⟩ , t ⟩ {\displaystyle \langle \langle e,t\rangle ,t\rangle } is a function from sets of entities to truth-values, i.e. a (indicator function of a) set of sets. This latter type is standardly taken to be the type of natural language quantifiers, like everybody or nobody (Montague 1973, Barwise and Cooper 1981). Type theory with records is a formal semantics representation framework, using records to express type theory types. It has been used in natural language processing, principally computational semantics and dialogue systems. === Social sciences === Gregory Bateson introduced a theory of logical types into the social sciences; his notions of double bind and logical levels are based on Russell's theory of types. == Logic == A type theory is a mathematical logic, which is to say it is a collection of rules of inference that result in judgments. Most logics have judgments asserting "The proposition φ {\displaystyle \varphi } is true", or "The formula φ {\displaystyle \varphi } is a well-formed formula". A type theory has judgments that define types and assign them to a collection of formal objects, known as terms. A term and its type are often written together as t e r m : t y p e {\displaystyle \mathrm {term} :{\mathsf {type}}} . === Terms === A term in logic is recursively defined as a constant symbol, variable, or a function application, where a term is applied to another term. Constant symbols could include the natural number 0 {\displaystyle 0} , the Boolean value t r u e {\displaystyle \mathrm {true} } , and functions such as the successor function S {\displaystyle \mathrm {S} } and conditional operator i f {\displaystyle \mathrm {if} } . Thus some terms could be 0 {\displaystyle 0} , ( S 0 ) {\displaystyle (\mathrm {S} \,0)} , ( S ( S 0 ) ) {\displaystyle (\mathrm {S} \,(\mathrm {S} \,0))} , and ( i f t r u e 0 ( S 0 ) ) {\displaystyle (\mathrm {if} \,\mathrm {true} \,0\,(\mathrm {S} \,0))} . === Judgments === Most type theories have 4 judgments: " T {\displaystyle T} is a type" " t {\displaystyle t} is a term of type T {\displaystyle T} " "Type T 1 {\displaystyle T_{1}} is equal to type T 2 {\displaystyle T_{2}} " "Terms t 1 {\displaystyle t_{1}} and t 2 {\displaystyle t_{2}} both of type T {\displaystyle T} are equal" Judgments may follow from assumptions. For example, one might say "assuming x {\displaystyle x} is a term of type b o o l {\displaystyle {\mathsf {bool}}} and y {\displaystyle y} is a term of type n a t {\displaystyle {\mathsf {nat}}} , it follows that ( i f x y y ) {\displaystyle (\mathrm {if} \,x\,y\,y)} is a term of type n a t {\displaystyle {\mathsf {nat}}} ". Such judgments are formally written with the turnstile symbol ⊢ {\displaystyle \vdash } . x : b o o l , y : n a t ⊢ ( if x y y ) : n a t {\displaystyle x:{\mathsf {bool}},y:{\mathsf {nat}}\vdash ({\textrm {if}}\,x\,y\,y):{\mathsf {nat}}} If there are no assumptions, there will be nothing to the left of the turnstile. ⊢ S : n a t → n a t {\displaystyle \vdash \mathrm {S} :{\mathsf {nat}}\to {\mathsf {nat}}} The list of assumptions on the left is the context of the judgment. Capital greek letters, such as Γ {\displaystyle \Gamma } and Δ {\displaystyle \Delta } , are common choices to represent some or all of the assumptions. The 4 different judgments are thus usually written as follows. Some textbooks use a triple equal sign ≡ {\displaystyle \equiv } to stress that this is judgmental equality and thus an extrinsic notion of equality. The judgments enforce that every term has a type. The type will restrict which rules can be applied to a term. === Rules of Inference === A type theory's inference rules say what judgments can be made, based on the existence of other judgments. Rules are expressed as a Gentzen-style deduction using a horizontal line, with the required input judgments above the line and the resulting judgment below the line. For example, the following inference rule states a substitution rule for judgmental equality. Γ ⊢ t : T 1 Δ ⊢ T 1 = T 2 Γ , Δ ⊢ t : T 2 {\displaystyle {\begin{array}{c}\Gamma \vdash t:T_{1}\qquad \Delta \vdash T_{1}=T_{2}\\\hline \Gamma ,\Delta \vdash t:T_{2}\end{array}}} The rules are syntactic and work by rewriting. The metavariables Γ {\displaystyle \Gamma } , Δ {\displaystyle \Delta } , t {\displaystyle t} , T 1 {\displaystyle T_{1}} , and T 2 {\displaystyle T_{2}} may actually consist of complex terms and types that contain many function applications, not just single symbols. To generate a particular judgment in type theory, there must be a rule to generate it, as well as rules to generate all of that rule's required inputs, and so on. The applied rules form a proof tree, where the top-most rules need no assumptions. One example of a rule that does not require any inputs is one that states the type of a constant term. For example, to assert that there is a term 0 {\displaystyle 0} of type n a t {\displaystyle {\mathsf {nat}}} , one would write the following. ⊢ 0 : n a t {\displaystyle {\begin{array}{c}\hline \vdash 0:nat\\\end{array}}} ==== Type inhabitation ==== Generally, the desired conclusion of a proof in type theory is one of type inhabitation. The decision problem of type inhabitation (abbreviated by ∃ t . Γ ⊢ t : τ ? {\displaystyle \exists t.\Gamma \vdash t:\tau ?} ) is: Given a context Γ {\displaystyle \Gamma } and a type τ {\displaystyle \tau } , decide whether there exists a term t {\displaystyle t} that can be assigned the type τ {\displaystyle \tau } in the type environment Γ {\displaystyle \Gamma } . Girard's paradox shows that type inhabitation is strongly related to the consistency of a type system with Curry–Howard correspondence. To be sound, such a system must have uninhabited types. A type theory usually has several rules, including ones to: create a judgment (known as a context in this case) add an assumption to the context (context weakening) rearrange the assumptions use an assumption to create a variable define reflexivity, symmetry and transitivity for judgmental equality define substitution for application of lambda terms list all the interactions of equality, such as substitution define a hierarchy of type universes assert the existence of new types Also, for each "by rule" type, there are 4 different kinds of rules "type formation" rules say how to create the type "term introduction" rules define the canonical terms and constructor functions, like "pair" and "S". "term elimination" rules define the other functions like "first", "second", and "R". "computation" rules specify how computation is performed with the type-specific functions. For examples of rules, an interested reader may follow Appendix A.2 of the Homotopy Type Theory book, or read Martin-Löf's Intuitionistic Type Theory. == Connections to foundations == The logical framework of a type theory bears a resemblance to intuitionistic, or constructive, logic. Formally, type theory is often cited as an implementation of the Brouwer–Heyting–Kolmogorov interpretation of intuitionistic logic. Additionally, connections can be made to category theory and computer programs. === Intuitionistic logic === When used as a foundation, certain types are interpreted to be propositions (statements that can be proven), and terms inhabiting the type are interpreted to be proofs of that proposition. When some types are interpreted as propositions, there is a set of common types that can be used to connect them to make a Boolean algebra out of types. However, the logic is not classical logic but intuitionistic logic, which is to say it does not have the law of excluded middle nor double negation. Under this intuitionistic interpretation, there are common types that act as the logical operators: Because the law of excluded middle does not hold, there is no term of type Π a . A + ( A → ⊥ ) {\displaystyle \Pi a.A+(A\to \bot )} . Likewise, double negation does not hold, so there is no term of type Π A . ( ( A → ⊥ ) → ⊥ ) → A {\displaystyle \Pi A.((A\to \bot )\to \bot )\to A} . It is possible to include the law of excluded middle and double negation into a type theory, by rule or assumption. However, terms may not compute down to canonical terms and it will interfere with the ability to determine if two terms are judgementally equal to each other. ==== Constructive mathematics ==== Per Martin-Löf proposed his intuitionistic type theory as a foundation for constructive mathematics. Constructive mathematics requires when proving "there exists an x {\displaystyle x} with property P ( x ) {\displaystyle P(x)} ", one must construct a particular x {\displaystyle x} and a proof that it has property P {\displaystyle P} . In type theory, existence is accomplished using the dependent product type, and its proof requires a term of that type. An example of a non-constructive proof is proof by contradiction. The first step is assuming that x {\displaystyle x} does not exist and refuting it by contradiction. The conclusion from that step is "it is not the case that x {\displaystyle x} does not exist". The last step is, by double negation, concluding that x {\displaystyle x} exists. Constructive mathematics does not allow the last step of removing the double negation to conclude that x {\displaystyle x} exists. Most of the type theories proposed as foundations are constructive, and this includes most of the ones used by proof assistants. It is possible to add non-constructive features to a type theory, by rule or assumption. These include operators on continuations such as call with current continuation. However, these operators tend to break desirable properties such as canonicity and parametricity. === Curry-Howard correspondence === The Curry–Howard correspondence is the observed similarity between logics and programming languages. The implication in logic, "A → {\displaystyle \to } B" resembles a function from type "A" to type "B". For a variety of logics, the rules are similar to expressions in a programming language's types. The similarity goes farther, as applications of the rules resemble programs in the programming languages. Thus, the correspondence is often summarized as "proofs as programs". The opposition of terms and types can also be viewed as one of implementation and specification. By program synthesis, (the computational counterpart of) type inhabitation can be used to construct (all or parts of) programs from the specification given in the form of type information. ==== Type inference ==== Many programs that work with type theory (e.g., interactive theorem provers) also do type inferencing. It lets them select the rules that the user intends, with fewer actions by the user. === Research areas === ==== Category theory ==== Although the initial motivation for category theory was far removed from foundationalism, the two fields turned out to have deep connections. As John Lane Bell writes: "In fact categories can themselves be viewed as type theories of a certain kind; this fact alone indicates that type theory is much more closely related to category theory than it is to set theory." In brief, a category can be viewed as a type theory by regarding its objects as types (or sorts ), i.e. "Roughly speaking, a category may be thought of as a type theory shorn of its syntax." A number of significant results follow in this way: cartesian closed categories correspond to the typed λ-calculus (Lambek, 1970); C-monoids (categories with products and exponentials and one non-terminal object) correspond to the untyped λ-calculus (observed independently by Lambek and Dana Scott around 1980); locally cartesian closed categories correspond to Martin-Löf type theories (Seely, 1984). The interplay, known as categorical logic, has been a subject of active research since then; see the monograph of Jacobs (1999) for instance. ==== Homotopy type theory ==== Homotopy type theory attempts to combine type theory and category theory. It focuses on equalities, especially equalities between types. Homotopy type theory differs from intuitionistic type theory mostly by its handling of the equality type. In 2016, cubical type theory was proposed, which is a homotopy type theory with normalization. == Definitions == === Terms and types === ==== Atomic terms ==== The most basic types are called atoms, and a term whose type is an atom is known as an atomic term. Common atomic terms included in type theories are natural numbers, often notated with the type n a t {\displaystyle {\mathsf {nat}}} , Boolean logic values ( t r u e {\displaystyle \mathrm {true} } / f a l s e {\displaystyle \mathrm {false} } ), notated with the type b o o l {\displaystyle {\mathsf {bool}}} , and formal variables, whose type may vary. For example, the following may be atomic terms. 42 : n a t {\displaystyle 42:{\mathsf {nat}}} t r u e : b o o l {\displaystyle \mathrm {true} :{\mathsf {bool}}} x : n a t {\displaystyle x:{\mathsf {nat}}} y : b o o l {\displaystyle y:{\mathsf {bool}}} ==== Function terms ==== In addition to atomic terms, most modern type theories also allow for functions. Function types introduce an arrow symbol, and are defined inductively: If σ {\displaystyle \sigma } and τ {\displaystyle \tau } are types, then the notation σ → τ {\displaystyle \sigma \to \tau } is the type of a function which takes a parameter of type σ {\displaystyle \sigma } and returns a term of type τ {\displaystyle \tau } . Types of this form are known as simple types. Some terms may be declared directly as having a simple type, such as the following term, a d d {\displaystyle \mathrm {add} } , which takes in two natural numbers in sequence and returns one natural number. a d d : n a t → ( n a t → n a t ) {\displaystyle \mathrm {add} :{\mathsf {nat}}\to ({\mathsf {nat}}\to {\mathsf {nat}})} Strictly speaking, a simple type only allows for one input and one output, so a more faithful reading of the above type is that a d d {\displaystyle \mathrm {add} } is a function which takes in a natural number and returns a function of the form n a t → n a t {\displaystyle {\mathsf {nat}}\to {\mathsf {nat}}} . The parentheses clarify that a d d {\displaystyle \mathrm {add} } does not have the type ( n a t → n a t ) → n a t {\displaystyle ({\mathsf {nat}}\to {\mathsf {nat}})\to {\mathsf {nat}}} , which would be a function which takes in a function of natural numbers and returns a natural number. The convention is that the arrow is right associative, so the parentheses may be dropped from a d d {\displaystyle \mathrm {add} } 's type. ==== Lambda terms ==== New function terms may be constructed using lambda expressions, and are called lambda terms. These terms are also defined inductively: a lambda term has the form ( λ v . t ) {\displaystyle (\lambda v.t)} , where v {\displaystyle v} is a formal variable and t {\displaystyle t} is a term, and its type is notated σ → τ {\displaystyle \sigma \to \tau } , where σ {\displaystyle \sigma } is the type of v {\displaystyle v} , and τ {\displaystyle \tau } is the type of t {\displaystyle t} . The following lambda term represents a function which doubles an input natural number. ( λ x . a d d x x ) : n a t → n a t {\displaystyle (\lambda x.\mathrm {add} \,x\,x):{\mathsf {nat}}\to {\mathsf {nat}}} The variable is x {\displaystyle x} and (implicit from the lambda term's type) must have type n a t {\displaystyle {\mathsf {nat}}} . The term a d d x x {\displaystyle \mathrm {add} \,x\,x} has type n a t {\displaystyle {\mathsf {nat}}} , which is seen by applying the function application inference rule twice. Thus, the lambda term has type n a t → n a t {\displaystyle {\mathsf {nat}}\to {\mathsf {nat}}} , which means it is a function taking a natural number as an argument and returning a natural number. A lambda term is often referred to as an anonymous function because it lacks a name. The concept of anonymous functions appears in many programming languages. === Inference Rules === ==== Function application ==== The power of type theories is in specifying how terms may be combined by way of inference rules. Type theories which have functions also have the inference rule of function application: if t {\displaystyle t} is a term of type σ → τ {\displaystyle \sigma \to \tau } , and s {\displaystyle s} is a term of type σ {\displaystyle \sigma } , then the application of t {\displaystyle t} to s {\displaystyle s} , often written ( t s ) {\displaystyle (t\,s)} , has type τ {\displaystyle \tau } . For example, if one knows the type notations 0 : nat {\displaystyle 0:{\textsf {nat}}} , 1 : nat {\displaystyle 1:{\textsf {nat}}} , and 2 : nat {\displaystyle 2:{\textsf {nat}}} , then the following type notations can be deduced from function application. ( a d d 1 ) : nat → nat {\displaystyle (\mathrm {add} \,1):{\textsf {nat}}\to {\textsf {nat}}} ( ( a d d 2 ) 0 ) : nat {\displaystyle ((\mathrm {add} \,2)\,0):{\textsf {nat}}} ( ( a d d 1 ) ( ( a d d 2 ) 0 ) ) : nat {\displaystyle ((\mathrm {add} \,1)((\mathrm {add} \,2)\,0)):{\textsf {nat}}} Parentheses indicate the order of operations; however, by convention, function application is left associative, so parentheses can be dropped where appropriate. In the case of the three examples above, all parentheses could be omitted from the first two, and the third may simplified to a d d 1 ( a d d 2 0 ) : nat {\displaystyle \mathrm {add} \,1\,(\mathrm {add} \,2\,0):{\textsf {nat}}} . ==== Reductions ==== Type theories that allow for lambda terms also include inference rules known as β {\displaystyle \beta } -reduction and η {\displaystyle \eta } -reduction. They generalize the notion of function application to lambda terms. Symbolically, they are written ( λ v . t ) s → t [ v : = s ] {\displaystyle (\lambda v.t)\,s\rightarrow t[v\colon =s]} ( β {\displaystyle \beta } -reduction). ( λ v . t v ) → t {\displaystyle (\lambda v.t\,v)\rightarrow t} , if v {\displaystyle v} is not a free variable in t {\displaystyle t} ( η {\displaystyle \eta } -reduction). The first reduction describes how to evaluate a lambda term: if a lambda expression ( λ v . t ) {\displaystyle (\lambda v.t)} is applied to a term s {\displaystyle s} , one replaces every occurrence of v {\displaystyle v} in t {\displaystyle t} with s {\displaystyle s} . The second reduction makes explicit the relationship between lambda expressions and function types: if ( λ v . t v ) {\displaystyle (\lambda v.t\,v)} is a lambda term, then it must be that t {\displaystyle t} is a function term because it is being applied to v {\displaystyle v} . Therefore, the lambda expression is equivalent to just t {\displaystyle t} , as both take in one argument and apply t {\displaystyle t} to it. For example, the following term may be β {\displaystyle \beta } -reduced. ( λ x . a d d x x ) 2 → a d d 2 2 {\displaystyle (\lambda x.\mathrm {add} \,x\,x)\,2\rightarrow \mathrm {add} \,2\,2} In type theories that also establish notions of equality for types and terms, there are corresponding inference rules of β {\displaystyle \beta } -equality and η {\displaystyle \eta } -equality. === Common terms and types === ==== Empty type ==== The empty type has no terms. The type is usually written ⊥ {\displaystyle \bot } or 0 {\displaystyle \mathbb {0} } . One use for the empty type is proofs of type inhabitation. If for a type a {\displaystyle a} , it is consistent to derive a function of type a → ⊥ {\displaystyle a\to \bot } , then a {\displaystyle a} is uninhabited, which is to say it has no terms. ==== Unit type ==== The unit type has exactly 1 canonical term. The type is written ⊤ {\displaystyle \top } or 1 {\displaystyle \mathbb {1} } and the single canonical term is written ∗ {\displaystyle \ast } . The unit type is also used in proofs of type inhabitation. If for a type a {\displaystyle a} , it is consistent to derive a function of type ⊤ → a {\displaystyle \top \to a} , then a {\displaystyle a} is inhabited, which is to say it must have one or more terms. ==== Boolean type ==== The Boolean type has exactly 2 canonical terms. The type is usually written bool {\displaystyle {\textsf {bool}}} or B {\displaystyle \mathbb {B} } or 2 {\displaystyle \mathbb {2} } . The canonical terms are usually t r u e {\displaystyle \mathrm {true} } and f a l s e {\displaystyle \mathrm {false} } . ==== Natural numbers ==== Natural numbers are usually implemented in the style of Peano Arithmetic. There is a canonical term 0 : n a t {\displaystyle 0:{\mathsf {nat}}} for zero. Canonical values larger than zero use iterated applications of a successor function S : n a t → n a t {\displaystyle \mathrm {S} :{\mathsf {nat}}\to {\mathsf {nat}}} . === Type constructors === Some type theories allow for types of complex terms, such as functions or lists, to depend on the types of its arguments; these are called type constructors. For example, a type theory could have the dependent type l i s t a {\displaystyle {\mathsf {list}}\,a} , which should correspond to lists of terms, where each term must have type a {\displaystyle a} . In this case, l i s t {\displaystyle {\mathsf {list}}} has the kind U → U {\displaystyle U\to U} , where U {\displaystyle U} denotes the universe of all types in the theory. ==== Product type ==== The product type, × {\displaystyle \times } , depends on two types, and its terms are commonly written as ordered pairs ( s , t ) {\displaystyle (s,t)} . The pair ( s , t ) {\displaystyle (s,t)} has the product type σ × τ {\displaystyle \sigma \times \tau } , where σ {\displaystyle \sigma } is the type of s {\displaystyle s} and τ {\displaystyle \tau } is the type of t {\displaystyle t} . Each product type is then usually defined with eliminator functions f i r s t : σ × τ → σ {\displaystyle \mathrm {first} :\sigma \times \tau \to \sigma } and s e c o n d : σ × τ → τ {\displaystyle \mathrm {second} :\sigma \times \tau \to \tau } . f i r s t ( s , t ) {\displaystyle \mathrm {first} \,(s,t)} returns s {\displaystyle s} , and s e c o n d ( s , t ) {\displaystyle \mathrm {second} \,(s,t)} returns t {\displaystyle t} . Besides ordered pairs, this type is used for the concepts of logical conjunction and intersection. ==== Sum type ==== The sum type is written as either + {\displaystyle +} or ⊔ {\displaystyle \sqcup } . In programming languages, sum types may be referred to as tagged unions. Each type σ ⊔ τ {\displaystyle \sigma \sqcup \tau } is usually defined with constructors l e f t : σ → ( σ ⊔ τ ) {\displaystyle \mathrm {left} :\sigma \to (\sigma \sqcup \tau )} and r i g h t : τ → ( σ ⊔ τ ) {\displaystyle \mathrm {right} :\tau \to (\sigma \sqcup \tau )} , which are injective, and an eliminator function m a t c h : ( σ → ρ ) → ( τ → ρ ) → ( σ ⊔ τ ) → ρ {\displaystyle \mathrm {match} :(\sigma \to \rho )\to (\tau \to \rho )\to (\sigma \sqcup \tau )\to \rho } such that m a t c h f g ( l e f t x ) {\displaystyle \mathrm {match} \,f\,g\,(\mathrm {left} \,x)} returns f x {\displaystyle f\,x} , and m a t c h f g ( r i g h t y ) {\displaystyle \mathrm {match} \,f\,g\,(\mathrm {right} \,y)} returns g y {\displaystyle g\,y} . The sum type is used for the concepts of logical disjunction and union. === Polymorphic types === Some theories also allow terms to have their definitions depend on types. For instance, an identity function of any type could be written as λ x . x : ∀ α . α → α {\displaystyle \lambda x.x:\forall \alpha .\alpha \to \alpha } . The function is said to be polymorphic in α {\displaystyle \alpha } , or generic in x {\displaystyle x} . As another example, consider a function a p p e n d {\displaystyle \mathrm {append} } , which takes in a l i s t a {\displaystyle {\mathsf {list}}\,a} and a term of type a {\displaystyle a} , and returns the list with the element at the end. The type annotation of such a function would be a p p e n d : ∀ a . l i s t a → a → l i s t a {\displaystyle \mathrm {append} :\forall \,a.{\mathsf {list}}\,a\to a\to {\mathsf {list}}\,a} , which can be read as "for any type a {\displaystyle a} , pass in a l i s t a {\displaystyle {\mathsf {list}}\,a} and an a {\displaystyle a} , and return a l i s t a {\displaystyle {\mathsf {list}}\,a} ". Here a p p e n d {\displaystyle \mathrm {append} } is polymorphic in a {\displaystyle a} . ==== Products and sums ==== With polymorphism, the eliminator functions can be defined generically for all product types as f i r s t : ∀ σ τ . σ × τ → σ {\displaystyle \mathrm {first} :\forall \,\sigma \,\tau .\sigma \times \tau \to \sigma } and s e c o n d : ∀ σ τ . σ × τ → τ {\displaystyle \mathrm {second} :\forall \,\sigma \,\tau .\sigma \times \tau \to \tau } . f i r s t ( s , t ) {\displaystyle \mathrm {first} \,(s,t)} returns s {\displaystyle s} , and s e c o n d ( s , t ) {\displaystyle \mathrm {second} \,(s,t)} returns t {\displaystyle t} . Likewise, the sum type constructors can be defined for all valid types of sum members as l e f t : ∀ σ τ . σ → ( σ ⊔ τ ) {\displaystyle \mathrm {left} :\forall \,\sigma \,\tau .\sigma \to (\sigma \sqcup \tau )} and r i g h t : ∀ σ τ . τ → ( σ ⊔ τ ) {\displaystyle \mathrm {right} :\forall \,\sigma \,\tau .\tau \to (\sigma \sqcup \tau )} , which are injective, and the eliminator function can be given as m a t c h : ∀ σ τ ρ . ( σ → ρ ) → ( τ → ρ ) → ( σ ⊔ τ ) → ρ {\displaystyle \mathrm {match} :\forall \,\sigma \,\tau \,\rho .(\sigma \to \rho )\to (\tau \to \rho )\to (\sigma \sqcup \tau )\to \rho } such that m a t c h f g ( l e f t x ) {\displaystyle \mathrm {match} \,f\,g\,(\mathrm {left} \,x)} returns f x {\displaystyle f\,x} , and m a t c h f g ( r i g h t y ) {\displaystyle \mathrm {match} \,f\,g\,(\mathrm {right} \,y)} returns g y {\displaystyle g\,y} . === Dependent typing === Some theories also permit types to be dependent on terms instead of types. For example, a theory could have the type v e c t o r n {\displaystyle {\mathsf {vector}}\,n} , where n {\displaystyle n} is a term of type n a t {\displaystyle {\mathsf {nat}}} encoding the length of the vector. This allows for greater specificity and type safety: functions with vector length restrictions or length matching requirements, such as the dot product, can encode this requirement as part of the type. There are foundational issues that can arise from dependent types if a theory is not careful about what dependencies are allowed, such as Girard's Paradox. The logician Henk Barendegt introduced the lambda cube as a framework for studying various restrictions and levels of dependent typing. ==== Dependent products and sums ==== Two common type dependencies, dependent product and dependent sum types, allow for the theory to encode BHK intuitionistic logic by acting as equivalents to universal and existential quantification; this is formalized by Curry–Howard Correspondence. As they also connect to products and sums in set theory, they are often written with the symbols Π {\displaystyle \Pi } and Σ {\displaystyle \Sigma } , respectively. Sum types are seen in dependent pairs, where the second type depends on the value of the first term. This arises naturally in computer science where functions may return different types of outputs based on the input. For example, the Boolean type is usually defined with an eliminator function i f {\displaystyle \mathrm {if} } , which takes three arguments and behaves as follows. i f t r u e x y {\displaystyle \mathrm {if} \,\mathrm {true} \,x\,y} returns x {\displaystyle x} , and i f f a l s e x y {\displaystyle \mathrm {if} \,\mathrm {false} \,x\,y} returns y {\displaystyle y} . Ordinary definitions of i f {\displaystyle \mathrm {if} } require x {\displaystyle x} and y {\displaystyle y} to have the same type. If the type theory allows for dependent types, then it is possible to define a dependent type x : b o o l ⊢ T F x : U → U → U {\displaystyle x:{\mathsf {bool}}\,\vdash \,\mathrm {TF} \,x:U\to U\to U} such that T F t r u e σ τ {\displaystyle \mathrm {TF} \,\mathrm {true} \,\sigma \,\tau } returns σ {\displaystyle \sigma } , and T F f a l s e σ τ {\displaystyle \mathrm {TF} \,\mathrm {false} \,\sigma \,\tau } returns τ {\displaystyle \tau } . The type of i f {\displaystyle \mathrm {if} } may then be written as ∀ σ τ . Π x : b o o l . σ → τ → T F x σ τ {\displaystyle \forall \,\sigma \,\tau .\Pi _{x:{\mathsf {bool}}}.\sigma \to \tau \to \mathrm {TF} \,x\,\sigma \,\tau } . ==== Identity type ==== Following the notion of Curry-Howard Correspondence, the identity type is a type introduced to mirror propositional equivalence, as opposed to the judgmental (syntactic) equivalence that type theory already provides. An identity type requires two terms of the same type and is written with the symbol = {\displaystyle =} . For example, if x + 1 {\displaystyle x+1} and 1 + x {\displaystyle 1+x} are terms, then x + 1 = 1 + x {\displaystyle x+1=1+x} is a possible type. Canonical terms are created with a reflexivity function, r e f l {\displaystyle \mathrm {refl} } . For a term t {\displaystyle t} , the call r e f l t {\displaystyle \mathrm {refl} \,t} returns the canonical term inhabiting the type t = t {\displaystyle t=t} . The complexities of equality in type theory make it an active research topic; homotopy type theory is a notable area of research that mainly deals with equality in type theory. ==== Inductive types ==== Inductive types are a general template for creating a large variety of types. In fact, all the types described above and more can be defined using the rules of inductive types. Two methods of generating inductive types are induction-recursion and induction-induction. A method that only uses lambda terms is Scott encoding. Some proof assistants, such as Rocq (previously known as Coq) and Lean, are based on the calculus for inductive constructions, which is a calculus of constructions with inductive types. == Differences from set theory == The most commonly accepted foundation for mathematics is first-order logic with the language and axioms of Zermelo–Fraenkel set theory with the axiom of choice, abbreviated ZFC. Type theories having sufficient expressibility may also act as a foundation of mathematics. There are a number of differences between these two approaches. Set theory has both rules and axioms, while type theories only have rules. Type theories, in general, do not have axioms and are defined by their rules of inference. Classical set theory and logic have the law of excluded middle. When a type theory encodes the concepts of "and" and "or" as types, it leads to intuitionistic logic, and does not necessarily have the law of excluded middle. In set theory, an element is not restricted to one set. The element can appear in subsets and unions with other sets. In type theory, terms (generally) belong to only one type. Where a subset would be used, type theory can use a predicate function or use a dependently-typed product type, where each element x {\displaystyle x} is paired with a proof that the subset's property holds for x {\displaystyle x} . Where a union would be used, type theory uses the sum type, which contains new canonical terms. Type theory has a built-in notion of computation. Thus, "1+1" and "2" are different terms in type theory, but they compute to the same value. Moreover, functions are defined computationally as lambda terms. In set theory, "1+1=2" means that "1+1" is just another way to refer the value "2". Type theory's computation does require a complicated concept of equality. Set theory encodes numbers as sets. Type theory can encode numbers as functions using Church encoding, or more naturally as inductive types, and the construction closely resembles Peano's axioms. In type theory, proofs are types whereas in set theory, proofs are part of the underlying first-order logic. Proponents of type theory will also point out its connection to constructive mathematics through the BHK interpretation, its connection to logic by the Curry–Howard isomorphism, and its connections to Category theory. === Properties of type theories === Terms usually belong to a single type. However, there are set theories that define "subtyping". Computation takes place by repeated application of rules. Many types of theories are strongly normalizing, which means that any order of applying the rules will always end in the same result. However, some are not. In a normalizing type theory, the one-directional computation rules are called "reduction rules", and applying the rules "reduces" the term. If a rule is not one-directional, it is called a "conversion rule". Some combinations of types are equivalent to other combinations of types. When functions are considered "exponentiation", the combinations of types can be written similarly to algebraic identities. Thus, 0 + A ≅ A {\displaystyle {\mathbb {0} }+A\cong A} , 1 × A ≅ A {\displaystyle {\mathbb {1} }\times A\cong A} , 1 + 1 ≅ 2 {\displaystyle {\mathbb {1} }+{\mathbb {1} }\cong {\mathbb {2} }} , A B + C ≅ A B × A C {\displaystyle A^{B+C}\cong A^{B}\times A^{C}} , A B × C ≅ ( A B ) C {\displaystyle A^{B\times C}\cong (A^{B})^{C}} . === Axioms === Most type theories do not have axioms. This is because a type theory is defined by its rules of inference. This is a source of confusion for people familiar with Set Theory, where a theory is defined by both the rules of inference for a logic (such as first-order logic) and axioms about sets. Sometimes, a type theory will add a few axioms. An axiom is a judgment that is accepted without a derivation using the rules of inference. They are often added to ensure properties that cannot be added cleanly through the rules. Axioms can cause problems if they introduce terms without a way to compute on those terms. That is, axioms can interfere with the normalizing property of the type theory. Some commonly encountered axioms are: "Axiom K" ensures "uniqueness of identity proofs". That is, that every term of an identity type is equal to reflexivity. "Univalence Axiom" holds that equivalence of types is equality of types. The research into this property led to cubical type theory, where the property holds without needing an axiom. "Law of Excluded Middle" is often added to satisfy users who want classical logic, instead of intuitionistic logic. The Axiom of Choice does not need to be added to type theory, because in most type theories it can be derived from the rules of inference. This is because of the constructive nature of type theory, where proving that a value exists requires a method to compute the value. The Axiom of Choice is less powerful in type theory than most set theories, because type theory's functions must be computable and, being syntax-driven, the number of terms in a type must be countable. (See Axiom of choice § In constructive mathematics.) == List of type theories == === Major === Simply typed lambda calculus which is a higher-order logic Intuitionistic type theory System F LF is often used to define other type theories Calculus of constructions and its derivatives === Minor === Automath ST type theory UTT (Luo's Unified Theory of dependent Types) some forms of combinatory logic others defined in the lambda cube (also known as pure type systems) others under the name typed lambda calculus === Active research === Homotopy type theory explores equality of types Cubical Type Theory is an implementation of homotopy type theory == See also == Class (set theory) Type–token distinction == Further reading == == Notes == == References == == External links == === Introductory material === Type Theory at nLab, which has articles on many topics. Intuitionistic Type Theory article at the Stanford Encyclopedia of Philosophy Lambda Calculi with Types book by Henk Barendregt Calculus of Constructions / Typed Lambda Calculus textbook style paper by Helmut Brandl Intuitionistic Type Theory notes by Per Martin-Löf Programming in Martin-Löf's Type Theory book Homotopy Type Theory book, which proposed homotopy type theory as a mathematical foundation. === Advanced material === Robert L. Constable (ed.). "Computational type theory". Scholarpedia. The TYPES Forum — moderated e-mail forum focusing on type theory in computer science, operating since 1987. The Nuprl Book: "Introduction to Type Theory." Types Project lecture notes of summer schools 2005–2008 The 2005 summer school has introductory lectures Oregon Programming Languages Summer School, many lectures and some notes. Summer 2013 lectures including Robert Harper's talks on YouTube Summer 2015 Types, Logic, Semantics, and Verification Andrej Bauer's blog
Wikipedia/Theory_of_types
Software design is the process of conceptualizing how a software system will work before it is implemented or modified. Software design also refers to the direct result of the design process – the concepts of how the software will work which consists of both design documentation and undocumented concepts. Software design usually is directed by goals for the resulting system and involves problem-solving and planning – including both high-level software architecture and low-level component and algorithm design. In terms of the waterfall development process, software design is the activity of following requirements specification and before coding. == General process == The design process enables a designer to model various aspects of a software system before it exists. Creativity, past experience, a sense of what makes "good" software, and a commitment to quality are success factors for a competent design. However, the design process is not always a straightforward procedure. The software design model can be compared to an architected plan for a house. High-level plans represent the totality of the house (e.g., a three-dimensional rendering of the house). Lower-level plans provide guidance for constructing each detail (e.g., the plumbing lay). Similarly, the software design model provides a variety of views of the proposed software solution. == Iterative Design for Software Components == Software systems inherently deal with uncertainties, and the size of software components can significantly influence a system's outcomes, both positively and negatively. Neal Ford and Mark Richards propose an iterative approach to address the challenge of identifying and right-sizing components. This method emphasizes continuous refinement as teams develop a more nuanced understanding of system behavior and requirements. The approach typically involves a cycle with several stages: A high-level partitioning strategy is established, often categorized as technical or domain-based. Guidelines for the smallest meaningful deployable unit, referred to as "quanta," are defined. While these foundational decisions are made early, they may be revisited later in the cycle if necessary. Initial components are identified based on the established strategy. Requirements are assigned to the identified components. The roles and responsibilities of each component are analyzed to ensure clarity and minimize overlap. Architectural characteristics, such as scalability, fault tolerance, and maintainability, are evaluated. Components may be restructured based on feedback from development teams. This cycle serves as a general framework and can be adapted to different domains. == Value == Software design documentation may be reviewed or presented to allow constraints, specifications and even requirements to be adjusted prior to coding. Redesign may occur after a review of a programmed simulation or prototype. It is possible to design software in the process of coding, without a plan or requirement analysis, but for more complex projects this is less feasible. A separate design prior to coding allows for multidisciplinary designers and subject-matter experts (SMEs) to collaborate with programmers in order to produce software that is useful and technically sound. == Requirements analysis == One component of software design is software requirements analysis (SRA). SRA is a part of the software development process that lists specifications used in software engineering. The output of the analysis is smaller problems to solve. In contrast, the design focuses on capabilities, and thus multiple designs for the same problem can exist. Depending on the environment, the design often varies, whether it is created from reliable frameworks or implemented with suitable design patterns. == Artifacts == A design process may include the production of artifacts such as flow chart, use case, Pseudocode, Unified Modeling Language model and other Fundamental modeling concepts. For user centered software, design may involve user experience design yielding a storyboard to help determine those specifications. Sometimes the output of a design process is design documentation. == Design principles == Basic design principles enable a software engineer to navigate the design process. Davis suggests a set of principles for software design, which have been adapted and extended in the following list: The design process should not suffer from "tunnel vision". A good designer should consider alternative approaches, judging each based on the requirements of the problem, the resources available to do the job. The design should be traceable to the analysis model. Because a single element of the design model can often be traced back to multiple requirements, it is necessary to have a means for tracking how requirements have been satisfied by the design model. The design should not reinvent the wheel. Systems are constructed using a set of design patterns, many of which have likely been encountered before. These patterns should always be chosen as an alternative to reinvention. Time is short and resources are limited; design time should be invested in representing (truly new) ideas by integrating patterns that already exist (when applicable). The design should "minimize the intellectual distance" between the software and the problem as it exists in the real world. That is, the structure of the software design should, whenever possible, mimic the structure of the problem domain. The design should exhibit uniformity and integration. A design is uniform if it appears fully coherent. In order to achieve this outcome, rules of style and format should be defined for a design team before design work begins. A design is integrated if care is taken in defining interfaces between design components. The design should be structured to accommodate change. The design concepts discussed in the next section enable a design to achieve this principle. The design should be structured to degrade gently, even when aberrant data, events, or operating conditions are encountered. Well-designed software should never "bomb"; it should be designed to accommodate unusual circumstances, and if it must terminate processing, it should do so in a graceful manner. Design is not coding, coding is not design. Even when detailed procedural designs are created for program components, the level of abstraction of the design model is higher than the source code. The only design decisions made at the coding level should address the small implementation details that enable the procedural design to be coded. The design should be assessed for quality as it is being created, not after the fact. A variety of design concepts and design measures are available to assist the designer in assessing quality throughout the development process. The design should be reviewed to minimize conceptual (semantic) errors. There is sometimes a tendency to focus on minutiae when the design is reviewed, missing the forest for the trees. A design team should ensure that major conceptual elements of the design (omissions, ambiguity, inconsistency) have been addressed before worrying about the syntax of the design model. == Design concepts == Design concepts provide a designer with a foundation from which more sophisticated methods can be applied. A set of design concepts has evolved including: Abstraction - Abstraction is the process or result of generalization by reducing the information content of a concept or an observable phenomenon, typically to retain only information that is relevant for a particular purpose. It is an act of Representing essential features without including the background details or explanations. Refinement - It is the process of elaboration. A hierarchy is developed by decomposing a macroscopic statement of function in a step-wise fashion until programming language statements are reached. In each step, one or several instructions of a given program are decomposed into more detailed instructions. Abstraction and Refinement are complementary concepts. Modularity - Software architecture is divided into components called modules. Software Architecture - It refers to the overall structure of the software and the ways in which that structure provides conceptual integrity for a system. Good software architecture will yield a good return on investment with respect to the desired outcome of the project, e.g. in terms of performance, quality, schedule and cost. Control Hierarchy - A program structure that represents the organization of a program component and implies a hierarchy of control. Structural Partitioning - The program structure can be divided horizontally and vertically. Horizontal partitions define separate branches of modular hierarchy for each major program function. Vertical partitioning suggests that control and work should be distributed top-down in the program structure. Data Structure - It is a representation of the logical relationship among individual elements of data. Software Procedure - It focuses on the processing of each module individually. Information Hiding - Modules should be specified and designed so that information contained within a module is inaccessible to other modules that have no need for such information. In his object model, Grady Booch mentions Abstraction, Encapsulation, Modularisation, and Hierarchy as fundamental software design principles. The acronym PHAME (Principles of Hierarchy, Abstraction, Modularisation, and Encapsulation) is sometimes used to refer to these four fundamental principles. == Design considerations == There are many aspects to consider in the design of a piece of software. The importance of each consideration should reflect the goals and expectations that the software is being created to meet. Some of these aspects are: Compatibility - The software is able to operate with other products that are designed for interoperability with another product. For example, a piece of software may be backward-compatible with an older version of itself. Extensibility - New capabilities can be added to the software without major changes to the underlying architecture. Modularity - the resulting software comprises well defined, independent components which leads to better maintainability. The components could be then implemented and tested in isolation before being integrated to form a desired software system. This allows division of work in a software development project. Fault-tolerance - The software is resistant to and able to recover from component failure. Maintainability - A measure of how easily bug fixes or functional modifications can be accomplished. High maintainability can be the product of modularity and extensibility. Reliability (Software durability) - The software is able to perform a required function under stated conditions for a specified period of time. Reusability - The ability to use some or all of the aspects of the preexisting software in other projects with little to no modification. Robustness - The software is able to operate under stress or tolerate unpredictable or invalid input. For example, it can be designed with resilience to low memory conditions. Security - The software is able to withstand and resist hostile acts and influences. Usability - The software user interface must be usable for its target user/audience. Default values for the parameters must be chosen so that they are a good choice for the majority of the users. Performance - The software performs its tasks within a time-frame that is acceptable for the user, and does not require too much memory. Portability - The software should be usable across a number of different conditions and environments. Scalability - The software adapts well to increasing data or added features or number of users. According to Marc Brooker: "a system is scalable in the range where marginal cost of additional workload is nearly constant." Serverless technologies fit this definition but you need to consider total cost of ownership not just the infra cost. == Modeling language == A modeling language can be used to express information, knowledge or systems in a structure that is defined by a consistent set of rules. These rules are used for interpretation of the components within the structure. A modeling language can be graphical or textual. Examples of graphical modeling languages for software design include: Architecture description language (ADL) is a language used to describe and represent the software architecture of a software system. Business Process Modeling Notation (BPMN) is an example of a Process Modeling language. EXPRESS and EXPRESS-G (ISO 10303-11) is an international standard general-purpose data modeling language. Extended Enterprise Modeling Language (EEML) is commonly used for business process modeling across a number of layers. Flowcharts are schematic representations of algorithms or other step-wise processes. Fundamental Modeling Concepts (FMC) is modeling language for software-intensive systems. IDEF is a family of modeling languages, the most notable of which include IDEF0 for functional modeling, IDEF1X for information modeling, and IDEF5 for modeling ontologies. Jackson Structured Programming (JSP) is a method for structured programming based on correspondences between data stream structure and program structure. LePUS3 is an object-oriented visual Design Description Language and a formal specification language that is suitable primarily for modeling large object-oriented (Java, C++, C#) programs and design patterns. Unified Modeling Language (UML) is a general modeling language to describe software both structurally and behaviorally. It has a graphical notation and allows for extension with a Profile (UML). Alloy (specification language) is a general purpose specification language for expressing complex structural constraints and behavior in a software system. It provides a concise language base on first-order relational logic. Systems Modeling Language (SysML) is a new general-purpose modeling language for systems engineering. Service-oriented modeling framework (SOMF) == Design patterns == A software designer may identify a design aspect which has been visited and perhaps even solved by others in the past. A template or pattern describing a solution to a common problem is known as a design pattern. The reuse of such patterns can increase software development velocity. == Code as design == The difficulty of using the term "design" in relation to software is that in some senses, the source code of a program is the design for the program that it produces. To the extent that this is true, "software design" refers to the design of the design. Edsger W. Dijkstra referred to this layering of semantic levels as the "radical novelty" of computer programming, and Donald Knuth used his experience writing TeX to describe the futility of attempting to design a program prior to implementing it: TEX would have been a complete failure if I had merely specified it and not participated fully in its initial implementation. The process of implementation constantly led me to unanticipated questions and to new insights about how the original specifications could be improved. == See also == Aspect-oriented software development Design Design rationale Graphic design Interaction design Icon design Outline of software Outline of software development Outline of software engineering Search-based software engineering Software Design Description (IEEE 1016) Software development User experience User interface design Web design Zero One Infinity == References == ^Roger S. Pressman (2001). Software engineering: a practitioner's approach. McGraw-Hill. ISBN 0-07-365578-3.
Wikipedia/Software_design
Type inference, sometimes called type reconstruction,: 320  refers to the automatic detection of the type of an expression in a formal language. These include programming languages and mathematical type systems, but also natural languages in some branches of computer science and linguistics. == Nontechnical explanation == In a typed language, a term's type determines the ways it can and cannot be used in that language. For example, consider the English language and terms that could fill in the blank in the phrase "sing _." The term "a song" is of singable type, so it could be placed in the blank to form a meaningful phrase: "sing a song." On the other hand, the term "a friend" does not have the singable type, so "sing a friend" is nonsense. At best it might be metaphor; bending type rules is a feature of poetic language. A term's type can also affect the interpretation of operations involving that term. For instance, "a song" is of composable type, so we interpret it as the thing created in the phrase "write a song". On the other hand, "a friend" is of recipient type, so we interpret it as the addressee in the phrase "write a friend". In normal language, we would be surprised if "write a song" meant addressing a letter to a song or "write a friend" meant drafting a friend on paper. Terms with different types can even refer to materially the same thing. For example, we would interpret "to hang up the clothes line" as putting it into use, but "to hang up the leash" as putting it away, even though, in context, both "clothes line" and "leash" might refer the same rope, just at different times. Typings are often used to prevent an object from being considered too generally. For instance, if the type system treats all numbers as the same, then a programmer who accidentally writes code where 4 is supposed to mean "4 seconds" but is interpreted as "4 meters" would have no warning of their mistake until it caused problems at runtime. By incorporating units into the type system, these mistakes can be detected much earlier. As another example, Russell's paradox arises when anything can be a set element and any predicate can define a set, but more careful typing gives several ways to resolve the paradox. In fact, Russell's paradox sparked early versions of type theory. There are several ways that a term can get its type: The type might be provided from somewhere outside the passage. For instance, if a speaker refers to "a song" in English, they generally do not have to tell the listener that "a song" is singable and composable; that information is part of their shared background knowledge. The type can be declared explicitly. For example, a programmer might write a statement like delay: seconds := 4 in their code, where the colon is the conventional mathematical symbol to mark a term with its type. That is, this statement is not only setting delay to the value 4, but the delay: seconds part also indicates that delay's type is an amount of time in seconds. The type can be inferred from context. For example, in the phrase "I bought it for a song", we can observe that trying to give the term "a song" types like "singable" and "composable" would lead to nonsense, whereas the type "amount of currency" works out. Therefore, without having to be told, we conclude that "song" here must mean "little to nothing", as in the English idiom "for a song", not "a piece of music, usually with lyrics". Especially in programming languages, there may not be much shared background knowledge available to the computer. In manifestly typed languages, this means that most types have to be declared explicitly. Type inference aims to alleviate this burden, freeing the author from declaring types that the computer should be able to deduce from context. == Type-checking vs. type-inference == In a typing, an expression E is opposed to a type T, formally written as E : T. Usually a typing only makes sense within some context, which is omitted here. In this setting, the following questions are of particular interest: E : T? In this case, both an expression E and a type T are given. Now, is E really a T? This scenario is known as type-checking. E : _? Here, only the expression is known. If there is a way to derive a type for E, then we have accomplished type inference. _ : T? The other way round. Given only a type, is there any expression for it or does the type have no values? Is there any example of a T? This is known as type inhabitation. For the simply typed lambda calculus, all three questions are decidable. The situation is not as comfortable when more expressive types are allowed. == Types in programming languages == Types are a feature present in some strongly statically typed languages. It is often characteristic of functional programming languages in general. Some languages that include type inference include C23, C++11, C# (starting with version 3.0), Chapel, Clean, Crystal, D, Dart, F#, FreeBASIC, Go, Haskell, Java (starting with version 10), Julia, Kotlin, ML, Nim, OCaml, Opa, Q#, RPython, Rust, Scala, Swift, TypeScript, Vala, and Visual Basic (starting with version 9.0). The majority of them use a simple form of type inference; the Hindley–Milner type system can provide more complete type inference. The ability to infer types automatically makes many programming tasks easier, leaving the programmer free to omit type annotations while still permitting type checking. In some programming languages, all values have a data type explicitly declared at compile time, limiting the values a particular expression can take on at run-time. Increasingly, just-in-time compilation blurs the distinction between run time and compile time. However, historically, if the type of a value is known only at run-time, these languages are dynamically typed. In other languages, the type of an expression is known only at compile time; these languages are statically typed. In most statically typed languages, the input and output types of functions and local variables ordinarily must be explicitly provided by type annotations. For example, in ANSI C: The signature of this function definition, int add_one(int x), declares that add_one is a function that takes one argument, an integer, and returns an integer. int result; declares that the local variable result is an integer. In a hypothetical language supporting type inference, the code might be written like this instead: This is identical to how code is written in the language Dart, except that it is subject to some added constraints as described below. It would be possible to infer the types of all the variables at compile time. In the example above, the compiler would infer that result and x have type integer since the constant 1 is type integer, and hence that add_one is a function int -> int. The variable result2 isn't used in a legal manner, so it wouldn't have a type. In the imaginary language in which the last example is written, the compiler would assume that, in the absence of information to the contrary, + takes two integers and returns one integer. (This is how it works in, for example, OCaml.) From this, the type inferencer can infer that the type of x + 1 is an integer, which means result is an integer and thus the return value of add_one is an integer. Similarly, since + requires both of its arguments be of the same type, x must be an integer, and thus, add_one accepts one integer as an argument. However, in the subsequent line, result2 is calculated by adding a decimal 1.0 with floating-point arithmetic, causing a conflict in the use of x for both integer and floating-point expressions. The correct type-inference algorithm for such a situation has been known since 1958 and has been known to be correct since 1982. It revisits the prior inferences and uses the most general type from the outset: in this case floating-point. This can however have detrimental implications, for instance using a floating-point from the outset can introduce precision issues that would have not been there with an integer type. Frequently, however, degenerate type-inference algorithms are used that cannot backtrack and instead generate an error message in such a situation. This behavior may be preferable as type inference may not always be neutral algorithmically, as illustrated by the prior floating-point precision issue. An algorithm of intermediate generality implicitly declares result2 as a floating-point variable, and the addition implicitly converts x to a floating point. This can be correct if the calling contexts never supply a floating point argument. Such a situation shows the difference between type inference, which does not involve type conversion, and implicit type conversion, which forces data to a different data type, often without restrictions. Finally, a significant downside of complex type-inference algorithm is that the resulting type inference resolution is not going to be obvious to humans (notably because of the backtracking), which can be detrimental as code is primarily intended to be comprehensible to humans. The recent emergence of just-in-time compilation allows for hybrid approaches where the type of arguments supplied by the various calling context is known at compile time, and can generate a large number of compiled versions of the same function. Each compiled version can then be optimized for a different set of types. For instance, JIT compilation allows there to be at least two compiled versions of add_one: A version that accepts an integer input and uses implicit type conversion. A version that accepts a floating-point number as input and uses floating point instructions throughout. == Technical description == Type inference is the ability to automatically deduce, either partially or fully, the type of an expression at compile time. The compiler is often able to infer the type of a variable or the type signature of a function, without explicit type annotations having been given. In many cases, it is possible to omit type annotations from a program completely if the type inference system is robust enough, or the program or language is simple enough. To obtain the information required to infer the type of an expression, the compiler either gathers this information as an aggregate and subsequent reduction of the type annotations given for its subexpressions, or through an implicit understanding of the type of various atomic values (e.g. true : Bool; 42 : Integer; 3.14159 : Real; etc.). It is through recognition of the eventual reduction of expressions to implicitly typed atomic values that the compiler for a type inferring language is able to compile a program completely without type annotations. In complex forms of higher-order programming and polymorphism, it is not always possible for the compiler to infer as much, and type annotations are occasionally necessary for disambiguation. For instance, type inference with polymorphic recursion is known to be undecidable. Furthermore, explicit type annotations can be used to optimize code by forcing the compiler to use a more specific (faster/smaller) type than it had inferred. Some methods for type inference are based on constraint satisfaction or satisfiability modulo theories. == High-Level Example == As an example, the Haskell function map applies a function to each element of a list, and may be defined as: (Recall that : in Haskell denotes cons, structuring a head element and a list tail into a bigger list or destructuring a nonempty list into its head element and its tail. It does not denote "of type" as in mathematics and elsewhere in this article; in Haskell that "of type" operator is written :: instead.) Type inference on the map function proceeds as follows. map is a function of two arguments, so its type is constrained to be of the form a -> b -> c. In Haskell, the patterns [] and (first:rest) always match lists, so the second argument must be a list type: b = [d] for some type d. Its first argument f is applied to the argument first, which must have type d, corresponding with the type in the list argument, so f :: d -> e (:: means "is of type") for some type e. The return value of map f, finally, is a list of whatever f produces, so [e]. Putting the parts together leads to map :: (d -> e) -> [d] -> [e]. Nothing is special about the type variables, so it can be relabeled as It turns out that this is also the most general type, since no further constraints apply. As the inferred type of map is parametrically polymorphic, the type of the arguments and results of f are not inferred, but left as type variables, and so map can be applied to functions and lists of various types, as long as the actual types match in each invocation. == Detailed Example == The algorithms used by programs like compilers are equivalent to the informally structured reasoning above, but a bit more verbose and methodical. The exact details depend on the inference algorithm chosen (see the following section for the best-known algorithm), but the example below gives the general idea. We again begin with the definition of map: (Again, remember that the : here is the Haskell list constructor, not the "of type" operator, which Haskell instead spells ::.) First, we make fresh type variables for each individual term: α shall denote the type of map that we want to infer. β shall denote the type of f in the first equation. [γ] shall denote the type of [] on the left side of the first equation. [δ] shall denote the type of [] on the right side of the first equation. ε shall denote the type of f in the second equation. ζ -> [ζ] -> [ζ] shall denote the type of : on the left side of the first equation. (This pattern is known from its definition.) η shall denote the type of first. θ shall denote the type of rest. ι -> [ι] -> [ι] shall denote the type of : on the right side of the first equation. Then we make fresh type variables for subexpressions built from these terms, constraining the type of the function being invoked accordingly: κ shall denote the type of map f []. We conclude that α ~ β -> [γ] -> κ where the "similar" symbol ~ means "unifies with"; we are saying that α, the type of map, must be compatible with the type of a function taking a β and a list of γs and returning a κ. λ shall denote the type of (first:rest). We conclude that ζ -> [ζ] -> [ζ] ~ η -> θ -> λ. μ shall denote the type of map f (first:rest). We conclude that α ~ ε -> λ -> μ. ν shall denote the type of f first. We conclude that ε ~ η -> ν. ξ shall denote the type of map f rest. We conclude that α ~ ε -> θ -> ξ. ο shall denote the type of f first : map f rest. We conclude that ι -> [ι] -> [ι] ~ ν -> ξ -> ο. We also constrain the left and right sides of each equation to unify with each other: κ ~ [δ] and μ ~ ο. Altogether the system of unifications to solve is: α ~ β -> [γ] -> κ ζ -> [ζ] -> [ζ] ~ η -> θ -> λ α ~ ε -> λ -> μ ε ~ η -> ν α ~ ε -> θ -> ξ ι -> [ι] -> [ι] ~ ν -> ξ -> ο κ ~ [δ] μ ~ ο Then we substitute until no further variables can be eliminated. The exact order is immaterial; if the code type-checks, any order will lead to the same final form. Let us begin by substituting ο for μ and [δ] for κ: α ~ β -> [γ] -> [δ] ζ -> [ζ] -> [ζ] ~ η -> θ -> λ α ~ ε -> λ -> ο ε ~ η -> ν α ~ ε -> θ -> ξ ι -> [ι] -> [ι] ~ ν -> ξ -> ο Substituting ζ for η, [ζ] for θ and λ, ι for ν, and [ι] for ξ and ο, all possible because a type constructor like · -> · is invertible in its arguments: α ~ β -> [γ] -> [δ] α ~ ε -> [ζ] -> [ι] ε ~ ζ -> ι Substituting ζ -> ι for ε and β -> [γ] -> [δ] for α, keeping the second constraint around so that we can recover α at the end: α ~ (ζ -> ι) -> [ζ] -> [ι] β -> [γ] -> [δ] ~ (ζ -> ι) -> [ζ] -> [ι] And, finally, substituting (ζ -> ι) for β as well as ζ for γ and ι for δ because a type constructor like [·] is invertible eliminates all the variables specific to the second constraint: α ~ (ζ -> ι) -> [ζ] -> [ι] No more substitutions are possible, and relabeling gives us map :: (a -> b) -> [a] -> [b], the same as we found without going into these details. == Hindley–Milner type inference algorithm == The algorithm first used to perform type inference is now informally termed the Hindley–Milner algorithm, although the algorithm should properly be attributed to Damas and Milner. It is also traditionally called type reconstruction.: 320  If a term is well-typed in accordance with Hindley–Milner typing rules, then the rules generate a principal typing for the term. The process of discovering this principal typing is the process of "reconstruction". The origin of this algorithm is the type inference algorithm for the simply typed lambda calculus that was devised by Haskell Curry and Robert Feys in 1958. In 1969 J. Roger Hindley extended this work and proved that their algorithm always inferred the most general type. In 1978 Robin Milner, independently of Hindley's work, provided an equivalent algorithm, Algorithm W. In 1982 Luis Damas finally proved that Milner's algorithm is complete and extended it to support systems with polymorphic references. == Side-effects of using the most general type == By design, type inference will infer the most general type appropriate. However, many languages, especially older programming languages, have slightly unsound type systems, where using a more general types may not always be algorithmically neutral. Typical cases include: Floating-point types being considered as generalizations of integer types. Actually, floating-point arithmetic has different precision and wrapping issues than integers do. Variant/dynamic types being considered as generalizations of other types in cases where this affects the selection of operator overloads. For example, the + operator may add integers but may concatenate variants as strings, even if those variants hold integers. == Type inference for natural languages == Type inference algorithms have been used to analyze natural languages as well as programming languages. Type inference algorithms are also used in some grammar induction and constraint-based grammar systems for natural languages. == References == == External links == Archived e-mail message by Roger Hindley, explains history of type inference Polymorphic Type Inference by Michael Schwartzbach, gives an overview of Polymorphic type inference. Basic Typechecking paper by Luca Cardelli, describes algorithm, includes implementation in Modula-2 Implementation of Hindley–Milner type inference in Scala, by Andrew Forrest (retrieved July 30, 2009) Implementation of Hindley-Milner in Perl 5, by Nikita Borisov at the Wayback Machine (archived February 18, 2007) What is Hindley-Milner? (and why is it cool?) Explains Hindley–Milner, examples in Scala
Wikipedia/Type_inference
In computer networking, a network service is an application running at the network layer and above, that provides data storage, manipulation, presentation, communication or other capability which is often implemented using a client–server or peer-to-peer architecture based on application layer network protocols. Each service is usually provided by a server component running on one or more computers (often a dedicated server computer offering multiple services) and accessed via a network by client components running on other devices. However, the client and server components can both be run on the same machine. Clients and servers will often have a user interface, and sometimes other hardware associated with it. == Examples == Examples are the Domain Name System (DNS) which translates domain names to Internet Protocol (IP) addresses and the Dynamic Host Configuration Protocol (DHCP) to assign networking configuration information to network hosts. Authentication servers identify and authenticate users, provide user account profiles, and may log usage statistics. Email, printing and distributed (network) file system services are common services on local area networks. They require users to have permissions to access the shared resources. Other network services include: Directory services Email File sharing Instant messaging Online game Printing File server Voice over IP Video on demand Videotelephony World Wide Web Simple Network Management Protocol Time service Wireless sensor network == Application layer == In computer network programming, the application layer is an abstraction layer reserved for communications protocols and methods designed for process-to-process communications across an IP network. Application layer protocols use the underlying transport layer protocols to establish host-to-host connections for network services. === TCP-IP network services === ==== Port numbers ==== Many IP-based services are associated with a particular well-known port number which is standardized by the Internet technical governance. For example, World-Wide-Web servers operate on port 80, and email relay servers usually listen on port 25. === TCP versus UDP === Different services use different packet transmission techniques. In general, packets that must get through in the correct order, without loss, use TCP, whereas real time services where later packets are more important than older packets use UDP. For example, file transfer requires complete accuracy and so is normally done using TCP, and audio conferencing is frequently done via UDP, where momentary glitches may not be noticed. UDP lacks built-in network congestion avoidance and the protocols that use it must be extremely carefully designed to prevent network collapse. == See also == Internet hosting service Web hosting service DNS hosting service E-mail hosting service Category:Network service == References ==
Wikipedia/Network_service
In formal linguistics, discourse representation theory (DRT) is a framework for exploring meaning under a formal semantics approach. One of the main differences between DRT-style approaches and traditional Montagovian approaches is that DRT includes a level of abstract mental representations (discourse representation structures, DRS) within its formalism, which gives it an intrinsic ability to handle meaning across sentence boundaries. DRT was created by Hans Kamp in 1981. A very similar theory was developed independently by Irene Heim in 1982, under the name of File Change Semantics (FCS). Discourse representation theories have been used to implement semantic parsers and natural language understanding systems. == Discourse representation structures == DRT uses discourse representation structures (DRS) to represent a hearer's mental representation of a discourse as it unfolds over time. There are two critical components to a DRS: A set of discourse referents representing entities that are under discussion. A set of DRS conditions representing information that has been given about discourse referents. Consider Sentence (1) below: (1) A farmer owns a donkey. The DRS of (1) can be notated as (2) below: (2) [x,y: farmer(x), donkey(y), owns(x,y)] What (2) says is that there are two discourse referents, x and y, and three discourse conditions farmer, donkey, and owns, such that the condition farmer holds of x, donkey holds of y, and owns holds of the pair x and y. Informally, the DRS in (2) is true in a given model of evaluation if and only if there are entities in that model that satisfy the conditions. So, if a model contains two individuals, and one is a farmer, the other is a donkey, and the first owns the second, the DRS in (2) is true in that model. Uttering subsequent sentences results in the existing DRS being updated. (3) He beats it. Uttering (3) after (1) results in the DRS in (2) being updated as follows, in (4) (assuming a way to disambiguate which pronoun refers to which individual). (4) [x,y: farmer(x), donkey(y), own(x,y), beat(x,y)] Successive utterances of sentences work in a similar way, although the process is somewhat more complicated for more complex sentences such as sentences containing negation, and conditionals. == Donkey anaphora == In one sense, DRT offers a variation of first-order predicate calculus—its forms are pairs of first-order formulae and the free variables that occur in them. In traditional natural language semantics, only individual sentences are examined, but the context of a dialogue plays a role in meaning as well. For example, anaphoric pronouns such as he and she rely upon previously introduced individual constants in order to have meaning. DRT uses variables for every individual constant in order to account for this problem. A discourse is represented in a discourse representation structure (DRS), a box with variables at the top and the sentences in the formal language below in the order of the original discourse. Sub-DRS can be used for different types of sentences. One of the major advantages of DRT is its ability to account for donkey sentences (Geach 1962) in a principled fashion: (5) Every farmer who owns a donkey beats it. Sentence (5) can be paraphrased as follows: Every farmer who owns a donkey beats the donkey that he/she owns. Under a Montagovian approach, the indefinite a donkey, which is assumed to be inherently an existential quantifier, ends up becoming a universal quantifier, an unwelcome result because the change in quantificational force cannot be accounted for in any principled way. DRT avoids this problem by assuming that indefinites introduce discourse referents (DRs), which are stored in the mental representation and are accessible (or not, depending on the conditions) to expressions like pronouns and other anaphoric elements. Furthermore, they are inherently non-quantificational, and pick up quantificational force depending upon the context. On the other hand, genuine quantifiers (e.g., 'every professor') bear scope. An 'every-NP' triggers the introduction of a complex condition of the form K1 → K2, where K1 and K2 are sub-DRSs representing the restriction and the scope of the quantification respectively. Unlike true quantifiers, indefinite noun phrases just contribute a new DR (together with some descriptive material in terms of conditions on the DR), which is placed in a larger structure. This larger structure can be the top-level DRS or some sub-DRS according to the sentence-internal environment of the analyzed noun phrase—in other words, a level that is accessible to an anaphor that comes later. == See also == Combinatory categorial grammar Donkey pronoun Montague grammar Minimal recursion semantics Segmented discourse representation theory == References == Kadmon, N. 2001. Formal Pragmatics: Semantics, Pragmatics, Presupposition, and Focus. Oxford: Blackwell Publishers. Lewis, David. 'Adverbs of Quantification'. In Formal Semantics of Natural Language. Edited by Edward L Keenan. Cambridge: Cambridge University Press, 1975. Pages 3–15. Moltmann, Friederike. 1997. Unbound Anaphoric Pronouns: E-Type, Dynamic and Structured Propositions Approaches'. Synthese 153, 2006. Pages 199-260. https://doi.org/10.1007/s11229-005-5469-x == External links == Boxer, a broad-coverage implementation of DRT The Handbook of Philosophical Logic Discourse Representation Theory Archived 2009-09-18 at the Wayback Machine Introduction to Discourse Representation Theory SEP Entry
Wikipedia/Discourse_representation_theory
In set theory, Zermelo–Fraenkel set theory, named after mathematicians Ernst Zermelo and Abraham Fraenkel, is an axiomatic system that was proposed in the early twentieth century in order to formulate a theory of sets free of paradoxes such as Russell's paradox. Today, Zermelo–Fraenkel set theory, with the historically controversial axiom of choice (AC) included, is the standard form of axiomatic set theory and as such is the most common foundation of mathematics. Zermelo–Fraenkel set theory with the axiom of choice included is abbreviated ZFC, where C stands for "choice", and ZF refers to the axioms of Zermelo–Fraenkel set theory with the axiom of choice excluded. Informally, Zermelo–Fraenkel set theory is intended to formalize a single primitive notion, that of a hereditary well-founded set, so that all entities in the universe of discourse are such sets. Thus the axioms of Zermelo–Fraenkel set theory refer only to pure sets and prevent its models from containing urelements (elements that are not themselves sets). Furthermore, proper classes (collections of mathematical objects defined by a property shared by their members where the collections are too big to be sets) can only be treated indirectly. Specifically, Zermelo–Fraenkel set theory does not allow for the existence of a universal set (a set containing all sets) nor for unrestricted comprehension, thereby avoiding Russell's paradox. Von Neumann–Bernays–Gödel set theory (NBG) is a commonly used conservative extension of Zermelo–Fraenkel set theory that does allow explicit treatment of proper classes. There are many equivalent formulations of the axioms of Zermelo–Fraenkel set theory. Most of the axioms state the existence of particular sets defined from other sets. For example, the axiom of pairing says that given any two sets a {\displaystyle a} and b {\displaystyle b} there is a new set { a , b } {\displaystyle \{a,b\}} containing exactly a {\displaystyle a} and b {\displaystyle b} . Other axioms describe properties of set membership. A goal of the axioms is that each axiom should be true if interpreted as a statement about the collection of all sets in the von Neumann universe (also known as the cumulative hierarchy). The metamathematics of Zermelo–Fraenkel set theory has been extensively studied. Landmark results in this area established the logical independence of the axiom of choice from the remaining Zermelo-Fraenkel axioms and of the continuum hypothesis from ZFC. The consistency of a theory such as ZFC cannot be proved within the theory itself, as shown by Gödel's second incompleteness theorem. == History == The modern study of set theory was initiated by Georg Cantor and Richard Dedekind in the 1870s. However, the discovery of paradoxes in naive set theory, such as Russell's paradox, led to the desire for a more rigorous form of set theory that was free of these paradoxes. In 1908, Ernst Zermelo proposed the first axiomatic set theory, Zermelo set theory. However, as first pointed out by Abraham Fraenkel in a 1921 letter to Zermelo, this theory was incapable of proving the existence of certain sets and cardinal numbers whose existence was taken for granted by most set theorists of the time, notably the cardinal number aleph-omega ( ℵ ω {\displaystyle \aleph _{\omega }} ) and the set { Z 0 , P ( Z 0 ) , P ( P ( Z 0 ) ) , P ( P ( P ( Z 0 ) ) ) , . . . } , {\displaystyle \{Z_{0},{\mathcal {P}}(Z_{0}),{\mathcal {P}}({\mathcal {P}}(Z_{0})),{\mathcal {P}}({\mathcal {P}}({\mathcal {P}}(Z_{0}))),...\},} where Z 0 {\displaystyle Z_{0}} is any infinite set and P {\displaystyle {\mathcal {P}}} is the power set operation. Moreover, one of Zermelo's axioms invoked a concept, that of a "definite" property, whose operational meaning was not clear. In 1922, Fraenkel and Thoralf Skolem independently proposed operationalizing a "definite" property as one that could be formulated as a well-formed formula in a first-order logic whose atomic formulas were limited to set membership and identity. They also independently proposed replacing the axiom schema of specification with the axiom schema of replacement. Appending this schema, as well as the axiom of regularity (first proposed by John von Neumann), to Zermelo set theory yields the theory denoted by ZF. Adding to ZF either the axiom of choice (AC) or a statement that is equivalent to it yields ZFC. == Formal language == Formally, ZFC is a one-sorted theory in first-order logic. The equality symbol can be treated as either a primitive logical symbol or a high-level abbreviation for having exactly the same elements. The former approach is the most common. The signature has a single predicate symbol, usually denoted ∈ {\displaystyle \in } , which is a predicate symbol of arity 2 (a binary relation symbol). This symbol symbolizes a set membership relation. For example, the formula a ∈ b {\displaystyle a\in b} means that a {\displaystyle a} is an element of the set b {\displaystyle b} (also read as a {\displaystyle a} is a member of b {\displaystyle b} ). There are different ways to formulate the formal language. Some authors may choose a different set of connectives or quantifiers. For example, the logical connective NAND alone can encode the other connectives, a property known as functional completeness. This section attempts to strike a balance between simplicity and intuitiveness. The language's alphabet consists of: A countably infinite amount of variables used for representing sets The logical connectives ¬ {\displaystyle \lnot } , ∧ {\displaystyle \land } , ∨ {\displaystyle \lor } The quantifier symbols ∀ {\displaystyle \forall } , ∃ {\displaystyle \exists } The equality symbol = {\displaystyle =} The set membership symbol ∈ {\displaystyle \in } Brackets ( ) With this alphabet, the recursive rules for forming well-formed formulae (wff) are as follows: Let x {\displaystyle x} and y {\displaystyle y} be metavariables for any variables. These are the two ways to build atomic formulae (the simplest wffs): x = y {\displaystyle x=y} x ∈ y {\displaystyle x\in y} Let ϕ {\displaystyle \phi } and ψ {\displaystyle \psi } be metavariables for any wff, and x {\displaystyle x} be a metavariable for any variable. These are valid wff constructions: ¬ ϕ {\displaystyle \lnot \phi } ( ϕ ∧ ψ ) {\displaystyle (\phi \land \psi )} ( ϕ ∨ ψ ) {\displaystyle (\phi \lor \psi )} ∀ x ϕ {\displaystyle \forall x\phi } ∃ x ϕ {\displaystyle \exists x\phi } A well-formed formula can be thought as a syntax tree. The leaf nodes are always atomic formulae. Nodes ∧ {\displaystyle \land } and ∨ {\displaystyle \lor } have exactly two child nodes, while nodes ¬ {\displaystyle \lnot } , ∀ x {\displaystyle \forall x} and ∃ x {\displaystyle \exists x} have exactly one. There are countably infinitely many wffs, however, each wff has a finite number of nodes. == Axioms == There are many equivalent formulations of the ZFC axioms. The following particular axiom set is from Kunen (1980). The axioms in order below are expressed in a mixture of first-order logic and high-level abbreviations. Axioms 1–8 form ZF, while the axiom 9 turns ZF into ZFC. Following Kunen (1980), we use the equivalent well-ordering theorem in place of the axiom of choice for axiom 9. All formulations of ZFC imply that at least one set exists. Kunen includes an axiom that directly asserts the existence of a set, although he notes that he does so only "for emphasis". Its omission here can be justified in two ways. First, in the standard semantics of first-order logic in which ZFC is typically formalized, the domain of discourse must be nonempty. Hence, it is a logical theorem of first-order logic that something exists – usually expressed as the assertion that something is identical to itself, ∃ x ( x = x ) {\displaystyle \exists x(x=x)} . Consequently, it is a theorem of every first-order theory that something exists. However, as noted above, because in the intended semantics of ZFC, there are only sets, the interpretation of this logical theorem in the context of ZFC is that some set exists. Hence, there is no need for a separate axiom asserting that a set exists. Second, however, even if ZFC is formulated in so-called free logic, in which it is not provable from logic alone that something exists, the axiom of infinity asserts that an infinite set exists. This implies that a set exists, and so, once again, it is superfluous to include an axiom asserting as much. === Axiom of extensionality === Two sets are equal (are the same set) if they have the same elements. The converse of this axiom follows from the substitution property of equality. ZFC is constructed in first-order logic. Some formulations of first-order logic include identity; others do not. If the variety of first-order logic in which one is constructing set theory does not include equality " = {\displaystyle =} ", x = y {\displaystyle x=y} may be defined as an abbreviation for the following formula: ∀ z [ z ∈ x ⇔ z ∈ y ] ∧ ∀ w [ x ∈ w ⇔ y ∈ w ] . {\displaystyle \forall z[z\in x\Leftrightarrow z\in y]\land \forall w[x\in w\Leftrightarrow y\in w].} In this case, the axiom of extensionality can be reformulated as which says that if x {\displaystyle x} and y {\displaystyle y} have the same elements, then they belong to the same sets. === Axiom of regularity (also called the axiom of foundation) === Every non-empty set x {\displaystyle x} contains a member y {\displaystyle y} such that x {\displaystyle x} and y {\displaystyle y} are disjoint sets. or in modern notation: ∀ x ( x ≠ ∅ ⇒ ∃ y ( y ∈ x ∧ y ∩ x = ∅ ) ) . {\displaystyle \forall x\,(x\neq \varnothing \Rightarrow \exists y(y\in x\land y\cap x=\varnothing )).} This (along with the axioms of pairing and union) implies, for example, that no set is an element of itself and that every set has an ordinal rank. === Axiom schema of specification (or of separation, or of restricted comprehension) === Subsets are commonly constructed using set builder notation. For example, the even integers can be constructed as the subset of the integers Z {\displaystyle \mathbb {Z} } satisfying the congruence modulo predicate x ≡ 0 ( mod 2 ) {\displaystyle x\equiv 0{\pmod {2}}} : In general, the subset of a set z {\displaystyle z} obeying a formula φ ( x ) {\displaystyle \varphi (x)} with one free variable x {\displaystyle x} may be written as: The axiom schema of specification states that this subset always exists (it is an axiom schema because there is one axiom for each φ {\displaystyle \varphi } ). Formally, let φ {\displaystyle \varphi } be any formula in the language of ZFC with all free variables among x , z , w 1 , … , w n {\displaystyle x,z,w_{1},\ldots ,w_{n}} ( y {\displaystyle y} is not free in φ {\displaystyle \varphi } ). Then: Note that the axiom schema of specification can only construct subsets and does not allow the construction of entities of the more general form: This restriction is necessary to avoid Russell's paradox (let y = { x : x ∉ x } {\displaystyle y=\{x:x\notin x\}} then y ∈ y ⇔ y ∉ y {\displaystyle y\in y\Leftrightarrow y\notin y} ) and its variants that accompany naive set theory with unrestricted comprehension (since under this restriction y {\displaystyle y} only refers to sets within z {\displaystyle z} that don't belong to themselves, and y ∈ z {\displaystyle y\in z} has not been established, even though y ⊆ z {\displaystyle y\subseteq z} is the case, so y {\displaystyle y} stands in a separate position from which it can't refer to or comprehend itself; therefore, in a certain sense, this axiom schema is saying that in order to build a y {\displaystyle y} on the basis of a formula φ ( x ) {\displaystyle \varphi (x)} , we need to previously restrict the sets y {\displaystyle y} will regard within a set z {\displaystyle z} that leaves y {\displaystyle y} outside so y {\displaystyle y} can't refer to itself; or, in other words, sets shouldn't refer to themselves). In some other axiomatizations of ZF, this axiom is redundant in that it follows from the axiom schema of replacement and the axiom of the empty set. On the other hand, the axiom schema of specification can be used to prove the existence of the empty set, denoted ∅ {\displaystyle \varnothing } , once at least one set is known to exist. One way to do this is to use a property φ {\displaystyle \varphi } which no set has. For example, if w {\displaystyle w} is any existing set, the empty set can be constructed as Thus, the axiom of the empty set is implied by the nine axioms presented here. The axiom of extensionality implies the empty set is unique (does not depend on w {\displaystyle w} ). It is common to make a definitional extension that adds the symbol " ∅ {\displaystyle \varnothing } " to the language of ZFC. === Axiom of pairing === If x {\displaystyle x} and y {\displaystyle y} are sets, then there exists a set which contains x {\displaystyle x} and y {\displaystyle y} as elements, for example if x = {1,2} and y = {2,3} then z will be {{1,2},{2,3}} The axiom schema of specification must be used to reduce this to a set with exactly these two elements. The axiom of pairing is part of Z, but is redundant in ZF because it follows from the axiom schema of replacement if we are given a set with at least two elements. The existence of a set with at least two elements is assured by either the axiom of infinity, or by the axiom schema of specification and the axiom of the power set applied twice to any set. === Axiom of union === The union over the elements of a set exists. For example, the union over the elements of the set { { 1 , 2 } , { 2 , 3 } } {\displaystyle \{\{1,2\},\{2,3\}\}} is { 1 , 2 , 3 } . {\displaystyle \{1,2,3\}.} The axiom of union states that for any set of sets F {\displaystyle {\mathcal {F}}} , there is a set A {\displaystyle A} containing every element that is a member of some member of F {\displaystyle {\mathcal {F}}} : Although this formula doesn't directly assert the existence of ∪ F {\displaystyle \cup {\mathcal {F}}} , the set ∪ F {\displaystyle \cup {\mathcal {F}}} can be constructed from A {\displaystyle A} in the above using the axiom schema of specification: === Axiom schema of replacement === The axiom schema of replacement asserts that the image of a set under any definable function will also fall inside a set. Formally, let φ {\displaystyle \varphi } be any formula in the language of ZFC whose free variables are among x , y , A , w 1 , … , w n , {\displaystyle x,y,A,w_{1},\dotsc ,w_{n},} so that in particular B {\displaystyle B} is not free in φ {\displaystyle \varphi } . Then: (The unique existential quantifier ∃ ! {\displaystyle \exists !} denotes the existence of exactly one element such that it follows a given statement.) In other words, if the relation φ {\displaystyle \varphi } represents a definable function f {\displaystyle f} , A {\displaystyle A} represents its domain, and f ( x ) {\displaystyle f(x)} is a set for every x ∈ A , {\displaystyle x\in A,} then the range of f {\displaystyle f} is a subset of some set B {\displaystyle B} . The form stated here, in which B {\displaystyle B} may be larger than strictly necessary, is sometimes called the axiom schema of collection. === Axiom of infinity === Let S ( w ) {\displaystyle S(w)} abbreviate w ∪ { w } , {\displaystyle w\cup \{w\},} where w {\displaystyle w} is some set. (We can see that { w } {\displaystyle \{w\}} is a valid set by applying the axiom of pairing with x = y = w {\displaystyle x=y=w} so that the set z is { w } {\displaystyle \{w\}} ). Then there exists a set X such that the empty set ∅ {\displaystyle \varnothing } , defined axiomatically, is a member of X and, whenever a set y is a member of X then S ( y ) {\displaystyle S(y)} is also a member of X. or in modern notation: ∃ X [ ∅ ∈ X ∧ ∀ y ( y ∈ X ⇒ S ( y ) ∈ X ) ] . {\displaystyle \exists X\left[\varnothing \in X\land \forall y(y\in X\Rightarrow S(y)\in X)\right].} More colloquially, there exists a set X having infinitely many members. (It must be established, however, that these members are all different because if two elements are the same, the sequence will loop around in a finite cycle of sets. The axiom of regularity prevents this from happening.) The minimal set X satisfying the axiom of infinity is the von Neumann ordinal ω which can also be thought of as the set of natural numbers N . {\displaystyle \mathbb {N} .} === Axiom of power set === By definition, a set z {\displaystyle z} is a subset of a set x {\displaystyle x} if and only if every element of z {\displaystyle z} is also an element of x {\displaystyle x} : The Axiom of power set states that for any set x {\displaystyle x} , there is a set y {\displaystyle y} that contains every subset of x {\displaystyle x} : The axiom schema of specification is then used to define the power set P ( x ) {\displaystyle {\mathcal {P}}(x)} as the subset of such a y {\displaystyle y} containing the subsets of x {\displaystyle x} exactly: Axioms 1–8 define ZF. Alternative forms of these axioms are often encountered, some of which are listed in Jech (2003). Some ZF axiomatizations include an axiom asserting that the empty set exists. The axioms of pairing, union, replacement, and power set are often stated so that the members of the set x {\displaystyle x} whose existence is being asserted are just those sets which the axiom asserts x {\displaystyle x} must contain. The following axiom is added to turn ZF into ZFC: === Axiom of well-ordering (choice) === The last axiom, commonly known as the axiom of choice, is presented here as a property about well-orders, as in Kunen (1980). For any set X {\displaystyle X} , there exists a binary relation R {\displaystyle R} which well-orders X {\displaystyle X} . This means R {\displaystyle R} is a linear order on X {\displaystyle X} such that every nonempty subset of X {\displaystyle X} has a least element under the order R {\displaystyle R} . Given axioms 1 – 8, many statements are provably equivalent to axiom 9. The most common of these goes as follows. Let X {\displaystyle X} be a set whose members are all nonempty. Then there exists a function f {\displaystyle f} from X {\displaystyle X} to the union of the members of X {\displaystyle X} , called a "choice function", such that for all Y ∈ X {\displaystyle Y\in X} one has f ( Y ) ∈ Y {\displaystyle f(Y)\in Y} . A third version of the axiom, also equivalent, is Zorn's lemma. Since the existence of a choice function when X {\displaystyle X} is a finite set is easily proved from axioms 1–8, AC only matters for certain infinite sets. AC is characterized as nonconstructive because it asserts the existence of a choice function but says nothing about how this choice function is to be "constructed". == Motivation via the cumulative hierarchy == One motivation for the ZFC axioms is the cumulative hierarchy of sets introduced by John von Neumann. In this viewpoint, the universe of set theory is built up in stages, with one stage for each ordinal number. At stage 0, there are no sets yet. At each following stage, a set is added to the universe if all of its elements have been added at previous stages. Thus the empty set is added at stage 1, and the set containing the empty set is added at stage 2. The collection of all sets that are obtained in this way, over all the stages, is known as V. The sets in V can be arranged into a hierarchy by assigning to each set the first stage at which that set was added to V. It is provable that a set is in V if and only if the set is pure and well-founded. And V satisfies all the axioms of ZFC if the class of ordinals has appropriate reflection properties. For example, suppose that a set x is added at stage α, which means that every element of x was added at a stage earlier than α. Then, every subset of x is also added at (or before) stage α, because all elements of any subset of x were also added before stage α. This means that any subset of x which the axiom of separation can construct is added at (or before) stage α, and that the powerset of x will be added at the next stage after α. The picture of the universe of sets stratified into the cumulative hierarchy is characteristic of ZFC and related axiomatic set theories such as Von Neumann–Bernays–Gödel set theory (often called NBG) and Morse–Kelley set theory. The cumulative hierarchy is not compatible with other set theories such as New Foundations. It is possible to change the definition of V so that at each stage, instead of adding all the subsets of the union of the previous stages, subsets are only added if they are definable in a certain sense. This results in a more "narrow" hierarchy, which gives the constructible universe L, which also satisfies all the axioms of ZFC, including the axiom of choice. It is independent from the ZFC axioms whether V = L. Although the structure of L is more regular and well behaved than that of V, few mathematicians argue that V = L should be added to ZFC as an additional "axiom of constructibility". == Metamathematics == === Virtual classes === Proper classes (collections of mathematical objects defined by a property shared by their members which are too big to be sets) can only be treated indirectly in ZF (and thus ZFC). An alternative to proper classes while staying within ZF and ZFC is the virtual class notational construct introduced by Quine (1969), where the entire construct y ∈ { x | Fx } is simply defined as Fy. This provides a simple notation for classes that can contain sets but need not themselves be sets, while not committing to the ontology of classes (because the notation can be syntactically converted to one that only uses sets). Quine's approach built on the earlier approach of Bernays & Fraenkel (1958). Virtual classes are also used in Levy (2002), Takeuti & Zaring (1982), and in the Metamath implementation of ZFC. === Finite axiomatization === The axiom schemata of replacement and separation each contain infinitely many instances. Montague (1961) included a result first proved in his 1957 Ph.D. thesis: if ZFC is consistent, it is impossible to axiomatize ZFC using only finitely many axioms. On the other hand, von Neumann–Bernays–Gödel set theory (NBG) can be finitely axiomatized. The ontology of NBG includes proper classes as well as sets; a set is any class that can be a member of another class. NBG and ZFC are equivalent set theories in the sense that any theorem not mentioning classes and provable in one theory can be proved in the other. === Consistency === Gödel's second incompleteness theorem says that a recursively axiomatizable system that can interpret Robinson arithmetic can prove its own consistency only if it is inconsistent. Moreover, Robinson arithmetic can be interpreted in general set theory, a small fragment of ZFC. Hence the consistency of ZFC cannot be proved within ZFC itself (unless it is actually inconsistent). Thus, to the extent that ZFC is identified with ordinary mathematics, the consistency of ZFC cannot be demonstrated in ordinary mathematics. The consistency of ZFC does follow from the existence of a weakly inaccessible cardinal, which is unprovable in ZFC if ZFC is consistent. Nevertheless, it is deemed unlikely that ZFC harbors an unsuspected contradiction; it is widely believed that if ZFC were inconsistent, that fact would have been uncovered by now. This much is certain – ZFC is immune to the classic paradoxes of naive set theory: Russell's paradox, the Burali-Forti paradox, and Cantor's paradox. Abian & LaMacchia (1978) studied a subtheory of ZFC consisting of the axioms of extensionality, union, powerset, replacement, and choice. Using models, they proved this subtheory consistent, and proved that each of the axioms of extensionality, replacement, and power set is independent of the four remaining axioms of this subtheory. If this subtheory is augmented with the axiom of infinity, each of the axioms of union, choice, and infinity is independent of the five remaining axioms. Because there are non-well-founded models that satisfy each axiom of ZFC except the axiom of regularity, that axiom is independent of the other ZFC axioms. If consistent, ZFC cannot prove the existence of the inaccessible cardinals that category theory requires. Huge sets of this nature are possible if ZF is augmented with Tarski's axiom. Assuming that axiom turns the axioms of infinity, power set, and choice (7 – 9 above) into theorems. === Independence === Many important statements are independent of ZFC. The independence is usually proved by forcing, whereby it is shown that every countable transitive model of ZFC (sometimes augmented with large cardinal axioms) can be expanded to satisfy the statement in question. A different expansion is then shown to satisfy the negation of the statement. An independence proof by forcing automatically proves independence from arithmetical statements, other concrete statements, and large cardinal axioms. Some statements independent of ZFC can be proven to hold in particular inner models, such as in the constructible universe. However, some statements that are true about constructible sets are not consistent with hypothesized large cardinal axioms. Forcing proves that the following statements are independent of ZFC: Axiom of constructibility (V=L) (which is also not a ZFC axiom) Continuum hypothesis Diamond principle Martin's axiom (which is not a ZFC axiom) Suslin hypothesis Remarks: The consistency of V=L is provable by inner models but not forcing: every model of ZF can be trimmed to become a model of ZFC + V=L. The diamond principle implies the continuum hypothesis and the negation of the Suslin hypothesis. Martin's axiom plus the negation of the continuum hypothesis implies the Suslin hypothesis. The constructible universe satisfies the generalized continuum hypothesis, the diamond principle, Martin's axiom and the Kurepa hypothesis. The failure of the Kurepa hypothesis is equiconsistent with the existence of a strongly inaccessible cardinal. A variation on the method of forcing can also be used to demonstrate the consistency and unprovability of the axiom of choice, i.e., that the axiom of choice is independent of ZF. The consistency of choice can be (relatively) easily verified by proving that the inner model L satisfies choice. (Thus every model of ZF contains a submodel of ZFC, so that Con(ZF) implies Con(ZFC).) Since forcing preserves choice, we cannot directly produce a model contradicting choice from a model satisfying choice. However, we can use forcing to create a model which contains a suitable submodel, namely one satisfying ZF but not C. Another method of proving independence results, one owing nothing to forcing, is based on Gödel's second incompleteness theorem. This approach employs the statement whose independence is being examined, to prove the existence of a set model of ZFC, in which case Con(ZFC) is true. Since ZFC satisfies the conditions of Gödel's second theorem, the consistency of ZFC is unprovable in ZFC (provided that ZFC is, in fact, consistent). Hence no statement allowing such a proof can be proved in ZFC. This method can prove that the existence of large cardinals is not provable in ZFC, but cannot prove that assuming such cardinals, given ZFC, is free of contradiction. === Proposed additions === The project to unify set theorists behind additional axioms to resolve the continuum hypothesis or other meta-mathematical ambiguities is sometimes known as "Gödel's program". Mathematicians currently debate which axioms are the most plausible or "self-evident", which axioms are the most useful in various domains, and about to what degree usefulness should be traded off with plausibility; some "multiverse" set theorists argue that usefulness should be the sole ultimate criterion in which axioms to customarily adopt. One school of thought leans on expanding the "iterative" concept of a set to produce a set-theoretic universe with an interesting and complex but reasonably tractable structure by adopting forcing axioms; another school advocates for a tidier, less cluttered universe, perhaps focused on a "core" inner model. == Criticisms == ZFC has been criticized both for being excessively strong and for being excessively weak, as well as for its failure to capture objects such as proper classes and the universal set. Many mathematical theorems can be proven in much weaker systems than ZFC, such as Peano arithmetic and second-order arithmetic (as explored by the program of reverse mathematics). Saunders Mac Lane and Solomon Feferman have both made this point. Some of "mainstream mathematics" (mathematics not directly connected with axiomatic set theory) is beyond Peano arithmetic and second-order arithmetic, but still, all such mathematics can be carried out in ZC (Zermelo set theory with choice), another theory weaker than ZFC. Much of the power of ZFC, including the axiom of regularity and the axiom schema of replacement, is included primarily to facilitate the study of the set theory itself. On the other hand, among axiomatic set theories, ZFC is comparatively weak. Unlike New Foundations, ZFC does not admit the existence of a universal set. Hence the universe of sets under ZFC is not closed under the elementary operations of the algebra of sets. Unlike von Neumann–Bernays–Gödel set theory (NBG) and Morse–Kelley set theory (MK), ZFC does not admit the existence of proper classes. A further comparative weakness of ZFC is that the axiom of choice included in ZFC is weaker than the axiom of global choice included in NBG and MK. There are numerous mathematical statements independent of ZFC. These include the continuum hypothesis, the Whitehead problem, and the normal Moore space conjecture. Some of these conjectures are provable with the addition of axioms such as Martin's axiom or large cardinal axioms to ZFC. Some others are decided in ZF+AD where AD is the axiom of determinacy, a strong supposition incompatible with choice. One attraction of large cardinal axioms is that they enable many results from ZF+AD to be established in ZFC adjoined by some large cardinal axiom. The Mizar system and metamath have adopted Tarski–Grothendieck set theory, an extension of ZFC, so that proofs involving Grothendieck universes (encountered in category theory and algebraic geometry) can be formalized. == See also == Foundations of mathematics Inner model Large cardinal axiom Related axiomatic set theories: Morse–Kelley set theory Von Neumann–Bernays–Gödel set theory Tarski–Grothendieck set theory Constructive set theory Internal set theory == Notes == == Bibliography == == External links == Axioms of set Theory - Lec 02 - Frederic Schuller on YouTube "ZFC", Encyclopedia of Mathematics, EMS Press, 2001 [1994] Stanford Encyclopedia of Philosophy articles by Joan Bagaria: Bagaria, Joan (31 January 2023). "Set Theory". In Zalta, Edward N. (ed.). Stanford Encyclopedia of Philosophy. — (31 January 2023). "Axioms of Zermelo–Fraenkel Set Theory". In — (ed.). Stanford Encyclopedia of Philosophy. Metamath version of the ZFC axioms — A concise and nonredundant axiomatization. The background first order logic is defined especially to facilitate machine verification of proofs. A derivation in Metamath of a version of the separation schema from a version of the replacement schema. Weisstein, Eric W. "Zermelo-Fraenkel Set Theory". MathWorld.
Wikipedia/Zermelo–Fraenkel_set_theory
The Kripke–Platek set theory (KP), pronounced , is an axiomatic set theory developed by Saul Kripke and Richard Platek. The theory can be thought of as roughly the predicative part of Zermelo–Fraenkel set theory (ZFC) and is considerably weaker than it. == Axioms == In its formulation, a Δ0 formula is one all of whose quantifiers are bounded. This means any quantification is the form ∀ u ∈ v {\displaystyle \forall u\in v} or ∃ u ∈ v . {\displaystyle \exists u\in v.} (See the Lévy hierarchy.) Axiom of extensionality: Two sets are the same if and only if they have the same elements. Axiom of induction: φ(a) being a formula, if for all sets x the assumption that φ(y) holds for all elements y of x entails that φ(x) holds, then φ(x) holds for all sets x. Axiom of empty set: There exists a set with no members, called the empty set and denoted {}. Axiom of pairing: If x, y are sets, then so is {x, y}, a set containing x and y as its only elements. Axiom of union: For any set x, there is a set y such that the elements of y are precisely the elements of the elements of x. Axiom of Δ0-separation: Given any set and any Δ0 formula φ(x), there is a subset of the original set containing precisely those elements x for which φ(x) holds. (This is an axiom schema.) Axiom of Δ0-collection: Given any Δ0 formula φ(x, y), if for every set x there exists a set y such that φ(x, y) holds, then for all sets X there exists a set Y such that for every x in X there is a y in Y such that φ(x, y) holds. Some but not all authors include an Axiom of infinity KP with infinity is denoted by KPω. These axioms lead to close connections between KP, generalized recursion theory, and the theory of admissible ordinals. KP can be studied as a constructive set theory by dropping the law of excluded middle, without changing any axioms. === Empty set === If any set c {\displaystyle c} is postulated to exist, such as in the axiom of infinity, then the axiom of empty set is redundant because it is equal to the subset { x ∈ c ∣ x ≠ x } {\displaystyle \{x\in c\mid x\neq x\}} . Furthermore, the existence of a member in the universe of discourse, i.e., ∃x(x=x), is implied in certain formulations of first-order logic, in which case the axiom of empty set follows from the axiom of Δ0-separation, and is thus redundant. === Comparison with Zermelo-Fraenkel set theory === As noted, the above are weaker than ZFC as they exclude the power set axiom, choice, and sometimes infinity. Also the axioms of separation and collection here are weaker than the corresponding axioms in ZFC because the formulas φ used in these are limited to bounded quantifiers only. The axiom of induction in the context of KP is stronger than the usual axiom of regularity, which amounts to applying induction to the complement of a set (the class of all sets not in the given set). == Related definitions == A set A {\displaystyle A\,} is called admissible if it is transitive and ⟨ A , ∈ ⟩ {\displaystyle \langle A,\in \rangle } is a model of Kripke–Platek set theory. An ordinal number α {\displaystyle \alpha } is called an admissible ordinal if L α {\displaystyle L_{\alpha }} is an admissible set. L α {\displaystyle L_{\alpha }} is called an amenable set if it is a standard model of KP set theory without the axiom of Δ0-collection. == Theorems == === Admissible sets === The ordinal α is an admissible ordinal if and only if α is a limit ordinal and there does not exist a γ < α for which there is a Σ1(Lα) mapping from γ onto α. If M is a standard model of KP, then the set of ordinals in M is an admissible ordinal. === Cartesian products exist === Theorem: If A and B are sets, then there is a set A×B which consists of all ordered pairs (a, b) of elements a of A and b of B. Proof: The singleton set with member a, written {a}, is the same as the unordered pair {a, a}, by the axiom of extensionality. The singleton, the set {a, b}, and then also the ordered pair ( a , b ) := { { a } , { a , b } } {\displaystyle (a,b):=\{\{a\},\{a,b\}\}} all exist by pairing. A possible Δ0-formula ψ ( a , b , p ) {\displaystyle \psi (a,b,p)} expressing that p stands for the pair (a, b) is given by the lengthy ∃ r ∈ p ( a ∈ r ∧ ∀ x ∈ r ( x = a ) ) {\displaystyle \exists r\in p\,{\big (}a\in r\,\land \,\forall x\in r\,(x=a){\big )}} ∧ ∃ s ∈ p ( a ∈ s ∧ b ∈ s ∧ ∀ x ∈ s ( x = a ∨ x = b ) ) {\displaystyle \land \,\exists s\in p\,{\big (}a\in s\,\land \,b\in s\,\land \,\forall x\in s\,(x=a\,\lor \,x=b){\big )}} ∧ ∀ t ∈ p ( ( a ∈ t ∧ ∀ x ∈ t ( x = a ) ) ∨ ( a ∈ t ∧ b ∈ t ∧ ∀ x ∈ t ( x = a ∨ x = b ) ) ) . {\displaystyle \land \,\forall t\in p\,{\Big (}{\big (}a\in t\,\land \,\forall x\in t\,(x=a){\big )}\,\lor \,{\big (}a\in t\land b\in t\land \forall x\in t\,(x=a\,\lor \,x=b){\big )}{\Big )}.} What follows are two steps of collection of sets, followed by a restriction through separation. All results are also expressed using set builder notation. Firstly, given b {\displaystyle b} and collecting with respect to A {\displaystyle A} , some superset of A × { b } = { ( a , b ) ∣ a ∈ A } {\displaystyle A\times \{b\}=\{(a,b)\mid a\in A\}} exists by collection. The Δ0-formula ∃ a ∈ A ψ ( a , b , p ) {\displaystyle \exists a\in A\,\psi (a,b,p)} grants that just A × { b } {\displaystyle A\times \{b\}} itself exists by separation. If P {\displaystyle P} ought to stand for this collection of pairs A × { b } {\displaystyle A\times \{b\}} , then a Δ0-formula characterizing it is ∀ a ∈ A ∃ p ∈ P ψ ( a , b , p ) ∧ ∀ p ∈ P ∃ a ∈ A ψ ( a , b , p ) . {\displaystyle \forall a\in A\,\exists p\in P\,\psi (a,b,p)\,\land \,\forall p\in P\,\exists a\in A\,\psi (a,b,p)\,.} Given A {\displaystyle A} and collecting with respect to B {\displaystyle B} , some superset of { A × { b } ∣ b ∈ B } {\displaystyle \{A\times \{b\}\mid b\in B\}} exists by collection. Putting ∃ b ∈ B {\displaystyle \exists b\in B} in front of that last formula and one finds the set { A × { b } ∣ b ∈ B } {\displaystyle \{A\times \{b\}\mid b\in B\}} itself exists by separation. Finally, the desired A × B := ⋃ { A × { b } ∣ b ∈ B } {\displaystyle A\times B:=\bigcup \{A\times \{b\}\mid b\in B\}} exists by union. Q.E.D. === Transitive containment === Transitive containment is the principle that every set is contained in some transitive set. It does not hold in certain set theories, such as Zermelo set theory (though its inclusion as an axiom does not add consistency strength). Theorem: If A is a set, then there exists a transitive set B such that A is a member of B. Proof: We proceed by induction on the formula: ϕ ( A ) := ∃ B ( A ∈ B ∧ ⋃ B ⊆ B ) {\displaystyle \phi (A):=\exists B(A\in B\land \bigcup B\subseteq B)} Note that ⋃ B ⊆ B {\displaystyle \bigcup B\subseteq B} is another way of expressing that B is transitive. The inductive hypothesis then informs us that ∀ a ∈ A ∃ b ( a ∈ b ∧ ⋃ b ⊆ b ) {\displaystyle \forall a\in A\,\exists b(a\in b\land \bigcup b\subseteq b)} . By Δ0-collection, we have: ∃ C ∀ a ∈ A ∃ b ∈ C ( a ∈ b ∧ ⋃ b ⊆ b ) {\displaystyle \exists C\,\forall a\in A\,\exists b\in C(a\in b\land \bigcup b\subseteq b)} By Δ0-separation, the set { c ∈ C ∣ ⋃ c ⊆ c } {\displaystyle \{c\in C\mid \bigcup c\subseteq c\}} exists, whose union we call D. Now D is a union of transitive sets, and therefore itself transitive. And since A ⊆ D {\displaystyle A\subseteq D} , we know D ∪ { A } {\displaystyle D\cup \{A\}} is also transitive, and further contains A, as required. Q.E.D. == Metalogic == The proof-theoretic ordinal of KPω is the Bachmann–Howard ordinal. KP fails to prove some common theorems in set theory, such as the Mostowski collapse lemma. == See also == Constructible universe Admissible ordinal Hereditarily countable set Kripke–Platek set theory with urelements == References == == Bibliography == Devlin, Keith J. (1984). Constructibility. Berlin: Springer-Verlag. ISBN 0-387-13258-9. Gostanian, Richard (1980). "Constructible Models of Subsystems of ZF". Journal of Symbolic Logic. 45 (2). Association for Symbolic Logic: 237. doi:10.2307/2273185. JSTOR 2273185. Kripke, S. (1964), "Transfinite recursion on admissible ordinals", Journal of Symbolic Logic, 29: 161–162, doi:10.2307/2271646, JSTOR 2271646 Platek, Richard Alan (1966), Foundations of recursion theory, Thesis (Ph.D.)–Stanford University, MR 2615453
Wikipedia/Kripke–Platek_set_theory
In universal algebra and in model theory, a structure consists of a set along with a collection of finitary operations and relations that are defined on it. Universal algebra studies structures that generalize the algebraic structures such as groups, rings, fields and vector spaces. The term universal algebra is used for structures of first-order theories with no relation symbols. Model theory has a different scope that encompasses more arbitrary first-order theories, including foundational structures such as models of set theory. From the model-theoretic point of view, structures are the objects used to define the semantics of first-order logic, cf. also Tarski's theory of truth or Tarskian semantics. For a given theory in model theory, a structure is called a model if it satisfies the defining axioms of that theory, although it is sometimes disambiguated as a semantic model when one discusses the notion in the more general setting of mathematical models. Logicians sometimes refer to structures as "interpretations", whereas the term "interpretation" generally has a different (although related) meaning in model theory; see interpretation (model theory). In database theory, structures with no functions are studied as models for relational databases, in the form of relational models. == History == In the context of mathematical logic, the term "model" was first applied in 1940 by the philosopher Willard Van Orman Quine, in a reference to mathematician Richard Dedekind (1831–1916), a pioneer in the development of set theory. Since the 19th century, one main method for proving the consistency of a set of axioms has been to provide a model for it. == Definition == Formally, a structure can be defined as a triple A = ( A , σ , I ) {\displaystyle {\mathcal {A}}=(A,\sigma ,I)} consisting of a domain A , {\displaystyle A,} a signature σ , {\displaystyle \sigma ,} and an interpretation function I {\displaystyle I} that indicates how the signature is to be interpreted on the domain. To indicate that a structure has a particular signature σ {\displaystyle \sigma } one can refer to it as a σ {\displaystyle \sigma } -structure. === Domain === The domain of a structure is an arbitrary set; it is also called the underlying set of the structure, its carrier (especially in universal algebra), its universe (especially in model theory, cf. universe), or its domain of discourse. In classical first-order logic, the definition of a structure prohibits the empty domain. Sometimes the notation dom ⁡ ( A ) {\displaystyle \operatorname {dom} ({\mathcal {A}})} or | A | {\displaystyle |{\mathcal {A}}|} is used for the domain of A , {\displaystyle {\mathcal {A}},} but often no notational distinction is made between a structure and its domain (that is, the same symbol A {\displaystyle {\mathcal {A}}} refers both to the structure and its domain.) === Signature === The signature σ = ( S , ar ) {\displaystyle \sigma =(S,\operatorname {ar} )} of a structure consists of: a set S {\displaystyle S} of function symbols and relation symbols, along with a function ar : S → N 0 {\displaystyle \operatorname {ar} :\ S\to \mathbb {N} _{0}} that ascribes to each symbol s {\displaystyle s} a natural number n = ar ⁡ ( s ) . {\displaystyle n=\operatorname {ar} (s).} The natural number n = ar ⁡ ( s ) {\displaystyle n=\operatorname {ar} (s)} of a symbol s {\displaystyle s} is called the arity of s {\displaystyle s} because it is the arity of the interpretation of s . {\displaystyle s.} Since the signatures that arise in algebra often contain only function symbols, a signature with no relation symbols is called an algebraic signature. A structure with such a signature is also called an algebra; this should not be confused with the notion of an algebra over a field. === Interpretation function === The interpretation function I {\displaystyle I} of A {\displaystyle {\mathcal {A}}} assigns functions and relations to the symbols of the signature. To each function symbol f {\displaystyle f} of arity n {\displaystyle n} is assigned an n {\displaystyle n} -ary function f A = I ( f ) {\displaystyle f^{\mathcal {A}}=I(f)} on the domain. Each relation symbol R {\displaystyle R} of arity n {\displaystyle n} is assigned an n {\displaystyle n} -ary relation R A = I ( R ) ⊆ A a r ( R ) {\displaystyle R^{\mathcal {A}}=I(R)\subseteq A^{\operatorname {ar(R)} }} on the domain. A nullary ( = 0 {\displaystyle =\,0} -ary) function symbol c {\displaystyle c} is called a constant symbol, because its interpretation I ( c ) {\displaystyle I(c)} can be identified with a constant element of the domain. When a structure (and hence an interpretation function) is given by context, no notational distinction is made between a symbol s {\displaystyle s} and its interpretation I ( s ) . {\displaystyle I(s).} For example, if f {\displaystyle f} is a binary function symbol of A , {\displaystyle {\mathcal {A}},} one simply writes f : A 2 → A {\displaystyle f:{\mathcal {A}}^{2}\to {\mathcal {A}}} rather than f A : | A | 2 → | A | . {\displaystyle f^{\mathcal {A}}:|{\mathcal {A}}|^{2}\to |{\mathcal {A}}|.} === Examples === The standard signature σ f {\displaystyle \sigma _{f}} for fields consists of two binary function symbols + {\displaystyle \mathbf {+} } and × {\displaystyle \mathbf {\times } } where additional symbols can be derived, such as a unary function symbol − {\displaystyle \mathbf {-} } (uniquely determined by + {\displaystyle \mathbf {+} } ) and the two constant symbols 0 {\displaystyle \mathbf {0} } and 1 {\displaystyle \mathbf {1} } (uniquely determined by + {\displaystyle \mathbf {+} } and × {\displaystyle \mathbf {\times } } respectively). Thus a structure (algebra) for this signature consists of a set of elements A {\displaystyle A} together with two binary functions, that can be enhanced with a unary function, and two distinguished elements; but there is no requirement that it satisfy any of the field axioms. The rational numbers Q , {\displaystyle \mathbb {Q} ,} the real numbers R {\displaystyle \mathbb {R} } and the complex numbers C , {\displaystyle \mathbb {C} ,} like any other field, can be regarded as σ {\displaystyle \sigma } -structures in an obvious way: Q = ( Q , σ f , I Q ) R = ( R , σ f , I R ) C = ( C , σ f , I C ) {\displaystyle {\begin{alignedat}{3}{\mathcal {Q}}&=(\mathbb {Q} ,\sigma _{f},I_{\mathcal {Q}})\\{\mathcal {R}}&=(\mathbb {R} ,\sigma _{f},I_{\mathcal {R}})\\{\mathcal {C}}&=(\mathbb {C} ,\sigma _{f},I_{\mathcal {C}})\\\end{alignedat}}} In all three cases we have the standard signature given by σ f = ( S f , ar f ) {\displaystyle \sigma _{f}=(S_{f},\operatorname {ar} _{f})} with S f = { + , × , − , 0 , 1 } {\displaystyle S_{f}=\{+,\times ,-,0,1\}} and ar f ( + ) = 2 , ar f ( × ) = 2 , ar f ( − ) = 1 , ar f ( 0 ) = 0 , ar f ( 1 ) = 0. {\displaystyle {\begin{alignedat}{3}\operatorname {ar} _{f}&(+)&&=2,\\\operatorname {ar} _{f}&(\times )&&=2,\\\operatorname {ar} _{f}&(-)&&=1,\\\operatorname {ar} _{f}&(0)&&=0,\\\operatorname {ar} _{f}&(1)&&=0.\\\end{alignedat}}} The interpretation function I Q {\displaystyle I_{\mathcal {Q}}} is: I Q ( + ) : Q × Q → Q {\displaystyle I_{\mathcal {Q}}(+):\mathbb {Q} \times \mathbb {Q} \to \mathbb {Q} } is addition of rational numbers, I Q ( × ) : Q × Q → Q {\displaystyle I_{\mathcal {Q}}(\times ):\mathbb {Q} \times \mathbb {Q} \to \mathbb {Q} } is multiplication of rational numbers, I Q ( − ) : Q → Q {\displaystyle I_{\mathcal {Q}}(-):\mathbb {Q} \to \mathbb {Q} } is the function that takes each rational number x {\displaystyle x} to − x , {\displaystyle -x,} and I Q ( 0 ) ∈ Q {\displaystyle I_{\mathcal {Q}}(0)\in \mathbb {Q} } is the number 0 , {\displaystyle 0,} and I Q ( 1 ) ∈ Q {\displaystyle I_{\mathcal {Q}}(1)\in \mathbb {Q} } is the number 1 ; {\displaystyle 1;} and I R {\displaystyle I_{\mathcal {R}}} and I C {\displaystyle I_{\mathcal {C}}} are similarly defined. But the ring Z {\displaystyle \mathbb {Z} } of integers, which is not a field, is also a σ f {\displaystyle \sigma _{f}} -structure in the same way. In fact, there is no requirement that any of the field axioms hold in a σ f {\displaystyle \sigma _{f}} -structure. A signature for ordered fields needs an additional binary relation such as < {\displaystyle \,<\,} or ≤ , {\displaystyle \,\leq ,\,} and therefore structures for such a signature are not algebras, even though they are of course algebraic structures in the usual, loose sense of the word. The ordinary signature for set theory includes a single binary relation ∈ . {\displaystyle \in .} A structure for this signature consists of a set of elements and an interpretation of the ∈ {\displaystyle \in } relation as a binary relation on these elements. == Induced substructures and closed subsets == A {\displaystyle {\mathcal {A}}} is called an (induced) substructure of B {\displaystyle {\mathcal {B}}} if A {\displaystyle {\mathcal {A}}} and B {\displaystyle {\mathcal {B}}} have the same signature σ ( A ) = σ ( B ) ; {\displaystyle \sigma ({\mathcal {A}})=\sigma ({\mathcal {B}});} the domain of A {\displaystyle {\mathcal {A}}} is contained in the domain of B : {\displaystyle {\mathcal {B}}:} | A | ⊆ | B | ; {\displaystyle |{\mathcal {A}}|\subseteq |{\mathcal {B}}|;} and the interpretations of all function and relation symbols agree on | A | . {\displaystyle |{\mathcal {A}}|.} The usual notation for this relation is A ⊆ B . {\displaystyle {\mathcal {A}}\subseteq {\mathcal {B}}.} A subset B ⊆ | A | {\displaystyle B\subseteq |{\mathcal {A}}|} of the domain of a structure A {\displaystyle {\mathcal {A}}} is called closed if it is closed under the functions of A , {\displaystyle {\mathcal {A}},} that is, if the following condition is satisfied: for every natural number n , {\displaystyle n,} every n {\displaystyle n} -ary function symbol f {\displaystyle f} (in the signature of A {\displaystyle {\mathcal {A}}} ) and all elements b 1 , b 2 , … , b n ∈ B , {\displaystyle b_{1},b_{2},\dots ,b_{n}\in B,} the result of applying f {\displaystyle f} to the n {\displaystyle n} -tuple b 1 b 2 … b n {\displaystyle b_{1}b_{2}\dots b_{n}} is again an element of B : {\displaystyle B:} f ( b 1 , b 2 , … , b n ) ∈ B . {\displaystyle f(b_{1},b_{2},\dots ,b_{n})\in B.} For every subset B ⊆ | A | {\displaystyle B\subseteq |{\mathcal {A}}|} there is a smallest closed subset of | A | {\displaystyle |{\mathcal {A}}|} that contains B . {\displaystyle B.} It is called the closed subset generated by B , {\displaystyle B,} or the hull of B , {\displaystyle B,} and denoted by ⟨ B ⟩ {\displaystyle \langle B\rangle } or ⟨ B ⟩ A {\displaystyle \langle B\rangle _{\mathcal {A}}} . The operator ⟨ ⟩ {\displaystyle \langle \rangle } is a finitary closure operator on the set of subsets of | A | {\displaystyle |{\mathcal {A}}|} . If A = ( A , σ , I ) {\displaystyle {\mathcal {A}}=(A,\sigma ,I)} and B ⊆ A {\displaystyle B\subseteq A} is a closed subset, then ( B , σ , I ′ ) {\displaystyle (B,\sigma ,I')} is an induced substructure of A , {\displaystyle {\mathcal {A}},} where I ′ {\displaystyle I'} assigns to every symbol of σ the restriction to B {\displaystyle B} of its interpretation in A . {\displaystyle {\mathcal {A}}.} Conversely, the domain of an induced substructure is a closed subset. The closed subsets (or induced substructures) of a structure form a lattice. The meet of two subsets is their intersection. The join of two subsets is the closed subset generated by their union. Universal algebra studies the lattice of substructures of a structure in detail. === Examples === Let σ = { + , × , − , 0 , 1 } {\displaystyle \sigma =\{+,\times ,-,0,1\}} be again the standard signature for fields. When regarded as σ {\displaystyle \sigma } -structures in the natural way, the rational numbers form a substructure of the real numbers, and the real numbers form a substructure of the complex numbers. The rational numbers are the smallest substructure of the real (or complex) numbers that also satisfies the field axioms. The set of integers gives an even smaller substructure of the real numbers which is not a field. Indeed, the integers are the substructure of the real numbers generated by the empty set, using this signature. The notion in abstract algebra that corresponds to a substructure of a field, in this signature, is that of a subring, rather than that of a subfield. The most obvious way to define a graph is a structure with a signature σ {\displaystyle \sigma } consisting of a single binary relation symbol E . {\displaystyle E.} The vertices of the graph form the domain of the structure, and for two vertices a {\displaystyle a} and b , {\displaystyle b,} ( a , b ) ∈ E {\displaystyle (a,b)\!\in {\text{E}}} means that a {\displaystyle a} and b {\displaystyle b} are connected by an edge. In this encoding, the notion of induced substructure is more restrictive than the notion of subgraph. For example, let G {\displaystyle G} be a graph consisting of two vertices connected by an edge, and let H {\displaystyle H} be the graph consisting of the same vertices but no edges. H {\displaystyle H} is a subgraph of G , {\displaystyle G,} but not an induced substructure. The notion in graph theory that corresponds to induced substructures is that of induced subgraphs. == Homomorphisms and embeddings == === Homomorphisms === Given two structures A {\displaystyle {\mathcal {A}}} and B {\displaystyle {\mathcal {B}}} of the same signature σ, a (σ-)homomorphism from A {\displaystyle {\mathcal {A}}} to B {\displaystyle {\mathcal {B}}} is a map h : | A | → | B | {\displaystyle h:|{\mathcal {A}}|\rightarrow |{\mathcal {B}}|} that preserves the functions and relations. More precisely: For every n-ary function symbol f of σ and any elements a 1 , a 2 , … , a n ∈ | A | {\displaystyle a_{1},a_{2},\dots ,a_{n}\in |{\mathcal {A}}|} , the following equation holds: h ( f ( a 1 , a 2 , … , a n ) ) = f ( h ( a 1 ) , h ( a 2 ) , … , h ( a n ) ) {\displaystyle h(f(a_{1},a_{2},\dots ,a_{n}))=f(h(a_{1}),h(a_{2}),\dots ,h(a_{n}))} . For every n-ary relation symbol R of σ and any elements a 1 , a 2 , … , a n ∈ | A | {\displaystyle a_{1},a_{2},\dots ,a_{n}\in |{\mathcal {A}}|} , the following implication holds: ( a 1 , a 2 , … , a n ) ∈ R A ⟹ ( h ( a 1 ) , h ( a 2 ) , … , h ( a n ) ) ∈ R B {\displaystyle (a_{1},a_{2},\dots ,a_{n})\in R^{\mathcal {A}}\implies (h(a_{1}),h(a_{2}),\dots ,h(a_{n}))\in R^{\mathcal {B}}} where R A {\displaystyle R^{\mathcal {A}}} , R B {\displaystyle R^{\mathcal {B}}} is the interpretation of the relation symbol R {\displaystyle R} of the object theory in the structure A {\displaystyle {\mathcal {A}}} , B {\displaystyle {\mathcal {B}}} respectively. A homomorphism h from A {\displaystyle {\mathcal {A}}} to B {\displaystyle {\mathcal {B}}} is typically denoted as h : A → B {\displaystyle h:{\mathcal {A}}\rightarrow {\mathcal {B}}} , although technically the function h is between the domains | A | {\displaystyle |{\mathcal {A}}|} , | B | {\displaystyle |{\mathcal {B}}|} of the two structures A {\displaystyle {\mathcal {A}}} , B {\displaystyle {\mathcal {B}}} . For every signature σ there is a concrete category σ-Hom which has σ-structures as objects and σ-homomorphisms as morphisms. A homomorphism h : A → B {\displaystyle h:{\mathcal {A}}\rightarrow {\mathcal {B}}} is sometimes called strong if: For every n-ary relation symbol R of the object theory and any elements b 1 , b 2 , … , b n ∈ | B | {\displaystyle b_{1},b_{2},\dots ,b_{n}\in |{\mathcal {B}}|} such that ( b 1 , b 2 , … , b n ) ∈ R B {\displaystyle (b_{1},b_{2},\dots ,b_{n})\in R^{\mathcal {B}}} , there are a 1 , a 2 , … , a n ∈ | A | {\displaystyle a_{1},a_{2},\dots ,a_{n}\in |{\mathcal {A}}|} such that ( a 1 , a 2 , … , a n ) ∈ R A {\displaystyle (a_{1},a_{2},\dots ,a_{n})\in R^{\mathcal {A}}} and b 1 = h ( a 1 ) , b 2 = h ( a 2 ) , … , b n = h ( a n ) . {\displaystyle b_{1}=h(a_{1}),\,b_{2}=h(a_{2}),\,\dots ,\,b_{n}=h(a_{n}).} The strong homomorphisms give rise to a subcategory of the category σ-Hom that was defined above. === Embeddings === A (σ-)homomorphism h : A → B {\displaystyle h:{\mathcal {A}}\rightarrow {\mathcal {B}}} is called a (σ-)embedding if it is one-to-one and for every n-ary relation symbol R of σ and any elements a 1 , a 2 , … , a n {\displaystyle a_{1},a_{2},\dots ,a_{n}} , the following equivalence holds: ( a 1 , a 2 , … , a n ) ∈ R A ⟺ ( h ( a 1 ) , h ( a 2 ) , … , h ( a n ) ) ∈ R B {\displaystyle (a_{1},a_{2},\dots ,a_{n})\in R^{\mathcal {A}}\iff (h(a_{1}),h(a_{2}),\dots ,h(a_{n}))\in R^{\mathcal {B}}} (where as before R A {\displaystyle R^{\mathcal {A}}} , R B {\displaystyle R^{\mathcal {B}}} refers to the interpretation of the relation symbol R of the object theory σ in the structure A {\displaystyle {\mathcal {A}}} , B {\displaystyle {\mathcal {B}}} respectively). Thus an embedding is the same thing as a strong homomorphism which is one-to-one. The category σ-Emb of σ-structures and σ-embeddings is a concrete subcategory of σ-Hom. Induced substructures correspond to subobjects in σ-Emb. If σ has only function symbols, σ-Emb is the subcategory of monomorphisms of σ-Hom. In this case induced substructures also correspond to subobjects in σ-Hom. === Example === As seen above, in the standard encoding of graphs as structures the induced substructures are precisely the induced subgraphs. However, a homomorphism between graphs is the same thing as a homomorphism between the two structures coding the graph. In the example of the previous section, even though the subgraph H of G is not induced, the identity map id: H → G is a homomorphism. This map is in fact a monomorphism in the category σ-Hom, and therefore H is a subobject of G which is not an induced substructure. === Homomorphism problem === The following problem is known as the homomorphism problem: Given two finite structures A {\displaystyle {\mathcal {A}}} and B {\displaystyle {\mathcal {B}}} of a finite relational signature, find a homomorphism h : A → B {\displaystyle h:{\mathcal {A}}\rightarrow {\mathcal {B}}} or show that no such homomorphism exists. Every constraint satisfaction problem (CSP) has a translation into the homomorphism problem. Therefore, the complexity of CSP can be studied using the methods of finite model theory. Another application is in database theory, where a relational model of a database is essentially the same thing as a relational structure. It turns out that a conjunctive query on a database can be described by another structure in the same signature as the database model. A homomorphism from the relational model to the structure representing the query is the same thing as a solution to the query. This shows that the conjunctive query problem is also equivalent to the homomorphism problem. == Structures and first-order logic == Structures are sometimes referred to as "first-order structures". This is misleading, as nothing in their definition ties them to any specific logic, and in fact they are suitable as semantic objects both for very restricted fragments of first-order logic such as that used in universal algebra, and for second-order logic. In connection with first-order logic and model theory, structures are often called models, even when the question "models of what?" has no obvious answer. === Satisfaction relation === Each first-order structure M = ( M , σ , I ) {\displaystyle {\mathcal {M}}=(M,\sigma ,I)} has a satisfaction relation M ⊨ ϕ {\displaystyle {\mathcal {M}}\vDash \phi } defined for all formulas ϕ {\displaystyle \,\phi } in the language consisting of the language of M {\displaystyle {\mathcal {M}}} together with a constant symbol for each element of M , {\displaystyle M,} which is interpreted as that element. This relation is defined inductively using Tarski's T-schema. A structure M {\displaystyle {\mathcal {M}}} is said to be a model of a theory T {\displaystyle T} if the language of M {\displaystyle {\mathcal {M}}} is the same as the language of T {\displaystyle T} and every sentence in T {\displaystyle T} is satisfied by M . {\displaystyle {\mathcal {M}}.} Thus, for example, a "ring" is a structure for the language of rings that satisfies each of the ring axioms, and a model of ZFC set theory is a structure in the language of set theory that satisfies each of the ZFC axioms. === Definable relations === An n {\displaystyle n} -ary relation R {\displaystyle R} on the universe (i.e. domain) M {\displaystyle M} of the structure M {\displaystyle {\mathcal {M}}} is said to be definable (or explicitly definable cf. Beth definability, or ∅ {\displaystyle \emptyset } -definable, or definable with parameters from ∅ {\displaystyle \emptyset } cf. below) if there is a formula φ ( x 1 , … , x n ) {\displaystyle \varphi (x_{1},\ldots ,x_{n})} such that R = { ( a 1 , … , a n ) ∈ M n : M ⊨ φ ( a 1 , … , a n ) } . {\displaystyle R=\{(a_{1},\ldots ,a_{n})\in M^{n}:{\mathcal {M}}\vDash \varphi (a_{1},\ldots ,a_{n})\}.} In other words, R {\displaystyle R} is definable if and only if there is a formula φ {\displaystyle \varphi } such that ( a 1 , … , a n ) ∈ R ⇔ M ⊨ φ ( a 1 , … , a n ) {\displaystyle (a_{1},\ldots ,a_{n})\in R\Leftrightarrow {\mathcal {M}}\vDash \varphi (a_{1},\ldots ,a_{n})} is correct. An important special case is the definability of specific elements. An element m {\displaystyle m} of M {\displaystyle M} is definable in M {\displaystyle {\mathcal {M}}} if and only if there is a formula φ ( x ) {\displaystyle \varphi (x)} such that M ⊨ ∀ x ( x = m ↔ φ ( x ) ) . {\displaystyle {\mathcal {M}}\vDash \forall x(x=m\leftrightarrow \varphi (x)).} ==== Definability with parameters ==== A relation R {\displaystyle R} is said to be definable with parameters (or | M | {\displaystyle |{\mathcal {M}}|} -definable) if there is a formula φ {\displaystyle \varphi } with parameters from M {\displaystyle {\mathcal {M}}} such that R {\displaystyle R} is definable using φ . {\displaystyle \varphi .} Every element of a structure is definable using the element itself as a parameter. Some authors use definable to mean definable without parameters, while other authors mean definable with parameters. Broadly speaking, the convention that definable means definable without parameters is more common amongst set theorists, while the opposite convention is more common amongst model theorists. ==== Implicit definability ==== Recall from above that an n {\displaystyle n} -ary relation R {\displaystyle R} on the universe M {\displaystyle M} of M {\displaystyle {\mathcal {M}}} is explicitly definable if there is a formula φ ( x 1 , … , x n ) {\displaystyle \varphi (x_{1},\ldots ,x_{n})} such that R = { ( a 1 , … , a n ) ∈ M n : M ⊨ φ ( a 1 , … , a n ) } . {\displaystyle R=\{(a_{1},\ldots ,a_{n})\in M^{n}:{\mathcal {M}}\vDash \varphi (a_{1},\ldots ,a_{n})\}.} Here the formula φ {\displaystyle \varphi } used to define a relation R {\displaystyle R} must be over the signature of M {\displaystyle {\mathcal {M}}} and so φ {\displaystyle \varphi } may not mention R {\displaystyle R} itself, since R {\displaystyle R} is not in the signature of M . {\displaystyle {\mathcal {M}}.} If there is a formula φ {\displaystyle \varphi } in the extended language containing the language of M {\displaystyle {\mathcal {M}}} and a new symbol R , {\displaystyle R,} and the relation R {\displaystyle R} is the only relation on M {\displaystyle {\mathcal {M}}} such that M ⊨ φ , {\displaystyle {\mathcal {M}}\vDash \varphi ,} then R {\displaystyle R} is said to be implicitly definable over M . {\displaystyle {\mathcal {M}}.} By Beth's theorem, every implicitly definable relation is explicitly definable. == Many-sorted structures == Structures as defined above are sometimes called one-sorted structures to distinguish them from the more general many-sorted structures. A many-sorted structure can have an arbitrary number of domains. The sorts are part of the signature, and they play the role of names for the different domains. Many-sorted signatures also prescribe which sorts the functions and relations of a many-sorted structure are defined on. Therefore, the arities of function symbols or relation symbols must be more complicated objects such as tuples of sorts rather than natural numbers. Vector spaces, for example, can be regarded as two-sorted structures in the following way. The two-sorted signature of vector spaces consists of two sorts V (for vectors) and S (for scalars) and the following function symbols: If V is a vector space over a field F, the corresponding two-sorted structure V {\displaystyle {\mathcal {V}}} consists of the vector domain | V | V = V {\displaystyle |{\mathcal {V}}|_{V}=V} , the scalar domain | V | S = F {\displaystyle |{\mathcal {V}}|_{S}=F} , and the obvious functions, such as the vector zero 0 V V = 0 ∈ | V | V {\displaystyle 0_{V}^{\mathcal {V}}=0\in |{\mathcal {V}}|_{V}} , the scalar zero 0 S V = 0 ∈ | V | S {\displaystyle 0_{S}^{\mathcal {V}}=0\in |{\mathcal {V}}|_{S}} , or scalar multiplication × V : | V | S × | V | V → | V | V {\displaystyle \times ^{\mathcal {V}}:|{\mathcal {V}}|_{S}\times |{\mathcal {V}}|_{V}\rightarrow |{\mathcal {V}}|_{V}} . Many-sorted structures are often used as a convenient tool even when they could be avoided with a little effort. But they are rarely defined in a rigorous way, because it is straightforward and tedious (hence unrewarding) to carry out the generalization explicitly. In most mathematical endeavours, not much attention is paid to the sorts. A many-sorted logic however naturally leads to a type theory. As Bart Jacobs puts it: "A logic is always a logic over a type theory." This emphasis in turn leads to categorical logic because a logic over a type theory categorically corresponds to one ("total") category, capturing the logic, being fibred over another ("base") category, capturing the type theory. == Other generalizations == === Partial algebras === Both universal algebra and model theory study classes of (structures or) algebras that are defined by a signature and a set of axioms. In the case of model theory these axioms have the form of first-order sentences. The formalism of universal algebra is much more restrictive; essentially it only allows first-order sentences that have the form of universally quantified equations between terms, e.g. ∀ {\displaystyle \forall } x ∀ {\displaystyle \forall } y (x + y = y + x). One consequence is that the choice of a signature is more significant in universal algebra than it is in model theory. For example, the class of groups, in the signature consisting of the binary function symbol × and the constant symbol 1, is an elementary class, but it is not a variety. Universal algebra solves this problem by adding a unary function symbol −1. In the case of fields this strategy works only for addition. For multiplication it fails because 0 does not have a multiplicative inverse. An ad hoc attempt to deal with this would be to define 0−1 = 0. (This attempt fails, essentially because with this definition 0 × 0−1 = 1 is not true.) Therefore, one is naturally led to allow partial functions, i.e., functions that are defined only on a subset of their domain. However, there are several obvious ways to generalize notions such as substructure, homomorphism and identity. === Structures for typed languages === In type theory, there are many sorts of variables, each of which has a type. Types are inductively defined; given two types δ and σ there is also a type σ → δ that represents functions from objects of type σ to objects of type δ. A structure for a typed language (in the ordinary first-order semantics) must include a separate set of objects of each type, and for a function type the structure must have complete information about the function represented by each object of that type. === Higher-order languages === There is more than one possible semantics for higher-order logic, as discussed in the article on second-order logic. When using full higher-order semantics, a structure need only have a universe for objects of type 0, and the T-schema is extended so that a quantifier over a higher-order type is satisfied by the model if and only if it is disquotationally true. When using first-order semantics, an additional sort is added for each higher-order type, as in the case of a many sorted first order language. === Structures that are proper classes === In the study of set theory and category theory, it is sometimes useful to consider structures in which the domain of discourse is a proper class instead of a set. These structures are sometimes called class models to distinguish them from the "set models" discussed above. When the domain is a proper class, each function and relation symbol may also be represented by a proper class. In Bertrand Russell's Principia Mathematica, structures were also allowed to have a proper class as their domain. == See also == Mathematical structure – Additional mathematical object == Notes == == References == Burris, Stanley N.; Sankappanavar, H. P. (1981), A Course in Universal Algebra, Berlin, New York: Springer-Verlag Chang, Chen Chung; Keisler, H. Jerome (1989) [1973], Model Theory, Elsevier, ISBN 978-0-7204-0692-4 Diestel, Reinhard (2005) [1997], Graph Theory, Graduate Texts in Mathematics, vol. 173 (3rd ed.), Berlin, New York: Springer-Verlag, ISBN 978-3-540-26183-4 Ebbinghaus, Heinz-Dieter; Flum, Jörg; Thomas, Wolfgang (1994), Mathematical Logic (2nd ed.), New York: Springer, ISBN 978-0-387-94258-2 Hinman, P. (2005), Fundamentals of Mathematical Logic, A K Peters, ISBN 978-1-56881-262-5 Hodges, Wilfrid (1993), Model theory, Cambridge: Cambridge University Press, ISBN 978-0-521-30442-9 Hodges, Wilfrid (1997), A shorter model theory, Cambridge: Cambridge University Press, ISBN 978-0-521-58713-6 Marker, David (2002), Model Theory: An Introduction, Berlin, New York: Springer-Verlag, ISBN 978-0-387-98760-6 Poizat, Bruno (2000), A Course in Model Theory: An Introduction to Contemporary Mathematical Logic, Berlin, New York: Springer-Verlag, ISBN 978-0-387-98655-5 Rautenberg, Wolfgang (2010), A Concise Introduction to Mathematical Logic (3rd ed.), New York: Springer Science+Business Media, doi:10.1007/978-1-4419-1221-3, ISBN 978-1-4419-1220-6 Rothmaler, Philipp (2000), Introduction to Model Theory, London: CRC Press, ISBN 978-90-5699-313-9 == External links == Semantics section in Classical Logic (an entry of Stanford Encyclopedia of Philosophy)
Wikipedia/Interpretation_function
Axiomatic constructive set theory is an approach to mathematical constructivism following the program of axiomatic set theory. The same first-order language with " = {\displaystyle =} " and " ∈ {\displaystyle \in } " of classical set theory is usually used, so this is not to be confused with a constructive types approach. On the other hand, some constructive theories are indeed motivated by their interpretability in type theories. In addition to rejecting the principle of excluded middle ( P E M {\displaystyle {\mathrm {PEM} }} ), constructive set theories often require some logical quantifiers in their axioms to be set bounded. The latter is motivated by results tied to impredicativity. == Introduction == === Constructive outlook === ==== Preliminary on the use of intuitionistic logic ==== The logic of the set theories discussed here is constructive in that it rejects the principle of excluded middle P E M {\displaystyle {\mathrm {PEM} }} , i.e. that the disjunction ϕ ∨ ¬ ϕ {\displaystyle \phi \lor \neg \phi } automatically holds for all propositions ϕ {\displaystyle \phi } . This is also often called the law of excluded middle ( L E M {\displaystyle {\mathrm {LEM} }} ) in contexts where it is assumed. Constructively, as a rule, to prove the excluded middle for a proposition P {\displaystyle P} , i.e. to prove the particular disjunction P ∨ ¬ P {\displaystyle P\lor \neg P} , either P {\displaystyle P} or ¬ P {\displaystyle \neg P} needs to be explicitly proven. When either such proof is established, one says the proposition is decidable, and this then logically implies the disjunction holds. Similarly and more commonly, a predicate Q ( x ) {\displaystyle Q(x)} for x {\displaystyle x} in a domain X {\displaystyle X} is said to be decidable when the more intricate statement ∀ ( x ∈ X ) . ( Q ( x ) ∨ ¬ Q ( x ) ) {\displaystyle \forall (x\in X).{\big (}Q(x)\lor \neg Q(x){\big )}} is provable. Non-constructive axioms may enable proofs that formally claim decidability of such P {\displaystyle P} (and/or Q {\displaystyle Q} ) in the sense that they prove excluded middle for P {\displaystyle P} (resp. the statement using the quantifier above) without demonstrating the truth of either side of the disjunction(s). This is often the case in classical logic. In contrast, axiomatic theories deemed constructive tend to not permit many classical proofs of statements involving properties that are provenly computationally undecidable. The law of noncontradiction is a special case of the propositional form of modus ponens. Using the former with any negated statement ¬ P {\displaystyle \neg P} , one valid De Morgan's law thus implies ¬ ¬ ( P ∨ ¬ P ) {\displaystyle \neg \neg (P\lor \neg P)} already in the more conservative minimal logic. In words, intuitionistic logic still posits: It is impossible to rule out a proposition and rule out its negation both at once, and thus the rejection of any instantiated excluded middle statement for an individual proposition is inconsistent. Here the double-negation captures that the disjunction statement now provenly can never be ruled out or rejected, even in cases where the disjunction may not be provable (for example, by demonstrating one of the disjuncts, thus deciding P {\displaystyle P} ) from the assumed axioms. More generally, constructive mathematical theories tend to prove classically equivalent reformulations of classical theorems. For example, in constructive analysis, one cannot prove the intermediate value theorem in its textbook formulation, but one can prove theorems with algorithmic content that, as soon as double negation elimination and its consequences are assumed legal, are at once classically equivalent to the classical statement. The difference is that the constructive proofs are harder to find. The intuitionistic logic underlying the set theories discussed here, unlike minimal logic, still permits double negation elimination for individual propositions P {\displaystyle P} for which excluded middle holds. In turn the theorem formulations regarding finite objects tends to not differ from their classical counterparts. Given a model of all natural numbers, the equivalent for predicates, namely Markov's principle, does not automatically hold, but may be considered as an additional principle. In an inhabited domain and using explosion, the disjunction P ∨ ∃ ( x ∈ X ) . ¬ Q ( x ) {\displaystyle P\lor \exists (x\in X).\neg Q(x)} implies the existence claim ∃ ( x ∈ X ) . ( Q ( x ) → P ) {\displaystyle \exists (x\in X).(Q(x)\to P)} , which in turn implies ( ∀ ( x ∈ X ) . Q ( x ) ) → P {\displaystyle {\big (}\forall (x\in X).Q(x){\big )}\to P} . Classically, these implications are always reversible. If one of the former is classically valid, it can be worth trying to establish it in the latter form. For the special case where P {\displaystyle P} is rejected, one deals with a counter-example existence claim ∃ ( x ∈ X ) . ¬ Q ( x ) {\displaystyle \exists (x\in X).\neg Q(x)} , which is generally constructively stronger than a rejection claim ¬ ∀ ( x ∈ X ) . Q ( x ) {\displaystyle \neg \forall (x\in X).Q(x)} : Exemplifying a t {\displaystyle t} such that Q ( t ) {\displaystyle Q(t)} is contradictory of course means it is not the case that Q {\displaystyle Q} holds for all possible x {\displaystyle x} . But one may also demonstrate that Q {\displaystyle Q} holding for all x {\displaystyle x} would logically lead to a contradiction without the aid of a specific counter-example, and even while not being able to construct one. In the latter case, constructively, here one does not stipulate an existence claim. ==== Imposed restrictions on a set theory ==== Compared to the classical counterpart, one is generally less likely to prove the existence of relations that cannot be realized. A restriction to the constructive reading of existence apriori leads to stricter requirements regarding which characterizations of a set f ⊂ X × Y {\displaystyle f\subset X\times Y} involving unbounded collections constitute a (mathematical, and so always meaning total) function. This is often because the predicate in a case-wise would-be definition may not be decidable. Adopting the standard definition of set equality via extensionality, the full Axiom of Choice is such a non-constructive principle that implies P E M {\displaystyle {\mathrm {PEM} }} for the formulas permitted in one's adopted Separation schema, by Diaconescu's theorem. Similar results hold for the Axiom of Regularity existence claim, as shown below. The latter has a classically equivalent inductive substitute. So a genuinely intuitionistic development of set theory requires the rewording of some standard axioms to classically equivalent ones. Apart from demands for computability and reservations regrading of impredicativity, technical question regarding which non-logical axioms effectively extend the underlying logic of a theory is also a research subject in its own right. ==== Metalogic ==== With computably undecidable propositions already arising in Robinson arithmetic, even just Predicative separation lets one define elusive subsets easily. In stark contrast to the classical framework, constructive set theories may be closed under the rule that any property that is decidable for all sets is already equivalent to one of the two trivial ones, ⊤ {\displaystyle \top } or ⊥ {\displaystyle \bot } . Also the real line may be taken to be indecomposable in this sense. Undecidability of disjunctions also affects the claims about total orders such as that of all ordinal numbers, expressed by the provability and rejection of the clauses in the order defining disjunction ( α ∈ β ) ∨ ( α = β ) ∨ ( β ∈ α ) {\displaystyle (\alpha \in \beta )\lor (\alpha =\beta )\lor (\beta \in \alpha )} . This determines whether the relation is trichotomous. A weakened theory of ordinals in turn affects the proof theoretic strength defined in ordinal analysis. In exchange, constructive set theories can exhibit attractive disjunction and existence properties, as is familiar from the study of constructive arithmetic theories. These are features of a fixed theory which metalogically relate judgements of propositions provable in the theory. Particularly well-studied are those such features that can be expressed in Heyting arithmetic, with quantifiers over numbers and which can often be realized by numbers, as formalized in proof theory. In particular, those are the numerical existence property and the closely related disjunctive property, as well as being closed under Church's rule, witnessing any given function to be computable. A set theory does not only express theorems about numbers, and so one may consider a more general so-called strong existence property that is harder to come by, as will be discussed. A theory has this property if the following can be established: For any property ϕ {\displaystyle \phi } , if the theory proves that a set exist that has that property, i.e. if the theory claims the existence statement, then there is also a property ψ {\displaystyle \psi } that uniquely describes such a set instance. More formally, for any predicate ϕ {\displaystyle \phi } there is a predicate ψ {\displaystyle \psi } so that T ⊢ ∃ x . ϕ ( x ) ⟹ T ⊢ ∃ ! x . ϕ ( x ) ∧ ψ ( x ) {\displaystyle {\mathsf {T}}\vdash \exists x.\phi (x)\implies {\mathsf {T}}\vdash \exists !x.\phi (x)\land \psi (x)} The role analogous to that of realized numbers in arithmetic is played here by defined sets proven to exist by (or according to) the theory. Questions concerning the axiomatic set theory's strength and its relation to term construction are subtle. While many theories discussed tend have all the various numerical properties, the existence property can easily be spoiled, as will be discussed. Weaker forms of existence properties have been formulated. Some theories with a classical reading of existence can in fact also be constrained so as to exhibit the strong existence property. In Zermelo–Fraenkel set theory with sets all taken to be ordinal-definable, a theory denoted Z F + ( V = H O D ) {\displaystyle {\mathsf {ZF}}+({\mathrm {V} }={\mathrm {HOD} })} , no sets without such definability exist. The property is also enforced via the constructible universe postulate in Z F + ( V = L ) {\displaystyle {\mathsf {ZF}}+({\mathrm {V} }={\mathrm {L} })} . For contrast, consider the theory Z F C {\displaystyle {\mathsf {ZFC}}} given by Z F {\displaystyle {\mathsf {ZF}}} plus the full axiom of choice existence postulate: Recall that this collection of axioms proves the well-ordering theorem, implying well-orderings exists for any set. In particular, this means that relations W ⊂ R × R {\displaystyle W\subset {\mathbb {R} }\times {\mathbb {R} }} formally exist that establish the well-ordering of R {\displaystyle {\mathbb {R} }} (i.e. the theory claims the existence of a least element for all subsets of R {\displaystyle {\mathbb {R} }} with respect to those relations). This is despite the fact that definability of such an ordering is known to be independent of Z F C {\displaystyle {\mathsf {ZFC}}} . The latter implies that for no particular formula ψ {\displaystyle \psi } in the language of the theory does the theory prove that the corresponding set is a well-ordering relation of the reals. So Z F C {\displaystyle {\mathsf {ZFC}}} formally proves the existence of a subset W ⊂ R × R {\displaystyle W\subset {\mathbb {R} }\times {\mathbb {R} }} with the property of being a well-ordering relation, but at the same time no particular set W {\displaystyle W} for which the property could be validated can possibly be defined. ==== Anti-classical principles ==== As mentioned above, a constructive theory T {\displaystyle {\mathsf {T}}} may exhibit the numerical existence property, T ⊢ ∃ e . ψ ( e ) ⟹ T ⊢ ψ ( e _ ) {\displaystyle {\mathsf {T}}\vdash \exists e.\psi (e)\implies {\mathsf {T}}\vdash \psi ({\underline {\mathrm {e} }})} , for some number e {\displaystyle {\mathrm {e} }} and where e _ {\displaystyle {\underline {\mathrm {e} }}} denotes the corresponding numeral in the formal theory. Here one must carefully distinguish between provable implications between two propositions, T ⊢ P → Q {\displaystyle {\mathsf {T}}\vdash P\to Q} , and a theory's properties of the form T ⊢ P ⟹ T ⊢ Q {\displaystyle {\mathsf {T}}\vdash P\implies {\mathsf {T}}\vdash Q} . When adopting a metalogically established schema of the latter type as an inference rule of one's proof calculus and nothing new can be proven, one says the theory T {\displaystyle {\mathsf {T}}} is closed under that rule. One may instead consider adjoining the rule corresponding to the meta-theoretical property as an implication (in the sense of " → {\displaystyle \to } ") to T {\displaystyle {\mathsf {T}}} , as an axiom schema or in quantified form. A situation commonly studied is that of a fixed T {\displaystyle {\mathsf {T}}} exhibiting the meta-theoretical property of the following type: For an instance from some collection of formulas of a particular form, here captured via ϕ {\displaystyle \phi } and ψ {\displaystyle \psi } , one established the existence of a number e {\displaystyle {\mathrm {e} }} so that T ⊢ ϕ ⟹ T ⊢ ψ ( e _ ) {\displaystyle {\mathsf {T}}\vdash \phi \implies {\mathsf {T}}\vdash \psi ({\underline {\mathrm {e} }})} . Here one may then postulate ϕ → ∃ ( e ∈ N ) . ψ ( e ) {\displaystyle \phi \to \exists (e\in {\mathbb {N} }).\psi (e)} , where the bound e {\displaystyle e} is a number variable in language of the theory. For example, Church's rule is an admissible rule in first-order Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} and, furthermore, the corresponding Church's thesis principle C T 0 {\displaystyle {\mathrm {CT} }_{0}} may consistently be adopted as an axiom. The new theory with the principle added is anti-classical, in that it may not be consistent anymore to also adopt P E M {\displaystyle {\mathrm {PEM} }} . Similarly, adjoining the excluded middle principle P E M {\displaystyle {\mathrm {PEM} }} to some theory T {\displaystyle {\mathsf {T}}} , the theory thus obtained may prove new, strictly classical statements, and this may spoil some of the meta-theoretical properties that were previously established for T {\displaystyle {\mathsf {T}}} . In such a fashion, C T 0 {\displaystyle {\mathrm {CT} }_{0}} may not be adopted in H A + P E M {\displaystyle {\mathsf {HA}}+{\mathrm {PEM} }} , also known as Peano arithmetic P A {\displaystyle {\mathsf {PA}}} . The focus in this subsection shall be on set theories with quantification over a fully formal notion of an infinite sequences space, i.e. function space, as it will be introduced further below. A translation of Church's rule into the language of the theory itself may here read ∀ ( f ∈ N N ) . ∃ ( e ∈ N ) . ( ∀ ( n ∈ N ) . ∃ ( w ∈ N ) . T ( e , n , w ) ∧ U ( w , f ( n ) ) ) {\displaystyle \forall (f\in {\mathbb {N} }^{\mathbb {N} }).\exists (e\in {\mathbb {N} }).{\Big (}\forall (n\in {\mathbb {N} }).\exists (w\in {\mathbb {N} }).T(e,n,w)\land U(w,f(n)){\Big )}} Kleene's T predicate together with the result extraction expresses that any input number n {\displaystyle n} being mapped to the number f ( n ) {\displaystyle f(n)} is, through w {\displaystyle w} , witnessed to be a computable mapping. Here N {\displaystyle {\mathbb {N} }} now denotes a set theory model of the standard natural numbers and e {\displaystyle e} is an index with respect to a fixed program enumeration. Stronger variants have been used, which extend this principle to functions f ∈ N X {\displaystyle f\in {\mathbb {N} }^{X}} defined on domains X ⊂ N {\displaystyle X\subset {\mathbb {N} }} of low complexity. The principle rejects decidability for the predicate Q ( e ) {\displaystyle Q(e)} defined as ∃ ( w ∈ N ) . T ( e , e , w ) {\displaystyle \exists (w\in {\mathbb {N} }).T(e,e,w)} , expressing that e {\displaystyle e} is the index of a computable function halting on its own index. Weaker, double negated forms of the principle may be considered too, which do not require the existence of a recursive implementation for every f {\displaystyle f} , but which still make principles inconsistent that claim the existence of functions which provenly have no recursive realization. Some forms of a Church's thesis as principle are even consistent with the classical, weak so called second-order arithmetic theory R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} , a subsystem of the two-sorted first-order theory Z 2 {\displaystyle {\mathsf {Z}}_{2}} . The collection of computable functions is classically subcountable, which classically is the same as being countable. But classical set theories will generally claim that N N {\displaystyle {\mathbb {N} }^{\mathbb {N} }} holds also other functions than the computable ones. For example there is a proof in Z F {\displaystyle {\mathsf {ZF}}} that total functions (in the set theory sense) do exist that cannot be captured by a Turing machine. Taking the computable world seriously as ontology, a prime example of an anti-classical conception related the Markovian school is the permitted subcountability of various uncountable collections. When adopting the subcountability of the collection of all unending sequences of natural numbers ( N N {\displaystyle {\mathbb {N} }^{\mathbb {N} }} ) as an axiom in a constructive theory, the "smallness" (in classical terms) of this collection, in some set theoretical realizations, is then already captured by the theory itself. A constructive theory may also adopt neither classical nor anti-classical axioms and so stay agnostic towards either possibility. Constructive principles already prove ∀ ( x ∈ X ) . ¬ ¬ ( Q ( x ) ∨ ¬ Q ( x ) ) {\displaystyle \forall (x\in X).\neg \neg {\big (}Q(x)\lor \neg Q(x){\big )}} for any Q {\displaystyle Q} . And so for any given element x {\displaystyle x} of X {\displaystyle X} , the corresponding excluded middle statement for the proposition cannot be negated. Indeed, for any given x {\displaystyle x} , by noncontradiction it is impossible to rule out Q ( x ) {\displaystyle Q(x)} and rule out its negation both at once, and the relevant De Morgan's rule applies as above. But a theory may in some instances also permit the rejection claim ¬ ∀ ( x ∈ X ) . ( Q ( x ) ∨ ¬ Q ( x ) ) {\displaystyle \neg \forall (x\in X).{\big (}Q(x)\lor \neg Q(x){\big )}} . Adopting this does not necessitate providing a particular t ∈ X {\displaystyle t\in X} witnessing the failure of excluded middle for the particular proposition Q ( t ) {\displaystyle Q(t)} , i.e. witnessing the inconsistent ¬ ( Q ( t ) ∨ ¬ Q ( t ) ) {\displaystyle \neg {\big (}Q(t)\lor \neg Q(t){\big )}} . Predicates Q ( x ) {\displaystyle Q(x)} on an infinite domain X {\displaystyle X} correspond to decision problems. Motivated by provenly computably undecidable problems, one may reject the possibility of decidability of a predicate without also making any existence claim in X {\displaystyle X} . As another example, such a situation is enforced in Brouwerian intuitionistic analysis, in a case where the quantifier ranges over infinitely many unending binary sequences and Q ( x ) {\displaystyle Q(x)} states that a sequence x {\displaystyle x} is everywhere zero. Concerning this property, of being conclusively identified as the sequence which is forever constant, adopting Brouwer's continuity principle strictly rules out that this could be proven decidable for all the sequences. So in a constructive context with a so-called non-classical logic as used here, one may consistently adopt axioms which are both in contradiction to quantified forms of excluded middle, but also non-constructive in the computable sense or as gauged by meta-logical existence properties discussed previously. In that way, a constructive set theory can also provide the framework to study non-classical theories, say rings modeling smooth infinitesimal analysis. === History and overview === Historically, the subject of constructive set theory (often also " C S T {\displaystyle {\mathsf {CST}}} ") begun with John Myhill's work on the theories also called I Z F {\displaystyle {\mathsf {IZF}}} and C S T {\displaystyle {\mathsf {CST}}} . In 1973, he had proposed the former as a first-order set theory based on intuitionistic logic, taking the most common foundation Z F C {\displaystyle {\mathsf {ZFC}}} and throwing out the Axiom of choice as well as the principle of the excluded middle, initially leaving everything else as is. However, different forms of some of the Z F C {\displaystyle {\mathsf {ZFC}}} axioms which are equivalent in the classical setting are inequivalent in the constructive setting, and some forms imply P E M {\displaystyle {\mathrm {PEM} }} , as will be demonstrated. In those cases, the intuitionistically weaker formulations were consequently adopted. The far more conservative system C S T {\displaystyle {\mathsf {CST}}} is also a first-order theory, but of several sorts and bounded quantification, aiming to provide a formal foundation for Errett Bishop's program of constructive mathematics. The main discussion presents a sequence of theories in the same language as Z F {\displaystyle {\mathsf {ZF}}} , leading up to Peter Aczel's well studied C Z F {\displaystyle {\mathsf {CZF}}} , and beyond. Many modern results trace back to Rathjen and his students. C Z F {\displaystyle {\mathsf {CZF}}} is also characterized by the two features present also in Myhill's theory: On the one hand, it is using the Predicative Separation instead of the full, unbounded Separation schema. Boundedness can be handled as a syntactic property or, alternatively, the theories can be conservatively extended with a higher boundedness predicate and its axioms. Secondly, the impredicative Powerset axiom is discarded, generally in favor of related but weaker axioms. The strong form is very casually used in classical general topology. Adding P E M {\displaystyle {\mathrm {PEM} }} to a theory even weaker than C Z F {\displaystyle {\mathsf {CZF}}} recovers Z F {\displaystyle {\mathsf {ZF}}} , as detailed below. The system, which has come to be known as Intuitionistic Zermelo–Fraenkel set theory ( I Z F {\displaystyle {\mathsf {IZF}}} ), is a strong set theory without P E M {\displaystyle {\mathrm {PEM} }} . It is similar to C Z F {\displaystyle {\mathsf {CZF}}} , but less conservative or predicative. The theory denoted I K P {\displaystyle {\mathsf {IKP}}} is the constructive version of K P {\displaystyle {\mathsf {KP}}} , the classical Kripke–Platek set theory without a form of Powerset and where even the Axiom of Collection is bounded. ==== Models ==== Many theories studied in constructive set theory are mere restrictions of Zermelo–Fraenkel set theory ( Z F {\displaystyle {\mathsf {ZF}}} ) with respect to their axiom as well as their underlying logic. Such theories can then also be interpreted in any model of Z F {\displaystyle {\mathsf {ZF}}} . Peano arithmetic P A {\displaystyle {\mathsf {PA}}} is bi-interpretable with the theory given by Z F {\displaystyle {\mathsf {ZF}}} minus Infinity and without infinite sets, plus the existence of all transitive closures. (The latter is also implied after promoting Regularity to the Set Induction schema, which is discussed below.) Likewise, constructive arithmetic can also be taken as an apology for most axioms adopted in C Z F {\displaystyle {\mathsf {CZF}}} : Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} is bi-interpretable with a weak constructive set theory, as also described in the article on H A {\displaystyle {\mathsf {HA}}} . One may arithmetically characterize a membership relation " ∈ {\displaystyle \in } " and with it prove - instead of the existence of a set of natural numbers ω {\displaystyle \omega } - that all sets in its theory are in bijection with a (finite) von Neumann natural, a principle denoted V = F i n {\displaystyle {\mathrm {V} }={\mathrm {Fin} }} . This context further validates Extensionality, Pairing, Union, Binary Intersection (which is related to the Axiom schema of predicative separation) and the Set Induction schema. Taken as axioms, the aforementioned principles constitute a set theory that is already identical with the theory given by C Z F {\displaystyle {\mathsf {CZF}}} minus the existence of ω {\displaystyle \omega } but plus V = F i n {\displaystyle {\mathrm {V} }={\mathrm {Fin} }} as axiom. All those axioms are discussed in detail below. Relatedly, C Z F {\displaystyle {\mathsf {CZF}}} also proves that the hereditarily finite sets fulfill all the previous axioms. This is a result which persists when passing on to P A {\displaystyle {\mathsf {PA}}} and Z F {\displaystyle {\mathsf {ZF}}} minus Infinity. As far as constructive realizations go there is a relevant realizability theory. Relatedly, Aczel's theory constructive Zermelo-Fraenkel C Z F {\displaystyle {\mathsf {CZF}}} has been interpreted in a Martin-Löf type theories, as sketched in the section on C Z F {\displaystyle {\mathsf {CZF}}} . In this way, theorems provable in this and weaker set theories are candidates for a computer realization. Presheaf models for constructive set theories have also been introduced. These are analogous to presheaf models for intuitionistic set theory developed by Dana Scott in the 1980s. Realizability models of C Z F {\displaystyle {\mathsf {CZF}}} within the effective topos have been identified, which, say, at once validate full Separation, relativized dependent choice R D C {\displaystyle {\mathrm {RDC} }} , independence of premise I P {\displaystyle {\mathrm {IP} }} for sets, but also the subcountability of all sets, Markov's principle M P {\displaystyle {\mathrm {MP} }} and Church's thesis C T 0 {\displaystyle {\mathrm {CT} _{0}}} in the formulation for all predicates. === Notation === In an axiomatic set theory, sets are the entities exhibiting properties. But there is then a more intricate relation between the set concept and logic. For example, the property of being a natural number smaller than 100 may be reformulated as being a member of the set of numbers with that property. The set theory axioms govern set existence and thus govern which predicates can be materialized as entity in itself, in this sense. Specification is also directly governed by the axioms, as discussed below. For a practical consideration, consider for example the property of being a sequence of coin flip outcomes that overall show more heads than tails. This property may be used to separate out a corresponding subset of any set of finite sequences of coin flips. Relatedly, the measure theoretic formalization of a probabilistic event is explicitly based around sets and provides many more examples. This section introduces the object language and auxiliary notions used to formalize this materialization. ==== Language ==== The propositional connective symbols used to form syntactic formulas are standard. The axioms of set theory give a means to prove equality " = {\displaystyle =} " of sets and that symbol may, by abuse of notation, be used for classes. A set in which the equality predicate is decidable is also called discrete. Negation " ¬ {\displaystyle \neg } " of equality is sometimes called the denial of equality, and is commonly written " ≠ {\displaystyle \neq } ". However, in a context with apartness relations, for example when dealing with sequences, the latter symbol is also sometimes used for something different. The common treatment, as also adopted here, formally only extends the underlying logic by one primitive binary predicate of set theory, " ∈ {\displaystyle \in } ". As with equality, negation of elementhood " ∈ {\displaystyle \in } " is often written " ∉ {\displaystyle \notin } ". ==== Variables ==== Below the Greek ϕ {\displaystyle \phi } denotes a proposition or predicate variable in axiom schemas and P {\displaystyle P} or Q {\displaystyle Q} is used for particular such predicates. The word "predicate" is sometimes used interchangeably with "formulas" as well, even in the unary case. Quantifiers only ever range over sets and those are denoted by lower case letters. As is common, one may use argument brackets to express predicates, for the sake of highlighting particular free variables in their syntactic expression, as in " Q ( z ) {\displaystyle Q(z)} ". Unique existence ∃ ! x . Q ( x ) {\displaystyle \exists !x.Q(x)} here means ∃ x . ∀ y . ( y = x ↔ Q ( y ) ) {\displaystyle \exists x.\forall y.{\big (}y=x\leftrightarrow Q(y){\big )}} . ==== Classes ==== As is also common, one makes use set builder notation for classes, which, in most contexts, are not part of the object language but used for concise discussion. In particular, one may introduce notation declarations of the corresponding class via " A = { z ∣ Q ( z ) } {\displaystyle A=\{z\mid Q(z)\}} ", for the purpose of expressing any Q ( a ) {\displaystyle Q(a)} as a ∈ A {\displaystyle a\in A} . Logically equivalent predicates can be used to introduce the same class. One also writes { z ∈ B ∣ Q ( z ) } {\displaystyle \{z\in B\mid Q(z)\}} as shorthand for { z ∣ z ∈ B ∧ Q ( z ) } {\displaystyle \{z\mid z\in B\land Q(z)\}} . For example, one may consider { z ∈ B ∣ z ∉ C } {\displaystyle \{z\in B\mid z\notin C\}} and this is also denoted B ∖ C {\displaystyle B\setminus C} . One abbreviates ∀ z . ( z ∈ A → Q ( z ) ) {\displaystyle \forall z.{\big (}z\in A\to Q(z){\big )}} by ∀ ( z ∈ A ) . Q ( z ) {\displaystyle \forall (z\in A).Q(z)} and ∃ z . ( z ∈ A ∧ Q ( z ) ) {\displaystyle \exists z.{\big (}z\in A\land Q(z){\big )}} by ∃ ( z ∈ A ) . Q ( z ) {\displaystyle \exists (z\in A).Q(z)} . The syntactic notion of bounded quantification in this sense can play a role in the formulation of axiom schemas, as seen in the discussion of axioms below. Express the subclass claim ∀ ( z ∈ A ) . z ∈ B {\displaystyle \forall (z\in A).z\in B} , i.e. ∀ z . ( z ∈ A → z ∈ B ) {\displaystyle \forall z.(z\in A\to z\in B)} , by A ⊂ B {\displaystyle A\subset B} . For a predicate Q {\displaystyle Q} , trivially ∀ z . ( ( z ∈ B ∧ Q ( z ) ) → z ∈ B ) {\displaystyle \forall z.{\big (}(z\in B\land Q(z))\to z\in B{\big )}} . And so follows that { z ∈ B ∣ Q ( z ) } ⊂ B {\displaystyle \{z\in B\mid Q(z)\}\subset B} . The notion of subset-bounded quantifiers, as in ∀ ( z ⊂ A ) . z ∈ B {\displaystyle \forall (z\subset A).z\in B} , has been used in set theoretical investigation as well, but will not be further highlighted here. If there provenly exists a set inside a class, meaning ∃ z . ( z ∈ A ) {\displaystyle \exists z.(z\in A)} , then one calls it inhabited. One may also use quantification in A {\displaystyle A} to express this as ∃ ( z ∈ A ) . ( z = z ) {\displaystyle \exists (z\in A).(z=z)} . The class A {\displaystyle A} is then provenly not the empty set, introduced below. While classically equivalent, constructively non-empty is a weaker notion with two negations and ought to be called not uninhabited. Unfortunately, the word for the more useful notion of 'inhabited' is rarely used in classical mathematics. Two ways to express that classes are disjoint does capture many of the intuitionistically valid negation rules: ( ∀ ( x ∈ A ) . x ∉ B ) ↔ ¬ ∃ ( x ∈ A ) . x ∈ B {\displaystyle {\big (}\forall (x\in A).x\notin B{\big )}\leftrightarrow \neg \exists (x\in A).x\in B} . Using the above notation, this is a purely logical equivalence and in this article the proposition will furthermore be expressible as A ∩ B = { } {\displaystyle A\cap B=\{\}} . A subclass A ⊂ B {\displaystyle A\subset B} is called detachable from B {\displaystyle B} if the relativized membership predicate is decidable, i.e. if ∀ ( x ∈ B ) . x ∈ A ∨ x ∉ A {\displaystyle \forall (x\in B).x\in A\lor x\notin A} holds. It is also called decidable if the superclass is clear from the context - often this is the set of natural numbers. ==== Extensional equivalence ==== Denote by A ≃ B {\displaystyle A\simeq B} the statement expressing that two classes have exactly the same elements, i.e. ∀ z . ( z ∈ A ↔ z ∈ B ) {\displaystyle \forall z.(z\in A\leftrightarrow z\in B)} , or equivalently ( A ⊂ B ) ∧ ( B ⊂ A ) {\displaystyle (A\subset B)\land (B\subset A)} . This is not to be conflated with the concept of equinumerosity also used below. With A {\displaystyle A} standing for { z ∣ Q ( z ) } {\displaystyle \{z\mid Q(z)\}} , the convenient notational relation between x ∈ A {\displaystyle x\in A} and Q ( x ) {\displaystyle Q(x)} , axioms of the form ∃ a . ∀ z . ( z ∈ a ↔ Q ( z ) ) {\displaystyle \exists a.\forall z.{\big (}z\in a\leftrightarrow Q(z){\big )}} postulate that the class of all sets for which Q {\displaystyle Q} holds actually forms a set. Less formally, this may be expressed as ∃ a . a ≃ A {\displaystyle \exists a.a\simeq A} . Likewise, the proposition ∀ a . ( a ≃ A ) → P ( a ) {\displaystyle \forall a.(a\simeq A)\to P(a)} conveys " P ( A ) {\displaystyle P(A)} when A {\displaystyle A} is among the theory's sets." For the case where P {\displaystyle P} is the trivially false predicate, the proposition is equivalent to the negation of the former existence claim, expressing the non-existence of A {\displaystyle A} as a set. Further extensions of class comprehension notation as above are in common used in set theory, giving meaning to statements such as " { f ( z ) ∣ Q ( z ) } ≃ { ⟨ x , y , z ⟩ ∣ T ( x , y , z ) } {\displaystyle \{f(z)\mid Q(z)\}\simeq \{\langle x,y,z\rangle \mid T(x,y,z)\}} ", and so on. Syntactically more general, a set w {\displaystyle w} may also be characterized using another 2-ary predicate R {\displaystyle R} trough ∀ x . x ∈ w ↔ R ( x , w ) {\displaystyle \forall x.x\in w\leftrightarrow R(x,w)} , where the right hand side may depend on the actual variable w {\displaystyle w} , and possibly even on membership in w {\displaystyle w} itself. == Subtheories of ZF == Here a series of familiar axioms is presented, or the relevant slight reformulations thereof. It is emphasized how the absence of P E M {\displaystyle {\mathrm {PEM} }} in the logic affects what is provable and it is highlighted which non-classical axioms are, in turn, consistent. === Equality === Using the notation introduced above, the following axiom gives a means to prove equality " = {\displaystyle =} " of two sets, so that through substitution, any predicate about x {\displaystyle x} translates to one of y {\displaystyle y} . By the logical properties of equality, the converse direction of the postulated implication holds automatically. In a constructive interpretation, the elements of a subclass A = { z ∈ B ∣ Q ( z ) ∨ ¬ Q ( z ) } {\displaystyle A=\{z\in B\mid Q(z)\lor \neg Q(z)\}} of B {\displaystyle B} may come equipped with more information than those of B {\displaystyle B} , in the sense that being able to judge b ∈ A {\displaystyle b\in A} is being able to judge Q ( b ) ∨ ¬ Q ( b ) {\displaystyle Q(b)\lor \neg Q(b)} . And (unless the whole disjunction follows from axioms) in the Brouwer–Heyting–Kolmogorov interpretation, this means to have proven Q ( b ) {\displaystyle Q(b)} or having rejected it. As { z ∈ B ∣ Q ( z ) } {\displaystyle \{z\in B\mid Q(z)\}} may not be detachable from B {\displaystyle B} , i.e. as Q {\displaystyle Q} may be not decidable for all elements in B {\displaystyle B} , the two classes A {\displaystyle A} and B {\displaystyle B} must a priori be distinguished. Consider a predicate Q {\displaystyle Q} that provenly holds for all elements of a set y {\displaystyle y} , so that y ≃ { z ∈ y ∣ Q ( z ) } {\displaystyle y\simeq \{z\in y\mid Q(z)\}} , and assume that the class on the right hand side is established to be a set. Note that, even if this set on the right informally also ties to proof-relevant information about the validity of Q {\displaystyle Q} for all the elements, the Extensionality axiom postulates that, in our set theory, the set on the right hand side is judged equal to the one on the left hand side. This above analysis also shows that a statement of the form ∀ ( x ∈ w ) . Q ( x ) {\displaystyle \forall (x\in w).Q(x)} , which in informal class notation may be expressed as w ⊂ { x ∣ Q ( x ) } {\displaystyle w\subset \{x\mid Q(x)\}} , is then equivalently expressed as { x ∈ w ∣ Q ( x ) } = w {\displaystyle \{x\in w\mid Q(x)\}=w} . This means that establishing such ∀ {\displaystyle \forall } -theorems (e.g. the ones provable from full mathematical induction) enables substituting the subclass of w {\displaystyle w} on the left hand side of the equality for just w {\displaystyle w} , in any formula. Note that adopting " = {\displaystyle =} " as a symbol in a predicate logic theory makes equality of two terms a quantifier-free expression. ==== Alternative approaches ==== While often adopted, this axiom has been criticized in constructive thought, as it effectively collapses differently defined properties, or at least the sets viewed as the extension of these properties, a Fregian notion. Modern type theories may instead aim at defining the demanded equivalence " ≃ {\displaystyle \simeq } " in terms of functions, see e.g. type equivalence. The related concept of function extensionality is often not adopted in type theory. Other frameworks for constructive mathematics might instead demand a particular rule for equality or apartness come for the elements z ∈ x {\displaystyle z\in x} of each and every set x {\displaystyle x} discussed. But also in an approach to sets emphasizing apartness may the above definition in terms of subsets be used to characterize a notion of equality " ≃ {\displaystyle \simeq } " of those subsets. Relatedly, a loose notion of complementation of two subsets u ⊂ x {\displaystyle u\subset x} and v ⊂ x {\displaystyle v\subset x} is given when any two members s ∈ u {\displaystyle s\in u} and t ∈ v {\displaystyle t\in v} are provably apart from each other. The collection of complementing pairs ⟨ u , v ⟩ {\displaystyle \langle u,v\rangle } is algebraically well behaved. === Merging sets === Define class notation for the pairing of a few given elements via disjunctions. E.g. z ∈ { a , b } {\displaystyle z\in \{a,b\}} is the quantifier-free statement ( z = a ) ∨ ( z = b ) {\displaystyle (z=a)\lor (z=b)} , and likewise z ∈ { a , b , c } {\displaystyle z\in \{a,b,c\}} says ( z = a ) ∨ ( z = b ) ∨ ( z = c ) {\displaystyle (z=a)\lor (z=b)\lor (z=c)} , and so on. Two other basic existence postulates given some other sets are as follows. Firstly, Given the definitions above, { x , y } ⊂ p {\displaystyle \{x,y\}\subset p} expands to ∀ z . ( z = x ∨ z = y ) → z ∈ p {\displaystyle \forall z.(z=x\lor z=y)\to z\in p} , so this is making use of equality and a disjunction. The axiom says that for any two sets x {\displaystyle x} and y {\displaystyle y} , there is at least one set p {\displaystyle p} , which hold at least those two sets. With bounded Separation below, also the class { x , y } {\displaystyle \{x,y\}} exists as a set. Denote by ⟨ x , y ⟩ {\displaystyle \langle x,y\rangle } the standard ordered pair model { { x } , { x , y } } {\displaystyle \{\{x\},\{x,y\}\}} , so that e.g. q = ⟨ x , y ⟩ {\displaystyle q=\langle x,y\rangle } denotes another bounded formula in the formal language of the theory. And then, using existential quantification and a conjunction, saying that for any set x {\displaystyle x} , there is at least one set u {\displaystyle u} , which holds all the members z {\displaystyle z} , of x {\displaystyle x} 's members y {\displaystyle y} . The minimal such set is the union. The two axioms are commonly formulated stronger, in terms of " ↔ {\displaystyle \leftrightarrow } " instead of just " → {\displaystyle \to } ", although this is technically redundant in the context of B C S T {\displaystyle {\mathsf {BCST}}} : As the Separation axiom below is formulated with " ↔ {\displaystyle \leftrightarrow } ", for statements ∃ t . ∀ z . ϕ ( z ) → z ∈ t {\displaystyle \exists t.\forall z.\phi (z)\to z\in t} the equivalence can be derived, given the theory allows for separation using ϕ {\displaystyle \phi } . In cases where ϕ {\displaystyle \phi } is an existential statement, like here in the union axiom, there is also another formulation using a universal quantifier. Also using bounded Separation, the two axioms just stated together imply the existence of a binary union of two classes a {\displaystyle a} and b {\displaystyle b} , when they have been established to be sets, denoted by ⋃ { a , b } {\displaystyle \bigcup \{a,b\}} or a ∪ b {\displaystyle a\cup b} . For a fixed set z {\displaystyle z} , to validate membership z ∈ a ∪ b {\displaystyle z\in a\cup b} in the union of two given sets y = a {\displaystyle y=a} and y = b {\displaystyle y=b} , one needs to validate the z ∈ y {\displaystyle z\in y} part of the axiom, which can be done by validating the disjunction of the predicates defining the sets a {\displaystyle a} and b {\displaystyle b} , for z {\displaystyle z} . In terms of the associated sets, it is done by validating the disjunction z ∈ a ∨ z ∈ b {\displaystyle z\in a\lor z\in b} . The union and other set forming notations are also used for classes. For instance, the proposition z ∈ A ∧ z ∉ C {\displaystyle z\in A\land z\notin C} is written z ∈ A ∖ C {\displaystyle z\in A\setminus C} . Let now B ⊂ A {\displaystyle B\subset A} . Given z ∈ A {\displaystyle z\in A} , the decidability of membership in B {\displaystyle B} , i.e. the potentially independent statement z ∈ B ∨ z ∉ B {\displaystyle z\in B\lor z\notin B} , can also be expressed as z ∈ B ∪ ( A ∖ B ) {\displaystyle z\in B\cup (A\setminus B)} . But, as for any excluded middle statement, the double-negation of the latter holds: That union isn't not inhabited by z {\displaystyle z} . This goes to show that partitioning is also a more involved notion, constructively. === Set existence === The property that is false for any set corresponds to the empty class, which is denoted by { } {\displaystyle \{\}} or zero, 0 {\displaystyle 0} . That the empty class is a set readily follows from other existence axioms, such as the Axiom of Infinity below. But if, e.g., one is explicitly interested in excluding infinite sets in one's study, one may at this point adopt the Introduction of the symbol { } {\displaystyle \{\}} (as abbreviating notation for expressions in involving characterizing properties) is justified as uniqueness for this set can be proven. As y ∈ { } {\displaystyle y\in \{\}} is false for any y {\displaystyle y} , the axiom then reads ∃ x . x ≃ { } {\displaystyle \exists x.x\simeq \{\}} . Write 1 {\displaystyle 1} for S 0 {\displaystyle S0} , which equals { { } } {\displaystyle \{\{\}\}} , i.e. { 0 } {\displaystyle \{0\}} . Likewise, write 2 {\displaystyle 2} for S 1 {\displaystyle S1} , which equals { { } , { { } } } {\displaystyle \{\{\},\{\{\}\}\}} , i.e. { 0 , 1 } {\displaystyle \{0,1\}} . A simple and provenly false proposition then is, for example, { } ∈ { } {\displaystyle \{\}\in \{\}} , corresponding to 0 < 0 {\displaystyle 0<0} in the standard arithmetic model. Again, here symbols such as { } {\displaystyle \{\}} are treated as convenient notation and any proposition really translates to an expression using only " ∈ {\displaystyle \in } " and logical symbols, including quantifiers. Accompanied by a metamathematical analysis that the capabilities of the new theories are equivalent in an effective manner, formal extensions by symbols such as 0 {\displaystyle 0} may also be considered. More generally, for a set x {\displaystyle x} , define the successor set S x {\displaystyle Sx} as x ∪ { x } {\displaystyle x\cup \{x\}} . The interplay of the successor operation with the membership relation has a recursive clause, in the sense that ( y ∈ S x ) ↔ ( y ∈ x ∨ y = x ) {\displaystyle (y\in Sx)\leftrightarrow (y\in x\lor y=x)} . By reflexivity of equality, x ∈ S x {\displaystyle x\in Sx} , and in particular S x {\displaystyle Sx} is always inhabited. === BCST === The following makes use of axiom schemas, i.e. axioms for some collection of predicates. Some of the stated axiom schemas shall allow for any collection of set parameters as well (meaning any particular named variables v 0 , v 1 , … , v n {\displaystyle v_{0},v_{1},\dots ,v_{n}} ). That is, instantiations of the schema are permitted in which the predicate (some particular ϕ {\displaystyle \phi } ) also depends on a number of further set variables and the statement of the axiom is understood with corresponding extra outer universal closures (as in ∀ v 0 . ∀ v 1 . ⋯ ∀ v n . {\displaystyle \forall v_{0}.\forall v_{1}.\cdots \forall v_{n}.} ). ==== Separation ==== Basic constructive set theory B C S T {\displaystyle {\mathsf {BCST}}} consists of several axioms also part of standard set theory, except the so called "full" Separation axiom is weakened. Beyond the four axioms above, it postulates Predicative Separation as well as the Replacement schema. This axiom amounts to postulating the existence of a set s {\displaystyle s} obtained by the intersection of any set y {\displaystyle y} and any predicatively described class { x ∣ ϕ ( x ) } {\displaystyle \{x\mid \phi (x)\}} . For any z {\displaystyle z} proven to be a set, when the predicate is taken as ϕ ( x ) := x ∈ z {\displaystyle \phi (x):=x\in z} , one obtains the binary intersection of sets and writes s = y ∩ z {\displaystyle s=y\cap z} . Intersection corresponds to conjunction in an analog way to how union corresponds to disjunction. When the predicate is taken as the negation ϕ ( x ) := x ∉ z {\displaystyle \phi (x):=x\notin z} , one obtains the difference principle, granting existence of any set y ∖ z {\displaystyle y\setminus z} . Note that sets like y ∖ y {\displaystyle y\setminus y} or { x ∈ y ∣ ¬ ( x = x ) } {\displaystyle \{x\in y\mid \neg (x=x)\}} are always empty. So, as noted, from Separation and the existence of at least one set (e.g. Infinity below) will follow the existence of the empty set { } {\displaystyle \{\}} (also denoted 0 {\displaystyle 0} ). Within this conservative context of B C S T {\displaystyle {\mathsf {BCST}}} , the Predicative Separation schema is actually equivalent to Empty Set plus the existence of the binary intersection for any two sets. The latter variant of axiomatization does not make use of a formula schema. Predicative Separation is a schema that takes into account syntactic aspects of set defining predicates, up to provable equivalence. The permitted formulas are denoted by Δ 0 {\displaystyle \Delta _{0}} , the lowest level in the set theoretical Lévy hierarchy. General predicates in set theory are never syntactically restricted in such a way and so, in praxis, generic subclasses of sets are still part of the mathematical language. As the scope of subclasses that are provably sets is sensitive to what sets already exist, this scope is expanded when further set existence postulates added added. A class with at most one element is called a subsingleton. For a proposition P {\displaystyle P} , a recurring trope in the constructive analysis of set theory is to view the predicate x = 0 ∧ P {\displaystyle x=0\land P} as the subsingleton B := { x ∈ 1 ∣ P } {\displaystyle B:=\{x\in 1\mid P\}} , which is subclass of the second ordinal 1 := S 0 = { 0 } {\displaystyle 1:=S0=\{0\}} . If it is provable that P {\displaystyle P} holds, or ¬ P {\displaystyle \neg P} , or ¬ ¬ P {\displaystyle \neg \neg P} , then B {\displaystyle B} is inhabited, or empty (uninhabited), or non-empty (not uninhabited), respectively. Clearly, P {\displaystyle P} is equivalent to both the proposition 0 ∈ B {\displaystyle 0\in B} , and also B = 1 {\displaystyle B=1} . Likewise, ¬ P {\displaystyle \neg P} is equivalent to B = 0 {\displaystyle B=0} and, equivalently, also ¬ ( 0 ∈ B ) {\displaystyle \neg (0\in B)} . So, here, B {\displaystyle B} being detachable from 1 {\displaystyle 1} exactly means P ∨ ¬ P {\displaystyle P\lor \neg P} . In the model of the naturals, if B {\displaystyle B} is a number, 0 ∈ B {\displaystyle 0\in B} also expresses that 0 {\displaystyle 0} is smaller than B {\displaystyle B} . The union that is part of the successor operation definition above may be used to express the excluded middle statement as 0 ∈ S B {\displaystyle 0\in SB} . In words, P {\displaystyle P} is decidable if and only if the successor of B {\displaystyle B} is larger than the smallest ordinal 0 {\displaystyle 0} . The proposition P {\displaystyle P} is decided either way through establishing how 0 {\displaystyle 0} is smaller: By 0 {\displaystyle 0} already being smaller than B {\displaystyle B} , or by 0 {\displaystyle 0} being S B {\displaystyle SB} 's direct predecessor. Yet another way to express excluded middle for P {\displaystyle P} is as the existence of a least number member of the inhabited class b := B ∪ { 1 } {\displaystyle b:=B\cup \{1\}} . If one's separation axiom allows for separation with P {\displaystyle P} , then B {\displaystyle B} is a subset, which may be called the truth value associated with P {\displaystyle P} . Two truth values can be proven equal, as sets, by proving an equivalence. In terms of this terminology, the collection of proof values can a priori be understood to be rich. Unsurprisingly, decidable propositions have one of a binary set of truth values. The excluded middle disjunction for that P {\displaystyle P} is then also implied by the global statement ∀ b . ( 0 ∈ b ) ∨ ( 0 ∉ b ) {\displaystyle \forall b.(0\in b)\lor (0\notin b)} . ==== No universal set ==== When using the informal class terminology, any set is also considered a class. At the same time, there do arise so called proper classes that can have no extension as a set. When in a theory there is a proof of ¬ ∃ x . A ⊂ x {\displaystyle \neg \exists x.A\subset x} , then A {\displaystyle A} must be proper. (When taking up the perspective of Z F {\displaystyle {\mathsf {ZF}}} on sets, a theory which has full Separation, proper classes are generally thought of as those that are "too big" to be a set. More technically, they are subclasses of the cumulative hierarchy that extend beyond any ordinal bound.) By a remark in the section on merging sets, a set cannot consistently ruled out to be a member of a class of the form A ∪ { x ∣ x ∉ A } {\displaystyle A\cup \{x\mid x\notin A\}} . A constructive proof that it is in that class contains information. Now if A {\displaystyle A} is a set, then the class { x ∣ x ∉ A } {\displaystyle \{x\mid x\notin A\}} is provably proper. The following demonstrates this in the special case when A {\displaystyle A} is empty, i.e. when the right side is the universal class. Being negative results, it reads as in the classical theory. The following holds for any relation E {\displaystyle E} . It gives a purely logical condition such that two terms s {\displaystyle s} and y {\displaystyle y} cannot be E {\displaystyle E} -related to one another. ( ∀ x . x E s ↔ ( x E y ∧ ¬ x E x ) ) → ¬ ( y E s ∨ s E s ∨ s E y ) {\displaystyle {\big (}\forall x.xEs\leftrightarrow (xEy\land \neg xEx){\big )}\to \neg (yEs\lor sEs\lor sEy)} Most important here is the rejection of the final disjunct, ¬ s E y {\displaystyle \neg sEy} . The expression ¬ ( x ∈ x ) {\displaystyle \neg (x\in x)} does not involve unbounded quantification and is thus allowed in Separation. Russel's construction in turn shows that { x ∈ y ∣ x ∉ x } ∉ y {\displaystyle \{x\in y\mid x\notin x\}\notin y} . So for any set y {\displaystyle y} , Predicative Separation alone implies that there exists a set which is not a member of y {\displaystyle y} . In particular, no universal set can exist in this theory. In a theory further adopting the axiom of regularity, like Z F {\displaystyle {\mathsf {ZF}}} , provenly x ∈ x {\displaystyle x\in x} is false for any set x {\displaystyle x} . There, this then means that the subset { x ∈ y ∣ x ∉ x } {\displaystyle \{x\in y\mid x\notin x\}} is equal to y {\displaystyle y} itself, and that the class { x ∣ x ∈ x } {\displaystyle \{x\mid x\in x\}} is the empty set. For any E {\displaystyle E} and y {\displaystyle y} , the special case s = y {\displaystyle s=y} in the formula above gives ¬ ( ∀ x . x E y ↔ ¬ x E x ) {\displaystyle \neg {\big (}\forall x.xEy\leftrightarrow \neg xEx{\big )}} This already implies that no set y {\displaystyle y} equals the subclass { x ∣ x ∉ x } {\displaystyle \{x\mid x\notin x\}} of the universal class, i.e. that subclass is a proper one as well. But even in Z F {\displaystyle {\mathsf {ZF}}} without Regularity it is consistent for there to be a proper class of singletons which each contain exactly themselves. As an aside, in a theory with stratification like Intuitionistic New Foundations, the syntactic expression x ∈ x {\displaystyle x\in x} may be disallowed in Separation. In turn, the above proof of negation of the existence of a universal set cannot be performed, in that theory. ==== Predicativity ==== The axiom schema of Predicative Separation is also called Δ 0 {\displaystyle \Delta _{0}} -Separation or Bounded Separation, as in Separation for set-bounded quantifiers only. (Warning note: The Lévy hierarchy nomenclature is in analogy to Δ 0 0 {\displaystyle \Delta _{0}^{0}} in the arithmetical hierarchy, albeit comparison can be subtle: The arithmetic classification is sometimes expressed not syntactically but in terms of subclasses of the naturals. Also, the bottom level of the arithmetical hierarchy has several common definitions, some not allowing the use of some total functions. A similar distinction is not relevant on the level Σ 1 0 {\displaystyle \Sigma _{1}^{0}} or higher. Finally note that a Δ 0 {\displaystyle \Delta _{0}} classification of a formula may be expressed up to equivalence in the theory.) The schema is also the way in which Mac Lane weakens a system close to Zermelo set theory Z {\displaystyle {\mathsf {Z}}} , for mathematical foundations related to topos theory. It is also used in the study of absoluteness, and there part of the formulation of Kripke-Platek set theory. The restriction in the axiom is also gatekeeping impredicative definitions: Existence should at best not be claimed for objects that are not explicitly describable, or whose definition involves themselves or reference to a proper class, such as when a property to be checked involves a universal quantifier. So in a constructive theory without Axiom of power set, when R {\displaystyle R} denotes some 2-ary predicate, one should not generally expect a subclass s {\displaystyle s} of y {\displaystyle y} to be a set, in case that it is defined, for example, as in { x ∈ y ∣ ∀ t . ( ( t ⊂ y ) → R ( x , t ) ) } {\displaystyle \{x\in y\mid \forall t.{\big (}(t\subset y)\to R(x,t){\big )}\}} , or via a similar definitions involving any quantification over the sets t ⊂ y {\displaystyle t\subset y} . Note that if this subclass s {\displaystyle s} of y {\displaystyle y} is provenly a set, then this subset itself is also in the unbounded scope of set variable t {\displaystyle t} . In other words, as the subclass property s ⊂ y {\displaystyle s\subset y} is fulfilled, this exact set s {\displaystyle s} , defined using the expression R ( x , s ) {\displaystyle R(x,s)} , would play a role in its own characterization. While predicative Separation leads to fewer given class definitions being sets, it may be emphasized that many class definitions that are classically equivalent are not so when restricting oneself to the weaker logic. Due to the potential undecidability of general predicates, the notion of subset and subclass is automatically more elaborate in constructive set theories than in classical ones. So in this way one has obtained a broader theory. This remains true if full Separation is adopted, such as in the theory I Z F {\displaystyle {\mathsf {IZF}}} , which however spoils the existence property as well as the standard type theoretical interpretations, and in this way spoils a bottom-up view of constructive sets. As an aside, as subtyping is not a necessary feature of constructive type theory, constructive set theory can be said to quite differ from that framework. ==== Replacement ==== Next consider the It is granting existence, as sets, of the range of function-like predicates, obtained via their domains. In the above formulation, the predicate is not restricted akin to the Separation schema, but this axiom already involves an existential quantifier in the antecedent. Of course, weaker schemas could be considered as well. Via Replacement, the existence of any pair { x , y } {\displaystyle \{x,y\}} also follows from that of any other particular pair, such as { 0 , 1 } = 2 = S S 0 {\displaystyle \{0,1\}=2=SS0} . But as the binary union used in S {\displaystyle S} already made use of the Pairing axiom, this approach then necessitates postulating the existence of 2 {\displaystyle 2} over that of 0 {\displaystyle 0} . In a theory with the impredicative Powerset axiom, the existence of 2 ⊂ P P 0 {\displaystyle 2\subset {\mathcal {P}}{\mathcal {P}}0} can also be demonstrated using Separation. With the Replacement schema, the theory outlined thus far proves that the equivalence classes or indexed sums are sets. In particular, the Cartesian product, holding all pairs of elements of two sets, is a set. In turn, for any fixed number (in the metatheory), the corresponding product expression, say x × x × x × x {\displaystyle x\times x\times x\times x} , can be constructed as a set. The axiomatic requirements for sets recursively defined in the language are discussed further below. A set x {\displaystyle x} is discrete, i.e. equality of elements inside a set x {\displaystyle x} is decidable, if the corresponding relation as a subset of x × x {\displaystyle x\times x} is decidable. Replacement is relevant for function comprehension and can be seen as a form of comprehension more generally. Only when assuming P E M {\displaystyle {\mathrm {PEM} }} does Replacement already imply full Separation. In Z F {\displaystyle {\mathsf {ZF}}} , Replacement is mostly important to prove the existence of sets of high rank, namely via instances of the axiom schema where ϕ ( x , y ) {\displaystyle \phi (x,y)} relates relatively small set x {\displaystyle x} to bigger ones, y {\displaystyle y} . Constructive set theories commonly have Axiom schema of Replacement, sometimes restricted to bounded formulas. However, when other axioms are dropped, this schema is actually often strengthened - not beyond Z F {\displaystyle {\mathsf {ZF}}} , but instead merely to gain back some provability strength. Such stronger axioms exist that do not spoil the strong existence properties of a theory, as discussed further below. If i X {\displaystyle i_{X}} is provenly a function on X {\displaystyle X} and it is equipped with a codomain Y {\displaystyle Y} (all discussed in detail below), then the image of i X {\displaystyle i_{X}} is a subset of Y {\displaystyle Y} . In other approaches to the set concept, the notion of subsets is defined in terms of "operations", in this fashion. ==== Hereditarily finite sets ==== Pendants of the elements of the class of hereditarily finite sets H ℵ 0 {\displaystyle H_{\aleph _{0}}} can be implemented in any common programming language. The axioms discussed above abstract from common operations on the set data type: Pairing and Union are related to nesting and flattening, or taken together concatenation. Replacement is related to comprehension and Separation is then related to the often simpler filtering. Replacement together with Set Induction (introduced below) suffices to axiomize H ℵ 0 {\displaystyle H_{\aleph _{0}}} constructively and that theory is also studied without Infinity. A sort of blend between pairing and union, an axiom more readily related to the successor is the Axiom of adjunction. Such principles are relevant for the standard modeling of individual Neumann ordinals. Axiom formulations also exist that pair Union and Replacement in one. While postulating Replacement is not a necessity in the design of a weak constructive set theory that is bi-interpretable with Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} , some form of induction is. For comparison, consider the very weak classical theory called General set theory that interprets the class of natural numbers and their arithmetic via just Extensionality, Adjunction and full Separation. The discussion now proceeds with axioms granting existence of objects which, in different but related form, are also found in dependent type theories, namely products and the collection of natural numbers as a completed set. Infinite sets are particularly handy to reason about operations applied to sequences defined on unbounded index domains, say the formal differentiation of a generating function or the addition of two Cauchy sequences. === ECST === For some fixed predicate I {\displaystyle I} and a set a {\displaystyle a} , the statement I ( a ) ∧ ( ∀ y . I ( y ) → a ⊂ y ) {\displaystyle I(a)\land {\big (}\forall y.I(y)\to a\subset y{\big )}} expresses that a {\displaystyle a} is the smallest (in the sense of " ⊂ {\displaystyle \subset } ") among all sets y {\displaystyle y} for which I ( y ) {\displaystyle I(y)} holds true, and that it is always a subset of such y {\displaystyle y} . The aim of the axiom of infinity is to eventually obtain unique smallest inductive set. In the context of common set theory axioms, one statement of infinitude is to state that a class is inhabited and also includes a chain of membership (or alternatively a chain of supersets). That is, ( ∃ z . z ∈ A ) ∧ ∀ ( x ∈ A ) . ∃ ( s ∈ A ) . x ∈ s {\displaystyle {\big (}\exists z.z\in A{\big )}\land \forall (x\in A).\exists (s\in A).x\in s} . More concretely, denote by I n d A {\displaystyle \mathrm {Ind} _{A}} the inductive property, ( 0 ∈ A ) ∧ ∀ ( x ∈ A ) . S x ∈ A {\displaystyle (0\in A)\land \forall (x\in A).Sx\in A} . In terms of a predicate Q {\displaystyle Q} underlying the class so that ∀ x . ( x ∈ A ) ↔ Q ( x ) {\displaystyle \forall x.(x\in A)\leftrightarrow Q(x)} , the latter translates to Q ( 0 ) ∧ ∀ x . ( Q ( x ) → Q ( S x ) ) {\displaystyle Q(0)\land \forall x.{\big (}Q(x)\to Q(Sx){\big )}} . Write ⋂ B {\displaystyle \bigcap B} for the general intersection { x ∣ ∀ ( y ∈ B ) . x ∈ y } {\displaystyle \{x\mid \forall (y\in B).x\in y\}} . (A variant of this definition may be considered which requires ∩ B ⊂ ∪ B {\displaystyle \cap B\subset \cup B} , but we only use this notion for the following auxiliary definition.) One commonly defines a class ω = ⋂ { y ∣ I n d y } {\displaystyle \omega =\bigcap \{y\mid \mathrm {Ind} _{y}\}} , the intersection of all inductive sets. (Variants of this treatment may work in terms of a formula that depends on a set parameter w {\displaystyle w} so that ω ⊂ w {\displaystyle \omega \subset w} .) The class ω {\displaystyle \omega } exactly holds all x {\displaystyle x} fulfilling the unbounded property ∀ y . I n d y → x ∈ y {\displaystyle \forall y.\mathrm {Ind} _{y}\to x\in y} . The intention is that if inductive sets exist at all, then the class ω {\displaystyle \omega } shares each common natural number with them, and then the proposition ω ⊂ A {\displaystyle \omega \subset A} , by definition of " ⊂ {\displaystyle \subset } ", implies that Q {\displaystyle Q} holds for each of these naturals. While bounded separation does not suffice to prove ω {\displaystyle \omega } to be the desired set, the language here forms the basis for the following axiom, granting natural number induction for predicates that constitute a set. The elementary constructive Set Theory E C S T {\displaystyle {\mathsf {ECST}}} has the axiom of B C S T {\displaystyle {\mathsf {BCST}}} as well as the postulate Going on, one takes the symbol ω {\displaystyle \omega } to denote the now unique smallest inductive set, an unbounded von Neumann ordinal. It contains the empty set and, for each set in ω {\displaystyle \omega } , another set in ω {\displaystyle \omega } that contains one element more. Symbols called zero and successor are in the signature of the theory of Peano. In B C S T {\displaystyle {\mathsf {BCST}}} , the above defined successor of any number also being in the class ω {\displaystyle \omega } follow directly from the characterization of the natural naturals by our von Neumann model. Since the successor of such a set contains itself, one also finds that no successor equals zero. So two of the Peano axioms regarding the symbols zero and the one regarding closedness of S {\displaystyle S} come easily. Fourthly, in E C S T {\displaystyle {\mathsf {ECST}}} , where ω {\displaystyle \omega } is a set, S {\displaystyle S} on ω {\displaystyle \omega } can be proven to be an injective operation. For some predicate of sets P {\displaystyle P} , the statement ∀ S . ( S ⊂ ω → P ( S ) ) {\displaystyle \forall S.(S\subset \omega \to P(S))} claims P {\displaystyle P} holds for all subsets of the set of naturals. And the axiom now proves such sets do exist. Such quantification is also possible in second-order arithmetic. The pairwise order " < {\displaystyle <} " on the naturals is captured by their membership relation " ∈ {\displaystyle \in } ". The theory proves the order as well as the equality relation on this set to be decidable. Not only is no number smaller than 0 {\displaystyle 0} , but induction implies that among subsets of ω {\displaystyle \omega } , it is exactly the empty set which has no least member. The contrapositive of this proves the double-negated least number existence for all non-empty subsets of ω {\displaystyle \omega } . Another valid principle also classically equivalent to it is least number existence for all inhabited detachable subsets. That said, the bare existence claim for the inhabited subset b := { z ∈ 1 ∣ P } ∪ { 1 } {\displaystyle b:=\{z\in 1\mid P\}\cup \{1\}} of ω {\displaystyle \omega } is equivalent to excluded middle for P {\displaystyle P} , and a constructive theory will therefore not prove ω {\displaystyle \omega } to be well-ordered. ==== Weaker formulations of infinity ==== Should it need motivation, the handiness of postulating an unbounded set of numbers in relation to other inductive properties becomes clear in the discussion of arithmetic in set theory further below. But as is familiar from classical set theory, also weak forms of Infinity can be formulated. For example, one may just postulate the existence of some inductive set, ∃ y . I n d y {\displaystyle \exists y.\mathrm {Ind} _{y}} - such an existence postulate suffices when full Separation may then be used to carve out the inductive subset w {\displaystyle w} of natural numbers, the shared subset of all inductive classes. Alternatively, more specific mere existence postulates may be adopted. Either which way, the inductive set then fulfills the following Δ 0 {\displaystyle \Delta _{0}} predecessor existence property in the sense of the von Neumann model: ∀ m . ( m ∈ w ) ↔ ( m = 0 ∨ ∃ ( p ∈ w ) . S p = m ) {\displaystyle \forall m.(m\in w)\leftrightarrow {\big (}m=0\lor \exists (p\in w).Sp=m{\big )}} Without making use of the notation for the previously defined successor notation, the extensional equality to a successor S p = m {\displaystyle Sp=m} is captured by ∀ n . ( n ∈ m ) ↔ ( n = p ∨ n ∈ p ) {\displaystyle \forall n.(n\in m)\leftrightarrow (n=p\lor n\in p)} . This expresses that all elements m {\displaystyle m} are either equal to 0 {\displaystyle 0} or themselves hold a predecessor set p ∈ w {\displaystyle p\in w} which shares all other members with m {\displaystyle m} . Observe that through the expression " ∃ ( p ∈ w ) {\displaystyle \exists (p\in w)} " on the right hand side, the property characterizing w {\displaystyle w} by its members m {\displaystyle m} here syntactically again contains the symbol w {\displaystyle w} itself. Due to the bottom-up nature of the natural numbers, this is tame here. Assuming Δ 0 {\displaystyle \Delta _{0}} -set induction on top of E C S T {\displaystyle {\mathsf {ECST}}} , no two different sets have this property. Also note that there are also longer formulations of this property, avoiding " ∃ ( p ∈ w ) {\displaystyle \exists (p\in w)} " in favor unbounded quantifiers. ==== Number bounds ==== Adopting an Axiom of Infinity, the set-bounded quantification legal in predicates used in Δ 0 {\displaystyle \Delta _{0}} -Separation then explicitly permits numerically unbounded quantifiers - the two meanings of "bounded" should not be confused. With ω {\displaystyle \omega } at hand, call a class of numbers I ⊂ ω {\displaystyle I\subset \omega } bounded if the following existence statement holds ∃ ( m ∈ ω ) . ∀ ( n ∈ ω ) . ( n ∈ I → n < m ) {\displaystyle \exists (m\in \omega ).\forall (n\in \omega ).(n\in I\to n<m)} This is a statements of finiteness, also equivalently formulated via m ≤ n → n ∉ I {\displaystyle m\leq n\to n\notin I} . Similarly, to reflect more closely the discussion of functions below, consider the above condition in the form ∃ ( m ∈ ω ) . ∀ ( n ∈ I ) . ( n < m ) {\displaystyle \exists (m\in \omega ).\forall (n\in I).(n<m)} . For decidable properties, these are Σ 2 0 {\displaystyle \Sigma _{2}^{0}} -statements in arithmetic, but with the Axiom of Infinity, the two quantifiers are set-bound. For a class C {\displaystyle C} , the logically positive unboundedness statement ∀ ( k ∈ ω ) . ∃ ( j ∈ ω ) . ( k ≤ j ∧ j ∈ C ) {\displaystyle \forall (k\in \omega ).\exists (j\in \omega ).(k\leq j\land j\in C)} is now also one of infinitude. It is Π 2 0 {\displaystyle \Pi _{2}^{0}} in the decidable arithmetic case. To validate infinitude of a set, this property even works if the set holds other elements besides infinitely many of members of ω {\displaystyle \omega } . ==== Moderate induction in ECST ==== In the following, an initial segment of the natural numbers, i.e. { n ∈ ω ∣ n < m } {\displaystyle \{n\in \omega \mid n<m\}} for any m ∈ ω {\displaystyle m\in \omega } and including the empty set, is denoted by { 0 , 1 , … , m − 1 } {\displaystyle \{0,1,\dots ,m-1\}} . This set equals m {\displaystyle m} and so at this point " m − 1 {\displaystyle m-1} " is mere notation for its predecessor (i.e. not involving subtraction function). It is instructive to recall the way in which a theory with set comprehension and extensionality ends up encoding predicate logic. Like any class in set theory, a set can be read as corresponding to predicates on sets. For example, an integer is even if it is a member of the set of even integers, or a natural number has a successor if it is a member of the set of natural numbers that have a successor. For a less primitive example, fix some set y {\displaystyle y} and let Q ( n ) {\displaystyle Q(n)} denote the existential statement that the function space on the finite ordinal into y {\displaystyle y} exist. The predicate will be denoted ∃ h . h ≃ y { 0 , 1 , … , n − 1 } {\displaystyle \exists h.h\simeq y^{\{0,1,\dots ,n-1\}}} below, and here the existential quantifier is not merely one over natural numbers, nor is it bounded by any other set. Now a proposition like the finite exponentiation principle ∀ ( n ∈ ω ) . Q ( n ) {\displaystyle \forall (n\in \omega ).Q(n)} and, less formally, the equality ω = { n ∈ ω ∣ Q ( n ) } {\displaystyle \omega =\{n\in \omega \mid Q(n)\}} are just two ways of formulating the same desired statement, namely an n {\displaystyle n} -indexed conjunction of existential propositions where n {\displaystyle n} ranges over the set of all naturals. Via extensional identification, the second form expresses the claim using notation for subclass comprehension and the bracketed object on the right hand side may not even constitute a set. If that subclass is not provably a set, it may not actually be used in many set theory principles in proofs, and establishing the universal closure ∀ ( n ∈ ω ) . Q ( n ) {\displaystyle \forall (n\in \omega ).Q(n)} as a theorem may not be possible. The set theory can thus be strengthened by more set existence axioms, to be used with predicative bounded Separation, but also by just postulating stronger ∀ {\displaystyle \forall } -statements. The second universally quantified conjunct in the strong axiom of Infinity expresses mathematical induction for all y {\displaystyle y} in the universe of discourse, i.e. for sets. This is because the consequent of this clause, ω ⊂ y {\displaystyle \omega \subset y} , states that all n ∈ ω {\displaystyle n\in \omega } fulfill the associated predicate. Being able to use predicative separation to define subsets of ω {\displaystyle \omega } , the theory proves induction for all predicates ϕ ( n ) {\displaystyle \phi (n)} involving only set-bounded quantifiers. This role of set-bounded quantifiers also means that more set existence axioms impact the strength of this induction principle, further motivating the function space and collection axioms that will be a focus of the rest of the article. Notably, E C S T {\displaystyle {\mathsf {ECST}}} already validates induction with quantifiers over the naturals, and hence induction as in the first-order arithmetic theory H A {\displaystyle {\mathsf {HA}}} . The so called axiom of full mathematical induction for any predicate (i.e. class) expressed through set theory language is far stronger than the bounded induction principle valid in E C S T {\displaystyle {\mathsf {ECST}}} . The former induction principle could be directly adopted, closer mirroring second-order arithmetic. In set theory it also follows from full (i.e. unbounded) Separation, which says that all predicates on ∀ {\displaystyle \forall } are sets. Mathematical induction is also superseded by the (full) Set induction axiom. Warning note: In naming induction statements, one must take care not to conflate terminology with arithmetic theories. The first-order induction schema of natural number arithmetic theory claims induction for all predicates definable in the language of first-order arithmetic, namely predicates of just numbers. So to interpret the axiom schema of H A {\displaystyle {\mathsf {HA}}} , one interprets these arithmetical formulas. In that context, the bounded quantification specifically means quantification over a finite range of numbers. One may also speak about the induction in the first-order but two-sorted theory of so-called second-order arithmetic Z 2 {\displaystyle {\mathsf {Z}}_{2}} , in a form explicitly expressed for subsets of the naturals. That class of subsets can be taken to correspond to a richer collection of formulas than the first-order arithmetic definable ones. In the program of reverse mathematics, all mathematical objects discussed are encoded as naturals or subsets of naturals. Subsystems of Z 2 {\displaystyle {\mathsf {Z}}_{2}} with very low complexity comprehension studied in that framework have a language that does not merely express arithmetical sets, while all sets of naturals particular such theories prove to exist are just computable sets. Theorems therein can be a relevant reference point for weak set theories with a set of naturals, predicative separation and only some further restricted form of induction. Constructive reverse mathematics exists as a field but is less developed than its classical counterpart. Z 2 {\displaystyle {\mathsf {Z}}_{2}} shall moreover not be confused with the second-order formulation of Peano arithmetic P A 2 {\displaystyle {\mathsf {PA}}_{2}} . Typical set theories like the one discussed here are also first-order, but those theories are not arithmetics and so formulas may also quantify over the subsets of the naturals. When discussing the strength of axioms concerning numbers, it is also important to keep in mind that the arithmetical and the set theoretical framework do not share a common signature. Likewise, care must always be taken with insights about totality of functions. In computability theory, the μ operator enables all partial general recursive functions (or programs, in the sense that they are Turing computable), including ones e.g. non-primitive recursive but P A {\displaystyle {\mathsf {PA}}} -total, such as the Ackermann function. The definition of the operator involves predicates over the naturals and so the theoretical analysis of functions and their totality depends on the formal framework and proof calculus at hand. === Functions === ==== General note on programs and functions ==== Naturally, the meaning of existence claims is a topic of interest in constructivism, be it for a theory of sets or any other framework. Let R {\displaystyle R} express a property such that a mathematical framework validates what amounts to the statement ∀ ( a ∈ A ) . ∃ ( c ∈ C ) . R ( a , c ) {\displaystyle \forall (a\in A).\exists (c\in C).R(a,c)} A constructive proof calculus may validate such a judgement in terms of programs on represented domains and some object representing a concrete assignment a ↦ c a {\displaystyle a\mapsto c_{a}} , providing a particular choice of value in C {\displaystyle C} (a unique one), for each input from A {\displaystyle A} . Expressed through the rewriting ∀ ( a ∈ A ) . R ( a , c a ) {\displaystyle \forall (a\in A).R(a,c_{a})} , this function object may be understood as witnessing the proposition. Consider for example the notions of proof in through realizability theory or function terms in a type theory with a notion of quantifiers. The latter captures proof of logical proposition through programs via the Curry–Howard correspondence. Depending on the context, the word "function" may be used in association with a particular model of computation, and this is a priori narrower than what is discussed in the present set theory context. One notion of program is formalized by partial recursive "functions" in computability theory. But beware that here the word "function" is used in a way that also comprises partial functions, and not just "total functions". The scare quotes are used for clarity here, as in a set theory context there is technically no need to speak of total functions, because this requirement is part of the definition of a set theoretical function and partial function spaces can be modeled via unions. At the same time, when combined with a formal arithmetic, partial function programs provides one particularly sharp notion of totality for functions. By Kleene's normal form theorem, each partial recursive function on the naturals computes, for the values where it terminates, the same as a ↦ U ( μ w . T 1 ( e , a , w ) ) {\displaystyle a\mapsto U(\mu w.T_{1}(e,a,w))} , for some partial function program index e ∈ N {\displaystyle e\in {\mathbb {N} }} , and any index will constitute some partial function. A program can be associated with a e {\displaystyle e} and may be said to be T 1 {\displaystyle T_{1}} -total whenever a theory proves ∀ a . ∃ w . T 1 ( e , a , w ) {\displaystyle \forall a.\exists w.T_{1}(e,a,w)} , where T 1 {\displaystyle T_{1}} amounts to a primitive recursive program and w {\displaystyle w} is related to the execution of e {\displaystyle e} . Kreisel proved that the class of partial recursive functions proven T 1 {\displaystyle T_{1}} -total by H A {\displaystyle {\mathsf {HA}}} is not enriched when P E M {\displaystyle {\mathrm {PEM} }} is added. As a predicate in e {\displaystyle e} , this totality constitutes an undecidable subset of indices, highlighting that the recursive world of functions between the naturals is already captured by a set dominated by N {\displaystyle {\mathbb {N} }} . As a third warning, note that this notion is really about programs and several indices will in fact constitute the same function, in the extensional sense. A theory in first-order logic, such as the axiomatic set theories discussed here, comes with a joint notion of total and functional for a binary predicate R {\displaystyle R} , namely ∀ a . ∃ ! c . R ( a , c ) {\displaystyle \forall a.\exists !c.R(a,c)} . Such theories relate to programs only indirectly. If S {\displaystyle S} denotes the successor operation in a formal language of a theory being studied, then any number, e.g. S S S 0 {\displaystyle {\mathrm {SSS0} }} (the number three), may metalogically be related to the standard numeral, e.g. S S S 0 _ = S S S 0 {\displaystyle {\underline {\mathrm {SSS0} }}=SSS0} . Similarly, programs in the partial recursive sense may be unrolled to predicates and weak assumptions suffice so that such a translation respects equality of their return values. Among finitely axiomizable sub-theories of P A {\displaystyle {\mathsf {PA}}} , classical Robinson arithmetic Q {\displaystyle {\mathsf {Q}}} exactly fulfills this. Its existence claims are intended to only concern natural numbers and instead of using the full mathematical induction schema for arithmetic formulas, the theories' axioms postulate that every number is either zero or that there exists a predecessor number to it. Focusing on T 1 {\displaystyle T_{1}} -total recursive functions here, it is a meta-theorem that the language of arithmetic expresses them by Σ 1 {\displaystyle \Sigma _{1}} -predicates G {\displaystyle G} encoding their graph such that Q {\displaystyle {\mathsf {Q}}} represents them, in the sense that it correctly proves or rejects G ( a _ , c _ ) {\displaystyle G({\underline {\mathrm {a} }},{\underline {\mathrm {c} }})} for any input-output pair of numbers a {\displaystyle \mathrm {a} } and c {\displaystyle \mathrm {c} } in the meta-theory. Now given a correctly representing G {\displaystyle G} , the predicate G l e a s t ( a , c ) {\displaystyle G_{\mathrm {least} }(a,c)} defined by G ( a , c ) ∧ ∀ ( n < c ) . ¬ G ( a , n ) {\displaystyle G(a,c)\land \forall (n<c).\neg G(a,n)} represents the recursive function just as well, and as this explicitly only validates the smallest return value, the theory also proves functionality for all inputs a {\displaystyle {\mathrm {a} }} in the sense of Q ⊢ ∃ ! c . G l e a s t ( a _ , c ) {\displaystyle {\mathsf {Q}}\vdash \exists !c.G_{\mathrm {least} }({\underline {\mathrm {a} }},c)} . Given a representing predicate, then at the cost of making use of P E M {\displaystyle {\mathrm {PEM} }} , one can always also systematically (i.e. with a ∀ a . {\displaystyle \forall a.} ) prove the graph to be total functional. Which predicates are provably functional for various inputs, or even total functional on their domain, generally depends on the adopted axioms of a theory and proof calculus. For example, for the diagonal halting problem, which cannot have a T 1 {\displaystyle T_{1}} -total index, it is H A {\displaystyle {\mathsf {HA}}} -independent whether the corresponding graph predicate on N × { 0 , 1 } {\displaystyle {\mathbb {N} }\times \{0,1\}} (a decision problem) is total functional, but P E M {\displaystyle {\mathrm {PEM} }} implies that it is. Proof theoretical function hierarchies provide examples of predicates proven total functional in systems going beyond P A {\displaystyle {\mathsf {PA}}} . Which sets proven to exist do constitute a total function, in the sense introduced next, also always depends on the axioms and the proof calculus. Finally, note that the soundness of halting claims is a metalogical property beyond consistency, i.e. a theory may be consistent and from it one may prove that some program will eventually halt, despite this never actually occurring when said program is run. More formally, assuming consistency of a theory does not imply it is also arithmetically Σ 1 {\displaystyle \Sigma _{1}} -sound. ==== Total functional relations ==== In set theory language here, speak of a function class when f ⊂ A × C {\displaystyle f\subset A\times C} and provenly ∀ ( a ∈ A ) . ∃ ! ( c ∈ C ) . ⟨ a , c ⟩ ∈ f {\displaystyle \forall (a\in A).\,\exists !(c\in C).\langle a,c\rangle \in f} . Notably, this definition involves quantifier explicitly asking for existence - an aspect which is particularly important in the constructive context. In words: For every a {\displaystyle a} , it demands the unique existence of a c {\displaystyle c} so that ⟨ a , c ⟩ ∈ f {\displaystyle \langle a,c\rangle \in f} . In the case that this holds one may use function application bracket notation and write f ( a ) = c {\displaystyle f(a)=c} . The above property may then be stated as ∀ ( a ∈ A ) . ∃ ! ( c ∈ C ) . f ( a ) = c {\displaystyle \forall (a\in A).\,\exists !(c\in C).f(a)=c} . This notation may be extended to equality of function values. Some notational conveniences involving function application will only work when a set has indeed been established to be a function. Let C A {\displaystyle C^{A}} (also written A C {\displaystyle ^{A}C} ) denote the class of sets that fulfill the function property. This is the class of functions from A {\displaystyle A} to C {\displaystyle C} in a pure set theory. Below the notation x → y {\displaystyle x\to y} is also used for y x {\displaystyle y^{x}} , for the sake of distinguishing it from ordinal exponentiation. When functions are understood as just function graphs as here, the membership proposition f ∈ C A {\displaystyle f\in C^{A}} is also written f : A → C {\displaystyle f\colon A\to C} . The Boolean-valued χ B : A → { 0 , 1 } {\displaystyle \chi _{B}\colon A\to \{0,1\}} are among the classes discussed in the next section. By construction, any such function respects equality in the sense that ( x = y ) → f ( x ) = f ( y ) {\displaystyle (x=y)\to f(x)=f(y)} , for any inputs from A {\displaystyle A} . This is worth mentioning since also more broader concepts of "assignment routines" or "operations" exist in the mathematical literature, which may not in general respect this. Variants of the functional predicate definition using apartness relations on setoids have been defined as well. A subset of a function is still a function and the function predicate may also be proven for enlarged chosen codomain sets. As noted, care must be taken with nomenclature "function", a word which sees use in most mathematical frameworks. When a function set itself is not tied to a particular codomain, then this set of pairs is also member of a function space with larger codomain. This do not happen when by the word one denotes the subset of pairs paired with a codomain set, i.e. a formalization in terms of ( A × C ) × { C } {\displaystyle (A\times C)\times \{C\}} . This is mostly a matter of bookkeeping, but affects how other predicates are defined, question of size. This choice is also just enforced by some mathematical frameworks. Similar considerations apply to any treatment of partial functions and their domains. If both the domain A {\displaystyle A} and considered codomain C {\displaystyle C} are sets, then the above function predicate only involves bounded quantifiers. Common notions such as injectivity and surjectivity can be expressed in a bounded fashion as well, and thus so is bijectivity. Both of these tie in to notions of size. Importantly, injection existence between any two sets provides a preorder. A power class does not inject into its underlying set and the latter does not map onto the former. Surjectivity is formally a more complex definition. Note that injectivity shall be defined positively, not by its contrapositive, which is common practice in classical mathematics. The version without negations is sometimes called weakly injective. The existence of value collisions is a strong notion of non-injectivity. And regarding surjectivity, similar considerations exist for outlier-production in the codomain. Whether a subclass (or predicate for that matter) can be judged to be a function set, or even total functional to begin with, will depend on the strength of the theory, which is to say the axioms one adopts. And notably, a general class could also fulfill the above defining predicate without being a subclass of the product A × C {\displaystyle A\times C} , i.e. the property is expressing not more or less than functionality w.r.t. the inputs from A {\displaystyle A} . Now if the domain is a set, the function comprehension principle, also called axiom of unique choice or non-choice, says that a function as a set, with some codomain, exists well. (And this principle is valid in a theory like C Z F {\displaystyle {\mathsf {CZF}}} . Also compare with the Replacement axiom.) That is, the mapping information exists as set and it has a pair for each element in the domain. Of course, for any set from some class, one may always associate unique element of the singleton 1 {\displaystyle 1} , which shows that merely a chosen range being a set does not suffice to be granted a function set. It is a metatheorem for theories containing B C S T {\displaystyle {\mathsf {BCST}}} that adding a function symbol for a provenly total class function is a conservative extension, despite this formally changing the scope of bounded Separation. In summary, in the set theory context the focus is on capturing particular total relations that are functional. To delineate the notion of function in the theories of the previous subsection (a 2-ary logical predicate defined to express a functions graph, together with a proposition that it is total and functional) from the "material" set theoretical notion here, one may explicitly call the latter graph of a function, anafunction or set function. The axiom schema of Replacement can also be formulated in terms of the ranges of such set functions. ==== Finitude ==== One defines three distinct notions involving surjections. For a general set to be (Bishop-)finite shall mean there is a bijective function to a natural. If the existence of such a bijection is proven impossible, the set is called non-finite. Secondly, for a notion weaker than finite, to be finitely indexed (or Kuratowski-finite) shall mean that there is a surjection from a von Neumann natural number onto it. In programming terms, the element of such a set are accessible in a (ending) for-loop, and only those, while it may not be decidable whether repetition occurred. Thirdly, call a set subfinite if it is the subset of a finite set, which thus injects into that finite set. Here, a for-loop will access all of the set's members, but also possibly others. For another combined notion, one weaker than finitely indexed, to be subfinitely indexed means to be in the surjective image of a subfinite set, and in E T C S {\displaystyle {\mathsf {ETCS}}} this just means to be the subset of a finitely indexed set, meaning the subset can also be taken on the image side instead of the domain side. A set exhibiting either of those notions can be understood to be majorized by a finite set, but in the second case the relation between the sets members is not necessarily fully understood. In the third case, validating membership in the set is generally more difficult, and not even membership of its member with respect to some superset of the set is necessary fully understood. The claim that being finite is equivalent to being subfinite, for all sets, is equivalent to P E M {\displaystyle {\mathrm {PEM} }} . More finiteness properties for a set X {\displaystyle X} can be defined, e.g. expressing the existence of some large enough natural such that a certain class of functions on the naturals always fail to map to distinct elements in X {\displaystyle X} . One definition considers some notion of non-injectivity into X {\displaystyle X} . Other definitions consider functions to a fixed superset of X {\displaystyle X} with more elements. Terminology for conditions of finiteness and infinitude may vary. Notably, subfinitely indexed sets (a notion necessarily involving surjections) are sometimes called subfinite (which can be defined without functions). The property of being finitely indexed could also be denoted "finitely countable", to fit the naming logic, but is by some authors also called finitely enumerable (which might be confusing as this suggest an injection in the other direction). Relatedly, the existence of a bijection with a finite set has not established, one may say a set is not finite, but this use of language is then weaker than to claim the set to be non-finite. The same issue applies to countable sets (not proven countable vs. proven non-countable), et cetera. A surjective map may also be called an enumeration. ==== Infinitude ==== The set ω {\displaystyle \omega } itself is clearly unbounded. In fact, for any surjection from a finite range onto ω {\displaystyle \omega } , one may construct an element that is different from any element in the functions range. Where needed, this notion of infinitude can also be expressed in terms of an apartness relation on the set in question. Being not Kuratowski-finite implies being non-finite and indeed the naturals shall not be finite in any sense. Commonly, the word infinite is used for the negative notion of being non-finite. Further, observe that ω {\displaystyle \omega } , unlike any of its members, can be put in bijection with some of its proper unbounded subsets, e.g. those of the form w m := { k ∈ ω ∣ k > m } {\displaystyle w_{m}:=\{k\in \omega \mid k>m\}} for any m ∈ ω {\displaystyle m\in \omega } . This validates the formulations of Dedekind-infinite. So more generally than the property of infinitude in the previous section on number bounds, one may call a set infinite in the logically positive sense if one can inject ω {\displaystyle \omega } into it. A set that is even in bijection with ω {\displaystyle \omega } may be called countably infinite. A set is Tarski-infinite if there is a chain of ⊂ {\displaystyle \subset } -increasing subsets of it. Here each set has new elements compared to its predecessor and the definition does not speak of sets growing rank. There are indeed plenty of properties characterizing infinitude even in classical Z F {\displaystyle {\mathsf {ZF}}} and that theory does not prove all non-finite sets to be infinite in the injection existence sense, albeit it there holds when further assuming countable choice. Z F {\displaystyle {\mathsf {ZF}}} without any choice even permits cardinals aside the aleph numbers, and there can then be sets that negate both of the above properties, i.e. they are both non-Dedekind-infinite and non-finite (also called Dedekind-finite infinite sets). Call an inhabited set countable if there exists a surjection from ω {\displaystyle \omega } onto it and subcountable if this can be done from some subset of ω {\displaystyle \omega } . Call a set enumerable if there exists an injection to ω {\displaystyle \omega } , which renders the set discrete. Notably, all of these are function existence claims. The empty set is not inhabited but generally deemed countable too, and note that the successor set of any countable set is countable. The set ω {\displaystyle \omega } is trivially infinite, countable and enumerable, as witnessed by the identity function. Also here, in strong classical theories many of these notions coincide in general and, as a result, the naming conventions in the literature are inconsistent. An infinite, countable set is equinumeros to ω {\displaystyle \omega } . There are also various ways to characterize logically negative notion. The notion of uncountability, in the sense of being not countable, is also discussed in conjunction with the exponentiation axiom further below. Another notion of uncountability of X {\displaystyle X} is given when one can produce a member in the compliment of any of X {\displaystyle X} 's countable subsets. More properties of finiteness may be defined as negations of such properties, et cetera. ==== Characteristic functions ==== Separation lets us cut out subsets of products A × C {\displaystyle A\times C} , at least when they are described in a bounded fashion. Given any B ⊂ A {\displaystyle B\subset A} , one is now led to reason about classes such as X B := { ⟨ x , y ⟩ ∈ A × { 0 , 1 } ∣ ( x ∈ B ∧ y = 1 ) ∨ ( x ∉ B ∧ y = 0 ) } . {\displaystyle X_{B}:={\big \{}\langle x,y\rangle \in A\times \{0,1\}\mid (x\in B\land y=1)\lor (x\notin B\land y=0){\big \}}.} Since ¬ ( 0 = 1 ) {\displaystyle \neg (0=1)} , one has ( a ∈ B ↔ ⟨ a , 1 ⟩ ∈ X B ) ∧ ( a ∉ B ↔ ⟨ a , 0 ⟩ ∈ X B ) {\displaystyle {\big (}a\in B\ \leftrightarrow \,\langle a,1\rangle \in X_{B}{\big )}\,\land \,{\big (}a\notin B\ \leftrightarrow \,\langle a,0\rangle \in X_{B}{\big )}} and so ( a ∈ B ∨ a ∉ B ) ↔ ∃ ! ( y ∈ { 0 , 1 } ) . ⟨ a , y ⟩ ∈ X B {\displaystyle {\big (}a\in B\lor a\notin B{\big )}\ \leftrightarrow \ \exists !(y\in \{0,1\}).\langle a,y\rangle \in X_{B}} . But be aware that in absence of any non-constructive axioms a ∈ B {\displaystyle a\in B} may in generally not be decidable, since one requires an explicit proof of either disjunct. Constructively, when ∃ ( y ∈ { 0 , 1 } ) . ⟨ x , y ⟩ ∈ X B {\displaystyle \exists (y\in \{0,1\}).\langle x,y\rangle \in X_{B}} cannot be witnessed for all the x ∈ A {\displaystyle x\in A} , or uniqueness of the terms y {\displaystyle y} associated with each x {\displaystyle x} cannot be proven, then one cannot judge the comprehended collection to be total functional. Case in point: The classical derivation of Schröder–Bernstein relies on case analysis - but to constitute a function, particular cases shall actually be specifiable, given any input from the domain. It has been established that Schröder–Bernstein cannot have a proof on the base of I Z F {\displaystyle {\mathsf {IZF}}} plus constructive principles. So to the extent that intuitionistic inference does not go beyond what is formalized here, there is no generic construction of a bijection from two injections in opposing directions. But being compatible with Z F {\displaystyle {\mathsf {ZF}}} , the development in this section still always permits "function on ω {\displaystyle \omega } " to be interpreted as a completed object that is also not necessarily given as lawlike sequence. Applications may be found in the common models for claims about probability, e.g. statements involving the notion of "being given" an unending random sequence of coin flips, even if many predictions can also be expressed in terms of spreads. If indeed one is given a function χ B : A → { 0 , 1 } {\displaystyle \chi _{B}\colon A\to \{0,1\}} , it is the characteristic function actually deciding membership in some detachable subset B ⊂ A {\displaystyle B\subset A} and B = { n ∈ ω ∣ χ B ( n ) = 1 } . {\displaystyle B=\{n\in \omega \mid \chi _{B}(n)=1\}.} Per convention, the detachable subset B {\displaystyle B} , χ B {\displaystyle \chi _{B}} as well as any equivalent of the formulas n ∈ B {\displaystyle n\in B} and χ B ( n ) = 1 {\displaystyle \chi _{B}(n)=1} (with n {\displaystyle n} free) may be referred to as a decidable property or set on A {\displaystyle A} . One may call a collection A {\displaystyle A} searchable for χ B {\displaystyle \chi _{B}} if existence is actually decidable, ∃ ( x ∈ A ) . χ B ( x ) = 1 ∨ ∀ ( x ∈ A ) . χ B ( x ) = 0. {\displaystyle \exists (x\in A).\chi _{B}(x)=1\ \lor \ \forall (x\in A).\chi _{B}(x)=0.} Now consider the case A = ω {\displaystyle A=\omega } . If χ B ( 0 ) = 0 {\displaystyle \chi _{B}(0)=0} , say, then the range { 0 } ⊂ R ⊂ { 0 , 1 } {\displaystyle \{0\}\subset R\subset \{0,1\}} of χ B {\displaystyle \chi _{B}} is an inhabited, counted set, by Replacement. However, the R {\displaystyle R} need not be again a decidable set itself, since the claim R = { 0 } {\displaystyle R=\{0\}} is equivalent to the rather strong ∀ n . χ B ( n ) = 0 {\displaystyle \forall n.\chi _{B}(n)=0} . Moreover, R = { 0 } {\displaystyle R=\{0\}} is also equivalent to B = { } {\displaystyle B=\{\}} and so one can state undecidable propositions about B {\displaystyle B} also when membership in B {\displaystyle B} is decidable. This also plays out like this classically in the sense that statements about B {\displaystyle B} may be independent, but any classical theory then nonetheless claims the joint proposition B = { } ∨ ¬ ( B = { } ) {\displaystyle B=\{\}\lor \neg (B=\{\})} . Consider the set B {\displaystyle B} of all indices of proofs of an inconsistency of the theory at hand, in which case the universally closed statement B = { } {\displaystyle B=\{\}} is a consistency claim. In terms of arithmetic principles, assuming decidability of this would be Π 1 0 {\displaystyle \Pi _{1}^{0}} - P E M {\displaystyle {\mathrm {PEM} }} or arithmetic ∀ {\displaystyle \forall } - P E M {\displaystyle {\mathrm {PEM} }} . This and the stronger related L P O {\displaystyle {\mathrm {LPO} }} , or arithmetic ∃ {\displaystyle \exists } - P E M {\displaystyle {\mathrm {PEM} }} , is discussed below. ==== Witness of apartness ==== The identity of indiscernibles, which in the first-order context is a higher order principle, holds that the equality x = y {\displaystyle x=y} of two terms x {\displaystyle x} and y {\displaystyle y} necessitates that all predicates P {\displaystyle P} agree on them. And so if there exists a predicate P {\displaystyle P} that distinguishes two terms x {\displaystyle x} and y {\displaystyle y} in the sense that P ( x ) ∧ ¬ P ( y ) {\displaystyle P(x)\land \neg P(y)} , then the principle implies that the two terms do not coincide. A form of this may be expressed set theoretically: x , y ∈ A {\displaystyle x,y\in A} may be deemed apart if there exists a subset B ⊂ A {\displaystyle B\subset A} such that one is a member and the other is not. Restricted to detachable subsets, this may also be formulated concisely using characteristic functions χ B ∈ { 0 , 1 } A {\displaystyle \chi _{B}\in \{0,1\}^{A}} . Indeed, the latter does not actually depend on the codomain being a binary set: Equality is rejected, i.e. x ≠ y {\displaystyle x\neq y} is proven, as soon it is established that not all functions f {\displaystyle f} on A {\displaystyle A} validate f ( x ) = f ( y ) {\displaystyle f(x)=f(y)} , a logically negative condition. One may on any set A {\displaystyle A} define the logically positive apartness relation x # A y := ∃ ( f ∈ N A ) . f ( x ) ≠ f ( y ) {\displaystyle x\,\#_{A}\,y\,:=\,\exists (f\in {\mathbb {N} }^{A}).f(x)\neq f(y)} As the naturals are discrete, for these functions the negative condition is equivalent to the (weaker) double-negation of this relation. Again in words, equality of x {\displaystyle x} and y {\displaystyle y} implies that no coloring f ∈ N A {\displaystyle f\in {\mathbb {N} }^{A}} can distinguish them - and so to rule out the former, i.e. to prove x ≠ y {\displaystyle x\neq y} , one must merely rule out the latter, i.e. merely prove ¬ ¬ ( x # A y ) {\displaystyle \neg \neg (x\,\#_{A}\,y)} . ==== Computable sets ==== Going back to more generality, given a general predicate Q {\displaystyle Q} on the numbers (say one defined from Kleene's T predicate), let again B := { n ∈ ω ∣ Q ( n ) } . {\displaystyle B:=\{n\in \omega \mid Q(n)\}.} Given any natural n ∈ ω {\displaystyle n\in \omega } , then ( Q ( n ) ∨ ¬ Q ( n ) ) ↔ ( n ∈ B ∨ n ∉ B ) . {\displaystyle {\big (}Q(n)\lor \neg Q(n){\big )}\leftrightarrow {\big (}n\in B\lor n\notin B{\big )}.} In classical set theory, ∀ ( n ∈ ω ) . Q ( n ) ∨ ¬ Q ( n ) {\displaystyle \forall (n\in \omega ).Q(n)\lor \neg Q(n)} by P E M {\displaystyle {\mathrm {PEM} }} and so excluded middle also holds for subclass membership. If the class B {\displaystyle B} has no numerical bound, then successively going through the natural numbers n {\displaystyle n} , and thus "listing" all numbers in B {\displaystyle B} by simply skipping those with n ∉ B {\displaystyle n\notin B} , classically always constitutes an increasing surjective sequence b : ω ↠ B {\displaystyle b\colon \omega \twoheadrightarrow B} . There, one can obtain a bijective function. In this way, the class of functions in typical classical set theories is provenly rich, as it also contains objects that are beyond what we know to be effectively computable, or programmatically listable in praxis. In computability theory, the computable sets are ranges of non-decreasing total functions in the recursive sense, at the level Σ 1 0 ∩ Π 1 0 = Δ 1 0 {\displaystyle \Sigma _{1}^{0}\cap \Pi _{1}^{0}=\Delta _{1}^{0}} of the arithmetical hierarchy, and not higher. Deciding a predicate at that level amounts to solving the task of eventually finding a certificate that either validates or rejects membership. As not every predicate Q {\displaystyle Q} is computably decidable, also the theory C Z F {\displaystyle {\mathsf {CZF}}} alone will not claim (prove) that all unbounded B ⊂ ω {\displaystyle B\subset \omega } are the range of some bijective function with domain ω {\displaystyle \omega } . See also Kripke's schema. Note that bounded Separation nonetheless proves the more complicated arithmetical predicates to still constitute sets, the next level being the computably enumerable ones at Σ 1 0 {\displaystyle \Sigma _{1}^{0}} . There is a large corpus of computability theory notions regarding how general subsets of naturals relate to one another. For example, one way to establish a bijection of two such sets is by relating them through a computable isomorphism, which is a computable permutation of all the naturals. The latter may in turn be established by a pair of particular injections in opposing directions. ==== Boundedness criteria ==== Any subset B ⊂ ω {\displaystyle B\subset \omega } injects into ω {\displaystyle \omega } . If B {\displaystyle B} is decidable and inhabited with y 0 ∈ B {\displaystyle y_{0}\in B} , the sequence q := { ⟨ x , y ⟩ ∈ ω × B ∣ ( x ∈ B ∧ y = x ) ∨ ( x ∉ B ∧ y = y 0 ) } {\displaystyle q:={\big \{}\langle x,y\rangle \in \omega \times B\mid (x\in B\land y=x)\lor (x\notin B\land y=y_{0}){\big \}}} i.e. q ( x ) := { x x ∈ B y 0 x ∉ B {\displaystyle q(x):={\begin{cases}x&x\in B\\y_{0}&x\notin B\\\end{cases}}} is surjective onto B {\displaystyle B} , making it a counted set. That function also has the property ∀ ( x ∈ B ) . q ( x ) = x {\displaystyle \forall (x\in B).q(x)=x} . Now consider a countable set R ⊂ ω {\displaystyle R\subset \omega } that is bounded in the sense defined previously. Any sequence taking values in R {\displaystyle R} is then numerically capped as well, and in particular eventually does not exceed the identity function on its input indices. Formally, ∀ ( r : ω → R ) . ∃ ( m ∈ ω ) . ∀ ( k ∈ ω ) . k > m → r ( k ) < k {\displaystyle \forall (r\colon \omega \to R).\exists (m\in \omega ).\forall (k\in \omega ).k>m\to r(k)<k} A set I {\displaystyle I} such that this loose bounding statement holds for all sequences taking values in I {\displaystyle I} (or an equivalent formulation of this property) is called pseudo-bounded. The intention of this property would be to still capture that I ⊂ ω {\displaystyle I\subset \omega } is eventually exhausted, albeit now this is expressed in terms of the function space I ω {\displaystyle I^{\omega }} (which is bigger than I {\displaystyle I} in the sense that I {\displaystyle I} always injects into I ω {\displaystyle I^{\omega }} ). The related notion familiar from topological vector space theory is formulated in terms of ratios going to zero for all sequences ( r ( k ) k {\displaystyle {\tfrac {r(k)}{k}}} in the above notation). For a decidable, inhabited set, validity of pseudo-boundedness, together with the counting sequence defined above, grants a bound for all the elements of I {\displaystyle I} . The principle that any inhabited, pseudo-bounded subset of ω {\displaystyle \omega } that is just countable (but not necessarily decidable) is always also bounded is called B D {\displaystyle \mathrm {BD} } - N {\displaystyle {\mathbb {N} }} . The principle also holds generally in many constructive frameworks, such as the Markovian base theory H A + E C T 0 + M P {\displaystyle {\mathsf {HA}}+{\mathrm {ECT} }_{0}+{\mathrm {MP} }} , which is a theory postulating exclusively lawlike sequences with nice number search termination properties. However, B D {\displaystyle \mathrm {BD} } - N {\displaystyle {\mathbb {N} }} is independent of I Z F {\displaystyle {\mathsf {IZF}}} . === Choice functions === Not even classical Z F {\displaystyle {\mathsf {ZF}}} proves each union of a countable set of two-element sets to be countable again. Indeed, models of Z F {\displaystyle {\mathsf {ZF}}} have been defined that negate the countability of such a countable union of pairs. Assuming countable choice rules out that model as an interpretation of the resulting theory. This principle is still independent of Z F {\displaystyle {\mathsf {ZF}}} - A naive proof strategy for that statement fails at the accounting of infinitely many existential instantiations. A choice principle postulates that certain selections can always be made in a joint fashion in the sense that they are also manifested as a single set function in the theory. As with any independent axiom, this raises the proving capabilities while restricting the scope of possible (model-theoretic) interpretations of the (syntactic) theory. A function existence claim can often be translated to the existence of inverses, orderings, and so on. Choice moreover implies statements about cardinalities of different sets, e.g. they imply or rule out countability of sets. Adding full choice to Z F {\displaystyle {\mathsf {ZF}}} does not prove any new Π 4 1 {\displaystyle \Pi _{4}^{1}} -theorems, but it is strictly non-constructive, as shown below. The development here proceeds in a fashion agnostic to any of the variants described next. Axiom of countable choice A C ω {\displaystyle {\mathrm {AC} _{\omega }}} (or C C {\displaystyle {\mathrm {CC} }} ): If g : ω → z {\displaystyle g\colon \omega \to z} , one can form the one-to-many relation-set { ⟨ n , u ⟩ ∣ n ∈ ω ∧ u ∈ g ( n ) } {\displaystyle \{\langle n,u\rangle \mid n\in \omega \land u\in g(n)\}} . The axiom of countable choice would grant that whenever ∀ ( n ∈ ω ) . ∃ u . u ∈ g ( n ) {\displaystyle \forall (n\in \omega ).\exists u.u\in g(n)} , one can form a function mapping each number to a unique value. The existence of such sequences is not generally provable on the base of Z F {\displaystyle {\mathsf {ZF}}} and countable choice is not Σ 4 1 {\displaystyle \Sigma _{4}^{1}} -conservative over that theory. Countable choice into general sets can also be weakened further. One common consideration is to restrict the possible cardinalities of the range of g {\displaystyle g} , giving the weak countable choice into countable, finite or even just binary sets ( A C ω , 2 {\displaystyle {\mathrm {AC} _{\omega ,2}}} ). One may consider the version of countable choice for functions into ω {\displaystyle \omega } (called A C ω , ω {\displaystyle {\mathrm {AC} _{\omega ,\omega }}} or A C 00 {\displaystyle {\mathrm {AC} _{00}}} ), as is implied by the constructive Church's thesis principle, i.e. by postulating that all total arithmetical relations are recursive. C T 0 {\displaystyle {\mathrm {CT} _{0}}} in arithmetic may be understood as a form of choice axiom. Another means of weakening countable choice is by restricting the involved definitions w.r.t. their place in the syntactic hierarchies (say Π 1 0 {\displaystyle \Pi _{1}^{0}} - A C ω , 2 {\displaystyle {\mathrm {AC} _{\omega ,2}}} ). The weak Kőnig's lemma W K L {\displaystyle {\mathrm {WKL} }} , which breaks strictly recursive mathematics as further discussed below, is stronger than Π 1 0 {\displaystyle \Pi _{1}^{0}} - A C ω , 2 {\displaystyle {\mathrm {AC} _{\omega ,2}}} and is itself sometimes viewed as capturing a form of countable choice. In the presence of a weak form of countable choice, the lemma becomes equivalent to the non-constructive principle of more logical flavor, L L P O {\displaystyle {\mathrm {LLPO} }} . Constructively, a weak form of choice is required for well-behaved Cauchy reals. Countable choice is not valid in the internal logic of a general topos, which can be seen as models of constructive set theories. Axiom of dependent choice D C {\displaystyle {\mathrm {DC} }} : Countable choice is implied by the more general axiom of dependent choice, extracting a sequence in an inhabited z {\displaystyle z} , given any entire relation R ⊂ z × z {\displaystyle R\subset z\times z} . In set theory, this sequence is again an infinite set of pairs, a subset of ω × z {\displaystyle \omega \times z} . So one is granted to pass from several existence statements to function existence, itself granting unique-existence statements, for every natural. An appropriate formulation of dependent choice is adopted in several constructive frameworks, e.g., by some schools that understand unending sequences as ongoing constructions instead of completed objects. At least those cases seem benign where, for any x ∈ z {\displaystyle x\in z} , next value existence ∃ ( y ∈ z ) . x R y {\displaystyle \exists (y\in z).xRy} can be validated in a computable fashion. The corresponding recursive function ω → z {\displaystyle \omega \to z} , if it exists, is then conceptualized as being able to return a value at infinitely many potential inputs n ∈ ω {\displaystyle n\in \omega } , but these do not have to be evaluated all together at once. It also holds in many realizability models. In the condition of the formally similar recursion theorem, one is already given a unique choice at each step, and that theorem lets one combine them to a function on ω {\displaystyle \omega } . So also with D C {\displaystyle {\mathrm {DC} }} one may consider forms of the axiom with restrictions on R {\displaystyle R} . Via the bounded separation axiom in E C S T {\displaystyle {\mathsf {ECST}}} , the principle also is equivalent to a schema in two bounded predicate variables: Keeping all quantifiers ranging over z {\displaystyle z} , one may further narrow this set domain using a unary Δ 0 {\displaystyle \Delta _{0}} -predicate variable, while also using any 2-ary Δ 0 {\displaystyle \Delta _{0}} -predicate instead of the relation set R {\displaystyle R} . Dependent choice does not imply that subsingleton domains have a choice function. Relativized dependent choice R D C {\displaystyle {\mathrm {RDC} }} : This is the schema just using two general classes, instead of requiring z {\displaystyle z} and R {\displaystyle R} be sets. The domain of the choice function granted to exist is still just ω {\displaystyle \omega } . Over E C S T {\displaystyle {\mathsf {ECST}}} , it implies full mathematical induction, which, in turn allows for function definition on ω {\displaystyle \omega } through the recursion schema. When R D C {\displaystyle {\mathrm {RDC} }} is restricted to Δ 0 {\displaystyle \Delta _{0}} -definitions, it still implies mathematical induction for Σ 1 {\displaystyle \Sigma _{1}} -predicates (with an existential quantifier over sets) as well as D C {\displaystyle {\mathrm {DC} }} . In Z F {\displaystyle {\mathsf {ZF}}} , the schema R D C {\displaystyle {\mathrm {RDC} }} is equivalent to D C {\displaystyle {\mathrm {DC} }} . Π Σ {\displaystyle \Pi \Sigma } - A C {\displaystyle \mathrm {AC} } : A family of sets is better controllable if it comes indexed by a function. A set b {\displaystyle b} is a base if all indexed families of sets i s : b → s {\displaystyle i_{s}\colon b\to s} over it, have a choice function f s {\displaystyle f_{s}} , i.e. ∀ ( x ∈ b ) . f s ( x ) ∈ i s ( x ) {\displaystyle \forall (x\in b).f_{s}(x)\in i_{s}(x)} . A collection of sets holding ω {\displaystyle \omega } and its elements and which is closed by taking indexed sums and products (see dependent type) is called Π Σ {\displaystyle \Pi \Sigma } -closed. While the axiom that all sets in the smallest Π Σ {\displaystyle \Pi \Sigma } -closed class are a base does need some work to formulate, it is the strongest choice principle over C Z F {\displaystyle {\mathsf {CZF}}} that holds in the type theoretical interpretation M L 1 V {\displaystyle {\mathsf {ML_{1}V}}} . Axiom of choice A C {\displaystyle {\mathrm {AC} }} : This is the "full" choice function postulate concerning domains that are general sets { z , … } {\displaystyle \{z,\dots \}} containing inhabited sets, with the codomain given as their general union. Given a collection of sets such that the logic allows to make a choice in each, the axiom grants that there exists a set function that jointly captures a choice in all. It is typically formulated for all sets but has also been studied in classical formulations for sets only up to any particular cardinality. A standard example is choice in all inhabited subsets of the reals, which classically equals the domain P R ∖ 1 {\displaystyle {\mathcal {P}}_{\mathbb {R} }\setminus 1} . For this collection there can be no uniform element selection prescription that provably constitutes a choice function on the base of Z F {\displaystyle {\mathsf {ZF}}} . Also, when restricted to the Borel algebra of the reals, Z F {\displaystyle {\mathsf {ZF}}} alone does not prove the existence of a function selecting a member from each non-empty such Lebesgue-measurable subset. (The set B ( R ) {\displaystyle {\mathcal {B}}({\mathbb {R} })} is the σ-algebra generated by the intervals I := { ( x , y ] ∣ x , y ∈ R } {\displaystyle I:=\{(x,y\,]\mid x,y\in {\mathbb {R} }\}} . It strictly includes those intervals, in the sense of I ⊊ B ( R ) ⊊ P R {\displaystyle I\subsetneq {\mathcal {B}}({\mathbb {R} })\subsetneq {\mathcal {P}}_{\mathbb {R} }} , but in Z F {\displaystyle {\mathsf {ZF}}} also only has the cardinality of the reals itself.) Striking existence claims implied by the axiom are abound. E C S T {\displaystyle {\mathsf {ECST}}} proves ω {\displaystyle \omega } exists and then the axiom of choice also implies dependent choice. Critically in the present context, it moreover also implies instances of P E M {\displaystyle {\mathrm {PEM} }} via Diaconescu's theorem. For E C S T {\displaystyle {\mathsf {ECST}}} or theories extending it, this means full choice at the very least proves P E M {\displaystyle {\mathrm {PEM} }} for all Δ 0 {\displaystyle \Delta _{0}} -formulas, a non-constructive consequence not acceptable, for example, from a computability standpoint. Note that constructively, Zorn's lemma does not imply choice: When membership in function domains fails to be decidable, the extremal function granted by that principle is not provably always a choice function on the whole domain. ==== Diaconescu's theorem ==== To highlight the strength of full Choice and its relation to matters of intentionality, one should consider the classes a = { u ∈ { 0 , 1 } ∣ ( u = 0 ) ∨ P } {\displaystyle a=\{u\in \{0,1\}\mid (u=0)\lor P\}} b = { u ∈ { 0 , 1 } ∣ ( u = 1 ) ∨ P } {\displaystyle b=\{u\in \{0,1\}\mid (u=1)\lor P\}} from the proof of Diaconescu's theorem. They are as contingent as the proposition P {\displaystyle P} involved in their definition and they are not proven finite. Nonetheless, the setup entails several consequences. Referring back to the introductory elaboration on the meaning of such convenient class notation, as well as to the principle of distributivity, t ∈ a ↔ ( t = 0 ∨ ( t = 1 ∧ P ) ) {\displaystyle t\in a\leftrightarrow {\big (}t=0\lor (t=1\land P){\big )}} . So unconditionally, 0 ∈ a {\displaystyle 0\in a} as well as 1 ∈ b {\displaystyle 1\in b} , and in particular they are inhabited. As ¬ ( 0 = 1 ) {\displaystyle \neg (0=1)} in any model of Heyting arithmetic, using the disjunctive syllogism both 0 ∈ b {\displaystyle 0\in b} and 1 ∈ a {\displaystyle 1\in a} each imply P {\displaystyle P} . The two statements are indeed equivalent to the proposition, as clearly P → ( a = { 0 , 1 } ∧ b = { 0 , 1 } ) {\displaystyle P\to (a=\{0,1\}\land b=\{0,1\})} . The latter also says that validity of P {\displaystyle P} means a {\displaystyle a} and b {\displaystyle b} share all members, and there are two of these. As a {\displaystyle a} are b {\displaystyle b} are then sets, also P → ( a = b ∧ { a , b } = { a } ) {\displaystyle P\to (a=b\land \{a,b\}=\{a\})} by extensionality. Conversely, assuming they are equal means x ∈ a ↔ x ∈ b {\displaystyle x\in a\leftrightarrow x\in b} for any x {\displaystyle x} , validating all membership statements. So both the membership statements as well as the equalities are found to be equivalent to P {\displaystyle P} . Using the contrapositive results in the weaker equivalence of disjuncts ( P ∨ ¬ P ) ↔ ( a = b ∨ ¬ ( a = b ) ) {\displaystyle (P\lor \neg P)\leftrightarrow (a=b\lor \neg (a=b))} . Of course, explicitly ¬ P → ( a = { 0 } ∧ b = { 1 } ) {\displaystyle \neg P\to (a=\{0\}\land b=\{1\})} and so one actually finds in which way the sets can end up being different. As functions preserves equality by definition, ¬ ( g ( a ) = g ( b ) ) → ¬ P {\displaystyle \neg {\big (}g(a)=g(b){\big )}\to \neg P} indeed holds for any g {\displaystyle g} with domain { a , b } {\displaystyle \{a,b\}} . In the following assume a context in which a , b {\displaystyle a,b} are indeed established to be sets, and thus subfinite sets. The general axiom of choice claims existence of a function f : { a , b } → a ∪ b {\displaystyle f\colon \{a,b\}\to a\cup b} with f ( z ) ∈ z {\displaystyle f(z)\in z} . It is important that the elements a , b {\displaystyle a,b} of the function's domain are different than the natural numbers 0 , 1 {\displaystyle 0,1} in the sense that a priori less is known about the former. When forming then union of the two classes, u = 0 ∨ u = 1 {\displaystyle u=0\lor u=1} is a necessary but then also sufficient condition. Thus a ∪ b = { 0 , 1 } {\displaystyle a\cup b=\{0,1\}} and one is dealing with functions f {\displaystyle f} into a set of two distinguishable values. With choice come the conjunction f ( a ) ∈ a ∧ f ( b ) ∈ b {\displaystyle f(a)\in a\land f(b)\in b} in the codomain of the function, but the possible function return values are known to be just 0 {\displaystyle 0} or 1 {\displaystyle 1} . Using the distributivity, there arises a list of conditions, another disjunction. Expanding what is then established, one finds that either both P {\displaystyle P} as well as the sets equality holds, or that the return values are different and P {\displaystyle P} can be rejected. The conclusion is that the choice postulate actually implies P ∨ ¬ P {\displaystyle P\lor \neg P} whenever a Separation axiom allows for set comprehension using undecidable proposition P {\displaystyle P} . ==== Analysis of Diaconescu's theorem ==== So full choice is non-constructive in set theory as defined here. The issue is that when propositions are part of set comprehension (like when P {\displaystyle P} is used to separate, and thereby define, the classes a {\displaystyle a} and b {\displaystyle b} from { 0 , 1 } {\displaystyle \{0,1\}} ), the notion of their truth values are ramified into set terms of the theory. Equality defined by the set theoretical axiom of extensionality, which itself is not related to functions, in turn couples knowledge about the proposition to information about function values. To recapitulate the final step in terms function values: On the one hand, witnessing f ( a ) = 1 {\displaystyle f(a)=1} implies P {\displaystyle P} and a = b {\displaystyle a=b} and this conclusion independently also applies to witnessing f ( b ) = 0 {\displaystyle f(b)=0} . On the other hand, witnessing f ( a ) = 0 ∧ f ( b ) = 1 {\displaystyle f(a)=0\land f(b)=1} implies the two function arguments are not equal and this rules out P {\displaystyle P} . There are really only three combinations, as the axiom of extensionality in the given setup makes f ( a ) = 1 ∧ f ( b ) = 0 {\displaystyle f(a)=1\land f(b)=0} inconsistent. So if the constructive reading of existence is to be preserved, full choice may be not adopted in the set theory, because the mere claim of function existence does not realize a particular function. To better understand why one cannot expect to be granted a definitive (total) choice function with domain { a , b } {\displaystyle \{a,b\}} , consider naive function candidates. Firstly, an analysis of the domain is in order. The surjection { ⟨ 0 , a ⟩ , ⟨ 1 , b ⟩ } {\displaystyle \{\langle 0,a\rangle ,\langle 1,b\rangle \}} witnesses that { a , b } {\displaystyle \{a,b\}} is finitely indexed. It was noted that its members are subfinite and also inhabited, since regardless of P {\displaystyle P} it is the case that 0 ∈ a {\displaystyle 0\in a} and 1 ∈ b {\displaystyle 1\in b} . So naively, this would seem to make f = { ⟨ a , 0 ⟩ , ⟨ b , 1 ⟩ } {\displaystyle f=\{\langle a,0\rangle ,\langle b,1\rangle \}} a contender for a choice function. When P {\displaystyle P} can be rejected, then this is indeed the only option. But in the case of provability of P {\displaystyle P} , when { a , b } = { a } {\displaystyle \{a,b\}=\{a\}} , there is extensionally only one possible function input to a choice function. So in that situation, a choice function would explicitly have type f : { a } → { 0 , 1 } {\displaystyle f\colon \{a\}\to \{0,1\}} , for example f = { ⟨ a , 0 ⟩ } {\displaystyle f=\{\langle a,0\rangle \}} and this would rule out the initial contender. For general P {\displaystyle P} , the domain of a would-be choice function is not concrete but contingent on P {\displaystyle P} and not proven finite. When considering the above functional assignment f ( a ) = 0 {\displaystyle f(a)=0} , then neither unconditionally declaring f ( b ) = 1 {\displaystyle f(b)=1} nor f ( b ) = 0 {\displaystyle f(b)=0} is necessarily consistent. Having identified 1 {\displaystyle 1} with { 0 } {\displaystyle \{0\}} , the two candidates described above can be represented simultaneously via f = { ⟨ a , 0 ⟩ , ⟨ b , B ¬ ⟩ } {\displaystyle f=\{\langle a,0\rangle ,\langle b,B_{\neg }\rangle \}} (which is not proven finite either) with the subfinite "truth value of ¬ P {\displaystyle \neg P} " given as B ¬ := { u ∈ { 0 } ∣ ¬ P } {\displaystyle B_{\neg }:=\{u\in \{0\}\mid \neg P\}} . As ( P → ( B ¬ = 0 ) ) ∧ ( ¬ P → ( B ¬ = 1 ) ) {\displaystyle (P\to (B_{\neg }=0))\land (\neg P\to (B_{\neg }=1))} , postulating P {\displaystyle P} , or ¬ P {\displaystyle \neg P} , or the classical principle P ∨ ¬ P {\displaystyle P\lor \neg P} here would indeed imply that B ¬ {\displaystyle B_{\neg }} is a natural, so that the latter set f {\displaystyle f} constitutes a choice function into { 0 , 1 } {\displaystyle \{0,1\}} . And as in the constructive case, given a particular choice function - a set holding either exactly one or exactly two pairs - one could actually infer whether P {\displaystyle P} or whether ¬ P {\displaystyle \neg P} does hold. Vice versa, the third and last candidate f = { ⟨ b , 1 ⟩ } {\displaystyle f=\{\langle b,1\rangle \}} can be captured as part of f = { ⟨ a , B ⟩ , ⟨ b , 1 ⟩ } {\displaystyle f=\{\langle a,B\rangle ,\langle b,1\rangle \}} , where B := { u ∈ { 0 } ∣ P } {\displaystyle B:=\{u\in \{0\}\mid P\}} . Such a B {\displaystyle B} had already been considered in the early section on the axiom of separation. Again, the latter f {\displaystyle f} here is a classical choice function either way also, where P {\displaystyle P} functions as a (potentially undecidable) "if-clause". Constructively, the domain and values of such P {\displaystyle P} -dependent would-be functions are not understood enough to prove them to be a total functional relation into { 0 , 1 } {\displaystyle \{0,1\}} . For computable semantics, set theory axioms postulating (total) function existence lead to the requirement for halting recursive functions. From their function graph in individual interpretations, one can infer the branches taken by the "if-clauses" that were undecided in the interpreted theory. But on the level of the synthetic frameworks, when they broadly become classical from adopting full choice, these extensional set theories theories contradict the constructive Church's rule. ==== Regularity implies PEM ==== The axiom of choice grants existence a function associated with every set-sized collection of inhabited elements s {\displaystyle s} , with which one can then at once pick unique elements t {\displaystyle t} . The axiom of regularity states that for every inhabited set s {\displaystyle s} in the universal collection, there exists an element t {\displaystyle t} in s {\displaystyle s} , which shares no elements with s {\displaystyle s} . This formulation does not involve functions or unique existence claims, but instead directly guarantees sets t ∈ s {\displaystyle t\in s} with a specific property. As the axiom correlates membership claims at different rank, the axiom also ends up implying P E M {\displaystyle {\mathrm {PEM} }} : The proof from Choice above had used 1 := { 0 } {\displaystyle 1:=\{0\}} and a particular set { a , b } {\displaystyle \{a,b\}} . The proof in this paragraph also assumes Separation applies to P {\displaystyle P} and uses b {\displaystyle b} , for which { 0 } ∈ b {\displaystyle \{0\}\in b} by definition. It was already explained that P ↔ 0 ∈ b {\displaystyle P\leftrightarrow 0\in b} and so one may prove excluded middle for P {\displaystyle P} in the form 0 ∈ b ∨ 0 ∉ b {\displaystyle 0\in b\lor 0\notin b} . Now let t ∈ b {\displaystyle t\in b} be the postulated member with the empty intersection property. The set b {\displaystyle b} was defined as a subset of { 0 , 1 } {\displaystyle \{0,1\}} and so any given t ∈ b {\displaystyle t\in b} fulfills the disjunction t = 0 ∨ t = 1 {\displaystyle t=0\lor t=1} . The left clause t = 0 {\displaystyle t=0} implies 0 ∈ b {\displaystyle 0\in b} , while for the right clause t = 1 {\displaystyle t=1} one may use that the special non-intersecting element t {\displaystyle t} fulfills ( t = { 0 } ) ↔ ( 0 ∉ b ) {\displaystyle (t=\{0\})\leftrightarrow (0\notin b)} . Demanding that the set of naturals is well-ordered with respect to it standard order relation imposes the same condition on the inhabited set b ⊂ ω {\displaystyle b\subset \omega } . So the least number principle has the same non-constructive implication. As with the proof from Choice, the scope of propositions for which these results hold is governed by one's Separation axiom. === Arithmetic === The four Peano axioms for 0 {\displaystyle 0} and S {\displaystyle S} , characterizing the set ω {\displaystyle \omega } as a model of the natural numbers in the constructive set theory E C S T {\displaystyle {\mathsf {ECST}}} , have been discussed. The order " < {\displaystyle <} " of natural numbers is captured by membership " ∈ {\displaystyle \in } " in this von Neumann model and this set is discrete, i.e. also ϕ ( n , m ) := ( n = m ) {\displaystyle \phi (n,m):=(n=m)} is decidable. As discussed, induction for arithmetic formulas is a theorem. However, when not assuming full mathematical induction (or stronger axioms like full Separation) in a set theory, there is a pitfall regarding the existence of arithmetic operations. The first-order theory of Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} has the same signature and non-logical axioms as Peano arithmetic P A {\displaystyle {\mathsf {PA}}} . In contrast, the signature of set theory does not contain addition " + {\displaystyle +} " or multiplication " × {\displaystyle \times } ". E C S T {\displaystyle {\mathsf {ECST}}} does actually not enable primitive recursion in ω {\displaystyle \omega } for function definitions of what would be h : ( x × ω ) → y {\displaystyle h\colon (x\times \omega )\to y} (where " × {\displaystyle \times } " here denotes the Cartesian product of set, not to be confused with multiplication above). Indeed, despite having the Replacement axiom, the theory does not prove there to be a set capturing the addition function + : ( ω × ω ) → ω {\displaystyle +\colon (\omega \times \omega )\to \omega } . In the next section, it is clarified which set theoretical axiom may be asserted to prove existence of the latter as a function set, together with their desired relation to zero and successor. Far beyond just the equality predicate, the obtained model of arithmetic then validates H A ⊢ ∀ n . ∀ m . ( ϕ ( n , m ) ∨ ¬ ϕ ( n , m ) ) {\displaystyle {\mathsf {HA}}\vdash \forall n.\forall m.{\big (}\phi (n,m)\lor \neg \phi (n,m){\big )}} for any quantifier-free formula. Indeed, P A {\displaystyle {\mathsf {PA}}} is Π 2 0 {\displaystyle \Pi _{2}^{0}} -conservative over H A {\displaystyle {\mathsf {HA}}} and double-negation elimination is possible for any Harrop formula. ==== Arithmetic functions from recursion ==== Going a step beyond E C S T {\displaystyle {\mathsf {ECST}}} , the axiom granting definition of set functions via iteration-step set functions must be added: For any set y {\displaystyle y} , set z ∈ y {\displaystyle z\in y} and f : y → y {\displaystyle f\colon y\to y} , there must also exist a function g : ω → y {\displaystyle g\colon \omega \to y} attained by making use of the former, namely such that g ( 0 ) = z {\displaystyle g(0)=z} and g ( S n ) = f ( g ( n ) ) {\displaystyle g(Sn)=f(g(n))} . This iteration- or recursion principle is akin to the transfinite recursion theorem, except it is restricted to set functions and finite ordinal arguments, i.e. there is no clause about limit ordinals. It functions as the set theoretical equivalent of a natural numbers object in category theory. This then enables a full interpretation of Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} in our set theory, including addition and multiplication functions. With this, N {\displaystyle {\mathbb {N} }} and Z {\displaystyle {\mathbb {Z} }} are well-founded, in the sense of the inductive subsets formulation. Further, arithmetic of rational numbers Q {\displaystyle {\mathbb {Q} }} can then also be defined and its properties, like uniqueness and countability, be proven. ==== Recursion from set theory axioms ==== Recall that h ≃ y x {\displaystyle h\simeq y^{x}} is short for ∀ f . ( f ∈ h ↔ f ∈ y x ) {\displaystyle \forall f.{\big (}f\in h\leftrightarrow f\in y^{x}{\big )}} , where f ∈ y x {\displaystyle f\in y^{x}} is short for the total function predicate, a proposition in terms of uses bounded quantifiers. If both sides are sets, then by extensionality this is also equivalent to h = y x {\displaystyle h=y^{x}} . (Although by slight abuse of formal notation, as with the symbol " ∈ {\displaystyle \in } ", the symbol " = {\displaystyle =} " is also commonly used with classes anyhow.) A set theory with the H A {\displaystyle {\mathsf {HA}}} -model enabling recursion principle, spelled out above, will also prove that, for all naturals n {\displaystyle n} and m {\displaystyle m} , the function spaces { 0 , 1 , … , n − 1 } → { 0 , 1 , … , m − 1 } {\displaystyle {\{0,1,\dots ,n-1\}}\to {\{0,1,\dots ,m-1\}}} are sets. Indeed, bounded recursion suffices, i.e. the principle for Δ 0 {\displaystyle \Delta _{0}} -defined classes. Conversely, the recursion principle can be proven from a definition involving the union of recursive functions on finite domains. Relevant for this is the class of partial functions on ω {\displaystyle \omega } such that all of its members have a return values only up to some natural number bound, which may be expressed by ∪ n ∈ ω y { 0 , 1 , … , n − 1 } {\displaystyle \cup _{n\in \omega }y^{\{0,1,\dots ,n-1\}}} . Existence of this as a set becomes provable assuming that the individual function spaces y n {\displaystyle y^{n}} all form sets themselves. To this end With this axiom, any such space is now a set of subsets of n × y {\displaystyle n\times y} and this is strictly weaker than full Separation. Notably, adoption of this principle has genuine set theoretical flavor, in contrast to a direct embedding of arithmetic principles into our theory. And it is a modest principle insofar as these function spaces are tame: When instead assuming full induction or full exponentiation, taking y {\displaystyle y} to function spaces y n {\displaystyle y^{n}} , or to n-fold Cartesian products, provably does preserve countability. In E C T S {\displaystyle {\mathsf {ECTS}}} plus finite exponentiation, the recursion principle is a theorem. Moreover, enumerable forms of the pigeon hole principle can now also be proven, e.g. that on a finitely indexed set, every auto-injection is also a surjection. As a consequence, the cardinality of finite sets, i.e. the finite von Neumann ordinal, is provably unique. The finitely indexed discrete sets are just the finite sets. In particular, finitely indexed subsets of ω {\displaystyle \omega } are finite. Taking quotients or taking the binary union or Cartesian product of two sets preserve finiteness, sub-finiteness and being finitely indexed. The set theory axioms listed so far incorporates first-order arithemtic and suffices as formalized framework for a good portion of common mathematics. The restriction to finite domains is lifted in the strictly stronger exponentiation axiom below. However, also that axiom does not entail the full induction schema for formulas with unbound quantifiers over the domain of sets, nor a dependent choice principle. Likewise, there are Collection principles that are constructively not implied by Replacement, as discussed further below. A consequence of this is that for some statements of higher complexity or indirection, even if concrete instances of interest may well be provable, the theory may not prove the universal closure. Stronger than this theory with finite exponentiation is E C T S {\displaystyle {\mathsf {ECTS}}} plus full induction. It implies the recursion principle even for classes and such that g {\displaystyle g} is unique. Already that recursion principle when restricted to Δ 0 {\displaystyle \Delta _{0}} does prove finite exponentiation, and also the existence of a transitive closure for every set with respect to ∈ {\displaystyle \in } (since union formation is Δ 0 {\displaystyle \Delta _{0}} ). With it more common constructions preserve countability. General unions over a finitely indexed set of finitely indexed sets are again finitely indexed, when at least assuming induction for Σ 1 {\displaystyle \Sigma _{1}} -predicates (with respect to the set theory language, and this then holds regardless of the decidability of their equality relations.) ==== Induction without infinite sets ==== Before discussing even classically uncountable sets, this last section takes a step back to a context more akin to B C S T {\displaystyle {\mathsf {BCST}}} . The addition of numbers, considered as relation on triples, is an infinite collection, just like collection of natural numbers themselves. But note that induction schemas may be adopted (for sets, ordinals or in conjunction with a natural number sort), without ever postulating that the collection of naturals exists as a set. As noted, Heyting arithmetic H A {\displaystyle {\mathsf {HA}}} is bi-interpretable with such a constructive set theory, in which all sets are postulated to be in bijection with an ordinal. The BIT predicate is a common means to encode sets in arithmetic. This paragraph lists a few weak natural number induction principles studied in the proof theory of arithmetic theories with addition and multiplication in their signature. This is the framework where these principles are most well understood. The theories may be defined via bounded formulations or variations on induction schemas that may furthermore only allow for predicates of restricted complexity. On the classical first-order side, this leads to theories between the Robinson arithmetic Q {\displaystyle {\mathsf {Q}}} and Peano arithmetic P A {\displaystyle {\mathsf {PA}}} : The theory Q {\displaystyle {\mathsf {Q}}} does not have any induction. P A {\displaystyle {\mathsf {PA}}} has full mathematical induction for arithmetical formulas and has ordinal ε 0 {\displaystyle \varepsilon _{0}} , meaning the theory lets one encode ordinals of weaker theories as recursive relation on just the naturals. Theories may also include additional symbols for particular functions. Many of the well studied arithmetic theories are weak regarding proof of totality for some more fast growing functions. Some of the most basic examples of arithmetics include elementary function arithmetic E F A {\displaystyle {\mathsf {EFA}}} , which includes induction for just bounded arithmetical formulas, here meaning with quantifiers over finite number ranges. The theory has a proof theoretic ordinal (the least not provenly recursive well-ordering) of ω 3 {\displaystyle \omega ^{3}} . The Σ 1 0 {\displaystyle \Sigma _{1}^{0}} -induction schema for arithmetical existential formulas allows for induction for those properties of naturals a validation of which is computable via a finite search with unbound (any, but finite) runtime. The schema is also classically equivalent to the Π 1 0 {\displaystyle \Pi _{1}^{0}} -induction schema. The relatively weak classical first-order arithmetic which adopts that schema is denoted I Σ 1 {\displaystyle {\mathsf {I\Sigma }}_{1}} and proves the primitive recursive functions total. The theory I Σ 1 {\displaystyle {\mathsf {I\Sigma }}_{1}} is Π 2 0 {\displaystyle \Pi _{2}^{0}} -conservative over primitive recursive arithmetic P R A {\displaystyle {\mathsf {PRA}}} . Note that the Σ 1 0 {\displaystyle \Sigma _{1}^{0}} -induction is also part of the second-order reverse mathematics base system R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} , its other axioms being Q {\displaystyle {\mathsf {Q}}} plus Δ 1 0 {\displaystyle \Delta _{1}^{0}} -comprehension of subsets of naturals. The theory R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} is Π 1 1 {\displaystyle \Pi _{1}^{1}} -conservative over I Σ 1 {\displaystyle {\mathsf {I\Sigma }}_{1}} . Those last mentioned arithmetic theories all have ordinal ω ω {\displaystyle \omega ^{\omega }} . Let us mention one more step beyond the Σ 1 0 {\displaystyle \Sigma _{1}^{0}} -induction schema. Lack of stronger induction schemas means, for example, that some unbounded versions of the pigeon hole principle are unprovable. One relatively weak one being the Ramsey theorem type claim here expressed as follows: For any m > 0 {\displaystyle m>0} and coding of a coloring map f {\displaystyle f} , associating each n ∈ ω {\displaystyle n\in \omega } with a color { 0 , 1 , … , m − 1 } {\displaystyle \{0,1,\dots ,m-1\}} , it is not the case that for every color c < m {\displaystyle c<m} there exists a threshold input number n c {\displaystyle n_{c}} beyond which c {\displaystyle c} is not ever the mappings return value anymore. (In the classical context and in terms of sets, this claim about coloring may be phrased positively, as saying that there always exists at least one return value k {\displaystyle k} such that, in effect, for some unbounded domain K ⊂ ω {\displaystyle K\subset \omega } it holds that ∀ ( n ∈ K ) . f ( n ) = k {\displaystyle \forall (n\in K).f(n)=k} . In words, when f {\displaystyle f} provides infinite enumerated assignments, each being of one of m {\displaystyle m} different possible colors, it is claimed that a particular k {\displaystyle k} coloring infinitely many numbers always exists and that the set can thus be specified, without even having to inspect properties of f {\displaystyle f} . When read constructively, one would want k {\displaystyle k} to be concretely specifiable and so that formulation is a stronger claim.) Higher indirection, than in induction for mere existential statements, is needed to formally reformulate such a negation (the Ramsey theorem type claim in the original formulation above) and prove it. Namely to restate the problem in terms of the negation of the existence of one joint threshold number, depending on all the hypothetical n c {\displaystyle n_{c}} 's, beyond which the function would still have to attain some color value. More specifically, the strength of the required bounding principle is strictly between the induction schema in I Σ 1 0 {\displaystyle {\mathsf {I\Sigma }}_{1}^{0}} and I Σ 2 0 {\displaystyle {\mathsf {I\Sigma }}_{2}^{0}} . For properties in terms of return values of functions on finite domains, brute force verification through checking all possible inputs has computational overhead which is larger for larger domains, but always finite. Acceptance of an induction schema as in I Σ 2 0 {\displaystyle {\mathsf {I\Sigma }}_{2}^{0}} validates the former so called infinite pigeon hole principle, which concerns unbounded domains, and so is about mappings with infinitely many inputs. It is worth noting that in the program of predicative arithmetic, even the mathematical induction schema has been criticized as possibly being impredicative, when natural numbers are defined as the object which fulfill this schema, which itself is defined in terms of all naturals. === Exponentiation === Classical Z F C {\displaystyle {\mathsf {ZFC}}} without the Powerset axiom has natural models in classes of sets of hereditary size less than certain uncountable cardinals. In particular, it is still consistent with all existing sets (including sets holding reals) being subcountable, and there even countable. Such a theory essentially amounts to second-order arithmetic. All sets being subcountable can constructively be consistent even in the present of uncountable sets, as introduced now. Possible choice principles were discussed, a weakened form of the Separation schema was already adopted, and more of the standard Z F C {\displaystyle {\mathsf {ZFC}}} axioms shall be weakened for a more predicative and constructive theory. The first one of those is the Powerset axiom, which is adopted in the form of the space of characteristic functions. The following axiom E x p {\displaystyle {\mathrm {Exp} }} is strictly stronger than its pendant for finite domains discussed above: The formulation here again uses the convenient notation for function spaces, as discussed above. In words, the axiom says that given two sets x , y {\displaystyle x,y} , the class y x {\displaystyle y^{x}} of all functions is, in fact, also a set. This is certainly required, for example, to formalize the object map of an internal hom-functor like h o m ( N , − ) . {\displaystyle {\mathrm {hom} }({\mathbb {N} },-).} Adopting such an existence statement also the quantification ∀ f {\displaystyle \forall f} over the elements of certain classes of (total) functions now only range over sets. Consider the collection of pairs ⟨ a , b ⟩ ∈ x × x {\displaystyle \langle a,b\rangle \in x\times x} validating the apartness relation ∃ ( f ∈ N x ) . f ( a ) ≠ f ( b ) {\displaystyle \exists (f\in {\mathbb {N} }^{x}).f(a)\neq f(b)} . Via bounded Separation, this now constitutes a subset of x × x {\displaystyle x\times x} . This examples shows that the Exponentiation axiom not only enriches the domain of sets directly, but via separation also enables the derivation of yet more sets, and this then furthermore also strengthens other axioms. Notably, these bounded quantifiers now range over function spaces that are provably uncountable, and hence even classically uncountable. E.g. the collection of all functions f : ω → 2 {\displaystyle f\colon \omega \to 2} where 2 := S S 0 = { 0 , 1 } {\displaystyle 2:=SS0=\{0,1\}} , i.e. the set 2 N {\displaystyle 2^{\mathbb {N} }} of points underlying the Cantor space, is uncountable, by Cantor's diagonal argument, and can at best be taken to be a subcountable set. In this theory one may now also quantify over subspaces of spaces like 2 N {\displaystyle 2^{\mathbb {N} }} , which is a third order notion on the naturals. (In this section and beyond, the symbol for the semiring of natural numbers in expressions like y N {\displaystyle y^{\mathbb {N} }} is used, or written ω → y {\displaystyle \omega \to y} , just to avoid conflation of cardinal- with ordinal exponentiation.) Roughly, classically uncountable sets, like for example these function spaces, tend to not have computably decidable equality. By taking the general union over an x {\displaystyle x} -indexed family { y i } i {\displaystyle \{y_{i}\}_{i}} , also the dependent or indexed product, written Π i ∈ x y i {\displaystyle \Pi _{i\in x}\,y_{i}} , is now a set. For constant y i {\displaystyle y_{i}} , this again reduces to the function space y x {\displaystyle y^{x}} . And taking the general union over function spaces themselves, whenever the powerclass of x {\displaystyle x} is a set, then also the superset ∪ s ⊂ x y s {\displaystyle \cup _{s\subset x}y^{s}} of y x {\displaystyle y^{x}} is now a set - giving a means to talk about the space of partial functions on x {\displaystyle x} . ==== Unions and countability ==== With Exponentiation, the theory proves the existence of any primitive recursive function in x × ω → y {\displaystyle x\times \omega \to y} , and in particular in the uncountable function spaces out of ω {\displaystyle \omega } . Indeed, with function spaces and the finite von Neumann ordinals as domains, we can model H A {\displaystyle {\mathsf {HA}}} as discussed, and thus encode ordinals in the arithmetic. One then furthermore obtains the ordinal-exponentiated number ω ω {\displaystyle \omega ^{\omega }} as a set, which may be characterized as ∪ n ∈ ω ω n {\displaystyle \cup _{n\in \omega }\omega ^{n}} , the counted set of words over an infinite alphabet. The union of all finite sequences over a countable set is now a countable set. Further, for any countable family of counting functions together with their ranges, the theory proves the union of those ranges to be countable. In contrast, not assuming countable choice, even Z F {\displaystyle {\mathsf {ZF}}} is consistent with the uncountable set R {\displaystyle {\mathbb {R} }} being the union of a countable set of countable sets. The list here is by no means complete. Many theorems about the various function existence predicates hold, especially when assuming countable choice - which as noted is never implicitly assumed in this discussion. At last, with Exponentiation, any finitely indexed union of a family of subfinitely indexed resp. subcountable sets is itself subfinitely indexed resp. subcountable as well. The theory also proves the collection of all the countable subsets of any set x {\displaystyle x} to be a set itself. Concerning this subset of the powerclass P x {\displaystyle {\mathcal {P}}_{x}} , some natural cardinality questions can also classically only be settled with Choice, at least for uncountable x {\displaystyle x} . ==== The class of all subsets of a set ==== Given a sequence of sets, one may define new such sequences, e.g. in ⟨ a , b ⟩ ↦ ⟨ ⟨ ⟩ , ⟨ a ⟩ , ⟨ b ⟩ , ⟨ a , b ⟩ ⟩ {\displaystyle \langle a,b\rangle \mapsto \langle \langle \rangle ,\langle a\rangle ,\langle b\rangle ,\langle a,b\rangle \rangle } . But notably, in a mathematical set theory framework, the collection of all subsets of a set is defined not in a bottom-up construction from its constituents but via a comprehension over all sets in the domain of discourse. The standard, standalone characterization of the powerclass of a set x {\displaystyle x} involves unbounded universal quantification, namely ∀ u . ( u ∈ P x ↔ u ⊂ x ) {\displaystyle \forall u.\left(u\in {\mathcal {P}}_{x}\leftrightarrow u\subset x\right)} , where ⊂ {\displaystyle \subset } was previously defined also in terms of the membership predicate ∈ {\displaystyle \in } . Here, a statement expressed as ∀ ( u ∈ P x ) . Q ( x ) {\displaystyle \forall (u\in {\mathcal {P}}_{x}).Q(x)} must a priori be taken for ∀ u . ( u ⊂ x → Q ( x ) ) {\displaystyle \forall u.{\big (}u\subset x\to Q(x){\big )}} and is not equivalent to a set-bounded proposition. Indeed, the statement y = P x {\displaystyle y={\mathcal {P}}_{x}} itself is Π 1 {\displaystyle \Pi _{1}} . If P x {\displaystyle {\mathcal {P}}_{x}} is a set, then the defining quantification even ranges across P x {\displaystyle {\mathcal {P}}_{x}} , which makes the axiom of powerset impredicative. Recall that a member of the set of characteristic functions 2 x {\displaystyle 2^{x}} corresponds to a predicate that is decidable on a set x {\displaystyle x} , which it thus determines a detachable subset s ⊂ x {\displaystyle s\subset x} . In turn, the class D x ⊂ P x {\displaystyle {\mathcal {D}}_{x}\subset {\mathcal {P}}_{x}} of all detachable subsets of x {\displaystyle x} is now also a set, via Replacement. However, D x {\displaystyle {\mathcal {D}}_{x}} may fail to provably have desirable properties, e.g. being closed under unending operations such as the unions over countably infinite index sets: For a countable sequence u n ∈ D x {\displaystyle u_{n}\in {\mathcal {D}}_{x}} , the subset U := ∪ k ∈ ω u k {\displaystyle U:=\cup _{k\in \omega }u_{k}} of x {\displaystyle x} validating ( a ∈ U ) ↔ ∃ ( m ∈ ω ) . a ∈ u m {\displaystyle (a\in U)\leftrightarrow \exists (m\in \omega ).a\in u_{m}} for all a ∈ x {\displaystyle a\in x} does exist as a set. But it may fail to be detachable and is therefore then not necessarily provably itself a member of D x {\displaystyle {\mathcal {D}}_{x}} . Meanwhile, over classical logic, all subsets of a set x {\displaystyle x} are trivially detachable, meaning D x = P x {\displaystyle {\mathcal {D}}_{x}={\mathcal {P}}_{x}} and then D x {\displaystyle {\mathcal {D}}_{x}} of course holds any subset. Over classical logic, this furthermore means that Exponentiation turns the power class into a set. Translating results of set theory based mathematical theories like point-set topology or measure theory to a constructive framework is a subtle back and forth. For example, while D x {\displaystyle {\mathcal {D}}_{x}} is a field of sets, for it to form a σ-algebra per definition also requires the above mentioned closedness under unions. But while a domain of subsets may fail to exhibit such closure property constructively, classically a measure μ {\displaystyle \mu } is continuous from below and so its value on an infinite union can in any case also be expressed without reference to that set as function input, namely as lim n → ∞ {\displaystyle \lim _{n\to \infty }} of the growing sequence μ ( ∪ k ≤ n u k ) {\displaystyle \mu (\cup _{k\leq n}u_{k})} of the function's values at finite unions. Apart from the class of detachable sets, also various other subclasses of any powerclass are now provenly sets. For example, the theory also proves this for the collection of all the countable subsets of any set. The richness of the full powerclass in a theory without excluded middle can best be understood by considering small classically finite sets. For any proposition P {\displaystyle P} , consider the subclass B := { x ∈ 1 ∣ P } {\displaystyle B:=\{x\in 1\mid P\}} of 1 {\displaystyle 1} (i.e. { 0 } {\displaystyle \{0\}} or S 0 {\displaystyle S0} ). It equals B = 0 {\displaystyle B=0} when P {\displaystyle P} can be rejected and it equals B = 1 {\displaystyle B=1} (i.e. B = S 0 {\displaystyle B=S0} ), when P {\displaystyle P} can be proven. But P {\displaystyle P} may also not be decidable at all. Consider three different undecidable proposition, none of which provenly imply another. They can be used to define three subclasses of the singleton 1 {\displaystyle 1} , none of which are provenly the same. In this view, the powerclass P 1 {\displaystyle {\mathcal {P}}_{1}} of the singleton, usually denoted by Ω {\displaystyle \Omega } , is called the truth value algebra and does not necessarily provenly have only two elements. With Exponentiation, the powerclass of the singleton, P 1 {\displaystyle {\mathcal {P}}_{1}} , being a set already implies Powerset for sets in general. The proof is via replacement for the association of f ∈ P 1 x {\displaystyle f\in {{\mathcal {P}}_{1}}^{x}} to { z ∈ x ∣ 0 ∈ f ( z ) } ∈ P x {\displaystyle \{z\in x\mid 0\in f(z)\}\in {\mathcal {P}}_{x}} , and an argument why all subsets are covered. The set 2 x {\displaystyle 2^{x}} injects into the function space P 1 x {\displaystyle {{\mathcal {P}}_{1}}^{x}} also. If the theory proves B {\displaystyle B} above a set (as for example I Z F {\displaystyle {\mathsf {IZF}}} unconditionally does), then the subset b := { ⟨ 0 , B ⟩ } {\displaystyle b:=\{\langle 0,B\rangle \}} of 1 × P 1 {\displaystyle 1\times {\mathcal {P}}_{1}} is a function b : 1 → P 1 {\displaystyle b\colon 1\to {\mathcal {P}}_{1}} with ( b ( 0 ) = 1 ) ↔ P {\displaystyle {\big (}b(0)=1{\big )}\leftrightarrow P} . To claim that P 1 = 2 {\displaystyle {\mathcal {P}}_{1}=2} is to claim that excluded middle holds for P {\displaystyle P} . It has been pointed out that the empty set 0 {\displaystyle 0} and the set 1 {\displaystyle 1} itself are of course two subsets of 1 {\displaystyle 1} , meaning 2 ⊂ P 1 {\displaystyle 2\subset {\mathcal {P}}_{1}} . Whether also P 1 ⊂ 2 {\displaystyle {\mathcal {P}}_{1}\subset 2} is true in a theory is contingent on a simple disjunction: ( ∀ ( x ∈ P 1 ) . ( 0 ∈ x ∨ 0 ∉ x ) ) → P 1 ⊂ 2 {\displaystyle {\big (}\forall (x\in {\mathcal {P}}_{1}).(0\in x\lor 0\notin x){\big )}\to \,{\mathcal {P}}_{1}\subset 2} . So assuming P E M {\displaystyle {\mathrm {PEM} }} for just bounded formulas, predicative Separation then lets one demonstrate that the powerclass P 1 {\displaystyle {\mathcal {P}}_{1}} is a set. And so in this context, also full Choice proves Powerset. (In the context of I Z F {\displaystyle {\mathsf {IZF}}} , bounded excluded middle in fact already turns set theory classical, as discussed further below.) Full Separation is equivalent to just assuming that each individual subclass of 1 {\displaystyle 1} is a set. Assuming full Separation, both full Choice and Regularity prove P E M {\displaystyle {\mathrm {PEM} }} . Assuming P E M {\displaystyle {\mathrm {PEM} }} in this theory, Set induction becomes equivalent to Regularity and Replacement becomes capable of proving full Separation. Note that cardinal relations involving uncountable sets are also elusive in Z F C {\displaystyle {\mathsf {ZFC}}} , where the characterization of uncountability simplifies to | ω | < | x | {\displaystyle |\omega |<|x|} . For example, regarding the uncountable power 2 | ω | {\displaystyle 2^{|\omega |}} , it is independent of that classical theory whether all such x {\displaystyle x} have 2 | ω | ≤ | x | {\displaystyle 2^{|\omega |}\leq |x|} , nor does it prove that 2 | ω | < 2 | x | {\displaystyle 2^{|\omega |}<2^{|x|}} . See continuum hypothesis and the related Easton's theorem. ==== Category and type theoretic notions ==== So in this context with Exponentiation, first-order arithmetic has a model and all function spaces between sets exist. The latter are more accessible than the classes containing all subsets of a set, as is the case with exponential objects resp. subobjects in category theory. In category theoretical terms, the theory B C S T + E x p {\displaystyle {\mathsf {BCST}}+{\mathrm {Exp} }} essentially corresponds to constructively well-pointed Cartesian closed Heyting pretoposes with (whenever Infinity is adopted) a natural numbers object. Existence of powerset is what would turn a Heyting pretopos into an elementary topos. Every such topos that interprets Z F {\displaystyle {\mathsf {ZF}}} is of course a model of these weaker theories, but locally Cartesian closed pretoposes have been defined that e.g. interpret theories with Exponentiation but reject full Separation and Powerset. A form of P E M {\displaystyle {\mathrm {PEM} }} corresponds to any subobject having a complement, in which case we call the topos Boolean. Diaconescu's theorem in its original topos form says that this hold iff any coequalizer of two nonintersecting monomorphisms has a section. The latter is a formulation of choice. Barr's theorem states that any topos admits a surjection from a Boolean topos onto it, relating to classical statements being provable intuitionistically. In type theory, the expression " x → y {\displaystyle x\to y} " exists on its own and denotes function spaces, a primitive notion. These types (or, in set theory, classes or sets) naturally appear, for example, as the type of the currying bijection between ( z × x ) → y {\displaystyle (z\times x)\to y} and z → y x {\displaystyle z\to y^{x}} , an adjunction. A typical type theory with general programming capability - and certainly those that can model C Z F {\displaystyle {\mathsf {CZF}}} , which is considered a constructive set theory - will have a type of integers and function spaces representing Z → Z {\displaystyle {\mathbb {Z} }\to {\mathbb {Z} }} , and as such also include types that are not countable. This is just to say, or implies, that among the function terms f : Z → ( Z → Z ) {\displaystyle f\colon {\mathbb {Z} }\to ({\mathbb {Z} }\to {\mathbb {Z} })} , none have the property of being a surjection. Constructive set theories are also studied in the context of applicative axioms. ==== Metalogic ==== While the theory E C S T + E x p {\displaystyle {\mathsf {ECST}}+{\mathrm {Exp} }} does not exceed the consistency strength of Heyting arithmetic, adding Excluded Middle gives a theory proving the same theorems as classical Z F {\displaystyle {\mathsf {ZF}}} minus Regularity! Thus, adding Regularity as well as either P E M {\displaystyle {\mathrm {PEM} }} or full Separation to E C S T + E x p {\displaystyle {\mathsf {ECST}}+{\mathrm {Exp} }} gives full classical Z F {\displaystyle {\mathsf {ZF}}} . Adding full Choice and full Separation gives Z F C {\displaystyle {\mathsf {ZFC}}} minus Regularity. So this would thus lead to a theory beyond the strength of typical type theory. The presented theory does not prove a function space like N N {\displaystyle {\mathbb {N} }^{\mathbb {N} }} to be not enumerable, in the sense of injections out of it. Without further axioms, intuitionistic mathematics has models in recursive functions but also forms of hypercomputation. === Analysis === In this section the strength of E C S T + E x p {\displaystyle {\mathsf {ECST}}+{\mathrm {Exp} }} is elaborated on. For context, possible further principles are mentioned, which are not necessarily classical and also not generally considered constructive. Here a general warning is in order: When reading proposition equivalence claims in the computable context, one shall always be aware which choice, induction and comprehension principles are silently assumed. See also the related constructive analysis, feasible analysis and computable analysis. The theory so far proves uniqueness of Archimedean, Dedekind complete (pseudo-)ordered fields, with equivalence by a unique isomorphism. The prefix "pseudo" here highlights that the order will, in any case, constructively not always be decidable. This result is relevant assuming complete such models exist as sets. ==== Topology ==== Regardless of the choice of model, the characteristic flavor of a constructive theory of numbers can be explicated using an independent proposition P {\displaystyle P} . Consider a counter-example to the constructive provability of the well-orderedness of the naturals, but now embedded in the reals. Say M := { x ∈ R ∣ ( x = 0 ∧ P ) ∨ ( x = 1 ) } {\displaystyle M:=\{x\in {\mathbb {R} }\mid (x=0\land P)\lor (x=1)\}} . The infimum metric distance between some point and such a subset, what may be expressed as ρ ( 0 , M ) {\displaystyle \rho (0,M)} for example, may constructively fail to provably exist. More generally, this locatedness property of subsets governs the well-developed constructive metric space theory. Whether Cauchy or Dedekind reals, among others, also fewer statements about the arithmetic of the reals are decidable, compared to the classical theory. ==== Cauchy sequences ==== Exponentiation implies recursion principles and so in E C S T + E x p {\displaystyle {\mathsf {ECST}}+{\mathrm {Exp} }} , one can comfortably reason about sequences s : ω → Q {\displaystyle s\colon \omega \to {\mathbb {Q} }} , their regularity properties such as | s n − s m | ≤ 1 n + 1 m {\displaystyle |s_{n}-s_{m}|\leq {\tfrac {1}{n}}+{\tfrac {1}{m}}} , or about shrinking intervals in ω → ( Q × Q ) {\displaystyle \omega \to ({\mathbb {Q} }\times {\mathbb {Q} })} . So this enables speaking of Cauchy sequences and their arithmetic. This is also the approach to analysis taken in Z 2 {\displaystyle {\mathsf {Z}}_{2}} . ==== Cauchy reals ==== Any Cauchy real number is a collection of such sequences, i.e. a subset of a set of functions on ω {\displaystyle \omega } constructed with respect to an equivalence relation. Exponentiation together with bounded separation prove the collection of Cauchy reals to be a set, thus somewhat simplifying the logically treatment of the reals. Even in the strong theory I Z F {\displaystyle {\mathsf {IZF}}} with a strengthened form of Collection, the Cauchy reals are poorly behaved when not assuming a form of countable choice, and A C ω , 2 {\displaystyle {\mathrm {AC} _{\omega ,2}}} suffices for most results. This concerns completeness of equivalence classes of such sequences, equivalence of the whole set to the Dedekind reals, existence of a modulus of convergence for all Cauchy sequences and the preservation of such a modulus when taking limits. An alternative approach that is slightly better behaved is to work a collection of Cauchy reals together a choice of modulus, i.e. not with just the real numbers but with a set of pairs, or even with a fixed modulus shared by all real numbers. ==== Towards the Dedekind reals ==== As in the classical theory, Dedekind cuts are characterized using subsets of algebraic structures such as Q {\displaystyle {\mathbb {Q} }} : The properties of being inhabited, numerically bounded above, "closed downwards" and "open upwards" are all bounded formulas with respect to the given set underlying the algebraic structure. A standard example of a cut, the first component indeed exhibiting these properties, is the representation of 2 {\displaystyle {\sqrt {2}}} given by ⟨ { x ∈ Q ∣ x < 0 ∨ x 2 < 2 } , { x ∈ Q ∣ 0 < x ∧ 2 < x 2 } ⟩ ∈ P Q × P Q {\displaystyle {\big \langle }\{x\in {\mathbb {Q} }\mid x<0\lor x^{2}<2\},\,\{x\in {\mathbb {Q} }\mid 0<x\land 2<x^{2}\}{\big \rangle }\,\ \in \,\ {{\mathcal {P}}_{\mathbb {Q} }}\times {{\mathcal {P}}_{\mathbb {Q} }}} (Depending on the convention for cuts, either of the two parts or neither, like here, may makes use of the sign ≤ {\displaystyle \leq } .) The theory given by the axioms so far validates that a pseudo-ordered field that is also Archimedean and Dedekind complete, if it exists at all, is in this way characterized uniquely, up to isomorphism. However, the existence of just function spaces such as { 0 , 1 } Q {\displaystyle \{0,1\}^{\mathbb {Q} }} does not grant P Q {\displaystyle {{\mathcal {P}}_{\mathbb {Q} }}} to be a set, and so neither is the class of all subsets of Q {\displaystyle {\mathbb {Q} }} that do fulfill the named properties. What is required for the class of Dedekind reals to be a set is an axiom regarding existence of a set of subsets and this is discussed further below in the section on Binary refinement. In a context without P E M {\displaystyle {\mathrm {PEM} }} or Powerset, countable choice into finite sets is assumed to prove the uncountability of the set of all Dedekind reals. ==== Constructive schools ==== Most schools for constructive analysis validate some choice and also B D {\displaystyle \mathrm {BD} } - N {\displaystyle {\mathbb {N} }} , as defined in the second section on number bounds. Here are some other propositions employed in theories of constructive analysis that are not provable using just base intuitionistic logic: On the recursive mathematics side (the "Russian" or "Markovian" constructive framework with many abbreviations, e.g. R U S S {\displaystyle {\mathsf {RUSS}}} ), first one has Markov's principle M P {\displaystyle {\mathrm {MP} }} , which is a form of proof by contradiction motivated by (unbound memory capacity) computable search. This has notable impact on statements about real numbers, as touched upon below. In this school one further even has the anti-classical constructive Church's thesis principle C T {\displaystyle {\mathrm {CT} }} , generally adopted for number-theoretic functions. Church's thesis principle expressed in the language of set theory and formulated for set functions postulates that these all correspond to computable programs that eventually halt on any argument. In computability theory, the natural numbers corresponding to indices of codes of the computable functions which are total are Π 2 0 {\displaystyle \Pi _{2}^{0}} in the arithmetical hierarchy, meaning membership of any index is affirmed by validating a ∀ x ∃ y {\displaystyle \forall x\,\exists y} proposition. This is to say that such a collection of functions is still a mere subclass of the naturals and so is, when put in relation to some classical function spaces, conceptually small. In this sense, adopting C T {\displaystyle {\mathrm {CT} }} postulate makes ω → ω {\displaystyle \omega \to \omega } into a "sparse" set, as viewed from classical set theory. Subcountability of sets can also be postulated independently. So on another end, on the Brouwerian intuitionist side ( I N T {\displaystyle {\mathsf {INT}}} ), there are bar induction, the decidable fan theorem F A N Δ {\displaystyle {\mathrm {FAN} }_{\Delta }} saying decidable bars are uniform, which are amongst the weakest often discussed principles, Kripke's schema (with countable choice turning all subclasses of ω {\displaystyle \omega } countable), or even Brouwer's anti-classical continuity principle, determining return values of what is established a function on unending sequences already through just finite initial segments. Certain laws in both of those schools contradict W L P O {\displaystyle {\mathrm {WLPO} }} , so that choosing to adopt all principles from either school disproves theorems from classical analysis. C T 0 {\displaystyle {\mathrm {CT} }_{0}} is still consistent with some choice, but contradicts the classical W K L {\displaystyle {\mathrm {WKL} }} and L L P O {\displaystyle {\mathrm {LLPO} }} , explained below. The independence of premise rule with set existence premises is not fully understood, but as a number theoretic principle it is in conflict with the Russian school axioms in some frameworks. Notably, C T 0 {\displaystyle {\mathrm {CT} }_{0}} also contradicts F A N Δ {\displaystyle {\mathrm {FAN} }_{\Delta }} , meaning the constructive schools also cannot be combined in full. Some of the principles cannot be combined constructively to the extent that together they imply forms of P E M {\displaystyle {\mathrm {PEM} }} - for example M P {\displaystyle {\mathrm {MP} }} plus the countability of all subsets of the naturals. These combinations are then naturally also not consistent with further anti-classical principles. ==== Indecomposability ==== Denote the class of all sets by V {\displaystyle {\mathcal {V}}} . Decidability of membership in a class R {\displaystyle R} can be expressed as membership in R ∪ ( V ∖ R ) {\displaystyle R\cup ({\mathcal {V}}\setminus R)} . We also note that, by definition, the two extremal classes V {\displaystyle {\mathcal {V}}} and { } {\displaystyle \{\}} are trivially decidable. Membership in those two is equivalent to the trivial propositions x = x {\displaystyle x=x} resp. ¬ ( x = x ) {\displaystyle \neg (x=x)} . Call a class R {\displaystyle R} indecomposable or cohesive if, for any predicate χ {\displaystyle \chi } , ( ∀ ( x ∈ R ) . χ ( x ) ∨ ¬ χ ( x ) ) → ( ( ∀ ( x ∈ R ) . χ ( x ) ) ∨ ( ∀ ( x ∈ R ) . ¬ χ ( x ) ) ) {\displaystyle {\big (}\forall (x\in R).\chi (x)\lor \neg \chi (x){\big )}\to {\Big (}{\big (}\forall (x\in R).\chi (x){\big )}\lor {\big (}\forall (x\in R).\neg \chi (x){\big )}{\Big )}} This expresses that the only properties that are decidable on R {\displaystyle R} are the trivial properties. This is well studied in intuitionistic analysis. The so called indecomposability schema U Z {\displaystyle {\mathrm {UZ} }} (Unzerlegbarkeit) for set theory is a possible principle which states that the whole class V {\displaystyle {\mathcal {V}}} is indecomposable. Extensionally speaking, U Z {\displaystyle {\mathrm {UZ} }} postulates that the two trivial classes are the only classes that are decidable with respect to the class of all sets. For a simple motivating predicate, consider membership x ∈ 1 {\displaystyle x\in 1} in the first non-trivial class, which is to say the property x = { } {\displaystyle x=\{\}} of being empty. This property is non-trivial to the extent that it separates some sets: The empty set is a member of 1 {\displaystyle 1} , by definition, while a plethora of sets are provenly not members of 1 {\displaystyle 1} . But, using Separation, one may of course also define various sets for which emptiness is not decidable in a constructive theory at all, i.e. membership in 1 ∪ ( V ∖ 1 ) {\displaystyle 1\cup ({\mathcal {V}}\setminus 1)} is not provable for all sets. So here the property of emptiness does not partition the set theoretical domain of discourse into two decidable parts. For any such non-trivial property, the contrapositive of U Z {\displaystyle {\mathrm {UZ} }} says that it cannot be decidable over all sets. U Z {\displaystyle {\mathrm {UZ} }} is implied by the uniformity principle U P {\displaystyle {\mathrm {UP} }} , which is consistent with C Z F {\displaystyle {\mathsf {CZF}}} and discussed below. === Non-constructive principles === Of course P E M {\displaystyle {\mathrm {PEM} }} and many principles defining intermediate logics are non-constructive. P E M {\displaystyle {\mathrm {PEM} }} and W P E M {\displaystyle {\mathrm {WPEM} }} , which is P E M {\displaystyle {\mathrm {PEM} }} for just negated propositions, can be presented as De Morgan's rules. More specifically, this section shall be concerned with statements in terms of predicates - especially weaker ones, expressed in terms of a few quantifiers over sets, on top of decidable predicates on numbers. Referring back to the section on characteristic functions, one may call a collection A {\displaystyle A} searchable if it is searchable for all its detachable subsets, which itself corresponds to { 0 , 1 } A {\displaystyle \{0,1\}^{A}} . This is a form of ∃ {\displaystyle \exists } - P E M {\displaystyle {\mathrm {PEM} }} for A {\displaystyle A} . Note that in the context of Exponentiation, such proposition on sets are now set-bound. Particularly valuable in the study of constructive analysis are non-constructive claims commonly formulated in terms of the collection of all binary sequences and the characteristic functions f {\displaystyle f} on the arithmetic domain A = ω {\displaystyle A=\omega } are well studied. Here f ( n _ ) = 0 {\displaystyle f({\underline {\mathrm {n} }})=0} is a decidable proposition at each numeral n {\displaystyle {\mathrm {n} }} , but, as demonstrated previously, quantified statements in terms of f {\displaystyle f} may not be. As is known from the incompleteness theorem and its variations, already in first-order arithmetic, example functions on N {\displaystyle {\mathbb {N} }} can be characterized such that if P A {\displaystyle {\mathsf {PA}}} is consistent, the competing ∃ {\displaystyle \exists } - P E M {\displaystyle {\mathrm {PEM} }} disjuncts, of low complexity, are each P A {\displaystyle {\mathsf {PA}}} -unprovable (even if P A {\displaystyle {\mathsf {PA}}} proves the disjunction of the two axiomatically.) More generally, the arithmetic ∃ {\displaystyle \exists } - P E M {\displaystyle {\mathrm {PEM} }} , a most prominent non-constructive, essentially logical statement goes by the name limited principle of omniscience L P O {\displaystyle {\mathrm {LPO} }} . In the constructive set theory C Z F {\displaystyle {\mathsf {CZF}}} introduced below, it implies B D {\displaystyle {\mathrm {BD} }} - N {\displaystyle {\mathbb {N} }} , M P {\displaystyle {\mathrm {MP} }} , the Π 1 0 {\displaystyle \Pi _{1}^{0}} -version of the fan theorem, but also W K L {\displaystyle {\mathrm {WKL} }} discussed below. Recall examples of famous sentences that can be written down in a Π 1 0 {\displaystyle \Pi _{1}^{0}} -fashion, i.e. of Goldbach-type: Goldbach conjecture, Fermat's last theorem but also the Riemann hypothesis are among them. Assuming relativized dependent choice R D P {\displaystyle {\mathrm {RDP} }} and the classical L P O {\displaystyle {\mathrm {LPO} }} over C Z F {\displaystyle {\mathsf {CZF}}} does not enable proofs of more Π 0 2 {\displaystyle \Pi _{0}^{2}} -statements. L P O {\displaystyle {\mathrm {LPO} }} postulates a disjunctive property, as does the weaker decidability statement for functions being constant ( Π 1 0 {\displaystyle \Pi _{1}^{0}} -sentences) W L P O {\displaystyle {\mathrm {WLPO} }} , the arithmetic ∀ {\displaystyle \forall } - P E M {\displaystyle {\mathrm {PEM} }} . The two are related in a similar way as is P E M {\displaystyle {\mathrm {PEM} }} versus W P E M {\displaystyle {\mathrm {WPEM} }} and they essentially differ by M P {\displaystyle {\mathrm {MP} }} . W L P O {\displaystyle {\mathrm {WLPO} }} in turn implies the so-called "lesser" version L L P O {\displaystyle {\mathrm {LLPO} }} . This is the (arithmetic) ∃ {\displaystyle \exists } -version of the non-constructive De Morgan's rule for a negated conjunction. There are, for example, models of the strong set theory I Z F {\displaystyle {\mathsf {IZF}}} which separate such statements, in the sense that they may validate L L P O {\displaystyle {\mathrm {LLPO} }} but reject W L P O {\displaystyle {\mathrm {WLPO} }} . Disjunctive principles about Π 1 0 {\displaystyle \Pi _{1}^{0}} -sentences generally hint at equivalent formulations deciding apartness in analysis in a context with mild choice or M P {\displaystyle {\mathrm {MP} }} . The claim expressed by L P O {\displaystyle {\mathrm {LPO} }} translated to real numbers is equivalent to the claim that either equality or apartness of any two reals is decidable (it in fact decides the trichotomy). It is then also equivalent to the statement that every real is either rational or irrational - without the requirement for or construction of a witness for either disjunct. Likewise, the claim expressed by L L P O {\displaystyle {\mathrm {LLPO} }} for real numbers is equivalent that the ordering ≤ {\displaystyle \leq } of any two reals is decidable (dichotomy). It is then also equivalent to the statement that if the product of two reals is zero, then either of the reals is zero - again without a witness. Indeed, formulations of the three omniscience principles are then each equivalent to theorems of the apartness, equality or order of two reals in this way. Yet more can be said about the Cauchy sequences that are augmented with a modulus of convergence. A famous source of computable undecidability - and in turn also of a broad range of undecidable propositions - is the predicate expressing a computer program to be total. ==== Infinite trees ==== Through the relation between computability and the arithmetical hierarchy, insights in this classical study are also revealing for constructive considerations. A basic insight of reverse mathematics concerns computable infinite finitely branching binary trees. Such a tree may e.g. be encoded as an infinite set of finite sets T ⊂ ⋃ n ∈ ω { 0 , 1 } { 0 , 1 , … , n − 1 } {\displaystyle T\,\subset \,\bigcup _{n\in \omega }\{0,1\}^{\{0,1,\dots ,n-1\}}} , with decidable membership, and those trees then provenly contain elements of arbitrary big finite size. The so called Weak Kőnig's lemma W K L {\displaystyle {\mathrm {WKL} }} states: For such T {\displaystyle T} , there always exists an infinite path in ω → { 0 , 1 } {\displaystyle \omega \to \{0,1\}} , i.e. an infinite sequence such that all its initial segments are part of the tree. In reverse mathematics, the second-order arithmetic subsystem R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} does not prove W K L {\displaystyle {\mathrm {WKL} }} . To understand this, note that there are computable trees K {\displaystyle K} for which no computable such path through it exists. To prove this, one enumerates the partial computable sequences and then diagonalizes all total computable sequences in one partial computable sequences d {\displaystyle d} . One can then roll out a certain tree K {\displaystyle K} , one exactly compatible with the still possible values of d {\displaystyle d} everywhere, which by construction is incompatible with any total computable path. In C Z F {\displaystyle {\mathsf {CZF}}} , the principle W K L {\displaystyle {\mathrm {WKL} }} implies L L P O {\displaystyle {\mathrm {LLPO} }} and Π 1 0 {\displaystyle \Pi _{1}^{0}} - A C ω , 2 {\displaystyle {\mathrm {AC} }_{\omega ,2}} , a very modest form of countable choice introduced above. The former two are equivalent assuming that choice principle already in the more conservative arithmetic context. W K L {\displaystyle {\mathrm {WKL} }} is also equivalent to the Brouwer fixed point theorem and other theorems regarding values of continuous functions on the reals. The fixed point theorem in turn implies the intermediate value theorem, but always be aware that these claims may depend on the formulation, as the classical theorems about encoded reals can translate to different variants when expressed in a constructive context. The W K L {\displaystyle {\mathrm {WKL} }} , and some variants thereof, concerns infinite graphs and so its contrapositives gives a condition for finiteness. Again to connect to analysis, over the classical arithmetic theory R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} , the claim of W K L {\displaystyle {\mathrm {WKL} }} is for example equivalent to the Borel compactness regarding finite subcovers of the real unit interval. F A N Δ {\displaystyle {\mathrm {FAN} }_{\Delta }} is a closely related existence claim involving finite sequences in an infinite context. Over R C A 0 {\displaystyle {\mathsf {RCA}}_{0}} , they are actually equivalent. In C Z F {\displaystyle {\mathsf {CZF}}} those are distinct, but, after again assuming some choice, here then W K L {\displaystyle {\mathrm {WKL} }} implies F A N Δ {\displaystyle {\mathrm {FAN} }_{\Delta }} . === Induction === ==== Mathematical induction ==== It was observed that in set language, induction principles can read I n d A → ω ⊂ A {\displaystyle \mathrm {Ind} _{A}\to \omega \subset A} , with the antecedent I n d A {\displaystyle \mathrm {Ind} _{A}} defined as further above, and with ω ⊂ A {\displaystyle \omega \subset A} meaning ∀ ( n ∈ ω ) . n ∈ A {\displaystyle \forall (n\in \omega ).n\in A} where the set ω {\displaystyle \omega } always denotes the standard model of natural numbers. Via the strong axiom of Infinity and predicative Separation, the validity of induction for set-bounded or Δ 0 {\displaystyle \Delta _{0}} -definitions was already established and thoroughly discussed. For those predicates involving only quantifiers over ω {\displaystyle \omega } , it validates induction in the sense of the first-order arithmetic theory. In a set theory context where ω {\displaystyle \omega } is a set, this induction principle can be used to prove predicatively defined subclasses of ω {\displaystyle \omega } to be the set ω {\displaystyle \omega } itself. The so called full mathematical induction schema now postulates set equality of ω {\displaystyle \omega } to all its inductive subclasses. As in the classical theory, it is also implied when passing to the impredicative full Separation schema. As stated in the section on Choice, induction principles such as this are also implied by various forms of choice principles. The recursion principle for set functions mentioned in the section dedicated to arithmetic is also implied by the full mathematical induction schema over one's structure modeling the naturals (e.g. ω {\displaystyle \omega } ). So for that theorem, granting a model of Heyting arithmetic, it represents an alternative to exponentiation principles. Predicate formulas used with the schema are to be understood as formulas in first-order set theory. The zero 0 {\displaystyle 0} denotes the set { } {\displaystyle \{\}} as above, and the set S n {\displaystyle Sn} denotes the successor set of n ∈ ω {\displaystyle n\in \omega } , with n ∈ S n {\displaystyle n\in Sn} . By Axiom of Infinity above, it is again a member of ω {\displaystyle \omega } . Beware that unlike in an arithmetic theory, the naturals here are not the abstract elements in the domain of discourse, but elements of a model. As has been observed in previous discussions, when accepting E C S T {\displaystyle {\mathsf {ECST}}} , not even for all predicatively defined sets is the equality to such a finite von Neumann ordinal necessarily decidable. ==== Set Induction ==== Going beyond the previous induction principles, one has full set induction, which is to be compared to well-founded induction. Like mathematical induction above, the following axiom is formulated as a schema in terms of predicates, and thus has a different character than induction principles proven from predicative set theory axioms. A variant of the axiom just for bounded formulas is also studied independently and may be derived from other axioms. Here ∀ ( z ∈ { } ) . ϕ ( z ) {\displaystyle \forall (z\in \{\}).\phi (z)} holds trivially and so this covers to the "bottom case" ϕ ( { } ) {\displaystyle \phi (\{\})} in the standard framework. This (as well as natural number induction) may again be restricted to just the bounded set formulas, in which case arithmetic is not impacted. In E C S T {\displaystyle {\mathsf {ECST}}} , the axiom proves induction in transitive sets and so in particular also for transitive sets of transitive sets. The latter then is an adequate definition of the ordinals, and even a Δ 0 {\displaystyle \Delta _{0}} -formulation. Set induction in turn enables ordinal arithmetic in this sense. It further allows definitions of class functions by transfinite recursion. The study of the various principles that grant set definitions by induction, i.e. inductive definitions, is a main topic in the context of constructive set theory and their comparatively weak strengths. This also holds for their counterparts in type theory. Replacement is not required to prove induction over the set of naturals from set induction, but that axiom is necessary for their arithmetic modeled within the set theory. The axiom of regularity is a single statement with universal quantifier over sets and not a schema. As show, it implies P E M {\displaystyle {\mathrm {PEM} }} , and so is non-constructive. Now for ϕ {\displaystyle \phi } taken to be the negation of some predicate ¬ S {\displaystyle \neg S} and writing Σ {\displaystyle \Sigma } for the class { y ∣ S ( y ) } {\displaystyle \{y\mid S(y)\}} , induction reads ∀ ( x ∈ Σ ) . ¬ ( x ∩ Σ = { } ) ↔ Σ = { } {\displaystyle \forall (x\in \Sigma ).\neg (x\cap \Sigma =\{\})\,\,\leftrightarrow \,\,\Sigma =\{\}} Via the contrapositive, set induction implies all instances of regularity but only with double-negated existence in the conclusion. In the other direction, given enough transitive sets, regularity implies each instance of set induction. ==== Metalogic ==== The theory formulated above can be expressed as C Z F {\displaystyle {\mathsf {CZF}}} with its collection axioms discarded in favour of the weaker Replacement and Exponentiation axioms. It proves the Cauchy reals to be a set, but not the class of Dedekind reals. Call an ordinal itself trichotomous if the irreflexive membership relation " ∈ {\displaystyle \in } " among its members is trichotomous. Like the axiom of regularity, set induction restricts the possible models of " ∈ {\displaystyle \in } " and thus that of a set theory, as was the motivation for the principle in the 20's. But the constructive theory here does not prove a trichotomy for all ordinals, while the trichotomous ordinals are not well behaved with respect to the notion of successor and rank. The added proof-theoretical strength attained with Induction in the constructive context is significant, even if dropping Regularity in the context of Z F {\displaystyle {\mathsf {ZF}}} does not reduce the proof-theoretical strength. Even without Exponentiation, the present theory with set induction has the same proof theoretic strength as C Z F {\displaystyle {\mathsf {CZF}}} and proves the same functions recursive. Specifically, its proof-theoretic large countable ordinal is the Bachmann–Howard ordinal. This is also the ordinal of classical or intuitionistic Kripke–Platek set theory. It is consistent even with I Z F {\displaystyle {\mathsf {IZF}}} to assume that the class of trichotomous ordinals form a set. The current theory augmented with this ordinal set existence postulate proves the consistency of C Z F {\displaystyle {\mathsf {CZF}}} . Aczel was also one of the main developers or Non-well-founded set theory, which rejects set induction. ==== Relation to ZF ==== The theory also constitutes a presentation of Zermelo–Fraenkel set theory Z F {\displaystyle {\mathsf {ZF}}} in the sense that variants of all its eight axioms are present. Extensionality, Pairing, Union and Replacement are indeed identical. Separation is adopted in a weak predicative form while Infinity is stated in a strong formulation. Akin to the classical formulation, this Separation axiom and the existence of any set already proves the Empty Set axiom. Exponentiation for finite domains and full mathematical induction are also implied by their stronger adopted variants. Without the principle of excluded middle, the theory here is lacking, in its classical form, full Separation, Powerset as well as Regularity. Accepting P E M {\displaystyle {\mathrm {PEM} }} now exactly leads into the classical theory. The following highlights the different readings of a formal theory. Let C H {\displaystyle \mathrm {CH} } denote the continuum hypothesis and B := { z ∈ 1 ∣ C H } {\displaystyle B:=\{z\in 1\mid \mathrm {CH} \}} so that 0 ∈ B ↔ C H {\displaystyle 0\in B\leftrightarrow \mathrm {CH} } . Then b := B ∪ { 1 } {\displaystyle b:=B\cup \{1\}} is inhabited by 1 {\displaystyle 1} and any set that is established to be a member of b {\displaystyle b} either equals 0 {\displaystyle 0} or 1 {\displaystyle 1} . Induction on ω {\displaystyle \omega } implies that it cannot consistently be negated that b {\displaystyle b} has some least natural number member. The value of such a member can be shown to be independent of theories such as Z F C {\displaystyle {\mathsf {ZFC}}} . Nonetheless, any classical set theory like Z F C {\displaystyle {\mathsf {ZFC}}} also proves there exists such a number. === Strong Collection === Having discussed all the weakened forms of the classical set theory axioms, Replacement and Exponentiation can be further strengthened without losing a type theoretical interpretation, and in a way that is not going beyond Z F {\displaystyle {\mathsf {ZF}}} . So firstly, one may reflect upon the strength of the axiom of replacement, also in the context of the classical set theory. For any set y {\displaystyle y} and any natural n {\displaystyle n} , there exists the product y n {\displaystyle y^{n}} recursively given by y n − 1 × y {\displaystyle y^{n-1}\times y} , which have ever deeper rank. Induction for unbound predicates proves that these sets exist for all of the infinitely many naturals. Replacement "for n ↦ y n {\displaystyle n\mapsto y^{n}} " now moreover states that this infinite class of products can be turned into the infinite set, { p ∣ ∃ ( n ∈ ω ) . p = y n } {\displaystyle \{p\mid \exists (n\in \omega ).p=y^{n}\}} . This is also not a subset of any previously established set. Going beyond those axioms also seen in Myhill's typed approach, consider the discussed constructive theory with Exponentiation and Induction, but now strengthened by the collection schema. In Z F {\displaystyle {\mathsf {ZF}}} it is equivalent to Replacement, unless the powerset axiom is dropped. In the current context the strong axiom presented supersedes Replacement, due to not requiring the binary relation definition to be functional, but possibly multi-valued. In words, for every total relation, there exists an image set b {\displaystyle b} such that the relation is total in both directions. Expressing this via a raw first-order formulation leads to a somewhat repetitive format. The antecedent states that one considers relation ϕ {\displaystyle \phi } between sets x {\displaystyle x} and y {\displaystyle y} that are total over a certain domain set a {\displaystyle a} , that is, ϕ {\displaystyle \phi } has at least one "image value" y {\displaystyle y} for every element x {\displaystyle x} in the domain. This is more general than an inhabitance condition x ∈ y {\displaystyle x\in y} in a set theoretical choice axiom, but also more general than the condition of Replacement, which demands unique existence ∃ ! y {\displaystyle \exists !y} . In the consequent, firstly, the axioms states that then there exists a set b {\displaystyle b} which contains at least one "image" value y {\displaystyle y} under ϕ {\displaystyle \phi } , for every element of the domain. Secondly, in this axioms formulation it then moreover states that only such images y {\displaystyle y} are elements of that new codomain set b {\displaystyle b} . It is guaranteeing that b {\displaystyle b} does not overshoot the codomain of ϕ {\displaystyle \phi } and thus the axiom is also expressing some power akin to a Separation procedure. The principle may be used in the constructive study of larger sets beyond the everyday need of analysis. Weak collection and predicative separation together imply strong collection: separation cuts out the subset of b {\displaystyle b} consisting of those y {\displaystyle y} such that ϕ ( x , y ) {\displaystyle \phi (x,y)} for some x ∈ a {\displaystyle x\in a} . ==== Metalogic ==== This theory without P E M {\displaystyle {\mathrm {PEM} }} , without unbounded separation and without "naive" Power set enjoys various nice properties. For example, as opposed to C Z F {\displaystyle {\mathsf {CZF}}} with its subset collection schema below, it has the existence property. === Constructive Zermelo–Fraenkel === ==== Binary refinement ==== The so called binary refinement axiom says that for any a {\displaystyle a} there exists a set B a ⊂ P a {\displaystyle {\mathcal {B}}_{a}\subset {\mathcal {P}}_{a}} such that for any covering a = x ∪ y {\displaystyle a=x\cup y} , the set B a {\displaystyle {\mathcal {B}}_{a}} holds two subsets c ⊂ x {\displaystyle c\subset x} and d ⊂ y {\displaystyle d\subset y} that also do this covering job, a = c ∪ d {\displaystyle a=c\cup d} . It is a weakest form of the powerset axiom and at the core of some important mathematical proofs. Fullness below, for relations between the set a {\displaystyle a} and the finite { 0 , 1 } {\displaystyle \{0,1\}} , implies that this is indeed possible. Taking another step back, E C S T {\displaystyle {\mathsf {ECST}}} plus Recursion and plus Binary refinement already proves that there exists an Archimedean, Dedekind complete pseudo-ordered field. That set theory also proves that the class of left Dedekind cuts is a set, not requiring Induction or Collection. And it moreover proves that function spaces into discrete sets are sets (there e.g. ω → ω {\displaystyle \omega \to \omega } ), without assuming E x p {\displaystyle {\mathrm {Exp} }} . Already over the weak theory B C S T {\displaystyle {\mathsf {BCST}}} (which is to say without Infinity) does binary refinement prove that function spaces into discrete sets are sets, and therefore e.g. the existence of all characteristic function spaces { 0 , 1 } a {\displaystyle \{0,1\}^{a}} . ==== Subset Collection ==== The theory known as C Z F {\displaystyle {\mathsf {CZF}}} adopts the axioms of the previous sections plus a stronger form of Exponentiation. It is by adopting the following alternative to Exponentiation, which can again be seen as a constructive version of the Power set axiom: An alternative that is not a schema is elaborated on below. ==== Fullness ==== For given a {\displaystyle a} and b {\displaystyle b} , let R a b {\displaystyle {\mathcal {R}}_{ab}} be the class of all total relations between a {\displaystyle a} and b {\displaystyle b} . This class is given as r ∈ R a b ↔ ( ( ∀ ( x ∈ a ) . ∃ ( y ∈ b ) . ⟨ x , y ⟩ ∈ r ) ∧ ( ∀ ( p ∈ r ) . ∃ ( x ∈ a ) . ∃ ( y ∈ b ) . p = ⟨ x , y ⟩ ) ) {\displaystyle r\in {\mathcal {R}}_{ab}\leftrightarrow {\Big (}{\big (}\forall (x\in a).\exists (y\in b).\langle x,y\rangle \in r{\big )}\,\land \,{\big (}\forall (p\in r).\exists (x\in a).\exists (y\in b).p=\langle x,y\rangle {\big )}{\Big )}} As opposed to the function definition, there is no unique existence quantifier in ∃ ! ( y ∈ b ) {\displaystyle \exists !(y\in b)} . The class R a b {\displaystyle {\mathcal {R}}_{ab}} represents the space of "non-unique-valued functions" or "multivalued functions" from a {\displaystyle a} to b {\displaystyle b} , but as set of individual pairs with right projection in b {\displaystyle b} . The second clause says that one is concerned with only these relations, not those which are total on a {\displaystyle a} but also extend their domain beyond a {\displaystyle a} . One does not postulate R a b {\displaystyle {\mathcal {R}}_{ab}} to be a set, since with Replacement one can use this collection of relations between a set a {\displaystyle a} and the finite b = { 0 , 1 } {\displaystyle b=\{0,1\}} , i.e. the "bi-valued functions on a {\displaystyle a} ", to extract the set P a {\displaystyle {\mathcal {P}}_{a}} of all its subsets. In other words R a b {\displaystyle {\mathcal {R}}_{ab}} being a set would imply the Powerset axiom. Over E C T S + Strong Collection {\displaystyle {\mathsf {ECTS}}+{\text{Strong Collection}}} , there is a single, somewhat clearer alternative axiom to the Subset Collection schema. It postulates the existence of a sufficiently large set S a b {\displaystyle {\mathcal {S}}_{ab}} of total relations between a {\displaystyle a} and b {\displaystyle b} . This says that for any two sets a {\displaystyle a} and b {\displaystyle b} , there exists a set S a b ⊂ R a b {\displaystyle {\mathcal {S}}_{ab}\subset {\mathcal {R}}_{ab}} which among its members inhabits a still total relation s ∈ S a b {\displaystyle s\in {\mathcal {S}}_{ab}} for any given total relation r ∈ R a b {\displaystyle r\in {\mathcal {R}}_{ab}} . On a given domain a {\displaystyle a} , the functions are exactly the sparsest total relations, namely the unique valued ones. Therefore, the axiom implies that there is a set such that all functions are in it. In this way, Fullness implies Exponentiation. It further implies binary refinement, already over B C S T {\displaystyle {\mathsf {BCST}}} . The Fullness axiom, as well as dependent choice, is in turn also implied by the so-called Presentation Axiom about sections, which can also be formulated category theoretically. === Metalogic of CZF === C Z F {\displaystyle {\mathsf {CZF}}} has the numerical existence property and the disjunctive property, but there are concessions: C Z F {\displaystyle {\mathsf {CZF}}} lacks the existence property due to the Subset Collection Schema or Fullness axiom. The schema can also be an obstacle for realizability models. The existence property is not lacking when the weaker Exponentiation or the stronger but impredicative Powerset axiom axiom is adopted instead. The latter is in general lacking a constructive interpretation. ==== Unprovable claims ==== The theory is consistent with some anti-classical assertions, but on its own proves nothing not provable in Z F {\displaystyle {\mathsf {ZF}}} . Some prominent statements not proven by the theory (nor by I Z F {\displaystyle {\mathsf {IZF}}} , for that matter) are part of the principles listed above, in the sections on constructive schools in analysis, on the Cauchy construction and on non-constructive principles. What follows concerns set theoretical concepts: The bounded notion of a transitive set of transitive sets is a good way to define ordinals and enables induction on ordinals. But notably, this definition includes some Δ 0 {\displaystyle \Delta _{0}} -subsets in C Z F {\displaystyle {\mathsf {CZF}}} . So assuming that the membership of 0 {\displaystyle 0} is decidable in all successor ordinals S α {\displaystyle S\alpha } proves P E M {\displaystyle {\mathrm {PEM} }} for bounded formulas in C Z F {\displaystyle {\mathsf {CZF}}} . Also, neither linearity of ordinals, nor existence of power sets of finite sets are derivable in this theory, as assuming either implies Power set. The circumstance that ordinals are better behaved in the classical than in the constructive context manifests in a different theory of large set existence postulates. Consider the functions the domain of which is ω {\displaystyle \omega } or some n ∈ ω {\displaystyle n\in \omega } . These are sequences and their ranges are counted sets. Denote by C {\displaystyle C} the class characterized as the smallest codomain such that the ranges of the aforementioned functions into C {\displaystyle C} are also itself members of C {\displaystyle C} . In Z F {\displaystyle {\mathsf {ZF}}} , this is the set H ℵ 1 {\displaystyle H_{\aleph _{1}}} of hereditarily countable sets and has ordinal rank at most ω 2 {\displaystyle \omega _{2}} . In Z F {\displaystyle {\mathsf {ZF}}} , it is uncountable (as it also contains all countable ordinals, the cardinality of which is denoted ℵ 1 {\displaystyle \aleph _{1}} ) but its cardinality is not necessarily that of R {\displaystyle {\mathbb {R} }} . Meanwhile, C Z F {\displaystyle {\mathsf {CZF}}} does not prove C {\displaystyle C} even constitutes a set, even when countable choice is assumed. Finally, the theory does not prove that all function spaces formed from sets in the constructible universe L {\displaystyle L} are sets inside L {\displaystyle L} , and this holds even when assuming Powerset instead of the weaker Exponentiation axiom. So this is a particular statement preventing C Z F {\displaystyle {\mathsf {CZF}}} from proving the class L {\displaystyle L} to be a model of C Z F {\displaystyle {\mathsf {CZF}}} . ==== Ordinal analysis ==== Taking C Z F {\displaystyle {\mathsf {CZF}}} and dropping set induction gives a theory that is conservative over H A {\displaystyle {\mathsf {HA}}} for arithmetic statements, in that sense that it proves the same arithmetical statements for its H A {\displaystyle {\mathsf {HA}}} -model ω {\displaystyle \omega } . Adding back just mathematical induction gives a theory with proof theoretic ordinal φ ( ε 0 , 0 ) {\displaystyle \varphi (\varepsilon _{0},0)} , which is the first common fixed point of the Veblen functions φ β {\displaystyle \varphi _{\beta }} for β < ε 0 {\displaystyle \beta <\varepsilon _{0}} . This is the same ordinal as for M L 1 {\displaystyle {\mathsf {ML_{1}}}} and is below the Feferman–Schütte ordinal Γ 0 {\displaystyle \Gamma _{0}} . Exhibiting a type theoretical model, the full theory C Z F {\displaystyle {\mathsf {CZF}}} goes beyond Γ 0 {\displaystyle \Gamma _{0}} , its ordinal still being the modest Bachmann–Howard ordinal. Assuming the class of trichotomous ordinals is a set raises the proof theoretical strength of C Z F {\displaystyle {\mathsf {CZF}}} (but not of I Z F {\displaystyle {\mathsf {IZF}}} ). Being related to inductive definitions or bar induction, the regular extension axiom R E A {\displaystyle {\mathrm {REA} }} raises the proof theoretical strength of C Z F {\displaystyle {\mathsf {CZF}}} . This large set axiom, granting the existence of certain nice supersets for every set, is proven by Z F C {\displaystyle {\mathsf {ZFC}}} . ==== Models ==== The category of sets and functions of C Z F + R E A {\displaystyle {\mathsf {CZF}}+{\mathrm {REA} }} is a Π W {\displaystyle \Pi W} -pretopos. Without diverging into topos theory, certain extended such Π W {\displaystyle \Pi W} -pretopoi contain models of C Z F + R E A {\displaystyle {\mathsf {CZF}}+{\mathrm {REA} }} . The effective topos contains a model of this C Z F + R E A {\displaystyle {\mathsf {CZF}}+{\mathrm {REA} }} based on maps characterized by certain good subcountability properties. Separation, stated redundantly in a classical context, is constructively not implied by Replacement. The discussion so far only committed to the predicatively justified bounded Separation. Note that full Separation (together with R D C {\displaystyle {\mathrm {RDC} }} , M P {\displaystyle {\mathrm {MP} }} and also I P {\displaystyle {\mathrm {IP} }} for sets) is validated in some effective topos models, meaning the axiom does not spoil cornerstones of the restrictive recursive school. Related are type theoretical interpretations. In 1977 Aczel showed that C Z F {\displaystyle {\mathsf {CZF}}} can still be interpreted in Martin-Löf type theory, using the propositions-as-types approach. More specifically, this uses one universe and W {\displaystyle W} -types, providing what is now seen a standard model of C Z F {\displaystyle {\mathsf {CZF}}} in M L 1 V {\displaystyle {\mathsf {ML_{1}V}}} . This is done in terms of the images of its functions and has a fairly direct constructive and predicative justification, while retaining the language of set theory. Roughly, there are two "big" types U , V {\displaystyle U,V} , the sets are all given through any f : A → V {\displaystyle f\colon A\to V} on some A : U {\displaystyle A\colon U} , and membership of a x {\displaystyle x} in the set is defined to hold when ∃ ( a : A ) . f ( a ) = x {\displaystyle \exists (a\colon A).f(a)=x} . Conversely, C Z F {\displaystyle {\mathsf {CZF}}} interprets M L 1 V {\displaystyle {\mathsf {ML_{1}V}}} . All statements validated in the subcountable model of the set theory can be proven exactly via C Z F {\displaystyle {\mathsf {CZF}}} plus the choice principle Π Σ {\displaystyle \Pi \Sigma } - A C {\displaystyle \mathrm {AC} } , stated further above. As noted, theories like C Z F {\displaystyle {\mathsf {CZF}}} , and also together with choice, have the existence property for a broad class of sets in common mathematics. Martin-Löf type theories with additional induction principles validate corresponding set theoretical axioms. Soundness and Completeness theorems of C Z F {\displaystyle {\mathsf {CZF}}} , with respect to realizability, have been established. ==== Breaking with ZF ==== One may of course add a Church's thesis. One may postulate the subcountability of all sets. This already holds true in the type theoretical interpretation and the model in the effective topos. By Infinity and Exponentiation, ω → ω {\displaystyle \omega \to \omega } is an uncountable set, while the class P ω {\displaystyle {\mathcal {P}}_{\omega }} or even P 1 {\displaystyle {\mathcal {P}}_{1}} is then provenly not a set, by Cantor's diagonal argument. So this theory then logically rejects Powerset and of course P E M {\displaystyle {\mathrm {PEM} }} . Subcountability is also in contradiction with various large set axioms. (On the other hand, also using C Z F {\displaystyle {\mathsf {CZF}}} , some such axioms imply the consistency of theories such as Z F {\displaystyle {\mathsf {ZF}}} and stronger.) As a rule of inference, C Z F {\displaystyle {\mathsf {CZF}}} is closed under Troelstra's general uniformity for both z = ω {\displaystyle z=\omega } and z = { 0 , 1 } {\displaystyle z=\{0,1\}} . One may adopt it as an anti-classical axiom schema, the uniformity principle which may be denoted U P {\displaystyle {\mathrm {UP} }} , ∀ z . ( ∀ x . ∃ ( y ∈ z ) . ϕ ( x , y ) ) → ∃ ( y ∈ z ) . ∀ x . ϕ ( x , y ) {\displaystyle \forall z.{\big (}\forall x.\exists (y\in z).\phi (x,y){\big )}\to \exists (y\in z).\forall x.\phi (x,y)} This also is incompatible with the powerset axiom. The principle is also often formulated for z = ω {\displaystyle z=\omega } . Now for a binary set of labels z = { 0 , 1 } {\displaystyle z=\{0,1\}} , U P {\displaystyle {\mathrm {UP} }} implies the indecomposability schema U Z {\displaystyle {\mathrm {UZ} }} , as noted. In 1989 Ingrid Lindström showed that non-well-founded sets can also be interpreted in Martin-Löf type theory, which are obtained by replacing Set Induction in C Z F {\displaystyle {\mathsf {CZF}}} with Aczel's anti-foundation axiom. The resulting theory C Z F A {\displaystyle {\mathsf {CZFA}}} may be studied by also adding back the ω {\displaystyle \omega } -induction schema or relativized dependent choice, as well as the assertion that every set is member of a transitive set. === Intuitionistic Zermelo–Fraenkel === The theory I Z F {\displaystyle {\mathsf {IZF}}} is C Z F {\displaystyle {\mathsf {CZF}}} adopting both the standard Separation as well as Power set and, as in Z F {\displaystyle {\mathsf {ZF}}} , one conventionally formulates the theory with Collection below. As such, I Z F {\displaystyle {\mathsf {IZF}}} can be seen as the most straight forward variant of Z F {\displaystyle {\mathsf {ZF}}} without PEM. So as noted, in I Z F {\displaystyle {\mathsf {IZF}}} , in place of Replacement, one may use the While the axiom of replacement requires the relation ϕ to be functional over the set z (as in, for every x in z there is associated exactly one y), the Axiom of Collection does not. It merely requires there be associated at least one y, and it asserts the existence of a set which collects at least one such y for each such x. In classical Z F C {\displaystyle {\mathsf {ZFC}}} , the Collection schema implies the Axiom schema of replacement. When making use of Powerset (and only then), they can be shown to be classically equivalent. While I Z F {\displaystyle {\mathsf {IZF}}} is based on intuitionistic rather than classical logic, it is considered impredicative. It allows formation of sets via a power set operation and using the general Axiom of Separation with any proposition, including ones which contain quantifiers which are not bounded. Thus new sets can be formed in terms of the universe of all sets, distancing the theory from the bottom-up constructive perspective. So it is even easier to define sets { x ∈ B ∣ Q ( x ) } {\displaystyle \{x\in B\mid Q(x)\}} with undecidable membership, namely by making use of undecidable predicates defined on a set. The power set axiom further implies the existence of a set of truth values. In the presence of excluded middle, this set has two elements. In the absence of it, the set of truth values is also considered impredicative. The axioms of I Z F {\displaystyle {\mathsf {IZF}}} are strong enough so that full PEM is already implied by PEM for bounded formulas. See also the previous discussion in the section on the Exponentiation axiom. And by the discussion about Separation, it is thus already implied by the particular formula ∀ x . ( 0 ∈ x ∨ 0 ∉ x ) {\displaystyle \forall x.{\big (}0\in x\lor 0\notin x{\big )}} , the principle that knowledge of membership of 0 {\displaystyle 0} shall always be decidable, no matter the set. ==== Metalogic ==== As implied above, the subcountability property cannot be adopted for all sets, given the theory proves P ω {\displaystyle {\mathcal {P}}_{\omega }} to be a set. The theory has many of the nice numerical existence properties and is e.g. consistent with Church's thesis principle as well as with ω → ω {\displaystyle \omega \to \omega } being subcountable. It also has the disjunctive property. I Z F {\displaystyle {\mathsf {IZF}}} with Replacement instead of Collection has the general existence property, even when adopting relativized dependent choice on top of it all. But just I Z F {\displaystyle {\mathsf {IZF}}} as formulated does not. The combination of schemas including full separation spoils it. Even without PEM, the proof theoretic strength of I Z F {\displaystyle {\mathsf {IZF}}} equals that of Z F {\displaystyle {\mathsf {ZF}}} . And H A {\displaystyle {\mathsf {HA}}} proves them equiconsistent and they prove the same Π 1 0 {\displaystyle \Pi _{1}^{0}} -sentences. === Intuitionistic Z === Again on the weaker end, as with its historical counterpart Zermelo set theory, one may denote by I Z {\displaystyle {\mathsf {IZ}}} the intuitionistic theory set up like I Z F {\displaystyle {\mathsf {IZF}}} but without Replacement, Collection or Induction. === Intuitionistic KP === Let us mention another very weak theory that has been investigated, namely Intuitionistic (or constructive) Kripke–Platek set theory I K P {\displaystyle {\mathsf {IKP}}} . It has not only Separation but also Collection restricted to Δ 0 {\displaystyle \Delta _{0}} -formulas, i.e. it is similar to B C S T {\displaystyle {\mathsf {BCST}}} but with Induction instead of full Replacement. The theory does not fit into the hierarchy as presented above, simply because it has Axiom schema of Set Induction from the start. This enables theorems involving the class of ordinals. The theory has the disjunction property. Of course, weaker versions of I K P {\displaystyle {\mathsf {IKP}}} are obtained by restricting the induction schema to narrower classes of formulas, say Σ 1 {\displaystyle \Sigma _{1}} . The theory is especially weak when studied without Infinity. == Sorted theories == === Constructive set theory === As he presented it, Myhill's system C S T {\displaystyle {\mathsf {CST}}} is a theory using constructive first-order logic with identity and two more sorts beyond sets, namely natural numbers and functions. Its axioms are: The usual Axiom of Extensionality for sets, as well as one for functions, and the usual Axiom of union. The Axiom of restricted, or predicative, separation, which is a weakened form of the Separation axiom from classical set theory, requiring that any quantifications be bounded to another set, as discussed. A form of the Axiom of Infinity asserting that the collection of natural numbers (for which he introduces a constant ω {\displaystyle \omega } ) is in fact a set. The axiom of Exponentiation, asserting that for any two sets, there is a third set which contains all (and only) the functions whose domain is the first set, and whose range is the second set. This is a greatly weakened form of the Axiom of power set in classical set theory, to which Myhill, among others, objected on the grounds of its impredicativity. And furthermore: The usual Peano axioms for natural numbers. Axioms asserting that the domain and range of a function are both sets. Additionally, an Axiom of non-choice asserts the existence of a choice function in cases where the choice is already made. Together these act like the usual Replacement axiom in classical set theory. One can roughly identify the strength of this theory with a constructive subtheories of Z F {\displaystyle {\mathsf {ZF}}} when comparing with the previous sections. And finally the theory adopts An Axiom of dependent choice, which is much weaker than the usual Axiom of choice. === Bishop style set theory === Set theory in the flavor of Errett Bishop's constructivist school mirrors that of Myhill, but is set up in a way that sets come equipped with relations that govern their discreteness. Commonly, Dependent Choice is adopted. A lot of analysis and module theory has been developed in this context. === Category theories === Not all formal logic theories of sets need to axiomize the binary membership predicate " ∈ {\displaystyle \in } " directly. A theory like the Elementary Theory of the Categories Of Set ( E T C S {\displaystyle {\mathsf {ETCS}}} ), e.g. capturing pairs of composable mappings between objects, can also be expressed with a constructive background logic. Category theory can be set up as a theory of arrows and objects, although first-order axiomatizations only in terms of arrows are possible. Beyond that, topoi also have internal languages that can be intuitionistic themselves and capture a notion of sets. Good models of constructive set theories in category theory are the pretoposes mentioned in the Exponentiation section. For some good set theory, this may require enough projectives, an axiom about surjective "presentations" of set, implying Countable and Dependent Choice. == See also == == References == == Further reading == Troelstra, Anne; van Dalen, Dirk (1988). Constructivism in Mathematics, Vol. 2. Studies in Logic and the Foundations of Mathematics. p. 619. ISBN 978-0-444-70358-3. Aczel, P. and Rathjen, M. (2001). Notes on constructive set theory. Technical Report 40, 2000/2001. Mittag-Leffler Institute, Sweden. == External links == Crosilla, Laura (13 February 2019). "Set Theory: Constructive and Intuitionistic ZF". In Zalta, Edward N. (ed.). Stanford Encyclopedia of Philosophy. Van den Berg, Benno (7 September 2012). "Constructive set theory – an overview" (PDF). Slides from Heyting dag, Amsterdam
Wikipedia/Constructive_set_theory
A semantic theory of truth is a theory of truth in the philosophy of language which holds that truth is a property of sentences. == Origin == The semantic conception of truth, which is related in different ways to both the correspondence and deflationary conceptions, is due to work by Polish logician Alfred Tarski. Tarski, in "On the Concept of Truth in Formal Languages" (1935), attempted to formulate a new theory of truth in order to resolve the liar paradox. In the course of this he made several metamathematical discoveries, most notably Tarski's undefinability theorem using the same formal technique Kurt Gödel used in his incompleteness theorems. Roughly, this states that a truth-predicate satisfying Convention T for the sentences of a given language cannot be defined within that language. == Tarski's theory of truth == To formulate linguistic theories without semantic paradoxes such as the liar paradox, it is generally necessary to distinguish the language that one is talking about (the object language) from the language that one is using to do the talking (the metalanguage). In the following, quoted text is use of the object language, while unquoted text is use of the metalanguage; a quoted sentence (such as "P") is always the metalanguage's name for a sentence, such that this name is simply the sentence P rendered in the object language. In this way, the metalanguage can be used to talk about the object language; Tarski's theory of truth (Alfred Tarski 1935) demanded that the object language be contained in the metalanguage. Tarski's material adequacy condition, also known as Convention T, holds that any viable theory of truth must entail, for every sentence "P", a sentence of the following form (known as "form (T)"): (1) "P" is true if, and only if, P. For example, (2) 'snow is white' is true if and only if snow is white. These sentences (1 and 2, etc.) have come to be called the "T-sentences". The reason they look trivial is that the object language and the metalanguage are both English; here is an example where the object language is German and the metalanguage is English: (3) 'Schnee ist weiß' is true if and only if snow is white. It is important to note that as Tarski originally formulated it, this theory applies only to formal languages, cf. also semantics of first-order logic. He gave a number of reasons for not extending his theory to natural languages, including the problem that there is no systematic way of deciding whether a given sentence of a natural language is well-formed, and that a natural language is closed (that is, it can describe the semantic characteristics of its own elements). But Tarski's approach was extended by Davidson into an approach to theories of meaning for natural languages, which involves treating "truth" as a primitive, rather than a defined, concept. (See truth-conditional semantics.) Tarski developed the theory to give an inductive definition of truth as follows. (See T-schema) For a language L containing ¬ ("not"), ∧ ("and"), ∨ ("or"), ∀ ("for all"), and ∃ ("there exists"), Tarski's inductive definition of truth looks like this: (1) A primitive statement "A" is true if, and only if, A. (2) "¬A" is true if, and only if, "A" is not true. (3) "A∧B" is true if, and only if, "A" is true and "B" is true. (4) "A∨B" is true if, and only if, "A" is true or "B" is true or ("A" is true and "B" is true). (5) "∀x(Fx)" is true if, and only if, for all objects x, "Fx" is true. (6) "∃x(Fx)" is true if, and only if, there is an object x for which "Fx" is true. These explain how the truth conditions of complex sentences (built up from connectives and quantifiers) can be reduced to the truth conditions of their constituents. The simplest constituents are atomic sentences. A contemporary semantic definition of truth would define truth for the atomic sentences as follows: An atomic sentence F(x1,...,xn) is true (relative to an assignment of values to the variables x1, ..., xn)) if the corresponding values of variables bear the relation expressed by the predicate F. Tarski himself defined truth for atomic sentences in a variant way that does not use any technical terms from semantics, such as the "expressed by" above. This is because he wanted to define these semantic terms in the context of truth. Therefore it would be circular to use one of them in the definition of truth itself. Tarski's semantic conception of truth plays an important role in modern logic and also in contemporary philosophy of language. It is a rather controversial point whether Tarski's semantic theory should be counted either as a correspondence theory or as a deflationary theory. == Kripke's theory of truth == Kripke's theory of truth (Saul Kripke 1975) is based on partial logic (a logic of partially defined truth predicates instead of Tarski's logic of totally defined truth predicates) with the strong Kleene evaluation scheme. == See also == Disquotational principle Semantics of logic T-schema Triune continuum paradigm == References == == Further reading == Simon Blackburn and Keith Simmons, eds., 1999. Truth. Oxford University Press, ISBN 0-19-875250-4. Michael K Butler, 2017. Deflationism and Semantic Theories of Truth. Pendlebury Press, ISBN 0993594549. Wilfrid Hodges, 2001. Tarski's truth definitions. In the Stanford Encyclopedia of Philosophy. Richard Kirkham, 1992. Theories of Truth. Bradford Books, ISBN 0-262-61108-2. Saul Kripke, 1975. "Outline of a Theory of Truth". Journal of Philosophy, 72: 690–716. Alfred Tarski, 1935. "The Concept of Truth in Formalized Languages". Logic, Semantics, Metamathematics, Indianapolis: Hackett 1983, 2nd edition, 152–278. Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4. == External links == Semantic Theory of Truth, Internet Encyclopedia of Philosophy Tarski's Truth Definitions (an entry of Stanford Encyclopedia of Philosophy) Alfred Tarski, 1944. The Semantic Conception of Truth and the Foundations of Semantics. Philosophy and Phenomenological Research 4.
Wikipedia/Tarski's_theory_of_truth
Electronic design automation (EDA), also referred to as electronic computer-aided design (ECAD), is a category of software tools for designing electronic systems such as integrated circuits and printed circuit boards. The tools work together in a design flow that chip designers use to design and analyze entire semiconductor chips. Since a modern semiconductor chip can have billions of components, EDA tools are essential for their design; this article in particular describes EDA specifically with respect to integrated circuits (ICs). == History == === Early days === The earliest electronic design automation is attributed to IBM with the documentation of its 700 series computers in the 1950s. Prior to the development of EDA, integrated circuits were designed by hand and manually laid out. Some advanced shops used geometric software to generate tapes for a Gerber photoplotter, responsible for generating a monochromatic exposure image, but even those copied digital recordings of mechanically drawn components. The process was fundamentally graphic, with the translation from electronics to graphics done manually; the best-known company from this era was Calma, whose GDSII format is still in use today. By the mid-1970s, developers started to automate circuit design in addition to drafting and the first placement and routing tools were developed; as this occurred, the proceedings of the Design Automation Conference catalogued the large majority of the developments of the time. The next era began following the publication of "Introduction to VLSI Systems" by Carver Mead and Lynn Conway in 1980, and is considered the standard textbook for chip design. The result was an increase in the complexity of the chips that could be designed, with improved access to design verification tools that used logic simulation. The chips were easier to lay out and more likely to function correctly, since their designs could be simulated more thoroughly prior to construction. Although the languages and tools have evolved, this general approach of specifying the desired behavior in a textual programming language and letting the tools derive the detailed physical design remains the basis of digital IC design today. The earliest EDA tools were produced academically. One of the most famous was the "Berkeley VLSI Tools Tarball", a set of UNIX utilities used to design early VLSI systems. Widely used were the Espresso heuristic logic minimizer, responsible for circuit complexity reductions and Magic, a computer-aided design platform. Another crucial development was the formation of MOSIS, a consortium of universities and fabricators that developed an inexpensive way to train student chip designers by producing real integrated circuits. The basic concept was to use reliable, low-cost, relatively low-technology IC processes and pack a large number of projects per wafer, with several copies of chips from each project remaining preserved. Cooperating fabricators either donated the processed wafers or sold them at cost, as they saw the program as helpful to their own long-term growth. === Commercial birth === 1981 marked the beginning of EDA as an industry. For many years, the larger electronic companies, such as Hewlett-Packard, Tektronix and Intel, had pursued EDA internally, with managers and developers beginning to spin out of these companies to concentrate on EDA as a business. Daisy Systems, Mentor Graphics and Valid Logic Systems were all founded around this time and collectively referred to as DMV. In 1981, the U.S. Department of Defense additionally began funding of VHDL as a hardware description language. Within a few years, there were many companies specializing in EDA, each with a slightly different emphasis. The first trade show for EDA was held at the Design Automation Conference in 1984 and in 1986, Verilog, another popular high-level design language, was first introduced as a hardware description language by Gateway Design Automation. Simulators quickly followed these introductions, permitting direct simulation of chip designs and executable specifications. Within several years, back-ends were developed to perform logic synthesis. === Modern day === Current digital flows are extremely modular, with front ends producing standardized design descriptions that compile into invocations of units similar to cells without regard to their individual technology. Cells implement logic or other electronic functions via the utilisation of a particular integrated circuit technology. Fabricators generally provide libraries of components for their production processes, with simulation models that fit standard simulation tools. Most analog circuits are still designed in a manual fashion, requiring specialist knowledge that is unique to analog design (such as matching concepts). Hence, analog EDA tools are far less modular, since many more functions are required, they interact more strongly and the components are, in general, less ideal. EDA for electronics has rapidly increased in importance with the continuous scaling of semiconductor technology. Some users are foundry operators, who operate the semiconductor fabrication facilities ("fabs") and additional individuals responsible for utilising the technology design-service companies who use EDA software to evaluate an incoming design for manufacturing readiness. EDA tools are also used for programming design functionality into FPGAs or field-programmable gate arrays, customisable integrated circuit designs. == Software focuses == === Design === Design flow primarily remains characterised via several primary components; these include: High-level synthesis (additionally known as behavioral synthesis or algorithmic synthesis) – The high-level design description (e.g. in C/C++) is converted into RTL or the register transfer level, responsible for representing circuitry via the utilisation of interactions between registers. Logic synthesis – The translation of RTL design description (e.g. written in Verilog or VHDL) into a discrete netlist or representation of logic gates. Schematic capture – For standard cell digital, analog, RF-like Capture CIS in Orcad by Cadence and ISIS in Proteus. Layout – usually schematic-driven layout, like Layout in Orcad by Cadence, ARES in Proteus === Simulation === Transistor simulation – low-level transistor-simulation of a schematic/layout's behavior, accurate at device-level. Logic simulation – digital-simulation of an RTL or gate-netlist's digital (Boolean 0/1) behavior, accurate at Boolean-level. Behavioral simulation – high-level simulation of a design's architectural operation, accurate at cycle-level or interface-level. Hardware emulation – Use of special purpose hardware to emulate the logic of a proposed design. Can sometimes be plugged into a system in place of a yet-to-be-built chip; this is called in-circuit emulation. Technology CAD simulate and analyze the underlying process technology. Electrical properties of devices are derived directly from device physics === Analysis and verification === Functional verification: ensures logic design matches specifications and executes tasks correctly. Includes dynamic functional verification via simulation, emulation, and prototypes. RTL Linting for adherence to coding rules such as syntax, semantics, and style. Clock domain crossing verification (CDC check): similar to linting, but these checks/tools specialize in detecting and reporting potential issues like data loss, meta-stability due to use of multiple clock domains in the design. Formal verification, also model checking: attempts to prove, by mathematical methods, that the system has certain desired properties, and that some undesired effects (such as deadlock) cannot occur. Equivalence checking: algorithmic comparison between a chip's RTL-description and synthesized gate-netlist, to ensure functional equivalence at the logical level. Static timing analysis: analysis of the timing of a circuit in an input-independent manner, hence finding a worst case over all possible inputs. Layout extraction: starting with a proposed layout, compute the (approximate) electrical characteristics of every wire and device. Often used in conjunction with static timing analysis above to estimate the performance of the completed chip. Electromagnetic field solvers, or just field solvers, solve Maxwell's equations directly for cases of interest in IC and PCB design. They are known for being slower but more accurate than the layout extraction above. Physical verification, PV: checking if a design is physically manufacturable, and that the resulting chips will not have any function-preventing physical defects, and will meet original specifications. === Manufacturing preparation === Mask data preparation or MDP - The generation of actual lithography photomasks, utilised to physically manufacture the chip. Chip finishing which includes custom designations and structures to improve manufacturability of the layout. Examples of the latter are a seal ring and filler structures. Producing a reticle layout with test patterns and alignment marks. Layout-to-mask preparation that enhances layout data with graphics operations, such as resolution enhancement techniques (RET) – methods for increasing the quality of the final photomask. This also includes optical proximity correction (OPC) or inverse lithography technology (ILT) – the up-front compensation for diffraction and interference effects occurring later when chip is manufactured using this mask. Mask generation – The generation of flat mask image from hierarchical design. Automatic test pattern generation or ATPG – The generation of pattern data systematically to exercise as many logic-gates and other components as possible. Built-in self-test or BIST – The installation of self-contained test-controllers to automatically test a logic or memory structure in the design === Functional safety === Functional safety analysis, systematic computation of failure in time (FIT) rates and diagnostic coverage metrics for designs in order to meet the compliance requirements for the desired safety integrity levels. Functional safety synthesis, add reliability enhancements to structured elements (modules, RAMs, ROMs, register files, FIFOs) to improve fault detection / fault tolerance. This includes (not limited to) addition of error detection and / or correction codes (Hamming), redundant logic for fault detection and fault tolerance (duplicate / triplicate) and protocol checks (interface parity, address alignment, beat count) Functional safety verification, running of a fault campaign, including insertion of faults into the design and verification that the safety mechanism reacts in an appropriate manner for the faults that are deemed covered. == Companies == === Current === Market capitalization and company name as of March 2023: $57.87 billion – Synopsys $56.68 billion – Cadence Design Systems $24.98 billion – Ansys AU$4.88 billion – Altium ¥77.25 billion – Zuken === Defunct === Market capitalization and company name as of December 2011: $2.33 billion – Mentor Graphics; Siemens acquired Mentor in 2017 and renamed as Siemens EDA in 2021 $507 million – Magma Design Automation; Synopsys acquired Magma in February 2012 NT$6.44 billion – SpringSoft; Synopsys acquired SpringSoft in August 2012 === Acquisitions === Many EDA companies acquire small companies with software or other technology that can be adapted to their core business. Most of the market leaders are amalgamations of many smaller companies and this trend is helped by the tendency of software companies to design tools as accessories that fit naturally into a larger vendor's suite of programs on digital circuitry; many new tools incorporate analog design and mixed systems. This is happening due to a trend to place entire electronic systems on a single chip. == Technical conferences == Design Automation Conference International Conference on Computer-Aided Design Design Automation and Test in Europe Asia and South Pacific Design Automation Conference Symposia on VLSI Technology and Circuits == See also == Computer-aided design (CAD) Circuit design EDA database Foundations and Trends in Electronic Design Automation Signoff (electronic design automation) Comparison of EDA software Platform-based design Silicon compiler == References == Notes
Wikipedia/Electronic_design_automation
Proof theory is a major branch of mathematical logic and theoretical computer science within which proofs are treated as formal mathematical objects, facilitating their analysis by mathematical techniques. Proofs are typically presented as inductively defined data structures such as lists, boxed lists, or trees, which are constructed according to the axioms and rules of inference of a given logical system. Consequently, proof theory is syntactic in nature, in contrast to model theory, which is semantic in nature. Some of the major areas of proof theory include structural proof theory, ordinal analysis, provability logic, reverse mathematics, proof mining, automated theorem proving, and proof complexity. Much research also focuses on applications in computer science, linguistics, and philosophy. == History == Although the formalisation of logic was much advanced by the work of such figures as Gottlob Frege, Giuseppe Peano, Bertrand Russell, and Richard Dedekind, the story of modern proof theory is often seen as being established by David Hilbert, who initiated what is called Hilbert's program in the Foundations of Mathematics. The central idea of this program was that if we could give finitary proofs of consistency for all the sophisticated formal theories needed by mathematicians, then we could ground these theories by means of a metamathematical argument, which shows that all of their purely universal assertions (more technically their provable Π 1 0 {\displaystyle \Pi _{1}^{0}} sentences) are finitarily true; once so grounded we do not care about the non-finitary meaning of their existential theorems, regarding these as pseudo-meaningful stipulations of the existence of ideal entities. The failure of the program was induced by Kurt Gödel's incompleteness theorems, which showed that any ω-consistent theory that is sufficiently strong to express certain simple arithmetic truths, cannot prove its own consistency, which on Gödel's formulation is a Π 1 0 {\displaystyle \Pi _{1}^{0}} sentence. However, modified versions of Hilbert's program emerged and research has been carried out on related topics. This has led, in particular, to: Refinement of Gödel's result, particularly J. Barkley Rosser's refinement, weakening the above requirement of ω-consistency to simple consistency; Axiomatisation of the core of Gödel's result in terms of a modal language, provability logic; Transfinite iteration of theories, due to Alan Turing and Solomon Feferman; The discovery of self-verifying theories, systems strong enough to talk about themselves, but too weak to carry out the diagonal argument that is the key to Gödel's unprovability argument. In parallel to the rise and fall of Hilbert's program, the foundations of structural proof theory were being founded. Jan Łukasiewicz suggested in 1926 that one could improve on Hilbert systems as a basis for the axiomatic presentation of logic if one allowed the drawing of conclusions from assumptions in the inference rules of the logic. In response to this, Stanisław Jaśkowski (1929) and Gerhard Gentzen (1934) independently provided such systems, called calculi of natural deduction, with Gentzen's approach introducing the idea of symmetry between the grounds for asserting propositions, expressed in introduction rules, and the consequences of accepting propositions in the elimination rules, an idea that has proved very important in proof theory. Gentzen (1934) further introduced the idea of the sequent calculus, a calculus advanced in a similar spirit that better expressed the duality of the logical connectives, and went on to make fundamental advances in the formalisation of intuitionistic logic, and provide the first combinatorial proof of the consistency of Peano arithmetic. Together, the presentation of natural deduction and the sequent calculus introduced the fundamental idea of analytic proof to proof theory. == Structural proof theory == Structural proof theory is the subdiscipline of proof theory that studies the specifics of proof calculi. The three most well-known styles of proof calculi are: The Hilbert calculi The natural deduction calculi The sequent calculi Each of these can give a complete and axiomatic formalization of propositional or predicate logic of either the classical or intuitionistic flavour, almost any modal logic, and many substructural logics, such as relevance logic or linear logic. Indeed, it is unusual to find a logic that resists being represented in one of these calculi. Proof theorists are typically interested in proof calculi that support a notion of analytic proof. The notion of analytic proof was introduced by Gentzen for the sequent calculus; there the analytic proofs are those that are cut-free. Much of the interest in cut-free proofs comes from the subformula property: every formula in the end sequent of a cut-free proof is a subformula of one of the premises. This allows one to show consistency of the sequent calculus easily; if the empty sequent were derivable it would have to be a subformula of some premise, which it is not. Gentzen's midsequent theorem, the Craig interpolation theorem, and Herbrand's theorem also follow as corollaries of the cut-elimination theorem. Gentzen's natural deduction calculus also supports a notion of analytic proof, as shown by Dag Prawitz. The definition is slightly more complex: we say the analytic proofs are the normal forms, which are related to the notion of normal form in term rewriting. More exotic proof calculi such as Jean-Yves Girard's proof nets also support a notion of analytic proof. A particular family of analytic proofs arising in reductive logic are focused proofs which characterise a large family of goal-directed proof-search procedures. The ability to transform a proof system into a focused form is a good indication of its syntactic quality, in a manner similar to how admissibility of cut shows that a proof system is syntactically consistent. Structural proof theory is connected to type theory by means of the Curry–Howard correspondence, which observes a structural analogy between the process of normalisation in the natural deduction calculus and beta reduction in the typed lambda calculus. This provides the foundation for the intuitionistic type theory developed by Per Martin-Löf, and is often extended to a three way correspondence, the third leg of which are the cartesian closed categories. Other research topics in structural theory include analytic tableau, which apply the central idea of analytic proof from structural proof theory to provide decision procedures and semi-decision procedures for a wide range of logics, and the proof theory of substructural logics. == Ordinal analysis == Ordinal analysis is a powerful technique for providing combinatorial consistency proofs for subsystems of arithmetic, analysis, and set theory. Gödel's second incompleteness theorem is often interpreted as demonstrating that finitistic consistency proofs are impossible for theories of sufficient strength. Ordinal analysis allows one to measure precisely the infinitary content of the consistency of theories. For a consistent recursively axiomatized theory T, one can prove in finitistic arithmetic that the well-foundedness of a certain transfinite ordinal implies the consistency of T. Gödel's second incompleteness theorem implies that the well-foundedness of such an ordinal cannot be proved in the theory T. Consequences of ordinal analysis include (1) consistency of subsystems of classical second order arithmetic and set theory relative to constructive theories, (2) combinatorial independence results, and (3) classifications of provably total recursive functions and provably well-founded ordinals. Ordinal analysis was originated by Gentzen, who proved the consistency of Peano Arithmetic using transfinite induction up to ordinal ε0. Ordinal analysis has been extended to many fragments of first and second order arithmetic and set theory. One major challenge has been the ordinal analysis of impredicative theories. The first breakthrough in this direction was Takeuti's proof of the consistency of Π11-CA0 using the method of ordinal diagrams. == Provability logic == Provability logic is a modal logic, in which the box operator is interpreted as 'it is provable that'. The point is to capture the notion of a proof predicate of a reasonably rich formal theory. As basic axioms of the provability logic GL (Gödel-Löb), which captures provable in Peano Arithmetic, one takes modal analogues of the Hilbert-Bernays derivability conditions and Löb's theorem (if it is provable that the provability of A implies A, then A is provable). Some of the basic results concerning the incompleteness of Peano Arithmetic and related theories have analogues in provability logic. For example, it is a theorem in GL that if a contradiction is not provable then it is not provable that a contradiction is not provable (Gödel's second incompleteness theorem). There are also modal analogues of the fixed-point theorem. Robert Solovay proved that the modal logic GL is complete with respect to Peano Arithmetic. That is, the propositional theory of provability in Peano Arithmetic is completely represented by the modal logic GL. This straightforwardly implies that propositional reasoning about provability in Peano Arithmetic is complete and decidable. Other research in provability logic has focused on first-order provability logic, polymodal provability logic (with one modality representing provability in the object theory and another representing provability in the meta-theory), and interpretability logics intended to capture the interaction between provability and interpretability. Some very recent research has involved applications of graded provability algebras to the ordinal analysis of arithmetical theories. == Reverse mathematics == Reverse mathematics is a program in mathematical logic that seeks to determine which axioms are required to prove theorems of mathematics. The field was founded by Harvey Friedman. Its defining method can be described as "going backwards from the theorems to the axioms", in contrast to the ordinary mathematical practice of deriving theorems from axioms. The reverse mathematics program was foreshadowed by results in set theory such as the classical theorem that the axiom of choice and Zorn's lemma are equivalent over ZF set theory. The goal of reverse mathematics, however, is to study possible axioms of ordinary theorems of mathematics rather than possible axioms for set theory. In reverse mathematics, one starts with a framework language and a base theory—a core axiom system—that is too weak to prove most of the theorems one might be interested in, but still powerful enough to develop the definitions necessary to state these theorems. For example, to study the theorem "Every bounded sequence of real numbers has a supremum" it is necessary to use a base system that can speak of real numbers and sequences of real numbers. For each theorem that can be stated in the base system but is not provable in the base system, the goal is to determine the particular axiom system (stronger than the base system) that is necessary to prove that theorem. To show that a system S is required to prove a theorem T, two proofs are required. The first proof shows T is provable from S; this is an ordinary mathematical proof along with a justification that it can be carried out in the system S. The second proof, known as a reversal, shows that T itself implies S; this proof is carried out in the base system. The reversal establishes that no axiom system S′ that extends the base system can be weaker than S while still proving T. One striking phenomenon in reverse mathematics is the robustness of the Big Five axiom systems. In order of increasing strength, these systems are named by the initialisms RCA0, WKL0, ACA0, ATR0, and Π11-CA0. Nearly every theorem of ordinary mathematics that has been reverse mathematically analyzed has been proven equivalent to one of these five systems. Much recent research has focused on combinatorial principles that do not fit neatly into this framework, like RT22 (Ramsey's theorem for pairs). Research in reverse mathematics often incorporates methods and techniques from recursion theory as well as proof theory. == Functional interpretations == Functional interpretations are interpretations of non-constructive theories in functional ones. Functional interpretations usually proceed in two stages. First, one "reduces" a classical theory C to an intuitionistic one I. That is, one provides a constructive mapping that translates the theorems of C to the theorems of I. Second, one reduces the intuitionistic theory I to a quantifier free theory of functionals F. These interpretations contribute to a form of Hilbert's program, since they prove the consistency of classical theories relative to constructive ones. Successful functional interpretations have yielded reductions of infinitary theories to finitary theories and impredicative theories to predicative ones. Functional interpretations also provide a way to extract constructive information from proofs in the reduced theory. As a direct consequence of the interpretation one usually obtains the result that any recursive function whose totality can be proven either in I or in C is represented by a term of F. If one can provide an additional interpretation of F in I, which is sometimes possible, this characterization is in fact usually shown to be exact. It often turns out that the terms of F coincide with a natural class of functions, such as the primitive recursive or polynomial-time computable functions. Functional interpretations have also been used to provide ordinal analyses of theories and classify their provably recursive functions. The study of functional interpretations began with Kurt Gödel's interpretation of intuitionistic arithmetic in a quantifier-free theory of functionals of finite type. This interpretation is commonly known as the Dialectica interpretation. Together with the double-negation interpretation of classical logic in intuitionistic logic, it provides a reduction of classical arithmetic to intuitionistic arithmetic. == Formal and informal proof == The informal proofs of everyday mathematical practice are unlike the formal proofs of proof theory. They are rather like high-level sketches that would allow an expert to reconstruct a formal proof at least in principle, given enough time and patience. For most mathematicians, writing a fully formal proof is too pedantic and long-winded to be in common use. Formal proofs are constructed with the help of computers in interactive theorem proving. Significantly, these proofs can be checked automatically, also by computer. Checking formal proofs is usually simple, whereas finding proofs (automated theorem proving) is generally hard. An informal proof in the mathematics literature, by contrast, requires weeks of peer review to be checked, and may still contain errors. == Proof-theoretic semantics == In linguistics, type-logical grammar, categorial grammar and Montague grammar apply formalisms based on structural proof theory to give a formal natural language semantics. == See also == Intermediate logic Model theory Proof (truth) Proof techniques Sequent calculus == Notes == == References == J. Avigad and E.H. Reck (2001). "'Clarifying the nature of the infinite': the development of metamathematics and proof theory". Carnegie-Mellon Technical Report CMU-PHIL-120. Barwise, Jon (1977). Handbook of Mathematical Logic. Studies in Logic and the Foundations of Mathematics. Vol. 90. North-Holland Publishing Company. ISBN 072042285X. LCCN 76026032. OCLC 2347202. (accessible to patrons with print disabilities) S. Buss, ed. (1998) Handbook of Proof Theory. Elsevier. G. Gentzen (1935/1969). "Investigations into logical deduction". In M. E. Szabo, ed. Collected Papers of Gerhard Gentzen. North-Holland. Translated by Szabo from "Untersuchungen über das logische Schliessen", Mathematisches Zeitschrift v. 39, pp. 176–210, 405 431. Girard, J.-Y.; Taylor, P.; Lafont, Y. (2003) [1989]. Proofs and Types (PDF). Cambridge University Press. ISBN 0521371813. Prawitz, Dag (1965). Natural Deduction: A Proof-Theoretic Study. Acta Universitatis Stockholmiensis; Stockholm Studies in Philosophy, 3. Stockholm, Göteborg, Uppsala: Almqvist & Wiksell. OCLC 912927896. Simpson, S. G. (2010). Subsystems of Second-order Arithmetic. Perspectives in logic (2 ed.). Cambridge University Press. ISBN 9780521150149. OCLC 528432422. A. S. Troelstra and H. Schwichtenberg (1996). Basic Proof Theory, Cambridge Tracts in Theoretical Computer Science, Cambridge University Press, ISBN 0-521-77911-1. Wang, Hao (1981). Popular Lectures on Mathematical Logic. Van Nostrand Reinhold Company. ISBN 9780442231095. OCLC 6087107. == External links == "Proof theory", Encyclopedia of Mathematics, EMS Press, 2001 [1994] J. von Plato (2008). The Development of Proof Theory. Stanford Encyclopedia of Philosophy.
Wikipedia/Proof_theory
In set theory, the complement of a set A, often denoted by A c {\displaystyle A^{c}} (or A′), is the set of elements not in A. When all elements in the universe, i.e. all elements under consideration, are considered to be members of a given set U, the absolute complement of A is the set of elements in U that are not in A. The relative complement of A with respect to a set B, also termed the set difference of B and A, written B ∖ A , {\displaystyle B\setminus A,} is the set of elements in B that are not in A. == Absolute complement == === Definition === If A is a set, then the absolute complement of A (or simply the complement of A) is the set of elements not in A (within a larger set that is implicitly defined). In other words, let U be a set that contains all the elements under study; if there is no need to mention U, either because it has been previously specified, or it is obvious and unique, then the absolute complement of A is the relative complement of A in U: A c = U ∖ A = { x ∈ U : x ∉ A } . {\displaystyle A^{c}=U\setminus A=\{x\in U:x\notin A\}.} The absolute complement of A is usually denoted by A c {\displaystyle A^{c}} . Other notations include A ¯ , A ′ , {\displaystyle {\overline {A}},A',} ∁ U A , and ∁ A . {\displaystyle \complement _{U}A,{\text{ and }}\complement A.} === Examples === Assume that the universe is the set of integers. If A is the set of odd numbers, then the complement of A is the set of even numbers. If B is the set of multiples of 3, then the complement of B is the set of numbers congruent to 1 or 2 modulo 3 (or, in simpler terms, the integers that are not multiples of 3). Assume that the universe is the standard 52-card deck. If the set A is the suit of spades, then the complement of A is the union of the suits of clubs, diamonds, and hearts. If the set B is the union of the suits of clubs and diamonds, then the complement of B is the union of the suits of hearts and spades. When the universe is the universe of sets described in formalized set theory, the absolute complement of a set is generally not itself a set, but rather a proper class. For more info, see universal set. === Properties === Let A and B be two sets in a universe U. The following identities capture important properties of absolute complements: De Morgan's laws: ( A ∪ B ) c = A c ∩ B c . {\displaystyle \left(A\cup B\right)^{c}=A^{c}\cap B^{c}.} ( A ∩ B ) c = A c ∪ B c . {\displaystyle \left(A\cap B\right)^{c}=A^{c}\cup B^{c}.} Complement laws: A ∪ A c = U . {\displaystyle A\cup A^{c}=U.} A ∩ A c = ∅ . {\displaystyle A\cap A^{c}=\emptyset .} ∅ c = U . {\displaystyle \emptyset ^{c}=U.} U c = ∅ . {\displaystyle U^{c}=\emptyset .} If A ⊆ B , then B c ⊆ A c . {\displaystyle {\text{If }}A\subseteq B{\text{, then }}B^{c}\subseteq A^{c}.} (this follows from the equivalence of a conditional with its contrapositive). Involution or double complement law: ( A c ) c = A . {\displaystyle \left(A^{c}\right)^{c}=A.} Relationships between relative and absolute complements: A ∖ B = A ∩ B c . {\displaystyle A\setminus B=A\cap B^{c}.} ( A ∖ B ) c = A c ∪ B = A c ∪ ( B ∩ A ) . {\displaystyle (A\setminus B)^{c}=A^{c}\cup B=A^{c}\cup (B\cap A).} Relationship with a set difference: A c ∖ B c = B ∖ A . {\displaystyle A^{c}\setminus B^{c}=B\setminus A.} The first two complement laws above show that if A is a non-empty, proper subset of U, then {A, A∁} is a partition of U. == Relative complement == === Definition === If A and B are sets, then the relative complement of A in B, also termed the set difference of B and A, is the set of elements in B but not in A. The relative complement of A in B is denoted B ∖ A {\displaystyle B\setminus A} according to the ISO 31-11 standard. It is sometimes written B − A , {\displaystyle B-A,} but this notation is ambiguous, as in some contexts (for example, Minkowski set operations in functional analysis) it can be interpreted as the set of all elements b − a , {\displaystyle b-a,} where b is taken from B and a from A. Formally: B ∖ A = { x ∈ B : x ∉ A } . {\displaystyle B\setminus A=\{x\in B:x\notin A\}.} === Examples === { 1 , 2 , 3 } ∖ { 2 , 3 , 4 } = { 1 } . {\displaystyle \{1,2,3\}\setminus \{2,3,4\}=\{1\}.} { 2 , 3 , 4 } ∖ { 1 , 2 , 3 } = { 4 } . {\displaystyle \{2,3,4\}\setminus \{1,2,3\}=\{4\}.} If R {\displaystyle \mathbb {R} } is the set of real numbers and Q {\displaystyle \mathbb {Q} } is the set of rational numbers, then R ∖ Q {\displaystyle \mathbb {R} \setminus \mathbb {Q} } is the set of irrational numbers. === Properties === Let A, B, and C be three sets in a universe U. The following identities capture notable properties of relative complements: C ∖ ( A ∩ B ) = ( C ∖ A ) ∪ ( C ∖ B ) . {\displaystyle C\setminus (A\cap B)=(C\setminus A)\cup (C\setminus B).} C ∖ ( A ∪ B ) = ( C ∖ A ) ∩ ( C ∖ B ) . {\displaystyle C\setminus (A\cup B)=(C\setminus A)\cap (C\setminus B).} C ∖ ( B ∖ A ) = ( C ∩ A ) ∪ ( C ∖ B ) , {\displaystyle C\setminus (B\setminus A)=(C\cap A)\cup (C\setminus B),} with the important special case C ∖ ( C ∖ A ) = ( C ∩ A ) {\displaystyle C\setminus (C\setminus A)=(C\cap A)} demonstrating that intersection can be expressed using only the relative complement operation. ( B ∖ A ) ∩ C = ( B ∩ C ) ∖ A = B ∩ ( C ∖ A ) . {\displaystyle (B\setminus A)\cap C=(B\cap C)\setminus A=B\cap (C\setminus A).} ( B ∖ A ) ∪ C = ( B ∪ C ) ∖ ( A ∖ C ) . {\displaystyle (B\setminus A)\cup C=(B\cup C)\setminus (A\setminus C).} A ∖ A = ∅ . {\displaystyle A\setminus A=\emptyset .} ∅ ∖ A = ∅ . {\displaystyle \emptyset \setminus A=\emptyset .} A ∖ ∅ = A . {\displaystyle A\setminus \emptyset =A.} A ∖ U = ∅ . {\displaystyle A\setminus U=\emptyset .} If A ⊂ B {\displaystyle A\subset B} , then C ∖ A ⊃ C ∖ B {\displaystyle C\setminus A\supset C\setminus B} . A ⊇ B ∖ C {\displaystyle A\supseteq B\setminus C} is equivalent to C ⊇ B ∖ A {\displaystyle C\supseteq B\setminus A} . == Complementary relation == A binary relation R {\displaystyle R} is defined as a subset of a product of sets X × Y . {\displaystyle X\times Y.} The complementary relation R ¯ {\displaystyle {\bar {R}}} is the set complement of R {\displaystyle R} in X × Y . {\displaystyle X\times Y.} The complement of relation R {\displaystyle R} can be written R ¯ = ( X × Y ) ∖ R . {\displaystyle {\bar {R}}\ =\ (X\times Y)\setminus R.} Here, R {\displaystyle R} is often viewed as a logical matrix with rows representing the elements of X , {\displaystyle X,} and columns elements of Y . {\displaystyle Y.} The truth of a R b {\displaystyle aRb} corresponds to 1 in row a , {\displaystyle a,} column b . {\displaystyle b.} Producing the complementary relation to R {\displaystyle R} then corresponds to switching all 1s to 0s, and 0s to 1s for the logical matrix of the complement. Together with composition of relations and converse relations, complementary relations and the algebra of sets are the elementary operations of the calculus of relations. == LaTeX notation == In the LaTeX typesetting language, the command \setminus is usually used for rendering a set difference symbol, which is similar to a backslash symbol. When rendered, the \setminus command looks identical to \backslash, except that it has a little more space in front and behind the slash, akin to the LaTeX sequence \mathbin{\backslash}. A variant \smallsetminus is available in the amssymb package, but this symbol is not included separately in Unicode. The symbol ∁ {\displaystyle \complement } (as opposed to C {\displaystyle C} ) is produced by \complement. (It corresponds to the Unicode symbol U+2201 ∁ COMPLEMENT.) == See also == Algebra of sets – Identities and relationships involving sets Intersection (set theory) – Set of elements common to all of some sets List of set identities and relations – Equalities for combinations of sets Naive set theory – Informal set theories Symmetric difference – Elements in exactly one of two sets Union (set theory) – Set of elements in any of some sets == Notes == == References == Bourbaki, N. (1970). Théorie des ensembles (in French). Paris: Hermann. ISBN 978-3-540-34034-8. Devlin, Keith J. (1979). Fundamentals of contemporary set theory. Universitext. Springer. ISBN 0-387-90441-7. Zbl 0407.04003. Halmos, Paul R. (1960). Naive set theory. The University Series in Undergraduate Mathematics. van Nostrand Company. ISBN 9780442030643. Zbl 0087.04403. {{cite book}}: ISBN / Date incompatibility (help) == External links == Weisstein, Eric W. "Complement". MathWorld. Weisstein, Eric W. "Complement Set". MathWorld.
Wikipedia/Complement_(set_theory)
In theoretical physics, statistical field theory (SFT) is a theoretical framework that describes phase transitions. It does not denote a single theory but encompasses many models, including for magnetism, superconductivity, superfluidity, topological phase transition, wetting as well as non-equilibrium phase transitions. A SFT is any model in statistical mechanics where the degrees of freedom comprise a field or fields. In other words, the microstates of the system are expressed through field configurations. It is closely related to quantum field theory, which describes the quantum mechanics of fields, and shares with it many techniques, such as the path integral formulation and renormalization. If the system involves polymers, it is also known as polymer field theory. In fact, by performing a Wick rotation from Minkowski space to Euclidean space, many results of statistical field theory can be applied directly to its quantum equivalent. The correlation functions of a statistical field theory are called Schwinger functions, and their properties are described by the Osterwalder–Schrader axioms. Statistical field theories are widely used to describe systems in polymer physics or biophysics, such as polymer films, nanostructured block copolymers or polyelectrolytes. == Notes == == References == Itzykson, Claude; Drouffe, Jean-Michel (1991). Statistical Field Theory. Cambridge Monographs on Mathematical Physics. Vol. I, II. Cambridge University Press. ISBN 0-521-40806-7. ISBN 0-521-40805-9 Parisi, Giorgio (1998). Statistical Field Theory. Advanced Book Classics. Perseus Books. ISBN 978-0-7382-0051-4. Simon, Barry (1974). The P(φ)2 Euclidean (quantum) field theory. Princeton University Press. ISBN 0-691-08144-1. Glimm, James; Jaffe, Arthur (1987). Quantum Physics: A Functional Integral Point of View (2nd ed.). Springer. ISBN 0-387-96477-0. == External links == Problems in Statistical Field Theory Particle and Polymer Field Theory Group
Wikipedia/Statistical_field_theory
In physics, Hamiltonian mechanics is a reformulation of Lagrangian mechanics that emerged in 1833. Introduced by Sir William Rowan Hamilton, Hamiltonian mechanics replaces (generalized) velocities q ˙ i {\displaystyle {\dot {q}}^{i}} used in Lagrangian mechanics with (generalized) momenta. Both theories provide interpretations of classical mechanics and describe the same physical phenomena. Hamiltonian mechanics has a close relationship with geometry (notably, symplectic geometry and Poisson structures) and serves as a link between classical and quantum mechanics. == Overview == === Phase space coordinates (p, q) and Hamiltonian H === Let ( M , L ) {\displaystyle (M,{\mathcal {L}})} be a mechanical system with configuration space M {\displaystyle M} and smooth Lagrangian L . {\displaystyle {\mathcal {L}}.} Select a standard coordinate system ( q , q ˙ ) {\displaystyle ({\boldsymbol {q}},{\boldsymbol {\dot {q}}})} on M . {\displaystyle M.} The quantities p i ( q , q ˙ , t ) = def ∂ L / ∂ q ˙ i {\displaystyle \textstyle p_{i}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)~{\stackrel {\text{def}}{=}}~{\partial {\mathcal {L}}}/{\partial {\dot {q}}^{i}}} are called momenta. (Also generalized momenta, conjugate momenta, and canonical momenta). For a time instant t , {\displaystyle t,} the Legendre transformation of L {\displaystyle {\mathcal {L}}} is defined as the map ( q , q ˙ ) → ( p , q ) {\displaystyle ({\boldsymbol {q}},{\boldsymbol {\dot {q}}})\to \left({\boldsymbol {p}},{\boldsymbol {q}}\right)} which is assumed to have a smooth inverse ( p , q ) → ( q , q ˙ ) . {\displaystyle ({\boldsymbol {p}},{\boldsymbol {q}})\to ({\boldsymbol {q}},{\boldsymbol {\dot {q}}}).} For a system with n {\displaystyle n} degrees of freedom, the Lagrangian mechanics defines the energy function E L ( q , q ˙ , t ) = def ∑ i = 1 n q ˙ i ∂ L ∂ q ˙ i − L . {\displaystyle E_{\mathcal {L}}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)\,{\stackrel {\text{def}}{=}}\,\sum _{i=1}^{n}{\dot {q}}^{i}{\frac {\partial {\mathcal {L}}}{\partial {\dot {q}}^{i}}}-{\mathcal {L}}.} The Legendre transform of L {\displaystyle {\mathcal {L}}} turns E L {\displaystyle E_{\mathcal {L}}} into a function H ( p , q , t ) {\displaystyle {\mathcal {H}}({\boldsymbol {p}},{\boldsymbol {q}},t)} known as the Hamiltonian. The Hamiltonian satisfies H ( ∂ L ∂ q ˙ , q , t ) = E L ( q , q ˙ , t ) {\displaystyle {\mathcal {H}}\left({\frac {\partial {\mathcal {L}}}{\partial {\boldsymbol {\dot {q}}}}},{\boldsymbol {q}},t\right)=E_{\mathcal {L}}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)} which implies that H ( p , q , t ) = ∑ i = 1 n p i q ˙ i − L ( q , q ˙ , t ) , {\displaystyle {\mathcal {H}}({\boldsymbol {p}},{\boldsymbol {q}},t)=\sum _{i=1}^{n}p_{i}{\dot {q}}^{i}-{\mathcal {L}}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t),} where the velocities q ˙ = ( q ˙ 1 , … , q ˙ n ) {\displaystyle {\boldsymbol {\dot {q}}}=({\dot {q}}^{1},\ldots ,{\dot {q}}^{n})} are found from the ( n {\displaystyle n} -dimensional) equation p = ∂ L / ∂ q ˙ {\displaystyle \textstyle {\boldsymbol {p}}={\partial {\mathcal {L}}}/{\partial {\boldsymbol {\dot {q}}}}} which, by assumption, is uniquely solvable for ⁠ q ˙ {\displaystyle {\boldsymbol {\dot {q}}}} ⁠. The ( 2 n {\displaystyle 2n} -dimensional) pair ( p , q ) {\displaystyle ({\boldsymbol {p}},{\boldsymbol {q}})} is called phase space coordinates. (Also canonical coordinates). === From Euler–Lagrange equation to Hamilton's equations === In phase space coordinates ⁠ ( p , q ) {\displaystyle ({\boldsymbol {p}},{\boldsymbol {q}})} ⁠, the ( n {\displaystyle n} -dimensional) Euler–Lagrange equation ∂ L ∂ q − d d t ∂ L ∂ q ˙ = 0 {\displaystyle {\frac {\partial {\mathcal {L}}}{\partial {\boldsymbol {q}}}}-{\frac {d}{dt}}{\frac {\partial {\mathcal {L}}}{\partial {\dot {\boldsymbol {q}}}}}=0} becomes Hamilton's equations in 2 n {\displaystyle 2n} dimensions === From stationary action principle to Hamilton's equations === Let P ( a , b , x a , x b ) {\displaystyle {\mathcal {P}}(a,b,{\boldsymbol {x}}_{a},{\boldsymbol {x}}_{b})} be the set of smooth paths q : [ a , b ] → M {\displaystyle {\boldsymbol {q}}:[a,b]\to M} for which q ( a ) = x a {\displaystyle {\boldsymbol {q}}(a)={\boldsymbol {x}}_{a}} and q ( b ) = x b . {\displaystyle {\boldsymbol {q}}(b)={\boldsymbol {x}}_{b}.} The action functional S : P ( a , b , x a , x b ) → R {\displaystyle {\mathcal {S}}:{\mathcal {P}}(a,b,{\boldsymbol {x}}_{a},{\boldsymbol {x}}_{b})\to \mathbb {R} } is defined via S [ q ] = ∫ a b L ( t , q ( t ) , q ˙ ( t ) ) d t = ∫ a b ( ∑ i = 1 n p i q ˙ i − H ( p , q , t ) ) d t , {\displaystyle {\mathcal {S}}[{\boldsymbol {q}}]=\int _{a}^{b}{\mathcal {L}}(t,{\boldsymbol {q}}(t),{\dot {\boldsymbol {q}}}(t))\,dt=\int _{a}^{b}\left(\sum _{i=1}^{n}p_{i}{\dot {q}}^{i}-{\mathcal {H}}({\boldsymbol {p}},{\boldsymbol {q}},t)\right)\,dt,} where ⁠ q = q ( t ) {\displaystyle {\boldsymbol {q}}={\boldsymbol {q}}(t)} ⁠, and p = ∂ L / ∂ q ˙ {\displaystyle {\boldsymbol {p}}=\partial {\mathcal {L}}/\partial {\boldsymbol {\dot {q}}}} (see above). A path q ∈ P ( a , b , x a , x b ) {\displaystyle {\boldsymbol {q}}\in {\mathcal {P}}(a,b,{\boldsymbol {x}}_{a},{\boldsymbol {x}}_{b})} is a stationary point of S {\displaystyle {\mathcal {S}}} (and hence is an equation of motion) if and only if the path ( p ( t ) , q ( t ) ) {\displaystyle ({\boldsymbol {p}}(t),{\boldsymbol {q}}(t))} in phase space coordinates obeys the Hamilton equations. === Basic physical interpretation === A simple interpretation of Hamiltonian mechanics comes from its application on a one-dimensional system consisting of one nonrelativistic particle of mass m. The value H ( p , q ) {\displaystyle H(p,q)} of the Hamiltonian is the total energy of the system, in this case the sum of kinetic and potential energy, traditionally denoted T and V, respectively. Here p is the momentum mv and q is the space coordinate. Then H = T + V , T = p 2 2 m , V = V ( q ) {\displaystyle {\mathcal {H}}=T+V,\qquad T={\frac {p^{2}}{2m}},\qquad V=V(q)} T is a function of p alone, while V is a function of q alone (i.e., T and V are scleronomic). In this example, the time derivative of q is the velocity, and so the first Hamilton equation means that the particle's velocity equals the derivative of its kinetic energy with respect to its momentum. The time derivative of the momentum p equals the Newtonian force, and so the second Hamilton equation means that the force equals the negative gradient of potential energy. == Example == A spherical pendulum consists of a mass m moving without friction on the surface of a sphere. The only forces acting on the mass are the reaction from the sphere and gravity. Spherical coordinates are used to describe the position of the mass in terms of (r, θ, φ), where r is fixed, r = ℓ. The Lagrangian for this system is L = 1 2 m ℓ 2 ( θ ˙ 2 + sin 2 ⁡ θ φ ˙ 2 ) + m g ℓ cos ⁡ θ . {\displaystyle L={\frac {1}{2}}m\ell ^{2}\left({\dot {\theta }}^{2}+\sin ^{2}\theta \ {\dot {\varphi }}^{2}\right)+mg\ell \cos \theta .} Thus the Hamiltonian is H = P θ θ ˙ + P φ φ ˙ − L {\displaystyle H=P_{\theta }{\dot {\theta }}+P_{\varphi }{\dot {\varphi }}-L} where P θ = ∂ L ∂ θ ˙ = m ℓ 2 θ ˙ {\displaystyle P_{\theta }={\frac {\partial L}{\partial {\dot {\theta }}}}=m\ell ^{2}{\dot {\theta }}} and P φ = ∂ L ∂ φ ˙ = m ℓ 2 sin 2 θ φ ˙ . {\displaystyle P_{\varphi }={\frac {\partial L}{\partial {\dot {\varphi }}}}=m\ell ^{2}\sin ^{2}\!\theta \,{\dot {\varphi }}.} In terms of coordinates and momenta, the Hamiltonian reads H = [ 1 2 m ℓ 2 θ ˙ 2 + 1 2 m ℓ 2 sin 2 θ φ ˙ 2 ] ⏟ T + [ − m g ℓ cos ⁡ θ ] ⏟ V = P θ 2 2 m ℓ 2 + P φ 2 2 m ℓ 2 sin 2 ⁡ θ − m g ℓ cos ⁡ θ . {\displaystyle H=\underbrace {\left[{\frac {1}{2}}m\ell ^{2}{\dot {\theta }}^{2}+{\frac {1}{2}}m\ell ^{2}\sin ^{2}\!\theta \,{\dot {\varphi }}^{2}\right]} _{T}+\underbrace {{\Big [}-mg\ell \cos \theta {\Big ]}} _{V}={\frac {P_{\theta }^{2}}{2m\ell ^{2}}}+{\frac {P_{\varphi }^{2}}{2m\ell ^{2}\sin ^{2}\theta }}-mg\ell \cos \theta .} Hamilton's equations give the time evolution of coordinates and conjugate momenta in four first-order differential equations, θ ˙ = P θ m ℓ 2 φ ˙ = P φ m ℓ 2 sin 2 ⁡ θ P θ ˙ = P φ 2 m ℓ 2 sin 3 ⁡ θ cos ⁡ θ − m g ℓ sin ⁡ θ P φ ˙ = 0. {\displaystyle {\begin{aligned}{\dot {\theta }}&={P_{\theta } \over m\ell ^{2}}\\[6pt]{\dot {\varphi }}&={P_{\varphi } \over m\ell ^{2}\sin ^{2}\theta }\\[6pt]{\dot {P_{\theta }}}&={P_{\varphi }^{2} \over m\ell ^{2}\sin ^{3}\theta }\cos \theta -mg\ell \sin \theta \\[6pt]{\dot {P_{\varphi }}}&=0.\end{aligned}}} Momentum ⁠ P φ {\displaystyle P_{\varphi }} ⁠, which corresponds to the vertical component of angular momentum ⁠ L z = ℓ sin ⁡ θ × m ℓ sin ⁡ θ φ ˙ {\displaystyle L_{z}=\ell \sin \theta \times m\ell \sin \theta \,{\dot {\varphi }}} ⁠, is a constant of motion. That is a consequence of the rotational symmetry of the system around the vertical axis. Being absent from the Hamiltonian, azimuth φ {\displaystyle \varphi } is a cyclic coordinate, which implies conservation of its conjugate momentum. == Deriving Hamilton's equations == Hamilton's equations can be derived by a calculation with the Lagrangian ⁠ L {\displaystyle {\mathcal {L}}} ⁠, generalized positions qi, and generalized velocities ⋅qi, where ⁠ i = 1 , … , n {\displaystyle i=1,\ldots ,n} ⁠. Here we work off-shell, meaning ⁠ q i {\displaystyle q^{i}} ⁠, ⁠ q ˙ i {\displaystyle {\dot {q}}^{i}} ⁠, ⁠ t {\displaystyle t} ⁠ are independent coordinates in phase space, not constrained to follow any equations of motion (in particular, q ˙ i {\displaystyle {\dot {q}}^{i}} is not a derivative of ⁠ q i {\displaystyle q^{i}} ⁠). The total differential of the Lagrangian is: d L = ∑ i ( ∂ L ∂ q i d q i + ∂ L ∂ q ˙ i d q ˙ i ) + ∂ L ∂ t d t . {\displaystyle \mathrm {d} {\mathcal {L}}=\sum _{i}\left({\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\mathrm {d} q^{i}+{\frac {\partial {\mathcal {L}}}{\partial {\dot {q}}^{i}}}\,\mathrm {d} {\dot {q}}^{i}\right)+{\frac {\partial {\mathcal {L}}}{\partial t}}\,\mathrm {d} t\ .} The generalized momentum coordinates were defined as ⁠ p i = ∂ L / ∂ q ˙ i {\displaystyle p_{i}=\partial {\mathcal {L}}/\partial {\dot {q}}^{i}} ⁠, so we may rewrite the equation as: d L = ∑ i ( ∂ L ∂ q i d q i + p i d q ˙ i ) + ∂ L ∂ t d t = ∑ i ( ∂ L ∂ q i d q i + d ( p i q ˙ i ) − q ˙ i d p i ) + ∂ L ∂ t d t . {\displaystyle {\begin{aligned}\mathrm {d} {\mathcal {L}}=&\sum _{i}\left({\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\,\mathrm {d} q^{i}+p_{i}\mathrm {d} {\dot {q}}^{i}\right)+{\frac {\partial {\mathcal {L}}}{\partial t}}\mathrm {d} t\\=&\sum _{i}\left({\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\,\mathrm {d} q^{i}+\mathrm {d} (p_{i}{\dot {q}}^{i})-{\dot {q}}^{i}\,\mathrm {d} p_{i}\right)+{\frac {\partial {\mathcal {L}}}{\partial t}}\,\mathrm {d} t\,.\end{aligned}}} After rearranging, one obtains: d ( ∑ i p i q ˙ i − L ) = ∑ i ( − ∂ L ∂ q i d q i + q ˙ i d p i ) − ∂ L ∂ t d t . {\displaystyle \mathrm {d} \!\left(\sum _{i}p_{i}{\dot {q}}^{i}-{\mathcal {L}}\right)=\sum _{i}\left(-{\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\,\mathrm {d} q^{i}+{\dot {q}}^{i}\mathrm {d} p_{i}\right)-{\frac {\partial {\mathcal {L}}}{\partial t}}\,\mathrm {d} t\ .} The term in parentheses on the left-hand side is just the Hamiltonian H = ∑ p i q ˙ i − L {\textstyle {\mathcal {H}}=\sum p_{i}{\dot {q}}^{i}-{\mathcal {L}}} defined previously, therefore: d H = ∑ i ( − ∂ L ∂ q i d q i + q ˙ i d p i ) − ∂ L ∂ t d t . {\displaystyle \mathrm {d} {\mathcal {H}}=\sum _{i}\left(-{\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\,\mathrm {d} q^{i}+{\dot {q}}^{i}\,\mathrm {d} p_{i}\right)-{\frac {\partial {\mathcal {L}}}{\partial t}}\,\mathrm {d} t\ .} One may also calculate the total differential of the Hamiltonian H {\displaystyle {\mathcal {H}}} with respect to coordinates ⁠ q i {\displaystyle q^{i}} ⁠, ⁠ p i {\displaystyle p_{i}} ⁠, ⁠ t {\displaystyle t} ⁠ instead of ⁠ q i {\displaystyle q^{i}} ⁠, ⁠ q ˙ i {\displaystyle {\dot {q}}^{i}} ⁠, ⁠ t {\displaystyle t} ⁠, yielding: d H = ∑ i ( ∂ H ∂ q i d q i + ∂ H ∂ p i d p i ) + ∂ H ∂ t d t . {\displaystyle \mathrm {d} {\mathcal {H}}=\sum _{i}\left({\frac {\partial {\mathcal {H}}}{\partial q^{i}}}\mathrm {d} q^{i}+{\frac {\partial {\mathcal {H}}}{\partial p_{i}}}\mathrm {d} p_{i}\right)+{\frac {\partial {\mathcal {H}}}{\partial t}}\,\mathrm {d} t\ .} One may now equate these two expressions for ⁠ d H {\displaystyle d{\mathcal {H}}} ⁠, one in terms of ⁠ L {\displaystyle {\mathcal {L}}} ⁠, the other in terms of ⁠ H {\displaystyle {\mathcal {H}}} ⁠: ∑ i ( − ∂ L ∂ q i d q i + q ˙ i d p i ) − ∂ L ∂ t d t = ∑ i ( ∂ H ∂ q i d q i + ∂ H ∂ p i d p i ) + ∂ H ∂ t d t . {\displaystyle \sum _{i}\left(-{\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\mathrm {d} q^{i}+{\dot {q}}^{i}\mathrm {d} p_{i}\right)-{\frac {\partial {\mathcal {L}}}{\partial t}}\,\mathrm {d} t\ =\ \sum _{i}\left({\frac {\partial {\mathcal {H}}}{\partial q^{i}}}\mathrm {d} q^{i}+{\frac {\partial {\mathcal {H}}}{\partial p_{i}}}\mathrm {d} p_{i}\right)+{\frac {\partial {\mathcal {H}}}{\partial t}}\,\mathrm {d} t\ .} Since these calculations are off-shell, one can equate the respective coefficients of ⁠ d q i {\displaystyle \mathrm {d} q^{i}} ⁠, ⁠ d p i {\displaystyle \mathrm {d} p_{i}} ⁠, ⁠ d t {\displaystyle \mathrm {d} t} ⁠ on the two sides: ∂ H ∂ q i = − ∂ L ∂ q i , ∂ H ∂ p i = q ˙ i , ∂ H ∂ t = − ∂ L ∂ t . {\displaystyle {\frac {\partial {\mathcal {H}}}{\partial q^{i}}}=-{\frac {\partial {\mathcal {L}}}{\partial q^{i}}}\quad ,\quad {\frac {\partial {\mathcal {H}}}{\partial p_{i}}}={\dot {q}}^{i}\quad ,\quad {\frac {\partial {\mathcal {H}}}{\partial t}}=-{\partial {\mathcal {L}} \over \partial t}\ .} On-shell, one substitutes parametric functions q i = q i ( t ) {\displaystyle q^{i}=q^{i}(t)} which define a trajectory in phase space with velocities ⁠ q ˙ i = d d t q i ( t ) {\displaystyle {\dot {q}}^{i}={\tfrac {d}{dt}}q^{i}(t)} ⁠, obeying Lagrange's equations: d d t ∂ L ∂ q ˙ i − ∂ L ∂ q i = 0 . {\displaystyle {\frac {\mathrm {d} }{\mathrm {d} t}}{\frac {\partial {\mathcal {L}}}{\partial {\dot {q}}^{i}}}-{\frac {\partial {\mathcal {L}}}{\partial q^{i}}}=0\ .} Rearranging and writing in terms of the on-shell p i = p i ( t ) {\displaystyle p_{i}=p_{i}(t)} gives: ∂ L ∂ q i = p ˙ i . {\displaystyle {\frac {\partial {\mathcal {L}}}{\partial q^{i}}}={\dot {p}}_{i}\ .} Thus Lagrange's equations are equivalent to Hamilton's equations: ∂ H ∂ q i = − p ˙ i , ∂ H ∂ p i = q ˙ i , ∂ H ∂ t = − ∂ L ∂ t . {\displaystyle {\frac {\partial {\mathcal {H}}}{\partial q^{i}}}=-{\dot {p}}_{i}\quad ,\quad {\frac {\partial {\mathcal {H}}}{\partial p_{i}}}={\dot {q}}^{i}\quad ,\quad {\frac {\partial {\mathcal {H}}}{\partial t}}=-{\frac {\partial {\mathcal {L}}}{\partial t}}\,.} In the case of time-independent H {\displaystyle {\mathcal {H}}} and ⁠ L {\displaystyle {\mathcal {L}}} ⁠, i.e. ⁠ ∂ H / ∂ t = − ∂ L / ∂ t = 0 {\displaystyle \partial {\mathcal {H}}/\partial t=-\partial {\mathcal {L}}/\partial t=0} ⁠, Hamilton's equations consist of 2n first-order differential equations, while Lagrange's equations consist of n second-order equations. Hamilton's equations usually do not reduce the difficulty of finding explicit solutions, but important theoretical results can be derived from them, because coordinates and momenta are independent variables with nearly symmetric roles. Hamilton's equations have another advantage over Lagrange's equations: if a system has a symmetry, so that some coordinate q i {\displaystyle q_{i}} does not occur in the Hamiltonian (i.e. a cyclic coordinate), the corresponding momentum coordinate p i {\displaystyle p_{i}} is conserved along each trajectory, and that coordinate can be reduced to a constant in the other equations of the set. This effectively reduces the problem from n coordinates to (n − 1) coordinates: this is the basis of symplectic reduction in geometry. In the Lagrangian framework, the conservation of momentum also follows immediately, however all the generalized velocities q ˙ i {\displaystyle {\dot {q}}_{i}} still occur in the Lagrangian, and a system of equations in n coordinates still has to be solved. The Lagrangian and Hamiltonian approaches provide the groundwork for deeper results in classical mechanics, and suggest analogous formulations in quantum mechanics: the path integral formulation and the Schrödinger equation. == Properties of the Hamiltonian == The value of the Hamiltonian H {\displaystyle {\mathcal {H}}} is the total energy of the system if and only if the energy function E L {\displaystyle E_{\mathcal {L}}} has the same property. (See definition of ⁠ H {\displaystyle {\mathcal {H}}} ⁠). d H d t = ∂ H ∂ t {\displaystyle {\frac {d{\mathcal {H}}}{dt}}={\frac {\partial {\mathcal {H}}}{\partial t}}} when ⁠ p ( t ) {\displaystyle \mathbf {p} (t)} ⁠, ⁠ q ( t ) {\displaystyle \mathbf {q} (t)} ⁠ form a solution of Hamilton's equations. Indeed, d H d t = ∂ H ∂ p ⋅ p ˙ + ∂ H ∂ q ⋅ q ˙ + ∂ H ∂ t , {\textstyle {\frac {d{\mathcal {H}}}{dt}}={\frac {\partial {\mathcal {H}}}{\partial {\boldsymbol {p}}}}\cdot {\dot {\boldsymbol {p}}}+{\frac {\partial {\mathcal {H}}}{\partial {\boldsymbol {q}}}}\cdot {\dot {\boldsymbol {q}}}+{\frac {\partial {\mathcal {H}}}{\partial t}},} and everything but the final term cancels out. H {\displaystyle {\mathcal {H}}} does not change under point transformations, i.e. smooth changes q ↔ q ′ {\displaystyle {\boldsymbol {q}}\leftrightarrow {\boldsymbol {q'}}} of space coordinates. (Follows from the invariance of the energy function E L {\displaystyle E_{\mathcal {L}}} under point transformations. The invariance of E L {\displaystyle E_{\mathcal {L}}} can be established directly). ∂ H ∂ t = − ∂ L ∂ t . {\displaystyle {\frac {\partial {\mathcal {H}}}{\partial t}}=-{\frac {\partial {\mathcal {L}}}{\partial t}}.} (See § Deriving Hamilton's equations). ⁠ − ∂ H ∂ q i = p ˙ i = ∂ L ∂ q i {\displaystyle -{\frac {\partial {\mathcal {H}}}{\partial q^{i}}}={\dot {p}}_{i}={\frac {\partial {\mathcal {L}}}{\partial q^{i}}}} ⁠. (Compare Hamilton's and Euler-Lagrange equations or see § Deriving Hamilton's equations). ∂ H ∂ q i = 0 {\displaystyle {\frac {\partial {\mathcal {H}}}{\partial q^{i}}}=0} if and only if ⁠ ∂ L ∂ q i = 0 {\displaystyle {\frac {\partial {\mathcal {L}}}{\partial q^{i}}}=0} ⁠.A coordinate for which the last equation holds is called cyclic (or ignorable). Every cyclic coordinate q i {\displaystyle q^{i}} reduces the number of degrees of freedom by ⁠ 1 {\displaystyle 1} ⁠, causes the corresponding momentum p i {\displaystyle p_{i}} to be conserved, and makes Hamilton's equations easier to solve. == Hamiltonian as the total system energy == In its application to a given system, the Hamiltonian is often taken to be H = T + V {\displaystyle {\mathcal {H}}=T+V} where T {\displaystyle T} is the kinetic energy and V {\displaystyle V} is the potential energy. Using this relation can be simpler than first calculating the Lagrangian, and then deriving the Hamiltonian from the Lagrangian. However, the relation is not true for all systems. The relation holds true for nonrelativistic systems when all of the following conditions are satisfied ∂ V ( q , q ˙ , t ) ∂ q ˙ i = 0 , ∀ i {\displaystyle {\frac {\partial V({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)}{\partial {\dot {q}}_{i}}}=0\;,\quad \forall i} ∂ T ( q , q ˙ , t ) ∂ t = 0 {\displaystyle {\frac {\partial T({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)}{\partial t}}=0} T ( q , q ˙ ) = ∑ i = 1 n ∑ j = 1 n ( c i j ( q ) q ˙ i q ˙ j ) {\displaystyle T({\boldsymbol {q}},{\boldsymbol {\dot {q}}})=\sum _{i=1}^{n}\sum _{j=1}^{n}{\biggl (}c_{ij}({\boldsymbol {q}}){\dot {q}}_{i}{\dot {q}}_{j}{\biggr )}} where t {\displaystyle t} is time, n {\displaystyle n} is the number of degrees of freedom of the system, and each c i j ( q ) {\displaystyle c_{ij}({\boldsymbol {q}})} is an arbitrary scalar function of q {\displaystyle {\boldsymbol {q}}} . In words, this means that the relation H = T + V {\displaystyle {\mathcal {H}}=T+V} holds true if T {\displaystyle T} does not contain time as an explicit variable (it is scleronomic), V {\displaystyle V} does not contain generalised velocity as an explicit variable, and each term of T {\displaystyle T} is quadratic in generalised velocity. === Proof === Preliminary to this proof, it is important to address an ambiguity in the related mathematical notation. While a change of variables can be used to equate L ( p , q , t ) = L ( q , q ˙ , t ) {\displaystyle {\mathcal {L}}({\boldsymbol {p}},{\boldsymbol {q}},t)={\mathcal {L}}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)} , it is important to note that ∂ L ( q , q ˙ , t ) ∂ q ˙ i ≠ ∂ L ( p , q , t ) ∂ q ˙ i {\displaystyle {\frac {\partial {\mathcal {L}}({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)}{\partial {\dot {q}}_{i}}}\neq {\frac {\partial {\mathcal {L}}({\boldsymbol {p}},{\boldsymbol {q}},t)}{\partial {\dot {q}}_{i}}}} . In this case, the right hand side always evaluates to 0. To perform a change of variables inside of a partial derivative, the multivariable chain rule should be used. Hence, to avoid ambiguity, the function arguments of any term inside of a partial derivative should be stated. Additionally, this proof uses the notation f ( a , b , c ) = f ( a , b ) {\displaystyle f(a,b,c)=f(a,b)} to imply that ∂ f ( a , b , c ) ∂ c = 0 {\displaystyle {\frac {\partial f(a,b,c)}{\partial c}}=0} . === Application to systems of point masses === For a system of point masses, the requirement for T {\displaystyle T} to be quadratic in generalised velocity is always satisfied for the case where T ( q , q ˙ , t ) = T ( q , q ˙ ) {\displaystyle T({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)=T({\boldsymbol {q}},{\boldsymbol {\dot {q}}})} , which is a requirement for H = T + V {\displaystyle {\mathcal {H}}=T+V} anyway. === Conservation of energy === If the conditions for H = T + V {\displaystyle {\mathcal {H}}=T+V} are satisfied, then conservation of the Hamiltonian implies conservation of energy. This requires the additional condition that V {\displaystyle V} does not contain time as an explicit variable. ∂ V ( q , q ˙ , t ) ∂ t = 0 {\displaystyle {\frac {\partial V({\boldsymbol {q}},{\boldsymbol {\dot {q}}},t)}{\partial t}}=0} In summary, the requirements for H = T + V = constant of time {\displaystyle {\mathcal {H}}=T+V={\text{constant of time}}} to be satisfied for a nonrelativistic system are V = V ( q ) {\displaystyle V=V({\boldsymbol {q}})} T = T ( q , q ˙ ) {\displaystyle T=T({\boldsymbol {q}},{\boldsymbol {\dot {q}}})} T {\displaystyle T} is a homogeneous quadratic function in q ˙ {\displaystyle {\boldsymbol {\dot {q}}}} Regarding extensions to the Euler-Lagrange formulation which use dissipation functions (See Lagrangian mechanics § Extensions to include non-conservative forces), e.g. the Rayleigh dissipation function, energy is not conserved when a dissipation function has effect. It is possible to explain the link between this and the former requirements by relating the extended and conventional Euler-Lagrange equations: grouping the extended terms into the potential function produces a velocity dependent potential. Hence, the requirements are not satisfied when a dissipation function has effect. == Hamiltonian of a charged particle in an electromagnetic field == A sufficient illustration of Hamiltonian mechanics is given by the Hamiltonian of a charged particle in an electromagnetic field. In Cartesian coordinates the Lagrangian of a non-relativistic classical particle in an electromagnetic field is (in SI Units): L = ∑ i 1 2 m x ˙ i 2 + ∑ i q x ˙ i A i − q φ , {\displaystyle {\mathcal {L}}=\sum _{i}{\tfrac {1}{2}}m{\dot {x}}_{i}^{2}+\sum _{i}q{\dot {x}}_{i}A_{i}-q\varphi ,} where q is the electric charge of the particle, φ is the electric scalar potential, and the Ai are the components of the magnetic vector potential that may all explicitly depend on x i {\displaystyle x_{i}} and ⁠ t {\displaystyle t} ⁠. This Lagrangian, combined with Euler–Lagrange equation, produces the Lorentz force law m x ¨ = q E + q x ˙ × B , {\displaystyle m{\ddot {\mathbf {x} }}=q\mathbf {E} +q{\dot {\mathbf {x} }}\times \mathbf {B} \,,} and is called minimal coupling. The canonical momenta are given by: p i = ∂ L ∂ x ˙ i = m x ˙ i + q A i . {\displaystyle p_{i}={\frac {\partial {\mathcal {L}}}{\partial {\dot {x}}_{i}}}=m{\dot {x}}_{i}+qA_{i}.} The Hamiltonian, as the Legendre transformation of the Lagrangian, is therefore: H = ∑ i x ˙ i p i − L = ∑ i ( p i − q A i ) 2 2 m + q φ . {\displaystyle {\mathcal {H}}=\sum _{i}{\dot {x}}_{i}p_{i}-{\mathcal {L}}=\sum _{i}{\frac {\left(p_{i}-qA_{i}\right)^{2}}{2m}}+q\varphi .} This equation is used frequently in quantum mechanics. Under gauge transformation: A → A + ∇ f , φ → φ − f ˙ , {\displaystyle \mathbf {A} \rightarrow \mathbf {A} +\nabla f\,,\quad \varphi \rightarrow \varphi -{\dot {f}}\,,} where f(r, t) is any scalar function of space and time. The aforementioned Lagrangian, the canonical momenta, and the Hamiltonian transform like: L → L ′ = L + q d f d t , p → p ′ = p + q ∇ f , H → H ′ = H − q ∂ f ∂ t , {\displaystyle L\rightarrow L'=L+q{\frac {df}{dt}}\,,\quad \mathbf {p} \rightarrow \mathbf {p'} =\mathbf {p} +q\nabla f\,,\quad H\rightarrow H'=H-q{\frac {\partial f}{\partial t}}\,,} which still produces the same Hamilton's equation: ∂ H ′ ∂ x i | p i ′ = ∂ ∂ x i | p i ′ ( x ˙ i p i ′ − L ′ ) = − ∂ L ′ ∂ x i | p i ′ = − ∂ L ∂ x i | p i ′ − q ∂ ∂ x i | p i ′ d f d t = − d d t ( ∂ L ∂ x ˙ i | p i ′ + q ∂ f ∂ x i | p i ′ ) = − p ˙ i ′ {\displaystyle {\begin{aligned}\left.{\frac {\partial H'}{\partial {x_{i}}}}\right|_{p'_{i}}&=\left.{\frac {\partial }{\partial {x_{i}}}}\right|_{p'_{i}}({\dot {x}}_{i}p'_{i}-L')=-\left.{\frac {\partial L'}{\partial {x_{i}}}}\right|_{p'_{i}}\\&=-\left.{\frac {\partial L}{\partial {x_{i}}}}\right|_{p'_{i}}-q\left.{\frac {\partial }{\partial {x_{i}}}}\right|_{p'_{i}}{\frac {df}{dt}}\\&=-{\frac {d}{dt}}\left(\left.{\frac {\partial L}{\partial {{\dot {x}}_{i}}}}\right|_{p'_{i}}+q\left.{\frac {\partial f}{\partial {x_{i}}}}\right|_{p'_{i}}\right)\\&=-{\dot {p}}'_{i}\end{aligned}}} In quantum mechanics, the wave function will also undergo a local U(1) group transformation during the Gauge Transformation, which implies that all physical results must be invariant under local U(1) transformations. === Relativistic charged particle in an electromagnetic field === The relativistic Lagrangian for a particle (rest mass m {\displaystyle m} and charge ⁠ q {\displaystyle q} ⁠) is given by: L ( t ) = − m c 2 1 − x ˙ ( t ) 2 c 2 + q x ˙ ( t ) ⋅ A ( x ( t ) , t ) − q φ ( x ( t ) , t ) {\displaystyle {\mathcal {L}}(t)=-mc^{2}{\sqrt {1-{\frac {{{\dot {\mathbf {x} }}(t)}^{2}}{c^{2}}}}}+q{\dot {\mathbf {x} }}(t)\cdot \mathbf {A} \left(\mathbf {x} (t),t\right)-q\varphi \left(\mathbf {x} (t),t\right)} Thus the particle's canonical momentum is p ( t ) = ∂ L ∂ x ˙ = m x ˙ 1 − x ˙ 2 c 2 + q A {\displaystyle \mathbf {p} (t)={\frac {\partial {\mathcal {L}}}{\partial {\dot {\mathbf {x} }}}}={\frac {m{\dot {\mathbf {x} }}}{\sqrt {1-{\frac {{\dot {\mathbf {x} }}^{2}}{c^{2}}}}}}+q\mathbf {A} } that is, the sum of the kinetic momentum and the potential momentum. Solving for the velocity, we get x ˙ ( t ) = p − q A m 2 + 1 c 2 ( p − q A ) 2 {\displaystyle {\dot {\mathbf {x} }}(t)={\frac {\mathbf {p} -q\mathbf {A} }{\sqrt {m^{2}+{\frac {1}{c^{2}}}{\left(\mathbf {p} -q\mathbf {A} \right)}^{2}}}}} So the Hamiltonian is H ( t ) = x ˙ ⋅ p − L = c m 2 c 2 + ( p − q A ) 2 + q φ {\displaystyle {\mathcal {H}}(t)={\dot {\mathbf {x} }}\cdot \mathbf {p} -{\mathcal {L}}=c{\sqrt {m^{2}c^{2}+{\left(\mathbf {p} -q\mathbf {A} \right)}^{2}}}+q\varphi } This results in the force equation (equivalent to the Euler–Lagrange equation) p ˙ = − ∂ H ∂ x = q x ˙ ⋅ ( ∇ A ) − q ∇ φ = q ∇ ( x ˙ ⋅ A ) − q ∇ φ {\displaystyle {\dot {\mathbf {p} }}=-{\frac {\partial {\mathcal {H}}}{\partial \mathbf {x} }}=q{\dot {\mathbf {x} }}\cdot ({\boldsymbol {\nabla }}\mathbf {A} )-q{\boldsymbol {\nabla }}\varphi =q{\boldsymbol {\nabla }}({\dot {\mathbf {x} }}\cdot \mathbf {A} )-q{\boldsymbol {\nabla }}\varphi } from which one can derive d d t ( m x ˙ 1 − x ˙ 2 c 2 ) = d d t ( p − q A ) = p ˙ − q ∂ A ∂ t − q ( x ˙ ⋅ ∇ ) A = q ∇ ( x ˙ ⋅ A ) − q ∇ φ − q ∂ A ∂ t − q ( x ˙ ⋅ ∇ ) A = q E + q x ˙ × B {\displaystyle {\begin{aligned}{\frac {\mathrm {d} }{\mathrm {d} t}}\left({\frac {m{\dot {\mathbf {x} }}}{\sqrt {1-{\frac {{\dot {\mathbf {x} }}^{2}}{c^{2}}}}}}\right)&={\frac {\mathrm {d} }{\mathrm {d} t}}(\mathbf {p} -q\mathbf {A} )={\dot {\mathbf {p} }}-q{\frac {\partial \mathbf {A} }{\partial t}}-q({\dot {\mathbf {x} }}\cdot \nabla )\mathbf {A} \\&=q{\boldsymbol {\nabla }}({\dot {\mathbf {x} }}\cdot \mathbf {A} )-q{\boldsymbol {\nabla }}\varphi -q{\frac {\partial \mathbf {A} }{\partial t}}-q({\dot {\mathbf {x} }}\cdot \nabla )\mathbf {A} \\&=q\mathbf {E} +q{\dot {\mathbf {x} }}\times \mathbf {B} \end{aligned}}} The above derivation makes use of the vector calculus identity: 1 2 ∇ ( A ⋅ A ) = A ⋅ J A = A ⋅ ( ∇ A ) = ( A ⋅ ∇ ) A + A × ( ∇ × A ) . {\displaystyle {\tfrac {1}{2}}\nabla \left(\mathbf {A} \cdot \mathbf {A} \right)=\mathbf {A} \cdot \mathbf {J} _{\mathbf {A} }=\mathbf {A} \cdot (\nabla \mathbf {A} )=(\mathbf {A} \cdot \nabla )\mathbf {A} +\mathbf {A} \times (\nabla \times \mathbf {A} ).} An equivalent expression for the Hamiltonian as function of the relativistic (kinetic) momentum, ⁠ P = γ m x ˙ ( t ) = p − q A {\displaystyle \mathbf {P} =\gamma m{\dot {\mathbf {x} }}(t)=\mathbf {p} -q\mathbf {A} } ⁠, is H ( t ) = x ˙ ( t ) ⋅ P ( t ) + m c 2 γ + q φ ( x ( t ) , t ) = γ m c 2 + q φ ( x ( t ) , t ) = E + V {\displaystyle {\mathcal {H}}(t)={\dot {\mathbf {x} }}(t)\cdot \mathbf {P} (t)+{\frac {mc^{2}}{\gamma }}+q\varphi (\mathbf {x} (t),t)=\gamma mc^{2}+q\varphi (\mathbf {x} (t),t)=E+V} This has the advantage that kinetic momentum P {\displaystyle \mathbf {P} } can be measured experimentally whereas canonical momentum p {\displaystyle \mathbf {p} } cannot. Notice that the Hamiltonian (total energy) can be viewed as the sum of the relativistic energy (kinetic+rest), ⁠ E = γ m c 2 {\displaystyle E=\gamma mc^{2}} ⁠, plus the potential energy, ⁠ V = q φ {\displaystyle V=q\varphi } ⁠. == From symplectic geometry to Hamilton's equations == === Geometry of Hamiltonian systems === The Hamiltonian can induce a symplectic structure on a smooth even-dimensional manifold M2n in several equivalent ways, the best known being the following: As a closed nondegenerate symplectic 2-form ω. According to Darboux's theorem, in a small neighbourhood around any point on M there exist suitable local coordinates p 1 , ⋯ , p n , q 1 , ⋯ , q n {\displaystyle p_{1},\cdots ,p_{n},\ q_{1},\cdots ,q_{n}} (canonical or symplectic coordinates) in which the symplectic form becomes: ω = ∑ i = 1 n d p i ∧ d q i . {\displaystyle \omega =\sum _{i=1}^{n}dp_{i}\wedge dq_{i}\,.} The form ω {\displaystyle \omega } induces a natural isomorphism of the tangent space with the cotangent space: ⁠ T x M ≅ T x ∗ M {\displaystyle T_{x}M\cong T_{x}^{*}M} ⁠. This is done by mapping a vector ξ ∈ T x M {\displaystyle \xi \in T_{x}M} to the 1-form ⁠ ω ξ ∈ T x ∗ M {\displaystyle \omega _{\xi }\in T_{x}^{*}M} ⁠, where ω ξ ( η ) = ω ( η , ξ ) {\displaystyle \omega _{\xi }(\eta )=\omega (\eta ,\xi )} for all ⁠ η ∈ T x M {\displaystyle \eta \in T_{x}M} ⁠. Due to the bilinearity and non-degeneracy of ⁠ ω {\displaystyle \omega } ⁠, and the fact that ⁠ dim ⁡ T x M = dim ⁡ T x ∗ M {\displaystyle \dim T_{x}M=\dim T_{x}^{*}M} ⁠, the mapping ξ → ω ξ {\displaystyle \xi \to \omega _{\xi }} is indeed a linear isomorphism. This isomorphism is natural in that it does not change with change of coordinates on M . {\displaystyle M.} Repeating over all ⁠ x ∈ M {\displaystyle x\in M} ⁠, we end up with an isomorphism J − 1 : Vect ( M ) → Ω 1 ( M ) {\displaystyle J^{-1}:{\text{Vect}}(M)\to \Omega ^{1}(M)} between the infinite-dimensional space of smooth vector fields and that of smooth 1-forms. For every f , g ∈ C ∞ ( M , R ) {\displaystyle f,g\in C^{\infty }(M,\mathbb {R} )} and ⁠ ξ , η ∈ Vect ( M ) {\displaystyle \xi ,\eta \in {\text{Vect}}(M)} ⁠, J − 1 ( f ξ + g η ) = f J − 1 ( ξ ) + g J − 1 ( η ) . {\displaystyle J^{-1}(f\xi +g\eta )=fJ^{-1}(\xi )+gJ^{-1}(\eta ).} (In algebraic terms, one would say that the C ∞ ( M , R ) {\displaystyle C^{\infty }(M,\mathbb {R} )} -modules Vect ( M ) {\displaystyle {\text{Vect}}(M)} and Ω 1 ( M ) {\displaystyle \Omega ^{1}(M)} are isomorphic). If ⁠ H ∈ C ∞ ( M × R t , R ) {\displaystyle H\in C^{\infty }(M\times \mathbb {R} _{t},\mathbb {R} )} ⁠, then, for every fixed ⁠ t ∈ R t {\displaystyle t\in \mathbb {R} _{t}} ⁠, ⁠ d H ∈ Ω 1 ( M ) {\displaystyle dH\in \Omega ^{1}(M)} ⁠, and ⁠ J ( d H ) ∈ Vect ( M ) {\displaystyle J(dH)\in {\text{Vect}}(M)} ⁠. J ( d H ) {\displaystyle J(dH)} is known as a Hamiltonian vector field. The respective differential equation on M {\displaystyle M} x ˙ = J ( d H ) ( x ) {\displaystyle {\dot {x}}=J(dH)(x)} is called Hamilton's equation. Here x = x ( t ) {\displaystyle x=x(t)} and J ( d H ) ( x ) ∈ T x M {\displaystyle J(dH)(x)\in T_{x}M} is the (time-dependent) value of the vector field J ( d H ) {\displaystyle J(dH)} at ⁠ x ∈ M {\displaystyle x\in M} ⁠. A Hamiltonian system may be understood as a fiber bundle E over time R, with the fiber Et being the position space at time t ∈ R. The Lagrangian is thus a function on the jet bundle J over E; taking the fiberwise Legendre transform of the Lagrangian produces a function on the dual bundle over time whose fiber at t is the cotangent space T∗Et, which comes equipped with a natural symplectic form, and this latter function is the Hamiltonian. The correspondence between Lagrangian and Hamiltonian mechanics is achieved with the tautological one-form. Any smooth real-valued function H on a symplectic manifold can be used to define a Hamiltonian system. The function H is known as "the Hamiltonian" or "the energy function." The symplectic manifold is then called the phase space. The Hamiltonian induces a special vector field on the symplectic manifold, known as the Hamiltonian vector field. The Hamiltonian vector field induces a Hamiltonian flow on the manifold. This is a one-parameter family of transformations of the manifold (the parameter of the curves is commonly called "the time"); in other words, an isotopy of symplectomorphisms, starting with the identity. By Liouville's theorem, each symplectomorphism preserves the volume form on the phase space. The collection of symplectomorphisms induced by the Hamiltonian flow is commonly called "the Hamiltonian mechanics" of the Hamiltonian system. The symplectic structure induces a Poisson bracket. The Poisson bracket gives the space of functions on the manifold the structure of a Lie algebra. If F and G are smooth functions on M then the smooth function ω(J(dF), J(dG)) is properly defined; it is called a Poisson bracket of functions F and G and is denoted {F, G}. The Poisson bracket has the following properties: bilinearity antisymmetry Leibniz rule: { F 1 ⋅ F 2 , G } = F 1 { F 2 , G } + F 2 { F 1 , G } {\displaystyle \{F_{1}\cdot F_{2},G\}=F_{1}\{F_{2},G\}+F_{2}\{F_{1},G\}} Jacobi identity: { { H , F } , G } + { { F , G } , H } + { { G , H } , F } ≡ 0 {\displaystyle \{\{H,F\},G\}+\{\{F,G\},H\}+\{\{G,H\},F\}\equiv 0} non-degeneracy: if the point x on M is not critical for F then a smooth function G exists such that ⁠ { F , G } ( x ) ≠ 0 {\displaystyle \{F,G\}(x)\neq 0} ⁠. Given a function f d d t f = ∂ ∂ t f + { f , H } , {\displaystyle {\frac {\mathrm {d} }{\mathrm {d} t}}f={\frac {\partial }{\partial t}}f+\left\{f,{\mathcal {H}}\right\},} if there is a probability distribution ρ, then (since the phase space velocity ( p ˙ i , q ˙ i ) {\displaystyle ({\dot {p}}_{i},{\dot {q}}_{i})} has zero divergence and probability is conserved) its convective derivative can be shown to be zero and so ∂ ∂ t ρ = − { ρ , H } {\displaystyle {\frac {\partial }{\partial t}}\rho =-\left\{\rho ,{\mathcal {H}}\right\}} This is called Liouville's theorem. Every smooth function G over the symplectic manifold generates a one-parameter family of symplectomorphisms and if {G, H} = 0, then G is conserved and the symplectomorphisms are symmetry transformations. A Hamiltonian may have multiple conserved quantities Gi. If the symplectic manifold has dimension 2n and there are n functionally independent conserved quantities Gi which are in involution (i.e., {Gi, Gj} = 0), then the Hamiltonian is Liouville integrable. The Liouville–Arnold theorem says that, locally, any Liouville integrable Hamiltonian can be transformed via a symplectomorphism into a new Hamiltonian with the conserved quantities Gi as coordinates; the new coordinates are called action–angle coordinates. The transformed Hamiltonian depends only on the Gi, and hence the equations of motion have the simple form G ˙ i = 0 , φ ˙ i = F i ( G ) {\displaystyle {\dot {G}}_{i}=0\quad ,\quad {\dot {\varphi }}_{i}=F_{i}(G)} for some function F. There is an entire field focusing on small deviations from integrable systems governed by the KAM theorem. The integrability of Hamiltonian vector fields is an open question. In general, Hamiltonian systems are chaotic; concepts of measure, completeness, integrability and stability are poorly defined. === Riemannian manifolds === An important special case consists of those Hamiltonians that are quadratic forms, that is, Hamiltonians that can be written as H ( q , p ) = 1 2 ⟨ p , p ⟩ q {\displaystyle {\mathcal {H}}(q,p)={\tfrac {1}{2}}\langle p,p\rangle _{q}} where ⟨ , ⟩q is a smoothly varying inner product on the fibers T∗qQ, the cotangent space to the point q in the configuration space, sometimes called a cometric. This Hamiltonian consists entirely of the kinetic term. If one considers a Riemannian manifold or a pseudo-Riemannian manifold, the Riemannian metric induces a linear isomorphism between the tangent and cotangent bundles. (See Musical isomorphism). Using this isomorphism, one can define a cometric. (In coordinates, the matrix defining the cometric is the inverse of the matrix defining the metric.) The solutions to the Hamilton–Jacobi equations for this Hamiltonian are then the same as the geodesics on the manifold. In particular, the Hamiltonian flow in this case is the same thing as the geodesic flow. The existence of such solutions, and the completeness of the set of solutions, are discussed in detail in the article on geodesics. See also Geodesics as Hamiltonian flows. === Sub-Riemannian manifolds === When the cometric is degenerate, then it is not invertible. In this case, one does not have a Riemannian manifold, as one does not have a metric. However, the Hamiltonian still exists. In the case where the cometric is degenerate at every point q of the configuration space manifold Q, so that the rank of the cometric is less than the dimension of the manifold Q, one has a sub-Riemannian manifold. The Hamiltonian in this case is known as a sub-Riemannian Hamiltonian. Every such Hamiltonian uniquely determines the cometric, and vice versa. This implies that every sub-Riemannian manifold is uniquely determined by its sub-Riemannian Hamiltonian, and that the converse is true: every sub-Riemannian manifold has a unique sub-Riemannian Hamiltonian. The existence of sub-Riemannian geodesics is given by the Chow–Rashevskii theorem. The continuous, real-valued Heisenberg group provides a simple example of a sub-Riemannian manifold. For the Heisenberg group, the Hamiltonian is given by H ( x , y , z , p x , p y , p z ) = 1 2 ( p x 2 + p y 2 ) . {\displaystyle {\mathcal {H}}\left(x,y,z,p_{x},p_{y},p_{z}\right)={\tfrac {1}{2}}\left(p_{x}^{2}+p_{y}^{2}\right).} pz is not involved in the Hamiltonian. === Poisson algebras === Hamiltonian systems can be generalized in various ways. Instead of simply looking at the algebra of smooth functions over a symplectic manifold, Hamiltonian mechanics can be formulated on general commutative unital real Poisson algebras. A state is a continuous linear functional on the Poisson algebra (equipped with some suitable topology) such that for any element A of the algebra, A2 maps to a nonnegative real number. A further generalization is given by Nambu dynamics. === Generalization to quantum mechanics through Poisson bracket === Hamilton's equations above work well for classical mechanics, but not for quantum mechanics, since the differential equations discussed assume that one can specify the exact position and momentum of the particle simultaneously at any point in time. However, the equations can be further generalized to then be extended to apply to quantum mechanics as well as to classical mechanics, through the deformation of the Poisson algebra over p and q to the algebra of Moyal brackets. Specifically, the more general form of the Hamilton's equation reads d f d t = { f , H } + ∂ f ∂ t , {\displaystyle {\frac {\mathrm {d} f}{\mathrm {d} t}}=\left\{f,{\mathcal {H}}\right\}+{\frac {\partial f}{\partial t}},} where f is some function of p and q, and H is the Hamiltonian. To find out the rules for evaluating a Poisson bracket without resorting to differential equations, see Lie algebra; a Poisson bracket is the name for the Lie bracket in a Poisson algebra. These Poisson brackets can then be extended to Moyal brackets comporting to an inequivalent Lie algebra, as proven by Hilbrand J. Groenewold, and thereby describe quantum mechanical diffusion in phase space (See Phase space formulation and Wigner–Weyl transform). This more algebraic approach not only permits ultimately extending probability distributions in phase space to Wigner quasi-probability distributions, but, at the mere Poisson bracket classical setting, also provides more power in helping analyze the relevant conserved quantities in a system. == See also == == References == == Further reading == == External links == Binney, James J., Classical Mechanics (lecture notes) (PDF), University of Oxford, retrieved 27 October 2010 Tong, David, Classical Dynamics (Cambridge lecture notes), University of Cambridge, retrieved 27 October 2010 Hamilton, William Rowan, On a General Method in Dynamics, Trinity College Dublin Malham, Simon J.A. (2016), An introduction to Lagrangian and Hamiltonian mechanics (lecture notes) (PDF) Morin, David (2008), Introduction to Classical Mechanics (Additional material: The Hamiltonian method) (PDF)
Wikipedia/Hamiltonian_mechanics
The NASA Deep Space Network (DSN) is a worldwide network of spacecraft communication ground segment facilities, located in the United States (California), Spain (Madrid), and Australia (Canberra), that supports NASA's interplanetary spacecraft missions. It also performs radio and radar astronomy observations for the exploration of the Solar System and the universe, and supports selected Earth-orbiting missions. DSN is part of the NASA Jet Propulsion Laboratory (JPL). == General information == DSN currently consists of three deep-space communications facilities located such that a distant spacecraft is always in view of at least one station. They are: the Goldstone Deep Space Communications Complex (35°25′36″N 116°53′24″W) about 60 kilometres (37 mi) north of Barstow, California. For details of Goldstone's contribution to the early days of space probe tracking, see Project Space Track; the Madrid Deep Space Communications Complex (40°25′53″N 4°14′53″W), 60 kilometres (37 mi) west of Madrid, Spain; and the Canberra Deep Space Communication Complex (CDSCC) in the Australian Capital Territory (35°24′05″S 148°58′54″E), 40 kilometres (25 mi) southwest of Canberra, Australia near the Tidbinbilla Nature Reserve. Each facility is situated in semi-mountainous, bowl-shaped terrain to help shield against radio frequency interference. The strategic placement of the stations permits constant observation of spacecraft as the Earth rotates, which helps to make the DSN the largest and most sensitive scientific telecommunications system in the world. The DSN supports NASA's contribution to the scientific investigation of the Solar System: It provides a two-way communications link that guides and controls various NASA uncrewed interplanetary space probes, and brings back the images and new scientific information these probes collect. All DSN antennas are steerable, high-gain, parabolic reflector antennas. The antennas and data delivery systems make it possible to: acquire telemetry data from spacecraft. transmit commands to spacecraft. upload software modifications to spacecraft. track spacecraft position and velocity. perform Very Long Baseline Interferometry observations. measure variations in radio waves for radio science experiments. gather science data. monitor and control the performance of the network. Other countries and organizations also run deep space networks. The DSN operates according to the standards of the Consultative Committee for Space Data Systems, as do most other deep space networks, and hence the DSN is able to inter-operate with the networks of other space agencies. These include the Soviet Deep Space Network, the Chinese Deep Space Network, the Indian Deep Space Network, the Japanese Deep Space Network, and the ESTRACK of the European Space Agency. These agencies often cooperate for better mission coverage. In particular, DSN has a cross-support agreement with ESA that allows mutual use of both networks for more effectiveness and reduced risk. In addition, radio astronomy facilities, such as the Parkes Observatory, the Green Bank Telescope, and the Very Large Array, are sometimes used to supplement the antennas of the DSN. === Operations control center === The antennas at all three DSN Complexes communicate directly with the Deep Space Operations Center (also known as Deep Space Network operations control center) located at the JPL facilities in Pasadena, California. In the early years, the operations control center did not have a permanent facility. It was a provisional setup with numerous desks and phones installed in a large room near the computers used to calculate orbits. In July 1961, NASA started the construction of the permanent facility, Space Flight Operations Facility (SFOF). The facility was completed in October 1963 and dedicated on May 14, 1964. In the initial setup of the SFOF, there were 31 consoles, 100 closed-circuit television cameras, and more than 200 television displays to support Ranger 6 to Ranger 9 and Mariner 4. Currently, the operations center personnel at SFOF monitor and direct operations, and oversee the quality of spacecraft telemetry and navigation data delivered to network users. In addition to the DSN complexes and the operations center, a ground communications facility provides communications that link the three complexes to the operations center at JPL, to space flight control centers in the United States and overseas, and to scientists around the world. == Deep space == Tracking vehicles in deep space is quite different from tracking missions in low Earth orbit (LEO). Deep space missions are visible for long periods of time from a large portion of the Earth's surface, and so require few stations (the DSN has only three main sites). These few stations, however, require huge antennas, ultra-sensitive receivers, and powerful transmitters in order to transmit and receive over the vast distances involved. Deep space is defined in several different ways. According to a 1975 NASA report, the DSN was designed to communicate with "spacecraft traveling approximately 16,000 km (10,000 miles) from Earth to the farthest planets of the solar system." JPL diagrams state that at an altitude of 30,000 km (19,000 mi), a spacecraft is always in the field of view of one of the tracking stations. The International Telecommunication Union, which sets aside various frequency bands for deep space and near Earth use, defines "deep space" to start at a distance of 2 million km (1.2 million mi) from the Earth's surface. === Frequency bands === The NASA Deep Space Network can both send and receive in all of the ITU deep space bands - S-band (2 GHz), X-band (8 GHz), and Ka-band (32 GHz). Frequency usage has in general moved upward over the life of the DSN, as higher frequencies have higher gain for the same size antenna, and the deep space bands are wider, so more data can be returned. However, higher frequencies also need more accurate pointing (on the spacecraft) and more precise antenna surfaces (on Earth), so improvements in both spacecraft and the DSN were required to move to higher bands. Early missions used S-band for both uplink and downlink. Viking (1975) had X-band as an experiment, and Voyager (1977) was the first to use it operationally. Similarly, Mars Observer (1994) carried a Ka-band experiment, Mars Reconnaissance Orbiter (2005) had a Ka-band demo, and Kepler (2009) was the first mission to use Ka-band as the primary downlink. However, not all space missions can use these bands. The Moon, the Earth-moon Lagrange points, and the Earth–Sun Lagrangian points L1 and L2 are all closer than 2 million km from Earth (distances are here), so they are considered near space and cannot use the ITU's deep space bands. Missions at these locations that need high data rates must therefore use the "near space" K band (27 GHz). Since NASA has several such missions (such as the James Webb Space Telescope and the Lunar Reconnaissance Orbiter), they have enhanced the Deep Space Network to receive (but not transmit) at these frequencies as well. The DSN is also pursuing optical deep space communication, offering greater communication speeds at the cost of susceptibility to weather and the need for extremely precise pointing of the spacecraft. This technology is working in prototype form. == History == The forerunner of the DSN was established in January 1958, when JPL, then under contract to the U.S. Army, deployed portable radio tracking stations in Nigeria, Singapore, and California to receive telemetry and plot the orbit of the Army-launched Explorer 1, the first successful U.S. satellite. NASA was officially established on October 1, 1958, to consolidate the separately developing space-exploration programs of the US Army, US Navy, and US Air Force into one civilian organization. On December 3, 1958, JPL was transferred from the US Army to NASA and given responsibility for the design and execution of lunar and planetary exploration programs using remotely controlled spacecraft. Shortly after the transfer, NASA established the concept of the Deep Space Network as a separately managed and operated communications system that would accommodate all deep space missions, thereby avoiding the need for each flight project to acquire and operate its own specialized space communications network. The DSN was given responsibility for its own research, development, and operation in support of all of its users. Under this concept, it has become a world leader in the development of low-noise receivers; large parabolic-dish antennas; tracking, telemetry, and command systems; digital signal processing; and deep space navigation. The Deep Space Network formally announced its intention to send missions into deep space on Christmas Eve 1963; it has remained in continuous operation in one capacity or another ever since. The largest antennas of the DSN are often called on during spacecraft emergencies. Almost all spacecraft are designed so normal operation can be conducted on the smaller (and more economical) antennas of the DSN, but during an emergency the use of the largest antennas is crucial. This is because a troubled spacecraft may be forced to use less than its normal transmitter power, attitude control problems may preclude the use of high-gain antennas, and recovering every bit of telemetry is critical to assessing the health of the spacecraft and planning the recovery. The most famous example is the Apollo 13 mission, where limited battery power and inability to use the spacecraft's high-gain antennas reduced signal levels below the capability of the Manned Space Flight Network, and the use of the biggest DSN antennas (and the Australian Parkes Observatory radio telescope) was critical to saving the lives of the astronauts. While Apollo was also a US mission, DSN provides this emergency service to other space agencies as well, in a spirit of inter-agency and international cooperation. For example, the recovery of the Solar and Heliospheric Observatory (SOHO) mission of the European Space Agency (ESA) would not have been possible without the use of the largest DSN facilities. === DSN and the Apollo program === Although normally tasked with tracking uncrewed spacecraft, the Deep Space Network (DSN) also contributed to the communication and tracking of Apollo missions to the Moon, although primary responsibility was held by the Manned Space Flight Network (MSFN). The DSN designed the MSFN stations for lunar communication and provided a second antenna at each MSFN site (the MSFN sites were near the DSN sites for just this reason). Two antennas at each site were needed both for redundancy and because the beam widths of the large antennas needed were too small to encompass both the lunar orbiter and the lander at the same time. DSN also supplied some larger antennas as needed, in particular for television broadcasts from the Moon, and emergency communications such as Apollo 13. Excerpt from a NASA report describing how the DSN and MSFN cooperated for Apollo: Another critical step in the evolution of the Apollo Network came in 1965 with the advent of the DSN Wing concept. Originally, the participation of DSN 26-m antennas during an Apollo Mission was to be limited to a backup role. This was one reason why the MSFN 26-m sites were collocated with the DSN sites at Goldstone, Madrid, and Canberra. However, the presence of two, well-separated spacecraft during lunar operations stimulated the rethinking of the tracking and communication problem. One thought was to add a dual S-band RF system to each of the three 26-m MSFN antennas, leaving the nearby DSN 26-m antennas still in a backup role. Calculations showed, though, that a 26-m antenna pattern centered on the landed Lunar Module would suffer a 9-to-12 db loss at the lunar horizon, making tracking and data acquisition of the orbiting Command Service Module difficult, perhaps impossible. It made sense to use both the MSFN and DSN antennas simultaneously during the all-important lunar operations. JPL was naturally reluctant to compromise the objectives of its many uncrewed spacecraft by turning three of its DSN stations over to the MSFN for long periods. How could the goals of both Apollo and deep space exploration be achieved without building a third 26-m antenna at each of the three sites or undercutting planetary science missions? The solution came in early 1965 at a meeting at NASA Headquarters, when Eberhardt Rechtin suggested what is now known as the "wing concept". The wing approach involves constructing a new section or "wing" to the main building at each of the three involved DSN sites. The wing would include a MSFN control room and the necessary interface equipment to accomplish the following: Permit tracking and two-way data transfer with either spacecraft during lunar operations. Permit tracking and two-way data transfer with the combined spacecraft during the flight to the Moon. Provide backup for the collocated MSFN site passive track (spacecraft to ground RF links) of the Apollo spacecraft during trans-lunar and trans-earth phases. With this arrangement, the DSN station could be quickly switched from a deep-space mission to Apollo and back again. GSFC personnel would operate the MSFN equipment completely independently of DSN personnel. Deep space missions would not be compromised nearly as much as if the entire station's equipment and personnel were turned over to Apollo for several weeks. The details of this cooperation and operation are available in a two-volume technical report from JPL. == Management == The network is a NASA facility and is managed and operated for NASA by JPL, which is part of the California Institute of Technology (Caltech). The Interplanetary Network Directorate (IND) manages the program within JPL and is charged with the development and operation of it. The IND is considered to be JPL's focal point for all matters relating to telecommunications, interplanetary navigation, information systems, information technology, computing, software engineering, and other relevant technologies. While the IND is best known for its duties relating to the Deep Space Network, the organization also maintains the JPL Advanced Multi-Mission Operations System (AMMOS) and JPL's Institutional Computing and Information Services (ICIS). The facilities in Spain and Australia are jointly owned and operated in conjunction with that government's scientific institutions. In Australia, "the Commonwealth Scientific and Industrial Research Organisation (CSIRO), an Australian Commonwealth Government Statutory Authority, established the CSIRO Astronomy and Space Science Division to manage the day-to-day operations, engineering, and maintenance activities of the Canberra Deep Space Communications Complex". Most of the staff at Tidbinbilla are Australian government employees; the land and buildings are owned by the Australian government; NASA provides the bulk of the funding, owns the movable property (such as dishes and electronic equipment) which it has paid for, and gets to decide where to point the dishes. Similarly, in Spain, "Ingenieria de Sistemas para la Defensa de España S.A. (ISDEFE), a wholly owned subsidiary of the Instituto Nacional de Técnica Aeroespacial (INTA) and a part of the Spanish Department of Defense, operates and maintains the Madrid Deep Space Communications Complex (Madrid)". Peraton (formerly Harris Corporation) is under contract to JPL for the DSN's operations and maintenance. Peraton has responsibility for managing the Goldstone complex, operating the DSOC, and for DSN operations, mission planning, operations engineering, and logistics. == Antennas == Each complex consists of at least four deep space terminals equipped with ultra-sensitive receiving systems and large parabolic-dish antennas. There are: Three or more 34-meter (112 ft) Beam waveguide antennas (BWG) One 70-meter (230 ft) antenna. Five of the 34-meter (112 ft) beam waveguide antennas were added to the system in the late 1990s. Three were located at Goldstone, and one each at Canberra and Madrid. A second 34-meter (112 ft) beam waveguide antenna (the network's sixth) was completed at the Madrid complex in 2004. In order to meet the current and future needs of deep space communication services, a number of new Deep Space Station antennas had to be built at the existing Deep Space Network sites. At the Canberra Deep Space Communication Complex the first of these was completed in October 2014 (DSS35), with a second becoming operational in October 2016 (DSS36). A new 34 meter dish (DSS53) became operational at the Madrid complex in February 2022. The 70 meter antennas are aging and more difficult to maintain than the modern BWG antennas. Therefore in 2012 NASA announced a plan to decommission all three of them and replace them with arrayed 34-meter BWG antennas. Each of these new antennas would be upgraded to have X-band uplink capabilities and both X and Ka-band downlink capabilities. However by 2021, NASA decided instead to do a complete refurbishment of all 70 meter antennas, requiring taking them offline for months at a time. These refurbished antennas were expected to serve for decades to come. == Current signal processing capabilities == The general capabilities of the DSN have not substantially changed since the beginning of the Voyager Interstellar Mission in the early 1990s. However, many advancements in digital signal processing, arraying and error correction have been adopted by the DSN. The ability to array several antennas was incorporated to improve the data returned from the Voyager 2 Neptune encounter, and extensively used for the Galileo mission, when the spacecraft's high-gain antenna failed to deploy and as a result Galileo was forced to resort to operating solely off its low-gain antennas. The DSN array currently available since the Galileo mission can link the 70-meter (230 ft) dish antenna at the Deep Space Network complex in Goldstone, California, with an identical antenna located in Australia, in addition to two 34-meter (112 ft) antennas at the Canberra complex. The California and Australia sites were used concurrently to pick up communications with Galileo. Arraying of antennas within the three DSN locations is also used. For example, a 70-meter (230 ft) dish antenna can be arrayed with a 34-meter dish. For especially vital missions, like Voyager 2, non-DSN facilities normally used for radio astronomy can be added to the array. In particular, the Canberra 70-meter (230 ft) dish can be arrayed with the Parkes Radio Telescope in Australia; and the Goldstone 70-meter dish can be arrayed with the Very Large Array of antennas in New Mexico. Also, two or more 34-meter (112 ft) dishes at one DSN location are commonly arrayed together. All the stations are remotely operated from a centralized Signal Processing Center at each complex. These Centers house the electronic subsystems that point and control the antennas, receive and process the telemetry data, transmit commands, and generate the spacecraft navigation data. Once the data are processed at the complexes, they are transmitted to JPL for further processing and for distribution to science teams over a modern communications network. Especially at Mars, there are often many spacecraft within the beam width of an antenna. For operational efficiency, a single antenna can receive signals from multiple spacecraft at the same time. This capability is called Multiple Spacecraft Per Aperture, or MSPA. Currently, the DSN can receive up to 4 spacecraft signals at the same time, or MSPA-4. However, apertures cannot currently be shared for uplink. When two or more high-power carriers are used simultaneously, very high order intermodulation products fall in the receiver bands, causing interference to the much (25 orders of magnitude) weaker received signals. Therefore, only one spacecraft at a time can get an uplink, though up to 4 can be received. == Network limitations and challenges == There are a number of limitations to the current DSN, and a number of challenges going forward. Most of these are outlined in an Audit of NASA's Deep Space Network performed by NASA's Office of Inspector General. Their main conclusions are: NASA's DSN is oversubscribed, leading to mission impacts and scheduling challenges Capacity limitations leading to mission impacts are expected to increase with the onset of crewed Artemis missions Capacity limitations, lack of readily available backups, and laborious process present challenges to scheduling time on DSN Upgrades to NASA's Deep Space Network are behind schedule and more costly than planned Challenges with international partners and project oversight Other problems have been noted as well: The Deep Space Network nodes are all on Earth. Therefore, data transmission rates from/to spacecraft and space probes are severely constrained due to the distances from Earth. For now it can connect with the Mars orbiters in the Mars Relay Network for faster and more flexible communications with spacecraft and landers on Mars. Adding dedicated communication satellites elsewhere in space, to handle multiparty, multi-mission use, such as the canceled Mars Telecommunications Orbiter, would increase flexibility towards some sort of Interplanetary Internet. The need to support "legacy" missions that have remained operational beyond their original lifetimes but are still returning scientific data. Programs such as Voyager have been operating long past their original mission termination date. They also need some of the largest antennas. Replacing major components can cause problems as it can leave an antenna out of service for months at a time. The older 70 m antennas are reaching the end of their lives, and at some point will need to be replaced. NASA has so far extended their lives through major refurbishment. The leading candidate for 70 m replacement had been an array of smaller dishes, but more recently the decision was taken to expand the provision of 34-meter (112 ft) BWG antennas at each complex to a total of 4. All the 34-meter HEF antennas have been replaced. Because of capacity limits on the DSN, new spacecraft intended for missions beyond geocentric orbits are being equipped to use the beacon mode service, which allows such missions to operate without the DSN most of the time. In addition, NASA is creating a network of Lunar Exploration Ground Sites to offload much of the lunar and Artemis mission needs from the DSN. == DSN and radio science == The DSN forms one portion of the radio sciences experiment included on most deep space missions, where radio links between spacecraft and Earth are used to investigate planetary science, space physics and fundamental physics. The experiments include radio occultations, gravity field determination and celestial mechanics, bistatic scattering, doppler wind experiments, solar corona characterization, and tests of fundamental physics. For example, the Deep Space Network forms one component of the gravity science experiment on Juno. This includes special communication hardware on Juno and uses its communication system. The DSN radiates a Ka-band uplink, which is picked up by Juno's Ka-Band communication system and then processed by a special communication box called KaTS, and then this new signal is sent back the DSN. This allows the velocity of the spacecraft over time to be determined with a level of precision that allows a more accurate determination of the gravity field at planet Jupiter. Another radio science experiment is REX on the New Horizons spacecraft to Pluto-Charon. REX received a signal from Earth as it was occulted by Pluto, to take various measurements of that system of bodies. == See also == == Sources == This article incorporates public domain material from R. Corliss, William (June 1974). NASA Technical report CR 140390, Histories of the Space Tracking and Data Acquisition Network (STADAN), the Manned Space Flight Network (MSFN), and the NASA Communications Network (NASCOM) (PDF). NASA. hdl:2060/19750002909. Archived (PDF) from the original on 2022-03-03. == References == Notes The sun orbiting Ulysses' extended mission operation terminated June 30, 2009. The extension permitted a third flyby over the Sun's poles in 2007–2008. The two Voyager spacecraft continue to operate, with some loss in subsystem redundancy, but retain the capability of returning science data from a full complement of VIM science instruments. Both spacecraft also have adequate electrical power and attitude control propellant to continue operating until around 2020, when the available electrical power will no longer support science instrument operation. At this time, science data return and spacecraft operations will cease. The Deep Space Positioning System (DSPS) is being developed. == External links and further reading == JPL DSN – official site. DSN Now, NASA, live status of antennas and spacecraft at all three facilities.
Wikipedia/NASA_Deep_Space_Network
In mathematics and theoretical physics, a superalgebra is a Z2-graded algebra. That is, it is an algebra over a commutative ring or field with a decomposition into "even" and "odd" pieces and a multiplication operator that respects the grading. The prefix super- comes from the theory of supersymmetry in theoretical physics. Superalgebras and their representations, supermodules, provide an algebraic framework for formulating supersymmetry. The study of such objects is sometimes called super linear algebra. Superalgebras also play an important role in related field of supergeometry where they enter into the definitions of graded manifolds, supermanifolds and superschemes. == Formal definition == Let K be a commutative ring. In most applications, K is a field of characteristic 0, such as R or C. A superalgebra over K is a K-module A with a direct sum decomposition A = A 0 ⊕ A 1 {\displaystyle A=A_{0}\oplus A_{1}} together with a bilinear multiplication A × A → A such that A i A j ⊆ A i + j {\displaystyle A_{i}A_{j}\subseteq A_{i+j}} where the subscripts are read modulo 2, i.e. they are thought of as elements of Z2. A superring, or Z2-graded ring, is a superalgebra over the ring of integers Z. The elements of each of the Ai are said to be homogeneous. The parity of a homogeneous element x, denoted by |x|, is 0 or 1 according to whether it is in A0 or A1. Elements of parity 0 are said to be even and those of parity 1 to be odd. If x and y are both homogeneous then so is the product xy and | x y | = | x | + | y | {\displaystyle |xy|=|x|+|y|} . An associative superalgebra is one whose multiplication is associative and a unital superalgebra is one with a multiplicative identity element. The identity element in a unital superalgebra is necessarily even. Unless otherwise specified, all superalgebras in this article are assumed to be associative and unital. A commutative superalgebra (or supercommutative algebra) is one which satisfies a graded version of commutativity. Specifically, A is commutative if y x = ( − 1 ) | x | | y | x y {\displaystyle yx=(-1)^{|x||y|}xy\,} for all homogeneous elements x and y of A. There are superalgebras that are commutative in the ordinary sense, but not in the superalgebra sense. For this reason, commutative superalgebras are often called supercommutative in order to avoid confusion. == Sign conventions == When the Z2 grading arises as a "rollup" of a Z- or N-graded algebra into even and odd components, then two distinct (but essentially equivalent) sign conventions can be found in the literature. These can be called the "cohomological sign convention" and the "super sign convention". They differ in how the antipode (exchange of two elements) behaves. In the first case, one has an exchange map x y ↦ ( − 1 ) m n + p q y x {\displaystyle xy\mapsto (-1)^{mn+pq}yx} where m = deg ⁡ x {\displaystyle m=\deg x} is the degree (Z- or N-grading) of x {\displaystyle x} and p {\displaystyle p} the parity. Likewise, n = deg ⁡ y {\displaystyle n=\deg y} is the degree of y {\displaystyle y} and with parity q . {\displaystyle q.} This convention is commonly seen in conventional mathematical settings, such as differential geometry and differential topology. The other convention is to take x y ↦ ( − 1 ) p q y x {\displaystyle xy\mapsto (-1)^{pq}yx} with the parities given as p = m mod 2 {\displaystyle p=m{\bmod {2}}} and q = n mod 2 {\displaystyle q=n{\bmod {2}}} the parity. This is more often seen in physics texts, and requires a parity functor to be judiciously employed to track isomorphisms. Detailed arguments are provided by Pierre Deligne == Examples == Any algebra over a commutative ring K may be regarded as a purely even superalgebra over K; that is, by taking A1 to be trivial. Any Z- or N-graded algebra may be regarded as superalgebra by reading the grading modulo 2. This includes examples such as tensor algebras and polynomial rings over K. In particular, any exterior algebra over K is a superalgebra. The exterior algebra is the standard example of a supercommutative algebra. The symmetric polynomials and alternating polynomials together form a superalgebra, being the even and odd parts, respectively. Note that this is a different grading from the grading by degree. Clifford algebras are superalgebras. They are generally noncommutative. The set of all endomorphisms (denoted E n d ( V ) ≡ H o m ( V , V ) {\displaystyle \mathbf {End} (V)\equiv \mathbf {Hom} (V,V)} , where the boldface H o m {\displaystyle \mathrm {Hom} } is referred to as internal H o m {\displaystyle \mathrm {Hom} } , composed of all linear maps) of a super vector space forms a superalgebra under composition. The set of all square supermatrices with entries in K forms a superalgebra denoted by Mp|q(K). This algebra may be identified with the algebra of endomorphisms of a free supermodule over K of rank p|q and is the internal Hom of above for this space. Lie superalgebras are a graded analog of Lie algebras. Lie superalgebras are nonunital and nonassociative; however, one may construct the analog of a universal enveloping algebra of a Lie superalgebra which is a unital, associative superalgebra. == Further definitions and constructions == === Even subalgebra === Let A be a superalgebra over a commutative ring K. The submodule A0, consisting of all even elements, is closed under multiplication and contains the identity of A and therefore forms a subalgebra of A, naturally called the even subalgebra. It forms an ordinary algebra over K. The set of all odd elements A1 is an A0-bimodule whose scalar multiplication is just multiplication in A. The product in A equips A1 with a bilinear form μ : A 1 ⊗ A 0 A 1 → A 0 {\displaystyle \mu :A_{1}\otimes _{A_{0}}A_{1}\to A_{0}} such that μ ( x ⊗ y ) ⋅ z = x ⋅ μ ( y ⊗ z ) {\displaystyle \mu (x\otimes y)\cdot z=x\cdot \mu (y\otimes z)} for all x, y, and z in A1. This follows from the associativity of the product in A. === Grade involution === There is a canonical involutive automorphism on any superalgebra called the grade involution. It is given on homogeneous elements by x ^ = ( − 1 ) | x | x {\displaystyle {\hat {x}}=(-1)^{|x|}x} and on arbitrary elements by x ^ = x 0 − x 1 {\displaystyle {\hat {x}}=x_{0}-x_{1}} where xi are the homogeneous parts of x. If A has no 2-torsion (in particular, if 2 is invertible) then the grade involution can be used to distinguish the even and odd parts of A: A i = { x ∈ A : x ^ = ( − 1 ) i x } . {\displaystyle A_{i}=\{x\in A:{\hat {x}}=(-1)^{i}x\}.} === Supercommutativity === The supercommutator on A is the binary operator given by [ x , y ] = x y − ( − 1 ) | x | | y | y x {\displaystyle [x,y]=xy-(-1)^{|x||y|}yx} on homogeneous elements, extended to all of A by linearity. Elements x and y of A are said to supercommute if [x, y] = 0. The supercenter of A is the set of all elements of A which supercommute with all elements of A: Z ( A ) = { a ∈ A : [ a , x ] = 0 for all x ∈ A } . {\displaystyle \mathrm {Z} (A)=\{a\in A:[a,x]=0{\text{ for all }}x\in A\}.} The supercenter of A is, in general, different than the center of A as an ungraded algebra. A commutative superalgebra is one whose supercenter is all of A. === Super tensor product === The graded tensor product of two superalgebras A and B may be regarded as a superalgebra A ⊗ B with a multiplication rule determined by: ( a 1 ⊗ b 1 ) ( a 2 ⊗ b 2 ) = ( − 1 ) | b 1 | | a 2 | ( a 1 a 2 ⊗ b 1 b 2 ) . {\displaystyle (a_{1}\otimes b_{1})(a_{2}\otimes b_{2})=(-1)^{|b_{1}||a_{2}|}(a_{1}a_{2}\otimes b_{1}b_{2}).} If either A or B is purely even, this is equivalent to the ordinary ungraded tensor product (except that the result is graded). However, in general, the super tensor product is distinct from the tensor product of A and B regarded as ordinary, ungraded algebras. == Generalizations and categorical definition == One can easily generalize the definition of superalgebras to include superalgebras over a commutative superring. The definition given above is then a specialization to the case where the base ring is purely even. Let R be a commutative superring. A superalgebra over R is a R-supermodule A with a R-bilinear multiplication A × A → A that respects the grading. Bilinearity here means that r ⋅ ( x y ) = ( r ⋅ x ) y = ( − 1 ) | r | | x | x ( r ⋅ y ) {\displaystyle r\cdot (xy)=(r\cdot x)y=(-1)^{|r||x|}x(r\cdot y)} for all homogeneous elements r ∈ R and x, y ∈ A. Equivalently, one may define a superalgebra over R as a superring A together with an superring homomorphism R → A whose image lies in the supercenter of A. One may also define superalgebras categorically. The category of all R-supermodules forms a monoidal category under the super tensor product with R serving as the unit object. An associative, unital superalgebra over R can then be defined as a monoid in the category of R-supermodules. That is, a superalgebra is an R-supermodule A with two (even) morphisms μ : A ⊗ A → A η : R → A {\displaystyle {\begin{aligned}\mu &:A\otimes A\to A\\\eta &:R\to A\end{aligned}}} for which the usual diagrams commute. == Notes == == References == Deligne, P.; Morgan, J. W. (1999). "Notes on Supersymmetry (following Joseph Bernstein)". Quantum Fields and Strings: A Course for Mathematicians. Vol. 1. American Mathematical Society. pp. 41–97. ISBN 0-8218-2012-5. Kac, V. G.; Martinez, C.; Zelmanov, E. (2001). Graded simple Jordan superalgebras of growth one. Memoirs of the AMS Series. Vol. 711. AMS Bookstore. ISBN 978-0-8218-2645-4. Manin, Y. I. (1997). Gauge Field Theory and Complex Geometry ((2nd ed.) ed.). Berlin: Springer. ISBN 3-540-61378-1. Varadarajan, V. S. (2004). Supersymmetry for Mathematicians: An Introduction. Courant Lecture Notes in Mathematics. Vol. 11. American Mathematical Society. ISBN 978-0-8218-3574-6.
Wikipedia/Superalgebra
There is a natural connection between particle physics and representation theory, as first noted in the 1930s by Eugene Wigner. It links the properties of elementary particles to the structure of Lie groups and Lie algebras. According to this connection, the different quantum states of an elementary particle give rise to an irreducible representation of the Poincaré group. Moreover, the properties of the various particles, including their spectra, can be related to representations of Lie algebras, corresponding to "approximate symmetries" of the universe. == General picture == === Symmetries of a quantum system === In quantum mechanics, any particular one-particle state is represented as a vector in a Hilbert space H {\displaystyle {\mathcal {H}}} . To help understand what types of particles can exist, it is important to classify the possibilities for H {\displaystyle {\mathcal {H}}} allowed by symmetries, and their properties. Let H {\displaystyle {\mathcal {H}}} be a Hilbert space describing a particular quantum system and let G {\displaystyle G} be a group of symmetries of the quantum system. In a relativistic quantum system, for example, G {\displaystyle G} might be the Poincaré group, while for the hydrogen atom, G {\displaystyle G} might be the rotation group SO(3). The particle state is more precisely characterized by the associated projective Hilbert space P H {\displaystyle \mathrm {P} {\mathcal {H}}} , also called ray space, since two vectors that differ by a nonzero scalar factor correspond to the same physical quantum state represented by a ray in Hilbert space, which is an equivalence class in H {\displaystyle {\mathcal {H}}} and, under the natural projection map H → P H {\displaystyle {\mathcal {H}}\rightarrow \mathrm {P} {\mathcal {H}}} , an element of P H {\displaystyle \mathrm {P} {\mathcal {H}}} . By definition of a symmetry of a quantum system, there is a group action on P H {\displaystyle \mathrm {P} {\mathcal {H}}} . For each g ∈ G {\displaystyle g\in G} , there is a corresponding transformation V ( g ) {\displaystyle V(g)} of P H {\displaystyle \mathrm {P} {\mathcal {H}}} . More specifically, if g {\displaystyle g} is some symmetry of the system (say, rotation about the x-axis by 12°), then the corresponding transformation V ( g ) {\displaystyle V(g)} of P H {\displaystyle \mathrm {P} {\mathcal {H}}} is a map on ray space. For example, when rotating a stationary (zero momentum) spin-5 particle about its center, g {\displaystyle g} is a rotation in 3D space (an element of S O ( 3 ) {\displaystyle \mathrm {SO(3)} } ), while V ( g ) {\displaystyle V(g)} is an operator whose domain and range are each the space of possible quantum states of this particle, in this example the projective space P H {\displaystyle \mathrm {P} {\mathcal {H}}} associated with an 11-dimensional complex Hilbert space H {\displaystyle {\mathcal {H}}} . Each map V ( g ) {\displaystyle V(g)} preserves, by definition of symmetry, the ray product on P H {\displaystyle \mathrm {P} {\mathcal {H}}} induced by the inner product on H {\displaystyle {\mathcal {H}}} ; according to Wigner's theorem, this transformation of P H {\displaystyle \mathrm {P} {\mathcal {H}}} comes from a unitary or anti-unitary transformation U ( g ) {\displaystyle U(g)} of H {\displaystyle {\mathcal {H}}} . Note, however, that the U ( g ) {\displaystyle U(g)} associated to a given V ( g ) {\displaystyle V(g)} is not unique, but only unique up to a phase factor. The composition of the operators U ( g ) {\displaystyle U(g)} should, therefore, reflect the composition law in G {\displaystyle G} , but only up to a phase factor: U ( g h ) = e i θ U ( g ) U ( h ) {\displaystyle U(gh)=e^{i\theta }U(g)U(h)} , where θ {\displaystyle \theta } will depend on g {\displaystyle g} and h {\displaystyle h} . Thus, the map sending g {\displaystyle g} to U ( g ) {\displaystyle U(g)} is a projective unitary representation of G {\displaystyle G} , or possibly a mixture of unitary and anti-unitary, if G {\displaystyle G} is disconnected. In practice, anti-unitary operators are always associated with time-reversal symmetry. === Ordinary versus projective representations === It is important physically that in general U ( ⋅ ) {\displaystyle U(\cdot )} does not have to be an ordinary representation of G {\displaystyle G} ; it may not be possible to choose the phase factors in the definition of U ( g ) {\displaystyle U(g)} to eliminate the phase factors in their composition law. An electron, for example, is a spin-one-half particle; its Hilbert space consists of wave functions on R 3 {\displaystyle \mathbb {R} ^{3}} with values in a two-dimensional spinor space. The action of S O ( 3 ) {\displaystyle \mathrm {SO(3)} } on the spinor space is only projective: It does not come from an ordinary representation of S O ( 3 ) {\displaystyle \mathrm {SO(3)} } . There is, however, an associated ordinary representation of the universal cover S U ( 2 ) {\displaystyle \mathrm {SU(2)} } of S O ( 3 ) {\displaystyle \mathrm {SO(3)} } on spinor space. For many interesting classes of groups G {\displaystyle G} , Bargmann's theorem tells us that every projective unitary representation of G {\displaystyle G} comes from an ordinary representation of the universal cover G ~ {\displaystyle {\tilde {G}}} of G {\displaystyle G} . Actually, if H {\displaystyle {\mathcal {H}}} is finite dimensional, then regardless of the group G {\displaystyle G} , every projective unitary representation of G {\displaystyle G} comes from an ordinary unitary representation of G ~ {\displaystyle {\tilde {G}}} . If H {\displaystyle {\mathcal {H}}} is infinite dimensional, then to obtain the desired conclusion, some algebraic assumptions must be made on G {\displaystyle G} (see below). In this setting the result is a theorem of Bargmann. Fortunately, in the crucial case of the Poincaré group, Bargmann's theorem applies. (See Wigner's classification of the representations of the universal cover of the Poincaré group.) The requirement referred to above is that the Lie algebra g {\displaystyle {\mathfrak {g}}} does not admit a nontrivial one-dimensional central extension. This is the case if and only if the second cohomology group of g {\displaystyle {\mathfrak {g}}} is trivial. In this case, it may still be true that the group admits a central extension by a discrete group. But extensions of G {\displaystyle G} by discrete groups are covers of G {\displaystyle G} . For instance, the universal cover G ~ {\displaystyle {\tilde {G}}} is related to G {\displaystyle G} through the quotient G ≈ G ~ / Γ {\displaystyle G\approx {\tilde {G}}/\Gamma } with the central subgroup Γ {\displaystyle \Gamma } being the center of G ~ {\displaystyle {\tilde {G}}} itself, isomorphic to the fundamental group of the covered group. Thus, in favorable cases, the quantum system will carry a unitary representation of the universal cover G ~ {\displaystyle {\tilde {G}}} of the symmetry group G {\displaystyle G} . This is desirable because H {\displaystyle {\mathcal {H}}} is much easier to work with than the non-vector space P H {\displaystyle \mathrm {P} {\mathcal {H}}} . If the representations of G ~ {\displaystyle {\tilde {G}}} can be classified, much more information about the possibilities and properties of H {\displaystyle {\mathcal {H}}} are available. === The Heisenberg case === An example in which Bargmann's theorem does not apply comes from a quantum particle moving in R n {\displaystyle \mathbb {R} ^{n}} . The group of translational symmetries of the associated phase space, R 2 n {\displaystyle \mathbb {R} ^{2n}} , is the commutative group R 2 n {\displaystyle \mathbb {R} ^{2n}} . In the usual quantum mechanical picture, the R 2 n {\displaystyle \mathbb {R} ^{2n}} symmetry is not implemented by a unitary representation of R 2 n {\displaystyle \mathbb {R} ^{2n}} . After all, in the quantum setting, translations in position space and translations in momentum space do not commute. This failure to commute reflects the failure of the position and momentum operators—which are the infinitesimal generators of translations in momentum space and position space, respectively—to commute. Nevertheless, translations in position space and translations in momentum space do commute up to a phase factor. Thus, we have a well-defined projective representation of R 2 n {\displaystyle \mathbb {R} ^{2n}} , but it does not come from an ordinary representation of R 2 n {\displaystyle \mathbb {R} ^{2n}} , even though R 2 n {\displaystyle \mathbb {R} ^{2n}} is simply connected. In this case, to obtain an ordinary representation, one has to pass to the Heisenberg group, which is a nontrivial one-dimensional central extension of R 2 n {\displaystyle \mathbb {R} ^{2n}} . == Poincaré group == The group of translations and Lorentz transformations form the Poincaré group, and this group should be a symmetry of a relativistic quantum system (neglecting general relativity effects, or in other words, in flat spacetime). Representations of the Poincaré group are in many cases characterized by a nonnegative mass and a half-integer spin (see Wigner's classification); this can be thought of as the reason that particles have quantized spin. (There are in fact other possible representations, such as tachyons, infraparticles, etc., which in some cases do not have quantized spin or fixed mass.) == Other symmetries == While the spacetime symmetries in the Poincaré group are particularly easy to visualize and believe, there are also other types of symmetries, called internal symmetries. One example is color SU(3), an exact symmetry corresponding to the continuous interchange of the three quark colors. == Lie algebras versus Lie groups == Many (but not all) symmetries or approximate symmetries form Lie groups. Rather than study the representation theory of these Lie groups, it is often preferable to study the closely related representation theory of the corresponding Lie algebras, which are usually simpler to compute. Now, representations of the Lie algebra correspond to representations of the universal cover of the original group. In the finite-dimensional case—and the infinite-dimensional case, provided that Bargmann's theorem applies—irreducible projective representations of the original group correspond to ordinary unitary representations of the universal cover. In those cases, computing at the Lie algebra level is appropriate. This is the case, notably, for studying the irreducible projective representations of the rotation group SO(3). These are in one-to-one correspondence with the ordinary representations of the universal cover SU(2) of SO(3). The representations of the SU(2) are then in one-to-one correspondence with the representations of its Lie algebra su(2), which is isomorphic to the Lie algebra so(3) of SO(3). Thus, to summarize, the irreducible projective representations of SO(3) are in one-to-one correspondence with the irreducible ordinary representations of its Lie algebra so(3). The two-dimensional "spin 1/2" representation of the Lie algebra so(3), for example, does not correspond to an ordinary (single-valued) representation of the group SO(3). (This fact is the origin of statements to the effect that "if you rotate the wave function of an electron by 360 degrees, you get the negative of the original wave function.") Nevertheless, the spin 1/2 representation does give rise to a well-defined projective representation of SO(3), which is all that is required physically. == Approximate symmetries == Although the above symmetries are believed to be exact, other symmetries are only approximate. === Hypothetical example === As an example of what an approximate symmetry means, suppose an experimentalist lived inside an infinite ferromagnet, with magnetization in some particular direction. The experimentalist in this situation would find not one but two distinct types of electrons: one with spin along the direction of the magnetization, with a slightly lower energy (and consequently, a lower mass), and one with spin anti-aligned, with a higher mass. Our usual SO(3) rotational symmetry, which ordinarily connects the spin-up electron with the spin-down electron, has in this hypothetical case become only an approximate symmetry, relating different types of particles to each other. === General definition === In general, an approximate symmetry arises when there are very strong interactions that obey that symmetry, along with weaker interactions that do not. In the electron example above, the two "types" of electrons behave identically under the strong and weak forces, but differently under the electromagnetic force. === Example: isospin symmetry === An example from the real world is isospin symmetry, an SU(2) group corresponding to the similarity between up quarks and down quarks. This is an approximate symmetry: while up and down quarks are identical in how they interact under the strong force, they have different masses and different electroweak interactions. Mathematically, there is an abstract two-dimensional vector space up quark → ( 1 0 ) , down quark → ( 0 1 ) {\displaystyle {\text{up quark}}\rightarrow {\begin{pmatrix}1\\0\end{pmatrix}},\qquad {\text{down quark}}\rightarrow {\begin{pmatrix}0\\1\end{pmatrix}}} and the laws of physics are approximately invariant under applying a determinant-1 unitary transformation to this space: ( x y ) ↦ A ( x y ) , where A is in S U ( 2 ) {\displaystyle {\begin{pmatrix}x\\y\end{pmatrix}}\mapsto A{\begin{pmatrix}x\\y\end{pmatrix}},\quad {\text{where }}A{\text{ is in }}SU(2)} For example, A = ( 0 1 − 1 0 ) {\displaystyle A={\begin{pmatrix}0&1\\-1&0\end{pmatrix}}} would turn all up quarks in the universe into down quarks and vice versa. Some examples help clarify the possible effects of these transformations: When these unitary transformations are applied to a proton, it can be transformed into a neutron, or into a superposition of a proton and neutron, but not into any other particles. Therefore, the transformations move the proton around a two-dimensional space of quantum states. The proton and neutron are called an "isospin doublet", mathematically analogous to how a spin-½ particle behaves under ordinary rotation. When these unitary transformations are applied to any of the three pions (π0, π+, and π−), it can change any of the pions into any other, but not into any non-pion particle. Therefore, the transformations move the pions around a three-dimensional space of quantum states. The pions are called an "isospin triplet", mathematically analogous to how a spin-1 particle behaves under ordinary rotation. These transformations have no effect at all on an electron, because it contains neither up nor down quarks. The electron is called an isospin singlet, mathematically analogous to how a spin-0 particle behaves under ordinary rotation. In general, particles form isospin multiplets, which correspond to irreducible representations of the Lie algebra SU(2). Particles in an isospin multiplet have very similar but not identical masses, because the up and down quarks are very similar but not identical. === Example: flavour symmetry === Isospin symmetry can be generalized to flavour symmetry, an SU(3) group corresponding to the similarity between up quarks, down quarks, and strange quarks. This is, again, an approximate symmetry, violated by quark mass differences and electroweak interactions—in fact, it is a poorer approximation than isospin, because of the strange quark's noticeably higher mass. Nevertheless, particles can indeed be neatly divided into groups that form irreducible representations of the Lie algebra SU(3), as first noted by Murray Gell-Mann and independently by Yuval Ne'eman. == See also == Charge (physics) Representation theory: Of Lie algebras Of Lie groups Projective representation Special unitary group == Notes == == References == Howard Georgi (2018). Lie Algebras In Particle Physics: from Isospin To Unified Theories. Taylor & Francis. ISBN 9780429499210. Hall, Brian C. (2013), Quantum Theory for Mathematicians, Graduate Texts in Mathematics, vol. 267, Springer, Bibcode:2013qtm..book.....H, ISBN 978-1461471158. Hall, Brian C. (2015), Lie Groups, Lie Algebras, and Representations: An Elementary Introduction, Graduate Texts in Mathematics, vol. 222 (2nd ed.), Springer, ISBN 978-3319134666. Sternberg, Shlomo (1994) Group Theory and Physics. Cambridge Univ. Press. ISBN 0-521-24870-1. Especially pp. 148–150. Weinberg, Steven (1995). The Quantum Theory of Fields, Volume 1: Foundations. Cambridge Univ. Press. ISBN 0-521-55001-7. Especially appendices A and B to Chapter 2. == External links == Baez, John C.; Huerta, John (2010). "The Algebra of Grand Unified Theories". Bull. Am. Math. Soc. 47 (3): 483–552. arXiv:0904.1556. doi:10.1090/S0273-0979-10-01294-2. S2CID 2941843.
Wikipedia/Particle_physics_and_representation_theory
In coding theory, decoding is the process of translating received messages into codewords of a given code. There have been many common methods of mapping messages to codewords. These are often used to recover messages sent over a noisy channel, such as a binary symmetric channel. == Notation == C ⊂ F 2 n {\displaystyle C\subset \mathbb {F} _{2}^{n}} is considered a binary code with the length n {\displaystyle n} ; x , y {\displaystyle x,y} shall be elements of F 2 n {\displaystyle \mathbb {F} _{2}^{n}} ; and d ( x , y ) {\displaystyle d(x,y)} is the distance between those elements. == Ideal observer decoding == One may be given the message x ∈ F 2 n {\displaystyle x\in \mathbb {F} _{2}^{n}} , then ideal observer decoding generates the codeword y ∈ C {\displaystyle y\in C} . The process results in this solution: P ( y sent ∣ x received ) {\displaystyle \mathbb {P} (y{\mbox{ sent}}\mid x{\mbox{ received}})} For example, a person can choose the codeword y {\displaystyle y} that is most likely to be received as the message x {\displaystyle x} after transmission. === Decoding conventions === Each codeword does not have an expected possibility: there may be more than one codeword with an equal likelihood of mutating into the received message. In such a case, the sender and receiver(s) must agree ahead of time on a decoding convention. Popular conventions include: Request that the codeword be resent – automatic repeat-request. Choose any random codeword from the set of most likely codewords which is nearer to that. If another code follows, mark the ambiguous bits of the codeword as erasures and hope that the outer code disambiguates them Report a decoding failure to the system == Maximum likelihood decoding == Given a received vector x ∈ F 2 n {\displaystyle x\in \mathbb {F} _{2}^{n}} maximum likelihood decoding picks a codeword y ∈ C {\displaystyle y\in C} that maximizes P ( x received ∣ y sent ) {\displaystyle \mathbb {P} (x{\mbox{ received}}\mid y{\mbox{ sent}})} , that is, the codeword y {\displaystyle y} that maximizes the probability that x {\displaystyle x} was received, given that y {\displaystyle y} was sent. If all codewords are equally likely to be sent then this scheme is equivalent to ideal observer decoding. In fact, by Bayes' theorem, P ( x received ∣ y sent ) = P ( x received , y sent ) P ( y sent ) = P ( y sent ∣ x received ) ⋅ P ( x received ) P ( y sent ) . {\displaystyle {\begin{aligned}\mathbb {P} (x{\mbox{ received}}\mid y{\mbox{ sent}})&{}={\frac {\mathbb {P} (x{\mbox{ received}},y{\mbox{ sent}})}{\mathbb {P} (y{\mbox{ sent}})}}\\&{}=\mathbb {P} (y{\mbox{ sent}}\mid x{\mbox{ received}})\cdot {\frac {\mathbb {P} (x{\mbox{ received}})}{\mathbb {P} (y{\mbox{ sent}})}}.\end{aligned}}} Upon fixing P ( x received ) {\displaystyle \mathbb {P} (x{\mbox{ received}})} , x {\displaystyle x} is restructured and P ( y sent ) {\displaystyle \mathbb {P} (y{\mbox{ sent}})} is constant as all codewords are equally likely to be sent. Therefore, P ( x received ∣ y sent ) {\displaystyle \mathbb {P} (x{\mbox{ received}}\mid y{\mbox{ sent}})} is maximised as a function of the variable y {\displaystyle y} precisely when P ( y sent ∣ x received ) {\displaystyle \mathbb {P} (y{\mbox{ sent}}\mid x{\mbox{ received}})} is maximised, and the claim follows. As with ideal observer decoding, a convention must be agreed to for non-unique decoding. The maximum likelihood decoding problem can also be modeled as an integer programming problem. The maximum likelihood decoding algorithm is an instance of the "marginalize a product function" problem which is solved by applying the generalized distributive law. == Minimum distance decoding == Given a received codeword x ∈ F 2 n {\displaystyle x\in \mathbb {F} _{2}^{n}} , minimum distance decoding picks a codeword y ∈ C {\displaystyle y\in C} to minimise the Hamming distance: d ( x , y ) = # { i : x i ≠ y i } {\displaystyle d(x,y)=\#\{i:x_{i}\not =y_{i}\}} i.e. choose the codeword y {\displaystyle y} that is as close as possible to x {\displaystyle x} . Note that if the probability of error on a discrete memoryless channel p {\displaystyle p} is strictly less than one half, then minimum distance decoding is equivalent to maximum likelihood decoding, since if d ( x , y ) = d , {\displaystyle d(x,y)=d,\,} then: P ( y received ∣ x sent ) = ( 1 − p ) n − d ⋅ p d = ( 1 − p ) n ⋅ ( p 1 − p ) d {\displaystyle {\begin{aligned}\mathbb {P} (y{\mbox{ received}}\mid x{\mbox{ sent}})&{}=(1-p)^{n-d}\cdot p^{d}\\&{}=(1-p)^{n}\cdot \left({\frac {p}{1-p}}\right)^{d}\\\end{aligned}}} which (since p is less than one half) is maximised by minimising d. Minimum distance decoding is also known as nearest neighbour decoding. It can be assisted or automated by using a standard array. Minimum distance decoding is a reasonable decoding method when the following conditions are met: The probability p {\displaystyle p} that an error occurs is independent of the position of the symbol. Errors are independent events – an error at one position in the message does not affect other positions. These assumptions may be reasonable for transmissions over a binary symmetric channel. They may be unreasonable for other media, such as a DVD, where a single scratch on the disk can cause an error in many neighbouring symbols or codewords. As with other decoding methods, a convention must be agreed to for non-unique decoding. == Syndrome decoding == Syndrome decoding is a highly efficient method of decoding a linear code over a noisy channel, i.e. one on which errors are made. In essence, syndrome decoding is minimum distance decoding using a reduced lookup table. This is allowed by the linearity of the code. Suppose that C ⊂ F 2 n {\displaystyle C\subset \mathbb {F} _{2}^{n}} is a linear code of length n {\displaystyle n} and minimum distance d {\displaystyle d} with parity-check matrix H {\displaystyle H} . Then clearly C {\displaystyle C} is capable of correcting up to t = ⌊ d − 1 2 ⌋ {\displaystyle t=\left\lfloor {\frac {d-1}{2}}\right\rfloor } errors made by the channel (since if no more than t {\displaystyle t} errors are made then minimum distance decoding will still correctly decode the incorrectly transmitted codeword). Now suppose that a codeword x ∈ F 2 n {\displaystyle x\in \mathbb {F} _{2}^{n}} is sent over the channel and the error pattern e ∈ F 2 n {\displaystyle e\in \mathbb {F} _{2}^{n}} occurs. Then z = x + e {\displaystyle z=x+e} is received. Ordinary minimum distance decoding would lookup the vector z {\displaystyle z} in a table of size | C | {\displaystyle |C|} for the nearest match - i.e. an element (not necessarily unique) c ∈ C {\displaystyle c\in C} with d ( c , z ) ≤ d ( y , z ) {\displaystyle d(c,z)\leq d(y,z)} for all y ∈ C {\displaystyle y\in C} . Syndrome decoding takes advantage of the property of the parity matrix that: H x = 0 {\displaystyle Hx=0} for all x ∈ C {\displaystyle x\in C} . The syndrome of the received z = x + e {\displaystyle z=x+e} is defined to be: H z = H ( x + e ) = H x + H e = 0 + H e = H e {\displaystyle Hz=H(x+e)=Hx+He=0+He=He} To perform ML decoding in a binary symmetric channel, one has to look-up a precomputed table of size 2 n − k {\displaystyle 2^{n-k}} , mapping H e {\displaystyle He} to e {\displaystyle e} . Note that this is already of significantly less complexity than that of a standard array decoding. However, under the assumption that no more than t {\displaystyle t} errors were made during transmission, the receiver can look up the value H e {\displaystyle He} in a further reduced table of size ∑ i = 0 t ( n i ) {\displaystyle {\begin{matrix}\sum _{i=0}^{t}{\binom {n}{i}}\\\end{matrix}}} == List decoding == == Information set decoding == This is a family of Las Vegas-probabilistic methods all based on the observation that it is easier to guess enough error-free positions, than it is to guess all the error-positions. The simplest form is due to Prange: Let G {\displaystyle G} be the k × n {\displaystyle k\times n} generator matrix of C {\displaystyle C} used for encoding. Select k {\displaystyle k} columns of G {\displaystyle G} at random, and denote by G ′ {\displaystyle G'} the corresponding submatrix of G {\displaystyle G} . With reasonable probability G ′ {\displaystyle G'} will have full rank, which means that if we let c ′ {\displaystyle c'} be the sub-vector for the corresponding positions of any codeword c = m G {\displaystyle c=mG} of C {\displaystyle C} for a message m {\displaystyle m} , we can recover m {\displaystyle m} as m = c ′ G ′ − 1 {\displaystyle m=c'G'^{-1}} . Hence, if we were lucky that these k {\displaystyle k} positions of the received word y {\displaystyle y} contained no errors, and hence equalled the positions of the sent codeword, then we may decode. If t {\displaystyle t} errors occurred, the probability of such a fortunate selection of columns is given by ( n − t k ) / ( n k ) {\displaystyle \textstyle {\binom {n-t}{k}}/{\binom {n}{k}}} . This method has been improved in various ways, e.g. by Stern and Canteaut and Sendrier. == Partial response maximum likelihood == Partial response maximum likelihood (PRML) is a method for converting the weak analog signal from the head of a magnetic disk or tape drive into a digital signal. == Viterbi decoder == A Viterbi decoder uses the Viterbi algorithm for decoding a bitstream that has been encoded using forward error correction based on a convolutional code. The Hamming distance is used as a metric for hard decision Viterbi decoders. The squared Euclidean distance is used as a metric for soft decision decoders. == Optimal decision decoding algorithm (ODDA) == Optimal decision decoding algorithm (ODDA) for an asymmetric TWRC system. == See also == Don't care alarm Error detection and correction Forbidden input == References == == Further reading == Hill, Raymond (1986). A first course in coding theory. Oxford Applied Mathematics and Computing Science Series. Oxford University Press. ISBN 978-0-19-853803-5. Pless, Vera (1982). Introduction to the theory of error-correcting codes. Wiley-Interscience Series in Discrete Mathematics. John Wiley & Sons. ISBN 978-0-471-08684-0. van Lint, Jacobus H. (1992). Introduction to Coding Theory. Graduate Texts in Mathematics (GTM). Vol. 86 (2 ed.). Springer-Verlag. ISBN 978-3-540-54894-2.
Wikipedia/Decoding_methods
Decision theory or the theory of rational choice is a branch of probability, economics, and analytic philosophy that uses expected utility and probability to model how individuals would behave rationally under uncertainty. It differs from the cognitive and behavioral sciences in that it is mainly prescriptive and concerned with identifying optimal decisions for a rational agent, rather than describing how people actually make decisions. Despite this, the field is important to the study of real human behavior by social scientists, as it lays the foundations to mathematically model and analyze individuals in fields such as sociology, economics, criminology, cognitive science, moral philosophy and political science. == History == The roots of decision theory lie in probability theory, developed by Blaise Pascal and Pierre de Fermat in the 17th century, which was later refined by others like Christiaan Huygens. These developments provided a framework for understanding risk and uncertainty, which are central to decision-making. In the 18th century, Daniel Bernoulli introduced the concept of "expected utility" in the context of gambling, which was later formalized by John von Neumann and Oskar Morgenstern in the 1940s. Their work on Game Theory and Expected Utility Theory helped establish a rational basis for decision-making under uncertainty. After World War II, decision theory expanded into economics, particularly with the work of economists like Milton Friedman and others, who applied it to market behavior and consumer choice theory. This era also saw the development of Bayesian decision theory, which incorporates Bayesian probability into decision-making models. By the late 20th century, scholars like Daniel Kahneman and Amos Tversky challenged the assumptions of rational decision-making. Their work in behavioral economics highlighted cognitive biases and heuristics that influence real-world decisions, leading to the development of prospect theory, which modified expected utility theory by accounting for psychological factors. == Branches == Normative decision theory is concerned with identification of optimal decisions where optimality is often determined by considering an ideal decision maker who is able to calculate with perfect accuracy and is in some sense fully rational. The practical application of this prescriptive approach (how people ought to make decisions) is called decision analysis and is aimed at finding tools, methodologies, and software (decision support systems) to help people make better decisions. In contrast, descriptive decision theory is concerned with describing observed behaviors often under the assumption that those making decisions are behaving under some consistent rules. These rules may, for instance, have a procedural framework (e.g. Amos Tversky's elimination by aspects model) or an axiomatic framework (e.g. stochastic transitivity axioms), reconciling the Von Neumann-Morgenstern axioms with behavioral violations of the expected utility hypothesis, or they may explicitly give a functional form for time-inconsistent utility functions (e.g. Laibson's quasi-hyperbolic discounting). Prescriptive decision theory is concerned with predictions about behavior that positive decision theory produces to allow for further tests of the kind of decision-making that occurs in practice. In recent decades, there has also been increasing interest in "behavioral decision theory", contributing to a re-evaluation of what useful decision-making requires. == Types of decisions == === Choice under uncertainty === The area of choice under uncertainty represents the heart of decision theory. Known from the 17th century (Blaise Pascal invoked it in his famous wager, which is contained in his Pensées, published in 1670), the idea of expected value is that, when faced with a number of actions, each of which could give rise to more than one possible outcome with different probabilities, the rational procedure is to identify all possible outcomes, determine their values (positive or negative) and the probabilities that will result from each course of action, and multiply the two to give an "expected value", or the average expectation for an outcome; the action to be chosen should be the one that gives rise to the highest total expected value. In 1738, Daniel Bernoulli published an influential paper entitled Exposition of a New Theory on the Measurement of Risk, in which he uses the St. Petersburg paradox to show that expected value theory must be normatively wrong. He gives an example in which a Dutch merchant is trying to decide whether to insure a cargo being sent from Amsterdam to St. Petersburg in winter. In his solution, he defines a utility function and computes expected utility rather than expected financial value. In the 20th century, interest was reignited by Abraham Wald's 1939 paper pointing out that the two central procedures of sampling-distribution-based statistical-theory, namely hypothesis testing and parameter estimation, are special cases of the general decision problem. Wald's paper renewed and synthesized many concepts of statistical theory, including loss functions, risk functions, admissible decision rules, antecedent distributions, Bayesian procedures, and minimax procedures. The phrase "decision theory" itself was used in 1950 by E. L. Lehmann. The revival of subjective probability theory, from the work of Frank Ramsey, Bruno de Finetti, Leonard Savage and others, extended the scope of expected utility theory to situations where subjective probabilities can be used. At the time, von Neumann and Morgenstern's theory of expected utility proved that expected utility maximization followed from basic postulates about rational behavior. The work of Maurice Allais and Daniel Ellsberg showed that human behavior has systematic and sometimes important departures from expected-utility maximization (Allais paradox and Ellsberg paradox). The prospect theory of Daniel Kahneman and Amos Tversky renewed the empirical study of economic behavior with less emphasis on rationality presuppositions. It describes a way by which people make decisions when all of the outcomes carry a risk. Kahneman and Tversky found three regularities – in actual human decision-making, "losses loom larger than gains"; people focus more on changes in their utility-states than they focus on absolute utilities; and the estimation of subjective probabilities is severely biased by anchoring. === Intertemporal choice === Intertemporal choice is concerned with the kind of choice where different actions lead to outcomes that are realized at different stages over time. It is also described as cost-benefit decision making since it involves the choices between rewards that vary according to magnitude and time of arrival. If someone received a windfall of several thousand dollars, they could spend it on an expensive holiday, giving them immediate pleasure, or they could invest it in a pension scheme, giving them an income at some time in the future. What is the optimal thing to do? The answer depends partly on factors such as the expected rates of interest and inflation, the person's life expectancy, and their confidence in the pensions industry. However even with all those factors taken into account, human behavior again deviates greatly from the predictions of prescriptive decision theory, leading to alternative models in which, for example, objective interest rates are replaced by subjective discount rates. === Interaction of decision makers === Some decisions are difficult because of the need to take into account how other people in the situation will respond to the decision that is taken. The analysis of such social decisions is often treated under decision theory, though it involves mathematical methods. In the emerging field of socio-cognitive engineering, the research is especially focused on the different types of distributed decision-making in human organizations, in normal and abnormal/emergency/crisis situations. === Complex decisions === Other areas of decision theory are concerned with decisions that are difficult simply because of their complexity, or the complexity of the organization that has to make them. Individuals making decisions are limited in resources (i.e. time and intelligence) and are therefore boundedly rational; the issue is thus, more than the deviation between real and optimal behavior, the difficulty of determining the optimal behavior in the first place. Decisions are also affected by whether options are framed together or separately; this is known as the distinction bias. == Heuristics == Heuristics are procedures for making a decision without working out the consequences of every option. Heuristics decrease the amount of evaluative thinking required for decisions, focusing on some aspects of the decision while ignoring others. While quicker than step-by-step processing, heuristic thinking is also more likely to involve fallacies or inaccuracies. One example of a common and erroneous thought process that arises through heuristic thinking is the gambler's fallacy — believing that an isolated random event is affected by previous isolated random events. For example, if flips of a fair coin give repeated tails, the coin still has the same probability (i.e., 0.5) of tails in future turns, though intuitively it might seems that heads becomes more likely. In the long run, heads and tails should occur equally often; people commit the gambler's fallacy when they use this heuristic to predict that a result of heads is "due" after a run of tails. Another example is that decision-makers may be biased towards preferring moderate alternatives to extreme ones. The compromise effect operates under a mindset that the most moderate option carries the most benefit. In an incomplete information scenario, as in most daily decisions, the moderate option will look more appealing than either extreme, independent of the context, based only on the fact that it has characteristics that can be found at either extreme. == Alternatives == A highly controversial issue is whether one can replace the use of probability in decision theory with something else. === Probability theory === Advocates for the use of probability theory point to: the work of Richard Threlkeld Cox for justification of the probability axioms, the Dutch book paradoxes of Bruno de Finetti as illustrative of the theoretical difficulties that can arise from departures from the probability axioms, and the complete class theorems, which show that all admissible decision rules are equivalent to the Bayesian decision rule for some utility function and some prior distribution (or for the limit of a sequence of prior distributions). Thus, for every decision rule, either the rule may be reformulated as a Bayesian procedure (or a limit of a sequence of such), or there is a rule that is sometimes better and never worse. === Alternatives to probability theory === The proponents of fuzzy logic, possibility theory, Dempster–Shafer theory, and info-gap decision theory maintain that probability is only one of many alternatives and point to many examples where non-standard alternatives have been implemented with apparent success. Notably, probabilistic decision theory can sometimes be sensitive to assumptions about the probabilities of various events, whereas non-probabilistic rules, such as minimax, are robust in that they do not make such assumptions. === Ludic fallacy === A general criticism of decision theory based on a fixed universe of possibilities is that it considers the "known unknowns", not the "unknown unknowns": it focuses on expected variations, not on unforeseen events, which some argue have outsized impact and must be considered – significant events may be "outside model". This line of argument, called the ludic fallacy, is that there are inevitable imperfections in modeling the real world by particular models, and that unquestioning reliance on models blinds one to their limits. == See also == == References == == Further reading ==
Wikipedia/Decision_theory
Neuroscience is the scientific study of the nervous system (the brain, spinal cord, and peripheral nervous system), its functions, and its disorders. It is a multidisciplinary science that combines physiology, anatomy, molecular biology, developmental biology, cytology, psychology, physics, computer science, chemistry, medicine, statistics, and mathematical modeling to understand the fundamental and emergent properties of neurons, glia and neural circuits. The understanding of the biological basis of learning, memory, behavior, perception, and consciousness has been described by Eric Kandel as the "epic challenge" of the biological sciences. The scope of neuroscience has broadened over time to include different approaches used to study the nervous system at different scales. The techniques used by neuroscientists have expanded enormously, from molecular and cellular studies of individual neurons to imaging of sensory, motor and cognitive tasks in the brain. == History == The earliest study of the nervous system dates to ancient Egypt. Trepanation, the surgical practice of either drilling or scraping a hole into the skull for the purpose of curing head injuries or mental disorders, or relieving cranial pressure, was first recorded during the Neolithic period. Manuscripts dating to 1700 BC indicate that the Egyptians had some knowledge about symptoms of brain damage. Early views on the function of the brain regarded it to be a "cranial stuffing" of sorts. In Egypt, from the late Middle Kingdom onwards, the brain was regularly removed in preparation for mummification. It was believed at the time that the heart was the seat of intelligence. According to Herodotus, the first step of mummification was to "take a crooked piece of iron, and with it draw out the brain through the nostrils, thus getting rid of a portion, while the skull is cleared of the rest by rinsing with drugs." The view that the heart was the source of consciousness was not challenged until the time of the Greek physician Hippocrates. He believed that the brain was not only involved with sensation—since most specialized organs (e.g., eyes, ears, tongue) are located in the head near the brain—but was also the seat of intelligence. Plato also speculated that the brain was the seat of the rational part of the soul. Aristotle, however, believed the heart was the center of intelligence and that the brain regulated the amount of heat from the heart. This view was generally accepted until the Roman physician Galen, a follower of Hippocrates and physician to Roman gladiators, observed that his patients lost their mental faculties when they had sustained damage to their brains. Abulcasis, Averroes, Avicenna, Avenzoar, and Maimonides, active in the Medieval Muslim world, described a number of medical problems related to the brain. In Renaissance Europe, Vesalius (1514–1564), René Descartes (1596–1650), Thomas Willis (1621–1675) and Jan Swammerdam (1637–1680) also made several contributions to neuroscience. Luigi Galvani's pioneering work in the late 1700s set the stage for studying the electrical excitability of muscles and neurons. In 1843 Emil du Bois-Reymond demonstrated the electrical nature of the nerve signal, whose speed Hermann von Helmholtz proceeded to measure, and in 1875 Richard Caton found electrical phenomena in the cerebral hemispheres of rabbits and monkeys. Adolf Beck published in 1890 similar observations of spontaneous electrical activity of the brain of rabbits and dogs. Studies of the brain became more sophisticated after the invention of the microscope and the development of a staining procedure by Camillo Golgi during the late 1890s. The procedure used a silver chromate salt to reveal the intricate structures of individual neurons. His technique was used by Santiago Ramón y Cajal and led to the formation of the neuron doctrine, the hypothesis that the functional unit of the brain is the neuron. Golgi and Ramón y Cajal shared the Nobel Prize in Physiology or Medicine in 1906 for their extensive observations, descriptions, and categorizations of neurons throughout the brain. In parallel with this research, in 1815 Jean Pierre Flourens induced localized lesions of the brain in living animals to observe their effects on motricity, sensibility and behavior. Work with brain-damaged patients by Marc Dax in 1836 and Paul Broca in 1865 suggested that certain regions of the brain were responsible for certain functions. At the time, these findings were seen as a confirmation of Franz Joseph Gall's theory that language was localized and that certain psychological functions were localized in specific areas of the cerebral cortex. The localization of function hypothesis was supported by observations of epileptic patients conducted by John Hughlings Jackson, who correctly inferred the organization of the motor cortex by watching the progression of seizures through the body. Carl Wernicke further developed the theory of the specialization of specific brain structures in language comprehension and production. Modern research through neuroimaging techniques, still uses the Brodmann cerebral cytoarchitectonic map (referring to the study of cell structure) anatomical definitions from this era in continuing to show that distinct areas of the cortex are activated in the execution of specific tasks. During the 20th century, neuroscience began to be recognized as a distinct academic discipline in its own right, rather than as studies of the nervous system within other disciplines. Eric Kandel and collaborators have cited David Rioch, Francis O. Schmitt, and Stephen Kuffler as having played critical roles in establishing the field. Rioch originated the integration of basic anatomical and physiological research with clinical psychiatry at the Walter Reed Army Institute of Research, starting in the 1950s. During the same period, Schmitt established a neuroscience research program within the Biology Department at the Massachusetts Institute of Technology, bringing together biology, chemistry, physics, and mathematics. The first freestanding neuroscience department (then called Psychobiology) was founded in 1964 at the University of California, Irvine by James L. McGaugh. This was followed by the Department of Neurobiology at Harvard Medical School, which was founded in 1966 by Stephen Kuffler. In the process of treating epilepsy, Wilder Penfield produced maps of the location of various functions (motor, sensory, memory, vision) in the brain. He summarized his findings in a 1950 book called The Cerebral Cortex of Man. Wilder Penfield and his co-investigators Edwin Boldrey and Theodore Rasmussen are considered to be the originators of the cortical homunculus. The understanding of neurons and of nervous system function became increasingly precise and molecular during the 20th century. For example, in 1952, Alan Lloyd Hodgkin and Andrew Huxley presented a mathematical model for the transmission of electrical signals in neurons of the giant axon of a squid, which they called "action potentials", and how they are initiated and propagated, known as the Hodgkin–Huxley model. In 1961–1962, Richard FitzHugh and J. Nagumo simplified Hodgkin–Huxley, in what is called the FitzHugh–Nagumo model. In 1962, Bernard Katz modeled neurotransmission across the space between neurons known as synapses. Beginning in 1966, Eric Kandel and collaborators examined biochemical changes in neurons associated with learning and memory storage in Aplysia. In 1981 Catherine Morris and Harold Lecar combined these models in the Morris–Lecar model. Such increasingly quantitative work gave rise to numerous biological neuron models and models of neural computation. As a result of the increasing interest about the nervous system, several prominent neuroscience organizations have been formed to provide a forum to all neuroscientists during the 20th century. For example, the International Brain Research Organization was founded in 1961, the International Society for Neurochemistry in 1963, the European Brain and Behaviour Society in 1968, and the Society for Neuroscience in 1969. Recently, the application of neuroscience research results has also given rise to applied disciplines as neuroeconomics, neuroeducation, neuroethics, and neurolaw. Over time, brain research has gone through philosophical, experimental, and theoretical phases, with work on neural implants and brain simulation predicted to be important in the future. == Modern neuroscience == The scientific study of the nervous system increased significantly during the second half of the twentieth century, principally due to advances in molecular biology, electrophysiology, and computational neuroscience. This has allowed neuroscientists to study the nervous system in all its aspects: how it is structured, how it works, how it develops, how it malfunctions, and how it can be changed. For example, it has become possible to understand, in much detail, the complex processes occurring within a single neuron. Neurons are cells specialized for communication. They are able to communicate with neurons and other cell types through specialized junctions called synapses, at which electrical or electrochemical signals can be transmitted from one cell to another. Many neurons extrude a long thin filament of axoplasm called an axon, which may extend to distant parts of the body and are capable of rapidly carrying electrical signals, influencing the activity of other neurons, muscles, or glands at their termination points. A nervous system emerges from the assemblage of neurons that are connected to each other in neural circuits, and networks. The vertebrate nervous system can be split into two parts: the central nervous system (defined as the brain and spinal cord), and the peripheral nervous system. In many species—including all vertebrates—the nervous system is the most complex organ system in the body, with most of the complexity residing in the brain. The human brain alone contains around one hundred billion neurons and one hundred trillion synapses; it consists of thousands of distinguishable substructures, connected to each other in synaptic networks whose intricacies have only begun to be unraveled. At least one out of three of the approximately 20,000 genes belonging to the human genome is expressed mainly in the brain. Due to the high degree of plasticity of the human brain, the structure of its synapses and their resulting functions change throughout life. Making sense of the nervous system's dynamic complexity is a formidable research challenge. Ultimately, neuroscientists would like to understand every aspect of the nervous system, including how it works, how it develops, how it malfunctions, and how it can be altered or repaired. Analysis of the nervous system is therefore performed at multiple levels, ranging from the molecular and cellular levels to the systems and cognitive levels. The specific topics that form the main focus of research change over time, driven by an ever-expanding base of knowledge and the availability of increasingly sophisticated technical methods. Improvements in technology have been the primary drivers of progress. Developments in electron microscopy, computer science, electronics, functional neuroimaging, and genetics and genomics have all been major drivers of progress. Advances in the classification of brain cells have been enabled by electrophysiological recording, single-cell genetic sequencing, and high-quality microscopy, which have combined into a single method pipeline called patch-sequencing in which all three methods are simultaneously applied using miniature tools. The efficiency of this method and the large amounts of data that is generated has allowed researchers to make some general conclusions about cell types; for example that the human and mouse brain have different versions of fundamentally the same cell types. === Molecular and cellular neuroscience === Basic questions addressed in molecular neuroscience include the mechanisms by which neurons express and respond to molecular signals and how axons form complex connectivity patterns. At this level, tools from molecular biology and genetics are used to understand how neurons develop and how genetic changes affect biological functions. The morphology, molecular identity, and physiological characteristics of neurons and how they relate to different types of behavior are also of considerable interest. Questions addressed in cellular neuroscience include the mechanisms of how neurons process signals physiologically and electrochemically. These questions include how signals are processed by neurites and somas and how neurotransmitters and electrical signals are used to process information in a neuron. Neurites are thin extensions from a neuronal cell body, consisting of dendrites (specialized to receive synaptic inputs from other neurons) and axons (specialized to conduct nerve impulses called action potentials). Somas are the cell bodies of the neurons and contain the nucleus. Another major area of cellular neuroscience is the investigation of the development of the nervous system. Questions include the patterning and regionalization of the nervous system, axonal and dendritic development, trophic interactions, synapse formation and the implication of fractones in neural stem cells, differentiation of neurons and glia (neurogenesis and gliogenesis), and neuronal migration. Computational neurogenetic modeling is concerned with the development of dynamic neuronal models for modeling brain functions with respect to genes and dynamic interactions between genes, on the cellular level (Computational Neurogenetic Modeling (CNGM) can also be used to model neural systems). === Neural circuits and systems === Systems neuroscience research centers on the structural and functional architecture of the developing human brain, and the functions of large-scale brain networks, or functionally-connected systems within the brain. Alongside brain development, systems neuroscience also focuses on how the structure and function of the brain enables or restricts the processing of sensory information, using learned mental models of the world, to motivate behavior. Questions in systems neuroscience include how neural circuits are formed and used anatomically and physiologically to produce functions such as reflexes, multisensory integration, motor coordination, circadian rhythms, emotional responses, learning, and memory. In other words, this area of research studies how connections are made and morphed in the brain, and the effect it has on human sensation, movement, attention, inhibitory control, decision-making, reasoning, memory formation, reward, and emotion regulation. Specific areas of interest for the field include observations of how the structure of neural circuits effect skill acquisition, how specialized regions of the brain develop and change (neuroplasticity), and the development of brain atlases, or wiring diagrams of individual developing brains. The related fields of neuroethology and neuropsychology address the question of how neural substrates underlie specific animal and human behaviors. Neuroendocrinology and psychoneuroimmunology examine interactions between the nervous system and the endocrine and immune systems, respectively. Despite many advancements, the way that networks of neurons perform complex cognitive processes and behaviors is still poorly understood. === Cognitive and behavioral neuroscience === Cognitive neuroscience addresses the questions of how psychological functions are produced by neural circuitry. The emergence of powerful new measurement techniques such as neuroimaging (e.g., fMRI, PET, SPECT), EEG, MEG, electrophysiology, optogenetics and human genetic analysis combined with sophisticated experimental techniques from cognitive psychology allows neuroscientists and psychologists to address abstract questions such as how cognition and emotion are mapped to specific neural substrates. Although many studies hold a reductionist stance looking for the neurobiological basis of cognitive phenomena, recent research shows that there is an interplay between neuroscientific findings and conceptual research, soliciting and integrating both perspectives. For example, neuroscience research on empathy solicited an interdisciplinary debate involving philosophy, psychology and psychopathology. Moreover, the neuroscientific identification of multiple memory systems related to different brain areas has challenged the idea of memory as a literal reproduction of the past, supporting a view of memory as a generative, constructive and dynamic process. Neuroscience is also allied with the social and behavioral sciences, as well as with nascent interdisciplinary fields. Examples of such alliances include neuroeconomics, decision theory, social neuroscience, and neuromarketing to address complex questions about interactions of the brain with its environment. A study into consumer responses for example uses EEG to investigate neural correlates associated with narrative transportation into stories about energy efficiency. === Computational neuroscience === Questions in computational neuroscience can span a wide range of levels of traditional analysis, such as development, structure, and cognitive functions of the brain. Research in this field utilizes mathematical models, theoretical analysis, and computer simulation to describe and verify biologically plausible neurons and nervous systems. For example, biological neuron models are mathematical descriptions of spiking neurons which can be used to describe both the behavior of single neurons as well as the dynamics of neural networks. Computational neuroscience is often referred to as theoretical neuroscience. === Neuroscience and medicine === ==== Clinical neuroscience ==== Neurology, psychiatry, neurosurgery, psychosurgery, anesthesiology and pain medicine, neuropathology, neuroradiology, ophthalmology, otolaryngology, clinical neurophysiology, addiction medicine, and sleep medicine are some medical specialties that specifically address the diseases of the nervous system. These terms also refer to clinical disciplines involving diagnosis and treatment of these diseases. Neurology works with diseases of the central and peripheral nervous systems, such as amyotrophic lateral sclerosis (ALS) and stroke, and their medical treatment. Psychiatry focuses on affective, behavioral, cognitive, and perceptual disorders. Anesthesiology focuses on perception of pain, and pharmacologic alteration of consciousness. Neuropathology focuses upon the classification and underlying pathogenic mechanisms of central and peripheral nervous system and muscle diseases, with an emphasis on morphologic, microscopic, and chemically observable alterations. Neurosurgery and psychosurgery work primarily with surgical treatment of diseases of the central and peripheral nervous systems. Neuroscience underlies the development of various neurotherapy methods to treat diseases of the nervous system. ==== Translational research ==== Recently, the boundaries between various specialties have blurred, as they are all influenced by basic research in neuroscience. For example, brain imaging enables objective biological insight into mental illnesses, which can lead to faster diagnosis, more accurate prognosis, and improved monitoring of patient progress over time. Integrative neuroscience describes the effort to combine models and information from multiple levels of research to develop a coherent model of the nervous system. For example, brain imaging coupled with physiological numerical models and theories of fundamental mechanisms may shed light on psychiatric disorders. Another important area of translational research is brain–computer interfaces (BCIs), or machines that are able to communicate and influence the brain. They are currently being researched for their potential to repair neural systems and restore certain cognitive functions. However, some ethical considerations have to be dealt with before they are accepted. == Major branches == Modern neuroscience education and research activities can be very roughly categorized into the following major branches, based on the subject and scale of the system in examination as well as distinct experimental or curricular approaches. Individual neuroscientists, however, often work on questions that span several distinct subfields. == Careers in neuroscience == Source: === Bachelor's Level === === Master's Level === === Advanced Degree === == Neuroscience organizations == The largest professional neuroscience organization is the Society for Neuroscience (SFN), which is based in the United States but includes many members from other countries. Since its founding in 1969 the SFN has grown steadily: as of 2010 it recorded 40,290 members from 83 countries. Annual meetings, held each year in a different American city, draw attendance from researchers, postdoctoral fellows, graduate students, and undergraduates, as well as educational institutions, funding agencies, publishers, and hundreds of businesses that supply products used in research. Other major organizations devoted to neuroscience include the International Brain Research Organization (IBRO), which holds its meetings in a country from a different part of the world each year, and the Federation of European Neuroscience Societies (FENS), which holds a meeting in a different European city every two years. FENS comprises a set of 32 national-level organizations, including the British Neuroscience Association, the German Neuroscience Society (Neurowissenschaftliche Gesellschaft), and the French Société des Neurosciences. The first National Honor Society in Neuroscience, Nu Rho Psi, was founded in 2006. Numerous youth neuroscience societies which support undergraduates, graduates and early career researchers also exist, such as Simply Neuroscience and Project Encephalon. In 2013, the BRAIN Initiative was announced in the US. The International Brain Initiative was created in 2017, currently integrated by more than seven national-level brain research initiatives (US, Europe, Allen Institute, Japan, China, Australia, Canada, Korea, and Israel) spanning four continents. === Public education and outreach === In addition to conducting traditional research in laboratory settings, neuroscientists have also been involved in the promotion of awareness and knowledge about the nervous system among the general public and government officials. Such promotions have been done by both individual neuroscientists and large organizations. For example, individual neuroscientists have promoted neuroscience education among young students by organizing the International Brain Bee, which is an academic competition for high school or secondary school students worldwide. In the United States, large organizations such as the Society for Neuroscience have promoted neuroscience education by developing a primer called Brain Facts, collaborating with public school teachers to develop Neuroscience Core Concepts for K-12 teachers and students, and cosponsoring a campaign with the Dana Foundation called Brain Awareness Week to increase public awareness about the progress and benefits of brain research. In Canada, the Canadian Institutes of Health Research's (CIHR) Canadian National Brain Bee is held annually at McMaster University. Neuroscience educators formed a Faculty for Undergraduate Neuroscience (FUN) in 1992 to share best practices and provide travel awards for undergraduates presenting at Society for Neuroscience meetings. Neuroscientists have also collaborated with other education experts to study and refine educational techniques to optimize learning among students, an emerging field called educational neuroscience. Federal agencies in the United States, such as the National Institute of Health (NIH) and National Science Foundation (NSF), have also funded research that pertains to best practices in teaching and learning of neuroscience concepts. == Engineering applications of neuroscience == === Neuromorphic computer chips === Neuromorphic engineering is a branch of neuroscience that deals with creating functional physical models of neurons for the purposes of useful computation. The emergent computational properties of neuromorphic computers are fundamentally different from conventional computers in the sense that they are complex systems, and that the computational components are interrelated with no central processor. One example of such a computer is the SpiNNaker supercomputer. Sensors can also be made smart with neuromorphic technology. An example of this is the Event Camera's BrainScaleS (brain-inspired Multiscale Computation in Neuromorphic Hybrid Systems), a hybrid analog neuromorphic supercomputer located at Heidelberg University in Germany. It was developed as part of the Human Brain Project's neuromorphic computing platform and is the complement to the SpiNNaker supercomputer, which is based on digital technology. The architecture used in BrainScaleS mimics biological neurons and their connections on a physical level; additionally, since the components are made of silicon, these model neurons operate on average 864 times (24 hours of real time is 100 seconds in the machine simulation) that of their biological counterparts. Recent advances in neuromorphic microchip technology have led a group of scientists to create an artificial neuron that can replace real neurons in diseases. == Nobel prizes related to neuroscience == == See also == == References == == Further reading == == External links == Neuroscience on In Our Time at the BBC Neuroscience Information Framework (NIF) American Society for Neurochemistry British Neuroscience Association (BNA) Federation of European Neuroscience Societies Neuroscience Online (electronic neuroscience textbook) HHMI Neuroscience lecture series - Making Your Mind: Molecules, Motion, and Memory Archived 2013-06-24 at the Wayback Machine Société des Neurosciences Neuroscience For Kids
Wikipedia/Neuroscience
A conformal field theory (CFT) is a quantum field theory that is invariant under conformal transformations. In two dimensions, there is an infinite-dimensional algebra of local conformal transformations, and conformal field theories can sometimes be exactly solved or classified. Conformal field theory has important applications to condensed matter physics, statistical mechanics, quantum statistical mechanics, and string theory. Statistical and condensed matter systems are indeed often conformally invariant at their thermodynamic or quantum critical points. == Scale invariance vs conformal invariance == In quantum field theory, scale invariance is a common and natural symmetry, because any fixed point of the renormalization group is by definition scale invariant. Conformal symmetry is stronger than scale invariance, and one needs additional assumptions to argue that it should appear in nature. The basic idea behind its plausibility is that local scale invariant theories have their currents given by T μ ν ξ ν {\displaystyle T_{\mu \nu }\xi ^{\nu }} where ξ ν {\displaystyle \xi ^{\nu }} is a Killing vector and T μ ν {\displaystyle T_{\mu \nu }} is a conserved operator (the stress-tensor) of dimension exactly ⁠ d {\displaystyle d} ⁠. For the associated symmetries to include scale but not conformal transformations, the trace T μ μ {\displaystyle T_{\mu }{}^{\mu }} has to be a non-zero total derivative implying that there is a non-conserved operator of dimension exactly ⁠ d − 1 {\displaystyle d-1} ⁠. Under some assumptions it is possible to completely rule out this type of non-renormalization and hence prove that scale invariance implies conformal invariance in a quantum field theory, for example in unitary compact conformal field theories in two dimensions. While it is possible for a quantum field theory to be scale invariant but not conformally invariant, examples are rare. For this reason, the terms are often used interchangeably in the context of quantum field theory. == Two dimensions vs higher dimensions == The number of independent conformal transformations is infinite in two dimensions, and finite in higher dimensions. This makes conformal symmetry much more constraining in two dimensions. All conformal field theories share the ideas and techniques of the conformal bootstrap. But the resulting equations are more powerful in two dimensions, where they are sometimes exactly solvable (for example in the case of minimal models), in contrast to higher dimensions, where numerical approaches dominate. The development of conformal field theory has been earlier and deeper in the two-dimensional case, in particular after the 1983 article by Belavin, Polyakov and Zamolodchikov. The term conformal field theory has sometimes been used with the meaning of two-dimensional conformal field theory, as in the title of a 1997 textbook. Higher-dimensional conformal field theories have become more popular with the AdS/CFT correspondence in the late 1990s, and the development of numerical conformal bootstrap techniques in the 2000s. === Global vs local conformal symmetry in two dimensions === The global conformal group of the Riemann sphere is the group of Möbius transformations ⁠ P S L 2 ( C ) {\displaystyle \mathrm {PSL} _{2}(\mathbb {C} )} ⁠, which is finite-dimensional. On the other hand, infinitesimal conformal transformations form the infinite-dimensional Witt algebra: the conformal Killing equations in two dimensions, ∂ μ ξ ν + ∂ ν ξ μ = ∂ ⋅ ξ η μ ν , {\displaystyle \partial _{\mu }\xi _{\nu }+\partial _{\nu }\xi _{\mu }=\partial \cdot \xi \eta _{\mu \nu },~} reduce to just the Cauchy-Riemann equations, ⁠ ∂ z ¯ ξ ( z ) = 0 = ∂ z ξ ( z ¯ ) {\displaystyle \partial _{\bar {z}}\xi (z)=0=\partial _{z}\xi ({\bar {z}})} ⁠, the infinity of modes of arbitrary analytic coordinate transformations ξ ( z ) {\displaystyle \xi (z)} yield the infinity of Killing vector fields ⁠ z n ∂ z {\displaystyle z^{n}\partial _{z}} ⁠. Strictly speaking, it is possible for a two-dimensional conformal field theory to be local (in the sense of possessing a stress-tensor) while still only exhibiting invariance under the global ⁠ P S L 2 ( C ) {\displaystyle \mathrm {PSL} _{2}(\mathbb {C} )} ⁠. This turns out to be unique to non-unitary theories; an example is the biharmonic scalar. This property should be viewed as even more special than scale without conformal invariance as it requires T μ μ {\displaystyle T_{\mu }{}^{\mu }} to be a total second derivative. Global conformal symmetry in two dimensions is a special case of conformal symmetry in higher dimensions, and is studied with the same techniques. This is done not only in theories that have global but not local conformal symmetry, but also in theories that do have local conformal symmetry, for the purpose of testing techniques or ideas from higher-dimensional CFT. In particular, numerical bootstrap techniques can be tested by applying them to minimal models, and comparing the results with the known analytic results that follow from local conformal symmetry. === Conformal field theories with a Virasoro symmetry algebra === In a conformally invariant two-dimensional quantum theory, the Witt algebra of infinitesimal conformal transformations has to be centrally extended. The quantum symmetry algebra is therefore the Virasoro algebra, which depends on a number called the central charge. This central extension can also be understood in terms of a conformal anomaly. It was shown by Alexander Zamolodchikov that there exists a function which decreases monotonically under the renormalization group flow of a two-dimensional quantum field theory, and is equal to the central charge for a two-dimensional conformal field theory. This is known as the Zamolodchikov C-theorem, and tells us that renormalization group flow in two dimensions is irreversible. In addition to being centrally extended, the symmetry algebra of a conformally invariant quantum theory has to be complexified, resulting in two copies of the Virasoro algebra. In Euclidean CFT, these copies are called holomorphic and antiholomorphic. In Lorentzian CFT, they are called left-moving and right moving. Both copies have the same central charge. The space of states of a theory is a representation of the product of the two Virasoro algebras. This space is a Hilbert space if the theory is unitary. This space may contain a vacuum state, or in statistical mechanics, a thermal state. Unless the central charge vanishes, there cannot exist a state that leaves the entire infinite dimensional conformal symmetry unbroken. The best we can have is a state that is invariant under the generators L n ≥ − 1 {\displaystyle L_{n\geq -1}} of the Virasoro algebra, whose basis is ⁠ ( L n ) n ∈ Z {\displaystyle (L_{n})_{n\in \mathbb {Z} }} ⁠. This contains the generators L − 1 , L 0 , L 1 {\displaystyle L_{-1},L_{0},L_{1}} of the global conformal transformations. The rest of the conformal group is spontaneously broken. == Conformal symmetry == === Definition and Jacobian === For a given spacetime and metric, a conformal transformation is a transformation that preserves angles. We will focus on conformal transformations of the flat d {\displaystyle d} -dimensional Euclidean space R d {\displaystyle \mathbb {R} ^{d}} or of the Minkowski space ⁠ R 1 , d − 1 {\displaystyle \mathbb {R} ^{1,d-1}} ⁠. If x → f ( x ) {\displaystyle x\to f(x)} is a conformal transformation, the Jacobian J ν μ ( x ) = ∂ f μ ( x ) ∂ x ν {\displaystyle J_{\nu }^{\mu }(x)={\frac {\partial f^{\mu }(x)}{\partial x^{\nu }}}} is of the form J ν μ ( x ) = Ω ( x ) R ν μ ( x ) , {\displaystyle J_{\nu }^{\mu }(x)=\Omega (x)R_{\nu }^{\mu }(x),} where Ω ( x ) {\displaystyle \Omega (x)} is the scale factor, and R ν μ ( x ) {\displaystyle R_{\nu }^{\mu }(x)} is a rotation (i.e. an orthogonal matrix) or Lorentz transformation. === Conformal group === The conformal group of Euclidean space is locally isomorphic to ⁠ S O ( 1 , d + 1 ) {\displaystyle \mathrm {SO} (1,d+1)} ⁠, and of Minkowski space is ⁠ S O ( 2 , d ) {\displaystyle \mathrm {SO} (2,d)} ⁠. This includes translations, rotations (Euclidean) or Lorentz transformations (Minkowski), and dilations i.e. scale transformations x μ → λ x μ . {\displaystyle x^{\mu }\to \lambda x^{\mu }.} This also includes special conformal transformations. For any translation ⁠ T a ( x ) = x + a {\displaystyle T_{a}(x)=x+a} ⁠, there is a special conformal transformation S a = I ∘ T a ∘ I , {\displaystyle S_{a}=I\circ T_{a}\circ I,} where I {\displaystyle I} is the inversion such that I ( x μ ) = x μ x 2 . {\displaystyle I\left(x^{\mu }\right)={\frac {x^{\mu }}{x^{2}}}.} In the sphere ⁠ S d = R d ∪ { ∞ } {\displaystyle S^{d}=\mathbb {R} ^{d}\cup \{\infty \}} ⁠, the inversion exchanges 0 {\displaystyle 0} with ⁠ ∞ {\displaystyle \infty } ⁠. Translations leave ∞ {\displaystyle \infty } fixed, while special conformal transformations leave 0 {\displaystyle 0} fixed. === Conformal algebra === The commutation relations of the corresponding Lie algebra are [ P μ , P ν ] = 0 , [ D , K μ ] = − K μ , [ D , P μ ] = P μ , [ K μ , K ν ] = 0 , [ K μ , P ν ] = η μ ν D − i M μ ν , {\displaystyle {\begin{aligned}[][P_{\mu },P_{\nu }]&=0,\\[][D,K_{\mu }]&=-K_{\mu },\\[][D,P_{\mu }]&=P_{\mu },\\[][K_{\mu },K_{\nu }]&=0,\\[][K_{\mu },P_{\nu }]&=\eta _{\mu \nu }D-iM_{\mu \nu },\end{aligned}}} where P {\displaystyle P} generate translations, D {\displaystyle D} generates dilations, K μ {\displaystyle K_{\mu }} generate special conformal transformations, and M μ ν {\displaystyle M_{\mu \nu }} generate rotations or Lorentz transformations. The tensor η μ ν {\displaystyle \eta _{\mu \nu }} is the flat metric. === Global issues in Minkowski space === In Minkowski space, the conformal group does not preserve causality. Observables such as correlation functions are invariant under the conformal algebra, but not under the conformal group. As shown by Lüscher and Mack, it is possible to restore the invariance under the conformal group by extending the flat Minkowski space into a Lorentzian cylinder. The original Minkowski space is conformally equivalent to a region of the cylinder called a Poincaré patch. In the cylinder, global conformal transformations do not violate causality: instead, they can move points outside the Poincaré patch. == Correlation functions and conformal bootstrap == In the conformal bootstrap approach, a conformal field theory is a set of correlation functions that obey a number of axioms. The n {\displaystyle n} -point correlation function ⟨ O 1 ( x 1 ) ⋯ O n ( x n ) ⟩ {\displaystyle \left\langle O_{1}(x_{1})\cdots O_{n}(x_{n})\right\rangle } is a function of the positions x i {\displaystyle x_{i}} and other parameters of the fields ⁠ O 1 , … , O n {\displaystyle O_{1},\dots ,O_{n}} ⁠. In the bootstrap approach, the fields themselves make sense only in the context of correlation functions, and may be viewed as efficient notations for writing axioms for correlation functions. Correlation functions depend linearly on fields, in particular ⁠ ∂ x 1 ⟨ O 1 ( x 1 ) ⋯ ⟩ = ⟨ ∂ x 1 O 1 ( x 1 ) ⋯ ⟩ {\displaystyle \partial _{x_{1}}\left\langle O_{1}(x_{1})\cdots \right\rangle =\left\langle \partial _{x_{1}}O_{1}(x_{1})\cdots \right\rangle } ⁠. We focus on CFT on the Euclidean space ⁠ R d {\displaystyle \mathbb {R} ^{d}} ⁠. In this case, correlation functions are Schwinger functions. They are defined for ⁠ x i ≠ x j {\displaystyle x_{i}\neq x_{j}} ⁠, and do not depend on the order of the fields. In Minkowski space, correlation functions are Wightman functions. They can depend on the order of the fields, as fields commute only if they are spacelike separated. A Euclidean CFT can be related to a Minkowskian CFT by Wick rotation, for example thanks to the Osterwalder-Schrader theorem. In such cases, Minkowskian correlation functions are obtained from Euclidean correlation functions by an analytic continuation that depends on the order of the fields. === Behaviour under conformal transformations === Any conformal transformation x → f ( x ) {\displaystyle x\to f(x)} acts linearly on fields ⁠ O ( x ) → π f ( O ) ( x ) {\displaystyle O(x)\to \pi _{f}(O)(x)} ⁠, such that f → π f {\displaystyle f\to \pi _{f}} is a representation of the conformal group, and correlation functions are invariant: ⟨ π f ( O 1 ) ( x 1 ) ⋯ π f ( O n ) ( x n ) ⟩ = ⟨ O 1 ( x 1 ) ⋯ O n ( x n ) ⟩ . {\displaystyle \left\langle \pi _{f}(O_{1})(x_{1})\cdots \pi _{f}(O_{n})(x_{n})\right\rangle =\left\langle O_{1}(x_{1})\cdots O_{n}(x_{n})\right\rangle .} Primary fields are fields that transform into themselves via ⁠ π f {\displaystyle \pi _{f}} ⁠. The behaviour of a primary field is characterized by a number Δ {\displaystyle \Delta } called its conformal dimension, and a representation ρ {\displaystyle \rho } of the rotation or Lorentz group. For a primary field, we then have π f ( O ) ( x ) = Ω ( x ′ ) − Δ ρ ( R ( x ′ ) ) O ( x ′ ) , where x ′ = f − 1 ( x ) . {\displaystyle \pi _{f}(O)(x)=\Omega (x')^{-\Delta }\rho (R(x'))O(x'),\quad {\text{where}}\ x'=f^{-1}(x).} Here Ω ( x ) {\displaystyle \Omega (x)} and R ( x ) {\displaystyle R(x)} are the scale factor and rotation that are associated to the conformal transformation ⁠ f {\displaystyle f} ⁠. The representation ρ {\displaystyle \rho } is trivial in the case of scalar fields, which transform as ⁠ π f ( O ) ( x ) = Ω ( x ′ ) − Δ O ( x ′ ) {\displaystyle \pi _{f}(O)(x)=\Omega (x')^{-\Delta }O(x')} ⁠. For vector fields, the representation ρ {\displaystyle \rho } is the fundamental representation, and we would have ⁠ π f ( O μ ) ( x ) = Ω ( x ′ ) − Δ R μ ν ( x ′ ) O ν ( x ′ ) {\displaystyle \pi _{f}(O_{\mu })(x)=\Omega (x')^{-\Delta }R_{\mu }^{\nu }(x')O_{\nu }(x')} ⁠. A primary field that is characterized by the conformal dimension Δ {\displaystyle \Delta } and representation ρ {\displaystyle \rho } behaves as a highest-weight vector in an induced representation of the conformal group from the subgroup generated by dilations and rotations. In particular, the conformal dimension Δ {\displaystyle \Delta } characterizes a representation of the subgroup of dilations. In two dimensions, the fact that this induced representation is a Verma module appears throughout the literature. For higher-dimensional CFTs (in which the maximally compact subalgebra is larger than the Cartan subalgebra), it has recently been appreciated that this representation is a parabolic or generalized Verma module. Derivatives (of any order) of primary fields are called descendant fields. Their behaviour under conformal transformations is more complicated. For example, if O {\displaystyle O} is a primary field, then π f ( ∂ μ O ) ( x ) = ∂ μ ( π f ( O ) ( x ) ) {\displaystyle \pi _{f}(\partial _{\mu }O)(x)=\partial _{\mu }\left(\pi _{f}(O)(x)\right)} is a linear combination of ∂ μ O {\displaystyle \partial _{\mu }O} and ⁠ O {\displaystyle O} ⁠. Correlation functions of descendant fields can be deduced from correlation functions of primary fields. However, even in the common case where all fields are either primaries or descendants thereof, descendant fields play an important role, because conformal blocks and operator product expansions involve sums over all descendant fields. The collection of all primary fields ⁠ O p {\displaystyle O_{p}} ⁠, characterized by their scaling dimensions Δ p {\displaystyle \Delta _{p}} and the representations ⁠ ρ p {\displaystyle \rho _{p}} ⁠, is called the spectrum of the theory. === Dependence on field positions === The invariance of correlation functions under conformal transformations severely constrain their dependence on field positions. In the case of two- and three-point functions, that dependence is determined up to finitely many constant coefficients. Higher-point functions have more freedom, and are only determined up to functions of conformally invariant combinations of the positions. The two-point function of two primary fields vanishes if their conformal dimensions differ. Δ 1 ≠ Δ 2 ⟹ ⟨ O 1 ( x 1 ) O 2 ( x 2 ) ⟩ = 0. {\displaystyle \Delta _{1}\neq \Delta _{2}\implies \left\langle O_{1}(x_{1})O_{2}(x_{2})\right\rangle =0.} If the dilation operator is diagonalizable (i.e. if the theory is not logarithmic), there exists a basis of primary fields such that two-point functions are diagonal, i.e. ⁠ i ≠ j ⟹ ⟨ O i O j ⟩ = 0 {\displaystyle i\neq j\implies \left\langle O_{i}O_{j}\right\rangle =0} ⁠. In this case, the two-point function of a scalar primary field is ⟨ O ( x 1 ) O ( x 2 ) ⟩ = 1 | x 1 − x 2 | 2 Δ , {\displaystyle \left\langle O(x_{1})O(x_{2})\right\rangle ={\frac {1}{|x_{1}-x_{2}|^{2\Delta }}},} where we choose the normalization of the field such that the constant coefficient, which is not determined by conformal symmetry, is one. Similarly, two-point functions of non-scalar primary fields are determined up to a coefficient, which can be set to one. In the case of a symmetric traceless tensor of rank ⁠ ℓ {\displaystyle \ell } ⁠, the two-point function is ⟨ O μ 1 , … , μ ℓ ( x 1 ) O ν 1 , … , ν ℓ ( x 2 ) ⟩ = ∏ i = 1 ℓ I μ i , ν i ( x 1 − x 2 ) − traces | x 1 − x 2 | 2 Δ , {\displaystyle \left\langle O_{\mu _{1},\dots ,\mu _{\ell }}(x_{1})O_{\nu _{1},\dots ,\nu _{\ell }}(x_{2})\right\rangle ={\frac {\prod _{i=1}^{\ell }I_{\mu _{i},\nu _{i}}(x_{1}-x_{2})-{\text{traces}}}{|x_{1}-x_{2}|^{2\Delta }}},} where the tensor I μ , ν ( x ) {\displaystyle I_{\mu ,\nu }(x)} is defined as I μ , ν ( x ) = η μ ν − 2 x μ x ν x 2 . {\displaystyle I_{\mu ,\nu }(x)=\eta _{\mu \nu }-{\frac {2x_{\mu }x_{\nu }}{x^{2}}}.} The three-point function of three scalar primary fields is ⟨ O 1 ( x 1 ) O 2 ( x 2 ) O 3 ( x 3 ) ⟩ = C 123 | x 12 | Δ 1 + Δ 2 − Δ 3 | x 13 | Δ 1 + Δ 3 − Δ 2 | x 23 | Δ 2 + Δ 3 − Δ 1 , {\displaystyle \left\langle O_{1}(x_{1})O_{2}(x_{2})O_{3}(x_{3})\right\rangle ={\frac {C_{123}}{|x_{12}|^{\Delta _{1}+\Delta _{2}-\Delta _{3}}|x_{13}|^{\Delta _{1}+\Delta _{3}-\Delta _{2}}|x_{23}|^{\Delta _{2}+\Delta _{3}-\Delta _{1}}}},} where ⁠ x i j = x i − x j {\displaystyle x_{ij}=x_{i}-x_{j}} ⁠, and C 123 {\displaystyle C_{123}} is a three-point structure constant. With primary fields that are not necessarily scalars, conformal symmetry allows a finite number of tensor structures, and there is a structure constant for each tensor structure. In the case of two scalar fields and a symmetric traceless tensor of rank ⁠ ℓ {\displaystyle \ell } ⁠, there is only one tensor structure, and the three-point function is ⟨ O 1 ( x 1 ) O 2 ( x 2 ) O μ 1 , … , μ ℓ ( x 3 ) ⟩ = C 123 ( ∏ i = 1 ℓ V μ i − traces ) | x 12 | Δ 1 + Δ 2 − Δ 3 | x 13 | Δ 1 + Δ 3 − Δ 2 | x 23 | Δ 2 + Δ 3 − Δ 1 , {\displaystyle \left\langle O_{1}(x_{1})O_{2}(x_{2})O_{\mu _{1},\dots ,\mu _{\ell }}(x_{3})\right\rangle ={\frac {C_{123}\left(\prod _{i=1}^{\ell }V_{\mu _{i}}-{\text{traces}}\right)}{|x_{12}|^{\Delta _{1}+\Delta _{2}-\Delta _{3}}|x_{13}|^{\Delta _{1}+\Delta _{3}-\Delta _{2}}|x_{23}|^{\Delta _{2}+\Delta _{3}-\Delta _{1}}}},} where we introduce the vector V μ = x 13 μ x 23 2 − x 23 μ x 13 2 | x 12 | | x 13 | | x 23 | . {\displaystyle V_{\mu }={\frac {x_{13}^{\mu }x_{23}^{2}-x_{23}^{\mu }x_{13}^{2}}{|x_{12}||x_{13}||x_{23}|}}.} Four-point functions of scalar primary fields are determined up to arbitrary functions g ( u , v ) {\displaystyle g(u,v)} of the two cross-ratios u = x 12 2 x 34 2 x 13 2 x 24 2 , v = x 14 2 x 23 2 x 13 2 x 24 2 . {\displaystyle u={\frac {x_{12}^{2}x_{34}^{2}}{x_{13}^{2}x_{24}^{2}}}\ ,\ v={\frac {x_{14}^{2}x_{23}^{2}}{x_{13}^{2}x_{24}^{2}}}.} The four-point function is then ⟨ ∏ i = 1 4 O i ( x i ) ⟩ = ( | x 24 | | x 14 | ) Δ 1 − Δ 2 ( | x 14 | | x 13 | ) Δ 3 − Δ 4 | x 12 | Δ 1 + Δ 2 | x 34 | Δ 3 + Δ 4 g ( u , v ) . {\displaystyle \left\langle \prod _{i=1}^{4}O_{i}(x_{i})\right\rangle ={\frac {\left({\frac {|x_{24}|}{|x_{14}|}}\right)^{\Delta _{1}-\Delta _{2}}\left({\frac {|x_{14}|}{|x_{13}|}}\right)^{\Delta _{3}-\Delta _{4}}}{|x_{12}|^{\Delta _{1}+\Delta _{2}}|x_{34}|^{\Delta _{3}+\Delta _{4}}}}g(u,v).} === Operator product expansion === The operator product expansion (OPE) is more powerful in conformal field theory than in more general quantum field theories. This is because in conformal field theory, the operator product expansion's radius of convergence is finite (i.e. it is not zero). Provided the positions x 1 , x 2 {\displaystyle x_{1},x_{2}} of two fields are close enough, the operator product expansion rewrites the product of these two fields as a linear combination of fields at a given point, which can be chosen as x 2 {\displaystyle x_{2}} for technical convenience. The operator product expansion of two fields takes the form O 1 ( x 1 ) O 2 ( x 2 ) = ∑ k c 12 k ( x 1 − x 2 ) O k ( x 2 ) , {\displaystyle O_{1}(x_{1})O_{2}(x_{2})=\sum _{k}c_{12k}(x_{1}-x_{2})O_{k}(x_{2}),} where c 12 k ( x ) {\displaystyle c_{12k}(x)} is some coefficient function, and the sum in principle runs over all fields in the theory. (Equivalently, by the state-field correspondence, the sum runs over all states in the space of states.) Some fields may actually be absent, in particular due to constraints from symmetry: conformal symmetry, or extra symmetries. If all fields are primary or descendant, the sum over fields can be reduced to a sum over primaries, by rewriting the contributions of any descendant in terms of the contribution of the corresponding primary: O 1 ( x 1 ) O 2 ( x 2 ) = ∑ p C 12 p P p ( x 1 − x 2 , ∂ x 2 ) O p ( x 2 ) , {\displaystyle O_{1}(x_{1})O_{2}(x_{2})=\sum _{p}C_{12p}P_{p}(x_{1}-x_{2},\partial _{x_{2}})O_{p}(x_{2}),} where the fields O p {\displaystyle O_{p}} are all primary, and C 12 p {\displaystyle C_{12p}} is the three-point structure constant (which for this reason is also called OPE coefficient). The differential operator P p ( x 1 − x 2 , ∂ x 2 ) {\displaystyle P_{p}(x_{1}-x_{2},\partial _{x_{2}})} is an infinite series in derivatives, which is determined by conformal symmetry and therefore in principle known. Viewing the OPE as a relation between correlation functions shows that the OPE must be associative. Furthermore, if the space is Euclidean, the OPE must be commutative, because correlation functions do not depend on the order of the fields, i.e. ⁠ O 1 ( x 1 ) O 2 ( x 2 ) = O 2 ( x 2 ) O 1 ( x 1 ) {\displaystyle O_{1}(x_{1})O_{2}(x_{2})=O_{2}(x_{2})O_{1}(x_{1})} ⁠. The existence of the operator product expansion is a fundamental axiom of the conformal bootstrap. However, it is generally not necessary to compute operator product expansions and in particular the differential operators ⁠ P p ( x 1 − x 2 , ∂ x 2 ) {\displaystyle P_{p}(x_{1}-x_{2},\partial _{x_{2}})} ⁠. Rather, it is the decomposition of correlation functions into structure constants and conformal blocks that is needed. The OPE can in principle be used for computing conformal blocks, but in practice there are more efficient methods. === Conformal blocks and crossing symmetry === Using the OPE ⁠ O 1 ( x 1 ) O 2 ( x 2 ) {\displaystyle O_{1}(x_{1})O_{2}(x_{2})} ⁠, a four-point function can be written as a combination of three-point structure constants and s-channel conformal blocks, ⟨ ∏ i = 1 4 O i ( x i ) ⟩ = ∑ p C 12 p C p 34 G p ( s ) ( x i ) . {\displaystyle \left\langle \prod _{i=1}^{4}O_{i}(x_{i})\right\rangle =\sum _{p}C_{12p}C_{p34}G_{p}^{(s)}(x_{i}).} The conformal block G p ( s ) ( x i ) {\displaystyle G_{p}^{(s)}(x_{i})} is the sum of the contributions of the primary field O p {\displaystyle O_{p}} and its descendants. It depends on the fields O i {\displaystyle O_{i}} and their positions. If the three-point functions ⟨ O 1 O 2 O p ⟩ {\displaystyle \left\langle O_{1}O_{2}O_{p}\right\rangle } or ⟨ O 3 O 4 O p ⟩ {\displaystyle \left\langle O_{3}O_{4}O_{p}\right\rangle } involve several independent tensor structures, the structure constants and conformal blocks depend on these tensor structures, and the primary field O p {\displaystyle O_{p}} contributes several independent blocks. Conformal blocks are determined by conformal symmetry, and known in principle. To compute them, there are recursion relations and integrable techniques. Using the OPE O 1 ( x 1 ) O 4 ( x 4 ) {\displaystyle O_{1}(x_{1})O_{4}(x_{4})} or ⁠ O 1 ( x 1 ) O 3 ( x 3 ) {\displaystyle O_{1}(x_{1})O_{3}(x_{3})} ⁠, the same four-point function is written in terms of t-channel conformal blocks or u-channel conformal blocks, ⟨ ∏ i = 1 4 O i ( x i ) ⟩ = ∑ p C 14 p C p 23 G p ( t ) ( x i ) = ∑ p C 13 p C p 24 G p ( u ) ( x i ) . {\displaystyle \left\langle \prod _{i=1}^{4}O_{i}(x_{i})\right\rangle =\sum _{p}C_{14p}C_{p23}G_{p}^{(t)}(x_{i})=\sum _{p}C_{13p}C_{p24}G_{p}^{(u)}(x_{i}).} The equality of the s-, t- and u-channel decompositions is called crossing symmetry: a constraint on the spectrum of primary fields, and on the three-point structure constants. Conformal blocks obey the same conformal symmetry constraints as four-point functions. In particular, s-channel conformal blocks can be written in terms of functions g p ( s ) ( u , v ) {\displaystyle g_{p}^{(s)}(u,v)} of the cross-ratios. While the OPE O 1 ( x 1 ) O 2 ( x 2 ) {\displaystyle O_{1}(x_{1})O_{2}(x_{2})} only converges if ⁠ | x 12 | < min ( | x 23 | , | x 24 | ) {\displaystyle \vert x_{12}\vert <\min(\vert x_{23}\vert ,\vert x_{24}\vert )} ⁠, conformal blocks can be analytically continued to all (non pairwise coinciding) values of the positions. In Euclidean space, conformal blocks are single-valued real-analytic functions of the positions except when the four points x i {\displaystyle x_{i}} lie on a circle but in a singly-transposed cyclic order [1324], and only in these exceptional cases does the decomposition into conformal blocks not converge. A conformal field theory in flat Euclidean space R d {\displaystyle \mathbb {R} ^{d}} is thus defined by its spectrum { ( Δ p , ρ p ) } {\displaystyle \{(\Delta _{p},\rho _{p})\}} and OPE coefficients (or three-point structure constants) ⁠ { C p p ′ p ″ } {\displaystyle \{C_{pp'p''}\}} ⁠, satisfying the constraint that all four-point functions are crossing-symmetric. From the spectrum and OPE coefficients (collectively referred to as the CFT data), correlation functions of arbitrary order can be computed. == Features == === Unitarity === A conformal field theory is unitary if its space of states has a positive definite scalar product such that the dilation operator is self-adjoint. Then the scalar product endows the space of states with the structure of a Hilbert space. In Euclidean conformal field theories, unitarity is equivalent to reflection positivity of correlation functions: one of the Osterwalder-Schrader axioms. Unitarity implies that the conformal dimensions of primary fields are real and bounded from below. The lower bound depends on the spacetime dimension ⁠ d {\displaystyle d} ⁠, and on the representation of the rotation or Lorentz group in which the primary field transforms. For scalar fields, the unitarity bound is Δ ≥ 1 2 ( d − 2 ) . {\displaystyle \Delta \geq {\frac {1}{2}}(d-2).} In a unitary theory, three-point structure constants must be real, which in turn implies that four-point functions obey certain inequalities. Powerful numerical bootstrap methods are based on exploiting these inequalities. === Compactness === A conformal field theory is compact if it obeys three conditions: All conformal dimensions are real. For any Δ ∈ R {\displaystyle \Delta \in \mathbb {R} } there are finitely many states whose dimensions are less than ⁠ Δ {\displaystyle \Delta } ⁠. There is a unique state with the dimension ⁠ Δ = 0 {\displaystyle \Delta =0} ⁠, and it is the vacuum state, i.e. the corresponding field is the identity field. (The identity field is the field whose insertion into correlation functions does not modify them, i.e. ⁠ ⟨ I ( x ) ⋯ ⟩ = ⟨ ⋯ ⟩ {\displaystyle \left\langle I(x)\cdots \right\rangle =\left\langle \cdots \right\rangle } ⁠.) The name comes from the fact that if a 2D conformal field theory is also a sigma model, it will satisfy these conditions if and only if its target space is compact. It is believed that all unitary conformal field theories are compact in dimension ⁠ d > 2 {\displaystyle d>2} ⁠. Without unitarity, on the other hand, it is possible to find CFTs in dimension four and in dimension 4 − ϵ {\displaystyle 4-\epsilon } that have a continuous spectrum. And in dimension two, Liouville theory is unitary but not compact. === Extra symmetries === A conformal field theory may have extra symmetries in addition to conformal symmetry. For example, the Ising model has a Z 2 {\displaystyle \mathbb {Z} _{2}} symmetry, and superconformal field theories have supersymmetry. == Examples == === Mean field theory === A generalized free field is a field whose correlation functions are deduced from its two-point function by Wick's theorem. For instance, if ϕ {\displaystyle \phi } is a scalar primary field of dimension ⁠ Δ {\displaystyle \Delta } ⁠, its four-point function reads ⟨ ∏ i = 1 4 ϕ ( x i ) ⟩ = 1 | x 12 | 2 Δ | x 34 | 2 Δ + 1 | x 13 | 2 Δ | x 24 | 2 Δ + 1 | x 14 | 2 Δ | x 23 | 2 Δ . {\displaystyle \left\langle \prod _{i=1}^{4}\phi (x_{i})\right\rangle ={\frac {1}{|x_{12}|^{2\Delta }|x_{34}|^{2\Delta }}}+{\frac {1}{|x_{13}|^{2\Delta }|x_{24}|^{2\Delta }}}+{\frac {1}{|x_{14}|^{2\Delta }|x_{23}|^{2\Delta }}}.} For instance, if ϕ 1 , ϕ 2 {\displaystyle \phi _{1},\phi _{2}} are two scalar primary fields such that ⟨ ϕ 1 ϕ 2 ⟩ = 0 {\displaystyle \langle \phi _{1}\phi _{2}\rangle =0} (which is the case in particular if Δ 1 ≠ Δ 2 {\displaystyle \Delta _{1}\neq \Delta _{2}} ), we have the four-point function ⟨ ϕ 1 ( x 1 ) ϕ 1 ( x 2 ) ϕ 2 ( x 3 ) ϕ 2 ( x 4 ) ⟩ = 1 | x 12 | 2 Δ 1 | x 34 | 2 Δ 2 . {\displaystyle {\Big \langle }\phi _{1}(x_{1})\phi _{1}(x_{2})\phi _{2}(x_{3})\phi _{2}(x_{4}){\Big \rangle }={\frac {1}{|x_{12}|^{2\Delta _{1}}|x_{34}|^{2\Delta _{2}}}}.} Mean field theory is a generic name for conformal field theories that are built from generalized free fields. For example, a mean field theory can be built from one scalar primary field ⁠ ϕ {\displaystyle \phi } ⁠. Then this theory contains ⁠ ϕ {\displaystyle \phi } ⁠, its descendant fields, and the fields that appear in the OPE \phi \phi. The primary fields that appear in ϕ ϕ {\displaystyle \phi \phi } can be determined by decomposing the four-point function ⟨ ϕ ϕ ϕ ϕ ⟩ {\displaystyle \langle \phi \phi \phi \phi \rangle } in conformal blocks: their conformal dimensions belong to 2 Δ + 2 N {\displaystyle 2\Delta +2\mathbb {N} } : in mean field theory, the conformal dimension is conserved modulo integers. Structure constants can be computed exactly in terms of the Gamma function. Similarly, it is possible to construct mean field theories starting from a field with non-trivial Lorentz spin. For example, the 4d Maxwell theory (in the absence of charged matter fields) is a mean field theory built out of an antisymmetric tensor field F μ ν {\displaystyle F_{\mu \nu }} with scaling dimension ⁠ Δ = 2 {\displaystyle \Delta =2} ⁠. Mean field theories have a Lagrangian description in terms of a quadratic action involving Laplacian raised to an arbitrary real power (which determines the scaling dimension of the field). For a generic scaling dimension, the power of the Laplacian is non-integer. The corresponding mean field theory is then non-local (e.g. it does not have a conserved stress tensor operator). === Critical Ising model === The critical Ising model is the critical point of the Ising model on a hypercubic lattice in two or three dimensions. It has a Z 2 {\displaystyle \mathbb {Z} _{2}} global symmetry, corresponding to flipping all spins. The two-dimensional critical Ising model includes the M ( 4 , 3 ) {\displaystyle {\mathcal {M}}(4,3)} Virasoro minimal model, which can be solved exactly. There is no Ising CFT in d ≥ 4 {\displaystyle d\geq 4} dimensions. === Critical Potts model === The critical Potts model with q = 2 , 3 , 4 , ⋯ {\displaystyle q=2,3,4,\cdots } colors is a unitary CFT that is invariant under the permutation group ⁠ S q {\displaystyle S_{q}} ⁠. It is a generalization of the critical Ising model, which corresponds to ⁠ q = 2 {\displaystyle q=2} ⁠. The critical Potts model exists in a range of dimensions depending on ⁠ q {\displaystyle q} ⁠. The critical Potts model may be constructed as the continuum limit of the Potts model on d-dimensional hypercubic lattice. In the Fortuin-Kasteleyn reformulation in terms of clusters, the Potts model can be defined for ⁠ q ∈ C {\displaystyle q\in \mathbb {C} } ⁠, but it is not unitary if q {\displaystyle q} is not integer. === Critical O(N) model === The critical O(N) model is a CFT invariant under the orthogonal group. For any integer ⁠ N {\displaystyle N} ⁠, it exists as an interacting, unitary and compact CFT in d = 3 {\displaystyle d=3} dimensions (and for N = 1 {\displaystyle N=1} also in two dimensions). It is a generalization of the critical Ising model, which corresponds to the O(N) CFT at ⁠ N = 1 {\displaystyle N=1} ⁠. The O(N) CFT can be constructed as the continuum limit of a lattice model with spins that are N-vectors, called the n-vector model. Alternatively, the critical O ( N ) {\displaystyle O(N)} model can be constructed as the ε → 1 {\displaystyle \varepsilon \to 1} limit of Wilson–Fisher fixed point in d = 4 − ε {\displaystyle d=4-\varepsilon } dimensions. At ⁠ ε = 0 {\displaystyle \varepsilon =0} ⁠, the Wilson–Fisher fixed point becomes the tensor product of N {\displaystyle N} free scalars with dimension ⁠ Δ = 1 {\displaystyle \Delta =1} ⁠. For 0 < ε < 1 {\displaystyle 0<\varepsilon <1} the model in question is non-unitary. When N is large, the O(N) model can be solved perturbatively in a 1/N expansion by means of the Hubbard–Stratonovich transformation. In particular, the N → ∞ {\displaystyle N\to \infty } limit of the critical O(N) model is well-understood. The conformal data of the critical O(N) model are functions of N and of the dimension, on which many results are known. === Conformal gauge theories === Some conformal field theories in three and four dimensions admit a Lagrangian description in the form of a gauge theory, either abelian or non-abelian. Examples of such CFTs are conformal QED with sufficiently many charged fields in d = 3 {\displaystyle d=3} or the Banks-Zaks fixed point in ⁠ d = 4 {\displaystyle d=4} ⁠. == Applications == === Continuous phase transitions === Continuous phase transitions (critical points) of classical statistical physics systems with D spatial dimensions are often described by Euclidean conformal field theories. A necessary condition for this to happen is that the critical point should be invariant under spatial rotations and translations. However this condition is not sufficient: some exceptional critical points are described by scale invariant but not conformally invariant theories. If the classical statistical physics system is reflection positive, the corresponding Euclidean CFT describing its critical point will be unitary. Continuous quantum phase transitions in condensed matter systems with D spatial dimensions may be described by Lorentzian D+1 dimensional conformal field theories (related by Wick rotation to Euclidean CFTs in D + 1 dimensions). Apart from translation and rotation invariance, an additional necessary condition for this to happen is that the dynamical critical exponent z should be equal to 1. CFTs describing such quantum phase transitions (in absence of quenched disorder) are always unitary. === String theory === World-sheet description of string theory involves a two-dimensional CFT coupled to dynamical two-dimensional quantum gravity (or supergravity, in case of superstring theory). Consistency of string theory models imposes constraints on the central charge of this CFT, which should be c = 26 in bosonic string theory and c = 10 in superstring theory. Coordinates of the spacetime in which string theory lives correspond to bosonic fields of this CFT. === AdS/CFT correspondence === Conformal field theories play a prominent role in the AdS/CFT correspondence, in which a gravitational theory in anti-de Sitter space (AdS) is equivalent to a conformal field theory on the AdS boundary. Notable examples are d = 4, N = 4 supersymmetric Yang–Mills theory, which is dual to Type IIB string theory on AdS5 × S5, and d = 3, N = 6 super-Chern–Simons theory, which is dual to M-theory on AdS4 × S7. (The prefix "super" denotes supersymmetry, N denotes the degree of extended supersymmetry possessed by the theory, and d the number of space-time dimensions on the boundary.) === Conformal perturbation theory === By perturbing a conformal field theory, it is possible to construct other field theories, conformal or not. Their correlation functions can be computed perturbatively from the correlation functions of the original CFT, by a technique called conformal perturbation theory. For example, a type of perturbation consists in discretizing a conformal field theory by studying it on a discrete spacetime. The resulting finite-size effects can be computed using conformal perturbation theory. == See also == == References == == Further reading == Rychkov, Slava (2016). "EPFL Lectures on Conformal Field Theory in D ≥ 3 Dimensions". SpringerBriefs in Physics. arXiv:1601.05000. doi:10.1007/978-3-319-43626-5. ISBN 978-3-319-43625-8. S2CID 119192484. Martin Schottenloher, A Mathematical Introduction to Conformal Field Theory, Springer-Verlag, Berlin, Heidelberg, 1997. ISBN 3-540-61753-1, 2nd edition 2008, ISBN 978-3-540-68625-5. == External links == Media related to Conformal field theory at Wikimedia Commons
Wikipedia/Conformal_field_theory
In physics, the algebra of physical space (APS) is the use of the Clifford or geometric algebra Cl3,0(R) of the three-dimensional Euclidean space as a model for (3+1)-dimensional spacetime, representing a point in spacetime via a paravector (3-dimensional vector plus a 1-dimensional scalar). The Clifford algebra Cl3,0(R) has a faithful representation, generated by Pauli matrices, on the spin representation C2; further, Cl3,0(R) is isomorphic to the even subalgebra Cl[0]3,1(R) of the Clifford algebra Cl3,1(R). APS can be used to construct a compact, unified and geometrical formalism for both classical and quantum mechanics. APS should not be confused with spacetime algebra (STA), which concerns the Clifford algebra Cl1,3(R) of the four-dimensional Minkowski spacetime. == Special relativity == === Spacetime position paravector === In APS, the spacetime position is represented as the paravector x = x 0 + x 1 e 1 + x 2 e 2 + x 3 e 3 , {\displaystyle x=x^{0}+x^{1}\mathbf {e} _{1}+x^{2}\mathbf {e} _{2}+x^{3}\mathbf {e} _{3},} where the time is given by the scalar part x0 = t, and e1, e2, e3 is a basis for position space. Throughout, units such that c = 1 are used, called natural units. In the Pauli matrix representation, the unit basis vectors are replaced by the Pauli matrices and the scalar part by the identity matrix. This means that the Pauli matrix representation of the space-time position is x → ( x 0 + x 3 x 1 − i x 2 x 1 + i x 2 x 0 − x 3 ) {\displaystyle x\rightarrow {\begin{pmatrix}x^{0}+x^{3}&&x^{1}-ix^{2}\\x^{1}+ix^{2}&&x^{0}-x^{3}\end{pmatrix}}} === Lorentz transformations and rotors === The restricted Lorentz transformations that preserve the direction of time and include rotations and boosts can be performed by an exponentiation of the spacetime rotation biparavector W L = e W / 2 . {\displaystyle L=e^{W/2}.} In the matrix representation, the Lorentz rotor is seen to form an instance of the SL(2, C) group (special linear group of degree 2 over the complex numbers), which is the double cover of the Lorentz group. The unimodularity of the Lorentz rotor is translated in the following condition in terms of the product of the Lorentz rotor with its Clifford conjugation L L ¯ = L ¯ L = 1. {\displaystyle L{\bar {L}}={\bar {L}}L=1.} This Lorentz rotor can be always decomposed in two factors, one Hermitian B = B†, and the other unitary R† = R−1, such that L = B R . {\displaystyle L=BR.} The unitary element R is called a rotor because this encodes rotations, and the Hermitian element B encodes boosts. === Four-velocity paravector === The four-velocity, also called proper velocity, is defined as the derivative of the spacetime position paravector with respect to proper time τ: u = d x d τ = d x 0 d τ + d d τ ( x 1 e 1 + x 2 e 2 + x 3 e 3 ) = d x 0 d τ [ 1 + d d x 0 ( x 1 e 1 + x 2 e 2 + x 3 e 3 ) ] . {\displaystyle u={\frac {dx}{d\tau }}={\frac {dx^{0}}{d\tau }}+{\frac {d}{d\tau }}(x^{1}\mathbf {e} _{1}+x^{2}\mathbf {e} _{2}+x^{3}\mathbf {e} _{3})={\frac {dx^{0}}{d\tau }}\left[1+{\frac {d}{dx^{0}}}(x^{1}\mathbf {e} _{1}+x^{2}\mathbf {e} _{2}+x^{3}\mathbf {e} _{3})\right].} This expression can be brought to a more compact form by defining the ordinary velocity as v = d d x 0 ( x 1 e 1 + x 2 e 2 + x 3 e 3 ) , {\displaystyle \mathbf {v} ={\frac {d}{dx^{0}}}(x^{1}\mathbf {e} _{1}+x^{2}\mathbf {e} _{2}+x^{3}\mathbf {e} _{3}),} and recalling the definition of the gamma factor: γ ( v ) = 1 1 − | v | 2 c 2 , {\displaystyle \gamma (\mathbf {v} )={\frac {1}{\sqrt {1-{\frac {|\mathbf {v} |^{2}}{c^{2}}}}}},} so that the proper velocity is more compactly: u = γ ( v ) ( 1 + v ) . {\displaystyle u=\gamma (\mathbf {v} )(1+\mathbf {v} ).} The proper velocity is a positive unimodular paravector, which implies the following condition in terms of the Clifford conjugation u u ¯ = 1. {\displaystyle u{\bar {u}}=1.} The proper velocity transforms under the action of the Lorentz rotor L as u → u ′ = L u L † . {\displaystyle u\rightarrow u^{\prime }=LuL^{\dagger }.} === Four-momentum paravector === The four-momentum in APS can be obtained by multiplying the proper velocity with the mass as p = m u , {\displaystyle p=mu,} with the mass shell condition translated into p ¯ p = m 2 . {\displaystyle {\bar {p}}p=m^{2}.} == Classical electrodynamics == === Electromagnetic field, potential, and current === The electromagnetic field is represented as a bi-paravector F: F = E + i B , {\displaystyle F=\mathbf {E} +i\mathbf {B} ,} with the Hermitian part representing the electric field E and the anti-Hermitian part representing the magnetic field B. In the standard Pauli matrix representation, the electromagnetic field is: F → ( E 3 E 1 − i E 2 E 1 + i E 2 − E 3 ) + i ( B 3 B 1 − i B 2 B 1 + i B 2 − B 3 ) . {\displaystyle F\rightarrow {\begin{pmatrix}E_{3}&E_{1}-iE_{2}\\E_{1}+iE_{2}&-E_{3}\end{pmatrix}}+i{\begin{pmatrix}B_{3}&B_{1}-iB_{2}\\B_{1}+iB_{2}&-B_{3}\end{pmatrix}}\,.} The source of the field F is the electromagnetic four-current: j = ρ + j , {\displaystyle j=\rho +\mathbf {j} \,,} where the scalar part equals the electric charge density ρ, and the vector part the electric current density j. Introducing the electromagnetic potential paravector defined as: A = ϕ + A , {\displaystyle A=\phi +\mathbf {A} \,,} in which the scalar part equals the electric potential ϕ, and the vector part the magnetic potential A. The electromagnetic field is then also: F = ∂ A ¯ . {\displaystyle F=\partial {\bar {A}}.} The field can be split into electric E = ⟨ ∂ A ¯ ⟩ V {\displaystyle E=\langle \partial {\bar {A}}\rangle _{V}} and magnetic B = i ⟨ ∂ A ¯ ⟩ B V {\displaystyle B=i\langle \partial {\bar {A}}\rangle _{BV}} components. Here, ∂ = ∂ t + e 1 ∂ x + e 2 ∂ y + e 3 ∂ z {\displaystyle \partial =\partial _{t}+\mathbf {e} _{1}\,\partial _{x}+\mathbf {e} _{2}\,\partial _{y}+\mathbf {e} _{3}\,\partial _{z}} and F is invariant under a gauge transformation of the form A → A + ∂ χ , {\displaystyle A\rightarrow A+\partial \chi \,,} where χ {\displaystyle \chi } is a scalar field. The electromagnetic field is covariant under Lorentz transformations according to the law F → F ′ = L F L ¯ . {\displaystyle F\rightarrow F^{\prime }=LF{\bar {L}}\,.} === Maxwell's equations and the Lorentz force === The Maxwell equations can be expressed in a single equation: ∂ ¯ F = 1 ϵ j ¯ , {\displaystyle {\bar {\partial }}F={\frac {1}{\epsilon }}{\bar {j}}\,,} where the overbar represents the Clifford conjugation. The Lorentz force equation takes the form d p d τ = e ⟨ F u ⟩ R . {\displaystyle {\frac {dp}{d\tau }}=e\langle Fu\rangle _{R}\,.} === Electromagnetic Lagrangian === The electromagnetic Lagrangian is L = 1 2 ⟨ F F ⟩ S − ⟨ A j ¯ ⟩ S , {\displaystyle L={\frac {1}{2}}\langle FF\rangle _{S}-\langle A{\bar {j}}\rangle _{S}\,,} which is a real scalar invariant. == Relativistic quantum mechanics == The Dirac equation, for an electrically charged particle of mass m and charge e, takes the form: i ∂ ¯ Ψ e 3 + e A ¯ Ψ = m Ψ ¯ † , {\displaystyle i{\bar {\partial }}\Psi \mathbf {e} _{3}+e{\bar {A}}\Psi =m{\bar {\Psi }}^{\dagger },} where e3 is an arbitrary unitary vector, and A is the electromagnetic paravector potential as above. The electromagnetic interaction has been included via minimal coupling in terms of the potential A. == Classical spinor == The differential equation of the Lorentz rotor that is consistent with the Lorentz force is d Λ d τ = e 2 m c F Λ , {\displaystyle {\frac {d\Lambda }{d\tau }}={\frac {e}{2mc}}F\Lambda ,} such that the proper velocity is calculated as the Lorentz transformation of the proper velocity at rest u = Λ Λ † , {\displaystyle u=\Lambda \Lambda ^{\dagger },} which can be integrated to find the space-time trajectory x ( τ ) {\displaystyle x(\tau )} with the additional use of d x d τ = u . {\displaystyle {\frac {dx}{d\tau }}=u.} == See also == Paravector Multivector wikibooks:Physics Using Geometric Algebra Dirac equation in the algebra of physical space Algebra == References == === Textbooks === Baylis, William (2002). Electrodynamics: A Modern Geometric Approach (2nd ed.). Springer. ISBN 0-8176-4025-8. Baylis, William, ed. (1999) [1996]. Clifford (Geometric) Algebras: with applications to physics, mathematics, and engineering. Springer. ISBN 978-0-8176-3868-9. Doran, Chris; Lasenby, Anthony (2007) [2003]. Geometric Algebra for Physicists. Cambridge University Press. ISBN 978-1-139-64314-6. Hestenes, David (1999). New Foundations for Classical Mechanics (2nd ed.). Kluwer. ISBN 0-7923-5514-8. === Articles === Baylis, W E (2004). "Relativity in introductory physics". Canadian Journal of Physics. 82 (11): 853–873. arXiv:physics/0406158. Bibcode:2004CaJPh..82..853B. doi:10.1139/p04-058. S2CID 35027499. Baylis, W E; Jones, G (7 January 1989). "The Pauli algebra approach to special relativity". Journal of Physics A: Mathematical and General. 22 (1): 1–15. Bibcode:1989JPhA...22....1B. doi:10.1088/0305-4470/22/1/008. Baylis, W. E. (1 March 1992). "Classical eigenspinors and the Dirac equation". Physical Review A. 45 (7): 4293–4302. Bibcode:1992PhRvA..45.4293B. doi:10.1103/physreva.45.4293. PMID 9907503. Baylis, W. E.; Yao, Y. (1 July 1999). "Relativistic dynamics of charges in electromagnetic fields: An eigenspinor approach". Physical Review A. 60 (2): 785–795. Bibcode:1999PhRvA..60..785B. doi:10.1103/physreva.60.785.
Wikipedia/Algebra_of_physical_space
In probability theory and related fields, Malliavin calculus is a set of mathematical techniques and ideas that extend the mathematical field of calculus of variations from deterministic functions to stochastic processes. In particular, it allows the computation of derivatives of random variables. Malliavin calculus is also called the stochastic calculus of variations. P. Malliavin first initiated the calculus on infinite dimensional space. Then, the significant contributors such as S. Kusuoka, D. Stroock, J-M. Bismut, Shinzo Watanabe, I. Shigekawa, and so on finally completed the foundations. Malliavin calculus is named after Paul Malliavin whose ideas led to a proof that Hörmander's condition implies the existence and smoothness of a density for the solution of a stochastic differential equation; Hörmander's original proof was based on the theory of partial differential equations. The calculus has been applied to stochastic partial differential equations as well. The calculus allows integration by parts with random variables; this operation is used in mathematical finance to compute the sensitivities of financial derivatives. The calculus has applications in, for example, stochastic filtering. == Overview and history == Malliavin introduced Malliavin calculus to provide a stochastic proof that Hörmander's condition implies the existence of a density for the solution of a stochastic differential equation; Hörmander's original proof was based on the theory of partial differential equations. His calculus enabled Malliavin to prove regularity bounds for the solution's density. The calculus has been applied to stochastic partial differential equations. == Gaussian probability space == Consider a Wiener functional F {\displaystyle F} (a functional from the classical Wiener space) and consider the task of finding a derivative for it. The natural idea would be to use the Gateaux derivative D g F := d d τ F [ f + τ g ] | τ = 0 , {\displaystyle D_{g}F:=\left.{\frac {d}{d\tau }}F[f+\tau g]\right|_{\tau =0},} however this does not always exist. Therefore it does make sense to find a new differential calculus for such spaces by limiting the directions. The toy model of Malliavin calculus is an irreducible Gaussian probability space X = ( Ω , F , P , H ) {\displaystyle X=(\Omega ,{\mathcal {F}},P,{\mathcal {H}})} . This is a (complete) probability space ( Ω , F , P ) {\displaystyle (\Omega ,{\mathcal {F}},P)} together with a closed subspace H ⊂ L 2 ( Ω , F , P ) {\displaystyle {\mathcal {H}}\subset L^{2}(\Omega ,{\mathcal {F}},P)} such that all H ∈ H {\displaystyle H\in {\mathcal {H}}} are mean zero Gaussian variables and F = σ ( H : H ∈ H ) {\displaystyle {\mathcal {F}}=\sigma (H:H\in {\mathcal {H}})} . If one chooses a basis for H {\displaystyle {\mathcal {H}}} then one calls X {\displaystyle X} a numerical model. On the other hand, for any separable Hilbert space G {\displaystyle {\mathcal {G}}} exists a canonical irreducible Gaussian probability space Seg ⁡ ( G ) {\displaystyle \operatorname {Seg} ({\mathcal {G}})} named the Segal model (named after Irving Segal) having G {\displaystyle {\mathcal {G}}} as its Gaussian subspace. In this case for a g ∈ G {\displaystyle g\in {\mathcal {G}}} one notates the associated random variable in Seg ⁡ ( G ) {\displaystyle \operatorname {Seg} ({\mathcal {G}})} as W ( g ) {\displaystyle W(g)} . Properties of a Gaussian probability space that do not depend on the particular choice of basis are called intrinsic and such that do depend on the choice extrensic. We denote the countably infinite product of real spaces as R N = ∏ i = 1 ∞ R {\displaystyle \mathbb {R} ^{\mathbb {N} }=\prod \limits _{i=1}^{\infty }\mathbb {R} } . Recall the modern version of the Cameron-Martin theorem Consider a locally convex vector space E {\displaystyle E} with a cylindrical Gaussian measure γ {\displaystyle \gamma } on it. For an element in the topological dual f ∈ E ′ {\displaystyle f\in E'} define the distance to the mean t γ ( f ) := f − ∫ E f ( x ) γ ( d x ) , {\displaystyle t_{\gamma }(f):=f-\int _{E}f(x)\gamma (\mathrm {d} x),} which is a map t γ : E ′ → L 2 ( E , γ ) {\displaystyle t_{\gamma }\colon E'\to L^{2}(E,\gamma )} , and denote the closure in L 2 ( E , γ ) {\displaystyle L^{2}(E,\gamma )} as E γ ′ := clos ⁡ { t γ ( f ) : f ∈ E ′ } {\displaystyle E_{\gamma }':=\operatorname {clos} \left\{t_{\gamma }(f)\colon \ f\in E'\right\}} Let γ m := γ ( ⋅ − m ) {\displaystyle \gamma _{m}:=\gamma (\cdot -m)} denote the translation by m ∈ E {\displaystyle m\in E} . Then E γ ′ {\displaystyle E_{\gamma }'} respectively the covariance operator R γ : E γ ′ → ( E γ ′ ) ∗ {\displaystyle R_{\gamma }:E_{\gamma }'\to (E_{\gamma }')^{*}} on it induces a reproducing kernel Hilbert space R {\displaystyle R} called the Cameron-Martin space such that for any m ∈ R {\displaystyle m\in R} there is equivalence γ m ∼ γ {\displaystyle \gamma _{m}\sim \gamma } . In fact one can use here the Feldman–Hájek theorem to find that for any other h ∉ R {\displaystyle h\not \in R} such measure would be singular. Let γ {\displaystyle \gamma } be the canonical Gaussian measure, by transferring the Cameron-Martin theorem from ( R N , B ( R N ) , γ N = ⊗ n ∈ N γ ) {\displaystyle (\mathbb {R} ^{\mathbb {N} },{\mathcal {B}}(\mathbb {R} ^{\mathbb {N} }),\gamma ^{\mathbb {N} }=\otimes _{n\in \mathbb {N} }\gamma )} into a numerical model X {\displaystyle X} , the additive group of H {\displaystyle {\mathcal {H}}} will define a quasi-automorphism group on Ω {\displaystyle \Omega } . A construction can be done as follows: choose an orthonormal basis in H {\displaystyle {\mathcal {H}}} , let τ α ( x ) = x + α {\displaystyle \tau _{\alpha }(x)=x+\alpha } denote the translation on R N {\displaystyle \mathbb {R} ^{\mathbb {N} }} by α {\displaystyle \alpha } , denote the map into the Cameron-Martin space by j : H → ℓ 2 {\displaystyle j:{\mathcal {H}}\to \ell ^{2}} , denote L ∞ − 0 ( Ω , F , P ) = ⋂ p < ∞ L p ( Ω , F , P ) {\displaystyle L^{\infty -0}(\Omega ,{\mathcal {F}},P)=\bigcap \limits _{p<\infty }L^{p}(\Omega ,{\mathcal {F}},P)\quad } and q : L ∞ − 0 ( R N , B ( R N ) , γ N ) → L ∞ − 0 ( Ω , F , P ) , {\displaystyle \quad q:L^{\infty -0}(\mathbb {R} ^{\mathbb {N} },{\mathcal {B}}(\mathbb {R} ^{\mathbb {N} }),\gamma ^{\mathbb {N} })\to L^{\infty -0}(\Omega ,{\mathcal {F}},P),} we get a canonical representation of the additive group ρ : H → End ⁡ ( L ∞ − 0 ( Ω , F , P ) ) {\displaystyle \rho :{\mathcal {H}}\to \operatorname {End} (L^{\infty -0}(\Omega ,{\mathcal {F}},P))} acting on the endomorphisms by defining ρ ( h ) = q ∘ τ j ( h ) ∘ q − 1 . {\displaystyle \rho (h)=q\circ \tau _{j(h)}\circ q^{-1}.} One can show that the action of ρ {\displaystyle \rho } is extrinsic meaning it does not depend on the choice of basis for H {\displaystyle {\mathcal {H}}} , further ρ ( h + h ′ ) = ρ ( h ) ρ ( h ′ ) {\displaystyle \rho (h+h')=\rho (h)\rho (h')} for h , h ′ ∈ H {\displaystyle h,h'\in {\mathcal {H}}} and for the infinitesimal generator of ( ρ ( h ) ) h {\displaystyle (\rho (h))_{h}} that lim ε → 0 ρ ( ε h ) − I ε = M h {\displaystyle \lim \limits _{\varepsilon \to 0}{\frac {\rho (\varepsilon h)-I}{\varepsilon }}=M_{h}} where I {\displaystyle I} is the identity operator and M h {\displaystyle M_{h}} denotes the multiplication operator by the random variable h ∈ H {\displaystyle h\in {\mathcal {H}}} (acting on the endomorphisms). In the case of an arbitrary Hilbert space G {\displaystyle {\mathcal {G}}} and the Segal model Seg ⁡ ( G ) {\displaystyle \operatorname {Seg} ({\mathcal {G}})} one has j : G → ℓ 2 {\displaystyle j:{\mathcal {G}}\to \ell ^{2}} (and thus ρ : G → End ⁡ ( L ∞ − 0 ( Ω , F , P ) ) {\displaystyle \rho :{\mathcal {G}}\to \operatorname {End} (L^{\infty -0}(\Omega ,{\mathcal {F}},P))} . Then the limit above becomes the multiplication operator by the random variable W ( g ) {\displaystyle W(g)} associated to g ∈ G {\displaystyle g\in {\mathcal {G}}} . For F ∈ L ∞ − 0 ( Ω , F , P ) {\displaystyle F\in L^{\infty -0}(\Omega ,{\mathcal {F}},P)} and h ∈ H {\displaystyle h\in {\mathcal {H}}} one now defines the directional derivative ⟨ D F , h ⟩ = D h F = lim ε → 0 ( ρ ( ε h ) − I ) F ε . {\displaystyle \langle DF,h\rangle =D_{h}F=\lim \limits _{\varepsilon \to 0}{\frac {\left(\rho (\varepsilon h)-I\right)F}{\varepsilon }}.} Given a Hilbert space H {\displaystyle H} and a Segal model Seg ⁡ ( H ) {\displaystyle \operatorname {Seg} (H)} with its Gaussian space H = { W ( h ) : h ∈ H } {\displaystyle {\mathcal {H}}=\{W(h):h\in H\}} . One can now deduce for F ∈ L ∞ − 0 ( Ω , F , P ) {\displaystyle F\in L^{\infty -0}(\Omega ,{\mathcal {F}},P)} the integration by parts formula E [ D h F ] = E [ M W ( h ) F ] = E [ W ( h ) F ] {\displaystyle \mathbb {E} [D_{h}F]=\mathbb {E} [M_{W(h)}F]=\mathbb {E} [W(h)F]} . == Invariance principle == The usual invariance principle for Lebesgue integration over the whole real line is that, for any real number ε and integrable function f, the following holds ∫ − ∞ ∞ f ( x ) d λ ( x ) = ∫ − ∞ ∞ f ( x + ε ) d λ ( x ) {\displaystyle \int _{-\infty }^{\infty }f(x)\,d\lambda (x)=\int _{-\infty }^{\infty }f(x+\varepsilon )\,d\lambda (x)} and hence ∫ − ∞ ∞ f ′ ( x ) d λ ( x ) = 0. {\displaystyle \int _{-\infty }^{\infty }f'(x)\,d\lambda (x)=0.} This can be used to derive the integration by parts formula since, setting f = gh, it implies 0 = ∫ − ∞ ∞ f ′ d λ = ∫ − ∞ ∞ ( g h ) ′ d λ = ∫ − ∞ ∞ g h ′ d λ + ∫ − ∞ ∞ g ′ h d λ . {\displaystyle 0=\int _{-\infty }^{\infty }f'\,d\lambda =\int _{-\infty }^{\infty }(gh)'\,d\lambda =\int _{-\infty }^{\infty }gh'\,d\lambda +\int _{-\infty }^{\infty }g'h\,d\lambda .} A similar idea can be applied in stochastic analysis for the differentiation along a Cameron-Martin-Girsanov direction. Indeed, let h s {\displaystyle h_{s}} be a square-integrable predictable process and set φ ( t ) = ∫ 0 t h s d s . {\displaystyle \varphi (t)=\int _{0}^{t}h_{s}\,ds.} If W {\displaystyle W} is a Wiener process, the Girsanov theorem then yields the following analogue of the invariance principle: E ( F ( W + ε φ ) ) = E [ F ( W ) exp ⁡ ( ε ∫ 0 1 h s d w s − 1 2 ε 2 ∫ 0 1 h s 2 d s ) ] . {\displaystyle E(F(W+\varepsilon \varphi ))=E\left[F(W)\exp \left(\varepsilon \int _{0}^{1}h_{s}\,dw_{s}-{\frac {1}{2}}\varepsilon ^{2}\int _{0}^{1}h_{s}^{2}\,ds\right)\right].} Differentiating with respect to ε on both sides and evaluating at ε=0, one obtains the following integration by parts formula: E ( ⟨ D F ( W ) , φ ⟩ ) = E [ F ( W ) ∫ 0 1 h s d w s ] . {\displaystyle E(\langle DF(W),\varphi \rangle )=E{\Big [}F(W)\int _{0}^{1}h_{s}\,dw_{s}{\Big ]}.} Here, the left-hand side is the Malliavin derivative of the random variable F {\displaystyle F} in the direction φ {\displaystyle \varphi } and the integral appearing on the right hand side should be interpreted as an Itô integral. == Clark–Ocone formula == One of the most useful results from Malliavin calculus is the Clark–Ocone theorem, which allows the process in the martingale representation theorem to be identified explicitly. A simplified version of this theorem is as follows: Consider the standard Wiener measure on the canonical space C [ 0 , 1 ] {\displaystyle C[0,1]} , equipped with its canonical filtration. For F : C [ 0 , 1 ] → R {\displaystyle F:C[0,1]\to \mathbb {R} } satisfying E ( F ( X ) 2 ) < ∞ {\displaystyle E(F(X)^{2})<\infty } which is Lipschitz and such that F has a strong derivative kernel, in the sense that for φ {\displaystyle \varphi } in C[0,1] lim ε → 0 1 ε ( F ( X + ε φ ) − F ( X ) ) = ∫ 0 1 F ′ ( X , d t ) φ ( t ) a . e . X {\displaystyle \lim _{\varepsilon \to 0}{\frac {1}{\varepsilon }}(F(X+\varepsilon \varphi )-F(X))=\int _{0}^{1}F'(X,dt)\varphi (t)\ \mathrm {a.e.} \ X} then F ( X ) = E ( F ( X ) ) + ∫ 0 1 H t d X t , {\displaystyle F(X)=E(F(X))+\int _{0}^{1}H_{t}\,dX_{t},} where H is the previsible projection of F'(x, (t,1]) which may be viewed as the derivative of the function F with respect to a suitable parallel shift of the process X over the portion (t,1] of its domain. This may be more concisely expressed by F ( X ) = E ( F ( X ) ) + ∫ 0 1 E ( D t F ∣ F t ) d X t . {\displaystyle F(X)=E(F(X))+\int _{0}^{1}E(D_{t}F\mid {\mathcal {F}}_{t})\,dX_{t}.} Much of the work in the formal development of the Malliavin calculus involves extending this result to the largest possible class of functionals F by replacing the derivative kernel used above by the "Malliavin derivative" denoted D t {\displaystyle D_{t}} in the above statement of the result. == Skorokhod integral == The Skorokhod integral operator which is conventionally denoted δ is defined as the adjoint of the Malliavin derivative in the white noise case when the Hilbert space is an L 2 {\displaystyle L^{2}} space, thus for u in the domain of the operator which is a subset of L 2 ( [ 0 , ∞ ) × Ω ) {\displaystyle L^{2}([0,\infty )\times \Omega )} , for F in the domain of the Malliavin derivative, we require E ( ⟨ D F , u ⟩ ) = E ( F δ ( u ) ) , {\displaystyle E(\langle DF,u\rangle )=E(F\delta (u)),} where the inner product is that on L 2 [ 0 , ∞ ) {\displaystyle L^{2}[0,\infty )} viz ⟨ f , g ⟩ = ∫ 0 ∞ f ( s ) g ( s ) d s . {\displaystyle \langle f,g\rangle =\int _{0}^{\infty }f(s)g(s)\,ds.} The existence of this adjoint follows from the Riesz representation theorem for linear operators on Hilbert spaces. It can be shown that if u is adapted then δ ( u ) = ∫ 0 ∞ u t d W t , {\displaystyle \delta (u)=\int _{0}^{\infty }u_{t}\,dW_{t},} where the integral is to be understood in the Itô sense. Thus this provides a method of extending the Itô integral to non adapted integrands. == Applications == The calculus allows integration by parts with random variables; this operation is used in mathematical finance to compute the sensitivities of financial derivatives. The calculus has applications for example in stochastic filtering. == References == Kusuoka, S. and Stroock, D. (1981) "Applications of Malliavin Calculus I", Stochastic Analysis, Proceedings Taniguchi International Symposium Katata and Kyoto 1982, pp 271–306 Kusuoka, S. and Stroock, D. (1985) "Applications of Malliavin Calculus II", J. Faculty Sci. Uni. Tokyo Sect. 1A Math., 32 pp 1–76 Kusuoka, S. and Stroock, D. (1987) "Applications of Malliavin Calculus III", J. Faculty Sci. Univ. Tokyo Sect. 1A Math., 34 pp 391–442 Malliavin, Paul and Thalmaier, Anton. Stochastic Calculus of Variations in Mathematical Finance, Springer 2005, ISBN 3-540-43431-3 Nualart, David (2006). The Malliavin calculus and related topics (Second ed.). Springer-Verlag. ISBN 978-3-540-28328-7. Bell, Denis. (2007) The Malliavin Calculus, Dover. ISBN 0-486-44994-7; ebook Sanz-Solé, Marta (2005) Malliavin Calculus, with applications to stochastic partial differential equations. EPFL Press, distributed by CRC Press, Taylor & Francis Group. Schiller, Alex (2009) Malliavin Calculus for Monte Carlo Simulation with Financial Applications. Thesis, Department of Mathematics, Princeton University Øksendal, Bernt K.(1997) An Introduction To Malliavin Calculus With Applications To Economics. Lecture Notes, Dept. of Mathematics, University of Oslo (Zip file containing Thesis and addendum) Di Nunno, Giulia, Øksendal, Bernt, Proske, Frank (2009) "Malliavin Calculus for Lévy Processes with Applications to Finance", Universitext, Springer. ISBN 978-3-540-78571-2 == External links == Quotations related to Malliavin calculus at Wikiquote Friz, Peter K. (2005-04-10). "An Introduction to Malliavin Calculus" (PDF). Archived from the original (PDF) on 2007-04-17. Retrieved 2007-07-23. Lecture Notes, 43 pages Zhang, H. (2004-11-11). "The Malliavin Calculus" (PDF). Retrieved 2004-11-11. Thesis, 100 pages
Wikipedia/Malliavin_calculus
In physics, a gauge theory is a type of field theory in which the Lagrangian, and hence the dynamics of the system itself, does not change under local transformations according to certain smooth families of operations (Lie groups). Formally, the Lagrangian is invariant under these transformations. The term "gauge" refers to any specific mathematical formalism to regulate redundant degrees of freedom in the Lagrangian of a physical system. The transformations between possible gauges, called gauge transformations, form a Lie group—referred to as the symmetry group or the gauge group of the theory. Associated with any Lie group is the Lie algebra of group generators. For each group generator there necessarily arises a corresponding field (usually a vector field) called the gauge field. Gauge fields are included in the Lagrangian to ensure its invariance under the local group transformations (called gauge invariance). When such a theory is quantized, the quanta of the gauge fields are called gauge bosons. If the symmetry group is non-commutative, then the gauge theory is referred to as non-abelian gauge theory, the usual example being the Yang–Mills theory. Many powerful theories in physics are described by Lagrangians that are invariant under some symmetry transformation groups. When they are invariant under a transformation identically performed at every point in the spacetime in which the physical processes occur, they are said to have a global symmetry. Local symmetry, the cornerstone of gauge theories, is a stronger constraint. In fact, a global symmetry is just a local symmetry whose group's parameters are fixed in spacetime (the same way a constant value can be understood as a function of a certain parameter, the output of which is always the same). Gauge theories are important as the successful field theories explaining the dynamics of elementary particles. Quantum electrodynamics is an abelian gauge theory with the symmetry group U(1) and has one gauge field, the electromagnetic four-potential, with the photon being the gauge boson. The Standard Model is a non-abelian gauge theory with the symmetry group U(1) × SU(2) × SU(3) and has a total of twelve gauge bosons: the photon, three weak bosons and eight gluons. Gauge theories are also important in explaining gravitation in the theory of general relativity. Its case is somewhat unusual in that the gauge field is a tensor, the Lanczos tensor. Theories of quantum gravity, beginning with gauge gravitation theory, also postulate the existence of a gauge boson known as the graviton. Gauge symmetries can be viewed as analogues of the principle of general covariance of general relativity in which the coordinate system can be chosen freely under arbitrary diffeomorphisms of spacetime. Both gauge invariance and diffeomorphism invariance reflect a redundancy in the description of the system. An alternative theory of gravitation, gauge theory gravity, replaces the principle of general covariance with a true gauge principle with new gauge fields. Historically, these ideas were first stated in the context of classical electromagnetism and later in general relativity. However, the modern importance of gauge symmetries appeared first in the relativistic quantum mechanics of electrons – quantum electrodynamics, elaborated on below. Today, gauge theories are useful in condensed matter, nuclear and high energy physics among other subfields. == History == The concept and the name of gauge theory derives from the work of Hermann Weyl in 1918. Weyl, in an attempt to generalize the geometrical ideas of general relativity to include electromagnetism, conjectured that Eichinvarianz or invariance under the change of scale (or "gauge") might also be a local symmetry of general relativity. After the development of quantum mechanics, Weyl, Vladimir Fock and Fritz London replaced the simple scale factor with a complex quantity and turned the scale transformation into a change of phase, which is a U(1) gauge symmetry. This explained the electromagnetic field effect on the wave function of a charged quantum mechanical particle. Weyl's 1929 paper introduced the modern concept of gauge invariance subsequently popularized by Wolfgang Pauli in his 1941 review. In retrospect, James Clerk Maxwell's formulation, in 1864–65, of electrodynamics in "A Dynamical Theory of the Electromagnetic Field" suggested the possibility of invariance, when he stated that any vector field whose curl vanishes—and can therefore normally be written as a gradient of a function—could be added to the vector potential without affecting the magnetic field. Similarly unnoticed, David Hilbert had derived the Einstein field equations by postulating the invariance of the action under a general coordinate transformation. The importance of these symmetry invariances remained unnoticed until Weyl's work. Inspired by Pauli's descriptions of connection between charge conservation and field theory driven by invariance, Chen Ning Yang sought a field theory for atomic nuclei binding based on conservation of nuclear isospin.: 202  In 1954, Yang and Robert Mills generalized the gauge invariance of electromagnetism, constructing a theory based on the action of the (non-abelian) SU(2) symmetry group on the isospin doublet of protons and neutrons. This is similar to the action of the U(1) group on the spinor fields of quantum electrodynamics. The Yang–Mills theory became the prototype theory to resolve some of the confusion in elementary particle physics. This idea later found application in the quantum field theory of the weak force, and its unification with electromagnetism in the electroweak theory. Gauge theories became even more attractive when it was realized that non-abelian gauge theories reproduced a feature called asymptotic freedom. Asymptotic freedom was believed to be an important characteristic of strong interactions. This motivated searching for a strong force gauge theory. This theory, now known as quantum chromodynamics, is a gauge theory with the action of the SU(3) group on the color triplet of quarks. The Standard Model unifies the description of electromagnetism, weak interactions and strong interactions in the language of gauge theory. In the 1970s, Michael Atiyah began studying the mathematics of solutions to the classical Yang–Mills equations. In 1983, Atiyah's student Simon Donaldson built on this work to show that the differentiable classification of smooth 4-manifolds is very different from their classification up to homeomorphism. Michael Freedman used Donaldson's work to exhibit exotic R4s, that is, exotic differentiable structures on Euclidean 4-dimensional space. This led to an increasing interest in gauge theory for its own sake, independent of its successes in fundamental physics. In 1994, Edward Witten and Nathan Seiberg invented gauge-theoretic techniques based on supersymmetry that enabled the calculation of certain topological invariants (the Seiberg–Witten invariants). These contributions to mathematics from gauge theory have led to a renewed interest in this area. The importance of gauge theories in physics is exemplified in the success of the mathematical formalism in providing a unified framework to describe the quantum field theories of electromagnetism, the weak force and the strong force. This theory, known as the Standard Model, accurately describes experimental predictions regarding three of the four fundamental forces of nature, and is a gauge theory with the gauge group SU(3) × SU(2) × U(1). Modern theories like string theory, as well as general relativity, are, in one way or another, gauge theories. See Jackson and Okun for early history of gauge and Pickering for more about the history of gauge and quantum field theories. == Description == === Global and local symmetries === ==== Global symmetry ==== In physics, the mathematical description of any physical situation usually contains excess degrees of freedom; the same physical situation is equally well described by many equivalent mathematical configurations. For instance, in Newtonian dynamics, if two configurations are related by a Galilean transformation (an inertial change of reference frame) they represent the same physical situation. These transformations form a group of "symmetries" of the theory, and a physical situation corresponds not to an individual mathematical configuration but to a class of configurations related to one another by this symmetry group. This idea can be generalized to include local as well as global symmetries, analogous to much more abstract "changes of coordinates" in a situation where there is no preferred "inertial" coordinate system that covers the entire physical system. A gauge theory is a mathematical model that has symmetries of this kind, together with a set of techniques for making physical predictions consistent with the symmetries of the model. ==== Example of global symmetry ==== When a quantity occurring in the mathematical configuration is not just a number but has some geometrical significance, such as a velocity or an axis of rotation, its representation as numbers arranged in a vector or matrix is also changed by a coordinate transformation. For instance, if one description of a pattern of fluid flow states that the fluid velocity in the neighborhood of (x = 1, y = 0) is 1 m/s in the positive x direction, then a description of the same situation in which the coordinate system has been rotated clockwise by 90 degrees states that the fluid velocity in the neighborhood of (x = 0, y= −1) is 1 m/s in the negative y direction. The coordinate transformation has affected both the coordinate system used to identify the location of the measurement and the basis in which its value is expressed. As long as this transformation is performed globally (affecting the coordinate basis in the same way at every point), the effect on values that represent the rate of change of some quantity along some path in space and time as it passes through point P is the same as the effect on values that are truly local to P. ==== Local symmetry ==== ===== Use of fiber bundles to describe local symmetries ===== In order to adequately describe physical situations in more complex theories, it is often necessary to introduce a "coordinate basis" for some of the objects of the theory that do not have this simple relationship to the coordinates used to label points in space and time. (In mathematical terms, the theory involves a fiber bundle in which the fiber at each point of the base space consists of possible coordinate bases for use when describing the values of objects at that point.) In order to spell out a mathematical configuration, one must choose a particular coordinate basis at each point (a local section of the fiber bundle) and express the values of the objects of the theory (usually "fields" in the physicist's sense) using this basis. Two such mathematical configurations are equivalent (describe the same physical situation) if they are related by a transformation of this abstract coordinate basis (a change of local section, or gauge transformation). In most gauge theories, the set of possible transformations of the abstract gauge basis at an individual point in space and time is a finite-dimensional Lie group. The simplest such group is U(1), which appears in the modern formulation of quantum electrodynamics (QED) via its use of complex numbers. QED is generally regarded as the first, and simplest, physical gauge theory. The set of possible gauge transformations of the entire configuration of a given gauge theory also forms a group, the gauge group of the theory. An element of the gauge group can be parameterized by a smoothly varying function from the points of spacetime to the (finite-dimensional) Lie group, such that the value of the function and its derivatives at each point represents the action of the gauge transformation on the fiber over that point. A gauge transformation with constant parameter at every point in space and time is analogous to a rigid rotation of the geometric coordinate system; it represents a global symmetry of the gauge representation. As in the case of a rigid rotation, this gauge transformation affects expressions that represent the rate of change along a path of some gauge-dependent quantity in the same way as those that represent a truly local quantity. A gauge transformation whose parameter is not a constant function is referred to as a local symmetry; its effect on expressions that involve a derivative is qualitatively different from that on expressions that do not. (This is analogous to a non-inertial change of reference frame, which can produce a Coriolis effect.) === Gauge fields === The "gauge covariant" version of a gauge theory accounts for this effect by introducing a gauge field (in mathematical language, an Ehresmann connection) and formulating all rates of change in terms of the covariant derivative with respect to this connection. The gauge field becomes an essential part of the description of a mathematical configuration. A configuration in which the gauge field can be eliminated by a gauge transformation has the property that its field strength (in mathematical language, its curvature) is zero everywhere; a gauge theory is not limited to these configurations. In other words, the distinguishing characteristic of a gauge theory is that the gauge field does not merely compensate for a poor choice of coordinate system; there is generally no gauge transformation that makes the gauge field vanish. When analyzing the dynamics of a gauge theory, the gauge field must be treated as a dynamical variable, similar to other objects in the description of a physical situation. In addition to its interaction with other objects via the covariant derivative, the gauge field typically contributes energy in the form of a "self-energy" term. One can obtain the equations for the gauge theory by: starting from a naïve ansatz without the gauge field (in which the derivatives appear in a "bare" form); listing those global symmetries of the theory that can be characterized by a continuous parameter (generally an abstract equivalent of a rotation angle); computing the correction terms that result from allowing the symmetry parameter to vary from place to place; and reinterpreting these correction terms as couplings to one or more gauge fields, and giving these fields appropriate self-energy terms and dynamical behavior. This is the sense in which a gauge theory "extends" a global symmetry to a local symmetry, and closely resembles the historical development of the gauge theory of gravity known as general relativity. === Physical experiments === Gauge theories used to model the results of physical experiments engage in: limiting the universe of possible configurations to those consistent with the information used to set up the experiment, and then computing the probability distribution of the possible outcomes that the experiment is designed to measure. We cannot express the mathematical descriptions of the "setup information" and the "possible measurement outcomes", or the "boundary conditions" of the experiment, without reference to a particular coordinate system, including a choice of gauge. One assumes an adequate experiment isolated from "external" influence that is itself a gauge-dependent statement. Mishandling gauge dependence calculations in boundary conditions is a frequent source of anomalies, and approaches to anomaly avoidance classifies gauge theories. === Continuum theories === The two gauge theories mentioned above, continuum electrodynamics and general relativity, are continuum field theories. The techniques of calculation in a continuum theory implicitly assume that: given a completely fixed choice of gauge, the boundary conditions of an individual configuration are completely described given a completely fixed gauge and a complete set of boundary conditions, the least action determines a unique mathematical configuration and therefore a unique physical situation consistent with these bounds fixing the gauge introduces no anomalies in the calculation, due either to gauge dependence in describing partial information about boundary conditions or to incompleteness of the theory. Determination of the likelihood of possible measurement outcomes proceed by: establishing a probability distribution over all physical situations determined by boundary conditions consistent with the setup information establishing a probability distribution of measurement outcomes for each possible physical situation convolving these two probability distributions to get a distribution of possible measurement outcomes consistent with the setup information These assumptions have enough validity across a wide range of energy scales and experimental conditions to allow these theories to make accurate predictions about almost all of the phenomena encountered in daily life: light, heat, and electricity, eclipses, spaceflight, etc. They fail only at the smallest and largest scales due to omissions in the theories themselves, and when the mathematical techniques themselves break down, most notably in the case of turbulence and other chaotic phenomena. === Quantum field theories === Other than these classical continuum field theories, the most widely known gauge theories are quantum field theories, including quantum electrodynamics and the Standard Model of elementary particle physics. The starting point of a quantum field theory is much like that of its continuum analog: a gauge-covariant action integral that characterizes "allowable" physical situations according to the principle of least action. However, continuum and quantum theories differ significantly in how they handle the excess degrees of freedom represented by gauge transformations. Continuum theories, and most pedagogical treatments of the simplest quantum field theories, use a gauge fixing prescription to reduce the orbit of mathematical configurations that represent a given physical situation to a smaller orbit related by a smaller gauge group (the global symmetry group, or perhaps even the trivial group). More sophisticated quantum field theories, in particular those that involve a non-abelian gauge group, break the gauge symmetry within the techniques of perturbation theory by introducing additional fields (the Faddeev–Popov ghosts) and counterterms motivated by anomaly cancellation, in an approach known as BRST quantization. While these concerns are in one sense highly technical, they are also closely related to the nature of measurement, the limits on knowledge of a physical situation, and the interactions between incompletely specified experimental conditions and incompletely understood physical theory. The mathematical techniques that have been developed in order to make gauge theories tractable have found many other applications, from solid-state physics and crystallography to low-dimensional topology. == Classical gauge theory == === Classical electromagnetism === In electrostatics, one can either discuss the electric field, E, or its corresponding electric potential, V. Knowledge of one makes it possible to find the other, except that potentials differing by a constant, V ↦ V + C {\displaystyle V\mapsto V+C} , correspond to the same electric field. This is because the electric field relates to changes in the potential from one point in space to another, and the constant C would cancel out when subtracting to find the change in potential. In terms of vector calculus, the electric field is the gradient of the potential, E = − ∇ V {\displaystyle \mathbf {E} =-\nabla V} . Generalizing from static electricity to electromagnetism, we have a second potential, the vector potential A, with E = − ∇ V − ∂ A ∂ t B = ∇ × A {\displaystyle {\begin{aligned}\mathbf {E} &=-\nabla V-{\frac {\partial \mathbf {A} }{\partial t}}\\\mathbf {B} &=\nabla \times \mathbf {A} \end{aligned}}} The general gauge transformations now become not just V ↦ V + C {\displaystyle V\mapsto V+C} but A ↦ A + ∇ f V ↦ V − ∂ f ∂ t {\displaystyle {\begin{aligned}\mathbf {A} &\mapsto \mathbf {A} +\nabla f\\V&\mapsto V-{\frac {\partial f}{\partial t}}\end{aligned}}} where f is any twice continuously differentiable function that depends on position and time. The electromagnetic fields remain the same under the gauge transformation. === Example: scalar O(n) gauge theory === The remainder of this section requires some familiarity with classical or quantum field theory, and the use of Lagrangians. Definitions in this section: gauge group, gauge field, interaction Lagrangian, gauge boson. The following illustrates how local gauge invariance can be "motivated" heuristically starting from global symmetry properties, and how it leads to an interaction between originally non-interacting fields. Consider a set of n {\displaystyle n} non-interacting real scalar fields, with equal masses m. This system is described by an action that is the sum of the (usual) action for each scalar field φ i {\displaystyle \varphi _{i}} S = ∫ d 4 x ∑ i = 1 n [ 1 2 ∂ μ φ i ∂ μ φ i − 1 2 m 2 φ i 2 ] {\displaystyle {\mathcal {S}}=\int \,\mathrm {d} ^{4}x\sum _{i=1}^{n}\left[{\frac {1}{2}}\partial _{\mu }\varphi _{i}\partial ^{\mu }\varphi _{i}-{\frac {1}{2}}m^{2}\varphi _{i}^{2}\right]} The Lagrangian (density) can be compactly written as L = 1 2 ( ∂ μ Φ ) T ∂ μ Φ − 1 2 m 2 Φ T Φ {\displaystyle \ {\mathcal {L}}={\frac {1}{2}}(\partial _{\mu }\Phi )^{\mathsf {T}}\partial ^{\mu }\Phi -{\frac {1}{2}}m^{2}\Phi ^{\mathsf {T}}\Phi } by introducing a vector of fields Φ T = ( φ 1 , φ 2 , … , φ n ) {\displaystyle \ \Phi ^{\mathsf {T}}=(\varphi _{1},\varphi _{2},\ldots ,\varphi _{n})} The term ∂ μ Φ {\displaystyle \partial _{\mu }\Phi } is the partial derivative of Φ {\displaystyle \Phi } along dimension μ {\displaystyle \mu } . It is now transparent that the Lagrangian is invariant under the transformation Φ ↦ Φ ′ = G Φ {\displaystyle \ \Phi \mapsto \Phi '=G\Phi } whenever G is a constant matrix belonging to the n-by-n orthogonal group O(n). This is seen to preserve the Lagrangian, since the derivative of Φ ′ {\displaystyle \Phi '} transforms identically to Φ {\displaystyle \Phi } and both quantities appear inside dot products in the Lagrangian (orthogonal transformations preserve the dot product). ( ∂ μ Φ ) ↦ ( ∂ μ Φ ) ′ = G ∂ μ Φ {\displaystyle \ (\partial _{\mu }\Phi )\mapsto (\partial _{\mu }\Phi )'=G\partial _{\mu }\Phi } This characterizes the global symmetry of this particular Lagrangian, and the symmetry group is often called the gauge group; the mathematical term is structure group, especially in the theory of G-structures. Incidentally, Noether's theorem implies that invariance under this group of transformations leads to the conservation of the currents J μ a = i ∂ μ Φ T T a Φ {\displaystyle \ J_{\mu }^{a}=i\partial _{\mu }\Phi ^{\mathsf {T}}T^{a}\Phi } where the Ta matrices are generators of the SO(n) group. There is one conserved current for every generator. Now, demanding that this Lagrangian should have local O(n)-invariance requires that the G matrices (which were earlier constant) should be allowed to become functions of the spacetime coordinates x. In this case, the G matrices do not "pass through" the derivatives, when G = G(x), ∂ μ ( G Φ ) ≠ G ( ∂ μ Φ ) {\displaystyle \ \partial _{\mu }(G\Phi )\neq G(\partial _{\mu }\Phi )} The failure of the derivative to commute with "G" introduces an additional term (in keeping with the product rule), which spoils the invariance of the Lagrangian. In order to rectify this we define a new derivative operator such that the derivative of Φ ′ {\displaystyle \Phi '} again transforms identically with Φ {\displaystyle \Phi } ( D μ Φ ) ′ = G D μ Φ {\displaystyle \ (D_{\mu }\Phi )'=GD_{\mu }\Phi } This new "derivative" is called a (gauge) covariant derivative and takes the form D μ = ∂ μ − i g A μ {\displaystyle \ D_{\mu }=\partial _{\mu }-igA_{\mu }} where g is called the coupling constant; a quantity defining the strength of an interaction. After a simple calculation we can see that the gauge field A(x) must transform as follows A μ ′ = G A μ G − 1 − i g ( ∂ μ G ) G − 1 {\displaystyle \ A'_{\mu }=GA_{\mu }G^{-1}-{\frac {i}{g}}(\partial _{\mu }G)G^{-1}} The gauge field is an element of the Lie algebra, and can therefore be expanded as A μ = ∑ a A μ a T a {\displaystyle \ A_{\mu }=\sum _{a}A_{\mu }^{a}T^{a}} There are therefore as many gauge fields as there are generators of the Lie algebra. Finally, we now have a locally gauge invariant Lagrangian L l o c = 1 2 ( D μ Φ ) T D μ Φ − 1 2 m 2 Φ T Φ {\displaystyle \ {\mathcal {L}}_{\mathrm {loc} }={\frac {1}{2}}(D_{\mu }\Phi )^{\mathsf {T}}D^{\mu }\Phi -{\frac {1}{2}}m^{2}\Phi ^{\mathsf {T}}\Phi } Pauli uses the term gauge transformation of the first type to mean the transformation of Φ {\displaystyle \Phi } , while the compensating transformation in A {\displaystyle A} is called a gauge transformation of the second type. The difference between this Lagrangian and the original globally gauge-invariant Lagrangian is seen to be the interaction Lagrangian L i n t = i g 2 Φ T A μ T ∂ μ Φ + i g 2 ( ∂ μ Φ ) T A μ Φ − g 2 2 ( A μ Φ ) T A μ Φ {\displaystyle \ {\mathcal {L}}_{\mathrm {int} }=i{\frac {g}{2}}\Phi ^{\mathsf {T}}A_{\mu }^{\mathsf {T}}\partial ^{\mu }\Phi +i{\frac {g}{2}}(\partial _{\mu }\Phi )^{\mathsf {T}}A^{\mu }\Phi -{\frac {g^{2}}{2}}(A_{\mu }\Phi )^{\mathsf {T}}A^{\mu }\Phi } This term introduces interactions between the n scalar fields just as a consequence of the demand for local gauge invariance. However, to make this interaction physical and not completely arbitrary, the mediator A(x) needs to propagate in space. That is dealt with in the next section by adding yet another term, L g f {\displaystyle {\mathcal {L}}_{\mathrm {gf} }} , to the Lagrangian. In the quantized version of the obtained classical field theory, the quanta of the gauge field A(x) are called gauge bosons. The interpretation of the interaction Lagrangian in quantum field theory is of scalar bosons interacting by the exchange of these gauge bosons. === Yang–Mills Lagrangian for the gauge field === The picture of a classical gauge theory developed in the previous section is almost complete, except for the fact that to define the covariant derivatives D, one needs to know the value of the gauge field A ( x ) {\displaystyle A(x)} at all spacetime points. Instead of manually specifying the values of this field, it can be given as the solution to a field equation. Further requiring that the Lagrangian that generates this field equation is locally gauge invariant as well, one possible form for the gauge field Lagrangian is L gf = − 1 2 tr ⁡ ( F μ ν F μ ν ) = − 1 4 F a μ ν F μ ν a {\displaystyle {\mathcal {L}}_{\text{gf}}=-{\frac {1}{2}}\operatorname {tr} \left(F^{\mu \nu }F_{\mu \nu }\right)=-{\frac {1}{4}}F^{a\mu \nu }F_{\mu \nu }^{a}} where the F μ ν a {\displaystyle F_{\mu \nu }^{a}} are obtained from potentials A μ a {\displaystyle A_{\mu }^{a}} , being the components of A ( x ) {\displaystyle A(x)} , by F μ ν a = ∂ μ A ν a − ∂ ν A μ a + g ∑ b , c f a b c A μ b A ν c {\displaystyle F_{\mu \nu }^{a}=\partial _{\mu }A_{\nu }^{a}-\partial _{\nu }A_{\mu }^{a}+g\sum _{b,c}f^{abc}A_{\mu }^{b}A_{\nu }^{c}} and the f a b c {\displaystyle f^{abc}} are the structure constants of the Lie algebra of the generators of the gauge group. This formulation of the Lagrangian is called a Yang–Mills action. Other gauge invariant actions also exist (e.g., nonlinear electrodynamics, Born–Infeld action, Chern–Simons model, theta term, etc.). In this Lagrangian term there is no field whose transformation counterweighs the one of A {\displaystyle A} . Invariance of this term under gauge transformations is a particular case of a priori classical (geometrical) symmetry. This symmetry must be restricted in order to perform quantization, the procedure being denominated gauge fixing, but even after restriction, gauge transformations may be possible. The complete Lagrangian for the gauge theory is now L = L loc + L gf = L global + L int + L gf {\displaystyle {\mathcal {L}}={\mathcal {L}}_{\text{loc}}+{\mathcal {L}}_{\text{gf}}={\mathcal {L}}_{\text{global}}+{\mathcal {L}}_{\text{int}}+{\mathcal {L}}_{\text{gf}}} === Example: electrodynamics === As a simple application of the formalism developed in the previous sections, consider the case of electrodynamics, with only the electron field. The bare-bones action that generates the electron field's Dirac equation is S = ∫ ψ ¯ ( i ℏ c γ μ ∂ μ − m c 2 ) ψ d 4 x {\displaystyle {\mathcal {S}}=\int {\bar {\psi }}\left(i\hbar c\,\gamma ^{\mu }\partial _{\mu }-mc^{2}\right)\psi \,\mathrm {d} ^{4}x} The global symmetry for this system is ψ ↦ e i θ ψ {\displaystyle \psi \mapsto e^{i\theta }\psi } The gauge group here is U(1), just rotations of the phase angle of the field, with the particular rotation determined by the constant θ. "Localising" this symmetry implies the replacement of θ by θ(x). An appropriate covariant derivative is then D μ = ∂ μ − i e ℏ A μ {\displaystyle D_{\mu }=\partial _{\mu }-i{\frac {e}{\hbar }}A_{\mu }} Identifying the "charge" e (not to be confused with the mathematical constant e in the symmetry description) with the usual electric charge (this is the origin of the usage of the term in gauge theories), and the gauge field A(x) with the four-vector potential of the electromagnetic field results in an interaction Lagrangian L int = e ℏ ψ ¯ ( x ) γ μ ψ ( x ) A μ ( x ) = J μ ( x ) A μ ( x ) {\displaystyle {\mathcal {L}}_{\text{int}}={\frac {e}{\hbar }}{\bar {\psi }}(x)\gamma ^{\mu }\psi (x)A_{\mu }(x)=J^{\mu }(x)A_{\mu }(x)} where J μ ( x ) = e ℏ ψ ¯ ( x ) γ μ ψ ( x ) {\displaystyle J^{\mu }(x)={\frac {e}{\hbar }}{\bar {\psi }}(x)\gamma ^{\mu }\psi (x)} is the electric current four vector in the Dirac field. The gauge principle is therefore seen to naturally introduce the so-called minimal coupling of the electromagnetic field to the electron field. Adding a Lagrangian for the gauge field A μ ( x ) {\displaystyle A_{\mu }(x)} in terms of the field strength tensor exactly as in electrodynamics, one obtains the Lagrangian used as the starting point in quantum electrodynamics. L QED = ψ ¯ ( i ℏ c γ μ D μ − m c 2 ) ψ − 1 4 μ 0 F μ ν F μ ν {\displaystyle {\mathcal {L}}_{\text{QED}}={\bar {\psi }}\left(i\hbar c\,\gamma ^{\mu }D_{\mu }-mc^{2}\right)\psi -{\frac {1}{4\mu _{0}}}F_{\mu \nu }F^{\mu \nu }} == Mathematical formalism == Gauge theories are usually discussed in the language of differential geometry. Mathematically, a gauge is just a choice of a (local) section of some principal bundle. A gauge transformation is just a transformation between two such sections. Although gauge theory is dominated by the study of connections (primarily because it's mainly studied by high-energy physicists), the idea of a connection is not central to gauge theory in general. In fact, a result in general gauge theory shows that affine representations (i.e., affine modules) of the gauge transformations can be classified as sections of a jet bundle satisfying certain properties. There are representations that transform covariantly pointwise (called by physicists gauge transformations of the first kind), representations that transform as a connection form (called by physicists gauge transformations of the second kind, an affine representation)—and other more general representations, such as the B field in BF theory. There are more general nonlinear representations (realizations), but these are extremely complicated. Still, nonlinear sigma models transform nonlinearly, so there are applications. If there is a principal bundle P whose base space is space or spacetime and structure group is a Lie group, then the sections of P form a principal homogeneous space of the group of gauge transformations. Connections (gauge connection) define this principal bundle, yielding a covariant derivative ∇ in each associated vector bundle. If a local frame is chosen (a local basis of sections), then this covariant derivative is represented by the connection form A, a Lie algebra-valued 1-form, which is called the gauge potential in physics. This is evidently not an intrinsic but a frame-dependent quantity. The curvature form F, a Lie algebra-valued 2-form that is an intrinsic quantity, is constructed from a connection form by F = d A + A ∧ A {\displaystyle \mathbf {F} =\mathrm {d} \mathbf {A} +\mathbf {A} \wedge \mathbf {A} } where d stands for the exterior derivative and ∧ {\displaystyle \wedge } stands for the wedge product. ( A {\displaystyle \mathbf {A} } is an element of the vector space spanned by the generators T a {\displaystyle T^{a}} , and so the components of A {\displaystyle \mathbf {A} } do not commute with one another. Hence the wedge product A ∧ A {\displaystyle \mathbf {A} \wedge \mathbf {A} } does not vanish.) Infinitesimal gauge transformations form a Lie algebra, which is characterized by a smooth Lie-algebra-valued scalar, ε. Under such an infinitesimal gauge transformation, δ ε A = [ ε , A ] − d ε {\displaystyle \delta _{\varepsilon }\mathbf {A} =[\varepsilon ,\mathbf {A} ]-\mathrm {d} \varepsilon } where [ ⋅ , ⋅ ] {\displaystyle [\cdot ,\cdot ]} is the Lie bracket. One nice thing is that if δ ε X = ε X {\displaystyle \delta _{\varepsilon }X=\varepsilon X} , then δ ε D X = ε D X {\displaystyle \delta _{\varepsilon }DX=\varepsilon DX} where D is the covariant derivative D X = d e f d X + A X {\displaystyle DX\ {\stackrel {\mathrm {def} }{=}}\ \mathrm {d} X+\mathbf {A} X} Also, δ ε F = [ ε , F ] {\displaystyle \delta _{\varepsilon }\mathbf {F} =[\varepsilon ,\mathbf {F} ]} , which means F {\displaystyle \mathbf {F} } transforms covariantly. Not all gauge transformations can be generated by infinitesimal gauge transformations in general. An example is when the base manifold is a compact manifold without boundary such that the homotopy class of mappings from that manifold to the Lie group is nontrivial. See instanton for an example. The Yang–Mills action is now given by 1 4 g 2 ∫ Tr ⁡ [ ⋆ F ∧ F ] {\displaystyle {\frac {1}{4g^{2}}}\int \operatorname {Tr} [{\star }F\wedge F]} where ⋆ {\displaystyle {\star }} is the Hodge star operator and the integral is defined as in differential geometry. A quantity which is gauge-invariant (i.e., invariant under gauge transformations) is the Wilson loop, which is defined over any closed path, γ, as follows: χ ( ρ ) ( P { e ∫ γ A } ) {\displaystyle \chi ^{(\rho )}\left({\mathcal {P}}\left\{e^{\int _{\gamma }A}\right\}\right)} where χ is the character of a complex representation ρ and P {\displaystyle {\mathcal {P}}} represents the path-ordered operator. The formalism of gauge theory carries over to a general setting. For example, it is sufficient to ask that a vector bundle have a metric connection; when one does so, one finds that the metric connection satisfies the Yang–Mills equations of motion. == Quantization of gauge theories == Gauge theories may be quantized by specialization of methods which are applicable to any quantum field theory. However, because of the subtleties imposed by the gauge constraints (see section on Mathematical formalism, above) there are many technical problems to be solved which do not arise in other field theories. At the same time, the richer structure of gauge theories allows simplification of some computations: for example Ward identities connect different renormalization constants. === Methods and aims === The first gauge theory quantized was quantum electrodynamics (QED). The first methods developed for this involved gauge fixing and then applying canonical quantization. The Gupta–Bleuler method was also developed to handle this problem. Non-abelian gauge theories are now handled by a variety of means. Methods for quantization are covered in the article on quantization. The main point to quantization is to be able to compute quantum amplitudes for various processes allowed by the theory. Technically, they reduce to the computations of certain correlation functions in the vacuum state. This involves a renormalization of the theory. When the running coupling of the theory is small enough, then all required quantities may be computed in perturbation theory. Quantization schemes intended to simplify such computations (such as canonical quantization) may be called perturbative quantization schemes. At present some of these methods lead to the most precise experimental tests of gauge theories. However, in most gauge theories, there are many interesting questions which are non-perturbative. Quantization schemes suited to these problems (such as lattice gauge theory) may be called non-perturbative quantization schemes. Precise computations in such schemes often require supercomputing, and are therefore less well-developed currently than other schemes. === Anomalies === Some of the symmetries of the classical theory are then seen not to hold in the quantum theory; a phenomenon called an anomaly. Among the most well known are: The scale anomaly, which gives rise to a running coupling constant. In QED this gives rise to the phenomenon of the Landau pole. In quantum chromodynamics (QCD) this leads to asymptotic freedom. The chiral anomaly in either chiral or vector field theories with fermions. This has close connection with topology through the notion of instantons. In QCD this anomaly causes the decay of a pion to two photons. The gauge anomaly, which must cancel in any consistent physical theory. In the electroweak theory this cancellation requires an equal number of quarks and leptons. == Pure gauge == A pure gauge is the set of field configurations obtained by a gauge transformation on the null-field configuration, i.e., a gauge transform of zero. So it is a particular "gauge orbit" in the field configuration's space. Thus, in the abelian case, where A μ ( x ) → A μ ′ ( x ) = A μ ( x ) + ∂ μ f ( x ) {\displaystyle A_{\mu }(x)\rightarrow A'_{\mu }(x)=A_{\mu }(x)+\partial _{\mu }f(x)} , the pure gauge is just the set of field configurations A μ ′ ( x ) = ∂ μ f ( x ) {\displaystyle A'_{\mu }(x)=\partial _{\mu }f(x)} for all f(x). == See also == == References == == Bibliography == General readers Schumm, Bruce (2004) Deep Down Things. Johns Hopkins University Press. Esp. chpt. 8. A serious attempt by a physicist to explain gauge theory and the Standard Model with little formal mathematics. Carroll, Sean (2024). The Biggest Ideas in the Universe : Quanta and Fields. Dutton. p. 193-234 (chap 9 : Gauge Theory, and chap 10 : Phases). ISBN 978-0-5931-8660-2. Texts Bailin, David; Love, Alexander (2019). Introduction to Gauge Field Theory. Taylor & Francis. ISBN 9780203750100. Cheng, T.-P.; Li, L.-F. (1983). Gauge Theory of Elementary Particle Physics. Oxford University Press. ISBN 0-19-851961-3. Frampton, P. (2008). Gauge Field Theories (3rd ed.). Wiley-VCH. Kane, G.L. (1987). Modern Elementary Particle Physics. Perseus Books. ISBN 0-201-11749-5. Quigg, Chris (1983). Gauge Theories of the Strong, Weak and Electromagnetic Interactions. Addison-Wesley. ISBN 0-8053-6021-2. Articles Becchi, C. (1997). "Introduction to Gauge Theories". arXiv:hep-ph/9705211. Gross, D. (1992). "Gauge theory – Past, Present and Future". Retrieved 2009-04-23. Jackson, J.D. (2002). "From Lorenz to Coulomb and other explicit gauge transformations". Am. J. Phys. 70 (9): 917–928. arXiv:physics/0204034. Bibcode:2002AmJPh..70..917J. doi:10.1119/1.1491265. S2CID 119652556. Svetlichny, George (1999). "Preparation for Gauge Theory". arXiv:math-ph/9902027. == External links == "Gauge transformation", Encyclopedia of Mathematics, EMS Press, 2001 [1994] Yang–Mills equations on DispersiveWiki Gauge theories on Scholarpedia
Wikipedia/Gauge_theory
In information theory, the entropy of a random variable quantifies the average level of uncertainty or information associated with the variable's potential states or possible outcomes. This measures the expected amount of information needed to describe the state of the variable, considering the distribution of probabilities across all potential states. Given a discrete random variable X {\displaystyle X} , which may be any member x {\displaystyle x} within the set X {\displaystyle {\mathcal {X}}} and is distributed according to p : X → [ 0 , 1 ] {\displaystyle p\colon {\mathcal {X}}\to [0,1]} , the entropy is H ( X ) := − ∑ x ∈ X p ( x ) log ⁡ p ( x ) , {\displaystyle \mathrm {H} (X):=-\sum _{x\in {\mathcal {X}}}p(x)\log p(x),} where Σ {\displaystyle \Sigma } denotes the sum over the variable's possible values. The choice of base for log {\displaystyle \log } , the logarithm, varies for different applications. Base 2 gives the unit of bits (or "shannons"), while base e gives "natural units" nat, and base 10 gives units of "dits", "bans", or "hartleys". An equivalent definition of entropy is the expected value of the self-information of a variable. The concept of information entropy was introduced by Claude Shannon in his 1948 paper "A Mathematical Theory of Communication", and is also referred to as Shannon entropy. Shannon's theory defines a data communication system composed of three elements: a source of data, a communication channel, and a receiver. The "fundamental problem of communication" – as expressed by Shannon – is for the receiver to be able to identify what data was generated by the source, based on the signal it receives through the channel. Shannon considered various ways to encode, compress, and transmit messages from a data source, and proved in his source coding theorem that the entropy represents an absolute mathematical limit on how well data from the source can be losslessly compressed onto a perfectly noiseless channel. Shannon strengthened this result considerably for noisy channels in his noisy-channel coding theorem. Entropy in information theory is directly analogous to the entropy in statistical thermodynamics. The analogy results when the values of the random variable designate energies of microstates, so Gibbs's formula for the entropy is formally identical to Shannon's formula. Entropy has relevance to other areas of mathematics such as combinatorics and machine learning. The definition can be derived from a set of axioms establishing that entropy should be a measure of how informative the average outcome of a variable is. For a continuous random variable, differential entropy is analogous to entropy. The definition E [ − log ⁡ p ( X ) ] {\displaystyle \mathbb {E} [-\log p(X)]} generalizes the above. == Introduction == The core idea of information theory is that the "informational value" of a communicated message depends on the degree to which the content of the message is surprising. If a highly likely event occurs, the message carries very little information. On the other hand, if a highly unlikely event occurs, the message is much more informative. For instance, the knowledge that some particular number will not be the winning number of a lottery provides very little information, because any particular chosen number will almost certainly not win. However, knowledge that a particular number will win a lottery has high informational value because it communicates the occurrence of a very low probability event. The information content, also called the surprisal or self-information, of an event E {\displaystyle E} is a function that increases as the probability p ( E ) {\displaystyle p(E)} of an event decreases. When p ( E ) {\displaystyle p(E)} is close to 1, the surprisal of the event is low, but if p ( E ) {\displaystyle p(E)} is close to 0, the surprisal of the event is high. This relationship is described by the function log ⁡ ( 1 p ( E ) ) , {\displaystyle \log \left({\frac {1}{p(E)}}\right),} where log {\displaystyle \log } is the logarithm, which gives 0 surprise when the probability of the event is 1. In fact, log is the only function that satisfies а specific set of conditions defined in section § Characterization. Hence, we can define the information, or surprisal, of an event E {\displaystyle E} by I ( E ) = log ⁡ ( 1 p ( E ) ) , {\displaystyle I(E)=\log \left({\frac {1}{p(E)}}\right),} or equivalently, I ( E ) = − log ⁡ ( p ( E ) ) . {\displaystyle I(E)=-\log(p(E)).} Entropy measures the expected (i.e., average) amount of information conveyed by identifying the outcome of a random trial.: 67  This implies that rolling a die has higher entropy than tossing a coin because each outcome of a die toss has smaller probability ( p = 1 / 6 {\displaystyle p=1/6} ) than each outcome of a coin toss ( p = 1 / 2 {\displaystyle p=1/2} ). Consider a coin with probability p of landing on heads and probability 1 − p of landing on tails. The maximum surprise is when p = 1/2, for which one outcome is not expected over the other. In this case a coin flip has an entropy of one bit (similarly, one trit with equiprobable values contains log 2 ⁡ 3 {\displaystyle \log _{2}3} (about 1.58496) bits of information because it can have one of three values). The minimum surprise is when p = 0 (impossibility) or p = 1 (certainty) and the entropy is zero bits. When the entropy is zero, sometimes referred to as unity, there is no uncertainty at all – no freedom of choice – no information. Other values of p give entropies between zero and one bits. === Example === Information theory is useful to calculate the smallest amount of information required to convey a message, as in data compression. For example, consider the transmission of sequences comprising the 4 characters 'A', 'B', 'C', and 'D' over a binary channel. If all 4 letters are equally likely (25%), one cannot do better than using two bits to encode each letter. 'A' might code as '00', 'B' as '01', 'C' as '10', and 'D' as '11'. However, if the probabilities of each letter are unequal, say 'A' occurs with 70% probability, 'B' with 26%, and 'C' and 'D' with 2% each, one could assign variable length codes. In this case, 'A' would be coded as '0', 'B' as '10', 'C' as '110', and 'D' as '111'. With this representation, 70% of the time only one bit needs to be sent, 26% of the time two bits, and only 4% of the time 3 bits. On average, fewer than 2 bits are required since the entropy is lower (owing to the high prevalence of 'A' followed by 'B' – together 96% of characters). The calculation of the sum of probability-weighted log probabilities measures and captures this effect. English text, treated as a string of characters, has fairly low entropy; i.e. it is fairly predictable. We can be fairly certain that, for example, 'e' will be far more common than 'z', that the combination 'qu' will be much more common than any other combination with a 'q' in it, and that the combination 'th' will be more common than 'z', 'q', or 'qu'. After the first few letters one can often guess the rest of the word. English text has between 0.6 and 1.3 bits of entropy per character of the message.: 234  == Definition == Named after Boltzmann's Η-theorem, Shannon defined the entropy Η (Greek capital letter eta) of a discrete random variable X {\textstyle X} , which takes values in the set X {\displaystyle {\mathcal {X}}} and is distributed according to p : X → [ 0 , 1 ] {\displaystyle p:{\mathcal {X}}\to [0,1]} such that p ( x ) := P [ X = x ] {\displaystyle p(x):=\mathbb {P} [X=x]} : H ( X ) = E [ I ⁡ ( X ) ] = E [ − log ⁡ p ( X ) ] . {\displaystyle \mathrm {H} (X)=\mathbb {E} [\operatorname {I} (X)]=\mathbb {E} [-\log p(X)].} Here E {\displaystyle \mathbb {E} } is the expected value operator, and I is the information content of X.: 11 : 19–20  I ⁡ ( X ) {\displaystyle \operatorname {I} (X)} is itself a random variable. The entropy can explicitly be written as: H ( X ) = − ∑ x ∈ X p ( x ) log b ⁡ p ( x ) , {\displaystyle \mathrm {H} (X)=-\sum _{x\in {\mathcal {X}}}p(x)\log _{b}p(x),} where b is the base of the logarithm used. Common values of b are 2, Euler's number e, and 10, and the corresponding units of entropy are the bits for b = 2, nats for b = e, and bans for b = 10. In the case of p ( x ) = 0 {\displaystyle p(x)=0} for some x ∈ X {\displaystyle x\in {\mathcal {X}}} , the value of the corresponding summand 0 logb(0) is taken to be 0, which is consistent with the limit:: 13  lim p → 0 + p log ⁡ ( p ) = 0. {\displaystyle \lim _{p\to 0^{+}}p\log(p)=0.} One may also define the conditional entropy of two variables X {\displaystyle X} and Y {\displaystyle Y} taking values from sets X {\displaystyle {\mathcal {X}}} and Y {\displaystyle {\mathcal {Y}}} respectively, as:: 16  H ( X | Y ) = − ∑ x , y ∈ X × Y p X , Y ( x , y ) log ⁡ p X , Y ( x , y ) p Y ( y ) , {\displaystyle \mathrm {H} (X|Y)=-\sum _{x,y\in {\mathcal {X}}\times {\mathcal {Y}}}p_{X,Y}(x,y)\log {\frac {p_{X,Y}(x,y)}{p_{Y}(y)}},} where p X , Y ( x , y ) := P [ X = x , Y = y ] {\displaystyle p_{X,Y}(x,y):=\mathbb {P} [X=x,Y=y]} and p Y ( y ) = P [ Y = y ] {\displaystyle p_{Y}(y)=\mathbb {P} [Y=y]} . This quantity should be understood as the remaining randomness in the random variable X {\displaystyle X} given the random variable Y {\displaystyle Y} . === Measure theory === Entropy can be formally defined in the language of measure theory as follows: Let ( X , Σ , μ ) {\displaystyle (X,\Sigma ,\mu )} be a probability space. Let A ∈ Σ {\displaystyle A\in \Sigma } be an event. The surprisal of A {\displaystyle A} is σ μ ( A ) = − ln ⁡ μ ( A ) . {\displaystyle \sigma _{\mu }(A)=-\ln \mu (A).} The expected surprisal of A {\displaystyle A} is h μ ( A ) = μ ( A ) σ μ ( A ) . {\displaystyle h_{\mu }(A)=\mu (A)\sigma _{\mu }(A).} A μ {\displaystyle \mu } -almost partition is a set family P ⊆ P ( X ) {\displaystyle P\subseteq {\mathcal {P}}(X)} such that μ ( ∪ ⁡ P ) = 1 {\displaystyle \mu (\mathop {\cup } P)=1} and μ ( A ∩ B ) = 0 {\displaystyle \mu (A\cap B)=0} for all distinct A , B ∈ P {\displaystyle A,B\in P} . (This is a relaxation of the usual conditions for a partition.) The entropy of P {\displaystyle P} is H μ ( P ) = ∑ A ∈ P h μ ( A ) . {\displaystyle \mathrm {H} _{\mu }(P)=\sum _{A\in P}h_{\mu }(A).} Let M {\displaystyle M} be a sigma-algebra on X {\displaystyle X} . The entropy of M {\displaystyle M} is H μ ( M ) = sup P ⊆ M H μ ( P ) . {\displaystyle \mathrm {H} _{\mu }(M)=\sup _{P\subseteq M}\mathrm {H} _{\mu }(P).} Finally, the entropy of the probability space is H μ ( Σ ) {\displaystyle \mathrm {H} _{\mu }(\Sigma )} , that is, the entropy with respect to μ {\displaystyle \mu } of the sigma-algebra of all measurable subsets of X {\displaystyle X} . Recent studies on layered dynamical systems have introduced the concept of symbolic conditional entropy, further extending classical entropy measures to more abstract informational structures. == Example == Consider tossing a coin with known, not necessarily fair, probabilities of coming up heads or tails; this can be modeled as a Bernoulli process. The entropy of the unknown result of the next toss of the coin is maximized if the coin is fair (that is, if heads and tails both have equal probability 1/2). This is the situation of maximum uncertainty as it is most difficult to predict the outcome of the next toss; the result of each toss of the coin delivers one full bit of information. This is because H ( X ) = − ∑ i = 1 n p ( x i ) log b ⁡ p ( x i ) = − ∑ i = 1 2 1 2 log 2 ⁡ 1 2 = − ∑ i = 1 2 1 2 ⋅ ( − 1 ) = 1. {\displaystyle {\begin{aligned}\mathrm {H} (X)&=-\sum _{i=1}^{n}{p(x_{i})\log _{b}p(x_{i})}\\&=-\sum _{i=1}^{2}{{\frac {1}{2}}\log _{2}{\frac {1}{2}}}\\&=-\sum _{i=1}^{2}{{\frac {1}{2}}\cdot (-1)}=1.\end{aligned}}} However, if we know the coin is not fair, but comes up heads or tails with probabilities p and q, where p ≠ q, then there is less uncertainty. Every time it is tossed, one side is more likely to come up than the other. The reduced uncertainty is quantified in a lower entropy: on average each toss of the coin delivers less than one full bit of information. For example, if p = 0.7, then H ( X ) = − p log 2 ⁡ p − q log 2 ⁡ q = − 0.7 log 2 ⁡ ( 0.7 ) − 0.3 log 2 ⁡ ( 0.3 ) ≈ − 0.7 ⋅ ( − 0.515 ) − 0.3 ⋅ ( − 1.737 ) = 0.8816 < 1. {\displaystyle {\begin{aligned}\mathrm {H} (X)&=-p\log _{2}p-q\log _{2}q\\[1ex]&=-0.7\log _{2}(0.7)-0.3\log _{2}(0.3)\\[1ex]&\approx -0.7\cdot (-0.515)-0.3\cdot (-1.737)\\[1ex]&=0.8816<1.\end{aligned}}} Uniform probability yields maximum uncertainty and therefore maximum entropy. Entropy, then, can only decrease from the value associated with uniform probability. The extreme case is that of a double-headed coin that never comes up tails, or a double-tailed coin that never results in a head. Then there is no uncertainty. The entropy is zero: each toss of the coin delivers no new information as the outcome of each coin toss is always certain.: 14–15  == Characterization == To understand the meaning of −Σ pi log(pi), first define an information function I in terms of an event i with probability pi. The amount of information acquired due to the observation of event i follows from Shannon's solution of the fundamental properties of information: I(p) is monotonically decreasing in p: an increase in the probability of an event decreases the information from an observed event, and vice versa. I(1) = 0: events that always occur do not communicate information. I(p1·p2) = I(p1) + I(p2): the information learned from independent events is the sum of the information learned from each event. I(p) is a twice continuously differentiable function of p. Given two independent events, if the first event can yield one of n equiprobable outcomes and another has one of m equiprobable outcomes then there are mn equiprobable outcomes of the joint event. This means that if log2(n) bits are needed to encode the first value and log2(m) to encode the second, one needs log2(mn) = log2(m) + log2(n) to encode both. Shannon discovered that a suitable choice of I {\displaystyle \operatorname {I} } is given by: I ⁡ ( p ) = log ⁡ ( 1 p ) = − log ⁡ ( p ) . {\displaystyle \operatorname {I} (p)=\log \left({\tfrac {1}{p}}\right)=-\log(p).} In fact, the only possible values of I {\displaystyle \operatorname {I} } are I ⁡ ( u ) = k log ⁡ u {\displaystyle \operatorname {I} (u)=k\log u} for k < 0 {\displaystyle k<0} . Additionally, choosing a value for k is equivalent to choosing a value x > 1 {\displaystyle x>1} for k = − 1 / log ⁡ x {\displaystyle k=-1/\log x} , so that x corresponds to the base for the logarithm. Thus, entropy is characterized by the above four properties. The different units of information (bits for the binary logarithm log2, nats for the natural logarithm ln, bans for the decimal logarithm log10 and so on) are constant multiples of each other. For instance, in case of a fair coin toss, heads provides log2(2) = 1 bit of information, which is approximately 0.693 nats or 0.301 decimal digits. Because of additivity, n tosses provide n bits of information, which is approximately 0.693n nats or 0.301n decimal digits. The meaning of the events observed (the meaning of messages) does not matter in the definition of entropy. Entropy only takes into account the probability of observing a specific event, so the information it encapsulates is information about the underlying probability distribution, not the meaning of the events themselves. === Alternative characterization === Another characterization of entropy uses the following properties. We denote pi = Pr(X = xi) and Ηn(p1, ..., pn) = Η(X). Continuity: H should be continuous, so that changing the values of the probabilities by a very small amount should only change the entropy by a small amount. Symmetry: H should be unchanged if the outcomes xi are re-ordered. That is, H n ( p 1 , p 2 , … , p n ) = H n ( p i 1 , p i 2 , … , p i n ) {\displaystyle \mathrm {H} _{n}\left(p_{1},p_{2},\ldots ,p_{n}\right)=\mathrm {H} _{n}\left(p_{i_{1}},p_{i_{2}},\ldots ,p_{i_{n}}\right)} for any permutation { i 1 , . . . , i n } {\displaystyle \{i_{1},...,i_{n}\}} of { 1 , . . . , n } {\displaystyle \{1,...,n\}} . Maximum: H n {\displaystyle \mathrm {H} _{n}} should be maximal if all the outcomes are equally likely i.e. H n ( p 1 , … , p n ) ≤ H n ( 1 n , … , 1 n ) {\displaystyle \mathrm {H} _{n}(p_{1},\ldots ,p_{n})\leq \mathrm {H} _{n}\left({\frac {1}{n}},\ldots ,{\frac {1}{n}}\right)} . Increasing number of outcomes: for equiprobable events, the entropy should increase with the number of outcomes i.e. H n ( 1 n , … , 1 n ⏟ n ) < H n + 1 ( 1 n + 1 , … , 1 n + 1 ⏟ n + 1 ) . {\displaystyle \mathrm {H} _{n}{\bigg (}\underbrace {{\frac {1}{n}},\ldots ,{\frac {1}{n}}} _{n}{\bigg )}<\mathrm {H} _{n+1}{\bigg (}\underbrace {{\frac {1}{n+1}},\ldots ,{\frac {1}{n+1}}} _{n+1}{\bigg )}.} Additivity: given an ensemble of n uniformly distributed elements that are partitioned into k boxes (sub-systems) with b1, ..., bk elements each, the entropy of the whole ensemble should be equal to the sum of the entropy of the system of boxes and the individual entropies of the boxes, each weighted with the probability of being in that particular box. ==== Discussion ==== The rule of additivity has the following consequences: for positive integers bi where b1 + ... + bk = n, H n ( 1 n , … , 1 n ) = H k ( b 1 n , … , b k n ) + ∑ i = 1 k b i n H b i ( 1 b i , … , 1 b i ) . {\displaystyle \mathrm {H} _{n}\left({\frac {1}{n}},\ldots ,{\frac {1}{n}}\right)=\mathrm {H} _{k}\left({\frac {b_{1}}{n}},\ldots ,{\frac {b_{k}}{n}}\right)+\sum _{i=1}^{k}{\frac {b_{i}}{n}}\,\mathrm {H} _{b_{i}}\left({\frac {1}{b_{i}}},\ldots ,{\frac {1}{b_{i}}}\right).} Choosing k = n, b1 = ... = bn = 1 this implies that the entropy of a certain outcome is zero: Η1(1) = 0. This implies that the efficiency of a source set with n symbols can be defined simply as being equal to its n-ary entropy. See also Redundancy (information theory). The characterization here imposes an additive property with respect to a partition of a set. Meanwhile, the conditional probability is defined in terms of a multiplicative property, P ( A ∣ B ) ⋅ P ( B ) = P ( A ∩ B ) {\displaystyle P(A\mid B)\cdot P(B)=P(A\cap B)} . Observe that a logarithm mediates between these two operations. The conditional entropy and related quantities inherit simple relation, in turn. The measure theoretic definition in the previous section defined the entropy as a sum over expected surprisals μ ( A ) ⋅ ln ⁡ μ ( A ) {\displaystyle \mu (A)\cdot \ln \mu (A)} for an extremal partition. Here the logarithm is ad hoc and the entropy is not a measure in itself. At least in the information theory of a binary string, log 2 {\displaystyle \log _{2}} lends itself to practical interpretations. Motivated by such relations, a plethora of related and competing quantities have been defined. For example, David Ellerman's analysis of a "logic of partitions" defines a competing measure in structures dual to that of subsets of a universal set. Information is quantified as "dits" (distinctions), a measure on partitions. "Dits" can be converted into Shannon's bits, to get the formulas for conditional entropy, and so on. === Alternative characterization via additivity and subadditivity === Another succinct axiomatic characterization of Shannon entropy was given by Aczél, Forte and Ng, via the following properties: Subadditivity: H ( X , Y ) ≤ H ( X ) + H ( Y ) {\displaystyle \mathrm {H} (X,Y)\leq \mathrm {H} (X)+\mathrm {H} (Y)} for jointly distributed random variables X , Y {\displaystyle X,Y} . Additivity: H ( X , Y ) = H ( X ) + H ( Y ) {\displaystyle \mathrm {H} (X,Y)=\mathrm {H} (X)+\mathrm {H} (Y)} when the random variables X , Y {\displaystyle X,Y} are independent. Expansibility: H n + 1 ( p 1 , … , p n , 0 ) = H n ( p 1 , … , p n ) {\displaystyle \mathrm {H} _{n+1}(p_{1},\ldots ,p_{n},0)=\mathrm {H} _{n}(p_{1},\ldots ,p_{n})} , i.e., adding an outcome with probability zero does not change the entropy. Symmetry: H n ( p 1 , … , p n ) {\displaystyle \mathrm {H} _{n}(p_{1},\ldots ,p_{n})} is invariant under permutation of p 1 , … , p n {\displaystyle p_{1},\ldots ,p_{n}} . Small for small probabilities: lim q → 0 + H 2 ( 1 − q , q ) = 0 {\displaystyle \lim _{q\to 0^{+}}\mathrm {H} _{2}(1-q,q)=0} . ==== Discussion ==== It was shown that any function H {\displaystyle \mathrm {H} } satisfying the above properties must be a constant multiple of Shannon entropy, with a non-negative constant. Compared to the previously mentioned characterizations of entropy, this characterization focuses on the properties of entropy as a function of random variables (subadditivity and additivity), rather than the properties of entropy as a function of the probability vector p 1 , … , p n {\displaystyle p_{1},\ldots ,p_{n}} . It is worth noting that if we drop the "small for small probabilities" property, then H {\displaystyle \mathrm {H} } must be a non-negative linear combination of the Shannon entropy and the Hartley entropy. == Further properties == The Shannon entropy satisfies the following properties, for some of which it is useful to interpret entropy as the expected amount of information learned (or uncertainty eliminated) by revealing the value of a random variable X: Adding or removing an event with probability zero does not contribute to the entropy: H n + 1 ( p 1 , … , p n , 0 ) = H n ( p 1 , … , p n ) . {\displaystyle \mathrm {H} _{n+1}(p_{1},\ldots ,p_{n},0)=\mathrm {H} _{n}(p_{1},\ldots ,p_{n}).} The maximal entropy of an event with n different outcomes is logb(n): it is attained by the uniform probability distribution. That is, uncertainty is maximal when all possible events are equiprobable:: 29  H ( p 1 , … , p n ) ≤ log b ⁡ n . {\displaystyle \mathrm {H} (p_{1},\dots ,p_{n})\leq \log _{b}n.} The entropy or the amount of information revealed by evaluating (X,Y) (that is, evaluating X and Y simultaneously) is equal to the information revealed by conducting two consecutive experiments: first evaluating the value of Y, then revealing the value of X given that you know the value of Y. This may be written as:: 16  H ( X , Y ) = H ( X | Y ) + H ( Y ) = H ( Y | X ) + H ( X ) . {\displaystyle \mathrm {H} (X,Y)=\mathrm {H} (X|Y)+\mathrm {H} (Y)=\mathrm {H} (Y|X)+\mathrm {H} (X).} If Y = f ( X ) {\displaystyle Y=f(X)} where f {\displaystyle f} is a function, then H ( f ( X ) | X ) = 0 {\displaystyle \mathrm {H} (f(X)|X)=0} . Applying the previous formula to H ( X , f ( X ) ) {\displaystyle \mathrm {H} (X,f(X))} yields H ( X ) + H ( f ( X ) | X ) = H ( f ( X ) ) + H ( X | f ( X ) ) , {\displaystyle \mathrm {H} (X)+\mathrm {H} (f(X)|X)=\mathrm {H} (f(X))+\mathrm {H} (X|f(X)),} so H ( f ( X ) ) ≤ H ( X ) {\displaystyle \mathrm {H} (f(X))\leq \mathrm {H} (X)} , the entropy of a variable can only decrease when the latter is passed through a function. If X and Y are two independent random variables, then knowing the value of Y doesn't influence our knowledge of the value of X (since the two don't influence each other by independence): H ( X | Y ) = H ( X ) . {\displaystyle \mathrm {H} (X|Y)=\mathrm {H} (X).} More generally, for any random variables X and Y, we have: 29  H ( X | Y ) ≤ H ( X ) . {\displaystyle \mathrm {H} (X|Y)\leq \mathrm {H} (X).} The entropy of two simultaneous events is no more than the sum of the entropies of each individual event i.e., H ( X , Y ) ≤ H ( X ) + H ( Y ) {\displaystyle \mathrm {H} (X,Y)\leq \mathrm {H} (X)+\mathrm {H} (Y)} , with equality if and only if the two events are independent.: 28  The entropy H ( p ) {\displaystyle \mathrm {H} (p)} is concave in the probability mass function p {\displaystyle p} , i.e.: 30  H ( λ p 1 + ( 1 − λ ) p 2 ) ≥ λ H ( p 1 ) + ( 1 − λ ) H ( p 2 ) {\displaystyle \mathrm {H} (\lambda p_{1}+(1-\lambda )p_{2})\geq \lambda \mathrm {H} (p_{1})+(1-\lambda )\mathrm {H} (p_{2})} for all probability mass functions p 1 , p 2 {\displaystyle p_{1},p_{2}} and 0 ≤ λ ≤ 1 {\displaystyle 0\leq \lambda \leq 1} .: 32  Accordingly, the negative entropy (negentropy) function is convex, and its convex conjugate is LogSumExp. == Aspects == === Relationship to thermodynamic entropy === The inspiration for adopting the word entropy in information theory came from the close resemblance between Shannon's formula and very similar known formulae from statistical mechanics. In statistical thermodynamics the most general formula for the thermodynamic entropy S of a thermodynamic system is the Gibbs entropy S = − k B ∑ i p i ln ⁡ p i , {\displaystyle S=-k_{\text{B}}\sum _{i}p_{i}\ln p_{i}\,,} where kB is the Boltzmann constant, and pi is the probability of a microstate. The Gibbs entropy was defined by J. Willard Gibbs in 1878 after earlier work by Ludwig Boltzmann (1872). The Gibbs entropy translates over almost unchanged into the world of quantum physics to give the von Neumann entropy introduced by John von Neumann in 1927: S = − k B T r ( ρ ln ⁡ ρ ) , {\displaystyle S=-k_{\text{B}}\,{\rm {Tr}}(\rho \ln \rho )\,,} where ρ is the density matrix of the quantum mechanical system and Tr is the trace. At an everyday practical level, the links between information entropy and thermodynamic entropy are not evident. Physicists and chemists are apt to be more interested in changes in entropy as a system spontaneously evolves away from its initial conditions, in accordance with the second law of thermodynamics, rather than an unchanging probability distribution. As the minuteness of the Boltzmann constant kB indicates, the changes in S / kB for even tiny amounts of substances in chemical and physical processes represent amounts of entropy that are extremely large compared to anything in data compression or signal processing. In classical thermodynamics, entropy is defined in terms of macroscopic measurements and makes no reference to any probability distribution, which is central to the definition of information entropy. The connection between thermodynamics and what is now known as information theory was first made by Boltzmann and expressed by his equation: S = k B ln ⁡ W , {\displaystyle S=k_{\text{B}}\ln W,} where S {\displaystyle S} is the thermodynamic entropy of a particular macrostate (defined by thermodynamic parameters such as temperature, volume, energy, etc.), W is the number of microstates (various combinations of particles in various energy states) that can yield the given macrostate, and kB is the Boltzmann constant. It is assumed that each microstate is equally likely, so that the probability of a given microstate is pi = 1/W. When these probabilities are substituted into the above expression for the Gibbs entropy (or equivalently kB times the Shannon entropy), Boltzmann's equation results. In information theoretic terms, the information entropy of a system is the amount of "missing" information needed to determine a microstate, given the macrostate. In the view of Jaynes (1957), thermodynamic entropy, as explained by statistical mechanics, should be seen as an application of Shannon's information theory: the thermodynamic entropy is interpreted as being proportional to the amount of further Shannon information needed to define the detailed microscopic state of the system, that remains uncommunicated by a description solely in terms of the macroscopic variables of classical thermodynamics, with the constant of proportionality being just the Boltzmann constant. Adding heat to a system increases its thermodynamic entropy because it increases the number of possible microscopic states of the system that are consistent with the measurable values of its macroscopic variables, making any complete state description longer. (See article: maximum entropy thermodynamics). Maxwell's demon can (hypothetically) reduce the thermodynamic entropy of a system by using information about the states of individual molecules; but, as Landauer (from 1961) and co-workers have shown, to function the demon himself must increase thermodynamic entropy in the process, by at least the amount of Shannon information he proposes to first acquire and store; and so the total thermodynamic entropy does not decrease (which resolves the paradox). Landauer's principle imposes a lower bound on the amount of heat a computer must generate to process a given amount of information, though modern computers are far less efficient. === Data compression === Shannon's definition of entropy, when applied to an information source, can determine the minimum channel capacity required to reliably transmit the source as encoded binary digits. Shannon's entropy measures the information contained in a message as opposed to the portion of the message that is determined (or predictable). Examples of the latter include redundancy in language structure or statistical properties relating to the occurrence frequencies of letter or word pairs, triplets etc. The minimum channel capacity can be realized in theory by using the typical set or in practice using Huffman, Lempel–Ziv or arithmetic coding. (See also Kolmogorov complexity.) In practice, compression algorithms deliberately include some judicious redundancy in the form of checksums to protect against errors. The entropy rate of a data source is the average number of bits per symbol needed to encode it. Shannon's experiments with human predictors show an information rate between 0.6 and 1.3 bits per character in English; the PPM compression algorithm can achieve a compression ratio of 1.5 bits per character in English text. If a compression scheme is lossless – one in which you can always recover the entire original message by decompression – then a compressed message has the same quantity of information as the original but is communicated in fewer characters. It has more information (higher entropy) per character. A compressed message has less redundancy. Shannon's source coding theorem states a lossless compression scheme cannot compress messages, on average, to have more than one bit of information per bit of message, but that any value less than one bit of information per bit of message can be attained by employing a suitable coding scheme. The entropy of a message per bit multiplied by the length of that message is a measure of how much total information the message contains. Shannon's theorem also implies that no lossless compression scheme can shorten all messages. If some messages come out shorter, at least one must come out longer due to the pigeonhole principle. In practical use, this is generally not a problem, because one is usually only interested in compressing certain types of messages, such as a document in English, as opposed to gibberish text, or digital photographs rather than noise, and it is unimportant if a compression algorithm makes some unlikely or uninteresting sequences larger. A 2011 study in Science estimates the world's technological capacity to store and communicate optimally compressed information normalized on the most effective compression algorithms available in the year 2007, therefore estimating the entropy of the technologically available sources.: 60–65  The authors estimate humankind technological capacity to store information (fully entropically compressed) in 1986 and again in 2007. They break the information into three categories—to store information on a medium, to receive information through one-way broadcast networks, or to exchange information through two-way telecommunications networks. === Entropy as a measure of diversity === Entropy is one of several ways to measure biodiversity and is applied in the form of the Shannon index. A diversity index is a quantitative statistical measure of how many different types exist in a dataset, such as species in a community, accounting for ecological richness, evenness, and dominance. Specifically, Shannon entropy is the logarithm of 1D, the true diversity index with parameter equal to 1. The Shannon index is related to the proportional abundances of types. === Entropy of a sequence === There are a number of entropy-related concepts that mathematically quantify information content of a sequence or message: the self-information of an individual message or symbol taken from a given probability distribution (message or sequence seen as an individual event), the joint entropy of the symbols forming the message or sequence (seen as a set of events), the entropy rate of a stochastic process (message or sequence is seen as a succession of events). (The "rate of self-information" can also be defined for a particular sequence of messages or symbols generated by a given stochastic process: this will always be equal to the entropy rate in the case of a stationary process.) Other quantities of information are also used to compare or relate different sources of information. It is important not to confuse the above concepts. Often it is only clear from context which one is meant. For example, when someone says that the "entropy" of the English language is about 1 bit per character, they are actually modeling the English language as a stochastic process and talking about its entropy rate. Shannon himself used the term in this way. If very large blocks are used, the estimate of per-character entropy rate may become artificially low because the probability distribution of the sequence is not known exactly; it is only an estimate. If one considers the text of every book ever published as a sequence, with each symbol being the text of a complete book, and if there are N published books, and each book is only published once, the estimate of the probability of each book is 1/N, and the entropy (in bits) is −log2(1/N) = log2(N). As a practical code, this corresponds to assigning each book a unique identifier and using it in place of the text of the book whenever one wants to refer to the book. This is enormously useful for talking about books, but it is not so useful for characterizing the information content of an individual book, or of language in general: it is not possible to reconstruct the book from its identifier without knowing the probability distribution, that is, the complete text of all the books. The key idea is that the complexity of the probabilistic model must be considered. Kolmogorov complexity is a theoretical generalization of this idea that allows the consideration of the information content of a sequence independent of any particular probability model; it considers the shortest program for a universal computer that outputs the sequence. A code that achieves the entropy rate of a sequence for a given model, plus the codebook (i.e. the probabilistic model), is one such program, but it may not be the shortest. The Fibonacci sequence is 1, 1, 2, 3, 5, 8, 13, .... treating the sequence as a message and each number as a symbol, there are almost as many symbols as there are characters in the message, giving an entropy of approximately log2(n). The first 128 symbols of the Fibonacci sequence has an entropy of approximately 7 bits/symbol, but the sequence can be expressed using a formula [F(n) = F(n−1) + F(n−2) for n = 3, 4, 5, ..., F(1) =1, F(2) = 1] and this formula has a much lower entropy and applies to any length of the Fibonacci sequence. === Limitations of entropy in cryptography === In cryptanalysis, entropy is often roughly used as a measure of the unpredictability of a cryptographic key, though its real uncertainty is unmeasurable. For example, a 128-bit key that is uniformly and randomly generated has 128 bits of entropy. It also takes (on average) 2 127 {\displaystyle 2^{127}} guesses to break by brute force. Entropy fails to capture the number of guesses required if the possible keys are not chosen uniformly. Instead, a measure called guesswork can be used to measure the effort required for a brute force attack. Other problems may arise from non-uniform distributions used in cryptography. For example, a 1,000,000-digit binary one-time pad using exclusive or. If the pad has 1,000,000 bits of entropy, it is perfect. If the pad has 999,999 bits of entropy, evenly distributed (each individual bit of the pad having 0.999999 bits of entropy) it may provide good security. But if the pad has 999,999 bits of entropy, where the first bit is fixed and the remaining 999,999 bits are perfectly random, the first bit of the ciphertext will not be encrypted at all. === Data as a Markov process === A common way to define entropy for text is based on the Markov model of text. For an order-0 source (each character is selected independent of the last characters), the binary entropy is: H ( S ) = − ∑ i p i log ⁡ p i , {\displaystyle \mathrm {H} ({\mathcal {S}})=-\sum _{i}p_{i}\log p_{i},} where pi is the probability of i. For a first-order Markov source (one in which the probability of selecting a character is dependent only on the immediately preceding character), the entropy rate is: H ( S ) = − ∑ i p i ∑ j p i ( j ) log ⁡ p i ( j ) , {\displaystyle \mathrm {H} ({\mathcal {S}})=-\sum _{i}p_{i}\sum _{j}\ p_{i}(j)\log p_{i}(j),} where i is a state (certain preceding characters) and p i ( j ) {\displaystyle p_{i}(j)} is the probability of j given i as the previous character. For a second order Markov source, the entropy rate is H ( S ) = − ∑ i p i ∑ j p i ( j ) ∑ k p i , j ( k ) log ⁡ p i , j ( k ) . {\displaystyle \mathrm {H} ({\mathcal {S}})=-\sum _{i}p_{i}\sum _{j}p_{i}(j)\sum _{k}p_{i,j}(k)\ \log p_{i,j}(k).} == Efficiency (normalized entropy) == A source set X {\displaystyle {\mathcal {X}}} with a non-uniform distribution will have less entropy than the same set with a uniform distribution (i.e. the "optimized alphabet"). This deficiency in entropy can be expressed as a ratio called efficiency: η ( X ) = H H max = − ∑ i = 1 n p ( x i ) log b ⁡ ( p ( x i ) ) log b ⁡ ( n ) . {\displaystyle \eta (X)={\frac {H}{H_{\text{max}}}}=-\sum _{i=1}^{n}{\frac {p(x_{i})\log _{b}(p(x_{i}))}{\log _{b}(n)}}.} Applying the basic properties of the logarithm, this quantity can also be expressed as: η ( X ) = − ∑ i = 1 n p ( x i ) log b ⁡ ( p ( x i ) ) log b ⁡ ( n ) = ∑ i = 1 n log b ⁡ ( p ( x i ) − p ( x i ) ) log b ⁡ ( n ) = ∑ i = 1 n log n ⁡ ( p ( x i ) − p ( x i ) ) = log n ⁡ ( ∏ i = 1 n p ( x i ) − p ( x i ) ) . {\displaystyle {\begin{aligned}\eta (X)&=-\sum _{i=1}^{n}{\frac {p(x_{i})\log _{b}(p(x_{i}))}{\log _{b}(n)}}=\sum _{i=1}^{n}{\frac {\log _{b}\left(p(x_{i})^{-p(x_{i})}\right)}{\log _{b}(n)}}\\[1ex]&=\sum _{i=1}^{n}\log _{n}\left(p(x_{i})^{-p(x_{i})}\right)=\log _{n}\left(\prod _{i=1}^{n}p(x_{i})^{-p(x_{i})}\right).\end{aligned}}} Efficiency has utility in quantifying the effective use of a communication channel. This formulation is also referred to as the normalized entropy, as the entropy is divided by the maximum entropy log b ⁡ ( n ) {\displaystyle {\log _{b}(n)}} . Furthermore, the efficiency is indifferent to the choice of (positive) base b, as indicated by the insensitivity within the final logarithm above thereto. == Entropy for continuous random variables == === Differential entropy === The Shannon entropy is restricted to random variables taking discrete values. The corresponding formula for a continuous random variable with probability density function f(x) with finite or infinite support X {\displaystyle \mathbb {X} } on the real line is defined by analogy, using the above form of the entropy as an expectation:: 224  H ( X ) = E [ − log ⁡ f ( X ) ] = − ∫ X f ( x ) log ⁡ f ( x ) d x . {\displaystyle \mathrm {H} (X)=\mathbb {E} [-\log f(X)]=-\int _{\mathbb {X} }f(x)\log f(x)\,\mathrm {d} x.} This is the differential entropy (or continuous entropy). A precursor of the continuous entropy h[f] is the expression for the functional Η in the H-theorem of Boltzmann. Although the analogy between both functions is suggestive, the following question must be set: is the differential entropy a valid extension of the Shannon discrete entropy? Differential entropy lacks a number of properties that the Shannon discrete entropy has – it can even be negative – and corrections have been suggested, notably limiting density of discrete points. To answer this question, a connection must be established between the two functions: In order to obtain a generally finite measure as the bin size goes to zero. In the discrete case, the bin size is the (implicit) width of each of the n (finite or infinite) bins whose probabilities are denoted by pn. As the continuous domain is generalized, the width must be made explicit. To do this, start with a continuous function f discretized into bins of size Δ {\displaystyle \Delta } . By the mean-value theorem there exists a value xi in each bin such that f ( x i ) Δ = ∫ i Δ ( i + 1 ) Δ f ( x ) d x {\displaystyle f(x_{i})\Delta =\int _{i\Delta }^{(i+1)\Delta }f(x)\,dx} the integral of the function f can be approximated (in the Riemannian sense) by ∫ − ∞ ∞ f ( x ) d x = lim Δ → 0 ∑ i = − ∞ ∞ f ( x i ) Δ , {\displaystyle \int _{-\infty }^{\infty }f(x)\,dx=\lim _{\Delta \to 0}\sum _{i=-\infty }^{\infty }f(x_{i})\Delta ,} where this limit and "bin size goes to zero" are equivalent. We will denote H Δ := − ∑ i = − ∞ ∞ f ( x i ) Δ log ⁡ ( f ( x i ) Δ ) {\displaystyle \mathrm {H} ^{\Delta }:=-\sum _{i=-\infty }^{\infty }f(x_{i})\Delta \log \left(f(x_{i})\Delta \right)} and expanding the logarithm, we have H Δ = − ∑ i = − ∞ ∞ f ( x i ) Δ log ⁡ ( f ( x i ) ) − ∑ i = − ∞ ∞ f ( x i ) Δ log ⁡ ( Δ ) . {\displaystyle \mathrm {H} ^{\Delta }=-\sum _{i=-\infty }^{\infty }f(x_{i})\Delta \log(f(x_{i}))-\sum _{i=-\infty }^{\infty }f(x_{i})\Delta \log(\Delta ).} As Δ → 0, we have ∑ i = − ∞ ∞ f ( x i ) Δ → ∫ − ∞ ∞ f ( x ) d x = 1 ∑ i = − ∞ ∞ f ( x i ) Δ log ⁡ ( f ( x i ) ) → ∫ − ∞ ∞ f ( x ) log ⁡ f ( x ) d x . {\displaystyle {\begin{aligned}\sum _{i=-\infty }^{\infty }f(x_{i})\Delta &\to \int _{-\infty }^{\infty }f(x)\,dx=1\\\sum _{i=-\infty }^{\infty }f(x_{i})\Delta \log(f(x_{i}))&\to \int _{-\infty }^{\infty }f(x)\log f(x)\,dx.\end{aligned}}} Note; log(Δ) → −∞ as Δ → 0, requires a special definition of the differential or continuous entropy: h [ f ] = lim Δ → 0 ( H Δ + log ⁡ Δ ) = − ∫ − ∞ ∞ f ( x ) log ⁡ f ( x ) d x , {\displaystyle h[f]=\lim _{\Delta \to 0}\left(\mathrm {H} ^{\Delta }+\log \Delta \right)=-\int _{-\infty }^{\infty }f(x)\log f(x)\,dx,} which is, as said before, referred to as the differential entropy. This means that the differential entropy is not a limit of the Shannon entropy for n → ∞. Rather, it differs from the limit of the Shannon entropy by an infinite offset (see also the article on information dimension). === Limiting density of discrete points === It turns out as a result that, unlike the Shannon entropy, the differential entropy is not in general a good measure of uncertainty or information. For example, the differential entropy can be negative; also it is not invariant under continuous co-ordinate transformations. This problem may be illustrated by a change of units when x is a dimensioned variable. f(x) will then have the units of 1/x. The argument of the logarithm must be dimensionless, otherwise it is improper, so that the differential entropy as given above will be improper. If Δ is some "standard" value of x (i.e. "bin size") and therefore has the same units, then a modified differential entropy may be written in proper form as: H = ∫ − ∞ ∞ f ( x ) log ⁡ ( f ( x ) Δ ) d x , {\displaystyle \mathrm {H} =\int _{-\infty }^{\infty }f(x)\log(f(x)\,\Delta )\,dx,} and the result will be the same for any choice of units for x. In fact, the limit of discrete entropy as N → ∞ {\displaystyle N\rightarrow \infty } would also include a term of log ⁡ ( N ) {\displaystyle \log(N)} , which would in general be infinite. This is expected: continuous variables would typically have infinite entropy when discretized. The limiting density of discrete points is really a measure of how much easier a distribution is to describe than a distribution that is uniform over its quantization scheme. === Relative entropy === Another useful measure of entropy that works equally well in the discrete and the continuous case is the relative entropy of a distribution. It is defined as the Kullback–Leibler divergence from the distribution to a reference measure m as follows. Assume that a probability distribution p is absolutely continuous with respect to a measure m, i.e. is of the form p(dx) = f(x)m(dx) for some non-negative m-integrable function f with m-integral 1, then the relative entropy can be defined as D K L ( p ‖ m ) = ∫ log ⁡ ( f ( x ) ) p ( d x ) = ∫ f ( x ) log ⁡ ( f ( x ) ) m ( d x ) . {\displaystyle D_{\mathrm {KL} }(p\|m)=\int \log(f(x))p(dx)=\int f(x)\log(f(x))m(dx).} In this form the relative entropy generalizes (up to change in sign) both the discrete entropy, where the measure m is the counting measure, and the differential entropy, where the measure m is the Lebesgue measure. If the measure m is itself a probability distribution, the relative entropy is non-negative, and zero if p = m as measures. It is defined for any measure space, hence coordinate independent and invariant under co-ordinate reparameterizations if one properly takes into account the transformation of the measure m. The relative entropy, and (implicitly) entropy and differential entropy, do depend on the "reference" measure m. == Use in number theory == Terence Tao used entropy to make a useful connection trying to solve the Erdős discrepancy problem. Intuitively the idea behind the proof was if there is low information in terms of the Shannon entropy between consecutive random variables (here the random variable is defined using the Liouville function (which is a useful mathematical function for studying distribution of primes) XH = λ ( n + H ) {\displaystyle \lambda (n+H)} . And in an interval [n, n+H] the sum over that interval could become arbitrary large. For example, a sequence of +1's (which are values of XH could take) have trivially low entropy and their sum would become big. But the key insight was showing a reduction in entropy by non negligible amounts as one expands H leading inturn to unbounded growth of a mathematical object over this random variable is equivalent to showing the unbounded growth per the Erdős discrepancy problem. The proof is quite involved and it brought together breakthroughs not just in novel use of Shannon entropy, but also it used the Liouville function along with averages of modulated multiplicative functions in short intervals. Proving it also broke the "parity barrier" for this specific problem. While the use of Shannon entropy in the proof is novel it is likely to open new research in this direction. == Use in combinatorics == Entropy has become a useful quantity in combinatorics. === Loomis–Whitney inequality === A simple example of this is an alternative proof of the Loomis–Whitney inequality: for every subset A ⊆ Zd, we have | A | d − 1 ≤ ∏ i = 1 d | P i ( A ) | {\displaystyle |A|^{d-1}\leq \prod _{i=1}^{d}|P_{i}(A)|} where Pi is the orthogonal projection in the ith coordinate: P i ( A ) = { ( x 1 , … , x i − 1 , x i + 1 , … , x d ) : ( x 1 , … , x d ) ∈ A } . {\displaystyle P_{i}(A)=\{(x_{1},\ldots ,x_{i-1},x_{i+1},\ldots ,x_{d}):(x_{1},\ldots ,x_{d})\in A\}.} The proof follows as a simple corollary of Shearer's inequality: if X1, ..., Xd are random variables and S1, ..., Sn are subsets of {1, ..., d} such that every integer between 1 and d lies in exactly r of these subsets, then H [ ( X 1 , … , X d ) ] ≤ 1 r ∑ i = 1 n H [ ( X j ) j ∈ S i ] {\displaystyle \mathrm {H} [(X_{1},\ldots ,X_{d})]\leq {\frac {1}{r}}\sum _{i=1}^{n}\mathrm {H} [(X_{j})_{j\in S_{i}}]} where ( X j ) j ∈ S i {\displaystyle (X_{j})_{j\in S_{i}}} is the Cartesian product of random variables Xj with indexes j in Si (so the dimension of this vector is equal to the size of Si). We sketch how Loomis–Whitney follows from this: Indeed, let X be a uniformly distributed random variable with values in A and so that each point in A occurs with equal probability. Then (by the further properties of entropy mentioned above) Η(X) = log|A|, where |A| denotes the cardinality of A. Let Si = {1, 2, ..., i−1, i+1, ..., d}. The range of ( X j ) j ∈ S i {\displaystyle (X_{j})_{j\in S_{i}}} is contained in Pi(A) and hence H [ ( X j ) j ∈ S i ] ≤ log ⁡ | P i ( A ) | {\displaystyle \mathrm {H} [(X_{j})_{j\in S_{i}}]\leq \log |P_{i}(A)|} . Now use this to bound the right side of Shearer's inequality and exponentiate the opposite sides of the resulting inequality you obtain. === Approximation to binomial coefficient === For integers 0 < k < n let q = k/n. Then 2 n H ( q ) n + 1 ≤ ( n k ) ≤ 2 n H ( q ) , {\displaystyle {\frac {2^{n\mathrm {H} (q)}}{n+1}}\leq {\tbinom {n}{k}}\leq 2^{n\mathrm {H} (q)},} where : 43  H ( q ) = − q log 2 ⁡ ( q ) − ( 1 − q ) log 2 ⁡ ( 1 − q ) . {\displaystyle \mathrm {H} (q)=-q\log _{2}(q)-(1-q)\log _{2}(1-q).} A nice interpretation of this is that the number of binary strings of length n with exactly k many 1's is approximately 2 n H ( k / n ) {\displaystyle 2^{n\mathrm {H} (k/n)}} . == Use in machine learning == Machine learning techniques arise largely from statistics and also information theory. In general, entropy is a measure of uncertainty and the objective of machine learning is to minimize uncertainty. Decision tree learning algorithms use relative entropy to determine the decision rules that govern the data at each node. The information gain in decision trees I G ( Y , X ) {\displaystyle IG(Y,X)} , which is equal to the difference between the entropy of Y {\displaystyle Y} and the conditional entropy of Y {\displaystyle Y} given X {\displaystyle X} , quantifies the expected information, or the reduction in entropy, from additionally knowing the value of an attribute X {\displaystyle X} . The information gain is used to identify which attributes of the dataset provide the most information and should be used to split the nodes of the tree optimally. Bayesian inference models often apply the principle of maximum entropy to obtain prior probability distributions. The idea is that the distribution that best represents the current state of knowledge of a system is the one with the largest entropy, and is therefore suitable to be the prior. Classification in machine learning performed by logistic regression or artificial neural networks often employs a standard loss function, called cross-entropy loss, that minimizes the average cross entropy between ground truth and predicted distributions. In general, cross entropy is a measure of the differences between two datasets similar to the KL divergence (also known as relative entropy). == See also == == Notes == == References == This article incorporates material from Shannon's entropy on PlanetMath, which is licensed under the Creative Commons Attribution/Share-Alike License. == Further reading == === Textbooks on information theory === Cover, T.M., Thomas, J.A. (2006), Elements of Information Theory – 2nd Ed., Wiley-Interscience, ISBN 978-0-471-24195-9 MacKay, D.J.C. (2003), Information Theory, Inference and Learning Algorithms, Cambridge University Press, ISBN 978-0-521-64298-9 Arndt, C. (2004), Information Measures: Information and its Description in Science and Engineering, Springer, ISBN 978-3-540-40855-0 Gray, R. M. (2011), Entropy and Information Theory, Springer. Martin, Nathaniel F.G.; England, James W. (2011). Mathematical Theory of Entropy. Cambridge University Press. ISBN 978-0-521-17738-2. Shannon, C.E., Weaver, W. (1949) The Mathematical Theory of Communication, Univ of Illinois Press. ISBN 0-252-72548-4 Stone, J. V. (2014), Chapter 1 of Information Theory: A Tutorial Introduction Archived 3 June 2016 at the Wayback Machine, University of Sheffield, England. ISBN 978-0956372857. == External links == "Entropy", Encyclopedia of Mathematics, EMS Press, 2001 [1994] "Entropy" Archived 4 June 2016 at the Wayback Machine at Rosetta Code—repository of implementations of Shannon entropy in different programming languages. Entropy Archived 31 May 2016 at the Wayback Machine an interdisciplinary journal on all aspects of the entropy concept. Open access.
Wikipedia/Entropy_(information_theory)
The Internet Engineering Task Force (IETF) is a standards organization for the Internet and is responsible for the technical standards that make up the Internet protocol suite (TCP/IP). It has no formal membership roster or requirements and all its participants are volunteers. Their work is usually funded by employers or other sponsors. The IETF was initially supported by the federal government of the United States but since 1993 has operated under the auspices of the Internet Society, a non-profit organization with local chapters around the world. == Organization == There is no membership in the IETF. Anyone can participate by signing up to a working group mailing list, or registering for an IETF meeting. The IETF operates in a bottom-up task creation mode, largely driven by working groups. Each working group normally has appointed two co-chairs (occasionally three); a charter that describes its focus; and what it is expected to produce, and when. It is open to all who want to participate and holds discussions on an open mailing list. Working groups hold open sessions at IETF meetings, where the onsite registration fee in 2024 was between US$875 (early registration) and $1200 per person for the week. Significant discounts are available for students and remote participants. As working groups do not make decisions at IETF meetings, with all decisions taken later on the working group mailing list, meeting attendance is not required for contributors. Rough consensus is the primary basis for decision making. There are no formal voting procedures. Each working group is intended to complete work on its topic and then disband. In some cases, the working group will instead have its charter updated to take on new tasks as appropriate. The working groups are grouped into areas by subject matter (see § Steering group, below). Each area is overseen by an area director (AD), with most areas having two ADs. The ADs are responsible for appointing working group chairs. The area directors, together with the IETF Chair, form the Internet Engineering Steering Group (IESG), which is responsible for the overall operation of the IETF. The Internet Architecture Board (IAB) oversees the IETF's external relationships. The IAB provides long-range technical direction for Internet development. The IAB also manages the Internet Research Task Force (IRTF), with which the IETF has a number of cross-group relations. A nominating committee (NomCom) of ten randomly chosen volunteers who participate regularly at meetings, a non-voting chair and 4-5 liaisons, is vested with the power to appoint, reappoint, and remove members of the IESG, IAB, IETF Trust and the IETF LLC. To date, no one has been removed by a NomCom, although several people have resigned their positions, requiring replacements. In 1993 the IETF changed from an activity supported by the US federal government to an independent, international activity associated with the Internet Society, a US-based 501(c)(3) organization. In 2018 the Internet Society created a subsidiary, the IETF Administration LLC, to be the corporate, legal and financial home for the IETF. IETF activities are funded by meeting fees, meeting sponsors and by the Internet Society via its organizational membership and the proceeds of the Public Interest Registry. In December 2005, the IETF Trust was established to manage the copyrighted materials produced by the IETF. === Steering group === The Internet Engineering Steering Group (IESG) is a body composed of the Internet Engineering Task Force (IETF) chair and area directors. It provides the final technical review of Internet standards and is responsible for day-to-day management of the IETF. It receives appeals of the decisions of the working groups, and the IESG makes the decision to progress documents in the standards track. The chair of the IESG is the area director of the general area, who also serves as the overall IETF chair. Members of the IESG include the two directors, sometimes three, of each of the following areas: Applications and real-time (art) General (gen) Internet (int) Operations and management (ops) Routing (rtg) Security (sec) Web and Internet transport (wit) Liaison and ex officio members include: IETF executive director IAB chair Appointed liaison from the IAB Liaison from the Internet Assigned Numbers Authority (IANA) Liaison from the Request for Comments (RFC) editor == Early leadership and administrative history == The Gateway Algorithms and Data Structures (GADS) Task Force was the precursor to the IETF. Its chairman was David L. Mills of the University of Delaware. In January 1986, the Internet Activities Board (IAB; now called the Internet Architecture Board) decided to divide GADS into two entities: an Internet Architecture (INARC) Task Force chaired by Mills to pursue research goals, and the IETF to handle nearer-term engineering and technology transfer issues. The first IETF chair was Mike Corrigan, who was then the technical program manager for the Defense Data Network (DDN). Also in 1986, after leaving DARPA, Robert E. Kahn founded the Corporation for National Research Initiatives (CNRI), which began providing administrative support to the IETF. In 1987, Corrigan was succeeded as IETF chair by Phill Gross. Effective March 1, 1989, but providing support dating back to late 1988, CNRI and NSF entered into a cooperative agreement, No. NCR-8820945, wherein CNRI agreed to create and provide a "secretariat" for the "overall coordination, management and support of the work of the IAB, its various task forces and, particularly, the IETF". In 1992, CNRI supported the formation and early funding of the Internet Society, which took on the IETF as a fiscally sponsored project, along with the IAB, the IRTF, and the organization of annual INET meetings. Gross continued to serve as IETF chair throughout this transition. Cerf, Kahn, and Lyman Chapin announced the formation of ISOC as "a professional society to facilitate, support, and promote the evolution and growth of the Internet as a global research communications infrastructure". At the first board meeting of the Internet Society, Cerf, representing CNRI, offered, "In the event a deficit occurs, CNRI has agreed to contribute up to USD$102,000 to offset it." In 1993, Cerf continued to support the formation of ISOC while working for CNRI, and the role of ISOC in "the official procedures for creating and documenting Internet Standards" was codified in the IETF's RFC 1602. In 1995, IETF's RFC 2031 describes ISOC's role in the IETF as being purely administrative, and ISOC as having "no influence whatsoever on the Internet Standards process, the Internet Standards or their technical content". In 1998, CNRI established Foretec Seminars, Inc. (Foretec), a for-profit subsidiary to take over providing secretariat services to the IETF. Foretec provided these services until at least 2004. By 2013, Foretec was dissolved. In 2003, IETF's RFC 3677 described IETFs role in appointing three board members to the ISOC's board of directors. In 2018, ISOC established The IETF Administration LLC, a separate LLC to handle the administration of the IETF. In 2019, the LLC issued a call for proposals to provide secretariat services to the IETF. == Meetings == The first IETF meeting was attended by 21 US federal government-funded researchers on 16 January 1986. It was a continuation of the work of the earlier GADS Task Force. Representatives from non-governmental entities (such as gateway vendors) were invited to attend starting with the fourth IETF meeting in October 1986. Since that time all IETF meetings have been open to the public. Initially, the IETF met quarterly, but from 1991, it has been meeting three times a year. The initial meetings were very small, with fewer than 35 people in attendance at each of the first five meetings. The maximum attendance during the first 13 meetings was only 120 attendees. This occurred at the twelfth meeting, held during January 1989. These meetings have grown in both participation and scope a great deal since the early 1990s; it had a maximum attendance of 2810 at the December 2000 IETF held in San Diego, California. Attendance declined with industry restructuring during the early 2000s, and is currently around 1200. The locations for IETF meetings vary greatly. A list of past and future meeting locations is on the IETF meetings page. The IETF strives to hold its meetings near where most of the IETF volunteers are located. IETF meetings are held three times a year, with one meeting each in Asia, Europe and North America. An occasional exploratory meeting is held outside of those regions in place of one of the other regions. The IETF also organizes hackathons during the IETF meetings. The focus is on implementing code that will improve standards in terms of quality and interoperability. Due to recent changes in USA administration that deny entry to foreign free speech supporters and could impact transgender people. There is a movement to ask the IETF to have its meeting outside of the USA in a safe country instead. == Operations == The details of IETF operations have changed considerably as the organization has grown, but the basic mechanism remains publication of proposed specifications, development based on the proposals, review and independent testing by participants, and republication as a revised proposal, a draft proposal, or eventually as an Internet Standard. IETF standards are developed in an open, all-inclusive process in which any interested individual can participate. All IETF documents are freely available over the Internet and can be reproduced at will. Multiple, working, useful, interoperable implementations are the chief requirement before an IETF proposed specification can become a standard. Most specifications are focused on single protocols rather than tightly interlocked systems. This has allowed the protocols to be used in many different systems, and its standards are routinely re-used by bodies which create full-fledged architectures (e.g. 3GPP IMS). Because it relies on volunteers and uses "rough consensus and running code" as its touchstone, results can be slow whenever the number of volunteers is either too small to make progress, or so large as to make consensus difficult, or when volunteers lack the necessary expertise. For protocols like SMTP, which is used to transport e-mail for a user community in the many hundreds of millions, there is also considerable resistance to any change that is not fully backward compatible, except for IPv6. Work within the IETF on ways to improve the speed of the standards-making process is ongoing but, because the number of volunteers with opinions on it is very great, consensus on improvements has been slow to develop. The IETF cooperates with the W3C, ISO/IEC, ITU, and other standards bodies. Statistics are available that show who the top contributors by RFC publication are. While the IETF only allows for participation by individuals, and not by corporations or governments, sponsorship information is available from these statistics. == Chairs == The IETF chairperson is selected by the NomCom process for a two-year renewable term. Before 1993, the IETF Chair was selected by the IAB. A list of the past and current chairs of the IETF: == Topics of interest == The IETF works on a broad range of networking technologies which provide foundation for the Internet's growth and evolution. === Automated network management === It aims to improve the efficiency in management of networks as they grow in size and complexity. The IETF is also standardizing protocols for autonomic networking that enables networks to be self managing. === Internet of things === It is a network of physical objects or things that are embedded with electronics, sensors, software and also enables objects to exchange data with operator, manufacturer and other connected devices. Several IETF working groups are developing protocols that are directly relevant to IoT. === New transport technology === Its development provides the ability of internet applications to send data over the Internet. There are some well-established transport protocols such as TCP (Transmission Control Protocol) and UDP (User Datagram Protocol) which are continuously getting extended and refined to meet the needs of the global Internet. == See also == Internet governance == References == == External links == Official website Steering group IETF Online Proceedings Early IETF Proceedings (note: large pdf files, one for each volume) Past Meetings of the IETF Past IESG Members and IETF Chairs The Tao of the IETF: details on how IETF is organized
Wikipedia/Internet_Engineering_Task_Force
Bosonic string theory is the original version of string theory, developed in the late 1960s. It is so called because it contains only bosons in the spectrum. In the 1980s, supersymmetry was discovered in the context of string theory, and a new version of string theory called superstring theory (supersymmetric string theory) became the real focus. Nevertheless, bosonic string theory remains a very useful model to understand many general features of perturbative string theory, and many theoretical difficulties of superstrings can actually already be found in the context of bosonic strings. == Problems == Although bosonic string theory has many attractive features, it falls short as a viable physical model in two significant areas. First, it predicts only the existence of bosons whereas many physical particles are fermions. Second, it predicts the existence of a mode of the string with imaginary mass, implying that the theory has an instability to a process known as "tachyon condensation". In addition, bosonic string theory in a general spacetime dimension displays inconsistencies due to the conformal anomaly. But, as was first noticed by Claud Lovelace, in a spacetime of 26 dimensions (25 dimensions of space and one of time), the critical dimension for the theory, the anomaly cancels. This high dimensionality is not necessarily a problem for string theory, because it can be formulated in such a way that along the 22 excess dimensions spacetime is folded up to form a small torus or other compact manifold. This would leave only the familiar four dimensions of spacetime visible to low energy experiments. The existence of a critical dimension where the anomaly cancels is a general feature of all string theories. == Types of bosonic strings == There are four possible bosonic string theories, depending on whether open strings are allowed and whether strings have a specified orientation. A theory of open strings must also include closed strings, because open strings can be thought of as having their endpoints fixed on a D25-brane that fills all of spacetime. A specific orientation of the string means that only interaction corresponding to an orientable worldsheet are allowed (e.g., two strings can only merge with equal orientation). A sketch of the spectra of the four possible theories is as follows: Note that all four theories have a negative energy tachyon ( M 2 = − 1 α ′ {\displaystyle M^{2}=-{\frac {1}{\alpha '}}} ) and a massless graviton. The rest of this article applies to the closed, oriented theory, corresponding to borderless, orientable worldsheets. == Mathematics == === Path integral perturbation theory === Bosonic string theory can be said to be defined by the path integral quantization of the Polyakov action: I 0 [ g , X ] = T 8 π ∫ M d 2 ξ g g m n ∂ m x μ ∂ n x ν G μ ν ( x ) {\displaystyle I_{0}[g,X]={\frac {T}{8\pi }}\int _{M}d^{2}\xi {\sqrt {g}}g^{mn}\partial _{m}x^{\mu }\partial _{n}x^{\nu }G_{\mu \nu }(x)} x μ ( ξ ) {\displaystyle x^{\mu }(\xi )} is the field on the worldsheet describing the most embedding of the string in 25 +1 spacetime; in the Polyakov formulation, g {\displaystyle g} is not to be understood as the induced metric from the embedding, but as an independent dynamical field. G {\displaystyle G} is the metric on the target spacetime, which is usually taken to be the Minkowski metric in the perturbative theory. Under a Wick rotation, this is brought to a Euclidean metric G μ ν = δ μ ν {\displaystyle G_{\mu \nu }=\delta _{\mu \nu }} . M is the worldsheet as a topological manifold parametrized by the ξ {\displaystyle \xi } coordinates. T {\displaystyle T} is the string tension and related to the Regge slope as T = 1 2 π α ′ {\displaystyle T={\frac {1}{2\pi \alpha '}}} . I 0 {\displaystyle I_{0}} has diffeomorphism and Weyl invariance. Weyl symmetry is broken upon quantization (Conformal anomaly) and therefore this action has to be supplemented with a counterterm, along with a hypothetical purely topological term, proportional to the Euler characteristic: I = I 0 + λ χ ( M ) + μ 0 2 ∫ M d 2 ξ g {\displaystyle I=I_{0}+\lambda \chi (M)+\mu _{0}^{2}\int _{M}d^{2}\xi {\sqrt {g}}} The explicit breaking of Weyl invariance by the counterterm can be cancelled away in the critical dimension 26. Physical quantities are then constructed from the (Euclidean) partition function and N-point function: Z = ∑ h = 0 ∞ ∫ D g m n D X μ N exp ⁡ ( − I [ g , X ] ) {\displaystyle Z=\sum _{h=0}^{\infty }\int {\frac {{\mathcal {D}}g_{mn}{\mathcal {D}}X^{\mu }}{\mathcal {N}}}\exp(-I[g,X])} ⟨ V i 1 ( k 1 μ ) ⋯ V i p ( k p μ ) ⟩ = ∑ h = 0 ∞ ∫ D g m n D X μ N exp ⁡ ( − I [ g , X ] ) V i 1 ( k 1 μ ) ⋯ V i p ( k p μ ) {\displaystyle \left\langle V_{i_{1}}(k_{1}^{\mu })\cdots V_{i_{p}}(k_{p}^{\mu })\right\rangle =\sum _{h=0}^{\infty }\int {\frac {{\mathcal {D}}g_{mn}{\mathcal {D}}X^{\mu }}{\mathcal {N}}}\exp(-I[g,X])V_{i_{1}}(k_{1}^{\mu })\cdots V_{i_{p}}(k_{p}^{\mu })} The discrete sum is a sum over possible topologies, which for euclidean bosonic orientable closed strings are compact orientable Riemannian surfaces and are thus identified by a genus h {\displaystyle h} . A normalization factor N {\displaystyle {\mathcal {N}}} is introduced to compensate overcounting from symmetries. While the computation of the partition function corresponds to the cosmological constant, the N-point function, including p {\displaystyle p} vertex operators, describes the scattering amplitude of strings. The symmetry group of the action actually reduces drastically the integration space to a finite dimensional manifold. The g {\displaystyle g} path-integral in the partition function is a priori a sum over possible Riemannian structures; however, quotienting with respect to Weyl transformations allows us to only consider conformal structures, that is, equivalence classes of metrics under the identifications of metrics related by g ′ ( ξ ) = e σ ( ξ ) g ( ξ ) {\displaystyle g'(\xi )=e^{\sigma (\xi )}g(\xi )} Since the world-sheet is two dimensional, there is a 1-1 correspondence between conformal structures and complex structures. One still has to quotient away diffeomorphisms. This leaves us with an integration over the space of all possible complex structures modulo diffeomorphisms, which is simply the moduli space of the given topological surface, and is in fact a finite-dimensional complex manifold. The fundamental problem of perturbative bosonic strings therefore becomes the parametrization of Moduli space, which is non-trivial for genus h ≥ 4 {\displaystyle h\geq 4} . ==== h = 0 ==== At tree-level, corresponding to genus 0, the cosmological constant vanishes: Z 0 = 0 {\displaystyle Z_{0}=0} . The four-point function for the scattering of four tachyons is the Shapiro-Virasoro amplitude: A 4 ∝ ( 2 π ) 26 δ 26 ( k ) Γ ( − 1 − s / 2 ) Γ ( − 1 − t / 2 ) Γ ( − 1 − u / 2 ) Γ ( 2 + s / 2 ) Γ ( 2 + t / 2 ) Γ ( 2 + u / 2 ) {\displaystyle A_{4}\propto (2\pi )^{26}\delta ^{26}(k){\frac {\Gamma (-1-s/2)\Gamma (-1-t/2)\Gamma (-1-u/2)}{\Gamma (2+s/2)\Gamma (2+t/2)\Gamma (2+u/2)}}} Where k {\displaystyle k} is the total momentum and s {\displaystyle s} , t {\displaystyle t} , u {\displaystyle u} are the Mandelstam variables. ==== h = 1 ==== Genus 1 is the torus, and corresponds to the one-loop level. The partition function amounts to: Z 1 = ∫ M 1 d 2 τ 8 π 2 τ 2 2 1 ( 4 π 2 τ 2 ) 12 | η ( τ ) | − 48 {\displaystyle Z_{1}=\int _{{\mathcal {M}}_{1}}{\frac {d^{2}\tau }{8\pi ^{2}\tau _{2}^{2}}}{\frac {1}{(4\pi ^{2}\tau _{2})^{12}}}\left|\eta (\tau )\right|^{-48}} τ {\displaystyle \tau } is a complex number with positive imaginary part τ 2 {\displaystyle \tau _{2}} ; M 1 {\displaystyle {\mathcal {M}}_{1}} , holomorphic to the moduli space of the torus, is any fundamental domain for the modular group P S L ( 2 , Z ) {\displaystyle PSL(2,\mathbb {Z} )} acting on the upper half-plane, for example { τ 2 > 0 , | τ | 2 > 1 , − 1 2 < τ 1 < 1 2 } {\displaystyle \left\{\tau _{2}>0,|\tau |^{2}>1,-{\frac {1}{2}}<\tau _{1}<{\frac {1}{2}}\right\}} . η ( τ ) {\displaystyle \eta (\tau )} is the Dedekind eta function. The integrand is of course invariant under the modular group: the measure d 2 τ τ 2 2 {\displaystyle {\frac {d^{2}\tau }{\tau _{2}^{2}}}} is simply the Poincaré metric which has PSL(2,R) as isometry group; the rest of the integrand is also invariant by virtue of τ 2 → | c τ + d | 2 τ 2 {\displaystyle \tau _{2}\rightarrow |c\tau +d|^{2}\tau _{2}} and the fact that η ( τ ) {\displaystyle \eta (\tau )} is a modular form of weight 1/2. This integral diverges. This is due to the presence of the tachyon and is related to the instability of the perturbative vacuum. == See also == Nambu–Goto action Polyakov action == Notes == == References == D'Hoker, Eric & Phong, D. H. (Oct 1988). "The geometry of string perturbation theory". Rev. Mod. Phys. 60 (4). American Physical Society: 917–1065. Bibcode:1988RvMP...60..917D. doi:10.1103/RevModPhys.60.917. Belavin, A.A. & Knizhnik, V.G. (Feb 1986). "Complex geometry and the theory of quantum strings". ZhETF. 91 (2): 364–390. Bibcode:1986ZhETF..91..364B. Archived from the original on 2021-02-26. Retrieved 2015-04-24. == External links == How many string theories are there? PIRSA:C09001 - Introduction to the Bosonic String
Wikipedia/Bosonic_string_theory
In mathematics, an ordinary differential equation (ODE) is a differential equation (DE) dependent on only a single independent variable. As with any other DE, its unknown(s) consists of one (or more) function(s) and involves the derivatives of those functions. The term "ordinary" is used in contrast with partial differential equations (PDEs) which may be with respect to more than one independent variable, and, less commonly, in contrast with stochastic differential equations (SDEs) where the progression is random. == Differential equations == A linear differential equation is a differential equation that is defined by a linear polynomial in the unknown function and its derivatives, that is an equation of the form a 0 ( x ) y + a 1 ( x ) y ′ + a 2 ( x ) y ″ + ⋯ + a n ( x ) y ( n ) + b ( x ) = 0 , {\displaystyle a_{0}(x)y+a_{1}(x)y'+a_{2}(x)y''+\cdots +a_{n}(x)y^{(n)}+b(x)=0,} where a 0 ( x ) , … , a n ( x ) {\displaystyle a_{0}(x),\ldots ,a_{n}(x)} and b ( x ) {\displaystyle b(x)} are arbitrary differentiable functions that do not need to be linear, and y ′ , … , y ( n ) {\displaystyle y',\ldots ,y^{(n)}} are the successive derivatives of the unknown function y {\displaystyle y} of the variable x {\displaystyle x} . Among ordinary differential equations, linear differential equations play a prominent role for several reasons. Most elementary and special functions that are encountered in physics and applied mathematics are solutions of linear differential equations (see Holonomic function). When physical phenomena are modeled with non-linear equations, they are generally approximated by linear differential equations for an easier solution. The few non-linear ODEs that can be solved explicitly are generally solved by transforming the equation into an equivalent linear ODE (see, for example Riccati equation). Some ODEs can be solved explicitly in terms of known functions and integrals. When that is not possible, the equation for computing the Taylor series of the solutions may be useful. For applied problems, numerical methods for ordinary differential equations can supply an approximation of the solution. == Background == Ordinary differential equations (ODEs) arise in many contexts of mathematics and social and natural sciences. Mathematical descriptions of change use differentials and derivatives. Various differentials, derivatives, and functions become related via equations, such that a differential equation is a result that describes dynamically changing phenomena, evolution, and variation. Often, quantities are defined as the rate of change of other quantities (for example, derivatives of displacement with respect to time), or gradients of quantities, which is how they enter differential equations. Specific mathematical fields include geometry and analytical mechanics. Scientific fields include much of physics and astronomy (celestial mechanics), meteorology (weather modeling), chemistry (reaction rates), biology (infectious diseases, genetic variation), ecology and population modeling (population competition), economics (stock trends, interest rates and the market equilibrium price changes). Many mathematicians have studied differential equations and contributed to the field, including Newton, Leibniz, the Bernoulli family, Riccati, Clairaut, d'Alembert, and Euler. A simple example is Newton's second law of motion—the relationship between the displacement x {\displaystyle x} and the time t {\displaystyle t} of an object under the force F {\displaystyle F} , is given by the differential equation m d 2 x ( t ) d t 2 = F ( x ( t ) ) {\displaystyle m{\frac {\mathrm {d} ^{2}x(t)}{\mathrm {d} t^{2}}}=F(x(t))\,} which constrains the motion of a particle of constant mass m {\displaystyle m} . In general, F {\displaystyle F} is a function of the position x ( t ) {\displaystyle x(t)} of the particle at time t {\displaystyle t} . The unknown function x ( t ) {\displaystyle x(t)} appears on both sides of the differential equation, and is indicated in the notation F ( x ( t ) ) {\displaystyle F(x(t))} . == Definitions == In what follows, y {\displaystyle y} is a dependent variable representing an unknown function y = f ( x ) {\displaystyle y=f(x)} of the independent variable x {\displaystyle x} . The notation for differentiation varies depending upon the author and upon which notation is most useful for the task at hand. In this context, the Leibniz's notation d y d x , d 2 y d x 2 , … , d n y d x n {\displaystyle {\frac {dy}{dx}},{\frac {d^{2}y}{dx^{2}}},\ldots ,{\frac {d^{n}y}{dx^{n}}}} is more useful for differentiation and integration, whereas Lagrange's notation y ′ , y ″ , … , y ( n ) {\displaystyle y',y'',\ldots ,y^{(n)}} is more useful for representing higher-order derivatives compactly, and Newton's notation ( y ˙ , y ¨ , y . . . ) {\displaystyle ({\dot {y}},{\ddot {y}},{\overset {...}{y}})} is often used in physics for representing derivatives of low order with respect to time. === General definition === Given F {\displaystyle F} , a function of x {\displaystyle x} , y {\displaystyle y} , and derivatives of y {\displaystyle y} . Then an equation of the form F ( x , y , y ′ , … , y ( n − 1 ) ) = y ( n ) {\displaystyle F\left(x,y,y',\ldots ,y^{(n-1)}\right)=y^{(n)}} is called an explicit ordinary differential equation of order n {\displaystyle n} . More generally, an implicit ordinary differential equation of order n {\displaystyle n} takes the form: F ( x , y , y ′ , y ″ , … , y ( n ) ) = 0 {\displaystyle F\left(x,y,y',y'',\ \ldots ,\ y^{(n)}\right)=0} There are further classifications: AutonomousA differential equation is autonomous if it does not depend on the variable x. Linear A differential equation is linear if F {\displaystyle F} can be written as a linear combination of the derivatives of y {\displaystyle y} ; that is, it can be rewritten as y ( n ) = ∑ i = 0 n − 1 a i ( x ) y ( i ) + r ( x ) {\displaystyle y^{(n)}=\sum _{i=0}^{n-1}a_{i}(x)y^{(i)}+r(x)} where a i ( x ) {\displaystyle a_{i}(x)} and r ( x ) {\displaystyle r(x)} are continuous functions of x {\displaystyle x} . The function r ( x ) {\displaystyle r(x)} is called the source term, leading to further classification. HomogeneousA linear differential equation is homogeneous if r ( x ) = 0 {\displaystyle r(x)=0} . In this case, there is always the "trivial solution" y = 0 {\displaystyle y=0} . Nonhomogeneous (or inhomogeneous)A linear differential equation is nonhomogeneous if r ( x ) ≠ 0 {\displaystyle r(x)\neq 0} . Non-linearA differential equation that is not linear. === System of ODEs === A number of coupled differential equations form a system of equations. If y {\displaystyle \mathbf {y} } is a vector whose elements are functions; y ( x ) = [ y 1 ( x ) , y 2 ( x ) , … , y m ( x ) ] {\displaystyle \mathbf {y} (x)=[y_{1}(x),y_{2}(x),\ldots ,y_{m}(x)]} , and F {\displaystyle \mathbf {F} } is a vector-valued function of y {\displaystyle \mathbf {y} } and its derivatives, then y ( n ) = F ( x , y , y ′ , y ″ , … , y ( n − 1 ) ) {\displaystyle \mathbf {y} ^{(n)}=\mathbf {F} \left(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n-1)}\right)} is an explicit system of ordinary differential equations of order n {\displaystyle n} and dimension m {\displaystyle m} . In column vector form: ( y 1 ( n ) y 2 ( n ) ⋮ y m ( n ) ) = ( f 1 ( x , y , y ′ , y ″ , … , y ( n − 1 ) ) f 2 ( x , y , y ′ , y ″ , … , y ( n − 1 ) ) ⋮ f m ( x , y , y ′ , y ″ , … , y ( n − 1 ) ) ) {\displaystyle {\begin{pmatrix}y_{1}^{(n)}\\y_{2}^{(n)}\\\vdots \\y_{m}^{(n)}\end{pmatrix}}={\begin{pmatrix}f_{1}\left(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n-1)}\right)\\f_{2}\left(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n-1)}\right)\\\vdots \\f_{m}\left(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n-1)}\right)\end{pmatrix}}} These are not necessarily linear. The implicit analogue is: F ( x , y , y ′ , y ″ , … , y ( n ) ) = 0 {\displaystyle \mathbf {F} \left(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n)}\right)={\boldsymbol {0}}} where 0 = ( 0 , 0 , … , 0 ) {\displaystyle {\boldsymbol {0}}=(0,0,\ldots ,0)} is the zero vector. In matrix form ( f 1 ( x , y , y ′ , y ″ , … , y ( n ) ) f 2 ( x , y , y ′ , y ″ , … , y ( n ) ) ⋮ f m ( x , y , y ′ , y ″ , … , y ( n ) ) ) = ( 0 0 ⋮ 0 ) {\displaystyle {\begin{pmatrix}f_{1}(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n)})\\f_{2}(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n)})\\\vdots \\f_{m}(x,\mathbf {y} ,\mathbf {y} ',\mathbf {y} '',\ldots ,\mathbf {y} ^{(n)})\end{pmatrix}}={\begin{pmatrix}0\\0\\\vdots \\0\end{pmatrix}}} For a system of the form F ( x , y , y ′ ) = 0 {\displaystyle \mathbf {F} \left(x,\mathbf {y} ,\mathbf {y} '\right)={\boldsymbol {0}}} , some sources also require that the Jacobian matrix ∂ F ( x , u , v ) ∂ v {\displaystyle {\frac {\partial \mathbf {F} (x,\mathbf {u} ,\mathbf {v} )}{\partial \mathbf {v} }}} be non-singular in order to call this an implicit ODE [system]; an implicit ODE system satisfying this Jacobian non-singularity condition can be transformed into an explicit ODE system. In the same sources, implicit ODE systems with a singular Jacobian are termed differential algebraic equations (DAEs). This distinction is not merely one of terminology; DAEs have fundamentally different characteristics and are generally more involved to solve than (nonsingular) ODE systems. Presumably for additional derivatives, the Hessian matrix and so forth are also assumed non-singular according to this scheme, although note that any ODE of order greater than one can be (and usually is) rewritten as system of ODEs of first order, which makes the Jacobian singularity criterion sufficient for this taxonomy to be comprehensive at all orders. The behavior of a system of ODEs can be visualized through the use of a phase portrait. === Solutions === Given a differential equation F ( x , y , y ′ , … , y ( n ) ) = 0 {\displaystyle F\left(x,y,y',\ldots ,y^{(n)}\right)=0} a function u : I ⊂ R → R {\displaystyle u:I\subset \mathbb {R} \to \mathbb {R} } , where I {\displaystyle I} is an interval, is called a solution or integral curve for F {\displaystyle F} , if u {\displaystyle u} is n {\displaystyle n} -times differentiable on I {\displaystyle I} , and F ( x , u , u ′ , … , u ( n ) ) = 0 x ∈ I . {\displaystyle F(x,u,u',\ \ldots ,\ u^{(n)})=0\quad x\in I.} Given two solutions u : J ⊂ R → R {\displaystyle u:J\subset \mathbb {R} \to \mathbb {R} } and v : I ⊂ R → R {\displaystyle v:I\subset \mathbb {R} \to \mathbb {R} } , u {\displaystyle u} is called an extension of v {\displaystyle v} if I ⊂ J {\displaystyle I\subset J} and u ( x ) = v ( x ) x ∈ I . {\displaystyle u(x)=v(x)\quad x\in I.\,} A solution that has no extension is called a maximal solution. A solution defined on all of R {\displaystyle \mathbb {R} } is called a global solution. A general solution of an n {\displaystyle n} th-order equation is a solution containing n {\displaystyle n} arbitrary independent constants of integration. A particular solution is derived from the general solution by setting the constants to particular values, often chosen to fulfill set 'initial conditions or boundary conditions'. A singular solution is a solution that cannot be obtained by assigning definite values to the arbitrary constants in the general solution. In the context of linear ODE, the terminology particular solution can also refer to any solution of the ODE (not necessarily satisfying the initial conditions), which is then added to the homogeneous solution (a general solution of the homogeneous ODE), which then forms a general solution of the original ODE. This is the terminology used in the guessing method section in this article, and is frequently used when discussing the method of undetermined coefficients and variation of parameters. === Solutions of finite duration === For non-linear autonomous ODEs it is possible under some conditions to develop solutions of finite duration, meaning here that from its own dynamics, the system will reach the value zero at an ending time and stays there in zero forever after. These finite-duration solutions can't be analytical functions on the whole real line, and because they will be non-Lipschitz functions at their ending time, they are not included in the uniqueness theorem of solutions of Lipschitz differential equations. As example, the equation: y ′ = − sgn ( y ) | y | , y ( 0 ) = 1 {\displaystyle y'=-{\text{sgn}}(y){\sqrt {|y|}},\,\,y(0)=1} Admits the finite duration solution: y ( x ) = 1 4 ( 1 − x 2 + | 1 − x 2 | ) 2 {\displaystyle y(x)={\frac {1}{4}}\left(1-{\frac {x}{2}}+\left|1-{\frac {x}{2}}\right|\right)^{2}} == Theories == === Singular solutions === The theory of singular solutions of ordinary and partial differential equations was a subject of research from the time of Leibniz, but only since the middle of the nineteenth century has it received special attention. A valuable but little-known work on the subject is that of Houtain (1854). Darboux (from 1873) was a leader in the theory, and in the geometric interpretation of these solutions he opened a field worked by various writers, notably Casorati and Cayley. To the latter is due (1872) the theory of singular solutions of differential equations of the first order as accepted circa 1900. === Reduction to quadratures === The primitive attempt in dealing with differential equations had in view a reduction to quadratures, that is, expressing the solutions in terms of known function and their integrals. This is possible for linear equations with constant coefficients, it appeared in the 19th century that this is generally impossible in other cases. Hence, analysts began the study (for their own) of functions that are solutions of differential equations, thus opening a new and fertile field. Cauchy was the first to appreciate the importance of this view. Thereafter, the real question was no longer whether a solution is possible by quadratures, but whether a given differential equation suffices for the definition of a function, and, if so, what are the characteristic properties of such functions. === Fuchsian theory === Two memoirs by Fuchs inspired a novel approach, subsequently elaborated by Thomé and Frobenius. Collet was a prominent contributor beginning in 1869. His method for integrating a non-linear system was communicated to Bertrand in 1868. Clebsch (1873) attacked the theory along lines parallel to those in his theory of Abelian integrals. As the latter can be classified according to the properties of the fundamental curve that remains unchanged under a rational transformation, Clebsch proposed to classify the transcendent functions defined by differential equations according to the invariant properties of the corresponding surfaces f = 0 {\displaystyle f=0} under rational one-to-one transformations. === Lie's theory === From 1870, Sophus Lie's work put the theory of differential equations on a better foundation. He showed that the integration theories of the older mathematicians can, using Lie groups, be referred to a common source, and that ordinary differential equations that admit the same infinitesimal transformations present comparable integration difficulties. He also emphasized the subject of transformations of contact. Lie's group theory of differential equations has been certified, namely: (1) that it unifies the many ad hoc methods known for solving differential equations, and (2) that it provides powerful new ways to find solutions. The theory has applications to both ordinary and partial differential equations. A general solution approach uses the symmetry property of differential equations, the continuous infinitesimal transformations of solutions to solutions (Lie theory). Continuous group theory, Lie algebras, and differential geometry are used to understand the structure of linear and non-linear (partial) differential equations for generating integrable equations, to find its Lax pairs, recursion operators, Bäcklund transform, and finally finding exact analytic solutions to DE. Symmetry methods have been applied to differential equations that arise in mathematics, physics, engineering, and other disciplines. === Sturm–Liouville theory === Sturm–Liouville theory is a theory of a special type of second-order linear ordinary differential equation. Their solutions are based on eigenvalues and corresponding eigenfunctions of linear operators defined via second-order homogeneous linear equations. The problems are identified as Sturm–Liouville problems (SLP) and are named after J. C. F. Sturm and J. Liouville, who studied them in the mid-1800s. SLPs have an infinite number of eigenvalues, and the corresponding eigenfunctions form a complete, orthogonal set, which makes orthogonal expansions possible. This is a key idea in applied mathematics, physics, and engineering. SLPs are also useful in the analysis of certain partial differential equations. == Existence and uniqueness of solutions == There are several theorems that establish existence and uniqueness of solutions to initial value problems involving ODEs both locally and globally. The two main theorems are In their basic form both of these theorems only guarantee local results, though the latter can be extended to give a global result, for example, if the conditions of Grönwall's inequality are met. Also, uniqueness theorems like the Lipschitz one above do not apply to DAE systems, which may have multiple solutions stemming from their (non-linear) algebraic part alone. === Local existence and uniqueness theorem simplified === The theorem can be stated simply as follows. For the equation and initial value problem: y ′ = F ( x , y ) , y 0 = y ( x 0 ) {\displaystyle y'=F(x,y)\,,\quad y_{0}=y(x_{0})} if F {\displaystyle F} and ∂ F / ∂ y {\displaystyle \partial F/\partial y} are continuous in a closed rectangle R = [ x 0 − a , x 0 + a ] × [ y 0 − b , y 0 + b ] {\displaystyle R=[x_{0}-a,x_{0}+a]\times [y_{0}-b,y_{0}+b]} in the x − y {\displaystyle x-y} plane, where a {\displaystyle a} and b {\displaystyle b} are real (symbolically: a , b ∈ R {\displaystyle a,b\in \mathbb {R} } ) and x {\displaystyle x} denotes the Cartesian product, square brackets denote closed intervals, then there is an interval I = [ x 0 − h , x 0 + h ] ⊂ [ x 0 − a , x 0 + a ] {\displaystyle I=[x_{0}-h,x_{0}+h]\subset [x_{0}-a,x_{0}+a]} for some h ∈ R {\displaystyle h\in \mathbb {R} } where the solution to the above equation and initial value problem can be found. That is, there is a solution and it is unique. Since there is no restriction on F {\displaystyle F} to be linear, this applies to non-linear equations that take the form F ( x , y ) {\displaystyle F(x,y)} , and it can also be applied to systems of equations. === Global uniqueness and maximum domain of solution === When the hypotheses of the Picard–Lindelöf theorem are satisfied, then local existence and uniqueness can be extended to a global result. More precisely: For each initial condition ( x 0 , y 0 ) {\displaystyle (x_{0},y_{0})} there exists a unique maximum (possibly infinite) open interval I max = ( x − , x + ) , x ± ∈ R ∪ { ± ∞ } , x 0 ∈ I max {\displaystyle I_{\max }=(x_{-},x_{+}),x_{\pm }\in \mathbb {R} \cup \{\pm \infty \},x_{0}\in I_{\max }} such that any solution that satisfies this initial condition is a restriction of the solution that satisfies this initial condition with domain I max {\displaystyle I_{\max }} . In the case that x ± ≠ ± ∞ {\displaystyle x_{\pm }\neq \pm \infty } , there are exactly two possibilities explosion in finite time: lim sup x → x ± ‖ y ( x ) ‖ → ∞ {\displaystyle \limsup _{x\to x_{\pm }}\|y(x)\|\to \infty } leaves domain of definition: lim x → x ± y ( x ) ∈ ∂ Ω ¯ {\displaystyle \lim _{x\to x_{\pm }}y(x)\ \in \partial {\bar {\Omega }}} where Ω {\displaystyle \Omega } is the open set in which F {\displaystyle F} is defined, and ∂ Ω ¯ {\displaystyle \partial {\bar {\Omega }}} is its boundary. Note that the maximum domain of the solution is always an interval (to have uniqueness) may be smaller than R {\displaystyle \mathbb {R} } may depend on the specific choice of ( x 0 , y 0 ) {\displaystyle (x_{0},y_{0})} . Example. y ′ = y 2 {\displaystyle y'=y^{2}} This means that F ( x , y ) = y 2 {\displaystyle F(x,y)=y^{2}} , which is C 1 {\displaystyle C^{1}} and therefore locally Lipschitz continuous, satisfying the Picard–Lindelöf theorem. Even in such a simple setting, the maximum domain of solution cannot be all R {\displaystyle \mathbb {R} } since the solution is y ( x ) = y 0 ( x 0 − x ) y 0 + 1 {\displaystyle y(x)={\frac {y_{0}}{(x_{0}-x)y_{0}+1}}} which has maximum domain: { R y 0 = 0 ( − ∞ , x 0 + 1 y 0 ) y 0 > 0 ( x 0 + 1 y 0 , + ∞ ) y 0 < 0 {\displaystyle {\begin{cases}\mathbb {R} &y_{0}=0\\[4pt]\left(-\infty ,x_{0}+{\frac {1}{y_{0}}}\right)&y_{0}>0\\[4pt]\left(x_{0}+{\frac {1}{y_{0}}},+\infty \right)&y_{0}<0\end{cases}}} This shows clearly that the maximum interval may depend on the initial conditions. The domain of y {\displaystyle y} could be taken as being R ∖ ( x 0 + 1 / y 0 ) , {\displaystyle \mathbb {R} \setminus (x_{0}+1/y_{0}),} but this would lead to a domain that is not an interval, so that the side opposite to the initial condition would be disconnected from the initial condition, and therefore not uniquely determined by it. The maximum domain is not R {\displaystyle \mathbb {R} } because lim x → x ± ‖ y ( x ) ‖ → ∞ , {\displaystyle \lim _{x\to x_{\pm }}\|y(x)\|\to \infty ,} which is one of the two possible cases according to the above theorem. == Reduction of order == Differential equations are usually easier to solve if the order of the equation can be reduced. === Reduction to a first-order system === Any explicit differential equation of order n {\displaystyle n} , F ( x , y , y ′ , y ″ , … , y ( n − 1 ) ) = y ( n ) {\displaystyle F\left(x,y,y',y'',\ \ldots ,\ y^{(n-1)}\right)=y^{(n)}} can be written as a system of n {\displaystyle n} first-order differential equations by defining a new family of unknown functions y i = y ( i − 1 ) . {\displaystyle y_{i}=y^{(i-1)}.\!} for i = 1 , 2 , … , n {\displaystyle i=1,2,\ldots ,n} . The n {\displaystyle n} -dimensional system of first-order coupled differential equations is then y 1 ′ = y 2 y 2 ′ = y 3 ⋮ y n − 1 ′ = y n y n ′ = F ( x , y 1 , … , y n ) . {\displaystyle {\begin{array}{rcl}y_{1}'&=&y_{2}\\y_{2}'&=&y_{3}\\&\vdots &\\y_{n-1}'&=&y_{n}\\y_{n}'&=&F(x,y_{1},\ldots ,y_{n}).\end{array}}} more compactly in vector notation: y ′ = F ( x , y ) {\displaystyle \mathbf {y} '=\mathbf {F} (x,\mathbf {y} )} where y = ( y 1 , … , y n ) , F ( x , y 1 , … , y n ) = ( y 2 , … , y n , F ( x , y 1 , … , y n ) ) . {\displaystyle \mathbf {y} =(y_{1},\ldots ,y_{n}),\quad \mathbf {F} (x,y_{1},\ldots ,y_{n})=(y_{2},\ldots ,y_{n},F(x,y_{1},\ldots ,y_{n})).} == Summary of exact solutions == Some differential equations have solutions that can be written in an exact and closed form. Several important classes are given here. In the table below, P ( x ) {\displaystyle P(x)} , Q ( x ) {\displaystyle Q(x)} , P ( y ) {\displaystyle P(y)} , Q ( y ) {\displaystyle Q(y)} , and M ( x , y ) {\displaystyle M(x,y)} , N ( x , y ) {\displaystyle N(x,y)} are any integrable functions of x {\displaystyle x} , y {\displaystyle y} ; b {\displaystyle b} and c {\displaystyle c} are real given constants; C 1 , C 2 , … {\displaystyle C_{1},C_{2},\ldots } are arbitrary constants (complex in general). The differential equations are in their equivalent and alternative forms that lead to the solution through integration. In the integral solutions, λ {\displaystyle \lambda } and ε {\displaystyle \varepsilon } are dummy variables of integration (the continuum analogues of indices in summation), and the notation ∫ x F ( λ ) d λ {\displaystyle \int ^{x}F(\lambda )\,d\lambda } just means to integrate F ( λ ) {\displaystyle F(\lambda )} with respect to λ {\displaystyle \lambda } , then after the integration substitute λ = x {\displaystyle \lambda =x} , without adding constants (explicitly stated). === Separable equations === === General first-order equations === === General second-order equations === === Linear to the nth order equations === == The guessing method == When all other methods for solving an ODE fail, or in the cases where we have some intuition about what the solution to a DE might look like, it is sometimes possible to solve a DE simply by guessing the solution and validating it is correct. To use this method, we simply guess a solution to the differential equation, and then plug the solution into the differential equation to validate if it satisfies the equation. If it does then we have a particular solution to the DE, otherwise we start over again and try another guess. For instance we could guess that the solution to a DE has the form: y = A e α t {\displaystyle y=Ae^{\alpha t}} since this is a very common solution that physically behaves in a sinusoidal way. In the case of a first order ODE that is non-homogeneous we need to first find a solution to the homogeneous portion of the DE, otherwise known as the associated homogeneous equation, and then find a solution to the entire non-homogeneous equation by guessing. Finally, we add both of these solutions together to obtain the general solution to the ODE, that is: general solution = general solution of the associated homogeneous equation + particular solution {\displaystyle {\text{general solution}}={\text{general solution of the associated homogeneous equation}}+{\text{particular solution}}} == Software for ODE solving == Maxima, an open-source computer algebra system. COPASI, a free (Artistic License 2.0) software package for the integration and analysis of ODEs. MATLAB, a technical computing application (MATrix LABoratory) GNU Octave, a high-level language, primarily intended for numerical computations. Scilab, an open source application for numerical computation. Maple, a proprietary application for symbolic calculations. Mathematica, a proprietary application primarily intended for symbolic calculations. SymPy, a Python package that can solve ODEs symbolically Julia (programming language), a high-level language primarily intended for numerical computations. SageMath, an open-source application that uses a Python-like syntax with a wide range of capabilities spanning several branches of mathematics. SciPy, a Python package that includes an ODE integration module. Chebfun, an open-source package, written in MATLAB, for computing with functions to 15-digit accuracy. GNU R, an open source computational environment primarily intended for statistics, which includes packages for ODE solving. == See also == Boundary value problem Examples of differential equations Laplace transform applied to differential equations List of dynamical systems and differential equations topics Matrix differential equation Method of undetermined coefficients Recurrence relation == Notes == == References == Halliday, David; Resnick, Robert (1977), Physics (3rd ed.), New York: Wiley, ISBN 0-471-71716-9 Harper, Charlie (1976), Introduction to Mathematical Physics, New Jersey: Prentice-Hall, ISBN 0-13-487538-9 Kreyszig, Erwin (1972), Advanced Engineering Mathematics (3rd ed.), New York: Wiley, ISBN 0-471-50728-8. Polyanin, A. D. and V. F. Zaitsev, Handbook of Exact Solutions for Ordinary Differential Equations (2nd edition), Chapman & Hall/CRC Press, Boca Raton, 2003. ISBN 1-58488-297-2 Simmons, George F. (1972), Differential Equations with Applications and Historical Notes, New York: McGraw-Hill, LCCN 75173716 Tipler, Paul A. (1991), Physics for Scientists and Engineers: Extended version (3rd ed.), New York: Worth Publishers, ISBN 0-87901-432-6 Boscain, Ugo; Chitour, Yacine (2011), Introduction à l'automatique (PDF) (in French) Dresner, Lawrence (1999), Applications of Lie's Theory of Ordinary and Partial Differential Equations, Bristol and Philadelphia: Institute of Physics Publishing, ISBN 978-0750305303 Ascher, Uri; Petzold, Linda (1998), Computer Methods for Ordinary Differential Equations and Differential-Algebraic Equations, SIAM, ISBN 978-1-61197-139-2 == Bibliography == Coddington, Earl A.; Levinson, Norman (1955). Theory of Ordinary Differential Equations. New York: McGraw-Hill. Hartman, Philip (2002) [1964], Ordinary differential equations, Classics in Applied Mathematics, vol. 38, Philadelphia: Society for Industrial and Applied Mathematics, doi:10.1137/1.9780898719222, ISBN 978-0-89871-510-1, MR 1929104 W. Johnson, A Treatise on Ordinary and Partial Differential Equations, John Wiley and Sons, 1913, in University of Michigan Historical Math Collection Ince, Edward L. (1944) [1926], Ordinary Differential Equations, Dover Publications, New York, ISBN 978-0-486-60349-0, MR 0010757 {{citation}}: ISBN / Date incompatibility (help) Witold Hurewicz, Lectures on Ordinary Differential Equations, Dover Publications, ISBN 0-486-49510-8 Ibragimov, Nail H. (1993). CRC Handbook of Lie Group Analysis of Differential Equations Vol. 1-3. Providence: CRC-Press. ISBN 0-8493-4488-3.. Teschl, Gerald (2012). Ordinary Differential Equations and Dynamical Systems. Providence: American Mathematical Society. ISBN 978-0-8218-8328-0. A. D. Polyanin, V. F. Zaitsev, and A. Moussiaux, Handbook of First Order Partial Differential Equations, Taylor & Francis, London, 2002. ISBN 0-415-27267-X D. Zwillinger, Handbook of Differential Equations (3rd edition), Academic Press, Boston, 1997. == External links == "Differential equation, ordinary", Encyclopedia of Mathematics, EMS Press, 2001 [1994] EqWorld: The World of Mathematical Equations, containing a list of ordinary differential equations with their solutions. Online Notes / Differential Equations by Paul Dawkins, Lamar University. Differential Equations, S.O.S. Mathematics. A primer on analytical solution of differential equations from the Holistic Numerical Methods Institute, University of South Florida. Ordinary Differential Equations and Dynamical Systems lecture notes by Gerald Teschl. Notes on Diffy Qs: Differential Equations for Engineers An introductory textbook on differential equations by Jiri Lebl of UIUC. Modeling with ODEs using Scilab A tutorial on how to model a physical system described by ODE using Scilab standard programming language by Openeering team. Solving an ordinary differential equation in Wolfram|Alpha
Wikipedia/Ordinary_differential_equation
In mathematics and mathematical physics, potential theory is the study of harmonic functions. The term "potential theory" was coined in 19th-century physics when it was realized that the two fundamental forces of nature known at the time, namely gravity and the electrostatic force, could be modeled using functions called the gravitational potential and electrostatic potential, both of which satisfy Poisson's equation—or in the vacuum, Laplace's equation. There is considerable overlap between potential theory and the theory of Poisson's equation to the extent that it is impossible to draw a distinction between these two fields. The difference is more one of emphasis than subject matter and rests on the following distinction: potential theory focuses on the properties of the functions as opposed to the properties of the equation. For example, a result about the singularities of harmonic functions would be said to belong to potential theory whilst a result on how the solution depends on the boundary data would be said to belong to the theory of Poisson's equation. This is not a hard and fast distinction, and in practice there is considerable overlap between the two fields, with methods and results from one being used in the other. Modern potential theory is also intimately connected with probability and the theory of Markov chains. In the continuous case, this is closely related to analytic theory. In the finite state space case, this connection can be introduced by introducing an electrical network on the state space, with resistance between points inversely proportional to transition probabilities and densities proportional to potentials. Even in the finite case, the analogue I-K of the Laplacian in potential theory has its own maximum principle, uniqueness principle, balance principle, and others. == Symmetry == A useful starting point and organizing principle in the study of harmonic functions is a consideration of the symmetries of the Laplace equation. Although it is not a symmetry in the usual sense of the term, we can start with the observation that the Laplace equation is linear. This means that the fundamental object of study in potential theory is a linear space of functions. This observation will prove especially important when we consider function space approaches to the subject in a later section. As for symmetry in the usual sense of the term, we may start with the theorem that the symmetries of the n {\displaystyle n} -dimensional Laplace equation are exactly the conformal symmetries of the n {\displaystyle n} -dimensional Euclidean space. This fact has several implications. First of all, one can consider harmonic functions which transform under irreducible representations of the conformal group or of its subgroups (such as the group of rotations or translations). Proceeding in this fashion, one systematically obtains the solutions of the Laplace equation which arise from separation of variables such as spherical harmonic solutions and Fourier series. By taking linear superpositions of these solutions, one can produce large classes of harmonic functions which can be shown to be dense in the space of all harmonic functions under suitable topologies. Second, one can use conformal symmetry to understand such classical tricks and techniques for generating harmonic functions as the Kelvin transform and the method of images. Third, one can use conformal transforms to map harmonic functions in one domain to harmonic functions in another domain. The most common instance of such a construction is to relate harmonic functions on a disk to harmonic functions on a half-plane. Fourth, one can use conformal symmetry to extend harmonic functions to harmonic functions on conformally flat Riemannian manifolds. Perhaps the simplest such extension is to consider a harmonic function defined on the whole of Rn (with the possible exception of a discrete set of singular points) as a harmonic function on the n {\displaystyle n} -dimensional sphere. More complicated situations can also happen. For instance, one can obtain a higher-dimensional analog of Riemann surface theory by expressing a multi-valued harmonic function as a single-valued function on a branched cover of Rn or one can regard harmonic functions which are invariant under a discrete subgroup of the conformal group as functions on a multiply connected manifold or orbifold. == Two dimensions == From the fact that the group of conformal transforms is infinite-dimensional in two dimensions and finite-dimensional for more than two dimensions, one can surmise that potential theory in two dimensions is different from potential theory in other dimensions. This is correct and, in fact, when one realizes that any two-dimensional harmonic function is the real part of a complex analytic function, one sees that the subject of two-dimensional potential theory is substantially the same as that of complex analysis. For this reason, when speaking of potential theory, one focuses attention on theorems which hold in three or more dimensions. In this connection, a surprising fact is that many results and concepts originally discovered in complex analysis (such as Schwarz's theorem, Morera's theorem, the Weierstrass-Casorati theorem, Laurent series, and the classification of singularities as removable, poles and essential singularities) generalize to results on harmonic functions in any dimension. By considering which theorems of complex analysis are special cases of theorems of potential theory in any dimension, one can obtain a feel for exactly what is special about complex analysis in two dimensions and what is simply the two-dimensional instance of more general results. == Local behavior == An important topic in potential theory is the study of the local behavior of harmonic functions. Perhaps the most fundamental theorem about local behavior is the regularity theorem for Laplace's equation, which states that harmonic functions are analytic. There are results which describe the local structure of level sets of harmonic functions. There is Bôcher's theorem, which characterizes the behavior of isolated singularities of positive harmonic functions. As alluded to in the last section, one can classify the isolated singularities of harmonic functions as removable singularities, poles, and essential singularities. == Inequalities == A fruitful approach to the study of harmonic functions is the consideration of inequalities they satisfy. Perhaps the most basic such inequality, from which most other inequalities may be derived, is the maximum principle. Another important result is Liouville's theorem, which states the only bounded harmonic functions defined on the whole of Rn are, in fact, constant functions. In addition to these basic inequalities, one has Harnack's inequality, which states that positive harmonic functions on bounded domains are roughly constant. One important use of these inequalities is to prove convergence of families of harmonic functions or sub-harmonic functions, see Harnack's theorem. These convergence theorems are used to prove the existence of harmonic functions with particular properties. == Spaces of harmonic functions == Since the Laplace equation is linear, the set of harmonic functions defined on a given domain is, in fact, a vector space. By defining suitable norms and/or inner products, one can exhibit sets of harmonic functions which form Hilbert or Banach spaces. In this fashion, one obtains such spaces as the Hardy space, Bloch space, Bergman space and Sobolev space. == See also == Subharmonic function – Class of mathematical functions Kellogg's theorem == References == A.I. Prilenko, E.D. Solomentsev (2001) [1994], "Potential theory", Encyclopedia of Mathematics, EMS Press E.D. Solomentsev (2001) [1994], "Abstract potential theory", Encyclopedia of Mathematics, EMS Press S. Axler, P. Bourdon, W. Ramey (2001). Harmonic Function Theory (2nd edition). Springer-Verlag. ISBN 0-387-95218-7. O. D. Kellogg (1969). Foundations of Potential Theory. Dover Publications. ISBN 0-486-60144-7. L. L. Helms (1975). Introduction to potential theory. R. E. Krieger ISBN 0-88275-224-3. J. L. Doob. Classical Potential Theory and Its Probabilistic Counterpart, Springer-Verlag, Berlin Heidelberg New York, ISBN 3-540-41206-9. James Laurie Snell; Peter G. Doyle (2000). "Random Walks and Electric Networks". arXiv:math/0001057. This article incorporates material from potentialtheory on PlanetMath, which is licensed under the Creative Commons Attribution/Share-Alike License.
Wikipedia/Potential_theory
In mathematics, and especially differential geometry and mathematical physics, gauge theory is the general study of connections on vector bundles, principal bundles, and fibre bundles. Gauge theory in mathematics should not be confused with the closely related concept of a gauge theory in physics, which is a field theory that admits gauge symmetry. In mathematics theory means a mathematical theory, encapsulating the general study of a collection of concepts or phenomena, whereas in the physical sense a gauge theory is a mathematical model of some natural phenomenon. Gauge theory in mathematics is typically concerned with the study of gauge-theoretic equations. These are differential equations involving connections on vector bundles or principal bundles, or involving sections of vector bundles, and so there are strong links between gauge theory and geometric analysis. These equations are often physically meaningful, corresponding to important concepts in quantum field theory or string theory, but also have important mathematical significance. For example, the Yang–Mills equations are a system of partial differential equations for a connection on a principal bundle, and in physics solutions to these equations correspond to vacuum solutions to the equations of motion for a classical field theory, particles known as instantons. Gauge theory has found uses in constructing new invariants of smooth manifolds, the construction of exotic geometric structures such as hyperkähler manifolds, as well as giving alternative descriptions of important structures in algebraic geometry such as moduli spaces of vector bundles and coherent sheaves. == History == Gauge theory has its origins as far back as the formulation of Maxwell's equations describing classical electromagnetism, which may be phrased as a gauge theory with structure group the circle group. Work of Paul Dirac on magnetic monopoles and relativistic quantum mechanics encouraged the idea that bundles and connections were the correct way of phrasing many problems in quantum mechanics. Gauge theory in mathematical physics arose as a significant field of study with the seminal work of Robert Mills and Chen-Ning Yang on so-called Yang–Mills gauge theory, which is now the fundamental model that underpins the standard model of particle physics. The mathematical investigation of gauge theory has its origins in the work of Michael Atiyah, Isadore Singer, and Nigel Hitchin on the self-duality equations on a Riemannian manifold in four dimensions. In this work the moduli space of self-dual connections (instantons) on Euclidean space was studied, and shown to be of dimension 8 k − 3 {\displaystyle 8k-3} where k {\displaystyle k} is a positive integer parameter. This linked up with the discovery by physicists of BPST instantons, vacuum solutions to the Yang–Mills equations in four dimensions with k = 1 {\displaystyle k=1} . Such instantons are defined by a choice of 5 parameters, the center z ∈ R 4 {\displaystyle z\in \mathbb {R} ^{4}} and scale ρ ∈ R > 0 {\displaystyle \rho \in \mathbb {R} _{>0}} , corresponding to the 8 − 3 = 5 {\displaystyle 8-3=5} -dimensional moduli space. A BPST instanton is depicted to the right. Around the same time Atiyah and Richard Ward discovered links between solutions to the self-duality equations and algebraic bundles over the complex projective space C P 3 {\displaystyle \mathbb {CP} ^{3}} . Another significant early discovery was the development of the ADHM construction by Atiyah, Vladimir Drinfeld, Hitchin, and Yuri Manin. This construction allowed for the solution to the anti-self-duality equations on Euclidean space R 4 {\displaystyle \mathbb {R} ^{4}} from purely linear algebraic data. Significant breakthroughs encouraging the development of mathematical gauge theory occurred in the early 1980s. At this time the important work of Atiyah and Raoul Bott about the Yang–Mills equations over Riemann surfaces showed that gauge theoretic problems could give rise to interesting geometric structures, spurring the development of infinite-dimensional moment maps, equivariant Morse theory, and relations between gauge theory and algebraic geometry. Important analytical tools in geometric analysis were developed at this time by Karen Uhlenbeck, who studied the analytical properties of connections and curvature proving important compactness results. The most significant advancements in the field occurred due to the work of Simon Donaldson and Edward Witten. Donaldson used a combination of algebraic geometry and geometric analysis techniques to construct new invariants of four manifolds, now known as Donaldson invariants. With these invariants, novel results such as the existence of topological manifolds admitting no smooth structures, or the existence of many distinct smooth structures on the Euclidean space R 4 {\displaystyle \mathbb {R} ^{4}} could be proved. For this work Donaldson was awarded the Fields Medal in 1986. Witten similarly observed the power of gauge theory to describe topological invariants, by relating quantities arising from Chern–Simons theory in three dimensions to the Jones polynomial, an invariant of knots. This work and the discovery of Donaldson invariants, as well as novel work of Andreas Floer on Floer homology, inspired the study of topological quantum field theory. After the discovery of the power of gauge theory to define invariants of manifolds, the field of mathematical gauge theory expanded in popularity. Further invariants were discovered, such as Seiberg–Witten invariants and Vafa–Witten invariants. Strong links to algebraic geometry were realised by the work of Donaldson, Uhlenbeck, and Shing-Tung Yau on the Kobayashi–Hitchin correspondence relating Yang–Mills connections to stable vector bundles. Work of Nigel Hitchin and Carlos Simpson on Higgs bundles demonstrated that moduli spaces arising out of gauge theory could have exotic geometric structures such as that of hyperkähler manifolds, as well as links to integrable systems through the Hitchin system. Links to string theory and Mirror symmetry were realised, where gauge theory is essential to phrasing the homological mirror symmetry conjecture and the AdS/CFT correspondence. == Fundamental objects of interest == The fundamental objects of interest in gauge theory are connections on vector bundles and principal bundles. In this section we briefly recall these constructions, and refer to the main articles on them for details. The structures described here are standard within the differential geometry literature, and an introduction to the topic from a gauge-theoretic perspective can be found in the book of Donaldson and Peter Kronheimer. === Principal bundles === The central objects of study in gauge theory are principal bundles and vector bundles. The choice of which to study is essentially arbitrary, as one may pass between them, but principal bundles are the natural objects from the physical perspective to describe gauge fields, and mathematically they more elegantly encode the corresponding theory of connections and curvature for vector bundles associated to them. A principal bundle with structure group G {\displaystyle G} , or a principal G {\displaystyle G} -bundle, consists of a quintuple ( P , X , π , G , ρ ) {\displaystyle (P,X,\pi ,G,\rho )} where π : P → X {\displaystyle \pi :P\to X} is a smooth fibre bundle with fibre space isomorphic to a Lie group G {\displaystyle G} , and ρ {\displaystyle \rho } represents a free and transitive right group action of G {\displaystyle G} on P {\displaystyle P} which preserves the fibres, in the sense that for all p ∈ P {\displaystyle p\in P} , π ( p g ) = π ( p ) {\displaystyle \pi (pg)=\pi (p)} for all g ∈ G {\displaystyle g\in G} . Here P {\displaystyle P} is the total space, and X {\displaystyle X} the base space. Using the right group action for each x ∈ X {\displaystyle x\in X} and any choice of p ∈ P x {\textstyle p\in P_{x}} , the map g ↦ p g {\displaystyle g\mapsto pg} defines a diffeomorphism P x ≅ G {\displaystyle P_{x}\cong G} between the fibre over x {\displaystyle x} and the Lie group G {\displaystyle G} as smooth manifolds. Note however there is no natural way of equipping the fibres of P {\displaystyle P} with the structure of Lie groups, as there is no natural choice of element p ∈ P x {\displaystyle p\in P_{x}} for every x ∈ X {\displaystyle x\in X} . The simplest examples of principal bundles are given when G = U ⁡ ( 1 ) {\displaystyle G=\operatorname {U} (1)} is the circle group. In this case the principal bundle has dimension dim ⁡ P = n + 1 {\displaystyle \dim P=n+1} where dim ⁡ X = n {\displaystyle \dim X=n} . Another natural example occurs when P = F ( T X ) {\displaystyle P={\mathcal {F}}(TX)} is the frame bundle of the tangent bundle of the manifold X {\displaystyle X} , or more generally the frame bundle of a vector bundle over X {\displaystyle X} . In this case the fibre of P {\displaystyle P} is given by the general linear group GL ⁡ ( n , R ) {\displaystyle \operatorname {GL} (n,\mathbb {R} )} . Since a principal bundle is a fibre bundle, it locally has the structure of a product. That is, there exists an open covering { U α } {\displaystyle \{U_{\alpha }\}} of X {\displaystyle X} and diffeomorphisms φ α : P U α → U α × G {\displaystyle \varphi _{\alpha }:P_{U_{\alpha }}\to U_{\alpha }\times G} commuting with the projections π {\displaystyle \pi } and pr 1 {\displaystyle \operatorname {pr} _{1}} , such that the transition functions g α β : U α ∩ U β → G {\displaystyle g_{\alpha \beta }:U_{\alpha }\cap U_{\beta }\to G} defined by φ α ∘ φ β − 1 ( x , g ) = ( x , g α β ( x ) g ) {\displaystyle \varphi _{\alpha }\circ \varphi _{\beta }^{-1}(x,g)=(x,g_{\alpha \beta }(x)g)} satisfy the cocycle condition g α β ( x ) g β γ ( x ) = g α γ ( x ) {\displaystyle g_{\alpha \beta }(x)g_{\beta \gamma }(x)=g_{\alpha \gamma }(x)} on any triple overlap U α ∩ U β ∩ U γ {\displaystyle U_{\alpha }\cap U_{\beta }\cap U_{\gamma }} . In order to define a principal bundle it is enough to specify such a choice of transition functions, The bundle is then defined by gluing trivial bundles U α × G {\displaystyle U_{\alpha }\times G} along the intersections U α ∩ U β {\displaystyle U_{\alpha }\cap U_{\beta }} using the transition functions. The cocycle condition ensures precisely that this defines an equivalence relation on the disjoint union ⨆ α U α × G {\displaystyle \bigsqcup _{\alpha }U_{\alpha }\times G} and therefore that the quotient space P = ⨆ α U α × G / ∼ {\displaystyle P=\bigsqcup _{\alpha }U_{\alpha }\times G/{\sim }} is well-defined. This is known as the fibre bundle construction theorem and the same process works for any fibre bundle described by transition functions, not just principal bundles or vector bundles. Notice that a choice of local section s α : U α → P U α {\displaystyle s_{\alpha }:U_{\alpha }\to P_{U_{\alpha }}} satisfying π ∘ s α = Id {\displaystyle \pi \circ s_{\alpha }=\operatorname {Id} } is an equivalent method of specifying a local trivialisation map. Namely, one can define φ α ( p ) = ( π ( p ) , s ~ α ( p ) ) {\displaystyle \varphi _{\alpha }(p)=(\pi (p),{\tilde {s}}_{\alpha }(p))} where s ~ α ( p ) ∈ G {\displaystyle {\tilde {s}}_{\alpha }(p)\in G} is the unique group element such that p s ~ α ( p ) − 1 = s α ( π ( p ) ) {\displaystyle p{\tilde {s}}_{\alpha }(p)^{-1}=s_{\alpha }(\pi (p))} . === Vector bundles === A vector bundle is a triple ( E , X , π ) {\displaystyle (E,X,\pi )} where π : E → X {\displaystyle \pi :E\to X} is a fibre bundle with fibre given by a vector space K r {\displaystyle \mathbb {K} ^{r}} where K = R , C {\displaystyle \mathbb {K} =\mathbb {R} ,\mathbb {C} } is a field. The number r {\displaystyle r} is the rank of the vector bundle. Again one has a local description of a vector bundle in terms of a trivialising open cover. If { U α } {\displaystyle \{U_{\alpha }\}} is such a cover, then under the isomorphism φ α : E U α → U α × K r {\displaystyle \varphi _{\alpha }:E_{U_{\alpha }}\to U_{\alpha }\times \mathbb {K} ^{r}} one obtains r {\displaystyle r} distinguished local sections of E {\displaystyle E} corresponding to the r {\displaystyle r} coordinate basis vectors e 1 , … , e r {\displaystyle e_{1},\dots ,e_{r}} of K r {\displaystyle \mathbb {K} ^{r}} , denoted e 1 , … , e r {\displaystyle {\boldsymbol {e}}_{1},\dots ,{\boldsymbol {e}}_{r}} . These are defined by the equation φ α ( e i ( x ) ) = ( x , e i ) . {\displaystyle \varphi _{\alpha }({\boldsymbol {e}}_{i}(x))=(x,e_{i}).} To specify a trivialisation it is therefore equivalent to give a collection of r {\displaystyle r} local sections which are everywhere linearly independent, and use this expression to define the corresponding isomorphism. Such a collection of local sections is called a frame. Similarly to principal bundles, one obtains transition functions g α β : U α ∩ U β → GL ⁡ ( r , K ) {\displaystyle g_{\alpha \beta }:U_{\alpha }\cap U_{\beta }\to \operatorname {GL} (r,\mathbb {K} )} for a vector bundle, defined by φ α ∘ φ β − 1 ( x , v ) = ( x , g α β ( x ) v ) . {\displaystyle \varphi _{\alpha }\circ \varphi _{\beta }^{-1}(x,v)=(x,g_{\alpha \beta }(x)v).} If one takes these transition functions and uses them to construct the local trivialisation for a principal bundle with fibre equal to the structure group GL ⁡ ( r , K ) {\displaystyle \operatorname {GL} (r,\mathbb {K} )} , one obtains exactly the frame bundle of E {\displaystyle E} , a principal GL ⁡ ( r , K ) {\displaystyle \operatorname {GL} (r,\mathbb {K} )} -bundle. === Associated bundles === Given a principal G {\displaystyle G} -bundle P {\displaystyle P} and a representation ρ {\displaystyle \rho } of G {\displaystyle G} on a vector space V {\displaystyle V} , one can construct an associated vector bundle E = P × ρ V {\displaystyle E=P\times _{\rho }V} with fibre the vector space V {\displaystyle V} . To define this vector bundle, one considers the right action on the product P × V {\displaystyle P\times V} defined by ( p , v ) g = ( p g , ρ ( g − 1 ) v ) {\displaystyle (p,v)g=(pg,\rho (g^{-1})v)} and defines P × ρ V = ( P × V ) / G {\displaystyle P\times _{\rho }V=(P\times V)/G} as the quotient space with respect to this action. In terms of transition functions the associated bundle can be understood more simply. If the principal bundle P {\displaystyle P} has transition functions g α β {\displaystyle g_{\alpha \beta }} with respect to a local trivialisation { U α } {\displaystyle \{U_{\alpha }\}} , then one constructs the associated vector bundle using the transition functions ρ ∘ g α β : U α ∩ U β → GL ⁡ ( V ) {\displaystyle \rho \circ g_{\alpha \beta }:U_{\alpha }\cap U_{\beta }\to \operatorname {GL} (V)} . The associated bundle construction can be performed for any fibre space F {\displaystyle F} , not just a vector space, provided ρ : G → Aut ⁡ ( F ) {\displaystyle \rho :G\to \operatorname {Aut} (F)} is a group homomorphism. One key example is the capital A adjoint bundle Ad ⁡ ( P ) {\displaystyle \operatorname {Ad} (P)} with fibre G {\displaystyle G} , constructed using the group homomorphism ρ : G → Aut ⁡ ( G ) {\displaystyle \rho :G\to \operatorname {Aut} (G)} defined by conjugation g ↦ ( h ↦ g h g − 1 ) {\displaystyle g\mapsto (h\mapsto ghg^{-1})} . Note that despite having fibre G {\displaystyle G} , the Adjoint bundle is neither a principal bundle, nor isomorphic as a fibre bundle to P {\displaystyle P} itself. For example, if G {\displaystyle G} is Abelian, then the conjugation action is trivial and Ad ⁡ ( P ) {\displaystyle \operatorname {Ad} (P)} will be the trivial G {\displaystyle G} -fibre bundle over X {\displaystyle X} regardless of whether or not P {\displaystyle P} is trivial as a fibre bundle. Another key example is the lowercase a adjoint bundle ad ⁡ ( P ) {\displaystyle \operatorname {ad} (P)} constructed using the adjoint representation ρ : G → Aut ⁡ ( g ) {\displaystyle \rho :G\to \operatorname {Aut} ({\mathfrak {g}})} where g {\displaystyle {\mathfrak {g}}} is the Lie algebra of G {\displaystyle G} . === Gauge transformations === A gauge transformation of a vector bundle or principal bundle is an automorphism of this object. For a principal bundle, a gauge transformation consists of a diffeomorphism φ : P → P {\displaystyle \varphi :P\to P} commuting with the projection operator π {\displaystyle \pi } and the right action ρ {\displaystyle \rho } . For a vector bundle a gauge transformation is similarly defined by a diffeomorphism φ : E → E {\displaystyle \varphi :E\to E} commuting with the projection operator π {\displaystyle \pi } which is a linear isomorphism of vector spaces on each fibre. The gauge transformations (of P {\displaystyle P} or E {\displaystyle E} ) form a group under composition, called the gauge group, typically denoted G {\displaystyle {\mathcal {G}}} . This group can be characterised as the space of global sections G = Γ ( Ad ⁡ ( P ) ) {\displaystyle {\mathcal {G}}=\Gamma (\operatorname {Ad} (P))} of the adjoint bundle, or G = Γ ( Ad ⁡ ( F ( E ) ) ) {\displaystyle {\mathcal {G}}=\Gamma (\operatorname {Ad} ({\mathcal {F}}(E)))} in the case of a vector bundle, where F ( E ) {\displaystyle {\mathcal {F}}(E)} denotes the frame bundle. One can also define a local gauge transformation as a local bundle isomorphism over a trivialising open subset U α {\displaystyle U_{\alpha }} . This can be uniquely specified as a map g α : U α → G {\displaystyle g_{\alpha }:U_{\alpha }\to G} (taking G = GL ⁡ ( r , K ) {\displaystyle G=\operatorname {GL} (r,\mathbb {K} )} in the case of vector bundles), where the induced bundle isomorphism is defined by φ α ( p ) = p g α ( π ( p ) ) {\displaystyle \varphi _{\alpha }(p)=pg_{\alpha }(\pi (p))} and similarly for vector bundles. Notice that given two local trivialisations of a principal bundle over the same open subset U α {\displaystyle U_{\alpha }} , the transition function is precisely a local gauge transformation g α α : U α → G {\displaystyle g_{\alpha \alpha }:U_{\alpha }\to G} . That is, local gauge transformations are changes of local trivialisation for principal bundles or vector bundles. === Connections on principal bundles === A connection on a principal bundle is a method of connecting nearby fibres so as to capture the notion of a section s : X → P {\displaystyle s:X\to P} being constant or horizontal. Since the fibres of an abstract principal bundle are not naturally identified with each other, or indeed with the fibre space G {\displaystyle G} itself, there is no canonical way of specifying which sections are constant. A choice of local trivialisation leads to one possible choice, where if P {\displaystyle P} is trivial over a set U α {\displaystyle U_{\alpha }} , then a local section could be said to be horizontal if it is constant with respect to this trivialisation, in the sense that φ α ( s ( x ) ) = ( x , g ) {\displaystyle \varphi _{\alpha }(s(x))=(x,g)} for all x ∈ U α {\displaystyle x\in U_{\alpha }} and one g ∈ G {\displaystyle g\in G} . In particular a trivial principal bundle P = X × G {\displaystyle P=X\times G} comes equipped with a trivial connection. In general a connection is given by a choice of horizontal subspaces H p ⊂ T p P {\displaystyle H_{p}\subset T_{p}P} of the tangent spaces at every point p ∈ P {\displaystyle p\in P} , such that at every point one has T p P = H p ⊕ V p {\displaystyle T_{p}P=H_{p}\oplus V_{p}} where V {\displaystyle V} is the vertical bundle defined by V = ker ⁡ d π {\displaystyle V=\ker d\pi } . These horizontal subspaces must be compatible with the principal bundle structure by requiring that the horizontal distribution H {\displaystyle H} is invariant under the right group action: H p g = d ( R g ) ( H p ) {\displaystyle H_{pg}=d(R_{g})(H_{p})} where R g : P → P {\displaystyle R_{g}:P\to P} denotes right multiplication by g {\displaystyle g} . A section s {\displaystyle s} is said to be horizontal if T p s ⊂ H p {\displaystyle T_{p}s\subset H_{p}} where s {\displaystyle s} is identified with its image inside P {\displaystyle P} , which is a submanifold of P {\displaystyle P} with tangent bundle T s {\displaystyle Ts} . Given a vector field v ∈ Γ ( T X ) {\displaystyle v\in \Gamma (TX)} , there is a unique horizontal lift v # ∈ Γ ( H ) {\displaystyle v^{\#}\in \Gamma (H)} . The curvature of the connection H {\displaystyle H} is given by the two-form with values in the adjoint bundle F ∈ Ω 2 ( X , ad ⁡ ( P ) ) {\displaystyle F\in \Omega ^{2}(X,\operatorname {ad} (P))} defined by F ( v 1 , v 2 ) = [ v 1 # , v 2 # ] − [ v 1 , v 2 ] # {\displaystyle F(v_{1},v_{2})=[v_{1}^{\#},v_{2}^{\#}]-[v_{1},v_{2}]^{\#}} where [ ⋅ , ⋅ ] {\displaystyle [\cdot ,\cdot ]} is the Lie bracket of vector fields. Since the vertical bundle consists of the tangent spaces to the fibres of P {\displaystyle P} and these fibres are isomorphic to the Lie group G {\displaystyle G} whose tangent bundle is canonically identified with T G = G × g {\displaystyle TG=G\times {\mathfrak {g}}} , there is a unique Lie algebra-valued two-form F ∈ Ω 2 ( P , g ) {\displaystyle F\in \Omega ^{2}(P,{\mathfrak {g}})} corresponding to the curvature. From the perspective of the Frobenius integrability theorem, the curvature measures precisely the extent to which the horizontal distribution fails to be integrable, and therefore the extent to which H {\displaystyle H} fails to embed inside P {\displaystyle P} as a horizontal submanifold locally. The choice of horizontal subspaces may be equivalently expressed by a projection operator ν : T P → V {\displaystyle \nu :TP\to V} which is equivariant in the correct sense, called the connection one-form. For a horizontal distribution H {\displaystyle H} , this is defined by ν H ( h + v ) = v {\displaystyle \nu _{H}(h+v)=v} where h + v {\displaystyle h+v} denotes the decomposition of a tangent vector with respect to the direct sum decomposition T P = H ⊕ V {\displaystyle TP=H\oplus V} . Due to the equivariance, this projection one-form may be taken to be Lie algebra-valued, giving some ν ∈ Ω 1 ( P , g ) {\displaystyle \nu \in \Omega ^{1}(P,{\mathfrak {g}})} . A local trivialisation for P {\displaystyle P} is equivalently given by a local section s α : U α → P U α {\displaystyle s_{\alpha }:U_{\alpha }\to P_{U_{\alpha }}} and the connection one-form and curvature can be pulled back along this smooth map. This gives the local connection one-form A α = s α ∗ ν ∈ Ω 1 ( U α , ad ⁡ ( P ) ) {\displaystyle A_{\alpha }=s_{\alpha }^{*}\nu \in \Omega ^{1}(U_{\alpha },\operatorname {ad} (P))} which takes values in the adjoint bundle of P {\displaystyle P} . Cartan's structure equation says that the curvature may be expressed in terms of the local one-form A α {\displaystyle A_{\alpha }} by the expression F = d A α + 1 2 [ A α , A α ] {\displaystyle F=dA_{\alpha }+{\frac {1}{2}}[A_{\alpha },A_{\alpha }]} where we use the Lie bracket on the Lie algebra bundle ad ⁡ ( P ) {\displaystyle \operatorname {ad} (P)} which is identified with U α × g {\displaystyle U_{\alpha }\times {\mathfrak {g}}} on the local trivialisation U α {\displaystyle U_{\alpha }} . Under a local gauge transformation g : U α → G {\displaystyle g:U_{\alpha }\to G} so that A ~ α = ( g ∘ s ) ∗ ν {\displaystyle {\tilde {A}}_{\alpha }=(g\circ s)^{*}\nu } , the local connection one-form transforms by the expression A ~ α = ad ⁡ ( g ) ∘ A α + ( g − 1 ) ∗ θ {\displaystyle {\tilde {A}}_{\alpha }=\operatorname {ad} (g)\circ A_{\alpha }+(g^{-1})^{*}\theta } where θ {\displaystyle \theta } denotes the Maurer–Cartan form of the Lie group G {\displaystyle G} . In the case where G {\displaystyle G} is a matrix Lie group, one has the simpler expression A ~ α = g A α g − 1 − ( d g ) g − 1 . {\displaystyle {\tilde {A}}_{\alpha }=gA_{\alpha }g^{-1}-(dg)g^{-1}.} === Connections on vector bundles === A connection on a vector bundle may be specified similarly to the case for principal bundles above, known as an Ehresmann connection. However vector bundle connections admit a more powerful description in terms of a differential operator. A connection on a vector bundle is a choice of K {\displaystyle \mathbb {K} } -linear differential operator ∇ : Γ ( E ) → Γ ( T ∗ X ⊗ E ) = Ω 1 ( E ) {\displaystyle \nabla :\Gamma (E)\to \Gamma (T^{*}X\otimes E)=\Omega ^{1}(E)} such that ∇ ( f s ) = d f ⊗ s + f ∇ s {\displaystyle \nabla (fs)=df\otimes s+f\nabla s} for all f ∈ C ∞ ( X ) {\displaystyle f\in C^{\infty }(X)} and sections s ∈ Γ ( E ) {\displaystyle s\in \Gamma (E)} . The covariant derivative of a section s {\displaystyle s} in the direction of a vector field v {\displaystyle v} is defined by ∇ v ( s ) = ∇ s ( v ) {\displaystyle \nabla _{v}(s)=\nabla s(v)} where on the right we use the natural pairing between Ω 1 ( X ) {\displaystyle \Omega ^{1}(X)} and T X {\displaystyle TX} . This is a new section of the vector bundle E {\displaystyle E} , thought of as the derivative of s {\displaystyle s} in the direction of v {\displaystyle v} . The operator ∇ v {\displaystyle \nabla _{v}} is the covariant derivative operator in the direction of v {\displaystyle v} . The curvature of ∇ {\displaystyle \nabla } is given by the operator F ∇ ∈ Ω 2 ( End ⁡ ( E ) ) {\displaystyle F_{\nabla }\in \Omega ^{2}(\operatorname {End} (E))} with values in the endomorphism bundle, defined by F ∇ ( v 1 , v 2 ) = ∇ v 1 ∇ v 2 − ∇ v 2 ∇ v 1 − ∇ [ v 1 , v 2 ] . {\displaystyle F_{\nabla }(v_{1},v_{2})=\nabla _{v_{1}}\nabla _{v_{2}}-\nabla _{v_{2}}\nabla _{v_{1}}-\nabla _{[v_{1},v_{2}]}.} In a local trivialisation the exterior derivative d {\displaystyle d} acts as a trivial connection (corresponding in the principal bundle picture to the trivial connection discussed above). Namely for a local frame e 1 , … , e r {\displaystyle {\boldsymbol {e}}_{1},\dots ,{\boldsymbol {e}}_{r}} one defines d ( s i e i ) = d s i ⊗ e i {\displaystyle d(s^{i}{\boldsymbol {e}}_{i})=ds^{i}\otimes {\boldsymbol {e}}_{i}} where here we have used Einstein notation for a local section s = s i e i {\displaystyle s=s^{i}{\boldsymbol {e}}_{i}} . Any two connections ∇ 1 , ∇ 2 {\displaystyle \nabla _{1},\nabla _{2}} differ by an End ⁡ ( E ) {\displaystyle \operatorname {End} (E)} -valued one-form A {\displaystyle A} . To see this, observe that the difference of two connections is C ∞ ( X ) {\displaystyle C^{\infty }(X)} -linear: ( ∇ 1 − ∇ 2 ) ( f s ) = f ( ∇ 1 − ∇ 2 ) ( s ) . {\displaystyle (\nabla _{1}-\nabla _{2})(fs)=f(\nabla _{1}-\nabla _{2})(s).} In particular since every vector bundle admits a connection (using partitions of unity and the local trivial connections), the set of connections on a vector bundle has the structure of an infinite-dimensional affine space modelled on the vector space Ω 1 ( End ⁡ ( E ) ) {\displaystyle \Omega ^{1}(\operatorname {End} (E))} . This space is commonly denoted A {\displaystyle {\mathcal {A}}} . Applying this observation locally, every connection over a trivialising subset U α {\displaystyle U_{\alpha }} differs from the trivial connection d {\displaystyle d} by some local connection one-form A α ∈ Ω 1 ( U α , End ⁡ ( E ) ) {\displaystyle A_{\alpha }\in \Omega ^{1}(U_{\alpha },\operatorname {End} (E))} , with the property that ∇ = d + A α {\displaystyle \nabla =d+A_{\alpha }} on U α {\displaystyle U_{\alpha }} . In terms of this local connection form, the curvature may be written as F A = d A α + A α ∧ A α {\displaystyle F_{A}=dA_{\alpha }+A_{\alpha }\wedge A_{\alpha }} where the wedge product occurs on the one-form component, and one composes endomorphisms on the endomorphism component. To link back to the theory of principal bundles, notice that A ∧ A = 1 2 [ A , A ] {\displaystyle A\wedge A={\frac {1}{2}}[A,A]} where on the right we now perform wedge of one-forms and commutator of endomorphisms. Under a gauge transformation u {\displaystyle u} of the vector bundle E {\displaystyle E} , a connection ∇ {\displaystyle \nabla } transforms into a connection u ⋅ ∇ {\displaystyle u\cdot \nabla } by the conjugation ( u ⋅ ∇ ) v ( s ) = u ( ∇ v ( u − 1 ( s ) ) {\displaystyle (u\cdot \nabla )_{v}(s)=u(\nabla _{v}(u^{-1}(s))} . The difference u ⋅ ∇ − ∇ = − ( ∇ u ) u − 1 {\displaystyle u\cdot \nabla -\nabla =-(\nabla u)u^{-1}} where here ∇ {\displaystyle \nabla } is acting on the endomorphisms of E {\displaystyle E} . Under a local gauge transformation g {\displaystyle g} one obtains the same expression A ~ α = g A α g − 1 − ( d g ) g − 1 {\displaystyle {\tilde {A}}_{\alpha }=gA_{\alpha }g^{-1}-(dg)g^{-1}} as in the case of principal bundles. === Induced connections === A connection on a principal bundle induces connections on associated vector bundles. One way to see this is in terms of the local connection forms described above. Namely, if a principal bundle connection H {\displaystyle H} has local connection forms A α ∈ Ω 1 ( U α , ad ⁡ ( P ) ) {\displaystyle A_{\alpha }\in \Omega ^{1}(U_{\alpha },\operatorname {ad} (P))} , and ρ : G → Aut ⁡ ( V ) {\displaystyle \rho :G\to \operatorname {Aut} (V)} is a representation of G {\displaystyle G} defining an associated vector bundle E = P × ρ V {\displaystyle E=P\times _{\rho }V} , then the induced local connection one-forms are defined by ρ ∗ A α ∈ Ω 1 ( U α , End ⁡ ( E ) ) . {\displaystyle \rho _{*}A_{\alpha }\in \Omega ^{1}(U_{\alpha },\operatorname {End} (E)).} Here ρ ∗ {\displaystyle \rho _{*}} is the induced Lie algebra homomorphism from g → End ⁡ ( V ) {\displaystyle {\mathfrak {g}}\to \operatorname {End} (V)} , and we use the fact that this map induces a homomorphism of vector bundles ad ⁡ ( P ) → End ⁡ ( E ) {\displaystyle \operatorname {ad} (P)\to \operatorname {End} (E)} . The induced curvature can be simply defined by ρ ∗ F A ∈ Ω 2 ( U α , End ⁡ ( E ) ) . {\displaystyle \rho _{*}F_{A}\in \Omega ^{2}(U_{\alpha },\operatorname {End} (E)).} Here one sees how the local expressions for curvature are related for principal bundles and vector bundles, as the Lie bracket on the Lie algebra g {\displaystyle {\mathfrak {g}}} is sent to the commutator of endomorphisms of End ⁡ ( V ) {\displaystyle \operatorname {End} (V)} under the Lie algebra homomorphism ρ ∗ {\displaystyle \rho _{*}} . === Space of connections === The central object of study in mathematical gauge theory is the space of connections on a vector bundle or principal bundle. This is an infinite-dimensional affine space A {\displaystyle {\mathcal {A}}} modelled on the vector space Ω 1 ( X , ad ⁡ ( P ) ) {\displaystyle \Omega ^{1}(X,\operatorname {ad} (P))} (or Ω 1 ( X , End ⁡ ( E ) ) {\displaystyle \Omega ^{1}(X,\operatorname {End} (E))} in the case of vector bundles). Two connections A , A ′ ∈ A {\displaystyle A,A'\in {\mathcal {A}}} are said to be gauge equivalent if there exists a gauge transformation u {\displaystyle u} such that A ′ = u ⋅ A {\displaystyle A'=u\cdot A} . Gauge theory is concerned with gauge equivalence classes of connections. In some sense gauge theory is therefore concerned with the properties of the quotient space A / G {\displaystyle {\mathcal {A}}/{\mathcal {G}}} , which is in general neither a Hausdorff space or a smooth manifold. Many interesting properties of the base manifold X {\displaystyle X} can be encoded in the geometry and topology of moduli spaces of connections on principal bundles and vector bundles over X {\displaystyle X} . Invariants of X {\displaystyle X} , such as Donaldson invariants or Seiberg–Witten invariants can be obtained by computing numeral quantities derived from moduli spaces of connections over X {\displaystyle X} . The most famous application of this idea is Donaldson's theorem, which uses the moduli space of Yang–Mills connections on a principal SU ⁡ ( 2 ) {\displaystyle \operatorname {SU} (2)} -bundle over a simply connected four-manifold X {\displaystyle X} to study its intersection form. For this work Donaldson was awarded a Fields Medal. == Notational conventions == There are various notational conventions used for connections on vector bundles and principal bundles which will be summarised here. The letter A {\displaystyle A} is the most common symbol used to represent a connection on a vector bundle or principal bundle. It comes from the fact that if one chooses a fixed connection ∇ 0 ∈ A {\displaystyle \nabla _{0}\in {\mathcal {A}}} of all connections, then any other connection may be written ∇ = ∇ 0 + A {\displaystyle \nabla =\nabla _{0}+A} for some unique one-form A ∈ Ω 1 ( X , ad ⁡ ( P ) ) {\displaystyle A\in \Omega ^{1}(X,\operatorname {ad} (P))} . It also comes from the use of A α {\displaystyle A_{\alpha }} to denote the local form of the connection on a vector bundle, which subsequently comes from the electromagnetic potential A {\displaystyle A} in physics. Sometimes the symbol ω {\displaystyle \omega } is also used to refer to the connection form, usually on a principal bundle, and usually in this case ω {\displaystyle \omega } refers to the global connection one-form ω ∈ Ω 1 ( P , g ) {\displaystyle \omega \in \Omega ^{1}(P,{\mathfrak {g}})} on the total space of the principal bundle, rather than the corresponding local connections forms. This convention is usually avoided in the mathematical literature as it often clashes with the use of ω {\displaystyle \omega } for a Kähler form when the underlying manifold X {\displaystyle X} is a Kähler manifold. The symbol ∇ {\displaystyle \nabla } is most commonly used to represent a connection on a vector bundle as a differential operator, and in that sense is used interchangeably with the letter A {\displaystyle A} . It is also used to refer to the covariant derivative operators ∇ X {\displaystyle \nabla _{X}} . Alternative notation for the connection operator and covariant derivative operators is ∇ A {\displaystyle \nabla _{A}} to emphasize the dependence on the choice of A ∈ A {\displaystyle A\in {\mathcal {A}}} , or D A {\displaystyle D_{A}} or d A {\displaystyle d_{A}} . The operator d A {\displaystyle d_{A}} most commonly refers to the exterior covariant derivative of a connection A {\displaystyle A} (and so is sometimes written d ∇ {\displaystyle d_{\nabla }} for a connection ∇ {\displaystyle \nabla } ). Since the exterior covariant derivative in degree 0 is the same as the regular covariant derivative, the connection or covariant derivative itself is often denoted d A {\displaystyle d_{A}} instead of ∇ {\displaystyle \nabla } . The symbol F A {\displaystyle F_{A}} or F ∇ {\displaystyle F_{\nabla }} is most commonly used to refer to the curvature of a connection. When the connection is referred to by ω {\displaystyle \omega } , the curvature is referred to by Ω {\displaystyle \Omega } rather than F ω {\displaystyle F_{\omega }} . Other conventions involve R {\displaystyle R} or R A {\displaystyle R_{A}} or R ∇ {\displaystyle R_{\nabla }} , by analogy with the Riemannian curvature tensor in Riemannian geometry which is denoted by R {\displaystyle R} . The letter H {\displaystyle H} is often used to denote a principal bundle connection or Ehresmann connection when emphasis is to be placed on the horizontal distribution H ⊂ T P {\displaystyle H\subset TP} . In this case the vertical projection operator corresponding to H {\displaystyle H} (the connection one-form on P {\displaystyle P} ) is usually denoted ω {\displaystyle \omega } , or v {\displaystyle v} , or ν {\displaystyle \nu } . Using this convention the curvature is sometimes denoted F H {\displaystyle F_{H}} to emphasize the dependence, and F H {\displaystyle F_{H}} may refer to either the curvature operator on the total space F H ∈ Ω 2 ( P , g ) {\displaystyle F_{H}\in \Omega ^{2}(P,{\mathfrak {g}})} , or the curvature on the base F H ∈ Ω 2 ( X , ad ⁡ ( P ) ) {\displaystyle F_{H}\in \Omega ^{2}(X,\operatorname {ad} (P))} . The Lie algebra adjoint bundle is usually denoted ad ⁡ ( P ) {\displaystyle \operatorname {ad} (P)} , and the Lie group adjoint bundle by Ad ⁡ ( P ) {\displaystyle \operatorname {Ad} (P)} . This disagrees with the convention in the theory of Lie groups, where Ad {\displaystyle \operatorname {Ad} } refers to the representation of G {\displaystyle G} on g {\displaystyle {\mathfrak {g}}} , and ad {\displaystyle \operatorname {ad} } refers to the Lie algebra representation of g {\displaystyle {\mathfrak {g}}} on itself by the Lie bracket. In the Lie group theory the conjugation action (which defines the bundle Ad ⁡ ( P ) {\displaystyle \operatorname {Ad} (P)} ) is often denoted by Ψ g {\displaystyle \Psi _{g}} . === Dictionary of mathematical and physical terminology === The mathematical and physical fields of gauge theory involve the study of the same objects, but use different terminology to describe them. Below is a summary of how these terms relate to each other. As a demonstration of this dictionary, consider an interacting term of an electron-positron particle field and the electromagnetic field in the Lagrangian of quantum electrodynamics: L = ψ ¯ ( i γ μ D μ − m ) ψ − 1 4 F μ ν F μ ν , {\displaystyle {\mathcal {L}}={\bar {\psi }}(i\gamma ^{\mu }D_{\mu }-m)\psi -{\frac {1}{4}}F_{\mu \nu }F^{\mu \nu },} Mathematically this might be rewritten L = ⟨ ψ , ( D / A − m ) ψ ⟩ L 2 + ‖ F A ‖ L 2 2 {\displaystyle {\mathcal {L}}=\langle \psi ,({D\!\!\!\!/}_{A}-m)\psi \rangle _{L^{2}}+\|F_{A}\|_{L^{2}}^{2}} where A {\displaystyle A} is a connection on a principal U ⁡ ( 1 ) {\displaystyle \operatorname {U} (1)} bundle P {\displaystyle P} , ψ {\displaystyle \psi } is a section of an associated spinor bundle and D / A {\displaystyle {D\!\!\!\!/}_{A}} is the induced Dirac operator of the induced covariant derivative ∇ A {\displaystyle \nabla _{A}} on this associated bundle. The first term is an interacting term in the Lagrangian between the spinor field (the field representing the electron-positron) and the gauge field (representing the electromagnetic field). The second term is the regular Yang–Mills functional which describes the basic non-interacting properties of the electromagnetic field (the connection A {\displaystyle A} ). The term of the form ∇ A ψ {\displaystyle \nabla _{A}\psi } is an example of what in physics is called minimal coupling, that is, the simplest possible interaction between a matter field ψ {\displaystyle \psi } and a gauge field A {\displaystyle A} . == Yang–Mills theory == The predominant theory that occurs in mathematical gauge theory is Yang–Mills theory. This theory involves the study of connections which are critical points of the Yang–Mills functional defined by YM ⁡ ( A ) = ∫ X ‖ F A ‖ 2 d v o l g {\displaystyle \operatorname {YM} (A)=\int _{X}\|F_{A}\|^{2}\,d\mathrm {vol} _{g}} where ( X , g ) {\displaystyle (X,g)} is an oriented Riemannian manifold with d v o l g {\displaystyle d\mathrm {vol} _{g}} the Riemannian volume form and ‖ ⋅ ‖ 2 {\displaystyle \|\cdot \|^{2}} an L 2 {\displaystyle L^{2}} -norm on the adjoint bundle ad ⁡ ( P ) {\displaystyle \operatorname {ad} (P)} . This functional is the square of the L 2 {\displaystyle L^{2}} -norm of the curvature of the connection A {\displaystyle A} , so connections which are critical points of this function are those with curvature as small as possible (or higher local minima of YM {\displaystyle \operatorname {YM} } ). These critical points are characterised as solutions of the associated Euler–Lagrange equations, the Yang–Mills equations d A ⋆ F A = 0 {\displaystyle d_{A}\star F_{A}=0} where d A {\displaystyle d_{A}} is the induced exterior covariant derivative of ∇ A {\displaystyle \nabla _{A}} on ad ⁡ ( P ) {\displaystyle \operatorname {ad} (P)} and ⋆ {\displaystyle \star } is the Hodge star operator. Such solutions are called Yang–Mills connections and are of significant geometric interest. The Bianchi identity asserts that for any connection, d A F A = 0 {\displaystyle d_{A}F_{A}=0} . By analogy for differential forms a harmonic form ω {\displaystyle \omega } is characterised by the condition d ⋆ ω = d ω = 0. {\displaystyle d\star \omega =d\omega =0.} If one defined a harmonic connection by the condition that d A ⋆ F A = d A F A = 0 {\displaystyle d_{A}\star F_{A}=d_{A}F_{A}=0} the then study of Yang–Mills connections is similar in nature to that of harmonic forms. Hodge theory provides a unique harmonic representative of every de Rham cohomology class [ ω ] {\displaystyle [\omega ]} . Replacing a cohomology class by a gauge orbit { u ⋅ A ∣ u ∈ G } {\displaystyle \{u\cdot A\mid u\in {\mathcal {G}}\}} , the study of Yang–Mills connections can be seen as trying to find unique representatives for each orbit in the quotient space A / G {\displaystyle {\mathcal {A}}/{\mathcal {G}}} of connections modulo gauge transformations. === Self-duality and anti-self-duality equations === In dimension four the Hodge star operator sends two-forms to two-forms, ⋆ : Ω 2 ( X ) → Ω 2 ( X ) {\displaystyle \star :\Omega ^{2}(X)\to \Omega ^{2}(X)} , and squares to the identity operator, ⋆ 2 = Id {\displaystyle \star ^{2}=\operatorname {Id} } . Thus the Hodge star operating on two-forms has eigenvalues ± 1 {\displaystyle \pm 1} , and the two-forms on an oriented Riemannian four-manifold split as a direct sum Ω 2 ( X ) = Ω + ( X ) ⊕ Ω − ( X ) {\displaystyle \Omega ^{2}(X)=\Omega _{+}(X)\oplus \Omega _{-}(X)} into the self-dual and anti-self-dual two-forms, given by the + 1 {\displaystyle +1} and − 1 {\displaystyle -1} eigenspaces of the Hodge star operator respectively. That is, α ∈ Ω 2 ( X ) {\displaystyle \alpha \in \Omega ^{2}(X)} is self-dual if ⋆ α = α {\displaystyle \star \alpha =\alpha } , and anti-self dual if ⋆ α = − α {\displaystyle \star \alpha =-\alpha } , and every differential two-form admits a splitting α = α + + α − {\displaystyle \alpha =\alpha _{+}+\alpha _{-}} into self-dual and anti-self-dual parts. If the curvature of a connection A {\displaystyle A} on a principal bundle over a four-manifold is self-dual or anti-self-dual then by the Bianchi identity d A ⋆ F A = ± d A F A = 0 {\displaystyle d_{A}\star F_{A}=\pm d_{A}F_{A}=0} , so the connection is automatically a Yang–Mills connection. The equation ⋆ F A = ± F A {\displaystyle \star F_{A}=\pm F_{A}} is a first order partial differential equation for the connection A {\displaystyle A} , and therefore is simpler to study than the full second order Yang–Mills equation. The equation ⋆ F A = F A {\displaystyle \star F_{A}=F_{A}} is called the self-duality equation, and the equation ⋆ F A = − F A {\displaystyle \star F_{A}=-F_{A}} is called the anti-self-duality equation, and solutions to these equations are self-dual connections or anti-self-dual connections respectively. === Dimensional reduction === One way to derive new and interesting gauge-theoretic equations is to apply the process of dimensional reduction to the Yang–Mills equations. This process involves taking the Yang–Mills equations over a manifold X {\displaystyle X} (usually taken to be the Euclidean space X = R 4 {\displaystyle X=\mathbb {R} ^{4}} ), and imposing that the solutions of the equations be invariant under a group of translational or other symmetries. Through this process the Yang–Mills equations lead to the Bogomolny equations describing monopoles on R 3 {\displaystyle \mathbb {R} ^{3}} , Hitchin's equations describing Higgs bundles on Riemann surfaces, and the Nahm equations on real intervals, by imposing symmetry under translations in one, two, and three directions respectively. == Gauge theory in one and two dimensions == Here the Yang–Mills equations when the base manifold X {\displaystyle X} is of low dimension is discussed. In this setting the equations simplify dramatically due to the fact that in dimension one there are no two-forms, and in dimension two the Hodge star operator on two-forms acts as ⋆ : Ω 2 ( X ) → C ∞ ( X ) {\displaystyle \star :\Omega ^{2}(X)\to C^{\infty }(X)} . === Yang–Mills theory === One may study the Yang–Mills equations directly on a manifold of dimension two. The theory of Yang–Mills equations when the base manifold is a compact Riemann surface was carried about by Michael Atiyah and Raoul Bott. In this case the moduli space of Yang–Mills connections over a complex vector bundle E {\displaystyle E} admits various rich interpretations, and the theory serves as the simplest case to understand the equations in higher dimensions. The Yang–Mills equations in this case become ⋆ F A = λ ( E ) Id E {\displaystyle \star F_{A}=\lambda (E)\operatorname {Id} _{E}} for some topological constant λ ( E ) ∈ C {\displaystyle \lambda (E)\in \mathbb {C} } depending on E {\displaystyle E} . Such connections are called projectively flat, and in the case where the vector bundle is topologically trivial (so λ ( E ) = 0 {\displaystyle \lambda (E)=0} ) they are precisely the flat connections. When the rank and degree of the vector bundle are coprime, the moduli space M {\displaystyle {\mathcal {M}}} of Yang–Mills connections is smooth and has a natural structure of a symplectic manifold. Atiyah and Bott observed that since the Yang–Mills connections are projectively flat, their holonomy gives projective unitary representations of the fundamental group of the surface, so that this space has an equivalent description as a moduli space of projective unitary representations of the fundamental group of the Riemann surface, a character variety. The theorem of Narasimhan and Seshadri gives an alternative description of this space of representations as the moduli space of stable holomorphic vector bundles which are smoothly isomorphic to the E {\displaystyle E} . Through this isomorphism the moduli space of Yang–Mills connections gains a complex structure, which interacts with the symplectic structure of Atiyah and Bott to make it a compact Kähler manifold. Simon Donaldson gave an alternative proof of the theorem of Narasimhan and Seshadri that directly passed from Yang–Mills connections to stable holomorphic structures. Atiyah and Bott used this rephrasing of the problem to illuminate the intimate relationship between the extremal Yang–Mills connections and the stability of the vector bundles, as an infinite-dimensional moment map for the action of the gauge group G {\displaystyle {\mathcal {G}}} , given by the curvature map A ↦ F A {\displaystyle A\mapsto F_{A}} itself. This observation phrases the Narasimhan–Seshadri theorem as a kind of infinite-dimensional version of the Kempf–Ness theorem from geometric invariant theory, relating critical points of the norm squared of the moment map (in this case Yang–Mills connections) to stable points on the corresponding algebraic quotient (in this case stable holomorphic vector bundles). This idea has been subsequently very influential in gauge theory and complex geometry since its introduction. === Nahm equations === The Nahm equations, introduced by Werner Nahm, are obtained as the dimensional reduction of the anti-self-duality in four dimensions to one dimension, by imposing translational invariance in three directions. Concretely, one requires that the connection form A = A 0 d x 0 + A 1 d x 1 + A 2 d x 2 + A 3 d x 3 {\displaystyle A=A_{0}\,dx^{0}+A_{1}\,dx^{1}+A_{2}\,dx^{2}+A_{3}\,dx^{3}} does not depend on the coordinates x 1 , x 2 , x 3 {\displaystyle x^{1},x^{2},x^{3}} . In this setting the Nahm equations between a system of equations on an interval I ⊂ R {\displaystyle I\subset \mathbb {R} } for four matrices T 0 , T 1 , T 2 , T 3 ∈ C ∞ ( I , g ) {\displaystyle T_{0},T_{1},T_{2},T_{3}\in C^{\infty }(I,{\mathfrak {g}})} satisfying the triple of equations { d T 1 d t + [ T 0 , T 1 ] + [ T 2 , T 3 ] = 0 d T 2 d t + [ T 0 , T 2 ] + [ T 3 , T 1 ] = 0 d T 3 d t + [ T 0 , T 3 ] + [ T 1 , T 2 ] = 0. {\displaystyle {\begin{cases}{\frac {dT_{1}}{dt}}+[T_{0},T_{1}]+[T_{2},T_{3}]=0\\{\frac {dT_{2}}{dt}}+[T_{0},T_{2}]+[T_{3},T_{1}]=0\\{\frac {dT_{3}}{dt}}+[T_{0},T_{3}]+[T_{1},T_{2}]=0.\end{cases}}} It was shown by Nahm that the solutions to these equations (which can be obtained fairly easily as they are a system of ordinary differential equations) can be used to construct solutions to the Bogomolny equations, which describe monopoles on R 3 {\displaystyle \mathbb {R} ^{3}} . Nigel Hitchin showed that solutions to the Bogomolny equations could be used to construct solutions to the Nahm equations, showing solutions to the two problems were equivalent. Donaldson further showed that solutions to the Nahm equations are equivalent to rational maps of degree k {\displaystyle k} from the complex projective line C P 1 {\displaystyle \mathbb {CP} ^{1}} to itself, where k {\displaystyle k} is the charge of the corresponding magnetic monopole. The moduli space of solutions to the Nahm equations has the structure of a hyperkähler manifold. === Hitchin's equations and Higgs bundles === Hitchin's equations, introduced by Nigel Hitchin, are obtained as the dimensional reduction of the self-duality equations in four dimensions to two dimensions by imposing translation invariance in two directions. In this setting the two extra connection form components A 3 d x 3 + A 4 d x 4 {\displaystyle A_{3}\,dx^{3}+A_{4}\,dx^{4}} can be combined into a single complex-valued endomorphism Φ = A 3 + i A 4 {\displaystyle \Phi =A_{3}+iA_{4}} , and when phrased in this way the equations become conformally invariant and therefore are natural to study on a compact Riemann surface rather than R 2 {\displaystyle \mathbb {R} ^{2}} . Hitchin's equations state that for a pair ( A , Φ ) {\displaystyle (A,\Phi )} on a complex vector bundle E → Σ {\displaystyle E\to \Sigma } where Φ ∈ Ω 1 , 0 ( Σ , End ⁡ ( E ) ) {\displaystyle \Phi \in \Omega ^{1,0}(\Sigma ,\operatorname {End} (E))} , that { F A + [ Φ , Φ ∗ ] = 0 ∂ ¯ A Φ = 0 {\displaystyle {\begin{cases}F_{A}+[\Phi ,\Phi ^{*}]=0\\{\bar {\partial }}_{A}\Phi =0\end{cases}}} where ∂ ¯ A {\displaystyle {\bar {\partial }}_{A}} is the ( 0 , 1 ) {\displaystyle (0,1)} -component of d A {\displaystyle d_{A}} . Solutions of Hitchin's equations are called Hitchin pairs. Whereas solutions to the Yang–Mills equations on a compact Riemann surface correspond to projective unitary representations of the surface group, Hitchin showed that solutions to Hitchin's equations correspond to projective complex representations of the surface group. The moduli space of Hitchin pairs naturally has (when the rank and degree of the bundle are coprime) the structure of a Kähler manifold. Through an analogue of Atiyah and Bott's observation about the Yang–Mills equations, Hitchin showed that Hitchin pairs correspond to so-called stable Higgs bundles, where a Higgs bundle is a pair ( E , Φ ) {\displaystyle (E,\Phi )} where E → Σ {\displaystyle E\to \Sigma } is a holomorphic vector bundle and Φ : E → E ⊗ K {\displaystyle \Phi :E\to E\otimes K} is a holomorphic endomorphism of E {\displaystyle E} with values in the canonical bundle of the Riemann surface Σ {\displaystyle \Sigma } . This is shown through an infinite-dimensional moment map construction, and this moduli space of Higgs bundles also has a complex structure, which is different to that coming from the Hitchin pairs, leading to two complex structures on the moduli space M {\displaystyle {\mathcal {M}}} of Higgs bundles. These combine to give a third making this moduli space a hyperkähler manifold. Hitchin's work was subsequently vastly generalised by Carlos Simpson, and the correspondence between solutions to Hitchin's equations and Higgs bundles over an arbitrary Kähler manifold is known as the nonabelian Hodge theorem. == Gauge theory in three dimensions == === Monopoles === The dimensional reduction of the Yang–Mills equations to three dimensions by imposing translational invariance in one direction gives rise to the Bogomolny equations for a pair ( A , Φ ) {\displaystyle (A,\Phi )} where Φ : R 3 → g {\displaystyle \Phi :\mathbb {R} ^{3}\to {\mathfrak {g}}} is a family of matrices. The equations are F A = ⋆ d A Φ . {\displaystyle F_{A}=\star d_{A}\Phi .} When the principal bundle P → R 3 {\displaystyle P\to \mathbb {R} ^{3}} has structure group U ⁡ ( 1 ) {\displaystyle \operatorname {U} (1)} the circle group, solutions to the Bogomolny equations model the Dirac monopole describing a magnetic monopole in classical electromagnetism. The work of Nahm and Hitchin shows that when the structure group is the special unitary group SU ⁡ ( 2 ) {\displaystyle \operatorname {SU} (2)} solutions to the monopole equations correspond to solutions to the Nahm equations, and by work of Donaldson these further correspond to rational maps from C P 1 {\displaystyle \mathbb {CP} ^{1}} to itself of degree k {\displaystyle k} where k {\displaystyle k} is the charge of the monopole. This charge is defined as the limit lim R → ∞ ∫ S R ( Φ , F A ) = 4 π k {\displaystyle \lim _{R\to \infty }\int _{S_{R}}(\Phi ,F_{A})=4\pi k} of the integral of the pairing ( Φ , F A ) ∈ Ω 2 ( R 3 ) {\displaystyle (\Phi ,F_{A})\in \Omega ^{2}(\mathbb {R} ^{3})} over spheres S R {\displaystyle S_{R}} in R 3 {\displaystyle \mathbb {R} ^{3}} of increasing radius R {\displaystyle R} . === Chern–Simons theory === Chern–Simons theory in 3 dimensions is a topological quantum field theory with an action functional proportional to the integral of the Chern–Simons form, a three-form defined by Tr ⁡ ( F A ∧ A − 1 3 A ∧ A ∧ A ) . {\displaystyle \operatorname {Tr} (F_{A}\wedge A-{\frac {1}{3}}A\wedge A\wedge A).} Classical solutions to the Euler–Lagrange equations of the Chern–Simons functional on a closed 3-manifold X {\displaystyle X} correspond to flat connections on the principal G {\displaystyle G} -bundle P → X {\displaystyle P\to X} . However, when X {\displaystyle X} has a boundary the situation becomes more complicated. Chern–Simons theory was used by Edward Witten to express the Jones polynomial, a knot invariant, in terms of the vacuum expectation value of a Wilson loop in SU ⁡ ( 2 ) {\displaystyle \operatorname {SU} (2)} Chern–Simons theory on the three-sphere S 3 {\displaystyle S^{3}} . This was a stark demonstration of the power of gauge theoretic problems to provide new insight in topology, and was one of the first instances of a topological quantum field theory. In the quantization of the classical Chern–Simons theory, one studies the induced flat or projectively flat connections on the principal bundle restricted to surfaces Σ ⊂ X {\displaystyle \Sigma \subset X} inside the 3-manifold. The classical state spaces corresponding to each surface are precisely the moduli spaces of Yang–Mills equations studied by Atiyah and Bott. The geometric quantization of these spaces was achieved by Nigel Hitchin and Axelrod–Della Pietra–Witten independently, and in the case where the structure group is complex, the configuration space is the moduli space of Higgs bundles and its quantization was achieved by Witten. === Floer homology === Andreas Floer introduced a type of homology on a 3-manifolds defined in analogy with Morse homology in finite dimensions. In this homology theory, the Morse function is the Chern–Simons functional on the space of connections on an SU ⁡ ( 2 ) {\displaystyle \operatorname {SU} (2)} principal bundle over the 3-manifold X {\displaystyle X} . The critical points are the flat connections, and the flow lines are defined to be the Yang–Mills instantons on M × I {\displaystyle M\times I} that restrict to the critical flat connections on the two boundary components. This leads to instanton Floer homology. The Atiyah–Floer conjecture asserts that instanton Floer homology agrees with the Lagrangian intersection Floer homology of the moduli space of flat connections on the surface Σ ⊂ X {\displaystyle \Sigma \subset X} defining a Heegaard splitting of X {\displaystyle X} , which is symplectic due to the observations of Atiyah and Bott. In analogy with instanton Floer homology one may define Seiberg–Witten Floer homology where instantons are replaced with solutions of the Seiberg–Witten equations. By work of Clifford Taubes this is known to be isomorphic to embedded contact homology and subsequently Heegaard Floer homology. == Gauge theory in four dimensions == Gauge theory has been most intensively studied in four dimensions. Here the mathematical study of gauge theory overlaps significantly with its physical origins, as the standard model of particle physics can be thought of as a quantum field theory on a four-dimensional spacetime. The study of gauge theory problems in four dimensions naturally leads to the study of topological quantum field theory. Such theories are physical gauge theories that are insensitive to changes in the Riemannian metric of the underlying four-manifold, and therefore can be used to define topological (or smooth structure) invariants of the manifold. === Anti-self-duality equations === In four dimensions the Yang–Mills equations admit a simplification to the first order anti-self-duality equations ⋆ F A = − F A {\displaystyle \star F_{A}=-F_{A}} for a connection A {\displaystyle A} on a principal bundle P → X {\displaystyle P\to X} over an oriented Riemannian four-manifold X {\displaystyle X} . These solutions to the Yang–Mills equations represent the absolute minima of the Yang–Mills functional, and the higher critical points correspond to the solutions d A ⋆ F A = 0 {\displaystyle d_{A}\star F_{A}=0} that do not arise from anti-self-dual connections. The moduli space of solutions to the anti-self-duality equations, M P {\displaystyle {\mathcal {M}}_{P}} , allows one to derive useful invariants about the underlying four-manifold. This theory is most effective in the case where X {\displaystyle X} is simply connected. For example, in this case Donaldson's theorem asserts that if the four-manifold has negative-definite intersection form (4-manifold), and if the principal bundle has structure group the special unitary group SU ⁡ ( 2 ) {\displaystyle \operatorname {SU} (2)} and second Chern class c 2 ( P ) = 1 {\displaystyle c_{2}(P)=1} , then the moduli space M P {\displaystyle {\mathcal {M}}_{P}} is five-dimensional and gives a cobordism between X {\displaystyle X} itself and a disjoint union of b 2 ( X ) {\displaystyle b_{2}(X)} copies of C P 2 {\displaystyle \mathbb {CP} ^{2}} with its orientation reversed. This implies that the intersection form of such a four-manifold is diagonalisable. There are examples of simply connected topological four-manifolds with non-diagonalisable intersection form, such as the E8 manifold, so Donaldson's theorem implies the existence of topological four-manifolds with no smooth structure. This is in stark contrast with two or three dimensions, in which topological structures and smooth structures are equivalent: any topological manifold of dimension less than or equal to 3 has a unique smooth structure on it. Similar techniques were used by Clifford Taubes and Donaldson to show that Euclidean space R 4 {\displaystyle \mathbb {R} ^{4}} admits uncountably infinitely many distinct smooth structures. This is in stark contrast to any dimension other than four, where Euclidean space has a unique smooth structure. An extension of these ideas leads to Donaldson theory, which constructs further invariants of smooth four-manifolds out of the moduli spaces of connections over them. These invariants are obtained by evaluating cohomology classes on the moduli space against a fundamental class, which exists due to analytical work showing the orientability and compactness of the moduli space by Karen Uhlenbeck, Taubes, and Donaldson. When the four-manifold is a Kähler manifold or algebraic surface and the principal bundle has vanishing first Chern class, the anti-self-duality equations are equivalent to the Hermitian Yang–Mills equations on the complex manifold X {\displaystyle X} . The Kobayashi–Hitchin correspondence proven for algebraic surfaces by Donaldson, and in general by Uhlenbeck and Yau, asserts that solutions to the HYM equations correspond to stable holomorphic vector bundles. This work gave an alternate algebraic description of the moduli space and its compactification, because the moduli space of semistable holomorphic vector bundles over a complex manifold is a projective variety, and therefore compact. This indicates one way of compactifying the moduli space of connections is to add in connections corresponding to semi-stable vector bundles, so-called almost Hermitian Yang–Mills connections. === Seiberg–Witten equations === During their investigation of supersymmetry in four dimensions, Edward Witten and Nathan Seiberg uncovered a system of equations now called the Seiberg–Witten equations, for a connection A {\displaystyle A} and spinor field ψ {\displaystyle \psi } . In this case the four-manifold must admit a SpinC structure, which defines a principal SpinC bundle P {\displaystyle P} with determinant line bundle L {\displaystyle L} , and an associated spinor bundle S + {\displaystyle S^{+}} . The connection A {\displaystyle A} is on L {\displaystyle L} , and the spinor field ψ ∈ Γ ( S + ) {\displaystyle \psi \in \Gamma (S^{+})} . The Seiberg–Witten equations are given by { F A + = ψ ⊗ ψ ∗ − 1 2 | ψ | 2 d A ψ = 0. {\displaystyle {\begin{cases}F_{A}^{+}=\psi \otimes \psi ^{*}-{\frac {1}{2}}|\psi |^{2}\\d_{A}\psi =0.\end{cases}}} Solutions to the Seiberg–Witten equations are called monopoles. The moduli space of solutions to the Seiberg–Witten equations, M σ {\displaystyle {\mathcal {M}}_{\sigma }} where σ {\displaystyle \sigma } denotes the choice of Spin structure, is used to derive the Seiberg–Witten invariants. The Seiberg–Witten equations have an advantage over the anti-self-duality equations, in that the equations themselves may be perturbed slightly to give the moduli space of solutions better properties. To do this, an arbitrary self-dual two-form is added on to the first equation. For generic choices of metric g {\displaystyle g} on the underlying four-manifold, and choice of perturbing two-form, the moduli space of solutions is a compact smooth manifold. In good circumstances (when the manifold X {\displaystyle X} is of simple type), this moduli space is zero-dimensional: a finite collection of points. The Seiberg–Witten invariant in this case is simply the number of points in the moduli space. The Seiberg–Witten invariants can be used to prove many of the same results as Donaldson invariants, but often with easier proofs which apply in more generality. == Gauge theory in higher dimensions == === Hermitian Yang–Mills equations === A particular class of Yang–Mills connections are possible to study over Kähler manifolds or Hermitian manifolds. The Hermitian Yang–Mills equations generalise the anti-self-duality equations occurring in four-dimensional Yang–Mills theory to holomorphic vector bundles over Hermitian complex manifolds in any dimension. If E → X {\displaystyle E\to X} is a holomorphic vector bundle over a compact Kähler manifold ( X , ω ) {\displaystyle (X,\omega )} , and A {\displaystyle A} is a Hermitian connection on E {\displaystyle E} with respect to some Hermitian metric h {\displaystyle h} . The Hermitian Yang–Mills equations are { F A 0 , 2 = 0 Λ ω F A = λ ( E ) Id E , {\displaystyle {\begin{cases}F_{A}^{0,2}=0\\\Lambda _{\omega }F_{A}=\lambda (E)\operatorname {Id} _{E},\end{cases}}} where λ ( E ) ∈ C {\displaystyle \lambda (E)\in \mathbb {C} } is a topological constant depending on E {\displaystyle E} . These may be viewed either as an equation for the Hermitian connection A {\displaystyle A} or for the corresponding Hermitian metric h {\displaystyle h} with associated Chern connection A {\displaystyle A} . In four dimensions the HYM equations are equivalent to the ASD equations. In two dimensions the HYM equations correspond to the Yang–Mills equations considered by Atiyah and Bott. The Kobayashi–Hitchin correspondence asserts that solutions of the HYM equations are in correspondence with polystable holomorphic vector bundles. In the case of compact Riemann surfaces this is the theorem of Narasimhan and Seshadri as proven by Donaldson. For algebraic surfaces it was proven by Donaldson, and in general it was proven by Karen Uhlenbeck and Shing-Tung Yau. This theorem is generalised in the nonabelian Hodge theorem by Simpson, and is in fact a special case of it where the Higgs field of a Higgs bundle ( E , Φ ) {\displaystyle (E,\Phi )} is set to zero. === Exceptional holonomy instantons === The effectiveness of solutions of the Yang–Mills equations in defining invariants of four-manifolds has led to interest that they may help distinguish between exceptional holonomy manifolds such as G2 manifolds in dimension 7 and Spin(7) manifolds in dimension 8, as well as related structures such as Calabi–Yau 6-manifolds and nearly Kähler manifolds. === String theory === New gauge-theoretic problems arise out of superstring theory models. In such models the universe is 10 dimensional consisting of four dimensions of regular spacetime and a 6-dimensional Calabi–Yau manifold. In such theories the fields which act on strings live on bundles over these higher dimensional spaces, and one is interested in gauge-theoretic problems relating to them. For example, the limit of the natural field theories in superstring theory as the string radius approaches zero (the so-called large volume limit) on a Calabi–Yau 6-fold is given by Hermitian Yang–Mills equations on this manifold. Moving away from the large volume limit one obtains the deformed Hermitian Yang–Mills equation, which describes the equations of motion for a D-brane in the B-model of superstring theory. Mirror symmetry predicts that solutions to these equations should correspond to special Lagrangian submanifolds of the mirror dual Calabi–Yau. == See also == Gauge theory Introduction to gauge theory Gauge group (mathematics) Gauge symmetry (mathematics) Yang–Mills theory Yang–Mills equations == References ==
Wikipedia/Gauge_theory_(mathematics)
Algebraic geometry codes, often abbreviated AG codes, are a type of linear code that generalize Reed–Solomon codes. The Russian mathematician V. D. Goppa constructed these codes for the first time in 1982. == History == The name of these codes has evolved since the publication of Goppa's paper describing them. Historically these codes have also been referred to as geometric Goppa codes; however, this is no longer the standard term used in coding theory literature. This is due to the fact that Goppa codes are a distinct class of codes which were also constructed by Goppa in the early 1970s. These codes attracted interest in the coding theory community because they have the ability to surpass the Gilbert–Varshamov bound; at the time this was discovered, the Gilbert–Varshamov bound had not been broken in the 30 years since its discovery. This was demonstrated by Tfasman, Vladut, and Zink in the same year as the code construction was published, in their paper "Modular curves, Shimura curves, and Goppa codes, better than Varshamov-Gilbert bound". The name of this paper may be one source of confusion affecting references to algebraic geometry codes throughout 1980s and 1990s coding theory literature. == Construction == In this section the construction of algebraic geometry codes is described. The section starts with the ideas behind Reed–Solomon codes, which are used to motivate the construction of algebraic geometry codes. === Reed–Solomon codes === Algebraic geometry codes are a generalization of Reed–Solomon codes. Constructed by Irving Reed and Gustave Solomon in 1960, Reed–Solomon codes use univariate polynomials to form codewords, by evaluating polynomials of sufficiently small degree at the points in a finite field F q {\displaystyle \mathbb {F} _{q}} . Formally, Reed–Solomon codes are defined in the following way. Let F q = { α 1 , … , α q } {\displaystyle \mathbb {F} _{q}=\{\alpha _{1},\dots ,\alpha _{q}\}} . Set positive integers k ≤ n ≤ q {\displaystyle k\leq n\leq q} . Let F q [ x ] < k := { f ∈ F q [ x ] : deg ⁡ f < k } {\displaystyle \mathbb {F} _{q}[x]_{<k}:=\left\{f\in \mathbb {F} _{q}[x]:\deg f<k\right\}} The Reed–Solomon code R S ( q , n , k ) {\displaystyle RS(q,n,k)} is the evaluation code R S ( q , n , k ) = { ( f ( α 1 ) , f ( α 2 ) , … , f ( α n ) ) : f ∈ F q [ x ] < k } ⊆ F q n . {\displaystyle RS(q,n,k)=\left\{\left(f(\alpha _{1}),f(\alpha _{2}),\dots ,f(\alpha _{n})\right):f\in \mathbb {F} _{q}[x]_{<k}\right\}\subseteq \mathbb {F} _{q}^{n}.} === Codes from algebraic curves === Goppa observed that F q {\displaystyle \mathbb {F} _{q}} can be considered as an affine line, with corresponding projective line P F q 1 {\displaystyle \mathbb {P} _{\mathbb {F} _{q}}^{1}} . Then, the polynomials in F q [ x ] < k {\displaystyle \mathbb {F} _{q}[x]_{<k}} (i.e. the polynomials of degree less than k {\displaystyle k} over F q {\displaystyle \mathbb {F} _{q}} ) can be thought of as polynomials with pole allowance no more than k {\displaystyle k} at the point at infinity in P F q 1 {\displaystyle \mathbb {P} _{\mathbb {F} _{q}}^{1}} . With this idea in mind, Goppa looked toward the Riemann–Roch theorem. The elements of a Riemann–Roch space are exactly those functions with pole order restricted below a given threshold, with the restriction being encoded in the coefficients of a corresponding divisor. Evaluating those functions at the rational points on an algebraic curve X {\displaystyle X} over F q {\displaystyle \mathbb {F} _{q}} (that is, the points in F q 2 {\displaystyle \mathbb {F} _{q}^{2}} on the curve X {\displaystyle X} ) gives a code in the same sense as the Reed-Solomon construction. However, because the parameters of algebraic geometry codes are connected to algebraic function fields, the definitions of the codes are often given in the language of algebraic function fields over finite fields. Nevertheless, it is important to remember the connection to algebraic curves, as this provides a more geometrically intuitive method of thinking about AG codes as extensions of Reed-Solomon codes. Formally, algebraic geometry codes are defined in the following way. Let F / F q {\displaystyle F/\mathbb {F} _{q}} be an algebraic function field, D = P 1 + ⋯ + P n {\displaystyle D=P_{1}+\dots +P_{n}} be the sum of n {\displaystyle n} distinct places of F / F q {\displaystyle F/\mathbb {F} _{q}} of degree one, and G {\displaystyle G} be a divisor with disjoint support from D {\displaystyle D} . The algebraic geometry code C L ( D , G ) {\displaystyle C_{\mathcal {L}}(D,G)} associated with divisors D {\displaystyle D} and G {\displaystyle G} is defined as C L ( D , G ) := { ( f ( P 1 ) , … , f ( P n ) ) : f ∈ L ( G ) } ⊆ F q n . {\displaystyle C_{\mathcal {L}}(D,G):=\lbrace (f(P_{1}),\dots ,f(P_{n})):f\in {\mathcal {L}}(G)\rbrace \subseteq \mathbb {F} _{q}^{n}.} More information on these codes may be found in both introductory texts as well as advanced texts on coding theory. == Examples == === Reed-Solomon codes === One can see that R S ( q , n , k ) = C L ( D , ( k − 1 ) P ∞ ) {\displaystyle RS(q,n,k)={\mathcal {C}}_{\mathcal {L}}(D,(k-1)P_{\infty })} where P ∞ {\displaystyle P_{\infty }} is the point at infinity on the projective line P F q 1 {\displaystyle \mathbb {P} _{\mathbb {F} _{q}}^{1}} and D = P 1 + ⋯ + P q {\displaystyle D=P_{1}+\dots +P_{q}} is the sum of the other F q {\displaystyle \mathbb {F} _{q}} -rational points. === One-point Hermitian codes === The Hermitian curve is given by the equation x q + 1 = y q + y {\displaystyle x^{q+1}=y^{q}+y} considered over the field F q 2 {\displaystyle \mathbb {F} _{q^{2}}} . This curve is of particular importance because it meets the Hasse–Weil bound with equality, and thus has the maximal number of affine points over F q 2 {\displaystyle \mathbb {F} _{q^{2}}} . With respect to algebraic geometry codes, this means that Hermitian codes are long relative to the alphabet they are defined over. The Riemann–Roch space of the Hermitian function field is given in the following statement. For the Hermitian function field F q 2 ( x , y ) {\displaystyle \mathbb {F} _{q^{2}}(x,y)} given by x q + 1 = y q + y {\displaystyle x^{q+1}=y^{q}+y} and for m ∈ Z + {\displaystyle m\in \mathbb {Z} ^{+}} , the Riemann–Roch space L ( m P ∞ ) {\displaystyle {\mathcal {L}}(mP_{\infty })} is L ( m P ∞ ) = ⟨ x a y b : 0 ≤ b ≤ q − 1 , a q + b ( q + 1 ) ≤ m ⟩ , {\displaystyle {\mathcal {L}}(mP_{\infty })=\left\langle x^{a}y^{b}:0\leq b\leq q-1,aq+b(q+1)\leq m\right\rangle ,} where P ∞ {\displaystyle P_{\infty }} is the point at infinity on H q ( F q 2 ) {\displaystyle {\mathcal {H}}_{q}(\mathbb {F} _{q^{2}})} . With that, the one-point Hermitian code can be defined in the following way. Let H q {\displaystyle {\mathcal {H}}_{q}} be the Hermitian curve defined over F q 2 {\displaystyle \mathbb {F} _{q^{2}}} . Let P ∞ {\displaystyle P_{\infty }} be the point at infinity on H q ( F q 2 ) {\displaystyle {\mathcal {H}}_{q}(\mathbb {F} _{q^{2}})} , and D = P 1 + ⋯ + P n {\displaystyle D=P_{1}+\cdots +P_{n}} be a divisor supported by the n := q 3 {\displaystyle n:=q^{3}} distinct F q 2 {\displaystyle \mathbb {F} _{q^{2}}} -rational points on H q {\displaystyle {\mathcal {H}}_{q}} other than P ∞ {\displaystyle P_{\infty }} . The one-point Hermitian code C ( D , m P ∞ ) {\displaystyle C(D,mP_{\infty })} is C ( D , m P ∞ ) := { ( f ( P 1 ) , … , f ( P n ) ) : f ∈ L ( m P ∞ ) } ⊆ F q 2 n . {\displaystyle C(D,mP_{\infty }):=\left\lbrace (f(P_{1}),\dots ,f(P_{n})):f\in {\mathcal {L}}(mP_{\infty })\right\rbrace \subseteq \mathbb {F} _{q^{2}}^{n}.} == References ==
Wikipedia/Algebraic_geometric_code
In cryptography, an adversary (rarely opponent, enemy) is an entity whose aim is to prevent the users of the cryptosystem from achieving their goal (primarily privacy, integrity, and availability of data), often with malicious intent. An adversary's efforts might take the form of attempting to discover secret data, corrupting some of the data in the system, spoofing the identity of a message sender or receiver, or forcing system downtime. Actual adversaries, as opposed to idealized ones, are referred to as attackers. The former term predominates in the cryptographic and the latter in the computer security literature. Eavesdropper Eve, malicious attacker Mallory, opponent Oscar, and intruder Trudy are all adversarial characters widely used in both types of texts. This notion of an adversary helps both intuitive and formal reasoning about cryptosystems by casting security analysis of cryptosystems as a 'game' between the users and a centrally co-ordinated enemy. The notion of security of a cryptosystem is meaningful only with respect to particular attacks (usually presumed to be carried out by particular sorts of adversaries). Adversaries can be divided into two main categories based on how they behave within protocols: passive and active. Passive adversaries (also known as semi-honest or honest-but-curious) are static adversaries that faithfully follow the protocol, but try to infer from the data they receive to gather more information than intended. Active adversaries (also known as malicious) are adversaries that may arbitrarily deviate from the protocol, often trying to disrupt its execution, steal data, inject false data, or cause damage. There are several types of adversaries depending on what capabilities or intentions they are presumed to have. Adversaries may be computationally bounded or unbounded (i.e. in terms of time and storage resources), eavesdropping or Byzantine (i.e. passively listening on or actively corrupting data in the channel), static or adaptive (i.e. having fixed or changing behavior), mobile or non-mobile (e.g. in the context of network security) and so on. In actual security practice, the attacks assigned to such adversaries are often seen, so such notional analysis is not merely theoretical. How successful an adversary is at breaking a system is measured by its advantage. An adversary's advantage is the difference between the adversary's probability of breaking the system and the probability that the system can be broken by simply guessing. The advantage is specified as a function of the security parameter. == See also == Threat model Operations security Concrete security == References ==
Wikipedia/Adversary_(cryptography)
Numerical methods for partial differential equations is the branch of numerical analysis that studies the numerical solution of partial differential equations (PDEs). In principle, specialized methods for hyperbolic, parabolic or elliptic partial differential equations exist. == Overview of methods == === Finite difference method === In this method, functions are represented by their values at certain grid points and derivatives are approximated through differences in these values. === Method of lines === The method of lines (MOL, NMOL, NUMOL) is a technique for solving partial differential equations (PDEs) in which all dimensions except one are discretized. MOL allows standard, general-purpose methods and software, developed for the numerical integration of ordinary differential equations (ODEs) and differential algebraic equations (DAEs), to be used. A large number of integration routines have been developed over the years in many different programming languages, and some have been published as open source resources. The method of lines most often refers to the construction or analysis of numerical methods for partial differential equations that proceeds by first discretizing the spatial derivatives only and leaving the time variable continuous. This leads to a system of ordinary differential equations to which a numerical method for initial value ordinary equations can be applied. The method of lines in this context dates back to at least the early 1960s. === Finite element method === The finite element method (FEM) is a numerical technique for finding approximate solutions to boundary value problems for differential equations. It uses variational methods (the calculus of variations) to minimize an error function and produce a stable solution. Analogous to the idea that connecting many tiny straight lines can approximate a larger circle, FEM encompasses all the methods for connecting many simple element equations over many small subdomains, named finite elements, to approximate a more complex equation over a larger domain. === Gradient discretization method === The gradient discretization method (GDM) is a numerical technique that encompasses a few standard or recent methods. It is based on the separate approximation of a function and of its gradient. Core properties allow the convergence of the method for a series of linear and nonlinear problems, and therefore all the methods that enter the GDM framework (conforming and nonconforming finite element, mixed finite element, mimetic finite difference...) inherit these convergence properties. === Finite volume method === The finite-volume method is a numerical technique for representing and evaluating partial differential equations in the form of algebraic equations [LeVeque, 2002; Toro, 1999]. Similar to the finite difference method or finite element method, values are calculated at discrete places on a meshed geometry. "Finite volume" refers to the small volume surrounding each node point on a mesh. In the finite volume method, volume integrals in a partial differential equation that contain a divergence term are converted to surface integrals, using the divergence theorem. These terms are then evaluated as fluxes at the surfaces of each finite volume. Because the flux entering a given volume is identical to that leaving the adjacent volume, these methods are conservative. Another advantage of the finite volume method is that it is easily formulated to allow for unstructured meshes. The method is used in many computational fluid dynamics packages. === Spectral method === Spectral methods are techniques used in applied mathematics and scientific computing to numerically solve certain differential equations, often involving the use of the fast Fourier transform. The idea is to write the solution of the differential equation as a sum of certain "basis functions" (for example, as a Fourier series, which is a sum of sinusoids) and then to choose the coefficients in the sum that best satisfy the differential equation. Spectral methods and finite element methods are closely related and built on the same ideas; the main difference between them is that spectral methods use basis functions that are nonzero over the whole domain, while finite element methods use basis functions that are nonzero only on small subdomains. In other words, spectral methods take on a global approach while finite element methods use a local approach. Partially for this reason, spectral methods have excellent error properties, with the so-called "exponential convergence" being the fastest possible, when the solution is smooth. However, there are no known three-dimensional single domain spectral shock capturing results. In the finite element community, a method where the degree of the elements is very high or increases as the grid parameter h decreases to zero is sometimes called a spectral element method. === Meshfree methods === Meshfree methods do not require a mesh connecting the data points of the simulation domain. Meshfree methods enable the simulation of some otherwise difficult types of problems, at the cost of extra computing time and programming effort. === Domain decomposition methods === Domain decomposition methods solve a boundary value problem by splitting it into smaller boundary value problems on subdomains and iterating to coordinate the solution between adjacent subdomains. A coarse problem with one or few unknowns per subdomain is used to further coordinate the solution between the subdomains globally. The problems on the subdomains are independent, which makes domain decomposition methods suitable for parallel computing. Domain decomposition methods are typically used as preconditioners for Krylov space iterative methods, such as the conjugate gradient method or GMRES. In overlapping domain decomposition methods, the subdomains overlap by more than the interface. Overlapping domain decomposition methods include the Schwarz alternating method and the additive Schwarz method. Many domain decomposition methods can be written and analyzed as a special case of the abstract additive Schwarz method. In non-overlapping methods, the subdomains intersect only on their interface. In primal methods, such as Balancing domain decomposition and BDDC, the continuity of the solution across subdomain interface is enforced by representing the value of the solution on all neighboring subdomains by the same unknown. In dual methods, such as FETI, the continuity of the solution across the subdomain interface is enforced by Lagrange multipliers. The FETI-DP method is hybrid between a dual and a primal method. Non-overlapping domain decomposition methods are also called iterative substructuring methods. Mortar methods are discretization methods for partial differential equations, which use separate discretization on nonoverlapping subdomains. The meshes on the subdomains do not match on the interface, and the equality of the solution is enforced by Lagrange multipliers, judiciously chosen to preserve the accuracy of the solution. In the engineering practice in the finite element method, continuity of solutions between non-matching subdomains is implemented by multiple-point constraints. Finite element simulations of moderate size models require solving linear systems with millions of unknowns. Several hours per time step is an average sequential run time, therefore, parallel computing is a necessity. Domain decomposition methods embody large potential for a parallelization of the finite element methods, and serve a basis for distributed, parallel computations. === Multigrid methods === Multigrid (MG) methods in numerical analysis are a group of algorithms for solving differential equations using a hierarchy of discretizations. They are an example of a class of techniques called multiresolution methods, very useful in (but not limited to) problems exhibiting multiple scales of behavior. For example, many basic relaxation methods exhibit different rates of convergence for short- and long-wavelength components, suggesting these different scales be treated differently, as in a Fourier analysis approach to multigrid. MG methods can be used as solvers as well as preconditioners. The main idea of multigrid is to accelerate the convergence of a basic iterative method by global correction from time to time, accomplished by solving a coarse problem. This principle is similar to interpolation between coarser and finer grids. The typical application for multigrid is in the numerical solution of elliptic partial differential equations in two or more dimensions. Multigrid methods can be applied in combination with any of the common discretization techniques. For example, the finite element method may be recast as a multigrid method. In these cases, multigrid methods are among the fastest solution techniques known today. In contrast to other methods, multigrid methods are general in that they can treat arbitrary regions and boundary conditions. They do not depend on the separability of the equations or other special properties of the equation. They have also been widely used for more-complicated non-symmetric and nonlinear systems of equations, like the Lamé system of elasticity or the Navier–Stokes equations. == Comparison == The finite difference method is often regarded as the simplest method to learn and use. The finite element and finite volume methods are widely used in engineering and in computational fluid dynamics, and are well suited to problems in complicated geometries. Spectral methods are generally the most accurate, provided that the solutions are sufficiently smooth. == See also == List of numerical analysis topics#Numerical methods for partial differential equations Numerical methods for ordinary differential equations == Further reading == LeVeque, Randall J. (1992). Numerical Methods for Conservation Laws. Basel: Birkhäuser Basel. doi:10.1007/978-3-0348-8629-1. ISBN 9783764327231. Retrieved 2021-11-15. Anderson, Dale A.; Pletcher, Richard H.; Tannehill, John C. (2013). Computational fluid mechanics and heat transfer. Series in computational and physical processes in mechanics and thermal sciences (3rd. ed.). Boca Raton: CRC Press, Taylor & Francis Group. ISBN 9781591690375. == References == == External links == Numerical Methods for Partial Differential Equations course at MIT OpenCourseWare. IMS, the Open Source IMTEK Mathematica Supplement (IMS) Numerical PDE Techniques for Scientists and Engineers, open access Lectures and Codes for Numerical PDEs
Wikipedia/Numerical_methods_for_partial_differential_equations
In theoretical physics, topological string theory is a version of string theory. Topological string theory appeared in papers by theoretical physicists, such as Edward Witten and Cumrun Vafa, by analogy with Witten's earlier idea of topological quantum field theory. == Overview == There are two main versions of topological string theory: the topological A-model and the topological B-model. The results of the calculations in topological string theory generically encode all holomorphic quantities within the full string theory whose values are protected by spacetime supersymmetry. Various calculations in topological string theory are closely related to Chern–Simons theory, Gromov–Witten invariants, mirror symmetry, geometric Langlands Program, and many other topics. The operators in topological string theory represent the algebra of operators in the full string theory that preserve a certain amount of supersymmetry. Topological string theory is obtained by a topological twist of the worldsheet description of ordinary string theory: the operators are given different spins. The operation is fully analogous to the construction of topological field theory which is a related concept. Consequently, there are no local degrees of freedom in topological string theory. == Admissible spacetimes == The fundamental strings of string theory are two-dimensional surfaces. A quantum field theory known as the N = (1,1) sigma model is defined on each surface. This theory consist of maps from the surface to a supermanifold. Physically the supermanifold is interpreted as spacetime and each map is interpreted as the embedding of the string in spacetime. Only special spacetimes admit topological strings. Classically, one must choose a spacetime such that the theory respects an additional pair of supersymmetries, making the spacetime an N = (2,2) sigma model. A particular case of this is if the spacetime is a Kähler manifold and the H-flux is identically equal to zero. Generalized Kähler manifolds can have a nontrivial H-flux. === Topological twist === Ordinary strings on special backgrounds are never topological. To make these strings topological, one needs to modify the sigma model via a procedure called a topological twist which was invented by Edward Witten in 1988. The central observation is that these theories have two U(1) symmetries known as R-symmetries, and the Lorentz symmetry may be modified by mixing rotations and R-symmetries. One may use either of the two R-symmetries, leading to two different theories, called the A model and the B model. After this twist, the action of the theory is BRST exact, and as a result the theory has no dynamics. Instead, all observables depend on the topology of a configuration. Such theories are known as topological theories. Classically this procedure is always possible. Quantum mechanically, the U(1) symmetries may be anomalous, making the twist impossible. For example, in the Kähler case with H = 0 the twist leading to the A-model is always possible but that leading to the B-model is only possible when the first Chern class of the spacetime vanishes, implying that the spacetime is Calabi–Yau. More generally (2,2) theories have two complex structures and the B model exists when the first Chern classes of associated bundles sum to zero whereas the A model exists when the difference of the Chern classes is zero. In the Kähler case the two complex structures are the same and so the difference is always zero, which is why the A model always exists. There is no restriction on the number of dimensions of spacetime, other than that it must be even because spacetime is generalized Kähler. However, all correlation functions with worldsheets that are not spheres vanish unless the complex dimension of the spacetime is three, and so spacetimes with complex dimension three are the most interesting. This is fortunate for phenomenology, as phenomenological models often use a physical string theory compactified on a 3 complex-dimensional space. The topological string theory is not equivalent to the physical string theory, even on the same space, but certain supersymmetric quantities agree in the two theories. == Objects == === A-model === The topological A-model comes with a target space which is a 6 real-dimensional generalized Kähler spacetime. In the case in which the spacetime is Kähler, the theory describes two objects. There are fundamental strings, which wrap two real-dimensional holomorphic curves. Amplitudes for the scattering of these strings depend only on the Kähler form of the spacetime, and not on the complex structure. Classically these correlation functions are determined by the cohomology ring. There are quantum mechanical instanton effects which correct these and yield Gromov–Witten invariants, which measure the cup product in a deformed cohomology ring called the quantum cohomology. The string field theory of the A-model closed strings is known as Kähler gravity, and was introduced by Michael Bershadsky and Vladimir Sadov in Theory of Kähler Gravity. In addition, there are D2-branes which wrap Lagrangian submanifolds of spacetime. These are submanifolds whose dimensions are one half that of space time, and such that the pullback of the Kähler form to the submanifold vanishes. The worldvolume theory on a stack of N D2-branes is the string field theory of the open strings of the A-model, which is a U(N) Chern–Simons theory. The fundamental topological strings may end on the D2-branes. While the embedding of a string depends only on the Kähler form, the embeddings of the branes depends entirely on the complex structure. In particular, when a string ends on a brane the intersection will always be orthogonal, as the wedge product of the Kähler form and the holomorphic 3-form is zero. In the physical string this is necessary for the stability of the configuration, but here it is a property of Lagrangian and holomorphic cycles on a Kahler manifold. There may also be coisotropic branes in various dimensions other than half dimensions of Lagrangian submanifolds. These were first introduced by Anton Kapustin and Dmitri Orlov in Remarks on A-Branes, Mirror Symmetry, and the Fukaya Category === B-model === The B-model also contains fundamental strings, but their scattering amplitudes depend entirely upon the complex structure and are independent of the Kähler structure. In particular, they are insensitive to worldsheet instanton effects and so can often be calculated exactly. Mirror symmetry then relates them to A model amplitudes, allowing one to compute Gromov–Witten invariants. The string field theory of the closed strings of the B-model is known as the Kodaira–Spencer theory of gravity and was developed by Michael Bershadsky, Sergio Cecotti, Hirosi Ooguri and Cumrun Vafa in Kodaira–Spencer Theory of Gravity and Exact Results for Quantum String Amplitudes. The B-model also comes with D(-1), D1, D3 and D5-branes, which wrap holomorphic 0, 2, 4 and 6-submanifolds respectively. The 6-submanifold is a connected component of the spacetime. The theory on a D5-brane is known as holomorphic Chern–Simons theory. The Lagrangian density is the wedge product of that of ordinary Chern–Simons theory with the holomorphic (3,0)-form, which exists in the Calabi–Yau case. The Lagrangian densities of the theories on the lower-dimensional branes may be obtained from holomorphic Chern–Simons theory by dimensional reductions. === Topological M-theory === Topological M-theory, which enjoys a seven-dimensional spacetime, is not a topological string theory, as it contains no topological strings. However topological M-theory on a circle bundle over a 6-manifold has been conjectured to be equivalent to the topological A-model on that 6-manifold. In particular, the D2-branes of the A-model lift to points at which the circle bundle degenerates, or more precisely Kaluza–Klein monopoles. The fundamental strings of the A-model lift to membranes named M2-branes in topological M-theory. One special case that has attracted much interest is topological M-theory on a space with G2 holonomy and the A-model on a Calabi–Yau. In this case, the M2-branes wrap associative 3-cycles. Strictly speaking, the topological M-theory conjecture has only been made in this context, as in this case functions introduced by Nigel Hitchin in The Geometry of Three-Forms in Six and Seven Dimensions and Stable Forms and Special Metrics provide a candidate low energy effective action. These functions are called "Hitchin functional" and Topological string is closely related to Hitchin's ideas on generalized complex structure, Hitchin system, and ADHM construction etc.. == Observables == === The topological twist === The 2-dimensional worldsheet theory is an N = (2,2) supersymmetric sigma model, the (2,2) supersymmetry means that the fermionic generators of the supersymmetry algebra, called supercharges, may be assembled into a single Dirac spinor, which consists of two Majorana–Weyl spinors of each chirality. This sigma model is topologically twisted, which means that the Lorentz symmetry generators that appear in the supersymmetry algebra simultaneously rotate the physical spacetime and also rotate the fermionic directions via the action of one of the R-symmetries. The R-symmetry group of a 2-dimensional N = (2,2) field theory is U(1) × U(1), twists by the two different factors lead to the A and B models respectively. The topological twisted construction of topological string theories was introduced by Edward Witten in his 1988 paper. === What do the correlators depend on? === The topological twist leads to a topological theory because the stress–energy tensor may be written as an anticommutator of a supercharge and another field. As the stress–energy tensor measures the dependence of the action on the metric tensor, this implies that all correlation functions of Q-invariant operators are independent of the metric. In this sense, the theory is topological. More generally, any D-term in the action, which is any term which may be expressed as an integral over all of superspace, is an anticommutator of a supercharge and so does not affect the topological observables. Yet more generally, in the B model any term which may be written as an integral over the fermionic θ ¯ ± {\displaystyle {\overline {\theta }}^{\pm }} coordinates does not contribute, whereas in the A-model any term which is an integral over θ − {\displaystyle \theta ^{-}} or over θ ¯ + {\displaystyle {\overline {\theta }}^{+}} does not contribute. This implies that A model observables are independent of the superpotential (as it may be written as an integral over just θ ¯ ± {\displaystyle {\overline {\theta }}^{\pm }} ) but depend holomorphically on the twisted superpotential, and vice versa for the B model. == Dualities == === Dualities between TSTs === A number of dualities relate the above theories. The A-model and B-model on two mirror manifolds are related by mirror symmetry, which has been described as a T-duality on a three-torus. The A-model and B-model on the same manifold are conjectured to be related by S-duality, which implies the existence of several new branes, called NS branes by analogy with the NS5-brane, which wrap the same cycles as the original branes but in the opposite theory. Also a combination of the A-model and a sum of the B-model and its conjugate are related to topological M-theory by a kind of dimensional reduction. Here the degrees of freedom of the A-model and the B-models appear to not be simultaneously observable, but rather to have a relation similar to that between position and momentum in quantum mechanics. ==== The holomorphic anomaly ==== The sum of the B-model and its conjugate appears in the above duality because it is the theory whose low energy effective action is expected to be described by Hitchin's formalism. This is because the B-model suffers from a holomorphic anomaly, which states that the dependence on complex quantities, while classically holomorphic, receives nonholomorphic quantum corrections. In Quantum Background Independence in String Theory, Edward Witten argued that this structure is analogous to a structure that one finds geometrically quantizing the space of complex structures. Once this space has been quantized, only half of the dimensions simultaneously commute and so the number of degrees of freedom has been halved. This halving depends on an arbitrary choice, called a polarization. The conjugate model contains the missing degrees of freedom, and so by tensoring the B-model and its conjugate one reobtains all of the missing degrees of freedom and also eliminates the dependence on the arbitrary choice of polarization. === Geometric transitions === There are also a number of dualities that relate configurations with D-branes, which are described by open strings, to those with branes the branes replaced by flux and with the geometry described by the near-horizon geometry of the lost branes. The latter are described by closed strings. Perhaps the first such duality is the Gopakumar–Vafa duality, which was introduced by Rajesh Gopakumar and Cumrun Vafa in On the Gauge Theory/Geometry Correspondence. This relates a stack of N D6-branes on a 3-sphere in the A-model on the deformed conifold to the closed string theory of the A-model on a resolved conifold with a B field equal to N times the string coupling constant. The open strings in the A model are described by a U(N) Chern–Simons theory, while the closed string theory on the A-model is described by the Kähler gravity. Although the conifold is said to be resolved, the area of the blown up two-sphere is zero, it is only the B-field, which is often considered to be the complex part of the area, which is nonvanishing. In fact, as the Chern–Simons theory is topological, one may shrink the volume of the deformed three-sphere to zero and so arrive at the same geometry as in the dual theory. The mirror dual of this duality is another duality, which relates open strings in the B model on a brane wrapping the 2-cycle in the resolved conifold to closed strings in the B model on the deformed conifold. Open strings in the B-model are described by dimensional reductions of homolomorphic Chern–Simons theory on the branes on which they end, while closed strings in the B model are described by Kodaira–Spencer gravity. === Dualities with other theories === ==== Crystal melting, quantum foam and U(1) gauge theory ==== In the paper Quantum Calabi–Yau and Classical Crystals, Andrei Okounkov, Nicolai Reshetikhin and Cumrun Vafa conjectured that the quantum A-model is dual to a classical melting crystal at a temperature equal to the inverse of the string coupling constant. This conjecture was interpreted in Quantum Foam and Topological Strings, by Amer Iqbal, Nikita Nekrasov, Andrei Okounkov and Cumrun Vafa. They claim that the statistical sum over melting crystal configurations is equivalent to a path integral over changes in spacetime topology supported in small regions with area of order the product of the string coupling constant and α'. Such configurations, with spacetime full of many small bubbles, dates back to John Archibald Wheeler in 1964, but has rarely appeared in string theory as it is notoriously difficult to make precise. However in this duality the authors are able to cast the dynamics of the quantum foam in the familiar language of a topologically twisted U(1) gauge theory, whose field strength is linearly related to the Kähler form of the A-model. In particular this suggests that the A-model Kähler form should be quantized. == Applications == A-model topological string theory amplitudes are used to compute prepotentials in N=2 supersymmetric gauge theories in four and five dimensions. The amplitudes of the topological B-model, with fluxes and or branes, are used to compute superpotentials in N=1 supersymmetric gauge theories in four dimensions. Perturbative A model calculations also count BPS states of spinning black holes in five dimensions. == See also == Quantum topology Topological defect Topological entropy in physics Topological order Topological quantum field theory Topological quantum number Introduction to M-theory == References == Neitzke, Andrew; Vafa, Cumrun (2004). "Topological strings and their physical applications". arXiv:hep-th/0410178. Dijkgraaf, Robbert; Gukov, Sergei; Neitzke, Andrew; Vafa, Cumrun (2005). "Topological M-theory as Unification of Form Theories of Gravity". Adv. Theor. Math. Phys. 9 (4): 603–665. arXiv:hep-th/0411073. Bibcode:2004hep.th...11073D. doi:10.4310/ATMP.2005.v9.n4.a5. S2CID 1204839. Topological string theory on arxiv.org Naqvi, Asad (2006). "Topological Strings" (PDF-Microsoft PowerPoint). Asad Naqvi - University of Wales, Swansea, United Kingdom. National Center for Physics.
Wikipedia/Topological_string_theory
In quantum mechanics, perturbation theory is a set of approximation schemes directly related to mathematical perturbation for describing a complicated quantum system in terms of a simpler one. The idea is to start with a simple system for which a mathematical solution is known, and add an additional "perturbing" Hamiltonian representing a weak disturbance to the system. If the disturbance is not too large, the various physical quantities associated with the perturbed system (e.g. its energy levels and eigenstates) can be expressed as "corrections" to those of the simple system. These corrections, being small compared to the size of the quantities themselves, can be calculated using approximate methods such as asymptotic series. The complicated system can therefore be studied based on knowledge of the simpler one. In effect, it is describing a complicated unsolved system using a simple, solvable system. == Approximate Hamiltonians == Perturbation theory is an important tool for describing real quantum systems, as it turns out to be very difficult to find exact solutions to the Schrödinger equation for Hamiltonians of even moderate complexity. The Hamiltonians to which we know exact solutions, such as the hydrogen atom, the quantum harmonic oscillator and the particle in a box, are too idealized to adequately describe most systems. Using perturbation theory, we can use the known solutions of these simple Hamiltonians to generate solutions for a range of more complicated systems. == Applying perturbation theory == Perturbation theory is applicable if the problem at hand cannot be solved exactly, but can be formulated by adding a "small" term to the mathematical description of the exactly solvable problem. For example, by adding a perturbative electric potential to the quantum mechanical model of the hydrogen atom, tiny shifts in the spectral lines of hydrogen caused by the presence of an electric field (the Stark effect) can be calculated. This is only approximate because the sum of a Coulomb potential with a linear potential is unstable (has no true bound states) although the tunneling time (decay rate) is very long. This instability shows up as a broadening of the energy spectrum lines, which perturbation theory fails to reproduce entirely. The expressions produced by perturbation theory are not exact, but they can lead to accurate results as long as the expansion parameter, say α, is very small. Typically, the results are expressed in terms of finite power series in α that seem to converge to the exact values when summed to higher order. After a certain order n ~ 1/α however, the results become increasingly worse since the series are usually divergent (being asymptotic series). There exist ways to convert them into convergent series, which can be evaluated for large-expansion parameters, most efficiently by the variational method. In practice, convergent perturbation expansions often converge slowly while divergent perturbation expansions sometimes give good results, c.f. the exact solution, at lower order. In the theory of quantum electrodynamics (QED), in which the electron–photon interaction is treated perturbatively, the calculation of the electron's magnetic moment has been found to agree with experiment to eleven decimal places. In QED and other quantum field theories, special calculation techniques known as Feynman diagrams are used to systematically sum the power series terms. === Limitations === ==== Large perturbations ==== Under some circumstances, perturbation theory is an invalid approach to take. This happens when the system we wish to describe cannot be described by a small perturbation imposed on some simple system. In quantum chromodynamics, for instance, the interaction of quarks with the gluon field cannot be treated perturbatively at low energies because the coupling constant (the expansion parameter) becomes too large, violating the requirement that corrections must be small. ==== Non-adiabatic states ==== Perturbation theory also fails to describe states that are not generated adiabatically from the "free model", including bound states and various collective phenomena such as solitons. Imagine, for example, that we have a system of free (i.e. non-interacting) particles, to which an attractive interaction is introduced. Depending on the form of the interaction, this may create an entirely new set of eigenstates corresponding to groups of particles bound to one another. An example of this phenomenon may be found in conventional superconductivity, in which the phonon-mediated attraction between conduction electrons leads to the formation of correlated electron pairs known as Cooper pairs. When faced with such systems, one usually turns to other approximation schemes, such as the variational method and the WKB approximation. This is because there is no analogue of a bound particle in the unperturbed model and the energy of a soliton typically goes as the inverse of the expansion parameter. However, if we "integrate" over the solitonic phenomena, the nonperturbative corrections in this case will be tiny; of the order of exp(−1/g) or exp(−1/g2) in the perturbation parameter g. Perturbation theory can only detect solutions "close" to the unperturbed solution, even if there are other solutions for which the perturbative expansion is not valid. ==== Difficult computations ==== The problem of non-perturbative systems has been somewhat alleviated by the advent of modern computers. It has become practical to obtain numerical non-perturbative solutions for certain problems, using methods such as density functional theory. These advances have been of particular benefit to the field of quantum chemistry. Computers have also been used to carry out perturbation theory calculations to extraordinarily high levels of precision, which has proven important in particle physics for generating theoretical results that can be compared with experiment. == Time-independent perturbation theory == Time-independent perturbation theory is one of two categories of perturbation theory, the other being time-dependent perturbation (see next section). In time-independent perturbation theory, the perturbation Hamiltonian is static (i.e., possesses no time dependence). Time-independent perturbation theory was presented by Erwin Schrödinger in a 1926 paper, shortly after he produced his theories in wave mechanics. In this paper Schrödinger referred to earlier work of Lord Rayleigh, who investigated harmonic vibrations of a string perturbed by small inhomogeneities. This is why this perturbation theory is often referred to as Rayleigh–Schrödinger perturbation theory. === First order corrections === The process begins with an unperturbed Hamiltonian H0, which is assumed to have no time dependence. It has known energy levels and eigenstates, arising from the time-independent Schrödinger equation: H 0 | n ( 0 ) ⟩ = E n ( 0 ) | n ( 0 ) ⟩ , n = 1 , 2 , 3 , ⋯ {\displaystyle H_{0}\left|n^{(0)}\right\rangle =E_{n}^{(0)}\left|n^{(0)}\right\rangle ,\qquad n=1,2,3,\cdots } For simplicity, it is assumed that the energies are discrete. The (0) superscripts denote that these quantities are associated with the unperturbed system. Note the use of bra–ket notation. A perturbation is then introduced to the Hamiltonian. Let V be a Hamiltonian representing a weak physical disturbance, such as a potential energy produced by an external field. Thus, V is formally a Hermitian operator. Let λ be a dimensionless parameter that can take on values ranging continuously from 0 (no perturbation) to 1 (the full perturbation). The perturbed Hamiltonian is: H = H 0 + λ V {\displaystyle H=H_{0}+\lambda V} The energy levels and eigenstates of the perturbed Hamiltonian are again given by the time-independent Schrödinger equation, ( H 0 + λ V ) | n ⟩ = E n | n ⟩ . {\displaystyle \left(H_{0}+\lambda V\right)|n\rangle =E_{n}|n\rangle .} The objective is to express En and | n ⟩ {\displaystyle |n\rangle } in terms of the energy levels and eigenstates of the old Hamiltonian. If the perturbation is sufficiently weak, they can be written as a (Maclaurin) power series in λ, E n = E n ( 0 ) + λ E n ( 1 ) + λ 2 E n ( 2 ) + ⋯ | n ⟩ = | n ( 0 ) ⟩ + λ | n ( 1 ) ⟩ + λ 2 | n ( 2 ) ⟩ + ⋯ {\displaystyle {\begin{aligned}E_{n}&=E_{n}^{(0)}+\lambda E_{n}^{(1)}+\lambda ^{2}E_{n}^{(2)}+\cdots \\[1ex]|n\rangle &=\left|n^{(0)}\right\rangle +\lambda \left|n^{(1)}\right\rangle +\lambda ^{2}\left|n^{(2)}\right\rangle +\cdots \end{aligned}}} where E n ( k ) = 1 k ! d k E n d λ k | λ = 0 | n ( k ) ⟩ = 1 k ! d k | n ⟩ d λ k | λ = 0. {\displaystyle {\begin{aligned}E_{n}^{(k)}&={\frac {1}{k!}}{\frac {d^{k}E_{n}}{d\lambda ^{k}}}{\bigg |}_{\lambda =0}\\[1ex]\left|n^{(k)}\right\rangle &=\left.{\frac {1}{k!}}{\frac {d^{k}|n\rangle }{d\lambda ^{k}}}\right|_{\lambda =0.}\end{aligned}}} When k = 0, these reduce to the unperturbed values, which are the first term in each series. Since the perturbation is weak, the energy levels and eigenstates should not deviate too much from their unperturbed values, and the terms should rapidly become smaller as the order is increased. Substituting the power series expansion into the Schrödinger equation produces: ( H 0 + λ V ) ( | n ( 0 ) ⟩ + λ | n ( 1 ) ⟩ + ⋯ ) = ( E n ( 0 ) + λ E n ( 1 ) + ⋯ ) ( | n ( 0 ) ⟩ + λ | n ( 1 ) ⟩ + ⋯ ) . {\displaystyle \left(H_{0}+\lambda V\right)\left(\left|n^{(0)}\right\rangle +\lambda \left|n^{(1)}\right\rangle +\cdots \right)=\left(E_{n}^{(0)}+\lambda E_{n}^{(1)}+\cdots \right)\left(\left|n^{(0)}\right\rangle +\lambda \left|n^{(1)}\right\rangle +\cdots \right).} Expanding this equation and comparing coefficients of each power of λ results in an infinite series of simultaneous equations. The zeroth-order equation is simply the Schrödinger equation for the unperturbed system, H 0 | n ( 0 ) ⟩ = E n ( 0 ) | n ( 0 ) ⟩ . {\displaystyle H_{0}\left|n^{(0)}\right\rangle =E_{n}^{(0)}\left|n^{(0)}\right\rangle .} The first-order equation is H 0 | n ( 1 ) ⟩ + V | n ( 0 ) ⟩ = E n ( 0 ) | n ( 1 ) ⟩ + E n ( 1 ) | n ( 0 ) ⟩ . {\displaystyle H_{0}\left|n^{(1)}\right\rangle +V\left|n^{(0)}\right\rangle =E_{n}^{(0)}\left|n^{(1)}\right\rangle +E_{n}^{(1)}\left|n^{(0)}\right\rangle .} Operating through by ⟨ n ( 0 ) | {\displaystyle \langle n^{(0)}|} , the first term on the left-hand side cancels the first term on the right-hand side. (Recall, the unperturbed Hamiltonian is Hermitian). This leads to the first-order energy shift, E n ( 1 ) = ⟨ n ( 0 ) | V | n ( 0 ) ⟩ . {\displaystyle E_{n}^{(1)}=\left\langle n^{(0)}\right|V\left|n^{(0)}\right\rangle .} This is simply the expectation value of the perturbation Hamiltonian while the system is in the unperturbed eigenstate. This result can be interpreted in the following way: supposing that the perturbation is applied, but the system is kept in the quantum state | n ( 0 ) ⟩ {\displaystyle |n^{(0)}\rangle } , which is a valid quantum state though no longer an energy eigenstate. The perturbation causes the average energy of this state to increase by ⟨ n ( 0 ) | V | n ( 0 ) ⟩ {\displaystyle \langle n^{(0)}|V|n^{(0)}\rangle } . However, the true energy shift is slightly different, because the perturbed eigenstate is not exactly the same as | n ( 0 ) ⟩ {\displaystyle |n^{(0)}\rangle } . These further shifts are given by the second and higher order corrections to the energy. Before corrections to the energy eigenstate are computed, the issue of normalization must be addressed. Supposing that ⟨ n ( 0 ) | n ( 0 ) ⟩ = 1 , {\displaystyle \left\langle n^{(0)}\right|\left.n^{(0)}\right\rangle =1,} but perturbation theory also assumes that ⟨ n | n ⟩ = 1 {\displaystyle \langle n|n\rangle =1} . Then at first order in λ, the following must be true: ( ⟨ n ( 0 ) | + λ ⟨ n ( 1 ) | ) ( | n ( 0 ) ⟩ + λ | n ( 1 ) ⟩ ) = 1 {\displaystyle \left(\left\langle n^{(0)}\right|+\lambda \left\langle n^{(1)}\right|\right)\left(\left|n^{(0)}\right\rangle +\lambda \left|n^{(1)}\right\rangle \right)=1} ⟨ n ( 0 ) | n ( 0 ) ⟩ + λ ⟨ n ( 0 ) | n ( 1 ) ⟩ + λ ⟨ n ( 1 ) | n ( 0 ) ⟩ + λ 2 ⟨ n ( 1 ) | n ( 1 ) ⟩ = 1 {\displaystyle \left\langle n^{(0)}\right|\left.n^{(0)}\right\rangle +\lambda \left\langle n^{(0)}\right|\left.n^{(1)}\right\rangle +\lambda \left\langle n^{(1)}\right|\left.n^{(0)}\right\rangle +{\cancel {\lambda ^{2}\left\langle n^{(1)}\right|\left.n^{(1)}\right\rangle }}=1} ⟨ n ( 0 ) | n ( 1 ) ⟩ + ⟨ n ( 1 ) | n ( 0 ) ⟩ = 0. {\displaystyle \left\langle n^{(0)}\right|\left.n^{(1)}\right\rangle +\left\langle n^{(1)}\right|\left.n^{(0)}\right\rangle =0.} Since the overall phase is not determined in quantum mechanics, without loss of generality, in time-independent theory it can be assumed that ⟨ n ( 0 ) | n ( 1 ) ⟩ {\displaystyle \langle n^{(0)}|n^{(1)}\rangle } is purely real. Therefore, ⟨ n ( 0 ) | n ( 1 ) ⟩ = ⟨ n ( 1 ) | n ( 0 ) ⟩ = − ⟨ n ( 1 ) | n ( 0 ) ⟩ , {\displaystyle \left\langle n^{(0)}\right|\left.n^{(1)}\right\rangle =\left\langle n^{(1)}\right|\left.n^{(0)}\right\rangle =-\left\langle n^{(1)}\right|\left.n^{(0)}\right\rangle ,} leading to ⟨ n ( 0 ) | n ( 1 ) ⟩ = 0. {\displaystyle \left\langle n^{(0)}\right|\left.n^{(1)}\right\rangle =0.} To obtain the first-order correction to the energy eigenstate, the expression for the first-order energy correction is inserted back into the result shown above, equating the first-order coefficients of λ. Then by using the resolution of the identity: V | n ( 0 ) ⟩ = ( ∑ k ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | ) V | n ( 0 ) ⟩ + ( | n ( 0 ) ⟩ ⟨ n ( 0 ) | ) V | n ( 0 ) ⟩ = ∑ k ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | n ( 0 ) ⟩ + E n ( 1 ) | n ( 0 ) ⟩ , {\displaystyle {\begin{aligned}V\left|n^{(0)}\right\rangle &=\left(\sum _{k\neq n}\left|k^{(0)}\right\rangle \left\langle k^{(0)}\right|\right)V\left|n^{(0)}\right\rangle +\left(\left|n^{(0)}\right\rangle \left\langle n^{(0)}\right|\right)V\left|n^{(0)}\right\rangle \\&=\sum _{k\neq n}\left|k^{(0)}\right\rangle \left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle +E_{n}^{(1)}\left|n^{(0)}\right\rangle ,\end{aligned}}} where the | k ( 0 ) ⟩ {\displaystyle |k^{(0)}\rangle } are in the orthogonal complement of | n ( 0 ) ⟩ {\displaystyle |n^{(0)}\rangle } , i.e., the other eigenvectors. The first-order equation may thus be expressed as ( E n ( 0 ) − H 0 ) | n ( 1 ) ⟩ = ∑ k ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | n ( 0 ) ⟩ . {\displaystyle \left(E_{n}^{(0)}-H_{0}\right)\left|n^{(1)}\right\rangle =\sum _{k\neq n}\left|k^{(0)}\right\rangle \left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle .} Suppose that the zeroth-order energy level is not degenerate, i.e. that there is no eigenstate of H0 in the orthogonal complement of | n ( 0 ) ⟩ {\displaystyle |n^{(0)}\rangle } with the energy E n ( 0 ) {\displaystyle E_{n}^{(0)}} . After renaming the summation dummy index above as k ′ {\displaystyle k'} , any k ≠ n {\displaystyle k\neq n} can be chosen and multiplying the first-order equation through by ⟨ k ( 0 ) | {\displaystyle \langle k^{(0)}|} gives ( E n ( 0 ) − E k ( 0 ) ) ⟨ k ( 0 ) | n ( 1 ) ⟩ = ⟨ k ( 0 ) | V | n ( 0 ) ⟩ . {\displaystyle \left(E_{n}^{(0)}-E_{k}^{(0)}\right)\left\langle k^{(0)}\right.\left|n^{(1)}\right\rangle =\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle .} The above ⟨ k ( 0 ) | n ( 1 ) ⟩ {\displaystyle \langle k^{(0)}|n^{(1)}\rangle } also gives us the component of the first-order correction along | k ( 0 ) ⟩ {\displaystyle |k^{(0)}\rangle } . Thus, in total, the result is, | n ( 1 ) ⟩ = ∑ k ≠ n ⟨ k ( 0 ) | V | n ( 0 ) ⟩ E n ( 0 ) − E k ( 0 ) | k ( 0 ) ⟩ . {\displaystyle \left|n^{(1)}\right\rangle =\sum _{k\neq n}{\frac {\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle }{E_{n}^{(0)}-E_{k}^{(0)}}}\left|k^{(0)}\right\rangle .} The first-order change in the n-th energy eigenket has a contribution from each of the energy eigenstates k ≠ n. Each term is proportional to the matrix element ⟨ k ( 0 ) | V | n ( 0 ) ⟩ {\displaystyle \langle k^{(0)}|V|n^{(0)}\rangle } , which is a measure of how much the perturbation mixes eigenstate n with eigenstate k; it is also inversely proportional to the energy difference between eigenstates k and n, which means that the perturbation deforms the eigenstate to a greater extent if there are more eigenstates at nearby energies. The expression is singular if any of these states have the same energy as state n, which is why it was assumed that there is no degeneracy. The above formula for the perturbed eigenstates also implies that the perturbation theory can be legitimately used only when the absolute magnitude of the matrix elements of the perturbation is small compared with the corresponding differences in the unperturbed energy levels, i.e., | ⟨ k ( 0 ) | V | n ( 0 ) ⟩ | ≪ | E n ( 0 ) − E k ( 0 ) | . {\displaystyle |\langle k^{(0)}|V|n^{(0)}\rangle |\ll |E_{n}^{(0)}-E_{k}^{(0)}|.} === Second-order and higher-order corrections === We can find the higher-order deviations by a similar procedure, though the calculations become quite tedious with our current formulation. Our normalization prescription gives that 2 ⟨ n ( 0 ) | n ( 2 ) ⟩ + ⟨ n ( 1 ) | n ( 1 ) ⟩ = 0. {\displaystyle 2\left\langle n^{(0)}\right|\left.n^{(2)}\right\rangle +\left\langle n^{(1)}\right|\left.n^{(1)}\right\rangle =0.} Up to second order, the expressions for the energies and (normalized) eigenstates are: E n ( λ ) = E n ( 0 ) + λ ⟨ n ( 0 ) | V | n ( 0 ) ⟩ + λ 2 ∑ k ≠ n | ⟨ k ( 0 ) | V | n ( 0 ) ⟩ | 2 E n ( 0 ) − E k ( 0 ) + O ( λ 3 ) {\displaystyle E_{n}(\lambda )=E_{n}^{(0)}+\lambda \left\langle n^{(0)}\right|V\left|n^{(0)}\right\rangle +\lambda ^{2}\sum _{k\neq n}{\frac {\left|\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle \right|^{2}}{E_{n}^{(0)}-E_{k}^{(0)}}}+O(\lambda ^{3})} | n ( λ ) ⟩ = | n ( 0 ) ⟩ + λ ∑ k ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | n ( 0 ) ⟩ E n ( 0 ) − E k ( 0 ) + λ 2 ∑ k ≠ n ∑ ℓ ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | ℓ ( 0 ) ⟩ ⟨ ℓ ( 0 ) | V | n ( 0 ) ⟩ ( E n ( 0 ) − E k ( 0 ) ) ( E n ( 0 ) − E ℓ ( 0 ) ) − λ 2 ∑ k ≠ n | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | n ( 0 ) ⟩ ⟨ n ( 0 ) | V | n ( 0 ) ⟩ ( E n ( 0 ) − E k ( 0 ) ) 2 − 1 2 λ 2 | n ( 0 ) ⟩ ∑ k ≠ n | ⟨ k ( 0 ) | V | n ( 0 ) ⟩ | 2 ( E n ( 0 ) − E k ( 0 ) ) 2 + O ( λ 3 ) . {\displaystyle {\begin{aligned}|n(\lambda )\rangle =\left|n^{(0)}\right\rangle &+\lambda \sum _{k\neq n}\left|k^{(0)}\right\rangle {\frac {\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle }{E_{n}^{(0)}-E_{k}^{(0)}}}+\lambda ^{2}\sum _{k\neq n}\sum _{\ell \neq n}\left|k^{(0)}\right\rangle {\frac {\left\langle k^{(0)}\right|V\left|\ell ^{(0)}\right\rangle \left\langle \ell ^{(0)}\right|V\left|n^{(0)}\right\rangle }{\left(E_{n}^{(0)}-E_{k}^{(0)}\right)\left(E_{n}^{(0)}-E_{\ell }^{(0)}\right)}}\\[1ex]&-\lambda ^{2}\sum _{k\neq n}\left|k^{(0)}\right\rangle {\frac {\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle \left\langle n^{(0)}\right|V\left|n^{(0)}\right\rangle }{\left(E_{n}^{(0)}-E_{k}^{(0)}\right)^{2}}}-{\frac {1}{2}}\lambda ^{2}\left|n^{(0)}\right\rangle \sum _{k\neq n}{\frac {|\left\langle k^{(0)}\right|V\left|n^{(0)}\right\rangle |^{2}}{\left(E_{n}^{(0)}-E_{k}^{(0)}\right)^{2}}}+O(\lambda ^{3}).\end{aligned}}} If an intermediate normalization is taken (in other words, if it is required that ⟨ n ( 0 ) | n ( λ ) ⟩ = 1 {\displaystyle \langle n^{(0)}|n(\lambda )\rangle =1} ), then we obtain a nearly identical expression for the second-order correction to the correction given immediately above. To be precise, for an intermediate normalization, the last term would be omitted. Extending the process further, the third-order energy correction can be shown to be E n ( 3 ) = ∑ k ≠ n ∑ m ≠ n ⟨ n ( 0 ) | V | m ( 0 ) ⟩ ⟨ m ( 0 ) | V | k ( 0 ) ⟩ ⟨ k ( 0 ) | V | n ( 0 ) ⟩ ( E n ( 0 ) − E m ( 0 ) ) ( E n ( 0 ) − E k ( 0 ) ) − ⟨ n ( 0 ) | V | n ( 0 ) ⟩ ∑ m ≠ n | ⟨ n ( 0 ) | V | m ( 0 ) ⟩ | 2 ( E n ( 0 ) − E m ( 0 ) ) 2 . {\displaystyle E_{n}^{(3)}=\sum _{k\neq n}\sum _{m\neq n}{\frac {\langle n^{(0)}|V|m^{(0)}\rangle \langle m^{(0)}|V|k^{(0)}\rangle \langle k^{(0)}|V|n^{(0)}\rangle }{\left(E_{n}^{(0)}-E_{m}^{(0)}\right)\left(E_{n}^{(0)}-E_{k}^{(0)}\right)}}-\langle n^{(0)}|V|n^{(0)}\rangle \sum _{m\neq n}{\frac {|\langle n^{(0)}|V|m^{(0)}\rangle |^{2}}{\left(E_{n}^{(0)}-E_{m}^{(0)}\right)^{2}}}.} It is possible to relate the k-th order correction to the energy En to the k-point connected correlation function of the perturbation V in the state | n ( 0 ) ⟩ {\displaystyle |n^{(0)}\rangle } . For k = 2 {\displaystyle k=2} , one has to consider the inverse Laplace transform ρ n , 2 ( s ) {\displaystyle \rho _{n,2}(s)} of the two-point correlator: ⟨ n ( 0 ) | V ( τ ) V ( 0 ) | n ( 0 ) ⟩ − ⟨ n ( 0 ) | V | n ( 0 ) ⟩ 2 = : ∫ R d s ρ n , 2 ( s ) e − ( s − E n ( 0 ) ) τ {\displaystyle \langle n^{(0)}|V(\tau )V(0)|n^{(0)}\rangle -\langle n^{(0)}|V|n^{(0)}\rangle ^{2}=\mathrel {\mathop {:} } \int _{\mathbb {R} }\!ds\;\rho _{n,2}(s)\,e^{-(s-E_{n}^{(0)})\tau }} where V ( τ ) = e H 0 τ V e − H 0 τ {\displaystyle V(\tau )=e^{H_{0}\tau }Ve^{-H_{0}\tau }} is the perturbing operator V in the interaction picture, evolving in Euclidean time. Then E n ( 2 ) = − ∫ R d s s − E n ( 0 ) ρ n , 2 ( s ) . {\displaystyle E_{n}^{(2)}=-\int _{\mathbb {R} }\!{\frac {ds}{s-E_{n}^{(0)}}}\,\rho _{n,2}(s).} Similar formulas exist to all orders in perturbation theory, allowing one to express E n ( k ) {\displaystyle E_{n}^{(k)}} in terms of the inverse Laplace transform ρ n , k {\displaystyle \rho _{n,k}} of the connected correlation function ⟨ n ( 0 ) | V ( τ 1 + … + τ k − 1 ) ⋯ V ( τ 1 + τ 2 ) V ( τ 1 ) V ( 0 ) | n ( 0 ) ⟩ conn = ⟨ n ( 0 ) | V ( τ 1 + … + τ k − 1 ) ⋯ V ( τ 1 + τ 2 ) V ( τ 1 ) V ( 0 ) | n ( 0 ) ⟩ − subtractions . {\displaystyle \langle n^{(0)}|V(\tau _{1}+\ldots +\tau _{k-1})\dotsm V(\tau _{1}+\tau _{2})V(\tau _{1})V(0)|n^{(0)}\rangle _{\text{conn}}=\langle n^{(0)}|V(\tau _{1}+\ldots +\tau _{k-1})\dotsm V(\tau _{1}+\tau _{2})V(\tau _{1})V(0)|n^{(0)}\rangle -{\text{subtractions}}.} To be precise, if we write ⟨ n ( 0 ) | V ( τ 1 + … + τ k − 1 ) ⋯ V ( τ 1 + τ 2 ) V ( τ 1 ) V ( 0 ) | n ( 0 ) ⟩ conn = ∫ R ∏ i = 1 k − 1 d s i e − ( s i − E n ( 0 ) ) τ i ρ n , k ( s 1 , … , s k − 1 ) {\displaystyle \langle n^{(0)}|V(\tau _{1}+\ldots +\tau _{k-1})\dotsm V(\tau _{1}+\tau _{2})V(\tau _{1})V(0)|n^{(0)}\rangle _{\text{conn}}=\int _{\mathbb {R} }\,\prod _{i=1}^{k-1}ds_{i}\,e^{-(s_{i}-E_{n}^{(0)})\tau _{i}}\,\rho _{n,k}(s_{1},\ldots ,s_{k-1})\,} then the k-th order energy shift is given by E n ( k ) = ( − 1 ) k − 1 ∫ R ∏ i = 1 k − 1 d s i s i − E n ( 0 ) ρ n , k ( s 1 , … , s k − 1 ) . {\displaystyle E_{n}^{(k)}=(-1)^{k-1}\int _{\mathbb {R} }\,\prod _{i=1}^{k-1}{\frac {ds_{i}}{s_{i}-E_{n}^{(0)}}}\,\rho _{n,k}(s_{1},\ldots ,s_{k-1}).} === Effects of degeneracy === Suppose that two or more energy eigenstates of the unperturbed Hamiltonian are degenerate. The first-order energy shift is not well defined, since there is no unique way to choose a basis of eigenstates for the unperturbed system. The various eigenstates for a given energy will perturb with different energies, or may well possess no continuous family of perturbations at all. This is manifested in the calculation of the perturbed eigenstate via the fact that the operator E n ( 0 ) − H 0 {\displaystyle E_{n}^{(0)}-H_{0}} does not have a well-defined inverse. Let D denote the subspace spanned by these degenerate eigenstates. No matter how small the perturbation is, in the degenerate subspace D the energy differences between the eigenstates of H are non-zero, so complete mixing of at least some of these states is assured. Typically, the eigenvalues will split, and the eigenspaces will become simple (one-dimensional), or at least of smaller dimension than D. The successful perturbations will not be "small" relative to a poorly chosen basis of D. Instead, we consider the perturbation "small" if the new eigenstate is close to the subspace D. The new Hamiltonian must be diagonalized in D, or a slight variation of D, so to speak. These perturbed eigenstates in D are now the basis for the perturbation expansion, | n ⟩ = ∑ k ∈ D α n k | k ( 0 ) ⟩ + λ | n ( 1 ) ⟩ . {\displaystyle |n\rangle =\sum _{k\in D}\alpha _{nk}|k^{(0)}\rangle +\lambda |n^{(1)}\rangle .} For the first-order perturbation, we need solve the perturbed Hamiltonian restricted to the degenerate subspace D, V | k ( 0 ) ⟩ = ϵ k | k ( 0 ) ⟩ + small ∀ | k ( 0 ) ⟩ ∈ D , {\displaystyle V|k^{(0)}\rangle =\epsilon _{k}|k^{(0)}\rangle +{\text{small}}\qquad \forall |k^{(0)}\rangle \in D,} simultaneously for all the degenerate eigenstates, where ϵ k {\displaystyle \epsilon _{k}} are first-order corrections to the degenerate energy levels, and "small" is a vector of O ( λ ) {\displaystyle O(\lambda )} orthogonal to D. This amounts to diagonalizing the matrix ⟨ k ( 0 ) | V | l ( 0 ) ⟩ = V k l ∀ | k ( 0 ) ⟩ , | l ( 0 ) ⟩ ∈ D . {\displaystyle \langle k^{(0)}|V|l^{(0)}\rangle =V_{kl}\qquad \forall \;|k^{(0)}\rangle ,|l^{(0)}\rangle \in D.} This procedure is approximate, since we neglected states outside the D subspace ("small"). The splitting of degenerate energies ϵ k {\displaystyle \epsilon _{k}} is generally observed. Although the splitting may be small, O ( λ ) {\displaystyle O(\lambda )} , compared to the range of energies found in the system, it is crucial in understanding certain details, such as spectral lines in Electron Spin Resonance experiments. Higher-order corrections due to other eigenstates outside D can be found in the same way as for the non-degenerate case, ( E n ( 0 ) − H 0 ) | n ( 1 ) ⟩ = ∑ k ∉ D ( ⟨ k ( 0 ) | V | n ( 0 ) ⟩ ) | k ( 0 ) ⟩ . {\displaystyle \left(E_{n}^{(0)}-H_{0}\right)|n^{(1)}\rangle =\sum _{k\not \in D}\left(\langle k^{(0)}|V|n^{(0)}\rangle \right)|k^{(0)}\rangle .} The operator on the left-hand side is not singular when applied to eigenstates outside D, so we can write | n ( 1 ) ⟩ = ∑ k ∉ D ⟨ k ( 0 ) | V | n ( 0 ) ⟩ E n ( 0 ) − E k ( 0 ) | k ( 0 ) ⟩ , {\displaystyle |n^{(1)}\rangle =\sum _{k\not \in D}{\frac {\langle k^{(0)}|V|n^{(0)}\rangle }{E_{n}^{(0)}-E_{k}^{(0)}}}|k^{(0)}\rangle ,} but the effect on the degenerate states is of O ( λ ) {\displaystyle O(\lambda )} . Near-degenerate states should also be treated similarly, when the original Hamiltonian splits aren't larger than the perturbation in the near-degenerate subspace. An application is found in the nearly free electron model, where near-degeneracy, treated properly, gives rise to an energy gap even for small perturbations. Other eigenstates will only shift the absolute energy of all near-degenerate states simultaneously. === Degeneracy lifted to first order === Let us consider degenerate energy eigenstates and a perturbation that completely lifts the degeneracy to first order of correction. The perturbed Hamiltonian is denoted as H ^ = H ^ 0 + λ V ^ , {\displaystyle {\hat {H}}={\hat {H}}_{0}+\lambda {\hat {V}}\,,} where H ^ 0 {\displaystyle {\hat {H}}_{0}} is the unperturbed Hamiltonian, V ^ {\displaystyle {\hat {V}}} is the perturbation operator, and 0 < λ < 1 {\displaystyle 0<\lambda <1} is the parameter of the perturbation. Let us focus on the degeneracy of the n {\displaystyle n} -th unperturbed energy E n ( 0 ) {\displaystyle E_{n}^{(0)}} . We will denote the unperturbed states in this degenerate subspace as | ψ n k ( 0 ) ⟩ {\displaystyle \left|\psi _{nk}^{(0)}\right\rangle } and the other unperturbed states as | ψ m ( 0 ) ⟩ {\displaystyle \left|\psi _{m}^{(0)}\right\rangle } , where k {\displaystyle k} is the index of the unperturbed state in the degenerate subspace and m ≠ n {\displaystyle m\neq n} represents all other energy eigenstates with energies different from E n ( 0 ) {\displaystyle E_{n}^{(0)}} . The eventual degeneracy among the other states with ∀ m ≠ n {\displaystyle \forall m\neq n} does not change our arguments. All states | ψ n k ( 0 ) ⟩ {\displaystyle \left|\psi _{nk}^{(0)}\right\rangle } with various values of k {\displaystyle k} share the same energy E n ( 0 ) {\displaystyle E_{n}^{(0)}} when there is no perturbation, i.e., when λ = 0 {\displaystyle \lambda =0} . The energies E m ( 0 ) {\displaystyle E_{m}^{(0)}} of the other states | ψ m ( 0 ) ⟩ {\displaystyle \left|\psi _{m}^{(0)}\right\rangle } with m ≠ n {\displaystyle m\neq n} are all different from E n ( 0 ) {\displaystyle E_{n}^{(0)}} , but not necessarily unique, i.e. not necessarily always different among themselves. By V n l , n k {\displaystyle V_{nl,nk}} and V m , n k {\displaystyle V_{m,nk}} , we denote the matrix elements of the perturbation operator V ^ {\displaystyle {\hat {V}}} in the basis of the unperturbed eigenstates. We assume that the basis vectors | ψ n k ( 0 ) ⟩ {\displaystyle \left|\psi _{nk}^{(0)}\right\rangle } in the degenerate subspace are chosen such that the matrix elements V n l , n k ≡ ⟨ ψ n l ( 0 ) | V ^ | ψ n k ( 0 ) ⟩ {\displaystyle V_{nl,nk}\equiv \left\langle \psi _{nl}^{(0)}\right|{\hat {V}}\left|\psi _{nk}^{(0)}\right\rangle } are diagonal. Assuming also that the degeneracy is completely lifted to the first order, i.e. that E n l ( 1 ) ≠ E n k ( 1 ) {\displaystyle E_{nl}^{(1)}\neq E_{nk}^{(1)}} if l ≠ k {\displaystyle l\neq k} , we have the following formulae for the energy correction to the second order in λ {\displaystyle \lambda } E n k = E n 0 + λ V n k , n k + λ 2 ∑ m ≠ n | V m , n k | 2 E n ( 0 ) − E m ( 0 ) + O ( λ 3 ) , {\displaystyle E_{nk}=E_{n}^{0}+\lambda V_{nk,nk}+\lambda ^{2}\sum \limits _{m\neq n}{\frac {\left|V_{m,nk}\right|^{2}}{E_{n}^{(0)}-E_{m}^{(0)}}}+{\mathcal {O}}(\lambda ^{3})\,,} and for the state correction to the first order in λ {\displaystyle \lambda } | ψ n k ( 1 ) ⟩ = | ψ n k ( 0 ) ⟩ + λ ∑ m ≠ n V m , n k E m ( 0 ) − E n ( 0 ) ( − | ψ m ( 0 ) ⟩ + ∑ l ≠ k V n l , m E n l ( 1 ) − E n k ( 1 ) | ψ n l ( 0 ) ⟩ ) + O ( λ 2 ) . {\displaystyle \left|\psi _{nk}^{(1)}\right\rangle =\left|\psi _{nk}^{(0)}\right\rangle +\lambda \sum \limits _{m\neq n}{\frac {V_{m,nk}}{E_{m}^{(0)}-E_{n}^{(0)}}}\left(-\left|\psi _{m}^{(0)}\right\rangle +\sum \limits _{l\neq k}{\frac {V_{nl,m}}{E_{nl}^{(1)}-E_{nk}^{(1)}}}\left|\psi _{nl}^{(0)}\right\rangle \right)+{\mathcal {O}}(\lambda ^{2})\,.} Notice that here the first order correction to the state is orthogonal to the unperturbed state, ⟨ ψ n k ( 0 ) | ψ n k ( 1 ) ⟩ = 0 . {\displaystyle \left\langle \psi _{nk}^{(0)}|\psi _{nk}^{(1)}\right\rangle =0\,.} === Generalization to multi-parameter case === The generalization of time-independent perturbation theory to the case where there are multiple small parameters x μ = ( x 1 , x 2 , ⋯ ) {\displaystyle x^{\mu }=(x^{1},x^{2},\cdots )} in place of λ can be formulated more systematically using the language of differential geometry, which basically defines the derivatives of the quantum states and calculates the perturbative corrections by taking derivatives iteratively at the unperturbed point. ==== Hamiltonian and force operator ==== From the differential geometric point of view, a parameterized Hamiltonian is considered as a function defined on the parameter manifold that maps each particular set of parameters ( x 1 , x 2 , ⋯ ) {\displaystyle (x^{1},x^{2},\cdots )} to an Hermitian operator H(x μ) that acts on the Hilbert space. The parameters here can be external field, interaction strength, or driving parameters in the quantum phase transition. Let En(x μ) and | n ( x μ ) ⟩ {\displaystyle |n(x^{\mu })\rangle } be the n-th eigenenergy and eigenstate of H(x μ) respectively. In the language of differential geometry, the states | n ( x μ ) ⟩ {\displaystyle |n(x^{\mu })\rangle } form a vector bundle over the parameter manifold, on which derivatives of these states can be defined. The perturbation theory is to answer the following question: given E n ( x 0 μ ) {\displaystyle E_{n}(x_{0}^{\mu })} and | n ( x 0 μ ) ⟩ {\displaystyle |n(x_{0}^{\mu })\rangle } at an unperturbed reference point x 0 μ {\displaystyle x_{0}^{\mu }} , how to estimate the En(x μ) and | n ( x μ ) ⟩ {\displaystyle |n(x^{\mu })\rangle } at x μ close to that reference point. Without loss of generality, the coordinate system can be shifted, such that the reference point x 0 μ = 0 {\displaystyle x_{0}^{\mu }=0} is set to be the origin. The following linearly parameterized Hamiltonian is frequently used H ( x μ ) = H ( 0 ) + x μ F μ . {\displaystyle H(x^{\mu })=H(0)+x^{\mu }F_{\mu }.} If the parameters x μ are considered as generalized coordinates, then Fμ should be identified as the generalized force operators related to those coordinates. Different indices μ label the different forces along different directions in the parameter manifold. For example, if x μ denotes the external magnetic field in the μ-direction, then Fμ should be the magnetization in the same direction. ==== Perturbation theory as power series expansion ==== The validity of perturbation theory lies on the adiabatic assumption, which assumes the eigenenergies and eigenstates of the Hamiltonian are smooth functions of parameters such that their values in the vicinity region can be calculated in power series (like Taylor expansion) of the parameters: E n ( x μ ) = E n + x μ ∂ μ E n + 1 2 ! x μ x ν ∂ μ ∂ ν E n + ⋯ | n ( x μ ) ⟩ = | n ⟩ + x μ | ∂ μ n ⟩ + 1 2 ! x μ x ν | ∂ μ ∂ ν n ⟩ + ⋯ {\displaystyle {\begin{aligned}E_{n}(x^{\mu })&=E_{n}+x^{\mu }\partial _{\mu }E_{n}+{\frac {1}{2!}}x^{\mu }x^{\nu }\partial _{\mu }\partial _{\nu }E_{n}+\cdots \\[1ex]\left|n(x^{\mu })\right\rangle &=\left|n\right\rangle +x^{\mu }\left|\partial _{\mu }n\right\rangle +{\frac {1}{2!}}x^{\mu }x^{\nu }\left|\partial _{\mu }\partial _{\nu }n\right\rangle +\cdots \end{aligned}}} Here ∂μ denotes the derivative with respect to x μ. When applying to the state | ∂ μ n ⟩ {\displaystyle |\partial _{\mu }n\rangle } , it should be understood as the covariant derivative if the vector bundle is equipped with non-vanishing connection. All the terms on the right-hand-side of the series are evaluated at x μ = 0, e.g. En ≡ En(0) and | n ⟩ ≡ | n ( 0 ) ⟩ {\displaystyle |n\rangle \equiv |n(0)\rangle } . This convention will be adopted throughout this subsection, that all functions without the parameter dependence explicitly stated are assumed to be evaluated at the origin. The power series may converge slowly or even not converge when the energy levels are close to each other. The adiabatic assumption breaks down when there is energy level degeneracy, and hence the perturbation theory is not applicable in that case. ==== Hellmann–Feynman theorems ==== The above power series expansion can be readily evaluated if there is a systematic approach to calculate the derivates to any order. Using the chain rule, the derivatives can be broken down to the single derivative on either the energy or the state. The Hellmann–Feynman theorems are used to calculate these single derivatives. The first Hellmann–Feynman theorem gives the derivative of the energy, ∂ μ E n = ⟨ n | ∂ μ H | n ⟩ {\displaystyle \partial _{\mu }E_{n}=\langle n|\partial _{\mu }H|n\rangle } The second Hellmann–Feynman theorem gives the derivative of the state (resolved by the complete basis with m ≠ n), ⟨ m | ∂ μ n ⟩ = ⟨ m | ∂ μ H | n ⟩ E n − E m , ⟨ ∂ μ m | n ⟩ = ⟨ m | ∂ μ H | n ⟩ E m − E n . {\displaystyle \langle m|\partial _{\mu }n\rangle ={\frac {\langle m|\partial _{\mu }H|n\rangle }{E_{n}-E_{m}}},\qquad \langle \partial _{\mu }m|n\rangle ={\frac {\langle m|\partial _{\mu }H|n\rangle }{E_{m}-E_{n}}}.} For the linearly parameterized Hamiltonian, ∂μH simply stands for the generalized force operator Fμ. The theorems can be simply derived by applying the differential operator ∂μ to both sides of the Schrödinger equation H | n ⟩ = E n | n ⟩ , {\displaystyle H|n\rangle =E_{n}|n\rangle ,} which reads ∂ μ H | n ⟩ + H | ∂ μ n ⟩ = ∂ μ E n | n ⟩ + E n | ∂ μ n ⟩ . {\displaystyle \partial _{\mu }H|n\rangle +H|\partial _{\mu }n\rangle =\partial _{\mu }E_{n}|n\rangle +E_{n}|\partial _{\mu }n\rangle .} Then overlap with the state ⟨ m | {\displaystyle \langle m|} from left and make use of the Schrödinger equation ⟨ m | H = ⟨ m | E m {\displaystyle \langle m|H=\langle m|E_{m}} again, ⟨ m | ∂ μ H | n ⟩ + E m ⟨ m | ∂ μ n ⟩ = ∂ μ E n ⟨ m | n ⟩ + E n ⟨ m | ∂ μ n ⟩ . {\displaystyle \langle m|\partial _{\mu }H|n\rangle +E_{m}\langle m|\partial _{\mu }n\rangle =\partial _{\mu }E_{n}\langle m|n\rangle +E_{n}\langle m|\partial _{\mu }n\rangle .} Given that the eigenstates of the Hamiltonian always form an orthonormal basis ⟨ m | n ⟩ = δ m n {\displaystyle \langle m|n\rangle =\delta _{mn}} , the cases of m = n and m ≠ n can be discussed separately. The first case will lead to the first theorem and the second case to the second theorem, which can be shown immediately by rearranging the terms. With the differential rules given by the Hellmann–Feynman theorems, the perturbative correction to the energies and states can be calculated systematically. ==== Correction of energy and state ==== To the second order, the energy correction reads E n ( x μ ) = ⟨ n | H | n ⟩ + ⟨ n | ∂ μ H | n ⟩ x μ + ℜ ∑ m ≠ n ⟨ n | ∂ ν H | m ⟩ ⟨ m | ∂ μ H | n ⟩ E n − E m x μ x ν + ⋯ , {\displaystyle E_{n}(x^{\mu })=\langle n|H|n\rangle +\langle n|\partial _{\mu }H|n\rangle x^{\mu }+\Re \sum _{m\neq n}{\frac {\langle n|\partial _{\nu }H|m\rangle \langle m|\partial _{\mu }H|n\rangle }{E_{n}-E_{m}}}x^{\mu }x^{\nu }+\cdots ,} where ℜ {\displaystyle \Re } denotes the real part function. The first order derivative ∂μEn is given by the first Hellmann–Feynman theorem directly. To obtain the second order derivative ∂μ∂νEn, simply applying the differential operator ∂μ to the result of the first order derivative ⟨ n | ∂ ν H | n ⟩ {\displaystyle \langle n|\partial _{\nu }H|n\rangle } , which reads ∂ μ ∂ ν E n = ⟨ ∂ μ n | ∂ ν H | n ⟩ + ⟨ n | ∂ μ ∂ ν H | n ⟩ + ⟨ n | ∂ ν H | ∂ μ n ⟩ . {\displaystyle \partial _{\mu }\partial _{\nu }E_{n}=\langle \partial _{\mu }n|\partial _{\nu }H|n\rangle +\langle n|\partial _{\mu }\partial _{\nu }H|n\rangle +\langle n|\partial _{\nu }H|\partial _{\mu }n\rangle .} Note that for a linearly parameterized Hamiltonian, there is no second derivative ∂μ∂νH = 0 on the operator level. Resolve the derivative of state by inserting the complete set of basis, ∂ μ ∂ ν E n = ∑ m ( ⟨ ∂ μ n | m ⟩ ⟨ m | ∂ ν H | n ⟩ + ⟨ n | ∂ ν H | m ⟩ ⟨ m | ∂ μ n ⟩ ) , {\displaystyle \partial _{\mu }\partial _{\nu }E_{n}=\sum _{m}\left(\langle \partial _{\mu }n|m\rangle \langle m|\partial _{\nu }H|n\rangle +\langle n|\partial _{\nu }H|m\rangle \langle m|\partial _{\mu }n\rangle \right),} then all parts can be calculated using the Hellmann–Feynman theorems. In terms of Lie derivatives, ⟨ ∂ μ n | n ⟩ = ⟨ n | ∂ μ n ⟩ = 0 {\displaystyle \langle \partial _{\mu }n|n\rangle =\langle n|\partial _{\mu }n\rangle =0} according to the definition of the connection for the vector bundle. Therefore, the case m = n can be excluded from the summation, which avoids the singularity of the energy denominator. The same procedure can be carried on for higher order derivatives, from which higher order corrections are obtained. The same computational scheme is applicable for the correction of states. The result to the second order is as follows | n ( x μ ) ⟩ = | n ⟩ + ∑ m ≠ n ⟨ m | ∂ μ H | n ⟩ E n − E m | m ⟩ x μ + ( ∑ m ≠ n ∑ l ≠ n ⟨ m | ∂ μ H | l ⟩ ⟨ l | ∂ ν H | n ⟩ ( E n − E m ) ( E n − E l ) | m ⟩ − ∑ m ≠ n ⟨ m | ∂ μ H | n ⟩ ⟨ n | ∂ ν H | n ⟩ ( E n − E m ) 2 | m ⟩ − 1 2 ∑ m ≠ n ⟨ n | ∂ μ H | m ⟩ ⟨ m | ∂ ν H | n ⟩ ( E n − E m ) 2 | n ⟩ ) x μ x ν + ⋯ . {\displaystyle {\begin{aligned}\left|n\left(x^{\mu }\right)\right\rangle =|n\rangle &+\sum _{m\neq n}{\frac {\langle m|\partial _{\mu }H|n\rangle }{E_{n}-E_{m}}}|m\rangle x^{\mu }\\&+\left(\sum _{m\neq n}\sum _{l\neq n}{\frac {\langle m|\partial _{\mu }H|l\rangle \langle l|\partial _{\nu }H|n\rangle }{(E_{n}-E_{m})(E_{n}-E_{l})}}|m\rangle -\sum _{m\neq n}{\frac {\langle m|\partial _{\mu }H|n\rangle \langle n|\partial _{\nu }H|n\rangle }{(E_{n}-E_{m})^{2}}}|m\rangle -{\frac {1}{2}}\sum _{m\neq n}{\frac {\langle n|\partial _{\mu }H|m\rangle \langle m|\partial _{\nu }H|n\rangle }{(E_{n}-E_{m})^{2}}}|n\rangle \right)x^{\mu }x^{\nu }+\cdots .\end{aligned}}} Both energy derivatives and state derivatives will be involved in deduction. Whenever a state derivative is encountered, resolve it by inserting the complete set of basis, then the Hellmann-Feynman theorem is applicable. Because differentiation can be calculated systematically, the series expansion approach to the perturbative corrections can be coded on computers with symbolic processing software like Mathematica. ==== Effective Hamiltonian ==== Let H(0) be the Hamiltonian completely restricted either in the low-energy subspace H L {\displaystyle {\mathcal {H}}_{L}} or in the high-energy subspace H H {\displaystyle {\mathcal {H}}_{H}} , such that there is no matrix element in H(0) connecting the low- and the high-energy subspaces, i.e. ⟨ m | H ( 0 ) | l ⟩ = 0 {\displaystyle \langle m|H(0)|l\rangle =0} if m ∈ H L , l ∈ H H {\displaystyle m\in {\mathcal {H}}_{L},l\in {\mathcal {H}}_{H}} . Let Fμ = ∂μH be the coupling terms connecting the subspaces. Then when the high energy degrees of freedoms are integrated out, the effective Hamiltonian in the low energy subspace reads H m n eff ( x μ ) = ⟨ m | H | n ⟩ + δ n m ⟨ m | ∂ μ H | n ⟩ x μ + 1 2 ! ∑ l ∈ H H ( ⟨ m | ∂ μ H | l ⟩ ⟨ l | ∂ ν H | n ⟩ E m − E l + ⟨ m | ∂ ν H | l ⟩ ⟨ l | ∂ μ H | n ⟩ E n − E l ) x μ x ν + ⋯ . {\displaystyle H_{mn}^{\text{eff}}\left(x^{\mu }\right)=\langle m|H|n\rangle +\delta _{nm}\langle m|\partial _{\mu }H|n\rangle x^{\mu }+{\frac {1}{2!}}\sum _{l\in {\mathcal {H}}_{H}}\left({\frac {\langle m|\partial _{\mu }H|l\rangle \langle l|\partial _{\nu }H|n\rangle }{E_{m}-E_{l}}}+{\frac {\langle m|\partial _{\nu }H|l\rangle \langle l|\partial _{\mu }H|n\rangle }{E_{n}-E_{l}}}\right)x^{\mu }x^{\nu }+\cdots .} Here m , n ∈ H L {\displaystyle m,n\in {\mathcal {H}}_{L}} are restricted in the low energy subspace. The above result can be derived by power series expansion of ⟨ m | H ( x μ ) | n ⟩ {\displaystyle \langle m|H(x^{\mu })|n\rangle } . In a formal way it is possible to define an effective Hamiltonian that gives exactly the low-lying energy states and wavefunctions. In practice, some kind of approximation (perturbation theory) is generally required. == Time-dependent perturbation theory == === Method of variation of constants === Time-dependent perturbation theory, initiated by Paul Dirac and further developed by John Archibald Wheeler, Richard Feynman, and Freeman Dyson, studies the effect of a time-dependent perturbation V(t) applied to a time-independent Hamiltonian H0. It is an extremely valuable tool for calculating the properties of any physical system. It is used for the quantitative description of phenomena as diverse as proton-proton scattering, photo-ionization of materials, scattering of electrons off lattice defects in a conductor, scattering of neutrons off nuclei, electric susceptibilities of materials, neutron absorption cross sections in a nuclear reactor, and much more. Since the perturbed Hamiltonian is time-dependent, so are its energy levels and eigenstates. Thus, the goals of time-dependent perturbation theory are slightly different from time-independent perturbation theory. One is interested in the following quantities: The time-dependent expectation value of some observable A, for a given initial state. The time-dependent expansion coefficients (w.r.t. a given time-dependent state) of those basis states that are energy eigenkets (eigenvectors) in the unperturbed system. The first quantity is important because it gives rise to the classical result of an A measurement performed on a macroscopic number of copies of the perturbed system. For example, we could take A to be the displacement in the x-direction of the electron in a hydrogen atom, in which case the expected value, when multiplied by an appropriate coefficient, gives the time-dependent dielectric polarization of a hydrogen gas. With an appropriate choice of perturbation (i.e. an oscillating electric potential), this allows one to calculate the AC permittivity of the gas. The second quantity looks at the time-dependent probability of occupation for each eigenstate. This is particularly useful in laser physics, where one is interested in the populations of different atomic states in a gas when a time-dependent electric field is applied. These probabilities are also useful for calculating the "quantum broadening" of spectral lines (see line broadening) and particle decay in particle physics and nuclear physics. We will briefly examine the method behind Dirac's formulation of time-dependent perturbation theory. Choose an energy basis | n ⟩ {\displaystyle {|n\rangle }} for the unperturbed system. (We drop the (0) superscripts for the eigenstates, because it is not useful to speak of energy levels and eigenstates for the perturbed system.) If the unperturbed system is an eigenstate (of the Hamiltonian) | j ⟩ {\displaystyle |j\rangle } at time t = 0, its state at subsequent times varies only by a phase (in the Schrödinger picture, where state vectors evolve in time and operators are constant), | j ( t ) ⟩ = e − i E j t / ℏ | j ⟩ . {\displaystyle |j(t)\rangle =e^{-iE_{j}t/\hbar }|j\rangle ~.} Now, introduce a time-dependent perturbing Hamiltonian V(t). The Hamiltonian of the perturbed system is H = H 0 + V ( t ) . {\displaystyle H=H_{0}+V(t)~.} Let | ψ ( t ) ⟩ {\displaystyle |\psi (t)\rangle } denote the quantum state of the perturbed system at time t. It obeys the time-dependent Schrödinger equation, H | ψ ( t ) ⟩ = i ℏ ∂ ∂ t | ψ ( t ) ⟩ . {\displaystyle H|\psi (t)\rangle =i\hbar {\frac {\partial }{\partial t}}|\psi (t)\rangle ~.} The quantum state at each instant can be expressed as a linear combination of the complete eigenbasis of | n ⟩ {\displaystyle |n\rangle } : where the cn(t)s are to be determined complex functions of t which we will refer to as amplitudes (strictly speaking, they are the amplitudes in the Dirac picture). We have explicitly extracted the exponential phase factors exp ⁡ ( − i E n t / ℏ ) {\displaystyle \exp(-iE_{n}t/\hbar )} on the right hand side. This is only a matter of convention, and may be done without loss of generality. The reason we go to this trouble is that when the system starts in the state | j ⟩ {\displaystyle |j\rangle } and no perturbation is present, the amplitudes have the convenient property that, for all t, cj(t) = 1 and cn(t) = 0 if n ≠ j. The square of the absolute amplitude cn(t) is the probability that the system is in state n at time t, since | c n ( t ) | 2 = | ⟨ n | ψ ( t ) ⟩ | 2 . {\displaystyle \left|c_{n}(t)\right|^{2}=\left|\langle n|\psi (t)\rangle \right|^{2}~.} Plugging into the Schrödinger equation and using the fact that ∂/∂t acts by a product rule, one obtains ∑ n ( i ℏ d c n d t − c n ( t ) V ( t ) ) e − i E n t / ℏ | n ⟩ = 0 . {\displaystyle \sum _{n}\left(i\hbar {\frac {dc_{n}}{dt}}-c_{n}(t)V(t)\right)e^{-iE_{n}t/\hbar }|n\rangle =0~.} By resolving the identity in front of V and multiplying through by the bra ⟨ n | {\displaystyle \langle n|} on the left, this can be reduced to a set of coupled differential equations for the amplitudes, d c n d t = − i ℏ ∑ k ⟨ n | V ( t ) | k ⟩ c k ( t ) e − i ( E k − E n ) t / ℏ . {\displaystyle {\frac {dc_{n}}{dt}}={\frac {-i}{\hbar }}\sum _{k}\langle n|V(t)|k\rangle \,c_{k}(t)\,e^{-i(E_{k}-E_{n})t/\hbar }~.} where we have used equation (1) to evaluate the sum on n in the second term, then used the fact that ⟨ k | Ψ ( t ) ⟩ = c k ( t ) e − i E k t / ℏ {\displaystyle \langle k|\Psi (t)\rangle =c_{k}(t)e^{-iE_{k}t/\hbar }} . The matrix elements of V play a similar role as in time-independent perturbation theory, being proportional to the rate at which amplitudes are shifted between states. Note, however, that the direction of the shift is modified by the exponential phase factor. Over times much longer than the energy difference Ek − En, the phase winds around 0 several times. If the time-dependence of V is sufficiently slow, this may cause the state amplitudes to oscillate. (For example, such oscillations are useful for managing radiative transitions in a laser.) Up to this point, we have made no approximations, so this set of differential equations is exact. By supplying appropriate initial values cn(t), we could in principle find an exact (i.e., non-perturbative) solution. This is easily done when there are only two energy levels (n = 1, 2), and this solution is useful for modelling systems like the ammonia molecule. However, exact solutions are difficult to find when there are many energy levels, and one instead looks for perturbative solutions. These may be obtained by expressing the equations in an integral form, c n ( t ) = c n ( 0 ) − i ℏ ∑ k ∫ 0 t d t ′ ⟨ n | V ( t ′ ) | k ⟩ c k ( t ′ ) e − i ( E k − E n ) t ′ / ℏ . {\displaystyle c_{n}(t)=c_{n}(0)-{\frac {i}{\hbar }}\sum _{k}\int _{0}^{t}dt'\;\langle n|V(t')|k\rangle \,c_{k}(t')\,e^{-i(E_{k}-E_{n})t'/\hbar }~.} Repeatedly substituting this expression for cn back into right hand side, yields an iterative solution, c n ( t ) = c n ( 0 ) + c n ( 1 ) + c n ( 2 ) + ⋯ {\displaystyle c_{n}(t)=c_{n}^{(0)}+c_{n}^{(1)}+c_{n}^{(2)}+\cdots } where, for example, the first-order term is c n ( 1 ) ( t ) = − i ℏ ∑ k ∫ 0 t d t ′ ⟨ n | V ( t ′ ) | k ⟩ c k ( 0 ) e − i ( E k − E n ) t ′ / ℏ . {\displaystyle c_{n}^{(1)}(t)={\frac {-i}{\hbar }}\sum _{k}\int _{0}^{t}dt'\;\langle n|V(t')|k\rangle \,c_{k}^{(0)}\,e^{-i(E_{k}-E_{n})t'/\hbar }~.} To the same approximation, the summation in the above expression can be removed since in the unperturbed state c k ( 0 ) = δ k n {\displaystyle c_{k}^{(0)}=\delta _{kn}} so that we have c n ( 1 ) ( t ) = − i ℏ ∫ 0 t d t ′ ⟨ n | V ( t ′ ) | k ⟩ e − i ( E k − E n ) t ′ / ℏ . {\displaystyle c_{n}^{(1)}(t)={\frac {-i}{\hbar }}\int _{0}^{t}dt'\;\langle n|V(t')|k\rangle \,e^{-i(E_{k}-E_{n})t'/\hbar }~.} Several further results follow from this, such as Fermi's golden rule, which relates the rate of transitions between quantum states to the density of states at particular energies; or the Dyson series, obtained by applying the iterative method to the time evolution operator, which is one of the starting points for the method of Feynman diagrams. === Method of Dyson series === Time-dependent perturbations can be reorganized through the technique of the Dyson series. The Schrödinger equation H ( t ) | ψ ( t ) ⟩ = i ℏ ∂ | ψ ( t ) ⟩ ∂ t {\displaystyle H(t)|\psi (t)\rangle =i\hbar {\frac {\partial |\psi (t)\rangle }{\partial t}}} has the formal solution | ψ ( t ) ⟩ = T exp ⁡ [ − i ℏ ∫ t 0 t d t ′ H ( t ′ ) ] | ψ ( t 0 ) ⟩ , {\displaystyle |\psi (t)\rangle =T\exp {\left[-{\frac {i}{\hbar }}\int _{t_{0}}^{t}dt'H(t')\right]}|\psi (t_{0})\rangle ~,} where T is the time ordering operator, T A ( t 1 ) A ( t 2 ) = { A ( t 1 ) A ( t 2 ) t 1 > t 2 A ( t 2 ) A ( t 1 ) t 2 > t 1 . {\displaystyle TA(t_{1})A(t_{2})={\begin{cases}A(t_{1})A(t_{2})&t_{1}>t_{2}\\A(t_{2})A(t_{1})&t_{2}>t_{1}\end{cases}}~.} Thus, the exponential represents the following Dyson series, | ψ ( t ) ⟩ = [ 1 − i ℏ ∫ t 0 t d t 1 H ( t 1 ) − 1 ℏ 2 ∫ t 0 t d t 1 ∫ t 0 t 1 d t 2 H ( t 1 ) H ( t 2 ) + … ] | ψ ( t 0 ) ⟩ . {\displaystyle |\psi (t)\rangle =\left[1-{\frac {i}{\hbar }}\int _{t_{0}}^{t}dt_{1}H(t_{1})-{\frac {1}{\hbar ^{2}}}\int _{t_{0}}^{t}dt_{1}\int _{t_{0}}^{t_{1}}dt_{2}H(t_{1})H(t_{2})+\ldots \right]|\psi (t_{0})\rangle ~.} Note that in the second term, the 1/2! factor exactly cancels the double contribution due to the time-ordering operator, etc. Consider the following perturbation problem [ H 0 + λ V ( t ) ] | ψ ( t ) ⟩ = i ℏ ∂ | ψ ( t ) ⟩ ∂ t , {\displaystyle [H_{0}+\lambda V(t)]|\psi (t)\rangle =i\hbar {\frac {\partial |\psi (t)\rangle }{\partial t}}~,} assuming that the parameter λ is small and that the problem H 0 | n ⟩ = E n | n ⟩ {\displaystyle H_{0}|n\rangle =E_{n}|n\rangle } has been solved. Perform the following unitary transformation to the interaction picture (or Dirac picture), | ψ ( t ) ⟩ = e − i ℏ H 0 ( t − t 0 ) | ψ I ( t ) ⟩ . {\displaystyle |\psi (t)\rangle =e^{-{\frac {i}{\hbar }}H_{0}(t-t_{0})}|\psi _{I}(t)\rangle ~.} Consequently, the Schrödinger equation simplifies to λ e i ℏ H 0 ( t − t 0 ) V ( t ) e − i ℏ H 0 ( t − t 0 ) | ψ I ( t ) ⟩ = i ℏ ∂ | ψ I ( t ) ⟩ ∂ t , {\displaystyle \lambda e^{{\frac {i}{\hbar }}H_{0}(t-t_{0})}V(t)e^{-{\frac {i}{\hbar }}H_{0}(t-t_{0})}|\psi _{I}(t)\rangle =i\hbar {\frac {\partial |\psi _{I}(t)\rangle }{\partial t}}~,} so it is solved through the above Dyson series, | ψ I ( t ) ⟩ = [ 1 − i λ ℏ ∫ t 0 t d t 1 e i ℏ H 0 ( t 1 − t 0 ) V ( t 1 ) e − i ℏ H 0 ( t 1 − t 0 ) − λ 2 ℏ 2 ∫ t 0 t d t 1 ∫ t 0 t 1 d t 2 e i ℏ H 0 ( t 1 − t 0 ) V ( t 1 ) e − i ℏ H 0 ( t 1 − t 0 ) e i ℏ H 0 ( t 2 − t 0 ) V ( t 2 ) e − i ℏ H 0 ( t 2 − t 0 ) + … ] | ψ ( t 0 ) ⟩ , {\displaystyle |\psi _{I}(t)\rangle =\left[1-{\frac {i\lambda }{\hbar }}\int _{t_{0}}^{t}dt_{1}e^{{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}V(t_{1})e^{-{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}-{\frac {\lambda ^{2}}{\hbar ^{2}}}\int _{t_{0}}^{t}dt_{1}\int _{t_{0}}^{t_{1}}dt_{2}e^{{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}V(t_{1})e^{-{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}e^{{\frac {i}{\hbar }}H_{0}(t_{2}-t_{0})}V(t_{2})e^{-{\frac {i}{\hbar }}H_{0}(t_{2}-t_{0})}+\ldots \right]|\psi (t_{0})\rangle ~,} as a perturbation series with small λ. Using the solution of the unperturbed problem H 0 | n ⟩ = E n | n ⟩ {\displaystyle H_{0}|n\rangle =E_{n}|n\rangle } and ∑ n | n ⟩ ⟨ n | = 1 {\displaystyle \sum _{n}|n\rangle \langle n|=1} (for the sake of simplicity assume a pure discrete spectrum), yields, to first order, | ψ I ( t ) ⟩ = [ 1 − i λ ℏ ∑ m ∑ n ∫ t 0 t d t 1 ⟨ m | V ( t 1 ) | n ⟩ e − i ℏ ( E n − E m ) ( t 1 − t 0 ) | m ⟩ ⟨ n | + … ] | ψ ( t 0 ) ⟩ . {\displaystyle |\psi _{I}(t)\rangle =\left[1-{\frac {i\lambda }{\hbar }}\sum _{m}\sum _{n}\int _{t_{0}}^{t}dt_{1}\langle m|V(t_{1})|n\rangle e^{-{\frac {i}{\hbar }}(E_{n}-E_{m})(t_{1}-t_{0})}|m\rangle \langle n|+\ldots \right]|\psi (t_{0})\rangle ~.} Thus, the system, initially in the unperturbed state | α ⟩ = | ψ ( t 0 ) ⟩ {\displaystyle |\alpha \rangle =|\psi (t_{0})\rangle } , by dint of the perturbation can go into the state | β ⟩ {\displaystyle |\beta \rangle } . The corresponding transition probability amplitude to first order is A α β = − i λ ℏ ∫ t 0 t d t 1 ⟨ β | V ( t 1 ) | α ⟩ e − i ℏ ( E α − E β ) ( t 1 − t 0 ) , {\displaystyle A_{\alpha \beta }=-{\frac {i\lambda }{\hbar }}\int _{t_{0}}^{t}dt_{1}\langle \beta |V(t_{1})|\alpha \rangle e^{-{\frac {i}{\hbar }}(E_{\alpha }-E_{\beta })(t_{1}-t_{0})}~,} as detailed in the previous section——while the corresponding transition probability to a continuum is furnished by Fermi's golden rule. As an aside, note that time-independent perturbation theory is also organized inside this time-dependent perturbation theory Dyson series. To see this, write the unitary evolution operator, obtained from the above Dyson series, as U ( t ) = 1 − i λ ℏ ∫ t 0 t d t 1 e i ℏ H 0 ( t 1 − t 0 ) V ( t 1 ) e − i ℏ H 0 ( t 1 − t 0 ) − λ 2 ℏ 2 ∫ t 0 t d t 1 ∫ t 0 t 1 d t 2 e i ℏ H 0 ( t 1 − t 0 ) V ( t 1 ) e − i ℏ H 0 ( t 1 − t 0 ) e i ℏ H 0 ( t 2 − t 0 ) V ( t 2 ) e − i ℏ H 0 ( t 2 − t 0 ) + ⋯ {\displaystyle U(t)=1-{\frac {i\lambda }{\hbar }}\int _{t_{0}}^{t}dt_{1}e^{{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}V(t_{1})e^{-{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}-{\frac {\lambda ^{2}}{\hbar ^{2}}}\int _{t_{0}}^{t}dt_{1}\int _{t_{0}}^{t_{1}}dt_{2}e^{{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}V(t_{1})e^{-{\frac {i}{\hbar }}H_{0}(t_{1}-t_{0})}e^{{\frac {i}{\hbar }}H_{0}(t_{2}-t_{0})}V(t_{2})e^{-{\frac {i}{\hbar }}H_{0}(t_{2}-t_{0})}+\cdots } and take the perturbation V to be time-independent. Using the identity resolution ∑ n | n ⟩ ⟨ n | = 1 {\displaystyle \sum _{n}|n\rangle \langle n|=1} with H 0 | n ⟩ = E n | n ⟩ {\displaystyle H_{0}|n\rangle =E_{n}|n\rangle } for a pure discrete spectrum, write U ( t ) = 1 − [ i λ ℏ ∫ t 0 t d t 1 ∑ m ∑ n ⟨ m | V | n ⟩ e − i ℏ ( E n − E m ) ( t 1 − t 0 ) | m ⟩ ⟨ n | ] − [ λ 2 ℏ 2 ∫ t 0 t d t 1 ∫ t 0 t 1 d t 2 ∑ m ∑ n ∑ q e − i ℏ ( E n − E m ) ( t 1 − t 0 ) ⟨ m | V | n ⟩ ⟨ n | V | q ⟩ e − i ℏ ( E q − E n ) ( t 2 − t 0 ) | m ⟩ ⟨ q | ] + ⋯ {\displaystyle {\begin{aligned}U(t)=1&-\left[{\frac {i\lambda }{\hbar }}\int _{t_{0}}^{t}dt_{1}\sum _{m}\sum _{n}\langle m|V|n\rangle e^{-{\frac {i}{\hbar }}(E_{n}-E_{m})(t_{1}-t_{0})}|m\rangle \langle n|\right]\\[5mu]&-\left[{\frac {\lambda ^{2}}{\hbar ^{2}}}\int _{t_{0}}^{t}dt_{1}\int _{t_{0}}^{t_{1}}dt_{2}\sum _{m}\sum _{n}\sum _{q}e^{-{\frac {i}{\hbar }}(E_{n}-E_{m})(t_{1}-t_{0})}\langle m|V|n\rangle \langle n|V|q\rangle e^{-{\frac {i}{\hbar }}(E_{q}-E_{n})(t_{2}-t_{0})}|m\rangle \langle q|\right]+\cdots \end{aligned}}} It is evident that, at second order, one must sum on all the intermediate states. Assume t 0 = 0 {\displaystyle t_{0}=0} and the asymptotic limit of larger times. This means that, at each contribution of the perturbation series, one has to add a multiplicative factor e − ϵ t {\displaystyle e^{-\epsilon t}} in the integrands for ε arbitrarily small. Thus the limit t → ∞ gives back the final state of the system by eliminating all oscillating terms, but keeping the secular ones. The integrals are thus computable, and, separating the diagonal terms from the others yields U ( t ) = 1 − i λ ℏ ∑ n ⟨ n | V | n ⟩ t − i λ 2 ℏ ∑ m ≠ n ⟨ n | V | m ⟩ ⟨ m | V | n ⟩ E n − E m t − 1 2 λ 2 ℏ 2 ∑ m , n ⟨ n | V | m ⟩ ⟨ m | V | n ⟩ t 2 + ⋯ + λ ∑ m ≠ n ⟨ m | V | n ⟩ E n − E m | m ⟩ ⟨ n | + λ 2 ∑ m ≠ n ∑ q ≠ n ∑ n ⟨ m | V | n ⟩ ⟨ n | V | q ⟩ ( E n − E m ) ( E q − E n ) | m ⟩ ⟨ q | + ⋯ {\displaystyle {\begin{aligned}U(t)=1&-{\frac {i\lambda }{\hbar }}\sum _{n}\langle n|V|n\rangle t-{\frac {i\lambda ^{2}}{\hbar }}\sum _{m\neq n}{\frac {\langle n|V|m\rangle \langle m|V|n\rangle }{E_{n}-E_{m}}}t-{\frac {1}{2}}{\frac {\lambda ^{2}}{\hbar ^{2}}}\sum _{m,n}\langle n|V|m\rangle \langle m|V|n\rangle t^{2}+\cdots \\&+\lambda \sum _{m\neq n}{\frac {\langle m|V|n\rangle }{E_{n}-E_{m}}}|m\rangle \langle n|+\lambda ^{2}\sum _{m\neq n}\sum _{q\neq n}\sum _{n}{\frac {\langle m|V|n\rangle \langle n|V|q\rangle }{(E_{n}-E_{m})(E_{q}-E_{n})}}|m\rangle \langle q|+\cdots \end{aligned}}} where the time secular series yields the eigenvalues of the perturbed problem specified above, recursively; whereas the remaining time-constant part yields the corrections to the stationary eigenfunctions also given above ( | n ( λ ) ⟩ = U ( 0 ; λ ) | n ⟩ ) {\displaystyle |n(\lambda )\rangle =U(0;\lambda )|n\rangle )} .) The unitary evolution operator is applicable to arbitrary eigenstates of the unperturbed problem and, in this case, yields a secular series that holds at small times. == Strong perturbation theory == In a similar way as for small perturbations, it is possible to develop a strong perturbation theory. Consider as usual the Schrödinger equation H ( t ) | ψ ( t ) ⟩ = i ℏ ∂ | ψ ( t ) ⟩ ∂ t {\displaystyle H(t)|\psi (t)\rangle =i\hbar {\frac {\partial |\psi (t)\rangle }{\partial t}}} and we consider the question if a dual Dyson series exists that applies in the limit of a perturbation increasingly large. This question can be answered in an affirmative way and the series is the well-known adiabatic series. This approach is quite general and can be shown in the following way. Consider the perturbation problem [ H 0 + λ V ( t ) ] | ψ ( t ) ⟩ = i ℏ ∂ | ψ ( t ) ⟩ ∂ t {\displaystyle [H_{0}+\lambda V(t)]|\psi (t)\rangle =i\hbar {\frac {\partial |\psi (t)\rangle }{\partial t}}} being λ→ ∞. Our aim is to find a solution in the form | ψ ⟩ = | ψ 0 ⟩ + 1 λ | ψ 1 ⟩ + 1 λ 2 | ψ 2 ⟩ + … {\displaystyle |\psi \rangle =|\psi _{0}\rangle +{\frac {1}{\lambda }}|\psi _{1}\rangle +{\frac {1}{\lambda ^{2}}}|\psi _{2}\rangle +\ldots } but a direct substitution into the above equation fails to produce useful results. This situation can be adjusted making a rescaling of the time variable as τ = λ t {\displaystyle \tau =\lambda t} producing the following meaningful equations V ( t ) | ψ 0 ⟩ = i ℏ ∂ | ψ 0 ⟩ ∂ τ V ( t ) | ψ 1 ⟩ + H 0 | ψ 0 ⟩ = i ℏ ∂ | ψ 1 ⟩ ∂ τ ⋮ {\displaystyle {\begin{aligned}V(t)|\psi _{0}\rangle &=i\hbar {\frac {\partial |\psi _{0}\rangle }{\partial \tau }}\\[1ex]V(t)|\psi _{1}\rangle +H_{0}|\psi _{0}\rangle &=i\hbar {\frac {\partial |\psi _{1}\rangle }{\partial \tau }}\\[1ex]&\;\,\vdots \end{aligned}}} that can be solved once we know the solution of the leading order equation. But we know that in this case we can use the adiabatic approximation. When V ( t ) {\displaystyle V(t)} does not depend on time one gets the Wigner-Kirkwood series that is often used in statistical mechanics. Indeed, in this case we introduce the unitary transformation | ψ ( t ) ⟩ = e − i ℏ λ V ( t − t 0 ) | ψ F ( t ) ⟩ {\displaystyle |\psi (t)\rangle =e^{-{\frac {i}{\hbar }}\lambda V(t-t_{0})}|\psi _{F}(t)\rangle } that defines a free picture as we are trying to eliminate the interaction term. Now, in dual way with respect to the small perturbations, we have to solve the Schrödinger equation e i ℏ λ V ( t − t 0 ) H 0 e − i ℏ λ V ( t − t 0 ) | ψ F ( t ) ⟩ = i ℏ ∂ | ψ F ( t ) ⟩ ∂ t {\displaystyle e^{{\frac {i}{\hbar }}\lambda V(t-t_{0})}H_{0}e^{-{\frac {i}{\hbar }}\lambda V(t-t_{0})}|\psi _{F}(t)\rangle =i\hbar {\frac {\partial |\psi _{F}(t)\rangle }{\partial t}}} and we see that the expansion parameter λ appears only into the exponential and so, the corresponding Dyson series, a dual Dyson series, is meaningful at large λs and is | ψ F ( t ) ⟩ = [ 1 − i ℏ ∫ t 0 t d t 1 e i ℏ λ V ( t 1 − t 0 ) H 0 e − i ℏ λ V ( t 1 − t 0 ) − 1 ℏ 2 ∫ t 0 t d t 1 ∫ t 0 t 1 d t 2 e i ℏ λ V ( t 1 − t 0 ) H 0 e − i ℏ λ V ( t 1 − t 0 ) e i ℏ λ V ( t 2 − t 0 ) H 0 e − i ℏ λ V ( t 2 − t 0 ) + ⋯ ] | ψ ( t 0 ) ⟩ . {\displaystyle |\psi _{F}(t)\rangle =\left[1-{\frac {i}{\hbar }}\int _{t_{0}}^{t}dt_{1}e^{{\frac {i}{\hbar }}\lambda V(t_{1}-t_{0})}H_{0}e^{-{\frac {i}{\hbar }}\lambda V(t_{1}-t_{0})}-{\frac {1}{\hbar ^{2}}}\int _{t_{0}}^{t}dt_{1}\int _{t_{0}}^{t_{1}}dt_{2}e^{{\frac {i}{\hbar }}\lambda V(t_{1}-t_{0})}H_{0}e^{-{\frac {i}{\hbar }}\lambda V(t_{1}-t_{0})}e^{{\frac {i}{\hbar }}\lambda V(t_{2}-t_{0})}H_{0}e^{-{\frac {i}{\hbar }}\lambda V(t_{2}-t_{0})}+\cdots \right]|\psi (t_{0})\rangle .} After the rescaling in time τ = λ t {\displaystyle \tau =\lambda t} we can see that this is indeed a series in 1 / λ {\displaystyle 1/\lambda } justifying in this way the name of dual Dyson series. The reason is that we have obtained this series simply interchanging H0 and V and we can go from one to another applying this exchange. This is called duality principle in perturbation theory. The choice H 0 = p 2 / 2 m {\displaystyle H_{0}=p^{2}/2m} yields, as already said, a Wigner-Kirkwood series that is a gradient expansion. The Wigner-Kirkwood series is a semiclassical series with eigenvalues given exactly as for WKB approximation. == Examples == === Example of first-order perturbation theory – ground-state energy of the quartic oscillator === Consider the quantum harmonic oscillator with the quartic potential perturbation and the Hamiltonian H = − ℏ 2 2 m ∂ 2 ∂ x 2 + m ω 2 x 2 2 + λ x 4 . {\displaystyle H=-{\frac {\hbar ^{2}}{2m}}{\frac {\partial ^{2}}{\partial x^{2}}}+{\frac {m\omega ^{2}x^{2}}{2}}+\lambda x^{4}.} The ground state of the harmonic oscillator is ψ 0 = ( α π ) 1 4 e − α x 2 / 2 {\displaystyle \psi _{0}=\left({\frac {\alpha }{\pi }}\right)^{\frac {1}{4}}e^{-\alpha x^{2}/2}} ( α = m ω / ℏ {\displaystyle \alpha =m\omega /\hbar } ), and the energy of unperturbed ground state is E 0 ( 0 ) = 1 2 ℏ ω {\displaystyle E_{0}^{(0)}={\tfrac {1}{2}}\hbar \omega } Using the first-order correction formula, we get E 0 ( 1 ) = λ ( α π ) 1 2 ∫ e − α x 2 / 2 x 4 e − α x 2 / 2 d x = λ ( α π ) 1 2 ∂ 2 ∂ α 2 ∫ e − α x 2 d x , {\displaystyle E_{0}^{(1)}=\lambda \left({\frac {\alpha }{\pi }}\right)^{\frac {1}{2}}\int e^{-\alpha x^{2}/2}x^{4}e^{-\alpha x^{2}/2}dx=\lambda \left({\frac {\alpha }{\pi }}\right)^{\frac {1}{2}}{\frac {\partial ^{2}}{\partial \alpha ^{2}}}\int e^{-\alpha x^{2}}dx,} or E 0 ( 1 ) = λ ( α π ) 1 2 ∂ 2 ∂ α 2 ( π α ) 1 2 = λ 3 4 1 α 2 = 3 4 ℏ 2 λ m 2 ω 2 . {\displaystyle E_{0}^{(1)}=\lambda \left({\frac {\alpha }{\pi }}\right)^{\frac {1}{2}}{\frac {\partial ^{2}}{\partial \alpha ^{2}}}\left({\frac {\pi }{\alpha }}\right)^{\frac {1}{2}}=\lambda {\frac {3}{4}}{\frac {1}{\alpha ^{2}}}={\frac {3}{4}}{\frac {\hbar ^{2}\lambda }{m^{2}\omega ^{2}}}.} === Example of first- and second-order perturbation theory – quantum pendulum === Consider the quantum-mathematical pendulum with the Hamiltonian H = − ℏ 2 2 m a 2 ∂ 2 ∂ ϕ 2 − λ cos ⁡ ϕ {\displaystyle H=-{\frac {\hbar ^{2}}{2ma^{2}}}{\frac {\partial ^{2}}{\partial \phi ^{2}}}-\lambda \cos \phi } with the potential energy − λ cos ⁡ ϕ {\displaystyle -\lambda \cos \phi } taken as the perturbation i.e. V = − cos ⁡ ϕ . {\displaystyle V=-\cos \phi .} The unperturbed normalized quantum wave functions are those of the rigid rotor and are given by ψ n ( ϕ ) = e i n ϕ 2 π , {\displaystyle \psi _{n}(\phi )={\frac {e^{in\phi }}{\sqrt {2\pi }}},} and the energies E n ( 0 ) = ℏ 2 n 2 2 m a 2 . {\displaystyle E_{n}^{(0)}={\frac {\hbar ^{2}n^{2}}{2ma^{2}}}.} The first-order energy correction to the rotor due to the potential energy is E n ( 1 ) = − 1 2 π ∫ e − i n ϕ cos ⁡ ϕ e i n ϕ = − 1 2 π ∫ cos ⁡ ϕ = 0. {\displaystyle E_{n}^{(1)}=-{\frac {1}{2\pi }}\int e^{-in\phi }\cos \phi e^{in\phi }=-{\frac {1}{2\pi }}\int \cos \phi =0.} Using the formula for the second-order correction, one gets E n ( 2 ) = m a 2 2 π 2 ℏ 2 ∑ k | ∫ e − i k ϕ cos ⁡ ϕ e i n ϕ d ϕ | 2 n 2 − k 2 , {\displaystyle E_{n}^{(2)}={\frac {ma^{2}}{2\pi ^{2}\hbar ^{2}}}\sum _{k}{\frac {\left|\int e^{-ik\phi }\cos \phi e^{in\phi }\,d\phi \right|^{2}}{n^{2}-k^{2}}},} or E n ( 2 ) = m a 2 2 ℏ 2 ∑ k | ( δ n , 1 − k + δ n , − 1 − k ) | 2 n 2 − k 2 , {\displaystyle E_{n}^{(2)}={\frac {ma^{2}}{2\hbar ^{2}}}\sum _{k}{\frac {\left|\left(\delta _{n,1-k}+\delta _{n,-1-k}\right)\right|^{2}}{n^{2}-k^{2}}},} or E n ( 2 ) = m a 2 2 ℏ 2 ( 1 2 n − 1 + 1 − 2 n − 1 ) = m a 2 ℏ 2 1 4 n 2 − 1 . {\displaystyle E_{n}^{(2)}={\frac {ma^{2}}{2\hbar ^{2}}}\left({\frac {1}{2n-1}}+{\frac {1}{-2n-1}}\right)={\frac {ma^{2}}{\hbar ^{2}}}{\frac {1}{4n^{2}-1}}.} === Potential energy as a perturbation === When the unperturbed state is a free motion of a particle with kinetic energy E {\displaystyle E} , the solution of the Schrödinger equation ∇ 2 ψ ( 0 ) + k 2 ψ ( 0 ) = 0 {\displaystyle \nabla ^{2}\psi ^{(0)}+k^{2}\psi ^{(0)}=0} corresponds to plane waves with wavenumber k = 2 m E / ℏ 2 {\textstyle k={\sqrt {2mE/\hbar ^{2}}}} . If there is a weak potential energy U ( x , y , z ) {\displaystyle U(x,y,z)} present in the space, in the first approximation, the perturbed state is described by the equation ∇ 2 ψ ( 1 ) + k 2 ψ ( 1 ) = 2 m U ℏ 2 ψ ( 0 ) , {\displaystyle \nabla ^{2}\psi ^{(1)}+k^{2}\psi ^{(1)}={\frac {2mU}{\hbar ^{2}}}\psi ^{(0)},} whose particular integral is ψ ( 1 ) ( x , y , z ) = − m 2 π ℏ 2 ∫ ψ ( 0 ) U ( x ′ , y ′ , z ′ ) e i k r r d x ′ d y ′ d z ′ , {\displaystyle \psi ^{(1)}(x,y,z)=-{\frac {m}{2\pi \hbar ^{2}}}\int \psi ^{(0)}U(x',y',z'){\frac {e^{ikr}}{r}}\,dx'dy'dz',} where r 2 = ( x − x ′ ) 2 + ( y − y ′ ) 2 + ( z − z ′ ) 2 {\displaystyle r^{2}=(x-x')^{2}+(y-y')^{2}+(z-z')^{2}} . In the two-dimensional case, the solution is ψ ( 1 ) ( x , y ) = − i m 2 ℏ 2 ∫ ψ ( 0 ) U ( x ′ , y ′ ) H 0 ( 1 ) ( k r ) d x ′ d y ′ , {\displaystyle \psi ^{(1)}(x,y)=-{\frac {im}{2\hbar ^{2}}}\int \psi ^{(0)}U(x',y')H_{0}^{(1)}(kr)\,dx'dy',} where r 2 = ( x − x ′ ) 2 + ( y − y ′ ) 2 {\displaystyle r^{2}=(x-x')^{2}+(y-y')^{2}} and H 0 ( 1 ) {\displaystyle H_{0}^{(1)}} is the Hankel function of the first kind. In the one-dimensional case, the solution is ψ ( 1 ) ( x ) = − i m ℏ 2 ∫ ψ ( 0 ) U ( x ′ ) e i k r k d x ′ , {\displaystyle \psi ^{(1)}(x)=-{\frac {im}{\hbar ^{2}}}\int \psi ^{(0)}U(x'){\frac {e^{ikr}}{k}}\,dx',} where r = | x − x ′ | {\displaystyle r=|x-x'|} . == Applications == Rabi cycle Fermi's golden rule Muon spin spectroscopy Perturbed angular correlation == References == == External links == "L1.1 General problem. Non-degenerate perturbation theory". YouTube. MIT OpenCourseWare. 14 February 2019. Archived from the original on 2021-12-12. (lecture by Barton Zwiebach) "L1.2 Setting up the perturbative equations". YouTube. MIT OpenCourseWare. 14 February 2019. Archived from the original on 2021-12-12. Quantum Physics Online - perturbation theory
Wikipedia/Perturbation_theory_(quantum_mechanics)
Tensor software is a class of mathematical software designed for manipulation and calculation with tensors. == Standalone software == SPLATT is an open source software package for high-performance sparse tensor factorization. SPLATT ships a stand-alone executable, C/C++ library, and Octave/MATLAB API. Cadabra is a computer algebra system (CAS) designed specifically for the solution of problems encountered in field theory. It has extensive functionality for tensor polynomial simplification including multi-term symmetries, fermions and anti-commuting variables, Clifford algebras and Fierz transformations, implicit coordinate dependence, multiple index types and many more. The input format is a subset of TeX. Both a command-line and a graphical interface are available. Tela is a software package similar to MATLAB and GNU Octave, but designed specifically for tensors. == Software for use with Mathematica == Tensor is a tensor package written for the Mathematica system. It provides many functions relevant for General Relativity calculations in general Riemann–Cartan geometries. Ricci is a system for Mathematica 2.x and later for doing basic tensor analysis, available for free. TTC Tools of Tensor Calculus is a Mathematica package for doing tensor and exterior calculus on differentiable manifolds. EDC and RGTC, "Exterior Differential Calculus" and "Riemannian Geometry & Tensor Calculus," are free Mathematica packages for tensor calculus especially designed but not only for general relativity. Tensorial "Tensorial 4.0" is a general purpose tensor calculus package for Mathematica. xAct: Efficient Tensor Computer Algebra for Mathematica. xAct is a collection of packages for fast manipulation of tensor expressions. GREAT is a free package for Mathematica that computes the Christoffel connection and the basic tensors of General Relativity from a given metric tensor. Atlas 2 for Mathematica is a powerful Mathematica toolbox which allows to do a wide range of modern differential geometry calculations GRTensorM is a computer algebra package for performing calculations in the general area of differential geometry. MathGR is a package to manipulate tensor and GR calculations with either abstract or explicit indices, simplify tensors with permutational symmetries, decompose tensors from abstract indices to partially or completely explicit indices and convert partial derivatives into total derivatives. TensoriaCalc is a tensor calculus package written for Mathematica 9 and higher, aimed at providing user-friendly functionality and a smooth consistency with the Mathematica language itself. As of January 2015, given a metric and the coordinates used, TensoriaCalc can compute Christoffel symbols, the Riemann curvature tensor, and Ricci tensor/scalar; it allows for user-defined tensors and is able to perform basic operations such as taking the covariant derivatives of tensors. TensoriaCalc is continuously under development due to time constraints faced by its developer. OGRe is a modern free and open-source Mathematica package for tensor calculus, released in 2021 for Mathematica 12.0 and later. It is designed to be both powerful and user-friendly, and is especially suitable for general relativity. OGRe allows performing arbitrarily complicated tensor operations, and automatically transforms between index configurations and coordinate systems behind the scenes as needed for each operation. == Software for use with Maple == GRTensorII is a computer algebra package for performing calculations in the general area of differential geometry. Atlas 2 for Maple is a modern differential geometry for Maple. DifferentialGeometry is a package which performs fundamental operations of calculus on manifolds, differential geometry, tensor calculus, General Relativity, Lie algebras, Lie groups, transformation groups, jet spaces, and the variational calculus. It is included with Maple. Physics is a package developed as part of Maple, which implements symbolic computations with most of the objects used in mathematical physics. It includes objects from general relativity (tensors, metrics, covariant derivatives, tetrads etc.), quantum mechanics (Kets, Bras, commutators, noncommutative variables) etc. == Software for use with Matlab == Tensorlab is a MATLAB toolbox for multilinear algebra and structured data fusion. Tensor Toolbox Multilinear algebra MATLAB software. MPCA and MPCA+LDA Multilinear subspace learning software: Multilinear principal component analysis. UMPCA Multilinear subspace learning software: Uncorrelated multilinear principal component analysis. UMLDA Multilinear subspace learning software: Uncorrelated multilinear discriminant analysis. == Software for use with Maxima == Maxima is a free open source general purpose computer algebra system which includes several packages for tensor algebra calculations in its core distribution. It is particularly useful for calculations with abstract tensors, i.e., when one wishes to do calculations without defining all components of the tensor explicitly. It comes with three tensor packages: itensor for abstract (indicial) tensor manipulation, ctensor for component-defined tensors, and atensor for algebraic tensor manipulation. == Software for use with R == Tensor is an R package for basic tensor operations. rTensor provides several tensor decomposition approaches. nnTensor provides several non-negative tensor decomposition approaches. ttTensor provides several tensor-train decomposition approaches. tensorBF is an R package for Bayesian Tensor decomposition. MTF Bayesian Multi-Tensor Factorization for data fusion and Bayesian versions of Tensor PCA and Tensor CCA. Software: MTF. == Software for use with Python == TensorLy provides several tensor decomposition approaches. OGRePy is Python port of the Mathematica package OGRe (see § Software for use with Mathematica), released in 2024 for Python 3.12 and later. It utilizes SymPy for symbolic computations and Jupyter as a notebook interface. OGRePy allows calculating arbitrary tensor formulas using any combination of addition, multiplication by scalar, trace, contraction, partial derivative, covariant derivative, and permutation of indices, and provides facilities for calculating various curvature tensors and geodesic equations. Tensorgrad, an open-source python package for symbolic tensor manipulation. Supports general symbolic tensor derivatives using Penrose graphical notation, and gaussian expectations via Isserlis' theorem. == Software for use with Julia == TensorDecompositions.jl provides several tensor decomposition approaches. TensorToolbox.jl provides several tensor decomposition approaches. This follows the functionality of MATLAB Tensor toolbox and Hierarchical Tucker Toolbox. ITensors.jl is a library for rapidly creating correct and efficient tensor network algorithms. This is the Julia version of ITensor, not a wrapper around the C++ version but full implementations by Julia language. == Software for use with SageMath == SageManifolds: tensor calculus on smooth manifolds; all SageManifolds code is included in SageMath since version 7.5; it allows for computations in various vector frames and coordinate charts, the manifold not being required to be parallelizable. == Software for use with Java == ND4J: N-dimensional arrays for the JVM is a Java library for basic tensor operations and scientific computing. Tensor: computation for regular or unstructured multi-dimensional tensors. Scalar entries are either in numeric or exact precision. API inspired by Mathematica. Java 8 library in with no external dependencies. == Libraries == Redberry is an open source computer algebra system designed for symbolic tensor manipulation. Redberry provides common tools for expression manipulation, generalized on tensorial objects, as well as tensor-specific features: indices symmetries, LaTeX-style input, natural dummy indices handling, multiple index types etc. The HEP package includes tools for Feynman diagrams calculation: Dirac and SU(N) algebra, Levi-Civita simplifications, tools for calculation of one-loop counterterms etc. Redberry is written in Java and provides extensive Groovy-based programming language. libxm is a lightweight distributed-parallel tensor library written in C. FTensor is a high performance tensor library written in C++. TL is a multi-threaded tensor library implemented in C++ used in Dynare++. The library allows for folded/unfolded, dense/sparse tensor representations, general ranks (symmetries). The library implements Faa Di Bruno formula and is adaptive to available memory. Dynare++ is a standalone package solving higher order Taylor approximations to equilibria of non-linear stochastic models with rational expectations. vmmlib is a C++ linear algebra library that supports 3-way tensors, emphasizing computation and manipulation of several tensor decompositions. Spartns is a Sparse Tensor framework for Common Lisp. FAstMat is a thread-safe general tensor algebra library written in C++ and specially designed for FEM/FVM/BEM/FDM element/edge wise computations. Cyclops Tensor Framework is a distributed memory library for efficient decomposition of tensors of arbitrary type and parallel MPI+OpenMP execution of tensor contractions/functions. TiledArray is a scalable, block-sparse tensor library that is designed to aid in rapid composition of high-performance algebraic tensor equation. It is designed to scale from a single multicore computer to a massively-parallel, distributed-memory system. libtensor is a set of performance linear tensor algebra routines for large tensors found in post-Hartree–Fock methods in quantum chemistry. ITensor features automatic contraction of matching tensor indices. It is written in C++ and has higher-level features for quantum physics algorithms based on tensor networks. Fastor is a high performance C++ tensor algebra library that supports tensors of any arbitrary dimensions and all their possible contraction and permutation thereof. It employs compile-time graph search optimisations to find the optimal contraction sequence between arbitrary number of tensors in a network. It has high level domain specific features for solving nonlinear multiphysics problem using FEM. Xerus is a C++ tensor algebra library for tensors of arbitrary dimensions and tensor decomposition into general tensor networks (focusing on matrix product states). It offers Einstein notation like syntax and optimizes the contraction order of any network of tensors at runtime so that dimensions need not be fixed at compile-time. == References ==
Wikipedia/Tensor_software
In information theory, redundancy measures the fractional difference between the entropy H(X) of an ensemble X, and its maximum possible value log ⁡ ( | A X | ) {\displaystyle \log(|{\mathcal {A}}_{X}|)} . Informally, it is the amount of wasted "space" used to transmit certain data. Data compression is a way to reduce or eliminate unwanted redundancy, while forward error correction is a way of adding desired redundancy for purposes of error detection and correction when communicating over a noisy channel of limited capacity. == Quantitative definition == In describing the redundancy of raw data, the rate of a source of information is the average entropy per symbol. For memoryless sources, this is merely the entropy of each symbol, while, in the most general case of a stochastic process, it is r = lim n → ∞ 1 n H ( M 1 , M 2 , … M n ) , {\displaystyle r=\lim _{n\to \infty }{\frac {1}{n}}H(M_{1},M_{2},\dots M_{n}),} in the limit, as n goes to infinity, of the joint entropy of the first n symbols divided by n. It is common in information theory to speak of the "rate" or "entropy" of a language. This is appropriate, for example, when the source of information is English prose. The rate of a memoryless source is simply H ( M ) {\displaystyle H(M)} , since by definition there is no interdependence of the successive messages of a memoryless source. The absolute rate of a language or source is simply R = log ⁡ | M | , {\displaystyle R=\log |\mathbb {M} |,\,} the logarithm of the cardinality of the message space, or alphabet. (This formula is sometimes called the Hartley function.) This is the maximum possible rate of information that can be transmitted with that alphabet. (The logarithm should be taken to a base appropriate for the unit of measurement in use.) The absolute rate is equal to the actual rate if the source is memoryless and has a uniform distribution. The absolute redundancy can then be defined as D = R − r , {\displaystyle D=R-r,\,} the difference between the absolute rate and the rate. The quantity D R {\displaystyle {\frac {D}{R}}} is called the relative redundancy and gives the maximum possible data compression ratio, when expressed as the percentage by which a file size can be decreased. (When expressed as a ratio of original file size to compressed file size, the quantity R : r {\displaystyle R:r} gives the maximum compression ratio that can be achieved.) Complementary to the concept of relative redundancy is efficiency, defined as r R , {\displaystyle {\frac {r}{R}},} so that r R + D R = 1 {\displaystyle {\frac {r}{R}}+{\frac {D}{R}}=1} . A memoryless source with a uniform distribution has zero redundancy (and thus 100% efficiency), and cannot be compressed. == Other notions == A measure of redundancy between two variables is the mutual information or a normalized variant. A measure of redundancy among many variables is given by the total correlation. Redundancy of compressed data refers to the difference between the expected compressed data length of n {\displaystyle n} messages L ( M n ) {\displaystyle L(M^{n})\,\!} (or expected data rate L ( M n ) / n {\displaystyle L(M^{n})/n\,\!} ) and the entropy n r {\displaystyle nr\,\!} (or entropy rate r {\displaystyle r\,\!} ). (Here we assume the data is ergodic and stationary, e.g., a memoryless source.) Although the rate difference L ( M n ) / n − r {\displaystyle L(M^{n})/n-r\,\!} can be arbitrarily small as n {\displaystyle n\,\!} increased, the actual difference L ( M n ) − n r {\displaystyle L(M^{n})-nr\,\!} , cannot, although it can be theoretically upper-bounded by 1 in the case of finite-entropy memoryless sources. Redundancy in an information-theoretic contexts can also refer to the information that is redundant between two mutual informations. For example, given three variables X 1 {\displaystyle X_{1}} , X 2 {\displaystyle X_{2}} , and Y {\displaystyle Y} , it is known that the joint mutual information can be less than the sum of the marginal mutual informations: I ( X 1 , X 2 ; Y ) < I ( X 1 ; Y ) + I ( X 2 ; Y ) {\displaystyle I(X_{1},X_{2};Y)<I(X_{1};Y)+I(X_{2};Y)} . In this case, at least some of the information about Y {\displaystyle Y} disclosed by X 1 {\displaystyle X_{1}} or X 2 {\displaystyle X_{2}} is the same. This formulation of redundancy is complementary to the notion of synergy, which occurs when the joint mutual information is greater than the sum of the marginals, indicating the presence of information that is only disclosed by the joint state and not any simpler collection of sources. === Group redundancy === The above pairwise redundancy measure can be generalized to a set of n variables. R e d u n d a n c y = I ( X 1 , X 2 , . . . , X n ; Y ) − ( I ( X 1 ; Y ) + I ( X 2 ; Y ) + . . . I ( X n ; Y ) ) {\displaystyle Redundancy=I(X_{1},X_{2},...,X_{n};Y)-\left(I(X_{1};Y)+I(X_{2};Y)+...I(X_{n};Y)\right)} . As the pair-wise measure above, if this value is negative, one says the set of variables is redundant. == See also == Minimum redundancy coding Huffman encoding Data compression Hartley function Negentropy Source coding theorem Overcompleteness == References == Reza, Fazlollah M. (1994) [1961]. An Introduction to Information Theory. New York: Dover [McGraw-Hill]. ISBN 0-486-68210-2. Schneier, Bruce (1996). Applied Cryptography: Protocols, Algorithms, and Source Code in C. New York: John Wiley & Sons, Inc. ISBN 0-471-12845-7. Auffarth, B; Lopez-Sanchez, M.; Cerquides, J. (2010). "Comparison of Redundancy and Relevance Measures for Feature Selection in Tissue Classification of CT images". Advances in Data Mining. Applications and Theoretical Aspects. Springer. pp. 248–262. CiteSeerX 10.1.1.170.1528.
Wikipedia/Redundancy_(information_theory)
In mathematical physics, spacetime algebra (STA) is the application of Clifford algebra Cl1,3(R), or equivalently the geometric algebra G(M4) to physics. Spacetime algebra provides a "unified, coordinate-free formulation for all of relativistic physics, including the Dirac equation, Maxwell equation and General Relativity" and "reduces the mathematical divide between classical, quantum and relativistic physics.": ix  Spacetime algebra is a vector space that allows not only vectors, but also bivectors (directed quantities describing rotations associated with rotations or particular planes, such as areas, or rotations) or blades (quantities associated with particular hyper-volumes) to be combined, as well as rotated, reflected, or Lorentz boosted.: 40, 43, 97, 113  It is also the natural parent algebra of spinors in special relativity.: 333  These properties allow many of the most important equations in physics to be expressed in particularly simple forms, and can be very helpful towards a more geometric understanding of their meanings.: v  In comparison to related methods, STA and Dirac algebra are both Clifford Cl1,3 algebras, but STA uses real number scalars while Dirac algebra uses complex number scalars. The STA spacetime split is similar to the algebra of physical space (APS, Pauli algebra) approach. APS represents spacetime as a paravector, a combined 3-dimensional vector space and a 1-dimensional scalar.: 225–266  == Structure == For any pair of STA vectors, a , b {\textstyle a,b} , there is a vector (geometric) product a b {\textstyle ab} , inner (dot) product a ⋅ b {\textstyle a\cdot b} and outer (exterior, wedge) product a ∧ b {\textstyle a\wedge b} . The vector product is a sum of an inner and outer product:: 6  a ⋅ b = a b + b a 2 = b ⋅ a , a ∧ b = a b − b a 2 = − b ∧ a , a b = a ⋅ b + a ∧ b {\displaystyle a\cdot b={\frac {ab+ba}{2}}=b\cdot a,\quad a\wedge b={\frac {ab-ba}{2}}=-b\wedge a,\quad ab=a\cdot b+a\wedge b} The inner product generates a real number (scalar), and the outer product generates a bivector. The vectors a {\textstyle a} and b {\textstyle b} are orthogonal if their inner product is zero; vectors a {\textstyle a} and b {\textstyle b} are parallel if their outer product is zero.: 22–23  The orthonormal basis vectors are a timelike vector γ 0 {\textstyle \gamma _{0}} and 3 spacelike vectors γ 1 , γ 2 , γ 3 {\textstyle \gamma _{1},\gamma _{2},\gamma _{3}} . The Minkowski metric tensor's nonzero terms are the diagonal terms, ( η 00 , η 11 , η 22 , η 33 ) = ( 1 , − 1 , − 1 , − 1 ) {\textstyle (\eta _{00},\eta _{11},\eta _{22},\eta _{33})=(1,-1,-1,-1)} . For μ , ν = 0 , 1 , 2 , 3 {\textstyle \mu ,\nu =0,1,2,3} : γ μ ⋅ γ ν = γ μ γ ν + γ ν γ μ 2 = η μ ν , γ 0 ⋅ γ 0 = 1 , γ 1 ⋅ γ 1 = γ 2 ⋅ γ 2 = γ 3 ⋅ γ 3 = − 1 , otherwise γ μ γ ν = − γ ν γ μ {\displaystyle \gamma _{\mu }\cdot \gamma _{\nu }={\frac {\gamma _{\mu }\gamma _{\nu }+\gamma _{\nu }\gamma _{\mu }}{2}}=\eta _{\mu \nu },\quad \gamma _{0}\cdot \gamma _{0}=1,\ \gamma _{1}\cdot \gamma _{1}=\gamma _{2}\cdot \gamma _{2}=\gamma _{3}\cdot \gamma _{3}=-1,\quad {\text{ otherwise }}\ \gamma _{\mu }\gamma _{\nu }=-\gamma _{\nu }\gamma _{\mu }} The Dirac matrices share these properties, and STA is equivalent to the algebra generated by the Dirac matrices over the field of real numbers;: x  explicit matrix representation is unnecessary for STA. Products of the basis vectors generate a tensor basis containing one scalar { 1 } {\displaystyle \{1\}} , four vectors { γ 0 , γ 1 , γ 2 , γ 3 } {\displaystyle \{\gamma _{0},\gamma _{1},\gamma _{2},\gamma _{3}\}} , six bivectors { γ 0 γ 1 , γ 0 γ 2 , γ 0 γ 3 , γ 1 γ 2 , γ 2 γ 3 , γ 3 γ 1 } {\displaystyle \{\gamma _{0}\gamma _{1},\,\gamma _{0}\gamma _{2},\,\gamma _{0}\gamma _{3},\,\gamma _{1}\gamma _{2},\,\gamma _{2}\gamma _{3},\,\gamma _{3}\gamma _{1}\}} , four pseudovectors (trivectors) { I γ 0 , I γ 1 , I γ 2 , I γ 3 } {\displaystyle \{I\gamma _{0},I\gamma _{1},I\gamma _{2},I\gamma _{3}\}} and one pseudoscalar { I } {\displaystyle \{I\}} with I = γ 0 γ 1 γ 2 γ 3 {\textstyle I=\gamma _{0}\gamma _{1}\gamma _{2}\gamma _{3}} .: 11  The pseudoscalar commutes with all even-grade STA elements, but anticommutes with all odd-grade STA elements.: 6  == Subalgebra == STA's even-graded elements (scalars, bivectors, pseudoscalar) form a Clifford Cl3,0(R) even subalgebra equivalent to the APS or Pauli algebra.: 12  The STA bivectors are equivalent to the APS vectors and pseudovectors. The STA subalgebra becomes more explicit by renaming the STA bivectors ( γ 1 γ 0 , γ 2 γ 0 , γ 3 γ 0 ) {\textstyle (\gamma _{1}\gamma _{0},\gamma _{2}\gamma _{0},\gamma _{3}\gamma _{0})} as ( σ 1 , σ 2 , σ 3 ) {\textstyle (\sigma _{1},\sigma _{2},\sigma _{3})} and the STA bivectors ( γ 3 γ 2 , γ 1 γ 3 , γ 2 γ 1 ) {\textstyle (\gamma _{3}\gamma _{2},\gamma _{1}\gamma _{3},\gamma _{2}\gamma _{1})} as ( I σ 1 , I σ 2 , I σ 3 ) {\textstyle (I\sigma _{1},I\sigma _{2},I\sigma _{3})} .: 22 : 37  The Pauli matrices, σ ^ 1 , σ ^ 2 , σ ^ 3 {\textstyle {\hat {\sigma }}_{1},{\hat {\sigma }}_{2},{\hat {\sigma }}_{3}} , are a matrix representation for σ 1 , σ 2 , σ 3 {\textstyle \sigma _{1},\sigma _{2},\sigma _{3}} .: 37  For any pair of ( σ 1 , σ 2 , σ 3 ) {\textstyle (\sigma _{1},\sigma _{2},\sigma _{3})} , the nonzero inner products are σ 1 ⋅ σ 1 = σ 2 ⋅ σ 2 = σ 3 ⋅ σ 3 = 1 {\textstyle \sigma _{1}\cdot \sigma _{1}=\sigma _{2}\cdot \sigma _{2}=\sigma _{3}\cdot \sigma _{3}=1} , and the nonzero outer products are:: 37 : 16  σ 1 ∧ σ 2 = I σ 3 σ 2 ∧ σ 3 = I σ 1 σ 3 ∧ σ 1 = I σ 2 {\displaystyle {\begin{aligned}\sigma _{1}\wedge \sigma _{2}&=I\sigma _{3}\\\sigma _{2}\wedge \sigma _{3}&=I\sigma _{1}\\\sigma _{3}\wedge \sigma _{1}&=I\sigma _{2}\\\end{aligned}}} The sequence of algebra to even subalgebra continues as algebra of physical space, quaternion algebra, complex numbers and real numbers. The even STA subalgebra Cl+(1,3) of real space-time spinors in Cl(1,3) is isomorphic to the Clifford geometric algebra Cl(3,0) of Euclidean space R3 with basis elements. See the illustration of space-time algebra spinors in Cl+(1,3) under the octonionic product as a Fano plane. == Division == A nonzero vector a {\textstyle a} is a null vector (degree 2 nilpotent) if a 2 = 0 {\textstyle a^{2}=0} .: 2  An example is a = γ 0 + γ 1 {\textstyle a=\gamma ^{0}+\gamma ^{1}} . Null vectors are tangent to the light cone (null cone).: 4  An element b {\textstyle b} is an idempotent if b 2 = b {\textstyle b^{2}=b} .: 103  Two idempotents b 1 {\textstyle b_{1}} and b 2 {\textstyle b_{2}} are orthogonal idempotents if b 1 b 2 = 0 {\textstyle b_{1}b_{2}=0} .: 103  An example of an orthogonal idempotent pair is 1 2 ( 1 + γ 0 γ k ) {\displaystyle {\tfrac {1}{2}}(1+\gamma _{0}\gamma _{k})} and 1 2 ( 1 − γ 0 γ k ) {\displaystyle {\tfrac {1}{2}}(1-\gamma _{0}\gamma _{k})} with k = 1 , 2 , 3 {\textstyle k=1,2,3} . Proper zero divisors are nonzero elements whose product is zero such as null vectors or orthogonal idempotents.: 191  A division algebra is an algebra that contains multiplicative inverse (reciprocal) elements for every element, but this occurs if there are no proper zero divisors and if the only idempotent is 1.: 103 : 211  The only associative division algebras are the real numbers, complex numbers and quaternions.: 366  As STA is not a division algebra, some STA elements may lack an inverse; however, division by the non-null vector c {\textstyle c} may be possible by multiplication by its inverse, defined as c − 1 = ( c ⋅ c ) − 1 c {\displaystyle c^{-1}=(c\cdot c)^{-1}c} .: 14  == Reciprocal frame == Associated with the orthogonal basis { γ 0 , γ 1 , γ 2 , γ 3 } {\displaystyle \{\gamma _{0},\gamma _{1},\gamma _{2},\gamma _{3}\}} is the reciprocal basis set { γ 0 , γ 1 , γ 2 , γ 3 } {\displaystyle \{\gamma ^{0},\gamma ^{1},\gamma ^{2},\gamma ^{3}\}} satisfying these equations: : 63  γ μ ⋅ γ ν = δ μ ν , μ , ν = 0 , 1 , 2 , 3 {\displaystyle \gamma _{\mu }\cdot \gamma ^{\nu }=\delta _{\mu }^{\nu },\quad \mu ,\nu =0,1,2,3} These reciprocal frame vectors differ only by a sign, with γ 0 = γ 0 {\displaystyle \gamma ^{0}=\gamma _{0}} , but γ 1 = − γ 1 , γ 2 = − γ 2 , γ 3 = − γ 3 {\displaystyle \gamma ^{1}=-\gamma _{1},\ \ \gamma ^{2}=-\gamma _{2},\ \ \gamma ^{3}=-\gamma _{3}} . A vector a {\textstyle a} may be represented using either the basis vectors or the reciprocal basis vectors a = a μ γ μ = a μ γ μ {\displaystyle a=a^{\mu }\gamma _{\mu }=a_{\mu }\gamma ^{\mu }} with summation over μ = 0 , 1 , 2 , 3 {\displaystyle \mu =0,1,2,3} , according to the Einstein notation. The inner product of vector and basis vectors or reciprocal basis vectors generates the vector components. a ⋅ γ ν = a ν , ν = 0 , 1 , 2 , 3 a ⋅ γ ν = a ν , ν = 0 , 1 , 2 , 3 {\displaystyle {\begin{aligned}a\cdot \gamma ^{\nu }&=a^{\nu },\quad \nu =0,1,2,3\\a\cdot \gamma _{\nu }&=a_{\nu },\quad \nu =0,1,2,3\end{aligned}}} The metric and index gymnastics raise or lower indices: γ μ = η μ ν γ ν , μ , ν = 0 , 1 , 2 , 3 γ μ = η μ ν γ ν , μ , ν = 0 , 1 , 2 , 3 {\displaystyle {\begin{aligned}\gamma _{\mu }&=\eta _{\mu \nu }\gamma ^{\nu },\quad \mu ,\nu =0,1,2,3\\\gamma ^{\mu }&=\eta ^{\mu \nu }\gamma _{\nu },\quad \mu ,\nu =0,1,2,3\end{aligned}}} == Spacetime gradient == The spacetime gradient, like the gradient in a Euclidean space, is defined such that the directional derivative relationship is satisfied:: 45  a ⋅ ∇ F ( x ) = lim τ → 0 F ( x + a τ ) − F ( x ) τ . {\displaystyle a\cdot \nabla F(x)=\lim _{\tau \rightarrow 0}{\frac {F(x+a\tau )-F(x)}{\tau }}.} This requires the definition of the gradient to be ∇ = γ μ ∂ ∂ x μ = γ μ ∂ μ . {\displaystyle \nabla =\gamma ^{\mu }{\frac {\partial }{\partial x^{\mu }}}=\gamma ^{\mu }\partial _{\mu }.} Written out explicitly with x = c t γ 0 + x k γ k {\displaystyle x=ct\gamma _{0}+x^{k}\gamma _{k}} , these partials are ∂ 0 = 1 c ∂ ∂ t , ∂ k = ∂ ∂ x k {\displaystyle \partial _{0}={\frac {1}{c}}{\frac {\partial }{\partial t}},\quad \partial _{k}={\frac {\partial }{\partial {x^{k}}}}} == Spacetime split == In STA, a spacetime split is a projection from four-dimensional space into (3+1)-dimensional space in a chosen reference frame by means of the following two operations: a collapse of the chosen time axis, yielding a 3-dimensional space spanned by bivectors, equivalent to the standard 3-dimensional basis vectors in the algebra of physical space and a projection of the 4D space onto the chosen time axis, yielding a 1-dimensional space of scalars, representing the scalar time.: 180  This is achieved by pre-multiplication or post-multiplication by a timelike basis vector γ 0 {\displaystyle \gamma _{0}} , which serves to split a four vector into a scalar timelike and a bivector spacelike component, in the reference frame co-moving with γ 0 {\displaystyle \gamma _{0}} . With x = x μ γ μ {\displaystyle x=x^{\mu }\gamma _{\mu }} we have x γ 0 = x 0 + x k γ k γ 0 γ 0 x = x 0 − x k γ k γ 0 {\displaystyle {\begin{aligned}x\gamma _{0}&=x^{0}+x^{k}\gamma _{k}\gamma _{0}\\\gamma _{0}x&=x^{0}-x^{k}\gamma _{k}\gamma _{0}\end{aligned}}} Spacetime split is a method for representing an even-graded vector of spacetime as a vector in the Pauli algebra, an algebra where time is a scalar separated from vectors that occur in 3 dimensional space. The method replaces these spacetime vectors ( γ ) {\textstyle (\gamma )} : 22–24  As these bivectors γ k γ 0 {\displaystyle \gamma _{k}\gamma _{0}} square to unity, they serve as a spatial basis. Utilizing the Pauli matrix notation, these are written σ k = γ k γ 0 {\displaystyle \sigma _{k}=\gamma _{k}\gamma _{0}} . Spatial vectors in STA are denoted in boldface; then with x = x k σ k {\displaystyle \mathbf {x} =x^{k}\sigma _{k}} and x 0 = c t {\displaystyle x^{0}=ct} , the γ 0 {\displaystyle \gamma _{0}} -spacetime split x γ 0 {\displaystyle x\gamma _{0}} , and its reverse γ 0 x {\displaystyle \gamma _{0}x} are: x γ 0 = x 0 + x k σ k = c t + x γ 0 x = x 0 − x k σ k = c t − x {\displaystyle {\begin{aligned}x\gamma _{0}&=x^{0}+x^{k}\sigma _{k}=ct+\mathbf {x} \\\gamma _{0}x&=x^{0}-x^{k}\sigma _{k}=ct-\mathbf {x} \end{aligned}}} However, the above formulas only work in the Minkowski metric with signature (+ - - -). For forms of the spacetime split that work in either signature, alternate definitions in which σ k = γ k γ 0 {\displaystyle \sigma _{k}=\gamma _{k}\gamma ^{0}} and σ k = γ 0 γ k {\displaystyle \sigma ^{k}=\gamma _{0}\gamma ^{k}} must be used. == Transformations == To rotate a vector v {\displaystyle v} in geometric algebra, the following formula is used:: 50–51  v ′ = e − β θ 2 v e β θ 2 {\displaystyle v'=e^{-\beta {\frac {\theta }{2}}}\ v\ e^{\beta {\frac {\theta }{2}}}} , where θ {\displaystyle \theta } is the angle to rotate by, and β {\displaystyle \beta } is the normalized bivector representing the plane of rotation so that β β ~ = 1 {\displaystyle \beta {\tilde {\beta }}=1} . For a given spacelike bivector, β 2 = − 1 {\displaystyle \beta ^{2}=-1} , so Euler's formula applies,: 401  giving the rotation v ′ = ( cos ⁡ ( θ 2 ) − β sin ⁡ ( θ 2 ) ) v ( cos ⁡ ( θ 2 ) + β sin ⁡ ( θ 2 ) ) {\displaystyle v'=\left(\cos \left({\frac {\theta }{2}}\right)-\beta \sin \left({\frac {\theta }{2}}\right)\right)\ v\ \left(\cos \left({\frac {\theta }{2}}\right)+\beta \sin \left({\frac {\theta }{2}}\right)\right)} . For a given timelike bivector, β 2 = 1 {\displaystyle \beta ^{2}=1} , so a "rotation through time" uses the analogous equation for the split-complex numbers: v ′ = ( cosh ⁡ ( θ 2 ) − β sinh ⁡ ( θ 2 ) ) v ( cosh ⁡ ( θ 2 ) + β sinh ⁡ ( θ 2 ) ) {\displaystyle v'=\left(\cosh \left({\frac {\theta }{2}}\right)-\beta \sinh \left({\frac {\theta }{2}}\right)\right)\ v\ \left(\cosh \left({\frac {\theta }{2}}\right)+\beta \sinh \left({\frac {\theta }{2}}\right)\right)} . Interpreting this equation, these rotations along the time direction are simply hyperbolic rotations. These are equivalent to Lorentz boosts in special relativity. Both of these transformations are known as Lorentz transformations, and the combined set of all of them is the Lorentz group. To transform an object in STA from any basis (corresponding to a reference frame) to another, one or more of these transformations must be used.: 47–62  Any spacetime element A {\textstyle A} is transformed by multiplication with the pseudoscalar to form its dual element A I {\textstyle AI} .: 114  Duality rotation transforms spacetime element A {\textstyle A} to element A ′ {\textstyle A^{\prime }} through angle ϕ {\textstyle \phi } with pseudoscalar I {\textstyle I} is:: 13  A ′ = e I ϕ A {\displaystyle A^{\prime }=e^{I\phi }A} Duality rotation occurs only for non-singular Clifford algebra, non-singular meaning a Clifford algebra containing pseudoscalars with a non-zero square.: 13  Grade involution (main involution, inversion) transforms every r-vector A r {\textstyle A_{r}} to A r ∗ {\textstyle A_{r}^{\ast }} :: 13  A r ∗ = ( − 1 ) r A r {\displaystyle A_{r}^{\ast }=(-1)^{r}\ A_{r}} Reversion transformation occurs by decomposing any spacetime element as a sum of products of vectors and then reversing the order of each product.: 13  For multivector A {\textstyle A} arising from a product of vectors, a 1 a 2 … a r − 1 a r {\textstyle a_{1}a_{2}\ldots a_{r-1}a_{r}} the reversion is A † {\textstyle A^{\dagger }} : A = a 1 a 2 … a r − 1 a r , A † = a r a r − 1 … a 2 a 1 {\displaystyle A=a_{1}a_{2}\ldots a_{r-1}a_{r},\quad A^{\dagger }=a_{r}a_{r-1}\ldots a_{2}a_{1}} Clifford conjugation of a spacetime element A {\textstyle A} combines reversion and grade involution transformations, indicated as A ~ {\textstyle {\tilde {A}}} : A ~ = A ∗ † {\displaystyle {\tilde {A}}=A^{\ast \dagger }} The grade involution, reversion and Clifford conjugation transformations are involutions. == Classical electromagnetism == === The Faraday bivector === In STA, the electric field and magnetic field can be unified into a single bivector field, known as the Faraday bivector, equivalent to the Faraday tensor.: 230  It is defined as: F = E → + I c B → , {\displaystyle F={\vec {E}}+Ic{\vec {B}},} where E {\displaystyle E} and B {\displaystyle B} are the usual electric and magnetic fields, and I {\displaystyle I} is the STA pseudoscalar.: 230  Alternatively, expanding F {\displaystyle F} in terms of components, F {\displaystyle F} is defined that F = E i σ i + I c B i σ i = E 1 γ 1 γ 0 + E 2 γ 2 γ 0 + E 3 γ 3 γ 0 − c B 1 γ 2 γ 3 − c B 2 γ 3 γ 1 − c B 3 γ 1 γ 2 . {\displaystyle F=E^{i}\sigma _{i}+IcB^{i}\sigma _{i}=E^{1}\gamma _{1}\gamma _{0}+E^{2}\gamma _{2}\gamma _{0}+E^{3}\gamma _{3}\gamma _{0}-cB^{1}\gamma _{2}\gamma _{3}-cB^{2}\gamma _{3}\gamma _{1}-cB^{3}\gamma _{1}\gamma _{2}.} The separate E → {\displaystyle {\vec {E}}} and B → {\displaystyle {\vec {B}}} fields are recovered from F {\displaystyle F} using E = 1 2 ( F − γ 0 F γ 0 ) , I c B = 1 2 ( F + γ 0 F γ 0 ) . {\displaystyle {\begin{aligned}E={\frac {1}{2}}\left(F-\gamma _{0}F\gamma _{0}\right),\\IcB={\frac {1}{2}}\left(F+\gamma _{0}F\gamma _{0}\right).\end{aligned}}} The γ 0 {\displaystyle \gamma _{0}} term represents a given reference frame, and as such, using different reference frames will result in apparently different relative fields, exactly as in standard special relativity.: 233  Since the Faraday bivector is a relativistic invariant, further information can be found in its square, giving two new Lorentz-invariant quantities, one scalar, and one pseudoscalar: F 2 = E 2 − c 2 B 2 + 2 I c E → ⋅ B → . {\displaystyle F^{2}=E^{2}-c^{2}B^{2}+2Ic{\vec {E}}\cdot {\vec {B}}.} The scalar part corresponds to the Lagrangian density for the electromagnetic field, and the pseudoscalar part is a less-often seen Lorentz invariant.: 234  === Maxwell's equation === STA formulates Maxwell's equations in a simpler form as one equation,: 230  rather than the 4 equations of vector calculus.: 2–3  Similarly to the above field bivector, the electric charge density and current density can be unified into a single spacetime vector, equivalent to a four-vector. As such, the spacetime current J {\displaystyle J} is given by: 26  J = c ρ γ 0 + J i γ i , {\displaystyle J=c\rho \gamma _{0}+J^{i}\gamma _{i},} where the components J i {\displaystyle J^{i}} are the components of the classical 3-dimensional current density. When combining these quantities in this way, it makes it particularly clear that the classical charge density is nothing more than a current travelling in the timelike direction given by γ 0 {\displaystyle \gamma _{0}} . Combining the electromagnetic field and current density together with the spacetime gradient as defined earlier, we can combine all four of Maxwell's equations into a single equation in STA. : 230  The fact that these quantities are all covariant objects in the STA automatically guarantees Lorentz covariance of the equation, which is much easier to show than when separated into four separate equations. In this form, it is also much simpler to prove certain properties of Maxwell's equations, such as the conservation of charge. Using the fact that for any bivector field, the divergence of its spacetime gradient is 0 {\displaystyle 0} , one can perform the following manipulation:: 231  ∇ ⋅ [ ∇ F ] = ∇ ⋅ [ μ 0 c J ] 0 = ∇ ⋅ J . {\displaystyle {\begin{aligned}\nabla \cdot \left[\nabla F\right]&=\nabla \cdot \left[\mu _{0}cJ\right]\\0&=\nabla \cdot J.\end{aligned}}} This equation has the clear meaning that the divergence of the current density is zero, i.e. the total charge and current density over time is conserved. Using the electromagnetic field, the form of the Lorentz force on a charged particle can also be considerably simplified using STA.: 156  === Potential formulation === In the standard vector calculus formulation, two potential functions are used: the electric scalar potential, and the magnetic vector potential. Using the tools of STA, these two objects are combined into a single vector field A {\displaystyle A} , analogous to the electromagnetic four-potential in tensor calculus. In STA, it is defined as A = ϕ c γ 0 + A k γ k {\displaystyle A={\frac {\phi }{c}}\gamma _{0}+A^{k}\gamma _{k}} where ϕ {\displaystyle \phi } is the scalar potential, and A k {\displaystyle A^{k}} are the components of the magnetic potential. As defined, this field has SI units of webers per meter (V⋅s⋅m−1). The electromagnetic field can also be expressed in terms of this potential field, using 1 c F = ∇ ∧ A . {\displaystyle {\frac {1}{c}}F=\nabla \wedge A.} However, this definition is not unique. For any twice-differentiable scalar function Λ ( x → ) {\displaystyle \Lambda ({\vec {x}})} , the potential given by A ′ = A + ∇ Λ {\displaystyle A'=A+\nabla \Lambda } will also give the same F {\displaystyle F} as the original, due to the fact that ∇ ∧ ( A + ∇ Λ ) = ∇ ∧ A + ∇ ∧ ∇ Λ = ∇ ∧ A . {\displaystyle \nabla \wedge \left(A+\nabla \Lambda \right)=\nabla \wedge A+\nabla \wedge \nabla \Lambda =\nabla \wedge A.} This phenomenon is called gauge freedom. The process of choosing a suitable function Λ {\displaystyle \Lambda } to make a given problem simplest is known as gauge fixing. However, in relativistic electrodynamics, the Lorenz condition is often imposed, where ∇ ⋅ A → = 0 {\displaystyle \nabla \cdot {\vec {A}}=0} .: 231  To reformulate the STA Maxwell equation in terms of the potential A {\displaystyle A} , F {\displaystyle F} is first replaced with the above definition. 1 c ∇ F = ∇ ( ∇ ∧ A ) = ∇ ⋅ ( ∇ ∧ A ) + ∇ ∧ ( ∇ ∧ A ) = ∇ 2 A + ( ∇ ∧ ∇ ) A = ∇ 2 A + 0 = ∇ 2 A {\displaystyle {\begin{aligned}{\frac {1}{c}}\nabla F&=\nabla \left(\nabla \wedge A\right)\\&=\nabla \cdot \left(\nabla \wedge A\right)+\nabla \wedge \left(\nabla \wedge A\right)\\&=\nabla ^{2}A+\left(\nabla \wedge \nabla \right)A=\nabla ^{2}A+0\\&=\nabla ^{2}A\end{aligned}}} Substituting in this result, one arrives at the potential formulation of electromagnetism in STA:: 232  === Lagrangian formulation === Analogously to the tensor calculus formalism, the potential formulation in STA naturally leads to an appropriate Lagrangian density.: 453  The multivector-valued Euler-Lagrange equations for the field can be derived, and being loose with the mathematical rigor of taking the partial derivative with respect to something that is not a scalar, the relevant equations become:: 440  ∇ ∂ L ∂ ( ∇ A ) − ∂ L ∂ A = 0. {\displaystyle \nabla {\frac {\partial {\mathcal {L}}}{\partial \left(\nabla A\right)}}-{\frac {\partial {\mathcal {L}}}{\partial A}}=0.} To begin to re-derive the potential equation from this form, it is simplest to work in the Lorenz gauge, setting: 232  ∇ ⋅ A = 0. {\displaystyle \nabla \cdot A=0.} This process can be done regardless of the chosen gauge, but this makes the resulting process considerably clearer. Due to the structure of the geometric product, using this condition results in ∇ ∧ A = ∇ A {\displaystyle \nabla \wedge A=\nabla A} . After substituting in F = c ∇ A {\displaystyle F=c\nabla A} , the same equation of motion as above for the potential field A {\displaystyle A} is easily obtained. == The Pauli equation == STA allows the description of the Pauli particle in terms of a real theory in place of a matrix theory. The matrix theory description of the Pauli particle is: i ℏ ∂ t Ψ = H S Ψ − e ℏ 2 m c σ ^ ⋅ B Ψ , {\displaystyle i\hbar \,\partial _{t}\Psi =H_{S}\Psi -{\frac {e\hbar }{2mc}}\,{\hat {\sigma }}\cdot \mathbf {B} \Psi ,} where Ψ {\displaystyle \Psi } is a spinor, i {\displaystyle i} is the imaginary unit with no geometric interpretation, σ ^ i {\displaystyle {\hat {\sigma }}_{i}} are the Pauli matrices (with the 'hat' notation indicating that σ ^ {\displaystyle {\hat {\sigma }}} is a matrix operator and not an element in the geometric algebra), and H S {\displaystyle H_{S}} is the Schrödinger Hamiltonian. The STA approach transforms the matrix spinor representation | ψ ⟩ {\textstyle |\psi \rangle } to the STA representation ψ {\textstyle \psi } using elements, σ 1 , σ 2 , σ 3 {\textstyle \mathbf {\sigma _{1},\sigma _{2},\sigma _{3}} } , of the even-graded spacetime subalgebra and the pseudoscalar I = σ 1 σ 2 σ 3 {\displaystyle I=\sigma _{1}\sigma _{2}\sigma _{3}} :: 37 : 270, 271  | ψ ⟩ = [ c o s ( θ / 2 ) e - i ϕ / 2 s i n ( θ / 2 ) e + i ϕ / 2 ] = [ a 0 + i a 3 − a 2 + i a 1 ] ↦ ψ = a 0 + a 1 I σ 1 + a 2 I σ 2 + a 3 I σ 3 {\displaystyle |\psi \rangle ={\begin{bmatrix}\operatorname {cos(\theta /2)\ e^{-i\phi /2}} \\\operatorname {sin(\theta /2)\ e^{+i\phi /2}} \end{bmatrix}}={\begin{bmatrix}a^{0}+ia^{3}\\-a^{2}+ia^{1}\end{bmatrix}}\mapsto \psi =a^{0}+a^{1}\mathbf {I\sigma _{1}} +a^{2}\mathbf {I\sigma _{2}} +a^{3}\mathbf {I\sigma _{3}} } The Pauli particle is described by the real Pauli–Schrödinger equation: ∂ t ψ I σ 3 ℏ = H S ψ − e ℏ 2 m c B ψ σ 3 , {\displaystyle \partial _{t}\psi \,I\sigma _{3}\,\hbar =H_{S}\psi -{\frac {e\hbar }{2mc}}\,\mathbf {B} \psi \sigma _{3},} where now ψ {\displaystyle \psi } is an even multi-vector of the geometric algebra, and the Schrödinger Hamiltonian is H S {\displaystyle H_{S}} . Hestenes refers to this as the real Pauli–Schrödinger theory to emphasize that this theory reduces to the Schrödinger theory if the term that includes the magnetic field is dropped.: 30  The vector σ 3 {\textstyle \sigma _{3}} is an arbitrarily selected fixed vector; a fixed rotation can generate any alternative selected fixed vector σ 3 ′ {\textstyle \sigma _{3}^{\prime }} .: 30  == The Dirac equation == STA enables a description of the Dirac particle in terms of a real theory in place of a matrix theory. The matrix theory description of the Dirac particle is: γ ^ μ ( i ∂ μ − e A μ ) | ψ ⟩ = m | ψ ⟩ , {\displaystyle {\hat {\gamma }}^{\mu }(i\partial _{\mu }-e\mathbf {A} _{\mu })|\psi \rangle =m|\psi \rangle ,} where γ ^ {\displaystyle {\hat {\gamma }}} are the Dirac matrices and i {\textstyle i} is the imaginary unit with no geometric interpretation. Using the same approach as for Pauli equation, the STA approach transforms the matrix upper spinor | ψ U ⟩ {\textstyle |\psi _{U}\rangle } and matrix lower spinor | ψ L ⟩ {\textstyle |\psi _{L}\rangle } of the matrix Dirac bispinor | ψ ⟩ {\textstyle |\psi \rangle } to the corresponding geometric algebra spinor representations ψ U {\textstyle \psi _{U}} and ψ L {\textstyle \psi _{L}} . These are then combined to represent the full geometric algebra Dirac bispinor ψ {\textstyle \psi } .: 279  | ψ ⟩ = | | ψ U ⟩ | ψ L ⟩ | ↦ ψ = ψ U + ψ L σ 3 {\displaystyle |\psi \rangle ={\begin{vmatrix}|\psi _{U}\rangle \\|\psi _{L}\rangle \end{vmatrix}}\mapsto \psi =\psi _{U}+\psi _{L}\mathbf {\sigma _{3}} } Following Hestenes' derivation, the Dirac particle is described by the equation:: 283  Here, ψ {\displaystyle \psi } is the spinor field, γ 0 {\displaystyle \gamma _{0}} and I σ 3 {\displaystyle I\sigma _{3}} are elements of the geometric algebra, A {\displaystyle \mathbf {A} } is the electromagnetic four-potential, and ∇ = γ μ ∂ μ {\displaystyle \nabla =\gamma ^{\mu }\partial _{\mu }} is the spacetime vector derivative. === Dirac spinors === A relativistic Dirac spinor ψ {\textstyle \psi } can be expressed as:: 280  ψ = R ( ρ e i β ) 1 2 {\displaystyle \psi =R(\rho e^{i\beta })^{\frac {1}{2}}} where, according to its derivation by David Hestenes, ψ = ψ ( x ) {\displaystyle \psi =\psi (x)} is an even multivector-valued function on spacetime, R = R ( x ) {\displaystyle R=R(x)} is a unimodular spinor or "rotor", and ρ = ρ ( x ) {\displaystyle \rho =\rho (x)} and β = β ( x ) {\displaystyle \beta =\beta (x)} are scalar-valued functions. In this construction, the components of ψ {\displaystyle \psi } directly correspond with the components of a Dirac spinor, both having 8 scalar degrees of freedom. This equation is interpreted as connecting spin with the imaginary pseudoscalar.: 104–121  The rotor, R {\displaystyle R} , Lorentz transforms the frame of vectors γ μ {\displaystyle \gamma _{\mu }} into another frame of vectors e μ {\displaystyle e_{\mu }} by the operation e μ = R γ μ R † {\displaystyle e_{\mu }=R\gamma _{\mu }R^{\dagger }} ;: 15  note that R † {\textstyle R^{\dagger }} indicates the reverse transformation. This has been extended to provide a framework for locally varying vector- and scalar-valued observables and support for the Zitterbewegung interpretation of quantum mechanics originally proposed by Schrödinger.: vi  Hestenes has compared his expression for ψ {\displaystyle \psi } with Feynman's expression for it in the path integral formulation: ψ = e i Φ λ / ℏ , {\displaystyle \psi =e^{i\Phi _{\lambda }/\hbar },} where Φ λ {\displaystyle \Phi _{\lambda }} is the classical action along the λ {\displaystyle \lambda } -path. Using the spinors, the current density from the field can be expressed by: 8  J μ = ψ ¯ γ μ ψ {\displaystyle J^{\mu }={\bar {\psi }}\gamma ^{\mu }\psi } === Symmetries === Global phase symmetry is a constant global phase shift of the wave function that leaves the Dirac equation unchanged.: 41–48  Local phase symmetry is a spatially varying phase shift that leaves the Dirac equation unchanged if accompanied by a gauge transformation of the electromagnetic four-potential as expressed by these combined substitutions.: 269, 283  ψ ↦ ψ e α ( x ) I σ 3 , e A ↦ e A − ∇ α ( x ) {\displaystyle \psi \mapsto \psi e^{\alpha (x)I\sigma _{3}},\quad eA\mapsto eA-\nabla \alpha (x)} In these equations, the local phase transformation is a phase shift α ( x ) {\displaystyle \alpha (x)} at spacetime location x {\textstyle x} with pseudovector I {\textstyle I} and σ 3 {\textstyle \sigma _{3}} of even-graded spacetime subalgebra applied to wave function ψ {\textstyle \psi } ; the gauge transformation is a subtraction of the gradient of the phase shift ∇ α ( x ) {\textstyle \nabla \alpha (x)} from the electromagnetic four-potential A {\textstyle A} with particle electric charge e {\textstyle e} .: 269, 283  Researchers have applied STA and related Clifford algebra approaches to gauge theories, electroweak interaction, Yang–Mills theory, and the standard model.: 1345–1347  The discrete symmetries are parity ( P ^ ) {\textstyle ({\hat {P}})} , charge conjugation ( C ^ ) {\textstyle ({\hat {C}})} and time reversal ( T ^ ) {\textstyle ({\hat {T}})} applied to wave function ψ {\textstyle \psi } . These effects are:: 283  P ^ | ψ ⟩ ↦ γ 0 ψ ( γ 0 x γ 0 ) γ 0 C ^ | ψ ⟩ ↦ ψ σ 1 T ^ | ψ ⟩ ↦ I γ 0 ψ ( γ 0 x γ 0 ) γ 1 {\displaystyle {\begin{aligned}{\hat {P}}|\psi \rangle &\mapsto \gamma _{0}\psi (\gamma _{0}x\gamma _{0})\gamma _{0}\\{\hat {C}}|\psi \rangle &\mapsto \psi \sigma _{1}\\{\hat {T}}|\psi \rangle &\mapsto I\gamma _{0}\psi (\gamma _{0}x\gamma _{0})\gamma _{1}\end{aligned}}} == General relativity == === General relativity === Researchers have applied STA and related Clifford algebra approaches to relativity, gravity and cosmology.: 1343  The gauge theory gravity (GTG) uses STA to describe an induced curvature on Minkowski space while admitting a gauge symmetry under "arbitrary smooth remapping of events onto spacetime" leading to this geodesic equation. d d τ R = 1 2 ( Ω − ω ) R {\displaystyle {\frac {d}{d\tau }}R={\frac {1}{2}}(\Omega -\omega )R} and the covariant derivative D τ = ∂ τ + 1 2 ω , {\displaystyle D_{\tau }=\partial _{\tau }+{\frac {1}{2}}\omega ,} where ω {\displaystyle \omega } is the connection associated with the gravitational potential, and Ω {\displaystyle \Omega } is an external interaction such as an electromagnetic field. The theory shows some promise for the treatment of black holes, as its form of the Schwarzschild solution does not break down at singularities; most of the results of general relativity have been mathematically reproduced, and the relativistic formulation of classical electrodynamics has been extended to quantum mechanics and the Dirac equation. == See also == Geometric algebra Dirac algebra Maxwell's equations Dirac equation General relativity == Notes == == Citations == == References == == External links == Exploring Physics with Geometric Algebra, book I Exploring Physics with Geometric Algebra, book II A multivector Lagrangian for Maxwell's equation Imaginary numbers are not real – the geometric algebra of spacetime, a tutorial introduction to the ideas of geometric algebra, by S. Gull, A. Lasenby, C. Doran Physical Applications of Geometric Algebra course-notes, see especially part 2. Cambridge University Geometric Algebra group Geometric Calculus research and development
Wikipedia/Spacetime_algebra