Merge branch 'master' of github.com:thomasabishop/computer_science
|
|
@ -2,7 +2,7 @@
|
|||
tags: [algorithms]
|
||||
---
|
||||
|
||||

|
||||

|
||||
_Summary of the main classes of algorithmic complexity_
|
||||
|
||||
## Distinguish algorithms from programs
|
||||
|
|
@ -65,7 +65,7 @@ If we say that it takes 1ms for two integers to be summed, this gives us the fol
|
|||
| 4 | 4 |
|
||||
| 5 | 5 |
|
||||
|
||||
If we plotted this as a graph it is clear that this is equivalent to a linear distribution:
|
||||
If we plotted this as a graph it is clear that this is equivalent to a linear distribution:
|
||||
|
||||
Algorithms which display this distribution are therefore called **linear algorithms**.
|
||||
|
||||
|
|
@ -134,7 +134,7 @@ If the input had length 4, the runtime would be 16 or 4x4. For every execution o
|
|||
This is not a linear algorithm because as n grows the runtime increases as a factor of it. Therefore the runtime is not growing proportional to the size of the input, it is growing proportional to the size of the input squared.
|
||||
|
||||
Graphically this is represented with a curving lines as follows:
|
||||

|
||||

|
||||
|
||||
We can clearly see that as n grows, the runtime gets steeper and more pronounced,
|
||||
|
||||
|
|
@ -176,7 +176,7 @@ For example, with $\log 25$:
|
|||
|
||||
Back to algorithms: $O(\log n)$ is a really good complexity to have. It is close to O(1) and in between O(1) and O(n). Represented graphically, it starts of with a slight increase in runtime but then quickly levels off:
|
||||
|
||||

|
||||

|
||||
|
||||
Many sorting algorithms run in log n time, as does recursion.
|
||||
|
||||
|
|
@ -227,7 +227,7 @@ When seeking to simplify algorithms to their most general level of complexity, w
|
|||
|
||||
With this in mind we can break down the `findSum` function like so:
|
||||
|
||||

|
||||

|
||||
|
||||
This gives us:
|
||||
|
||||
|
|
|
|||
|
|
@ -5,48 +5,37 @@ categories:
|
|||
tags: [motherboard]
|
||||
---
|
||||
|
||||
#
|
||||
|
||||
# Bus
|
||||
|
||||
A bus is a communication system that transfers data between components inside a computer, or between computers.
|
||||
A bus is a communication system that transfers data between components inside a computer, or between computers. **A bus can be thought of as a kind of pipeline that allows different components of the computer to communicate with each other.**
|
||||
|
||||
Note that the use of the word "bus" varies somewhat in points of emphasis. A bus can mean:
|
||||
|
||||
- The physical wires that make up the bus
|
||||
- The logical communication channel that is established over those wires
|
||||
- TheBany\_.
|
||||
|
||||
## Main buses
|
||||
|
||||
### System bus
|
||||
|
||||
The primary pathway between the CPU and [memory](/Computer_Architecture/Memory/Memory.md). It comprises the **data bus** that transfers data from the memory to the CPU and the **address bus** which transmits requests from the CPU to memory.
|
||||
|
||||
### Internal bus
|
||||
|
||||
Connects local devices for example the harddisk to the CPU.
|
||||
|
||||
### External bus
|
||||
|
||||
Connects peripheral devices such as disks and printers to the [motherboard](/Electronics_and_Hardware/Motherboard.md)
|
||||
|
||||
### Expansion bus
|
||||
|
||||
Allows expansion boards to access the CPU and memory.
|
||||
|
||||
### Frontside bus
|
||||
|
||||
Main computer bus that determines data transfer rate speed and is the primary data transfer path between the CPU, RAM and other [motherboard](Electronics_and_Hardware/Motherboard.md) devices.
|
||||
|
||||
### Backside bus
|
||||
|
||||
Transfers secondary cache (L2 cache) data at faster speeds, allowing more efficient CPU operations
|
||||
| Bus type | Description |
|
||||
| ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| System bus | The primary pathway between the CPU and [memory](/Computer_Architecture/Memory/Memory.md). It comprises the **data bus** that transfers data from the memory to the CPU and the **address bus** which transmits requests from the CPU to memory. |
|
||||
| Internal bus | Connects local devices for example the harddisk to the CPU. |
|
||||
| External bus | Connects peripheral devices such as disks and printers to the [motherboard](/Electronics_and_Hardware/Motherboard.md) |
|
||||
| Expansion bus | Allows expansion boards to access the CPU and memory. |
|
||||
| Frontside bus | Main computer bus that determines data transfer rate speed and is the primary data transfer path between the CPU, RAM and other [motherboard](Electronics_and_Hardware/Motherboard.md) devices. |
|
||||
| Backside bus | Transfers secondary cache (L2 cache) data at faster speeds, allowing more efficient CPU operations |
|
||||
|
||||
## Bus standards
|
||||
|
||||
### Parallel and serial transmission types
|
||||
|
||||
There is a distinction between buses that use serial and buses that use parallel transmission. They are distinguished by the way in which data in the form of bits is transferred from one point to another, along the bus.
|
||||
There is a distinction between buses that use **serial** and buses that use **parallel transmission**. They are distinguished by the way in which the bits are transferred from one point to another, along the bus.
|
||||
|
||||
Serial Transmission is the type of transmission in which a single communication link is used to transfer the data from an end to another. On other hand Parallel Transmission is the transmission in which multiple parallel links are used that transmit each bit of data simultaneously.
|
||||
|
||||
<img src="../img/serial-transmission.jpg" width="800px"/>
|
||||
<img src="../img/parallel-transmission.jpg" width="800px"/>
|
||||
<img src="../_img/serial-transmission.jpg" width="800px"/>
|
||||
<img src="../_img/parallel-transmission.jpg" width="800px"/>
|
||||
|
||||
- Serial buses are cheaper to implement than parallel buses
|
||||
- Serial buses operate at greater [latency](/Computer_Architecture/Bus.md#latency) than parallel buses
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ This is the heart of the CPU; all the other components on the CPU chip are appen
|
|||
|
||||
Below is a schematic of a series of logical circuits within the CPU core:
|
||||
|
||||

|
||||

|
||||
|
||||
### Processor cores
|
||||
|
||||
|
|
@ -74,6 +74,6 @@ Each "cycle" is the execution of a process that commences once the [kernel](/Ope
|
|||
|
||||
Hertz was the scientist who detected electromagentic waves and more broadly in science, we use Hertz to measure the frequency of electromatic wave cycles in a signal.
|
||||
|
||||

|
||||

|
||||
|
||||
As the diagram above shows, a cycle is equal to one ascending and one descending crest. The more cycles per time unit, the greater the Hertz. We see the Hz increase as the number of cycles increases over time.
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ tags: [CPU, processors]
|
|||
|
||||
The [Little Man Computer](https://peterhigginson.co.uk/lmc/) is a simplified computer that works on Von Neuman principles. It has all the CPU components we have detailed above. It is programmed in machine code but for simplicity it uses the denary rather than the binary number system.
|
||||
|
||||

|
||||

|
||||
|
||||
On the left is the instruction set. Each number constitutes and execution routine and the `xx` stand for the address in RAM that the execution will work on.
|
||||
|
||||
|
|
|
|||
84
Computer_Architecture/Hardware_Description_Language.md
Normal file
|
|
@ -0,0 +1,84 @@
|
|||
---
|
||||
categories:
|
||||
- Computer Architecture
|
||||
- Hardware
|
||||
tags: [HDL, nand-to-tetris]
|
||||
---
|
||||
|
||||
# Hardware Description Language
|
||||
|
||||
An HDL is a declarative programming language used to describe the behaviour or structure of [digital circuits](/Electronics_and_Hardware/Digital_circuits/Integrated_circuits.md). They are used to simulate the circuit and check its response.
|
||||
|
||||
The hardware designer specifies a chip's logic by writing an HDL program which is then rigorously tested. At this stage, a [hardware simulator](/Computer_Architecture/Hardware_simulation.md) takes the HDL program as input and creates a software representation of the chip logic. The designer can instruct the simulator to test the virtual chip on various sets of inputs. This is done to check the chip's functionality but also to benchmark a variety of other parameters such as speed of computation and energy consumption.
|
||||
|
||||
There are many HDLs but the most popular are VHDL ("very high speed integrated-circuit description language") and Verilog.
|
||||
|
||||
## Usage in _NAND to Tetris_
|
||||
|
||||
We won't use an actual HDL language, instead we will use a simplified toy language called HDL that is simple enough that when it is used with a simulator, we can learn the main facets of chip design. Its syntax is very similar to VHDL.
|
||||
|
||||
## Demonstration of HDL program
|
||||
|
||||
### Boolean function to enact
|
||||
|
||||
We will create an HDL program for an XOR gate that is implemented through the following arrangement of NOT, AND, and OR gates:
|
||||
|
||||

|
||||
|
||||
### HDL file (`Xor.hdl`):
|
||||
|
||||
Here is our HDL file:
|
||||
|
||||
```vhdl
|
||||
/* Xor gate
|
||||
If a!=b out=1 else out=0
|
||||
*/
|
||||
CHIP Xor {
|
||||
IN a, b;
|
||||
OUT out;
|
||||
PARTS:
|
||||
Not (in=a, out=nota);
|
||||
Not (in=b, out=notb);
|
||||
And (a=a, b=notb, out=w1);
|
||||
And (a=nota, b=b, out=w2);
|
||||
Or (a=w1, b=w2, out=out)
|
||||
}
|
||||
```
|
||||
|
||||
#### Interface (`CHIP, IN, OUT`)
|
||||
|
||||
At the top level of the HDL program, the `CHIP` name and `IN`/`OUT` declaration is the _interface_ of the chip. Here we specify our naming convention for the `IN` and `OUT` values which we will refer to in the implementation declaration in `PARTS`.
|
||||
|
||||
#### Implementation (`PARTS`)
|
||||
|
||||
Everything under the `PARTS` section is the chip _implementation_. We can draw on composite gates in the `PARTS` declaration (e.g. `Not`, `And`, `Or`). The convention is to work from left to right when transcribing from a digital circuit diagram
|
||||
|
||||
#### Pins
|
||||
|
||||
In an HDL program we distinguish internal pins along with the standard [input and output pins](/Electronics_and_Hardware/Digital_circuits/Integrated_circuits.md). At the level of the interface, we are concerned only with input and output pins (in the example program these are `a`, `b` and `out`). It is at the level of the implementation that internal pins are encountered. In the example these are the connections between, e.g. the AND and NOT gates such as `And (a=a, b-notb, out=w1)`. This means the AND gate is receiving through its `a` pin the input `a` value and through its `b` pin the value of `b` inverted by a NOT. `out` is the value that is computed based on the input pins of `a` and `b`.
|
||||
|
||||
### Test file (`Xor.tst`)
|
||||
|
||||
Along with the HDL file we also create a test file. This runs the chip against the inputs we supply, these will typically be equivalent to the (left-hand) truth-values column in a truth table which is the same as the parameters passed to a [Boolean function](/Logic/Propositional_logic/Boolean_functions.md), for example:
|
||||
|
||||
```vhdl
|
||||
load Xor.hdl
|
||||
output-list a, b, out;
|
||||
set a 0, set b 0, eval, output;
|
||||
set a 0, set b 1, eval, output;
|
||||
set a 1, set b 0, eval, output;
|
||||
set a 1, set b =, eval, output;
|
||||
```
|
||||
|
||||
### Output file (`Xor.out`)
|
||||
|
||||
When the test file is run against the HDL file it will generate an output file. This is effectively the result of the unit test. And will take the form of a truth table:
|
||||
|
||||
```
|
||||
a | b | out
|
||||
-----------
|
||||
0 | 0 | 0
|
||||
0 | 1 | 1
|
||||
1 | 0 | 1
|
||||
1 | 1 | 0
|
||||
```
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
categories:
|
||||
- Computer Architecture
|
||||
- Hardware
|
||||
tags: [abstraction, modules]
|
||||
tags: [abstraction, modules, nand-to-tetris]
|
||||
---
|
||||
|
||||
# Hardware abstraction and modularity
|
||||
|
|
@ -24,4 +24,4 @@ When using a module as a building block you are to focus exclusively on the modu
|
|||
|
||||
The design of the diagram below emphasises the role of abstraction and modularity in the movement from transistors to chips:
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
57
Computer_Architecture/Hardware_simulation.md
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
---
|
||||
categories:
|
||||
- Computer Architecture
|
||||
- Hardware
|
||||
tags: [HDL, nand-to-tetris]
|
||||
---
|
||||
|
||||
# Hardware simulation
|
||||
|
||||
In order to test our [HDL](/Computer_Architecture/Hardware_Description_Language.md) files we load them into the hardware simulator program. We will demonstrate this with the following XOR implementation:
|
||||
|
||||

|
||||
|
||||
There are several simulation options:
|
||||
|
||||
- interactive
|
||||
- script-based (where we load a test script into the simulator along with the HDL file
|
||||
- comparative (running the HDL program against our intended output specified in the `.cmp` file)
|
||||
|
||||
The use-cases for each mode are based on the complexity of the chip you are evaluating. For a small chip, interactive and script-based testing would be sufficient but for much larger components like an ALU a comparative approach would be more manageable and efficient.
|
||||
|
||||
## Interactive
|
||||
|
||||
The image below shows a basic interactive usage of the simulator. We have uploaded the `Xor.hdl` file into the simulator and changed the input pins to `a=1, b=0` and clicked the calculator icon (representing "evaluation"). This then shows the output and internal pin values for these inputs.
|
||||
|
||||
<img src="/home/thomas/repos/computer_science/_img/hardware-sim-basic.png" >
|
||||
|
||||
## Script-based
|
||||
|
||||
This time we have clicked the script icon to load `Xor.tst`. This loads the test script into the main GUI panel on the left. We can step through each line of the test file and we will see the pin values update in accordance with the test.
|
||||
|
||||
When this is run it automatically generates an output file in the source directory at `Xor.out`. This can be viewed within the simulator via the 'View' drop down.
|
||||
|
||||

|
||||
|
||||
## Comparison-based
|
||||
|
||||
With a comparison-based approach to chip testing we run a comparison against the `.out` file that the simulator generates when running the HDL program against a `.cmp` comparison file that we provide. Both are simply truth-tables. For XOR if the program matched the comparison specification both `Xor.out` and `Xor.cmp` would look like the following:
|
||||
|
||||
```
|
||||
a | b | out
|
||||
-----------
|
||||
0 | 0 | 0
|
||||
0 | 1 | 1
|
||||
1 | 0 | 1
|
||||
1 | 1 | 0
|
||||
```
|
||||
|
||||
You don't have to do anything to apply the comparison since the compare file will already be loaded as part of the test file's set up:
|
||||
|
||||
```vhdl
|
||||
load Xor.hdl
|
||||
output file Xor.out
|
||||
compare-to Xor.cmp
|
||||
output-list a, b, out;
|
||||
set ...
|
||||
```
|
||||
|
|
@ -43,7 +43,7 @@ The table below details the relative speeds of the different types of memory and
|
|||
|
||||
The diagram below compares the different forms of memory within a computing device in terms of speed, monetary cost and capacity:
|
||||
|
||||

|
||||

|
||||
|
||||
## References
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ The following steps outline the way in which memory interacts with the processor
|
|||
|
||||
> This is a simplified account; it is not the case that only single requests are passed back and forth. This would be inefficient and time-wasting. The kernel sends to the CPU not just the first instruction in the requested file but also a number of instructions that immediately follow it.
|
||||
|
||||

|
||||

|
||||
|
||||
Every part of the above process - the journey accross the bus, the lookup in the controller, the operations on the DRAM, the journey back accross the bus - takes muliple CPU clock cycles.
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ tags:
|
|||
|
||||
_Visualization of the queue data structure_
|
||||
|
||||

|
||||

|
||||
|
||||
## A queue is a sequential data structure and most similar to a stack
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ More generally recursion means when a thing is defined in terms of itself. There
|
|||
## Schema
|
||||
|
||||
The general structure of a recursive function is as follows:
|
||||

|
||||

|
||||
|
||||
## Why use recursive functions?
|
||||
|
||||
|
|
@ -111,4 +111,4 @@ if (num > 0) {
|
|||
}
|
||||
```
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -6,10 +6,10 @@ tags:
|
|||
---
|
||||
|
||||
_A stack visualised vertically_
|
||||

|
||||

|
||||
|
||||
_A stack visualised horizontally_
|
||||

|
||||

|
||||
|
||||
## A stack is a linear data structure that observes LIFO
|
||||
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ server.listen().then(() => {
|
|||
|
||||
When we access the local URL we are able to access the Apollo server using the Explorer GUI. This automatically loads our schema and is basically a more fancy version of GraphiQL:
|
||||
|
||||

|
||||

|
||||
|
||||
It makes it easy to read descriptions of the dataypes and to construct queries by clicking to insert fields.
|
||||
|
||||
|
|
|
|||
|
|
@ -6,4 +6,4 @@ tags: [graphql]
|
|||
|
||||
# The journey of a GraphQL query
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ From the point of view of the backend, GraphQL is a **runtime** that provides a
|
|||
|
||||
Client requests are sent over HTTPS and the data is typically returned in the form of JSON:
|
||||
|
||||

|
||||

|
||||
|
||||
## Implementation overview
|
||||
|
||||
|
|
@ -83,15 +83,15 @@ With a REST API if you require multiple resources you have to make multiple requ
|
|||
|
||||
The REST scenario:
|
||||
|
||||

|
||||

|
||||
|
||||
The GraphQL scenario:
|
||||
|
||||

|
||||

|
||||
|
||||
### Abstraction of multiple services
|
||||
|
||||

|
||||

|
||||
|
||||
### Stops overfetching
|
||||
|
||||
|
|
|
|||
|
|
@ -44,4 +44,4 @@ When we run this, we call the `save` method on the Mongoose schema. We will then
|
|||
|
||||
This will also be reflected in Compass:
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -25,4 +25,4 @@ This will run continuously in the terminal and should say somewhere that it is w
|
|||
|
||||
_Compass_ is a graphical interface for viewing and interacting with the data in your Mongo database. It will automatically load to the default Mongo port: `27017`.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -61,10 +61,10 @@ const course = new Course({
|
|||
});
|
||||
```
|
||||
|
||||

|
||||

|
||||
|
||||
## Outcome
|
||||
|
||||
Having created a database, connected to it with Mongoose, and created a model we will see our collection reflected in Compass:
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -16,4 +16,4 @@ Although Mongo is not a relational database it has a structure that we can under
|
|||
|
||||
A document is a container comprising key-value pairs in the manner of an object.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ tags: [relational-database]
|
|||
|
||||
Tables, fields and records are the basic building blocks of databases
|
||||
|
||||

|
||||

|
||||
|
||||
## Table
|
||||
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ ON model.model_id = sales.model_id; -- Specify the match criteria
|
|||
|
||||
We can represent the logical relationship that obtains between the `sales` and `model` tables as follows:
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
## Outer joins
|
||||
|
|
@ -118,7 +118,7 @@ In the context of our dataset, in the _sales_ database we have a row where there
|
|||
|
||||
The logical relationship sustained between `sales` and `model` by a left inner join is represented in the following diagram:
|
||||
|
||||

|
||||

|
||||
|
||||
#### Implementation
|
||||
|
||||
|
|
@ -153,7 +153,7 @@ In the context of our dataset, in the _model_ database we have a row where there
|
|||
|
||||
The logical relationship sustained between `sales` and `model` by a right inner join is represented in the following diagram:
|
||||
|
||||

|
||||

|
||||
|
||||
#### Implementation
|
||||
|
||||
|
|
@ -191,7 +191,7 @@ In the context of our dataset it would result in the following table being gener
|
|||
|
||||
Represented by the following diagram:
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
#### Implementation
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ tags: [analogue, digital]
|
|||
|
||||
Analogue and digital are paradigms for recording information, specifically information about an object or state that obtains in the world.
|
||||
|
||||

|
||||

|
||||
|
||||
## Analogue
|
||||
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ Cells and batteries can be connected to each other in electrical ciruits to incr
|
|||
|
||||
The table below summarises the relative differences:
|
||||
|
||||

|
||||

|
||||
|
||||
### Series connections
|
||||
|
||||
|
|
@ -43,11 +43,11 @@ Thus series connections increase voltage but keep current constant.
|
|||
|
||||
_Series battery connection:_
|
||||
|
||||

|
||||

|
||||
|
||||
_Can be represented in a circuit diagram in one of the following two ways: as a series of cells or as a single battery:_
|
||||
|
||||

|
||||

|
||||
|
||||
In the case of **series opposing**, negative terminals are connected to each other and positive terminals are connected to each other in a series. This doesn't have many applications.
|
||||
|
||||
|
|
@ -67,11 +67,11 @@ $$
|
|||
|
||||
_Parallel battery connection:_
|
||||
|
||||

|
||||

|
||||
|
||||
_Parallel battery circuit diagram:_
|
||||
|
||||

|
||||

|
||||
|
||||
### Series-parrallel
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ An electrical circuit is a set of electrical components connected in such a way
|
|||
|
||||
Below is a basic circuit representing a 9-volt [battery](/Electronics_and_Hardware/Analogue_circuits/Cells_and_batteries.md#cells-and-batteries) with a 10,000$\Omega$ [resistor](/Electronics_and_Hardware/Analogue_circuits/Resistance.md) attached accross its terminals. Through the application of [Ohm's Law](/Electronics_and_Hardware/Physics_of_electricity/Ohms_Law.md) we can determine that the maximum current will be 0.9 miliamps.
|
||||
|
||||

|
||||

|
||||
|
||||
## Open and short circuits
|
||||
|
||||
|
|
@ -24,4 +24,4 @@ Sometimes circuits can be represented in a vertical manner rather than in an act
|
|||
|
||||
The circuit below is functionally identical to the previous circuit but represented vertically:
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ When the terminals are connected to each other via a conductor (e.g. copper wire
|
|||
|
||||
_The diagram below illustrates the flow of current where the circles are electrons knocking into each other and passing current:_
|
||||
|
||||

|
||||

|
||||
|
||||
> Electrons travel very slowly through a conductor. This is in contrast to their intrinsic motion which of course equal to the speed of light (186, 000 miles per second).
|
||||
|
||||
|
|
|
|||
|
|
@ -17,4 +17,4 @@ In circuit diagrams with simple DC current, ground is taken to be the negative t
|
|||
|
||||
The symbol for ground in circuit diagrams:
|
||||
|
||||
<img src="/home/thomas/repos/computer_science/img/ground-symbol.png" width="300px">
|
||||
<img src="/home/thomas/repos/computer_science/_img/ground-symbol.png" width="300px">
|
||||
|
|
|
|||
|
|
@ -8,10 +8,10 @@ tags: [electricity, electrical-circuits]
|
|||
|
||||
LED' stands for **Light Emitting Diode**, a [circuit]() component that emits light. The symbol for an LED is displayed below:
|
||||
|
||||

|
||||

|
||||
|
||||
A **diode** is a special kind of component that only permits current to flow through it in one direction. To achieve this it has very low resistance in one direction to allow current flow and high resistance in the other direction to impede current flow. This feature of diodes is clearly represented in the generic diode circuit symbol:
|
||||
|
||||

|
||||

|
||||
|
||||
An LED diode lights up when the right amount of current flows through it. A standard LED has a maximum current of 20mA. An appropriate [resistor](/Electronics_and_Hardware/Analogue_circuits/Resistance.md#resistors) must therefore be added to the circuit to ensure the current doesn't exeedd this amount.
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ The relationship between voltage rise and voltage drop is expressed in Kirchoff'
|
|||
|
||||
The application of the Law is illustrated in the following diagram:
|
||||
|
||||

|
||||

|
||||
|
||||
The explanation for the voltage drop at the positions $V^{A}$ and $V^{D}$ are obvious enough: they are at the beginning and end of the loop so are equal to the maximal voltage rise and minimal voltage drop, respectively.
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ Let's break down each column from the right:
|
|||
|
||||
### More examples to practise with
|
||||
|
||||

|
||||

|
||||
|
||||
## Binary multiplication
|
||||
|
||||
|
|
@ -64,10 +64,10 @@ When we multiply binary numbers in columns we multiply each of the top numbers b
|
|||
|
||||
An important difference is that when we move along the bottom row from the $2^0$, to $2^2$, to $2^4$ etc we must put a zero in the preceding column as a place holder. The sequence is shown below:
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ We can start with a limited palette: greyscale. Here there is black and white an
|
|||
|
||||
In decimal, 0 is equal to black (zero light intensity) and 255 is equal to white (full light intensity). Some examples of this (including binary and hex representations are below):
|
||||
|
||||

|
||||

|
||||
|
||||
### Colour encoding
|
||||
|
||||
|
|
@ -28,12 +28,12 @@ Some examples below
|
|||
|
||||
Red is represented in RGB with all 8 red bits to set to 1 and the remaining 16 bits for the other two colours set to 0.
|
||||
|
||||

|
||||

|
||||
|
||||
#### Yellow
|
||||
|
||||
Yellow is represented in RGB with both red and blue set to 1 and the remaining 8 green bits set to ):
|
||||
|
||||

|
||||

|
||||
|
||||
## Binary encoding of images
|
||||
|
|
|
|||
|
|
@ -87,11 +87,11 @@ If we have before us the binary place values ($1, 2, 4, 8$). We know that 6 is e
|
|||
|
||||
More clearly:
|
||||
|
||||

|
||||

|
||||
|
||||
And for comparison:
|
||||
|
||||

|
||||

|
||||
|
||||
Or we can express the binary as:
|
||||
|
||||
|
|
@ -105,4 +105,4 @@ $$ 2^1 + 2^2 $$
|
|||
|
||||
Let's convert 23 into binary:
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -103,6 +103,6 @@ $$
|
|||
= 15
|
||||
$$
|
||||
|
||||

|
||||

|
||||
|
||||
> Every four bits (or half byte) in binary corresponds to one symbol in hexadecimal. Therefore **a byte can be easily represented with two hexadecimal symbols, a 16-bit number can be represented with four hex symbols, a 32-bit number can represented with eight hex symbols and so on.**
|
||||
|
|
|
|||
|
|
@ -19,11 +19,11 @@ For example the two's complement of $0101$ (binary 5) is $1011$. There is a simp
|
|||
1. Take the unsigned number, and flip the bits. In other words: invert the values, so $0$ becomes $1$ and $1$ becomes $0$.
|
||||
2. Add one
|
||||
|
||||

|
||||

|
||||
|
||||
To translate a signed number to an unsigned number you flip them back and still add one:
|
||||
|
||||

|
||||

|
||||
|
||||
### Advantages
|
||||
|
||||
|
|
@ -66,7 +66,7 @@ Thus for a 4-bit number:
|
|||
|
||||
Then if we add the decimal equivalents of the place value together, we get our signed number. So in the case of $-3$:
|
||||
|
||||

|
||||

|
||||
|
||||
## Considerations
|
||||
|
||||
|
|
|
|||
|
|
@ -13,13 +13,13 @@ tags: [binary, bits]
|
|||
The reason is straight forward: it is the simplest way on the level of pure engineering of representing numerical and logical values; both of which are the basic foundations of programming. An electronic circuit or transistor only needs to represent two states: on (1) and off (0) which corresponds to the switch on an electrical circuit.
|
||||
A single circuit representing the binary values of 1 and 0:
|
||||
|
||||

|
||||

|
||||
|
||||
It would be much more complicated to have to represent ten different states under the decimal number system, although denary computers do exist.
|
||||
|
||||
If we want more digits, we just need to add in more circuits, and we can represent as large a binary number as we need. We just need one switch for every digit we want to represent. The switches used in modern computers are so cheap and so small that billions can be fitted on a single circuit board.
|
||||
|
||||

|
||||

|
||||
|
||||
When we use the term 'switch' we actually mean the transistor components of a circuit. We don't need to know the physical details at this level but we can say that a transistor turns a current on and off. They can also be used to amplify the current.
|
||||
|
||||
|
|
|
|||
|
|
@ -10,28 +10,18 @@ tags: [binary, memory, clock, electromagnetism]
|
|||
|
||||
In the examples of digital circuits so far (i.e [adders](/Electronics_and_Hardware/Digital_circuits/Half_adder_and_full_adder.md) and [latches](/Electronics_and_Hardware/Digital_circuits/Latches.md)) everything happens in a single instant or over several repeated instances. This is because of how simple the circuits are. In the case of latches only a single bit is updated. And even with rippled adders they are just a series of 1-bit updaters in a chain.
|
||||
|
||||
With more complex circuits that use multiple memory devices which store a series of bits at once, we need a way to ensure that the bits are set at the same time.
|
||||
|
||||
We synchronize multiple circuit components with a **clock signal**.
|
||||
|
||||
A clock signal alternates its voltage level from high to low on a regular cadence where it is high half the time and low the rest of the time. This gives the wave form a squared appearence.
|
||||
|
||||
With more complex circuits that use multiple memory devices which store a series of bits at once, we need a way to ensure that the bits are set at theB
|
||||
A single iteration of the volatage rising and falling is a **pulse**. A complete oscillation from low to high and back to low is a **cycle**. As with all [electromagnetic](/Electronics_and_Hardware/Physics_of_electricity/Electromagnetism.md) signals we measure the frequency of the wave in Hertz: cylcles per second. We also further distinguish the rising and falling edge of a pulse. Rising represents the signal passing from ground to its maximum voltage and falling is the reverse (the electrons moving from the voltage source to ground).
|
||||
|
||||
The diagram below shows a pulse cycle of 2Hz.
|
||||
|
||||

|
||||

|
||||
|
||||
## Linking components to the clock
|
||||
|
||||
- All components that need to be synchronised are connected to the clock
|
||||
- State changes in the component occur only when a clock pulse occurs
|
||||
- Clock-driven components will typically trigger their state c| J | K | Clock | Q state | Operation |
|
||||
|--- |--- |------- |--------------------------- |----------- |
|
||||
| 0 | 0 | Pulse | Maintain previous value | Hold |
|
||||
| 0 | 1 | Pulse | 0 | Reset |
|
||||
| 1 | 0 | Pulse | 1 | Set |
|
||||
| 1 | 1 | Pulse | Inverse of previous value | Toggle |hanges on either the rising edge or the falling edge of the pulse.
|
||||
- | Clock-driven components will typically trigger their state changes on either the rising edge or the falling edge of the pulse. |
|
||||
- Components that trigger state changes on the rising pulse are **positive edge-triggered**
|
||||
- Components that trigger state changes on the falling pulse are **negative edge-triggered**
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ tags: [logic-gates, binary, memory]
|
|||
|
||||
The [logic circuit](/Electronics_and_Hardware/Digital_circuits/Digital_circuits.md) below demonstrates how memory can be created using [NAND](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md#nand-gate) gates. A single bit is stored in memory.
|
||||
|
||||

|
||||

|
||||
Interactive version of circuit:
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/nand-mem?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="500" width="500" allowFullScreen></iframe>
|
||||
|
|
@ -35,7 +35,7 @@ Interactive version of circuit:
|
|||
|
||||
> Upshot: With **S** `ON`, output is the same as input
|
||||
|
||||

|
||||

|
||||
|
||||
### Second state: both S and I `ON`
|
||||
|
||||
|
|
@ -48,7 +48,7 @@ Interactive version of circuit:
|
|||
|
||||
> Upshot: With **S** on, the output is again the same as the input
|
||||
|
||||

|
||||

|
||||
|
||||
> So far we have seen that when **S** is `ON` you can change **I** on and off and **O** will change with it.
|
||||
|
||||
|
|
@ -60,4 +60,4 @@ The specific reason for this is that, if **S** is `OFF`, both **A** and **B** ar
|
|||
|
||||
This is illustrated in the diagram below. The space occupied by **A** and **B** remains on (note it is illuminated) regardless of the state of **I**.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ The possible state changes for the JK Flip-Flop are detailed below:
|
|||
|
||||
A JK Flip-Flop can execute on either the positive or negative pulse. Below are the diagrams for a rising and falling pulse respectively:
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
|
||||
|
|
@ -43,7 +43,7 @@ Thus the state table for the T Flip-Flop is:
|
|||
| 0 | Pulse | Maintain previous value | Hold |
|
||||
| 0 | Pulse | Inverse of previous value | Toggle |
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
<iframe src="https://withdiode.com/embed/4f015341-dc37-49e6-912a-42a580a1c92e" style="width:100%; height:500px; border:1px solid rgba(0,0,0,0.1); border-radius: 0.5rem; overflow:hidden;" title="LED & Switch" allow="accelerometer; ambient-light-sensor; camera; encrypted-media; geolocation; gyroscope; hid; microphone; midi; payment; usb; vr; xr-spatial-tracking" sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts" ></iframe>
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ We will achieve this by using three full adders and one half adder, moving from
|
|||
|
||||
Let's walk through the process:
|
||||
|
||||

|
||||

|
||||
|
||||
1. HA receives the bits $0$ and $1$ as inputs. It outputs $1$ as the sum bit and $0$ as the carry-out.
|
||||
2. FA1 receives $0$ as the carry-in bit plus $1$ and $1$ as its input. This means it has the following calculation to execute: $1 + 1 + 0$. This gives $0$ as the sum bit and $1$ as the carry-out bit.
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ The half adder receives two bits (A and B) which are to be added together. It ou
|
|||
|
||||
The diagram below shows the circuit representation of a half-adder and an example calculation. This calculation matches the ones column of the earlier binary addition example: $0011 + 0010$.
|
||||
|
||||

|
||||

|
||||
|
||||
### Implementation with logic gates
|
||||
|
||||
|
|
@ -88,7 +88,7 @@ And the carry-out bit replicates the truth conditions of [AND](/Electronics_and_
|
|||
|
||||
It is therefore possible to implement a half-adder with just these two logic gates:
|
||||
|
||||

|
||||

|
||||
|
||||
The digital circuit above has the same inputs and outputs as the half adder diagram above.
|
||||
|
||||
|
|
@ -104,7 +104,7 @@ The full adder takes in three inputs and has two outputs. It is identical to the
|
|||
| ---------------------------- | ----------------------------- | ------------------------ | ---------------------- | ---------------------------- |
|
||||
| The first number to be added | The second number to be added | The incoming carried bit | The sum bit (A+B+C_in) | The carry-out bit (A+B+C_in) |
|
||||
|
||||

|
||||

|
||||
|
||||
The diagram above is equivalent to the calculation taking place in the fours column. It has received a carry from the twos column ($1 + 1$ results in $1$ as a carry) and then adds this together with its own inputs ($0$ and $0$).
|
||||
|
||||
|
|
|
|||
|
|
@ -10,11 +10,13 @@ tags: [logic-gates]
|
|||
|
||||
An integrated circuit (IC) is a single unit that comprises several logic gates designed for the easy construction of [digital circuits](/Electronics_and_Hardware/Digital_circuits/Digital_circuits.md). The terms "integrated circuit" and "chip" are often used interchangeably.
|
||||
|
||||
An IC puts the gates on a single piece of silicon that has electrical contact points called pins. The type we will look at are called **dual in-line packages** (DIPs). They are rectangular wth two parallel rows of pins. The pins make it easy to connect DIPs to a breadboard.
|
||||
An IC puts the gates on a single piece of silicon that has electrical contact points called pins. There are two types of pins on an IC: input pins and output pins. Input pins are used to receive signals from other components in the circuit, while output pins are used to send signals to other components. The function of a pin is determined by the connection it has to the rest of the circuit and the type of signal it is intended to transmit or receive.
|
||||
|
||||
The type we will look at are called **dual in-line packages** (DIPs). They are rectangular wth two parallel rows of pins. The pins make it easy to connect DIPs to a breadboard.
|
||||
|
||||
_An integrated circuit and its use on a breadboard:_
|
||||
|
||||
<img align="left" width="200" src="/home/thomas/repos/computer_science/img/integrated-circuit.jpeg">
|
||||
<img width="200" src="/home/thomas/repos/computer_science/img/breadboard-DIP.jpg">
|
||||
<img align="left" width="200" src="/home/thomas/repos/computer_science/_img/integrated-circuit.jpeg">
|
||||
<img width="200" src="/home/thomas/repos/computer_science/_img/breadboard-DIP.jpg">
|
||||
|
||||
// TODO: Add diagrams of different IC gate types
|
||||
|
|
|
|||
|
|
@ -27,12 +27,9 @@ The SR Latch goes through the following state changes:
|
|||
|
||||
This is represented more clearly in the table below:
|
||||
|
||||
| S | R | Q | Operation |
|
||||
| --- | --- | ----------------------- | ------------- |
|
||||
| 0 | 0 | Maintain previous value | Hold |
|
||||
| 0 | 1 | 0 | Reset |
|
||||
| 1 | 0 | 1 | Set |
|
||||
| 1 | 1 | X | Invalid, null |
|
||||
| S | R | Q | Operation |
|
||||
| --- | --- | ----------------------- | ---------<iframe src="https://circuitverse.org/simulator/embed/multiplexor-5406f205-8ac7-4c5b-a1ba-861c5face8d3?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="500" width="500" allowFullScreen></iframe> |
|
||||
| 1 | 1 | X | Invalid, null |
|
||||
|
||||
The most succinct account of a latch:
|
||||
|
||||
|
|
@ -40,7 +37,7 @@ The most succinct account of a latch:
|
|||
|
||||
_The representation of an SR Latch in a digital circuit diagram_:
|
||||
|
||||

|
||||

|
||||
|
||||
## Creating a latch circuit
|
||||
|
||||
|
|
@ -50,7 +47,7 @@ The two gates are in a **cross-coupled configuration**. This basically means tha
|
|||
|
||||
The circuit is created as follows:
|
||||
|
||||

|
||||

|
||||
|
||||
Interactive version:
|
||||
|
||||
|
|
|
|||
|
|
@ -8,10 +8,33 @@ tags: [logic-gates, binary]
|
|||
|
||||
# Logic gates
|
||||
|
||||
> [A logic gate consists in] three connections where there may or may not be some electricity. Two of those connections are places where electricity may be put into the device, and the third connection is a place where electricity may come out of the device. (Scott, 2009 p.21)
|
||||
> [A logic gate consists in] three connections where there may or may not be some electricity. Two of those connections are places where electricity may be put into the device, and the third connection is a place where electricity may come out of the device.
|
||||
|
||||
Logic gates are the basic building blocks of digital computing. **A logic gate is an electrical circuit that has one or more than one input and only one output.** The input controls the output and the logic determining which types of input (on/off) lead to specific outputs (on/off) is identical to the truth-conditions of the [Boolean connectives](/Logic/Truth-functional_connectives.md) specifiable in terms of [truth-tables](/Logic/Truth-tables.md).
|
||||
Physically, what 'travels through' the gates is electrical current and what constitutes the 'gate' is a [transistor](/Electronics_and_Hardware/Digital_circuits/Transistors.md) responding to the current. At the next level of abstraction it is bits that go into the gate and bits which come out: binary information that may be either 1 or 0.
|
||||
[J.C. Scott. 2009. **But How Do It Know? The Basics of Computers for Everyone**, 21]
|
||||
|
||||
Logic gates are the basic building blocks of digital computing. **A logic gate is an electrical circuit that has one or more than one input and only one output.** The input and output points of the gate are [pins](/Electronics_and_Hardware/Digital_circuits/Integrated_circuits.md) The input controls the output and the logic determining which types of input (on/off) lead to specific outputs (on/off) is isomorphic with the truth-conditions of the [Boolean connectives](/Logic/Truth-functional_connectives.md) specifiable in terms of [truth tables](/Logic/Truth-tables.md).
|
||||
|
||||
Physically, what 'travels through' the gates is electrical current and what constitutes the 'gate' is a [transistor](/Electronics_and_Hardware/Digital_circuits/Transistors.md) responding to the current. Going up a level of abstraction, the current/ charge is identified with a [bit](/Electronics_and_Hardware/Binary/Binary_units_of_measurement.md#binary-units-of-measurement). It is bits that go into the gate and bits which come out: binary information that may be either 1 or 0.
|
||||
|
||||
## Elementary and composite gates
|
||||
|
||||
We distinguish elementary from composite logic gates. An elementary gate is a single gate embodying a single logical connective. It cannot be reduced any lower as a logical abstraction. A composite gate is a gate made up of more than one elementary gate and/or other composite gates.
|
||||
|
||||
An example of a composite gate would be a three-way AND. An AND with three inputs rather than the standard two that furnish the elementary AND gate. This gate would output 1 when all three gates have the value 1 and 0 otherwise. [Adders](/Electronics_and_Hardware/Digital_circuits/Half_adder_and_full_adder.md) and [latches](/Electronics_and_Hardware/Digital_circuits/Latches.md) whilst being [integrated circuits](/Electronics_and_Hardware/Digital_circuits/Integrated_circuits.md) are also, technically speaking, composite gates.
|
||||
|
||||
## Gate interface / gate implementation
|
||||
|
||||
The gate _interface_ is an abstraction that the enables the user to think of the gate simply in terms of inputs and outputs, without being concerned with the technical details of how this is achieved. How it is achieved is the gate _implementation_.
|
||||
|
||||
We can demonstrate this with the earlier example of a three-way AND. The diagram below represents the gate as an interface:
|
||||
|
||||
// TODO: Interface diagram
|
||||
|
||||
Whereas this diagram presents the implementation of the gate: it shows the specific combination of gates which creates the enables the behaviour represented in the interface diagram.
|
||||
|
||||
// TODO: Implementation diagram
|
||||
|
||||
> Importantly, a single interface may be implemented in a variety of ways. There is a one-to-many relationship at work here. From the point of view of the user interface these differences should not be detectable. This is another example of [hardware abstraction](/Computer_Architecture/Hardware_abstraction_and_modularity.md)
|
||||
|
||||
## NOT gate
|
||||
|
||||
|
|
@ -19,55 +42,61 @@ Physically, what 'travels through' the gates is electrical current and what cons
|
|||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | ~ P |
|
||||
| --- | --- |
|
||||
| T | F |
|
||||
| F | T |
|
||||
| $P$ | $\lnot P$ |
|
||||
| --- | --------- |
|
||||
| 1 | 0 |
|
||||
| 0 | 1 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/not-gate-aeb5f9e5-9f58-4883-b8e5-d70f6d023185?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
||||
## AND gate
|
||||
|
||||
> The AND gate represents the truth conditions of the [conjunction](/Logic/Truth-functional_connectives.md#conjunction) truth functional connective
|
||||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | Q | P & Q |
|
||||
| --- | --- | ----- |
|
||||
| T | T | T |
|
||||
| T | F | F |
|
||||
| F | T | F |
|
||||
| F | F | F |
|
||||
| $P$ | $Q$ | $P \land Q$ |
|
||||
| --- | --- | ----------- |
|
||||
| 1 | 1 | 1 |
|
||||
| 1 | 0 | 0 |
|
||||
| 0 | 0 | 0 |
|
||||
| 0 | 0 | 0 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/and-gate-b6937338-e83f-474b-af79-854b39c151a3?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
||||
## NAND gate
|
||||
|
||||
> The NAND gate inverts the truth conditions of AND.
|
||||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | Q | ~(P & Q) |
|
||||
| --- | --- | -------- |
|
||||
| T | T | F |
|
||||
| T | F | F |
|
||||
| F | T | F |
|
||||
| F | F | T |
|
||||
| $P$ | $Q$ | $\lnot(P \land Q)$ |
|
||||
| --- | --- | ------------------ |
|
||||
| 1 | 1 | 0 |
|
||||
| 1 | 0 | 0 |
|
||||
| 0 | 1 | 0 |
|
||||
| 0 | 0 | 1 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/nand-gate-60613ab9-9562-445e-9883-c4ea1920e206?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
||||
NAND is a **universal logic gate**: equipped with just a NAND we can represent every other possible logical condition. In practice with circuits, it is more efficient to use specific dedicated gates (i.e OR, AND, NOT etc) for the other Boolean connectives but in principle the same output can be achieved through NANDs alone.
|
||||
|
||||
## OR gate
|
||||
|
|
@ -76,57 +105,59 @@ NAND is a **universal logic gate**: equipped with just a NAND we can represent e
|
|||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | Q | P v Q |
|
||||
| --- | --- | ----- |
|
||||
| T | T | T |
|
||||
| T | F | T |
|
||||
| F | T | T |
|
||||
| F | F | F |
|
||||
| $P$ | $Q$ | $P \lor Q$ |
|
||||
| --- | --- | ---------- |
|
||||
| 1 | 1 | 1 |
|
||||
| 1 | 0 | 1 |
|
||||
| 0 | 1 | 1 |
|
||||
| 0 | 0 | 0 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/or-gate-087e4933-7963-482d-b4bf-9e130ef05706?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
||||
## XOR gate
|
||||
|
||||
> The OR gate represents the truth conditions of the exclusive OR
|
||||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | Q | ~(P <> Q) |
|
||||
| --- | --- | --------- |
|
||||
| T | T | F |
|
||||
| T | F | T |
|
||||
| F | T | T |
|
||||
| F | F | F |
|
||||
| $P$ | $Q$ | $\lnot(P \Leftrightarrow Q)$ |
|
||||
| --- | --- | ---------------------------- |
|
||||
| 1 | 1 | 0 |
|
||||
| 1 | 0 | 1 |
|
||||
| 0 | 1 | 1 |
|
||||
| 0 | 0 | 0 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/xor-gate-a240131e-a9c3-4240-a52b-e14412fdd654?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
||||
## NOR gate
|
||||
|
||||
> The NOR gate inverts the function of an OR gate
|
||||
|
||||
### Symbol
|
||||
|
||||

|
||||

|
||||
|
||||
### Truth conditions
|
||||
|
||||
| P | Q | P v Q |
|
||||
| --- | --- | ----- |
|
||||
| T | T | F |
|
||||
| T | F | F |
|
||||
| F | T | F |
|
||||
| F | F | T |
|
||||
| $P$ | $Q$ | $P \lor Q$ |
|
||||
| --- | --- | ---------- |
|
||||
| 1 | 1 | 0 |
|
||||
| 1 | 0 | 0 |
|
||||
| 0 | 1 | 0 |
|
||||
| 0 | 0 | 1 |
|
||||
|
||||
### Interactive circuit
|
||||
|
||||
## References
|
||||
|
||||
Scott, J. Clark. 2009. _But how do it know?: the basic principles of computers for everyone_. Self-published.
|
||||
<iframe src="https://circuitverse.org/simulator/embed/nor-gate-ac7946b4-f5d0-4c87-afd1-a2e92326d006?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="250" width="500" allowFullScreen></iframe>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,32 @@
|
|||
---
|
||||
categories:
|
||||
- Electronics
|
||||
- Hardware
|
||||
tags: [logic-gates, binary, nand-to-tetris]
|
||||
---
|
||||
|
||||
# Multiplexers (MUX) and demultiplexers (DMUX)
|
||||
|
||||
## Multiplexer
|
||||
|
||||
> Multiplexing is the generic term used to describe the operation of sending one or more analogue or digital signals over a common transmission line at different times or speeds.
|
||||
|
||||
A multiplexer selects one of several input signals and forwards ths selected input to a single output line.
|
||||
|
||||
We have two inputs (A,B) plus a third input SEL (for "select"). Applying a value to SEL toggles the output between A and B.
|
||||
|
||||
Multiplexers can be used to build larger circuits by connecting the output of one multiplexer to the input of another. They are often used to implement data selection and switching in digital systems
|
||||
|
||||
// TODO: Add component diagram
|
||||
|
||||
### Programable gates
|
||||
|
||||
One of the main use cases of multiplexers is to implement programmable gates. These are gates where the logic can be switched. For example an ANDMUXOR gate uses the SEL value to toggle the operation of a gate between AND and OR for its two inputs A and B
|
||||
|
||||
## Demultiplexer
|
||||
|
||||
As the name suggests, a demultiplexer reverses the functionality of a multiplexer. It receives a single input and based on the selection of the SEL input it channels it to either an A or a B output.
|
||||
|
||||
We can think of it as a distributor of a value into one of several possible channels.
|
||||
|
||||
// TODO: Add component diagram
|
||||
|
|
@ -44,7 +44,7 @@ If we look at the pattern of each flip-flops' output we notice the following:
|
|||
This means that to construct a circuit that displays this behaviour we just have to use a [T flip-flop](/Electronics_and_Hardware/Digital_circuits/Flip_flops.md#t-flip-flops) since the only state change we need is a single bit toggle three times that retains its value.
|
||||
|
||||
Using these pulse patterns we can construct a circuit as follows:
|
||||

|
||||

|
||||
|
||||
<iframe src="https://circuitverse.org/simulator/embed/3-bit-counter-d33846e3-7538-427d-b4cc-dc64fdaf0af3?theme=default&display_title=false&clock_time=true&fullscreen=true&zoom_in_out=true" style="border-width:; border-style: solid; border-color:;" name="myiframe" id="projectPreview" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="500" width="600" allowFullScreen></iframe>
|
||||
|
||||
|
|
|
|||
|
|
@ -16,11 +16,11 @@ An electrical switch is inherently binary. When the switch is on, it acts like a
|
|||
|
||||
We can combine switches in a circuit to create analogs to logic gates.
|
||||
|
||||

|
||||

|
||||
|
||||
In the example above a simple AND gate is implemented with switches. Each switch is a conjunct and the current only flows if both switches are on, closing the circuit.
|
||||
|
||||

|
||||

|
||||
|
||||
In the example above is a circuit implementing an OR gate. The current flows just if one of the switches are on or if both of the switches are on but not if both switches are off.
|
||||
|
||||
|
|
@ -32,15 +32,15 @@ Thus instead of switches, modern digital circuits use transistors, a special ele
|
|||
|
||||
There are different types of transistors but the simplest for the purposes of explanation are **bipolar junction transistors**.
|
||||
|
||||

|
||||

|
||||
|
||||
A transistor works as follows: applying a small amount of current at the base allows a larger current to flow from the collector to the emitter. Relating this back to switches, applying current to the base is like turning the switch on. Removing this current is like turning the switch off.
|
||||
|
||||
The diagrams below show a transistor being used in a circuit to create 'on' and 'off' switch states alongside a switch based circuit.
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||
- $V^{in}$ is the voltage that electrically controls the switch-as-transistor
|
||||
- $V^{out}$ is the voltage we want to control: it will be high when the transistor is in the 'on' state and low otherwise
|
||||
|
|
@ -60,8 +60,8 @@ With the basic element of the transistor established, we can combine transistors
|
|||
|
||||
For example to create an [AND](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md#and-gate) gate we would have two voltage inputs going into two transistors that are connected in sequence. The two transistors create a continuous line going from the collector of one to the emitter of the other. If either voltage input is low then the voltage of the combined line is low (equivalent to the circuit being broken) and there is no current flowing.
|
||||
|
||||

|
||||

|
||||
|
||||
Below, an [OR](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md#or-gate) has been constructed with transistors. If a voltage is applied to the base of either transistor, the current reaches the V-out terminal.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ tags: [motherboard]
|
|||
|
||||
# Motherboard
|
||||
|
||||
<img src="../img/motherboard-pi.jpg" width="400px"/>
|
||||
<img src="../_img/motherboard-pi.jpg" width="400px"/>
|
||||
|
||||
The motherboard is the foundation of a computer. It allocates power and allows communication to and between the [CPU](/Computer_Architecture/CPU/Von_Neumann_architecture.md), [RAM](/Computer_Architecture/Memory/Memory.md), [harddisk](/Operating_Systems/Disks/What_are_disks.md) and all other hardware components.
|
||||
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ Magnetism, understood as the effect of a magnetic field, arises from the propert
|
|||
|
||||
As they spin they produce a **magnetic dipole**: the two poles noted above. We call this propensity of electrons the **intrinsic magnetic moment** of the electron. It is aggregates of these miniature magnetic behaviours that produce the overall magnetic property of the material.
|
||||
|
||||

|
||||

|
||||
|
||||
In most materials, equal numbers of electrons spin in opposite directions. As a result, their magentic effects are cancelled out. However **in strongly magnetic materials an overall majority of electrons spin in one particular direction**. This breaks the equilibrium and produces the magnetic field.
|
||||
|
||||
|
|
@ -72,7 +72,7 @@ The magnetic field and force is more complex than the electric field/force. Wher
|
|||
|
||||
This is illustrated below which shows the magnetic field operating at right angles to the flow of charge within a wire.
|
||||
|
||||
<img src="/home/thomas/repos/computer_science/img/magnetic_field.png" width="300" />
|
||||
<img src="/home/thomas/repos/computer_science/_img/magnetic_field.png" width="300" />
|
||||
|
||||
## The electromagnetic field
|
||||
|
||||
|
|
@ -101,7 +101,7 @@ Maxwell's Equations describe how electromagnetic fields are generated and behave
|
|||
|
||||
Electromagnetic waves consist of rapidly changing electric and magnetic fields. They are emitted any time an electrically charged particle accelerates. These waves are generally referred to as light. However, more accurately, 'light' refers to the types of electromagnetic wave that we can see. Electromagnetic waves form a spectrum based on their frequency and wavelength. For example, 'radio waves' are low-frequency / long wavelength electromagnetic waves and gamma rays are high-frequency / short wavelength waves:
|
||||
|
||||

|
||||

|
||||
|
||||
The image below shows the propagation of an electromagnetic wave through space. We can identify the core components as follows
|
||||
|
||||
|
|
@ -109,7 +109,7 @@ The image below shows the propagation of an electromagnetic wave through space.
|
|||
- The magenetic field is perpendicular to the vector of the electric field $E$ which propagates upward along the $y$ axis
|
||||
- The directionality of both waves is forward along the $x$ axis
|
||||
|
||||

|
||||

|
||||
|
||||
## Using magnetism to generate electricity
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ Each shell can accomodate a maximum number of electrons. The shells are designat
|
|||
|
||||
_The diagram below demonstrates shell naming conventions and the maximum number of electrons per shell._
|
||||
|
||||

|
||||

|
||||
|
||||
## Valence
|
||||
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ tags: [physics]
|
|||
|
||||
## Atomic particles
|
||||
|
||||
<img src="/home/thomas/repos/computer_science/img/atom-diagram.svg" width="400" align="right" />
|
||||
<img src="/home/thomas/repos/computer_science/_img/atom-diagram.svg" width="400" align="right" />
|
||||
|
||||
* There are three particles comprising atoms: **protons**, **neutrons** and **electrons**.
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ We can use [ps](/Programming_Languages/Shell_Scripting/Processes.md) to list the
|
|||
|
||||
_Here I have pressed `u` to show only the processes associated with my user:_
|
||||
|
||||

|
||||

|
||||
|
||||
### Main commands
|
||||
|
||||
|
|
@ -96,7 +96,7 @@ procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
|
|||
|
||||
`lsof` stands for _list open files_. It lists opened files and the processes using them. Without modifiers it outputs a huge amount of data. The best way to use it is to execute it against a specific PID. For example the below output gives me some useful info about which files VS Code is using:
|
||||
|
||||

|
||||

|
||||
|
||||
## System calls: `strace`
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ tags: [journaling, systemd, systems-programming]
|
|||
|
||||
`journald` is a program that comes as default with [systemd](/Linux/systemd.md). It is a service fror collecting and storing system-level log data. I keeps a track of all [kernel](/Operating_Systems/The_Kernel.md) processes. It is invaluable when tracing the source of problems and errors that may arise on the system level. It keeps a track of all kernal processes.
|
||||
|
||||

|
||||

|
||||
|
||||
## `journalctl`
|
||||
|
||||
|
|
|
|||
|
|
@ -51,13 +51,13 @@ Units are managed via `systemd` configuration files.
|
|||
|
||||
System level `systemd` config files are located in the _system unit directory_ at `/usr/lib/systemd/system`. You shouldn't change or manipulate these files or attempt to add new config files here since they will be overwritten by the system.
|
||||
|
||||

|
||||

|
||||
_`systemd` global unit files_
|
||||
|
||||
|
||||
Local definitions that relate to the specific user and where the user herself can define units are located in the _system configuration_ directory: `/etc/systemd/system`.
|
||||
|
||||

|
||||

|
||||
|
||||
_`systemd` local unit files, specific to the currently logged-in user_
|
||||
|
||||
|
|
|
|||
|
|
@ -1,63 +0,0 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
---
|
||||
|
||||
## Informal definition
|
||||
|
||||
A set of sentences is consistent if and only if **it is possible for all the members of the set to be true at the same time**. A set of sentences is inconsistent if and only if it is not consistent.
|
||||
|
||||
### Demonstration
|
||||
|
||||
The following set of sentences form an inconsistent set:
|
||||
|
||||
```
|
||||
(1) Anyone who takes astrology seriously is a lunatic.
|
||||
(2) Alice is my sister and no sister of mine has a lunatic for a husband.
|
||||
(3) David is Alice's husband and he read's the horoscope column every morning.
|
||||
(4) Anyone who reads the horoscope column every morning takes astrology seriously.
|
||||
```
|
||||
|
||||
The set is inconsistent because not all of them can be true. If (1), (3), (4) are true, (2) cannot be. If (2), (3),(4) are true, (1) cannot be.
|
||||
|
||||
## Formal definition
|
||||
|
||||
> A finite set of sentences $\Gamma$ is truth-functionally consistent if and only if there is at least one truth-assignment in which all sentences of $\Gamma$ are true.
|
||||
|
||||
### Informal expression
|
||||
|
||||
```
|
||||
The book is blue or the book is brown
|
||||
The book is brown
|
||||
```
|
||||
|
||||
### Formal expression
|
||||
|
||||
```
|
||||
{P v Q, Q}
|
||||
```
|
||||
|
||||
### Truth-table
|
||||
|
||||
```
|
||||
P Q P ∨ Q Q
|
||||
T T T T *
|
||||
T F T F
|
||||
F T T T *
|
||||
F F F F
|
||||
```
|
||||
|
||||
## Derivation
|
||||
|
||||
> In terms of logical derivation, a finite $\Gamma$ of propositions is **inconsistent** in a system of derivation for propositional logic if and only if a sentence of the $P & \sim P$ is derivable from $\Gamma$. It is **consistent** just if this is not the case.
|
||||
|
||||
In other terms, if you can derive a contradiction from the set, the set is logically inconsistent.
|
||||
|
||||
A [contradiction](Logical%20truth%20and%20falsity.md#logical-falsity) contradiction has very important consequences for reasoning because if a set of propositions is inconsistent, every and all other propositions are derivable from that set.
|
||||
|
||||

|
||||
|
||||
_A demonstration of the the consequences of deriving a contradiction in a sequence of reasoning._
|
||||
|
||||
Here we want to derive some proposition $Q$. If we can derive a contradiction from its negation as an assumption then, by the [negation elimination](Negation%20Elimination.md) rule, we can assert $Q$. This is why contradictions should be avoided in arguments, they 'prove' everything which, by association, undermines any particular premise you are trying to assert.
|
||||
|
|
@ -1,49 +0,0 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
---
|
||||
|
||||
The vast majority of sentences in natural and formal logical languages are neither [ logically true](Logical%20truth%20and%20falsity.md#logical-truth) or [\| logically false](Logical%20truth%20and%20falsity.md#logical-falsity). This makes sense because sentences of this form are all either tautologies or contradictions and as such do not express information about the state of events in the world. We call sentences that are neither logically true or logically false, logically indeterminate sentences.
|
||||
|
||||
## Informal definition
|
||||
|
||||
A sentence is logically indeterminate if it is neither logically true or logically false. This is to say: it can be both [consistently](Consistency.md) asserted and consistently denied.
|
||||
|
||||
For example the sentence:
|
||||
|
||||
```
|
||||
It is raining.
|
||||
```
|
||||
|
||||
May be true or false thus it can it both be asserted and denied quite consistently. It is true if it actually is raining and false if it actually is not raining. There is no logical contradiction in saying it is raining when it isn't raining, this assertion is simply false. There is a contradiction in saying it is both states. Thus the sentence:
|
||||
|
||||
```
|
||||
It is raining and it is not raining.
|
||||
```
|
||||
|
||||
Cannot be consistently asserted as there is no possibility of the sentence being true. It is either raining or it isn't raining. Given the law for conjunction both conjuncts must be true for the sentence as a whole to be true. But in the case of this sentence if one conjunct is true, the other must be false and vice versa, hence it is not possible for the sentence to be true at all. It can _only_ be false.
|
||||
|
||||
Contrariwise the sentence:
|
||||
|
||||
```
|
||||
It is raining or it is not raining.
|
||||
```
|
||||
|
||||
Cannot be consistently denied as there is no possibility of it being false. It is either raining or not raining. Given the law for disjunction, either disjunct can be true to make the sentence as a whole true. Given that it is either raining or not raining in either scenario, the sentence as a whole will be true. Therefore there is no possibility of it being false, it can _only_ be true.
|
||||
|
||||
## Formal definition
|
||||
|
||||
> A sentence P is truth-functionally indeterminate if and only if it is neither truth-functionally true or truth-functionally false.
|
||||
|
||||
```
|
||||
P
|
||||
```
|
||||
|
||||
### Truth-table
|
||||
|
||||
```
|
||||
P P
|
||||
T T
|
||||
F F
|
||||
```
|
||||
64
Logic/General_concepts/Logical_consistency.md
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
---
|
||||
categories:
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Logical consistency
|
||||
|
||||
## Informal definition
|
||||
|
||||
A set of propositions is consistent if and only if **it is possible for all the members of the set to be true at the same time**. A set of propositions is inconsistent if and only if it is not consistent.
|
||||
|
||||
### Demonstration
|
||||
|
||||
The following set of propositions form an inconsistent set:
|
||||
|
||||
1. Anyone who takes astrology seriously is a lunatic.
|
||||
2. Alice is my sister and no sister of mine has a lunatic for a husband.
|
||||
3. David is Alice's husband and he read's the horoscope column every morning.
|
||||
4. Anyone who reads the horoscope column every morning takes astrology seriously.
|
||||
|
||||
The set is inconsistent because not all of them can be true. If (1), (3), (4) are true, (2) cannot be. If (2), (3),(4) are true, (1) cannot be.
|
||||
|
||||
## Formal definition
|
||||
|
||||
> A finite set of propositions $\Gamma$ is truth-functionally consistent if and only if there is at least one truth-assignment in which all propositions of $\Gamma$ are true.
|
||||
|
||||
### Informal expression
|
||||
|
||||
```
|
||||
The book is blue or the book is brown
|
||||
The book is brown
|
||||
```
|
||||
|
||||
### Formal expression
|
||||
|
||||
$$
|
||||
\{P \lor Q, Q\}
|
||||
$$
|
||||
|
||||
### Truth table
|
||||
|
||||
$ \{P, Q\} $ form a consistent set because there is at least one assignment when both propositions are true. In fact there are two (corresponding to each disjunct) but one is sufficient.
|
||||
|
||||
| $P$ | $Q$ | $ P \lor Q $ | $Q$ |
|
||||
| --- | --- | ------------ | --- |
|
||||
| T | T | T | T |
|
||||
| T | F | T | F |
|
||||
| F | T | T | T |
|
||||
| F | F | F | F |
|
||||
|
||||
## Derivation
|
||||
|
||||
> In terms of logical derivation, a finite $\Gamma$ of propositions is **inconsistent** in a system of derivation for propositional logic if and only if a proposition of the form $P \& \lnot P$ is derivable from $\Gamma$. It is **consistent** just if this is not the case.
|
||||
|
||||
In other terms, if you can derive a contradiction from the set, the set is logically inconsistent.
|
||||
|
||||
A [contradiction](/Logic/General_concepts/Logical_truth_and_falsity.md#logical-falsity) has very important consequences for reasoning because if a set of propositions is inconsistent, any other proposition is derivable from it.
|
||||
|
||||

|
||||
|
||||
_A demonstration of the the consequences of deriving a contradiction in a sequence of reasoning._
|
||||
|
||||
Here we want to derive some proposition $Q$. If we can derive a contradiction from its negation as an assumption then, by the [negation elimination](/Logic/Proofs/Negation_Elimination.md)) rule, we can assert $Q$. This is why contradictions should be avoided in arguments, they 'prove' everything which, by association, undermines any particular premise you are trying to assert.
|
||||
|
|
@ -1,48 +1,38 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Logical equivalence
|
||||
|
||||
> Two sentences, P and Q, are truth-functionally equivalent if and only if there is no truth assignment in which P is true and Q is false
|
||||
|
||||
### Informal expression
|
||||
|
||||
```
|
||||
P: If it is raining then the pavement will be wet.
|
||||
|
||||
Q: The pavement is not wet unless it is raining.
|
||||
```
|
||||
|
||||
### Formal expression
|
||||
|
||||
$$
|
||||
P \supset Q \equiv \sim P \lor Q
|
||||
(P \rightarrow Q) \longleftrightarrow (\lnot P \lor Q)
|
||||
$$
|
||||
|
||||
### Truth-tables
|
||||
|
||||
```
|
||||
P Q P ⊃ Q
|
||||
T T T
|
||||
T F F
|
||||
F T T
|
||||
F F T
|
||||
```
|
||||
|
||||
```
|
||||
P Q ~ P ∨ Q
|
||||
T T T
|
||||
T F F
|
||||
F T T
|
||||
F F T
|
||||
```
|
||||
| $P$ | $Q$ | $ P \rightarrow Q $ | $ \lnot P \lor Q$ |
|
||||
| --- | --- | ------------------- | ----------------- |
|
||||
| T | T | T | T |
|
||||
| T | F | T | F |
|
||||
| F | T | T | T |
|
||||
| F | F | F | T |
|
||||
|
||||
### Derivation
|
||||
|
||||
> Propositions $P$ and $Q$ are equivalent in a system of [derivation](Formal%20proofs%20in%20propositional%20logic.md) for propositional logic if $Q$ is derivable from $P$ and $P$ is derivable from $Q$.
|
||||
|
||||
Note that the property of equivalence stated in terms of derivablity above is identical to the derivation rule for the [material biconditional](Biconditional%20Introduction.md):
|
||||
Note that the property of equivalence stated in terms of derivablity above is identical to the derivation rule for the [material biconditional](/Logic/Proofs/Biconditional_Introduction.md):
|
||||
|
||||

|
||||
|
||||
//TODO: Add demonstration of this by deriving two equivalents from one of DeMorgan's Laws
|
||||

|
||||
|
|
|
|||
51
Logic/General_concepts/Logical_indeterminacy.md
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
---
|
||||
categories:
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Logical indeterminacy
|
||||
|
||||
The vast majority of propositions in natural and formal logical languages are **neither [logically true](/Logic/General_concepts/Logical_truth_and_falsity.md#logical-truth) or [logically false](/Logic/General_concepts/Logical_truth_and_falsity.md#logical-falsity)**. This makes sense because propositions of this form are all either tautologies or contradictions and as such do not express information about the state of events in the world. We call propositions that are neither logically true or logically false, **logically indeterminate** propositions.
|
||||
|
||||
## Informal definition
|
||||
|
||||
A proposition is logically indeterminate if it is neither logically true or logically false. This is to say: it can be both [consistently](Consistency.md) asserted and consistently denied.
|
||||
|
||||
For example the proposition:
|
||||
|
||||
```
|
||||
It is raining.
|
||||
```
|
||||
|
||||
May be true or false thus it can it both be asserted and denied quite consistently. It is true if it actually is raining and false if it actually is not raining. There is no logical contradiction implied by saying it is raining when it isn't raining, this assertion is simply false. There is a contradiction in saying that both states obtain. Thus the proposition:
|
||||
|
||||
```
|
||||
It is raining and it is not raining.
|
||||
```
|
||||
|
||||
Cannot be consistently asserted as there is no possibility of the proposition being true. It is either raining or it isn't raining. Given the law for conjunction, both conjuncts must be true for the proposition as a whole to be true. But in the case of this proposition if one conjunct is true, the other must be false and vice versa, hence it is not possible for the proposition to be true at all. It can _only_ be false.
|
||||
|
||||
Contrariwise the proposition:
|
||||
|
||||
```
|
||||
It is raining or it is not raining.
|
||||
```
|
||||
|
||||
Cannot be consistently denied as there is no possibility of it being false. It is either raining or not raining. Given the law for disjunction, either disjunct can be true to make the proposition as a whole true. Given that it is either raining or not raining in either scenario, the proposition as a whole will be true. Therefore there is no possibility of it being false, it can _only_ be true.
|
||||
|
||||
## Formal definition
|
||||
|
||||
> A proposition P is truth-functionally indeterminate if and only if it is neither truth-functionally true or truth-functionally false.
|
||||
> should be avoided in arguments, they 'prove' everything whi
|
||||
|
||||
```
|
||||
P
|
||||
```
|
||||
|
||||
### Truth-table
|
||||
|
||||
| $P$ | $P$ |
|
||||
| --- | --- |
|
||||
| T | T |
|
||||
| F | F |
|
||||
|
|
@ -1,12 +1,14 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Logical possibility and necessity
|
||||
|
||||
## Logical possibility
|
||||
|
||||
In distinguishing the properties of [logical consistency](Consistency.md) and [validity](Validity%20and%20entailment.md#validity) we make tacit use of the notion of **possibility**. This is because when we consider the validity of an argument we are assessing truth-conditions and this consists in asking ourselves what could or could not be the case: were it such that _P_, then it would be the case that _Q_. It is important to understand what possibility means in the context of logic and how it differs from what we might mean ordinarily when we use the term.
|
||||
In distinguishing the properties of [logical consistency](/Logic/General_concepts/Logical_consistency.md) and [validity](/Logic/General_concepts/Validity_and_entailment.md) we make tacit use of the notion of **possibility**. This is because when we consider the validity of an argument we are assessing truth-conditions and this consists in asking ourselves what could or could not be the case: were it such that _P_, then it would be the case that _Q_. It is important to understand what possibility means in the context of logic and how it differs from what we might mean ordinarily when we use the term.
|
||||
|
||||
It is evident from the case of arguments that are valid but not sound that logic operates with a specialised notion of possibility. For example it has to be the case that the proposition _Every woman can levitate_ is logically possible since the following argument is valid:
|
||||
|
||||
|
|
@ -32,6 +34,6 @@ From this we can derive the following property of logical possibility:
|
|||
|
||||
## Logical necessity
|
||||
|
||||
A sentence is _logically necessary_ if it is true in every logically possible circumstance which is to say: true on every possible truth functional assignment. Necessity and [ logical truth](Logical%20truth%20and%20falsity.md#logical-truth) are therefore synonyms: anything that is logically true (a tautology) is true by necessity (could not be otherwise.)
|
||||
A proposition is _logically necessary_ if it is true in every logically possible circumstance which is to say: true on every possible truth functional assignment. Necessity and [logical truth](/Logic/General_concepts/Logical_truth_and_falsity.md#logical-truth) are therefore synonyms: anything that is logically true (a tautology) is true by necessity (could not be otherwise.)
|
||||
|
||||
Further, every logical truth is logically possible but not everything that is logically possible is logically true. It is possible that it is raining but this is not logically necessary - it could be otherwise, i.e not raining. However it is not possible that it could be both raining and not raining.
|
||||
|
|
|
|||
|
|
@ -1,16 +1,18 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
We say of certain sentences that they are logically true or logically false.
|
||||
# Logical truth and falsity
|
||||
|
||||
We say of certain propositions that they are logically true or logically false.
|
||||
|
||||
## Logical falsity
|
||||
|
||||
### Informal definition
|
||||
|
||||
A sentence is logically false if and only if **it is not possible for the sentence to be true**. The sentence itself cannot be consistently asserted.
|
||||
A proposition is logically false if and only if **it is not possible for the proposition to be true**. The proposition itself cannot be consistently asserted.
|
||||
|
||||
**Demonstration**
|
||||
|
||||
|
|
@ -19,9 +21,7 @@ There is a country that is not a country.
|
|||
Apples are fruits and apples are not fruits
|
||||
```
|
||||
|
||||
Neither sentence can be true because the truth of the first clause is contradicted by the second. By the principle of [consistency](Consistency.md), it is not possible for both clauses to be true at once therefore the sentence, overall has the truth value of falsity
|
||||
|
||||
The examples above are simple sentences but logical falsity also applies to compound sentences and it is actually easier to see the logical principle at work with compound sentences since once simple sentence of the compound contradicts the other such that the overall sentence cannot be consistently asserted:
|
||||
Neither proposition can be true because the truth of the first clause is contradicted by the second. By the principle of [consistency](/Logic/General_concepts/Logical_consistency.md), it is not possible for both clauses to be true at once therefore the proposition, overall has the truth value of false.
|
||||
|
||||
```
|
||||
It is raining and it is not raining.
|
||||
|
|
@ -29,28 +29,24 @@ It is raining and it is not raining.
|
|||
|
||||
### Formal definition
|
||||
|
||||
> A sentence P is truth-functionally false if and only if P is false on every truth-value assignment
|
||||
> A proposition P is truth-functionally false if and only if P is false on every truth-value assignment
|
||||
|
||||
### Formal expression
|
||||
|
||||
```
|
||||
P & ~ P
|
||||
```
|
||||
$$ P \land \lnot P $$
|
||||
|
||||
### Truth-table
|
||||
|
||||
```
|
||||
Can
|
||||
P P & ~ P
|
||||
T F
|
||||
F F
|
||||
```
|
||||
| $P$ | $P \land \lnot P$ |
|
||||
| --- | ----------------- |
|
||||
| T | F |
|
||||
| T | F |
|
||||
|
||||
## Logical truth
|
||||
|
||||
### Informal definition
|
||||
|
||||
A sentence is logically true if and only if it is not possible for the sentence to be false. The sentence itself cannot be [consistently](Consistency.md) denied.
|
||||
A proposition is logically true if and only if it is not possible for the proposition to be false. The proposition itself cannot be consistently denied.
|
||||
|
||||
**Demonstration**
|
||||
|
||||
|
|
@ -59,35 +55,32 @@ A rose is a rose.
|
|||
Today is Tuesday unless today is not Tuesday.
|
||||
```
|
||||
|
||||
Regardless of any facts obtaining in the world, these sentences cannot be false.
|
||||
Regardless of any facts obtaining in the world, these propositions cannot be false.should be avoided in arguments, they 'prove' everything whi
|
||||
|
||||
As with logically false sentences, logical truth can also apply to compound sentences:
|
||||
As with logically false propositions, logical truth can also apply to compound propositions:
|
||||
|
||||
```
|
||||
It is Monday and Monday is a day of the week.
|
||||
A rose is a rose and a shoe is a shoe
|
||||
```
|
||||
|
||||
### Formal definition
|
||||
|
||||
> A sentence P is truth-functionally true if and only if P is true on every truth-value assignment
|
||||
> A proposition P is truth-functionally true if and only if P is true on every truth-value assignment
|
||||
|
||||
```
|
||||
P v ~P
|
||||
```
|
||||
$$ P \lor \lnot P$$
|
||||
|
||||
### Truth-table
|
||||
|
||||
```
|
||||
P P ∨ ¬ P
|
||||
T T
|
||||
F T
|
||||
```
|
||||
| $P$ | $P \lor \lnot P$ |
|
||||
| --- | ---------------- |
|
||||
| T | T |
|
||||
| F | T |
|
||||
|
||||
### Consequences
|
||||
|
||||
The existence of logically false and logically true sentences affects the validity and soundness of arguments in which they are used. These are technicalities that have philosophically interesting consequences.
|
||||
The existence of logically false and logically true propositions affects the validity and soundness of arguments in which they are used. These are technicalities that have philosophically interesting consequences.
|
||||
|
||||
- If an argument contains premises which are logically false than this argument will perforce be valid. This is because one cannot consistently assert the premises and deny the conclusion which is the definition of validity. However the _reason_ why one cannot consistently assert the premises and deny the conclusions is because one cannot consistently assert the premises - they conflict with each other. Furthermore as the argument contains false premises, it cannot be sound.
|
||||
- If an argument contains premises which are logically false than this argument will perforce be valid. This is because one cannot consistently assert the premises and deny the conclusion which is the definition of [validity](/Logic/General_concepts/Validity_and_entailment.md). However the _reason_ why one cannot consistently assert the premises and deny the conclusions is because one cannot consistently assert the premises - they conflict with each other. Furthermore as the argument contains false premises, it cannot be sound.
|
||||
|
||||
```
|
||||
(P1) Russia is a country.
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
## Object and metalanguages
|
||||
# Object and metalanguages
|
||||
|
||||
When we talk about a language we call that language the **object language**. A **metalanguage** is a language used to describe some object language.
|
||||
|
||||
|
|
@ -28,4 +28,4 @@ When we create an expression in a language we are said to _use_ that language. W
|
|||
|
||||
A metalinguistic variable (metavariable for short) is an expression in the metalanguage that is used to talk generally about expressions of the object language. The convention in these notes will be to embolden single letters when these letters are used as metavariables.
|
||||
|
||||
For example, instead of saying _'P & Q' is an expression comprising two atomic sentences and a conjunction_ we might say **\*P** is an expression comprising two atomic sentences and a conjunction.\* In this instance **P** is a metavariable in the metalanguage mentioning the expression P & Q in the object language
|
||||
For example, instead of saying _'P & Q' is an expression comprising two atomic sentences and a conjunction_ we might say **\*P** is an expression comprising two atomic sentences and a conjunction. In this instance **P** is a metavariable in the metalanguage mentioning the expression P & Q in the object language
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
### Soundness
|
||||
# Soundness
|
||||
|
||||
Recall that in the definition of [deductive validity](Validity%20and%20entailment.md#validity) we do not say: an argument is valid iff if the premises _are true_ and the conclusion _is true_. We say _if it is possible for the premises to be true_. This is important: we are not interested in the actual truth of the premises or the conclusion.
|
||||
Recall that in the definition of [deductive validity](/Logic/General_concepts/Validity_and_entailment.md#validity) we do not say: an argument is valid iff if the premises _are true_ and the conclusion _is true_. We say _if it is possible for the premises to be true_. This is important: we are not interested in the actual truth of the premises or the conclusion.
|
||||
|
||||
#### Demonstration
|
||||
|
||||
|
|
@ -32,20 +32,19 @@ ____________________________________________
|
|||
|
||||
The difference here is that the premises happen to be true and, given that the argument is valid, the conclusion must also be true. What we have defined here is **soundness**: the argument is said to be sound as well as valid. This is an additional and stronger criterion of evaluation.
|
||||
|
||||
> An argument is sound if and only if it is deductively valid and all it's premises are true.
|
||||
> An argument is sound if and only if it is deductively valid and all its premises are true.
|
||||
|
||||
We must not forget that truth alone is not the sole condition for soundness. We can have arguments whose conclusion and premises are all true without the argument being sound:
|
||||
|
||||
```
|
||||
(P1) London is the capital of the United Kingdom
|
||||
(P2) The capital of the United Kingdom is in the southern part of the United Kingdom.
|
||||
Can
|
||||
(P3) Cambridge is not the capital of the United Kingdom
|
||||
____________________________________________
|
||||
(C) London is south of Cambridge
|
||||
```
|
||||
|
||||
All sentences are true here but the argument is not deductively valid: the premises are all true but the conclusion is false.
|
||||
All propositions are true here but the argument is not deductively valid: the premises are all true but the conclusion is false.
|
||||
|
||||
We can also have arguments which are valid but which are not sound:
|
||||
|
||||
|
|
@ -56,4 +55,4 @@ ____________________________________________
|
|||
(C) Vitamin C is harmless
|
||||
```
|
||||
|
||||
This argument is valid because we cannot consistently assert the premises and deny the conclusion. In either case, the conclusion can be said to follow from the premises. The problem is that we cannot consistently assert both premises: it is not possible for both sentences to be true at the same time.
|
||||
This argument is valid because we cannot consistently assert the premises and deny the conclusion. In either case, the conclusion can be said to follow from the premises. The problem is that we cannot consistently assert both premises: it is not possible for both propositions to be true at the same time.
|
||||
|
|
|
|||
|
|
@ -1,12 +1,14 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
In order to make assertions about the relative [consistency](Consistency.md) or inconsistency of a set of propositions we advance arguments. Consider everyday life: if we are having an argument with someone, we believe that they are wrong. A more logical way to say this is that we believe that their beliefs are inconsistent. In order to change their viewpoint or point out why they are wrong we advance an argument intended to show that belief A conflicts with belief B. Or if C is true, then you cannot believe that D.
|
||||
# Syllogism
|
||||
|
||||
In formal terms **an argument is a set of sentences comprising one or more premises and a conclusion. The conclusion is taken to be supported by the premises.**
|
||||
In order to make assertions about the relative [consistency](/Logic/General_concepts/Logical_consistency.md) or inconsistency of a set of propositions we advance arguments. Consider everyday life: if we are having an argument with someone, we believe that they are wrong. A more logical way to say this is that we believe that their beliefs are inconsistent. In order to change their viewpoint or point out why they are wrong we advance an argument intended to show that belief A conflicts with belief B. Or if C is true, then you cannot believe that D.
|
||||
|
||||
In formal terms **an argument is a set of propositions comprising one or more premises and a conclusion. The conclusion is taken to be supported by the premises.**
|
||||
|
||||
> The terms **argument** and **syllogism** are used interchangeably in logic to describe the above feature of a set of propositions.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
## Validity
|
||||
|
|
@ -39,23 +39,21 @@ The test for a strong inductive argument is not whether the conclusion is true,
|
|||
|
||||
> An argument is truth-functionally valid if and only if there is no truth-assignment on which all the premises are true and the conclusion is false.
|
||||
|
||||
Linking this to [derivation](Formal%20proofs%20in%20propositional%20logic.md), we say:
|
||||
Linking this to derivation, we say:
|
||||
|
||||
> In a system of derivation in propositional logic, an argument is valid if the conclusion of the argument is derivable within the system of derivation from the set consisting of the premises, and invalid otherwise.
|
||||
|
||||
### Demonstration
|
||||
|
||||
The inference from the set ${P, P \supset Q}$ to $Q$ is valid
|
||||
The inference from the set ${P, P \rightarrow Q}$ to $Q$ is valid
|
||||
|
||||
### Truth-table
|
||||
|
||||
```
|
||||
P Q P ⊃ Q P Q
|
||||
T T T T T *
|
||||
T F F T F
|
||||
F T T F T
|
||||
F F T F F
|
||||
```
|
||||
| $P$ | $Q$ | $P \rightarrow Q$ | $P$ | $Q$ | Assessment |
|
||||
| --- | --- | ----------------- | --- | --- | ---------- |
|
||||
| T | T | T | T | T | Valid |
|
||||
| T | F | F | T | F | |
|
||||
| F | T | T | F | T | |
|
||||
|
||||
## Entailment
|
||||
|
||||
|
|
@ -79,16 +77,14 @@ The pavement is wet.
|
|||
|
||||
#### Formal demonstration
|
||||
|
||||
```
|
||||
{P, P ⊃ Q} ⊨ Q
|
||||
```
|
||||
$$
|
||||
\{ P, P\rightarrow Q \} \vdash Q
|
||||
$$
|
||||
|
||||
#### Truth-table
|
||||
|
||||
```
|
||||
P Q P ⊃ Q P Q
|
||||
T T T T T *
|
||||
T F F T F
|
||||
F T T F T
|
||||
F F T F F
|
||||
```
|
||||
| $P$ | $Q$ | $P \rightarrow Q$ | $P$ | $Q$ | Assessment |
|
||||
| --- | --- | ----------------- | --- | --- | ---------- |
|
||||
| T | T | T | T | T | Valid |
|
||||
| T | F | F | T | F | |
|
||||
| F | T | T | F | T | |
|
||||
|
|
|
|||
|
|
@ -1,41 +1,39 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
## Corresponding material conditional to show validity
|
||||
# Corresponding material conditional to show validity
|
||||
|
||||
To demonstrate _truth-functional validity_ we have to construct a truth-table which contains each of the premises and the conclusion and then review each row to see if there is an assignment where both the premises and the conclusion are true.
|
||||
|
||||
A simpler way to get the same result is to invoke the corresponding material conditional. Here we concatenate the premises using conjunction and then join them to the conclusion using the material conditional, which then becomes the main connective. We then populate the truth table for this compound sentence. If it is logically true, the argument is valid.
|
||||
A simpler way to get the same result is to invoke the corresponding material conditional. Here we concatenate the premises using conjunction and then join them to the conclusion using the material conditional, which then becomes the main connective. We then populate the truth table for this compound proposition. If it is logically true, the argument is valid.
|
||||
|
||||
### Demonstration
|
||||
|
||||
We will demonstrate with the following set:
|
||||
|
||||
$$ {P \equiv Q, P \lor Q, P &Q } $$
|
||||
$$ \{ P \leftrightarrow Q, P \lor Q, P \land Q \} $$
|
||||
|
||||
```
|
||||
P Q P ≡ Q P ∨ Q P & Q
|
||||
T T T T T *
|
||||
T F F T F
|
||||
F T F T F
|
||||
F F T F F
|
||||
```
|
||||
| $P$ | $Q$ | $P \leftrightarrow Q$ | $P \lor Q$ |
|
||||
| --- | --- | --------------------- | ---------- |
|
||||
| T | T | T | T |
|
||||
| T | F | F | T |
|
||||
| F | T | F | T |
|
||||
| F | F | T | F |
|
||||
|
||||
```
|
||||
P Q ( ( P ≡ Q ) & ( P ∨ Q ) ) ≡ ( P & Q )
|
||||
T T T
|
||||
T F T
|
||||
F T T
|
||||
F F T
|
||||
```
|
||||
| $P$ | $Q$ | $(P \leftrightarrow Q) \land (P \lor Q)) \leftrightarrow (P \land Q)$ |
|
||||
| --- | --- | --------------------------------------------------------------------- |
|
||||
| T | T | T |
|
||||
| T | F | T |
|
||||
| F | T | T |
|
||||
| F | F | T |
|
||||
|
||||
We see above that the main connective, the material conditional returns true for every truth-functional assignment. In other words it is logically true. Consequently the argument is valid
|
||||
|
||||
## Corresponding material biconditional
|
||||
|
||||
We can use the corresponding material biconditional as a shorthand for demonstrating logical equivalence between two sentences.
|
||||
We can use the corresponding material biconditional as a shorthand for demonstrating logical equivalence between two propositions.
|
||||
|
||||
For two putatively equivalent sentences $P$ and $Q$, $P$ and $Q$ are logically equivalent if the compound sentence $P \equiv Q$ is logically true.
|
||||
For two putatively equivalent propositions $P$ and $Q$, $P$ and $Q$ are logically equivalent if the compound proposition $P \leftrightarrow Q$ is logically true.
|
||||
|
|
|
|||
|
|
@ -6,26 +6,36 @@ tags: [logic, laws]
|
|||
|
||||
# DeMorgan's Laws
|
||||
|
||||
DeMorgan's laws express some fundamental equivalences that obtain between the Boolean [connectives](Truth-functional%20connectives.md):
|
||||
DeMorgan's laws express some fundamental equivalences that obtain between the Boolean [connectives](/Logic/Propositional_logic/Truth-functional_connectives.md).
|
||||
|
||||
## First Law
|
||||
|
||||
> The negation of a conjunction is logically equivalent to the disjunction of the negations of the original conjuncts.
|
||||
|
||||
$$
|
||||
\sim (P \& Q) \equiv \sim P \lor \sim Q
|
||||
\lnot (P \land Q) \leftrightarrow \lnot P \lor \lnot Q
|
||||
$$
|
||||
|
||||
The equivalence is demonstrated with the following truth-table
|
||||
|
||||

|
||||
| $P$ | $Q$ | $ \lnot (P \land Q)$ | $ \lnot P \lor \lnot Q$ |
|
||||
| --- | --- | -------------------- | ----------------------- |
|
||||
| T | T | F | F |
|
||||
| T | F | T | T |
|
||||
| F | T | T | T |
|
||||
| F | F | T | T |
|
||||
|
||||
## Second Law
|
||||
|
||||
> The negation of a disjunction is equivalent to the conjunction of the negation of the original disjuncts.
|
||||
|
||||
$$
|
||||
\sim (P \lor Q) \equiv \sim P \& \sim Q
|
||||
\lnot (P \lor Q) \leftrightarrow \lnot P \land \lnot Q
|
||||
$$
|
||||
|
||||

|
||||
| $P$ | $Q$ | $ \lnot (P \lor Q)$ | $ \lnot P \land \lnot Q$ |
|
||||
| --- | --- | ------------------- | ------------------------ |
|
||||
| T | T | F | F |
|
||||
| T | F | F | F |
|
||||
| F | T | F | F |
|
||||
| F | F | T | T |
|
||||
|
|
|
|||
|
|
@ -1,11 +1,13 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic, theorems]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Law of Non-Contradiction
|
||||
|
||||
> A proposition cannot be true and false at the same time.
|
||||
>
|
||||
> $$
|
||||
> \\sim (P & \sim P)
|
||||
> $$
|
||||
|
||||
$$
|
||||
\lnot (P \land \lnot P)
|
||||
$$
|
||||
|
|
|
|||
|
|
@ -1,11 +1,13 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [theorems, logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Law of the Excluded Middle
|
||||
|
||||
> Every proposition has to be either true or false. There can be no middle ground.
|
||||
>
|
||||
> $$
|
||||
> P \lor \sim P
|
||||
> $$
|
||||
|
||||
$$
|
||||
P \lor \sim P
|
||||
$$
|
||||
|
|
|
|||
|
|
@ -1,13 +1,14 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
We know that when we construct a [derivation](Formal%20proofs%20in%20propositional%20logic.md#constructing-proofs) we start from a set of assumptions and then attempt to reach a proposition that is a consequence of the starting assumptions. However it does not always have to be the case that the starting set contains members. The set can in fact be empty.
|
||||
We know that when we construct a [derivation](/Logic/Proofs/Formal_proofs_in_propositional_logic.md#derivation-rules) we start from a set of assumptions and then attempt to reach a proposition that is a consequence of the starting assumptions. However it does not always have to be the case that the starting set contains members. The set can in fact be empty.
|
||||
|
||||
_Demonstration_
|
||||

|
||||
|
||||

|
||||
|
||||
We see in this example that there is no starting set and thus no primary assumptions. Instead we start with nothing other than the proposition we wish to derive. The proposition is effectively derived from itself. In these scenarios we say that we are constructing a derivation from an **empty set**.
|
||||
|
||||
|
|
@ -18,7 +19,7 @@ Propositions which possess this property are called theorems:
|
|||
We represent a theorem as:
|
||||
|
||||
$$
|
||||
\\vdash P
|
||||
\vdash P
|
||||
$$
|
||||
|
||||
(There is no preceding $\Gamma$ as the set is empty. )
|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
Give that the biconditional means that if $P$ is the case, $Q$ is the case and if $Q$ is the case, $P$ must be the case, if we have $P \equiv Q$ and $P$, we can derive $Q$ and vice versa.
|
||||
# Biconditional Elimination
|
||||
|
||||

|
||||
Give that the biconditional means that if $P$ is the case, $Q$ must be the case and if $Q$ is the case, $P$ must be the case, if we have $P \leftrightarrow Q$ and $P$, we can derive $Q$ and vice versa.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: []
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
The biconditional means if $P$ is the case, $Q$ is the case and if $Q$ is the case, $P$ must be the case. Thus to introduce this operator we must demonstrate both that $Q$ follows from $P$ and that $P$ follows from $Q$. We do this via two sub-proofs.
|
||||
# Biconditional introduction
|
||||
|
||||

|
||||
The biconditional means if $P$ is the case, $Q$ must be the case and if $Q$ is the case, $P$ must be the case. Thus to introduce this operator we must demonstrate both that $Q$ follows from $P$ and that $P$ follows from $Q$. We do this via two sub-proofs.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
# Conditional elimination
|
||||
|
||||
If we have a conditional and we have independently derived its antecedent, we may invoke its consequent. This is often referred to as _Modus ponens_ (affirming the antecedent).
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
If we can show that $Q$ follows from $P$ (typically via a subproof) than we can assert that P implies Q. This is also sometimes known as _Conditional Proof_
|
||||
# Conditional Introduction
|
||||
|
||||

|
||||
If we can show that $Q$ follows from $P$ (typically via a sub-proof) than we can assert that P implies Q. This is also sometimes known as _Conditional Proof_
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
# Conditional Elimination
|
||||
|
||||
If a conjunction exists, it means that both conjuncts are the case; therefore we can legitimately extract either one of them. Also known as _Simplification_.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
If two conjuncts have each been independently derived then they can be conjoined. Also known more simply as _Conjunction_
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -1,18 +1,20 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
# Disjunction Elimination
|
||||
|
||||
This rule is sometimes also referred to as _Constructive Dilemma_. This can be a bit tricky to understand because the goal is to derive or _introduce_ a new proposition separate from the disjunction you start out with. This may be disjunction, a single proposition or a proposition containing any other logical connective. You do this by constructing two sub-proofs, one for each of the disjuncts comprising the disjunction you start out with. If you can derive your target proposition as the conclusion of each subproof then you may invoke the conclusion in the main proof and take it to be derived.
|
||||
|
||||

|
||||

|
||||
|
||||
_Here is an example where Disjunction Elimination is used to derive a new disjunction._
|
||||
|
||||

|
||||

|
||||
|
||||
_Here are two further examples that use Disjunction Elimination to derive singular propositions_
|
||||
|
||||

|
||||

|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -1,10 +1,12 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
# Disjunction Introduction
|
||||
|
||||
This rule can seem a little odd: like we are randomly introducing an additional proposition without giving any justification. However this is just a consequence of the fact if $P$ is true, so is $P \lor Q$ since disjunction is not the same as conjunction: only one disjunct needs to be true for the compound disjunction to be true. This is represented in the context of [truth-trees](Truth-trees.md#disjunction-decomposition) by the fact that truth can pass up via either branch of a disjunction pattern.
|
||||
This rule is sometimes also referred to (confusingly) as _Addition_.
|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Formal proofs in propositional logic
|
||||
|
||||
When we construct a formal proof in logic we are seeking to show that a certain proposition is **derivable** from other propositions. We use the words _derivation_ and _proof_ interchangeably.
|
||||
|
||||
> A sentence $P$ is derivable in a system of propositional logic from a finite set of sentences if and only if there is a derivation in this system in which all and only the members of the set are **primary assumptions** and $P$ is the sentence on the last line.
|
||||
|
|
@ -15,11 +17,12 @@ Derivability is therefore a property that a proposition can possess relative to
|
|||
For instance to demonstrate derivability for:
|
||||
|
||||
$$
|
||||
{\sim F \lor D, F, D \supset (G & H)} \vdash G &H
|
||||
\{ \lnot F \lor D, F, D \rightarrow (G \land H) \} \vdash G \land H
|
||||
$$
|
||||
|
||||
We would establish $\sim F \lor D, F, D \supset (G & H)$ as primary assumptions and then, using the derivation rules of the system conclude with $G&H$. Every sentence in the derivation is either a **primary assumption** or an **auxiliary** assumption or justified by the rules of the derivation. An auxiliary assumption is one belonging to a sub-derivation. The primary assumptions belong to the main derivation.
|
||||
For any given derivation of the form $\Gamma \vdash P$ there may be a number of ways of demonstrating the derivation (more than one application of the rules governing the system) but only one is sufficient to establish derivability.
|
||||
We would establish $\lnot F \lor D, F, D \rightarrow (G \land H)$ as primary assumptions and then, using the derivation rules of the system conclude with $G\land H$. Every sentence in the derivation is either a **primary assumption** or an **auxiliary** assumption or justified by the rules of the derivation.
|
||||
|
||||
An auxiliary assumption is an assumption belonging to a sub-derivation. Primary assumptions belong to the main derivation. For any given derivation of the form $\Gamma \vdash P$ there may be a number of ways of demonstrating the derivation (more than one application of the rules governing the system) but one alone is sufficient to establish derivability.
|
||||
|
||||
> We will tend to use the terms _derivation_ and _proof_ interchangeably but we should note that there is a technical distinction in that a **proof is a derivation in which all of the assumptions have been discharged**
|
||||
|
||||
|
|
@ -29,13 +32,14 @@ We place assumptions above derivations and mark them _A_ in the right-hand margi
|
|||
|
||||
We divide assumptions from derivations with a horizontal line. We number each line and use this to refer to the line we are applying the derivation to. Sub-proofs follow this structure recursively.
|
||||
This is known as _Fitch notation_
|
||||
_Schematically_
|
||||
|
||||

|
||||
_Schematically_:
|
||||
|
||||
_Applied example_
|
||||

|
||||
|
||||

|
||||
_Applied example_:
|
||||
|
||||

|
||||
|
||||
## Sub-proofs
|
||||
|
||||
|
|
@ -43,7 +47,7 @@ When a sub-proof is terminated, the assumption with which it starts is said to b
|
|||
|
||||
## Derivation rules
|
||||
|
||||
Derivation rules are [syntactic](Syntax%20of%20sentential%20logic.md) rather than semantic. They are applied on the basis of their form rather than on the basis of the truth conditions of the sentences they are applied to.
|
||||
Derivation rules are [syntactic](/Logic/Propositional_logic/Syntax_of_sentential_logic.md) rather than semantic. They are applied on the basis of their form rather than on the basis of the truth conditions of the sentences they are applied to.
|
||||
|
||||
> Derivation rules can be applied without having an interpretation of the symbols in mind. A derivation rule tells us that: given a group of symbols with a certain structure, we can write down another group of symbols with a certain structure.
|
||||
|
||||
|
|
@ -51,13 +55,13 @@ Each of the main logical connectives has an associated derivation rule. The bina
|
|||
|
||||
The main derivation rules:
|
||||
|
||||
- [Negation Introduction](Negation%20Introduction.md)
|
||||
- [Negation Elimination](Negation%20Elimination.md)
|
||||
- [Conjunction Introduction](Conjunction%20Introduction.md)
|
||||
- [Conjunction Elimination](Conjunction%20Elimination.md)
|
||||
- [Disjunction Introduction](Disjunction%20Introduction.md)
|
||||
- [Disjunction Elimination](Disjunction%20Elimination.md)
|
||||
- [Conditional Introduction](Conditional%20Introduction.md)
|
||||
- [Disjunction Elimination](Disjunction%20Elimination.md)
|
||||
- [Biconditional Introduction](Biconditional%20Introduction.md)
|
||||
- [Biconditional Elimination](Biconditional%20Elimination.md)
|
||||
- [Negation Introduction](/Logic/Proofs/Negation_Introduction.md)
|
||||
- [Negation Elimination](/Logic/Proofs/Negation_Elimination.md)
|
||||
- [Conjunction Introduction](/Logic/Proofs/Conjunction_Introduction.md)
|
||||
- [Conjunction Elimination](/Logic/Proofs/Conditional_Elimination.md)
|
||||
- [Disjunction Introduction](/Logic/Proofs/Disjunction_Introduction.md)
|
||||
- [Disjunction Elimination](/Logic/Proofs/Disjunction_Elimination.md)
|
||||
- [Conditional Introduction](/Logic/Proofs/Conditional_Introduction.md)
|
||||
- [Disjunction Elimination](/Logic/Proofs/Disjunction_Elimination.md)
|
||||
- [Biconditional Introduction](/Logic/Proofs/Biconditional_Introduction.md)
|
||||
- [Biconditional Elimination](/Logic/Proofs/Biconditional_Elimination.md)
|
||||
|
|
|
|||
|
|
@ -1,8 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||

|
||||
Like the [introduction](Negation%20Elimination.md) rule for negation, the elimination rule also works by deriving a contradiction. It is basically _Negation Introduction_ in reverse. Instead of starting the subproof with a true proposition from which you derive a contradiction, you start with the negation of a proposition, derive a contradiction and then assert the positive of the negated proposition you started out with.
|
||||
# Negation Elimination
|
||||
|
||||
Like the [introduction](/Logic/Proofs/Negation_Introduction.md) rule for negation, the elimination rule also works by deriving a contradiction. It is basically _Negation Introduction_ in reverse. Instead of starting the sub-proof with a true proposition from which you derive a contradiction, you start with the negation of a proposition, derive a contradiction and then assert the positive of the negated proposition you started out with.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
This is also known as _proof by contradiction_. You start with an assumption declared in a subproof. If you can derive a contradiction from this assumption (typically from the introduction of another proposition and its negation), then you are permitted to derive the negation of the auxiliary assumption in the main proof.
|
||||
# Negation Introduction
|
||||
|
||||
[]()
|
||||
This is also known as _proof by contradiction_. You start with an assumption declared in a sub-proof. If you can derive a contradiction from this assumption (typically from the introduction of another proposition and its negation), then you are permitted to derive the negation of the auxiliary assumption in the main proof.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [derivation-rules]
|
||||
---
|
||||
|
||||
**Reiteration (R)** allows us to restate any proposition already in the proof within the main proof or a more deeply nested subproof. Reiteration allows us to reuse any assumptions, or propositions derived from assumptions, without having to introduce a new dependency with another assumption.
|
||||
# Reiteration
|
||||
|
||||

|
||||
**Reiteration (R)** allows us to restate any proposition already in the proof within the main proof or a more deeply nested sub-proof. Reiteration allows us to reuse any assumptions, or propositions derived from assumptions, without having to introduce a new dependency with another assumption.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic, proofs]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Strategies for constructing proofs in propositional logic
|
||||
|
||||
## General strategy
|
||||
|
||||
- Break complex propositions into simpler sentences by using the elimination rules
|
||||
|
|
@ -13,80 +15,83 @@ tags: [logic, proofs]
|
|||
|
||||
The approach above describes the general form of a proof but of course it will not always work and there will be cases where the route to the desired derivation is more circuitous. In these instances it is to best to combine this general top level strategy with goal analysis.
|
||||
|
||||
Goal analysis is a [recursive](../Algorithms%20&%20Data%20Structures/Recursion.md) strategy which proceeds by using a 'goal' proposition to guide the construction of intermediary derivations.
|
||||
Goal analysis is a [recursive](/Data_Structures/Recursion.md) strategy which proceeds by using a 'goal' proposition to guide the construction of intermediary derivations.
|
||||
|
||||
Assume that we want to show that an argument is [valid](Validity%20and%20entailment.md#validity). Then our ultimate goal is to derive the conclusion from the premises we are given. We first ask ourselves: _which propositions if we could derive them, would allow us to easily derive the conclusion_? (For example, these propositions might be two simple propositions that when combined with [Conjunction Introduction](Conjunction%20Introduction.md) give us the conclusion.) Deriving these propositions then becomes the new intermediate goal.
|
||||
Assume that we want to show that an argument is [valid](/Logic/General_concepts/Validity_and_entailment.md#validity). Then our ultimate goal is to derive the conclusion from the premises we are given. We first ask ourselves: _which propositions if we could derive them, would allow us to easily derive the conclusion_? (For example, these propositions might be two simple propositions that when combined with [Conjunction Introduction](/Logic/Proofs/Conjunction_Introduction.md) give us the conclusion.) Deriving these propositions then becomes the new intermediate goal.
|
||||
|
||||
If arriving at these propositions is not trivial, we then ask ourselves the question again: _which propositions would permit us to derive the intermediary propositions we need_? You keep working back in this manner until you reach a base level. Then it is just a matter or working upwards from each set of derived intermediary propositions until you reach the ultimate goal.
|
||||
|
||||
### Demonstration
|
||||
|
||||
Let's say we want to prove $(L \lor A) & D$ from the propositions $\sim N$ and $(\sim N \supset L) & (D \equiv \sim N)$.
|
||||
Let's say we want to prove $(L \lor A) \land D$ from the propositions $\lnot N$ and $((\lnot N \rightarrow L) \land (D \leftrightarrow \lnot N))$.
|
||||
|
||||
First, we consider what is the easiest possible way of achieving the proposition $(L \lor A) & D$. Clearly it is to separately derive each disjunct ($L \lor A$ and $D$) and then combine them with [Conjunction Introduction](Conjunction%20Introduction.md). This provides us with our first goal: to derive each of the separate conjuncts.
|
||||
First, we consider what is the easiest possible way of achieving the proposition $(L \lor A) \land D$. Clearly it is to separately derive each disjunct ($L \lor A$ and $D$) and then combine them with [Conjunction Introduction](/Logic/Proofs/Conditional_Introduction.md). This provides us with our first goal: to derive each of the separate conjuncts.
|
||||
|
||||
Let's start with $D$: where does it occur in the assumptions? It occurs in the compound $(\sim N \supset L) & (D \equiv \sim N)$, but only in the first conjunct. We can get this simply bu applying [Conjunction Elimination](Conjunction%20Elimination.md).
|
||||
Let's start with $D$: where does it occur in the assumptions? It occurs in the compound $(\lnot N \rightarrow L) \land (D \leftrightarrow \lnot N)$, but only in the first conjunct. We can get this simply but applying [Conjunction Elimination](Conjunction%20Elimination.md).
|
||||
|
||||
So far we have:
|
||||
|
||||

|
||||

|
||||
|
||||
Now we just need to get $D$ from the proposition at line 3. This is easy since we already have access to the consequent of the biconditional at line 1. Therefore we can apply [Biconditional Elimination](Biconditional%20Elimination.md) at line 3 to get $D$. We are now halfway there:
|
||||
Now we just need to get $D$ from the proposition at line 3. This is easy since we already have access to the consequent of the biconditional at line 1. Therefore we can apply [Biconditional Elimination](/Logic/Proofs/Biconditional_Elimination.md)) at line 3 to get $D$. We are now halfway there:
|
||||
|
||||

|
||||

|
||||
|
||||
Next we need to turn our attention to deriving $L \lor A$. How can we obtain $L$ ? Well it is contained within the first conjunct of the assumption on line 2. Again, we can get this through the application of [Conjunction Elimination](Conjunction%20Elimination.md).
|
||||
Now, how do we get $L$ from $(\sim N \supset L)$? Well, we already have the antecedent $\sim N$ as an assumption on the first line, so we can use [Conditional Elimination](Conditional%20Elimination.md) to derive $L$. These two steps give us:
|
||||
Next we need to turn our attention to deriving $L \lor A$. How can we obtain $L$ ? Well it is contained within the first conjunct of the assumption on line 2. Again, we can get this through the application of [Conjunction Elimination](/Logic/Proofs/Conjunction_Elimination.md).
|
||||
Now, how do we get $L$ from $(\lnot N \rightarrow L)$? Well, we already have the antecedent $\lnot N$ as an assumption on the first line, so we can use [Conditional Elimination](/Logic/Proofs/Conditional_Elimination.md) to derive $L$. These two steps give us:
|
||||
|
||||

|
||||

|
||||
|
||||
Now we need to get from $L$ to $L \lor A$. This is really straightforward because by using [Disjunction Introduction](Disjunction%20Introduction.md) we can get from any sentence to a disjunction. Finally, having assembled all the constituent parts of the conjunction that is the conclusion, we can combine them with [Conjunction Introduction](Conjunction%20Introduction.md) as we had planned at the outset.
|
||||
Now we need to get from $L$ to $L \lor A$. This is really straightforward because by using [Disjunction Introduction](/Logic/Proofs/Disjunction_Introduction.md)) we can get from any sentence to a disjunction. Finally, having assembled all the constituent parts of the conjunction that is the conclusion, we can combine them with [Conjunction Introduction](/Logic/Proofs/Conjunction_Introduction.md) as we had planned at the outset.
|
||||
|
||||

|
||||

|
||||
|
||||
### A further example
|
||||
|
||||
We will seek to prove the following:
|
||||
|
||||
$$
|
||||
{ \sim L \equiv \[X & (\sim S \lor B)\], (E & C) \supset \sim L, (E & R) & C} \vdash X & (\sim S \lor B)
|
||||
\{ \lnot L \leftrightarrow [X \land (\lnot S \lor B) ], (E \land C) \rightarrow \lnot L, (E \land R) \land C \} \vdash X \land (\lnot S \lor B)
|
||||
$$
|
||||
|
||||
The requirements here could easily mislead us. We see that the target proposition is a conjunction so we might think that the best strategy is to seek to derive each conjunct and then combine them via [Conjunction Introduction](Conjunction%20Introduction.md).
|
||||
The requirements here could easily mislead us. We see that the target proposition is a conjunction so we might think that the best strategy is to seek to derive each conjunct and then combine them via [Conjunction Introduction](/Logic/Proofs/Conjunction_Introduction.md)).
|
||||
|
||||
Actually, if we look more closely, there is a better approach. The target proposition is contained in the first premise as the consequent to the biconditional ($\sim L \equiv \[X & (\sim S \lor B)\]$). A better approach is therefore to seek to derive the antecedent ($\sim L$) and then use [Biconditional Elimination](Biconditional%20Elimination.md) to extract the target sentence which is the consequent.
|
||||
Actually, if we look more closely, there is a better approach. The target proposition is contained in the first premise as the consequent to the biconditional ($\lnot L \leftrightarrow [X \land (\lnot S \lor B)]$). A better approach is therefore to seek to derive the antecedent ($\lnot L$) and then use [Biconditional Elimination](/Logic/Proofs/Biconditional_Elimination.md) to extract the target sentence which is the consequent.
|
||||
|
||||

|
||||

|
||||
|
||||
## Proving theorems
|
||||
|
||||
When we are proving [theorems](Theorems%20and%20empty%20sets.md) we do not have a set of assumptions to work from when constructing the proof. We must derive the target sentence from the 'empty set' which is the target sentence itself. It is therefore like a process of reverse engineering.
|
||||
When we are proving [theorems](/Logic/Laws_and_theorems.md/Theorems_and_empty_sets.md#theorems-and-empty-sets) we do not have a set of assumptions to work from when constructing the proof. We must derive the target sentence from the 'empty set' which is the target sentence itself. It is therefore like a process of reverse engineering.
|
||||
|
||||
### Demonstration
|
||||
|
||||
\_Prove \_ $\vdash (U & Y) \supset \[L \supset (U & L)\]$
|
||||
_Prove:_ $\vdash (U \land Y) \rightarrow [L \rightarrow (U \land L)]$
|
||||
|
||||
Our strategy here is to identify the main connective in the proposition we want to derive (the [material conditional](Truth-functional%20connectives.md#material-conditional-a-k-a-implication)). We then assume the antecedent and attempt to derive the consequent from it.
|
||||
Our strategy here is to identify the main connective in the proposition we want to derive (the material conditional). We then assume the antecedent and attempt to derive the consequent from it.
|
||||
|
||||

|
||||

|
||||
|
||||
## A complex theorem proof
|
||||
|
||||
_Prove_ $\vdash (\sim A \lor \sim B) \equiv \sim(A & B)$
|
||||
_Prove_ $\vdash (\lnot A \lor \lnot B) \leftrightarrow \lnot(A \land B)$
|
||||
|
||||

|
||||

|
||||
|
||||
### Walkthrough
|
||||
|
||||
**Lines 1-12**
|
||||
|
||||
- Our auxiliary goal is to prove $\sim (A \lor B) \supset \sim (A & B)$.
|
||||
- Our starting assumption is to a disjunction. Thus we can apply [Disjunction Elimination](Disjunction%20Elimination.md) to show that our goal sentence $\sim(A & B)$ follows from each of the disjuncts ($\sim A$ and $\sim B$) in dedicated subproofs. If we can do this, we have the right to derive $\sim (A & B$).
|
||||
- In both cases($\sim A \vdash \sim (A & B$) and ($\sim B \vdash \sim (A & B$) we require another subproof to reach the target as there is no easy path available. So we derive a negation from $A & B$ so that we can negate it as $\sim (A & B$).
|
||||
- Having done this, we can discharge the [Disjunction Elimination](Disjunction%20Elimination.md) subproofs and derive $\sim (A & B$) from $\sim A \lor \sim B$
|
||||
- Our auxiliary goal is to prove $\lnot (A \lor B) \rightarrow \lnot (A \land B)$.
|
||||
|
||||
- Our starting assumption is to a disjunction. Thus we can apply [Disjunction Elimination](/Logic/Proofs/Disjunction_Elimination.md) to show that our goal sentence $\lnot(A \land B)$ follows from each of the disjuncts ($\lnot A$ and $\lnot B$) in dedicated sub-proofs. If we can do this, we have the right to derive $\lnot (A \land B)$.
|
||||
|
||||
- In both cases($\lnot A \vdash \lnot (A \land B)$) and ($\lnot B \vdash \lnot (A \land B)$ we require another sub-proof to reach the target as there is no easy path available. So we derive a negation from $A \land B$ so that we can negate it as $\lnot (A \land B)$.
|
||||
|
||||
- Having done this, we can discharge the [Disjunction Elimination](/Logic/Proofs/Disjunction_Elimination.md) sub-proofs and derive $\lnot (A \land B)$ from $\lnot A \lor \lnot B$
|
||||
|
||||
**Lines 13-26**
|
||||
|
||||
- Our auxiliary goal is to prove $\sim (A & B) \supset \sim A \lor \sim B$. This will require a different approach to the above because we are not working from a disjunction anymore, we have a negated conjunction.
|
||||
- We will do this by assuming the negation of what we want to prove ($\sim (\sim A \lor \sim B)$) and then apply [Negation Elimination](Negation%20Elimination.md) to get $\sim A \lor \sim B$.
|
||||
- This requires us to derive a contradiction. We get this on lines 23 and 24. This requires as previous steps that we have two subproofs that use [Negation Elimination](Negation%20Elimination.md) to release $A$ and $B$
|
||||
- Our auxiliary goal is to prove $\lnot (A \land B) \rightarrow \lnot A \lor \lnot B$. This will require a different approach to the above because we are not working from a disjunction anymore, we have a negated conjunction.
|
||||
- We will do this by assuming the negation of what we want to prove ($\lnot (\lnot A \lor \lnot B)$) and then apply [Negation Elimination](/Logic/Proofs/Negation_Elimination.md) to get $\lnot A \lor \lnot B$.
|
||||
- This requires us to derive a contradiction. We get this on lines 23 and 24. This requires as previous steps that we have two sub-proofs that use [Negation Elimination](/Logic/Proofs/Negation_Elimination.md) to release $A$ and $B$
|
||||
|
|
|
|||
|
|
@ -0,0 +1,53 @@
|
|||
---
|
||||
categories:
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Atomic and molecular propositions
|
||||
|
||||
Propositions are expressions **that have truth values**, either true or false.
|
||||
|
||||
We call a proposition which does not contain a logical connective (or 'sentential connective') a **simple proposition**.
|
||||
|
||||
We call a proposition that does contain a logical connective, a **compound proposition**.
|
||||
|
||||
Simple propositions are represented within a formal language of sentential logic with a single character, customarily _P_ or _Q_. When we refer to the formal representation of such propositions in our system of sentential logic (SL) we call them **atomic propositions**.
|
||||
|
||||
Compound propositions consist in single characters for each atomic proposition that they comprise, combined with a symbol for the logical connective. When we refer to the formal representation of such propositions in SL we call them **molecular propositions**.
|
||||
|
||||
### Demonstration
|
||||
|
||||
Atomic proposition:
|
||||
|
||||
```
|
||||
Socrates was a philosopher.
|
||||
(P)
|
||||
```
|
||||
|
||||
Molecular proposition:
|
||||
|
||||
```
|
||||
Socrates was a philosopher and a drinker.
|
||||
(P & Q)
|
||||
```
|
||||
|
||||
Connectives in natural language often obscure the logical basis of the proposition being expressed (where such a proposition contains a proposition, i.e. excluding propositions that are _logically indeterminate_. The molecular proposition is above is such an example. In this instance the proposition can be expressed more precisely as:
|
||||
|
||||
```
|
||||
Socrates was a philosopher and Socrates was a drinker.
|
||||
```
|
||||
|
||||
Where propositions in natural language cannot be elucidated by the addition of implied logical connectives in the manner above, they must be treated not as molecular propositions but as atomic proposition. Example:
|
||||
|
||||
```
|
||||
Two splashes of gin and a few drops of vermouth make a great martini.
|
||||
```
|
||||
|
||||
If we were to formalise this as:
|
||||
|
||||
```
|
||||
Two splashes of gin make a great martini and a few drops of vermouth make a great martini.
|
||||
```
|
||||
|
||||
We would lose the sense of the original and we would not be uncovering any logic that is in the original.
|
||||
|
|
@ -1,51 +0,0 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
---
|
||||
|
||||
Sentences or propositions (we will use 'sentences' for consistency) are expressions **that have truth values**, either true or false.
|
||||
|
||||
We call a sentence which does not contain a logical connective (or 'sentential connective') a **simple sentence**.
|
||||
|
||||
We call a sentence that does contain a logical connective, a **compound sentence**.
|
||||
|
||||
Simple sentences are represented within a formal language of sentential logic with a single character, customarily _P_ or _Q_. When we refer to the formal representation of such sentences in our system of sentential logic (SL) we call them **atomic sentences**.
|
||||
|
||||
Compound sentences consist in single characters for each atomic sentence that they comprise, combined with a symbol for the logical connective. When we refer to the formal representation of such sentences in SL we call them **molecular sentences**.
|
||||
|
||||
### Demonstration
|
||||
|
||||
Atomic sentence:
|
||||
|
||||
```
|
||||
Socrates was a philosopher.
|
||||
(P)
|
||||
```
|
||||
|
||||
Molecular sentence:
|
||||
|
||||
```
|
||||
Socrates was a philosopher and a drinker.
|
||||
(P & Q)
|
||||
```
|
||||
|
||||
Connectives in natural language often obscure the logical basis of the proposition being expressed (where such a sentence contains a proposition, i.e. excluding sentences that are _logically indeterminate_. The molecular sentence is above is such an example. In this instance the sentence can be expressed more precisely as:
|
||||
|
||||
```
|
||||
Socrates was a philosopher and Socrates was a drinker.
|
||||
```
|
||||
|
||||
Where sentences in natural language cannot be elucidated by the addition of implied logical connectives in the manner above, they must be treated not as molecular sentences but as atomic sentence. Example:
|
||||
|
||||
```
|
||||
Two splashes of gin and a few drops of vermouth make a great martini.
|
||||
```
|
||||
|
||||
If we were to formalise this as:
|
||||
|
||||
```
|
||||
Two splashes of gin make a great martini and a few drops of vermouth make a great martini.
|
||||
```
|
||||
|
||||
We would lose the sense of the original and we would not be uncovering any logic that is in the original.
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
categories:
|
||||
- Logic
|
||||
- Computer Architecture
|
||||
tags: [propositional-logic, algebra]
|
||||
tags: [propositional-logic, algebra, nand-to-tetris]
|
||||
---
|
||||
|
||||
# Boolean algebra
|
||||
|
|
@ -89,7 +89,7 @@ $$
|
|||
We can employ DeMorgan's Laws to convert the second conjunct to a different form:
|
||||
|
||||
$$
|
||||
\lnot (x \lor x) = \lnot x \land \lnot y
|
||||
\lnot (x \lor y) = \lnot x \land \lnot y
|
||||
$$
|
||||
|
||||
So now we have:
|
||||
|
|
|
|||
|
|
@ -7,9 +7,11 @@ tags: [logic, propositional-logic, nand-to-tetris]
|
|||
|
||||
# Boolean function synthesis
|
||||
|
||||
When we looked at [boolean functions](/Logic/Propositional_logic/Boolean_functions.md) we were working in a particular direction: from a function to a truth table. When we do Boolean function synthesis we work in the opposite direction: from a function to a truth table.
|
||||
When we looked at [boolean functions](/Logic/Propositional_logic/Boolean_functions.md) we were working in a particular direction: from a function to a truth table. When we do Boolean function synthesis we work in the opposite direction: from a truth table to a function.
|
||||
|
||||
This is an important skill that we will use when constructing [logic circuits](/Electronics_and_Hardware/Digital_circuits/Digital_circuits.md). We will go from truth conditions (i.e. what we want the circuit to do and when we want it to do it) to a function expression which is then reduced and implemented with [logic gates](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md).
|
||||
This is an important skill that we will use when constructing [logic circuits](/Electronics_and_Hardware/Digital_circuits/Digital_circuits.md). We will go from truth conditions (i.e. what we want the circuit to do and when we want it to do it) to a function expression which is then reduced to its simplest form and implemented with [logic gates](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md). Specifically, NAND gates.
|
||||
|
||||
We will show here that a complex logical expression can be reduced to an equivalent expression that uses only the NAND operator.
|
||||
|
||||
## The process
|
||||
|
||||
|
|
@ -27,7 +29,7 @@ Let's say we have the following truth table:
|
|||
|
||||
| Line | $x$ | $y$ | $z$ | $f$ |
|
||||
| ---- | --- | --- | --- | --- |
|
||||
| 1 | 0 | 0 | 0 | 1 |
|
||||
| 1 | 0 | 0 | 0 | 0 |
|
||||
| 2 | 0 | 0 | 1 | 0 |
|
||||
| 3 | 0 | 1 | 0 | 1 |
|
||||
| 4 | 0 | 1 | 1 | 0 |
|
||||
|
|
@ -46,16 +48,16 @@ We only need to focus on lines 1, 3, and 5 since they have the output 1:
|
|||
|
||||
For each line we construct a Boolean expression that would result in the value in the $f$ column. In other words we construct the function:
|
||||
|
||||
| Line | $x$ | $y$ | $z$ | $f$ |
|
||||
| ---- | --- | --- | --- | ------------------------------------------- |
|
||||
| 1 | 0 | 0 | 0 | $ \lnot(x) \land \lnot (y) \land \lnot(z) $ |
|
||||
| 3 | 0 | 1 | 0 | $ \lnot(x) \land y \land \lnot(z) $ |
|
||||
| 5 | 1 | 0 | 0 | $ x \land \lnot(y) \land \lnot(z) $ |
|
||||
| Line | $x$ | $y$ | $z$ | $f$ |
|
||||
| ---- | --- | --- | --- | ----------------------------------------- |
|
||||
| 1 | 0 | 0 | 0 | $\lnot(x) \land \lnot (y) \land \lnot(z)$ |
|
||||
| 3 | 0 | 1 | 0 | $\lnot(x) \land y \land \lnot(z)$ |
|
||||
| 5 | 1 | 0 | 0 | $x \land \lnot(y) \land \lnot(z)$ |
|
||||
|
||||
We can now join each expression to create a complex expression that covers the entire truth table. Since 1 will be output for any one of these sub-expressions we can just join them up with OR:
|
||||
We can now join each expression to create a complex expression that covers the entire truth table using OR:
|
||||
|
||||
$$
|
||||
(\lnot(x) \land \lnot (y) \land \lnot(z)) \lor (\lnot(x) \land y \land \lnot(z)) \lor (x \land \lnot(y) \land \lnot(z))
|
||||
(\lnot(x) \land \lnot (y) \land \lnot(z)) \\ \lor \\ (\lnot(x) \land y \land \lnot(z)) \\ \lor \\ (x \land \lnot(y) \land \lnot(z))
|
||||
$$
|
||||
|
||||
It's clear that we have transcribed the truth conditions accurately but that we are doing so in a rather verbose way. We can simplify by just looking at the position of the 1s in the truth table. Notice:
|
||||
|
|
@ -69,16 +71,43 @@ $$
|
|||
(\lnot(x) \land \lnot(z)) \lor (\lnot(y) \land \lnot(z))
|
||||
$$
|
||||
|
||||
Notice that $\lnot(z)$ is repeated so we can remove the repetition:
|
||||
Notice that $\lnot(z)$ is repeated so we can remove the repetition through [idempotence](/Logic/Propositional_logic/Boolean_algebra.md#idempotent-law):
|
||||
|
||||
$$
|
||||
\lnot z \land (\lnot(x) \lor \lnot(y))
|
||||
$$
|
||||
|
||||
The upshot is that we now have a simpler expression that uses only NOT, OR and AND. We could therefore construct a circuit that just uses these gates to construct the conditions we specified in the first truth table.
|
||||
The upshot is that we now have a simpler expression that uses only NOT, OR and AND. These are the fundamental logic gates thus we are able to construct a circuit that embodies the logic of the expression.
|
||||
|
||||
> This is important and is an instance of the general theorem that _any Boolean function_ can be represented using an expression containing AND, OR and NOT operations
|
||||
|
||||
But even this is too complex. We could get rid of the OR and just use AND and NOT, in other words, NAND:
|
||||
But even this is too complex. We could get rid of the OR and just use AND and NOT:
|
||||
|
||||
stopped at 6:38
|
||||
We can prove this theorem by showing that an expression with AND, NOT, and OR can be formulated as an equivalent expression using just NOT and AND:
|
||||
|
||||
$$
|
||||
x \lor y = \lnot(\lnot(x) \land \lnot(y))
|
||||
$$
|
||||
|
||||
| $x$ | $y$ | $x \lor y$ | $\lnot(\lnot(x) \land \lnot(y)$ |
|
||||
| --- | --- | ---------- | ------------------------------- |
|
||||
| 0 | 0 | 0 | 0 |
|
||||
| 0 | 1 | 1 | 1 |
|
||||
| 1 | 0 | 1 | 1 |
|
||||
| 1 | 1 | 1 | 1 |
|
||||
|
||||
Finally, we can simplify even further by doing away with AND and NOT and using a single [NAND gate](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md#nand-gate) which embodies the logic of both, being true in all instances where AND would be false: $\lnot (x \land y)$.
|
||||
|
||||
Let's prove the theorem that every logical expression can be formulated as a NAND function. To do this we need to show that both NOT and AND can be converted to NAND.
|
||||
|
||||
NOT:
|
||||
|
||||
$$
|
||||
\lnot(x) = x \lnot\land x
|
||||
$$
|
||||
|
||||
AND:
|
||||
|
||||
$$
|
||||
x \land y = \lnot(x \lnot\land y)
|
||||
$$
|
||||
|
|
|
|||
|
|
@ -15,11 +15,11 @@ $$
|
|||
|
||||
Here is a work through where $f(1, 0, 1)$:
|
||||
|
||||
- The first disjunction : $ \lnot(x) \land z $ is false because $x$ is 1 and $z$ is 0
|
||||
- The first disjunction : $\lnot(x) \land z$ is false because $x$ is 1 and $z$ is 0
|
||||
- The second disjunction: $x \land y$ is false because $x$ is 1 and $y$ is 1
|
||||
- The overall function returns false because the main connective is disjunction and both of its disjuncts are false
|
||||
|
||||
We can compute all possible outputs of the function by constructing a [truth-table](/Logic/Propositional_logic/Truth-tables.md) with each possible variable as the truth conditions and the output of the function as the truth value:
|
||||
We can compute all possible outputs of the function by constructing a [truth table](/Logic/Propositional_logic/Truth-tables.md) with each possible variable as the truth conditions and the output of the function as the truth value:
|
||||
|
||||
| $x$ | $y$ | $z$ | $f(x,y,z) = (x \land y) \lor (\lnot(x) \land z )$ |
|
||||
| --- | --- | --- | ------------------------------------------------- |
|
||||
|
|
|
|||
66
Logic/Propositional_logic/Syntax_of_propositional_logic.md
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
---
|
||||
categories:
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
# Syntax of propositional logic
|
||||
|
||||
## Syntax of formal languages versus semantics
|
||||
|
||||
> The syntactical study of a language is the study of the expressions of the language and the relations among them _without regard_ to the possible interpretations or 'meaning' of these expressions.
|
||||
|
||||
Syntax is talking about the order and placement of propositions relative to connectives and what constitutes a well-formed expression in these terms. Semantics is about what the connectives mean, in other words: truth-functions and truth-values and not just placement and order.
|
||||
|
||||
## Formal specification of the syntax of the language of Sentential Logic
|
||||
|
||||
### Vocabulary
|
||||
|
||||
Propositions in SL are capitalised Roman letters (non-bold) with or without natural number subscripts. We may call these proposition letters. For example:
|
||||
|
||||
$$
|
||||
P, Q, R,... P_{1}, Q_{1}, R_{1}, ...
|
||||
$$
|
||||
|
||||
The connectives of SL are the five truth-functional connectives:
|
||||
|
||||
$$
|
||||
\lnot, \land, \lor, \rightarrow, \leftrightarrow
|
||||
$$
|
||||
|
||||
The punctuation marks of SL consist in the left and right parentheses:
|
||||
|
||||
$$
|
||||
( )
|
||||
$$
|
||||
|
||||
### Grammar
|
||||
|
||||
1. Every letter in a statement is a proposition.
|
||||
2. If $P$ is a proposition then $\lnot P$ is a proposition.
|
||||
3. If $P$ and $Q$ are propositions, then $P \land Q$ is a proposition
|
||||
4. If $P$ and $Q$ are propositions, then $P \lor Q$ is a proposition
|
||||
5. If $P$ and $Q$ are propositions, then $P \rightarrow Q$ is a proposition
|
||||
6. If $P$ and $Q$ are propositions, then $P \leftrightarrow Q$ is a proposition
|
||||
7. Nothing is a proposition unless it can be formed by repeated application of rules 1-6
|
||||
|
||||
### Additional syntactic concepts
|
||||
|
||||
We also distinguish:
|
||||
|
||||
- the **main connective**
|
||||
- **immediate sentential components**
|
||||
- **sentential components**
|
||||
- **atomic components**
|
||||
|
||||
These definitions provide a formal specification of the concepts of [atomic and molecular propositions](/Logic/Propositional_logic/Atomic_and_molecular_propositions.md) introduced previously.
|
||||
|
||||
1. If $P$ is an atomic proposition, $P$ contains no connectives and hence does not have a main connective. $P$ has no immediate propositional components.
|
||||
1. If $P$ is of the form $\lnot Q$ where $Q$ is a proposition, then the main connective of $P$ is the negation symbol that occurs before $Q$ and $Q$ is the immediate propositional component of $P$
|
||||
1. If P is of the form:
|
||||
1. $Q \land R$
|
||||
1. $Q \lor R$
|
||||
1. $Q \rightarrow R$
|
||||
1. $Q \leftrightarrow R$
|
||||
|
||||
where $Q$ and $R$ are propositions, then the main connective of $P$ is the connective that occurs between $Q$ and $R$ and $Q$ and $R$ are the immediate propositional components of $P$.
|
||||
|
|
@ -1,64 +0,0 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
---
|
||||
|
||||
## Syntax of formal languages versus semantics
|
||||
|
||||
> The syntactical study of a language is the study of the expressions of the language and the relations among them _without regard_ to the possible interpretations or 'meaning' of these expressions.
|
||||
|
||||
Syntax is talking about the order and placement of propositions relative to connectives and what constitutes a well-formed expression in these terms. Semantics is about what the connectives mean, in other words: truth-functions and truth-values and not just placement and order.
|
||||
|
||||
## Formal specification of the syntax of the language of Sentential Logic
|
||||
|
||||
### Vocabulary
|
||||
|
||||
Sentences in SL are capitalised Roman letters (non-bold) with or without natural number subscripts. We may call these sentence letters. For example:
|
||||
|
||||
```plain
|
||||
P, Q, R...P1, Q1, R1...
|
||||
```
|
||||
|
||||
The connectives of SL are the five truth-functional connectives:
|
||||
|
||||
```
|
||||
~, &, v, ⊃, ≡
|
||||
```
|
||||
|
||||
The punctuation marks of SL consist in the left and right parentheses:
|
||||
|
||||
```
|
||||
( )
|
||||
```
|
||||
|
||||
### Grammar
|
||||
|
||||
1. Every sentence letter is a sentence.
|
||||
1. If **P** is a sentence then **~P** is a sentence.
|
||||
1. If **P** and **Q** are sentences, then **(P & Q)** is a sentence
|
||||
1. If **P** and **Q** are sentences, then **(P v Q)** is a sentence
|
||||
1. If **P** and **Q** are sentences, then **(P ⊃ Q)** is a sentence
|
||||
1. If **P** and **Q** are sentences, then **(P ≡ Q)** is a sentence
|
||||
1. Nothing is a sentence unless it can be formed by repeated application of clauses 1-6
|
||||
|
||||
### Additional syntactic concepts
|
||||
|
||||
We also distinguish:
|
||||
|
||||
- the **main connective**
|
||||
- **immediate sentential components**
|
||||
- **sentential components**
|
||||
- **atomic components**
|
||||
|
||||
These definitions provide a formal specification of the concepts of atomic and molecular sentences _introduced earlier_.
|
||||
|
||||
1. If **P** is an atomic sentence, **P** contains no connectives and hence does not have a main connective. **P** has no immediate sentential components.
|
||||
1. If **P** is of the form **~Q** where **Q** is a sentence, then the main connective of **P** is the tilde that occurs before **Q** and **Q** is the immediate sentential component of **P**.
|
||||
1. If P is of the form:
|
||||
1. **Q & R**
|
||||
1. **Q v R**
|
||||
1. **Q ⊃ R**
|
||||
1. **Q ≡ R**
|
||||
|
||||
where **Q** and **R** are sentences, then the main connective of **P** is the connective that occurs between **Q** and **R** and **Q** and **R** are the immediate sentential components of **P**.
|
||||
|
|
@ -1,26 +1,26 @@
|
|||
---
|
||||
categories:
|
||||
- Mathematics
|
||||
tags: [logic]
|
||||
- Logic
|
||||
tags: [propositional-logic]
|
||||
---
|
||||
|
||||
## Truth-functional connectives
|
||||
# Truth-functional connectives
|
||||
|
||||
Sentences generated from other (simple) sentences by means of sentential connectives are [compound sentences](Atomic%20and%20molecular%20sentences.md).
|
||||
Propositions generated from other (simple) propositions by means of propositional connectives are [compound propositions](/Logic/Propositional_logic/Atomic_and_molecular_propositions.md).
|
||||
|
||||
We know that logically determinant sentences express a truth value. When simple sentences are joined with a connective to make a compound sentence they also have a truth value. This is determined by the nature of the connective and the truth value of the constituent sentences. We therefore call connectives of this nature truth _functional_ connectives since the **truth value of the compound is a function of the truth values of its components**.
|
||||
We know that [logically determinant](/Logic/General_concepts/Logical_indeterminacy.md) propositions express a truth value. When simple propositions are joined with a connective to make a compound proposition they also have a truth value. This is determined by the nature of the connective and the truth value of the constituent propositions. We therefore call connectives of this nature truth _functional_ connectives since the **truth value of the compound is a function of the truth values of its components**.
|
||||
|
||||
> A sentential connective is used truth-functionally if and only if it is used to generate a compound sentence from one or more sentences in such a way that the truth value of the generated compound is wholly determined by the truth-values of those one or more sentences from which the compound is generated, no matter what the truth values may be.
|
||||
> A propositional connective is used truth-functionally if and only if it is used to generate a compound proposition from one or more propositions in such a way that the truth value of the generated compound is wholly determined by the truth-values of those one or more propositions from which the compound is generated, no matter what the truth values may be.
|
||||
|
||||
Each truth-functional connective has a characteristic **truth-table**. This discloses the conditions under which the constituent sentences have a given truth value when combined with one or more connectives.
|
||||
Each truth-functional connective has a characteristic **truth table**. This discloses the conditions under which the constituent propositions have a given truth value when combined with one or more connectives.
|
||||
|
||||
We shall now review each of the truth-functional connectives in detail.
|
||||
|
||||
### Conjunction
|
||||
|
||||
Conjunction is equivalent to the word AND in natural language. We use `&` as the symbol for this connective.
|
||||
Conjunction is equivalent to the word AND in natural language. We use $\land$ as the symbol for this connective.
|
||||
|
||||
A molecular sentence joining two conjuncts P and Q is true iff both conjuncts are true and false otherwise:
|
||||
A molecular proposition joining two conjuncts P and Q is true iff both conjuncts are true and false otherwise:
|
||||
|
||||
```
|
||||
P Q P & Q
|
||||
|
|
@ -34,7 +34,7 @@ F F F
|
|||
|
||||
Conjunction is equivalent to the word OR in natural language. We use `v` as the symbol of this connective.
|
||||
|
||||
A molecular sentence joining two disjuncts P and Q is true if either disjunct is true or if both disjuncts are true and false otherwise. This corresponds to the inclusive sense of OR in natural language.
|
||||
A molecular proposition joining two disjuncts P and Q is true if either disjunct is true or if both disjuncts are true and false otherwise. This corresponds to the inclusive sense of OR in natural language.
|
||||
|
||||
```
|
||||
P Q P ∨ Q
|
||||
|
|
@ -46,7 +46,7 @@ F F F
|
|||
|
||||
### Negation
|
||||
|
||||
In contrast to the two previous connectives, negation is a unary connective not a binary connective. We use `~` to symbolise negation. It does not join two or more sentences, it applies to one sentence as a whole. This can be a simple sentence or a complex sentence. It simply negates the truth-value of whichever sentence it is applied to. Hence applied to P, it is true if P is false. And if P is false, it is true when P is true. !
|
||||
In contrast to the two previous connectives, negation is a unary connective not a binary connective. We use `~` to symbolise negation. It does not join two or more propositions, it applies to one proposition as a whole. This can be a simple proposition or a complex proposition. It simply negates the truth-value of whichever proposition it is applied to. Hence applied to P, it is true if P is false. And if P is false, it is true when P is true. !
|
||||
|
||||
```
|
||||
P ~ P
|
||||
|
|
@ -62,7 +62,7 @@ The material conditional approximates the meaning expressed in natural language
|
|||
If it rains today the pavement will be wet.
|
||||
```
|
||||
|
||||
We call the proposition that expresses the 'if' sentence the **antecedent** and the proposition that expresses the 'then' statement the **consequent**. The symbol we use to represent the material conditional is `⊃` although you may see `→` used as well.
|
||||
We call the proposition that expresses the 'if' proposition the **antecedent** and the proposition that expresses the 'then' statement the **consequent**. The symbol we use to represent the material conditional is `⊃` although you may see `→` used as well.
|
||||
|
||||
The truth table is as follows:
|
||||
|
||||
|
|
@ -74,7 +74,7 @@ F T T
|
|||
F F T
|
||||
```
|
||||
|
||||
The material conditional is perhaps the least intuitive of the logical connectives. The first case (TT) closely matches what we expect the connective to mean: it has rained so the pavement is wet. The antecedent is true and therefore the consequent is true. This chimes with what we tend to mean by 'if' in natural language. In the second case (TF) it also makes sense: the complex sentence is false because it rained and the pavement wasn't wet: this negates the truth of the expression. The final case (FF) is also straight forward. It didn't rain therefore the pavement wasn't wet, thus the overall assertion that rain implies wet pavements is retained.
|
||||
The material conditional is perhaps the least intuitive of the logical connectives. The first case (TT) closely matches what we expect the connective to mean: it has rained so the pavement is wet. The antecedent is true and therefore the consequent is true. This chimes with what we tend to mean by 'if' in natural language. In the second case (TF) it also makes sense: the complex proposition is false because it rained and the pavement wasn't wet: this negates the truth of the expression. The final case (FF) is also straight forward. It didn't rain therefore the pavement wasn't wet, thus the overall assertion that rain implies wet pavements is retained.
|
||||
|
||||
FT is less intuitive:
|
||||
|
||||
|
|
@ -84,7 +84,7 @@ It did not rain today. The pavement was wet.
|
|||
|
||||
To some degree one just has to take these statements as axioms, whether or not they have intuitive sense is a secondary, more philosophical question. The semantic issues arise because we tacitly assume the material conditional to be a causal connective: there is something about the nature of **P** that _engenders_ or _brings about_ **Q** but causality is not a logical concern.
|
||||
|
||||
If we instead just focus on the simple sentences that comprise the truth value it is more plausible. In the case of FT we can say it didn't rain yet the pavement was wet does not stop the pavement being wet when it rains. The fact that I can pour a beer on the pavement thereby making it wet doesn't stop or render false the idea that the rain can also make the pavement wet. The same explanation covers the FF case: it hasn't rained and so the pavement is not wet does not contradict the assertion that when it rains the pavement will be wet.
|
||||
If we instead just focus on the simple propositions that comprise the truth value it is more plausible. In the case of FT we can say it didn't rain yet the pavement was wet does not stop the pavement being wet when it rains. The fact that I can pour a beer on the pavement thereby making it wet doesn't stop or render false the idea that the rain can also make the pavement wet. The same explanation covers the FF case: it hasn't rained and so the pavement is not wet does not contradict the assertion that when it rains the pavement will be wet.
|
||||
|
||||
Things are elucidated when we look at an equivalent expression of P ⊃ Q, ~P v Q:
|
||||
|
||||
|
|
@ -100,7 +100,7 @@ A disjunction is true whenever either disjunct is true so when both are false th
|
|||
|
||||
### Material biconditional (a.k.a equivalence)
|
||||
|
||||
The material biconditional equates to the English expression 'if and only if', as a conditional connective it therefore avoids some of the perplexity aroused by its material cousin. In this scenario both antecedent and consequent have to be true for the overall expression to be true. If either is false the complex sentence is false. Other ways of expressing the semantics of this connective is to say that one sentence implies the other or that **P** and **Q** are equivalent.
|
||||
The material biconditional equates to the English expression 'if and only if', as a conditional connective it therefore avoids some of the perplexity aroused by its material cousin. In this scenario both antecedent and consequent have to be true for the overall expression to be true. If either is false the complex proposition is false. Other ways of expressing the semantics of this connective is to say that one proposition implies the other or that **P** and **Q** are equivalent.
|
||||
|
||||
```
|
||||
If and only if James studies every day he will pass the exam.
|
||||
|
|
@ -122,9 +122,9 @@ The last condition (FF) maybe requires some explanation: if he has not studied e
|
|||
|
||||
---
|
||||
|
||||
So far we have applied connectives to simple sentences. In so doing we generate complex sentences. However sentences and connectives are inherently generative: we can build more complex expressions from less complex parts, using more than one type of connective or several different connectives to make larger complex sentences and express more detailed logical conditions ans statements about the world.
|
||||
So far we have applied connectives to simple propositions. In so doing we generate complex propositions. However propositions and connectives are inherently generative: we can build more complex expressions from less complex parts, using more than one type of connective or several different connectives to make larger complex propositions and express more detailed logical conditions ans statements about the world.
|
||||
|
||||
For example the sentence:
|
||||
For example the proposition:
|
||||
|
||||
```
|
||||
Socrates was either a philosopher or a drinker but he wasn't a politician.
|
||||
|
|
@ -156,7 +156,7 @@ F F T F
|
|||
F F F F
|
||||
```
|
||||
|
||||
Let's walk through each case where S stands for the overall sentence.
|
||||
Let's walk through each case where S stands for the overall proposition.
|
||||
|
||||
1. S is false if Socrates was a philosopher, a drinker and a politician.
|
||||
1. **S is true if Socrates was a philosopher, a drinker but not a politician.**
|
||||
|
|
@ -169,13 +169,13 @@ Let's walk through each case where S stands for the overall sentence.
|
|||
|
||||
If we look just at the true cases for simplicity, it becomes obvious that the truth value of the whole is a function of the truth-values of the parts.
|
||||
|
||||
At the highest level of generality the sentence is a conjunction with two disjuncts: `P v Q` and `~R` . Therefore, for the sentence to be true both conjuncts must be true. The first conjunct is true just if one of the subordinate disjuncts is true (Socrates is either a philosopher, a drinker, or both). The second conjunct is true just if Socrates is not a politician. Thus there is only one variation for the second conjunct (not being a politician) and two variations for the first conjunct (being a drinker/being a philosopher) hence there are three cases where the overall sentence is true.
|
||||
At the highest level of generality the proposition is a conjunction with two disjuncts: `P v Q` and `~R` . Therefore, for the proposition to be true both conjuncts must be true. The first conjunct is true just if one of the subordinate disjuncts is true (Socrates is either a philosopher, a drinker, or both). The second conjunct is true just if Socrates is not a politician. Thus there is only one variation for the second conjunct (not being a politician) and two variations for the first conjunct (being a drinker/being a philosopher) hence there are three cases where the overall proposition is true.
|
||||
|
||||
### Logical equivalence
|
||||
|
||||
Once we start working with complex sentences with more than one truth-functional connective it becomes clear that the same sentence expressed in natural language can be expressed formally more than one way and thus that in logical terms, both formal expressions are equivalent. We can prove this equivalence by comparing truth tables.
|
||||
Once we start working with complex propositions with more than one truth-functional connective it becomes clear that the same proposition expressed in natural language can be expressed formally more than one way and thus that in logical terms, both formal expressions are equivalent. We can prove this equivalence by comparing truth tables.
|
||||
|
||||
For example the sentence:
|
||||
For example the proposition:
|
||||
|
||||
```
|
||||
I am going to the shops and the gym.
|
||||
|
|
@ -263,7 +263,7 @@ The example above is a key equivalence that you will encounter a lot especially
|
|||
|
||||
## Enforcing binary connectives through bracketing
|
||||
|
||||
If we had a sentence of the form
|
||||
If we had a proposition of the form
|
||||
|
||||
```
|
||||
Socrates is man, is mortal and a philosopher.
|
||||
|
|
@ -275,7 +275,7 @@ We could not write this as:
|
|||
P & Q & R
|
||||
```
|
||||
|
||||
This would not be a well-formed sentence because at most truth functional connectives can only connect two simple sentences. It would not be possible to generate truth conditions for this sentence in its current form. Instead we introduce brackets to enforce a binary grouping of simple sentences. In this instance, the placement of the brackets does not affect the accurate interpretation of the truth conditions of the compound, so the following two formalisations are equivalent:
|
||||
This would not be a well-formed proposition because at most truth functional connectives can only connect two simple propositions. It would not be possible to generate truth conditions for this proposition in its current form. Instead we introduce brackets to enforce a binary grouping of simple propositions. In this instance, the placement of the brackets does not affect the accurate interpretation of the truth conditions of the compound, so the following two formalisations are equivalent:
|
||||
|
||||
```
|
||||
(P & Q) & R
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ Using the definitions above, we can now define truth-functional consistency and
|
|||
|
||||
The following is a truth tree for the set ${P \lor Q, \sim P }$:
|
||||
|
||||

|
||||

|
||||
|
||||
### Interpretation
|
||||
|
||||
|
|
@ -90,7 +90,7 @@ Invoking the truth-table highlights the differences between the two techniques.
|
|||
|
||||
The following is a truth tree for the set ${A & \sim B, C, \sim A \lor \sim B }$.
|
||||
|
||||

|
||||

|
||||
|
||||
### Interpretation
|
||||
|
||||
|
|
@ -119,37 +119,37 @@ So far we have encountered the decomposition rules for conjunction (`&D`) and di
|
|||
|
||||
### Negated negation decomposition: `~~D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes only if $P$ is true
|
||||
|
||||
### Conjunction decomposition: `&D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes only $P$ and $Q$ are both true.
|
||||
|
||||
### Negated Conjunction decomposition: `~&D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if either $\sim P$ or $\sim Q$ is true. This rule is a consequence of the equivalence between $\sim (P & Q)$ and $\sim P \lor \sim Q$ , the first of DeMorgan’s Laws.
|
||||
|
||||
### Disjunction decomposition: `vD`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if either $P$or $Q$ are true.
|
||||
|
||||
### Negated Disjunction decomposition: `~vD`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if both $P$ and $Q$ are false. This rule is a consequence of the equivalence between $\sim (P \lor Q)$ and $\sim P & \sim Q$, the second of DeMorgan’s Laws.
|
||||
|
||||
### Conditional decomposition: `⊃D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if either $\sim P$ or $Q$ are true. This rule is a consequence of the equivalence between $P \supset Q$ and $\sim P \lor Q$ therefore this branch has the shape of a disjunction with $\sim P$ , $Q$ as its disjuncts.
|
||||
|
||||
|
|
@ -157,17 +157,17 @@ Truth passes if either $\sim P$ or $Q$ are true. This rule is a consequence of t
|
|||
|
||||
Truth passes if both $P$ and $\sim Q$ are true. This is a consequence of the equivalence between $\sim (P \supset Q)$ and $P & \sim Q$.
|
||||
|
||||

|
||||

|
||||
|
||||
### Biconditional decomposition: `≡D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if either $P$ and $Q$ are true or $\sim P & \sim Q$ are true. This is an interesting rule because it combines the disjunction and conjunction tree shapes.
|
||||
|
||||
### Negated biconditional decomposition: `~≡D`
|
||||
|
||||

|
||||

|
||||
|
||||
Truth passes if either $P$ and $\sim Q$ is true or if $\sim P$ and $Q$ is true.
|
||||
|
||||
|
|
@ -181,7 +181,7 @@ With truth-trees regardless of which order you decompose the set members, the co
|
|||
|
||||
Here are some examples of these rules applied:
|
||||
|
||||

|
||||

|
||||
|
||||
Observe that here we don’t bother to decompose the sentence on line 1. This is because, having decomposed the sentences on lines 2 and 3 we have arrived at a closed tree. It is therefore unnecessary to go any further for if two sentences in the set are inconsistent with each other, adding another sentence is not going to change the overall assignment of inconsistency.
|
||||
|
||||
|
|
@ -199,7 +199,7 @@ When we wish to assess [logical falsity](Logical%20truth%20and%20falsity.md#logi
|
|||
|
||||
A logically false sentence cannot be true on any assignment. This is the same thing as an inconsistent set. Thus it will be represented in a truth tree as inconsistency which is disclosed via a closed tree.
|
||||
|
||||

|
||||

|
||||
|
||||
### Logical truth
|
||||
|
||||
|
|
@ -221,7 +221,7 @@ Recall that $P$ and $Q$ are [logically equivalent](Logical%20equivalence.md) jus
|
|||
|
||||
> Sentences $P$ and $Q$ are truth-functionally equivalent if and only if the set $\sim (P \equiv Q)$ has a closed tree
|
||||
|
||||

|
||||

|
||||
|
||||
### Logical entailment and validity
|
||||
|
||||
|
|
|
|||
|
|
@ -11,15 +11,15 @@ tags:
|
|||
|
||||
Suppose you have the following shape:
|
||||
|
||||

|
||||

|
||||
|
||||
One part is shaded. This represents one-eighth of the original shape.
|
||||
|
||||

|
||||

|
||||
|
||||
Now imagine there are four instances of the shape and one-eighth remains shaded. How man one-eighths are there in four?
|
||||
|
||||

|
||||

|
||||
|
||||
The shaded proportion represents $\frac{1}{8}$ of the shape. Imagine four of these shapes, how many eighths are there?
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ tags:
|
|||
Two fractions are equivalent if they represent the same value.
|
||||
To begin with we can represent this visually:
|
||||
|
||||

|
||||

|
||||
|
||||
_Each shaded area is taking up the same proportion of the whole._
|
||||
|
||||
|
|
|
|||
|
|
@ -16,10 +16,10 @@ Prime factorisation is the activity of expressing a composite number as the uniq
|
|||
|
||||
> **Factor trees:** we take a number $n$ and break it down into two factors of $n$. We then repeat this process with the resulting factors working recursively until the numbers we are left with are primes.
|
||||
|
||||

|
||||

|
||||
_The prime factors of 27 are 2, 3, 3_
|
||||
|
||||
it doesn't matter which products we choose as the interim factors, we should always reach the same outcome:
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ This is still a bit long-winded however particularly when finding the factors of
|
|||
A better method is to utilise [prime factorization](Prime%20factorization.md) combined with the canceling technique.
|
||||
|
||||
First we find the prime factors of both the numerator and denominator:
|
||||

|
||||

|
||||
|
||||
This gives us:
|
||||
|
||||
|
|
@ -133,7 +133,7 @@ _Reduce the following fraction to its lowest terms: $$\frac{14y^5}{-35y^3}$$_
|
|||
|
||||
- Apply [Prime factorization](Prime%20factorization.md):
|
||||
|
||||

|
||||

|
||||
|
||||
- Cancel the coefficients and variable parts
|
||||
|
||||
|
|
@ -148,7 +148,7 @@ $$\frac{- 12xy^2}{ - 18xy^2}$$_
|
|||
|
||||
- Apply [Prime factorization](Prime%20factorization.md):
|
||||
|
||||

|
||||

|
||||
|
||||
- Cancel the coefficients and variable parts
|
||||
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ Even though most modern computers use UEFI, it may still be referred to as BIOS
|
|||
|
||||
The de facto standard boot loader for Linux is GRUB: Grand Unified Boot Loader.
|
||||
|
||||

|
||||

|
||||
|
||||
You see the GRUB default menu when you first start a Linux machine. It will offer you various options for loading your installed OS or other OSs. GRUB is a filesystem like the main disk. If you press `e` in this screen you can view and edit specific boot parameters. Pressing `c` gives you access to the GRUB command line interface. This allows you to interact with GRUB in the same way as you would with any other filesystem, allowing for advanced configuration.
|
||||
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ touch test.txt
|
|||
|
||||
Our `sda1` partition is now mounted at `mountpoint`. We can go ahead and create files. If we now look within the graphical file manager when we click on the `sda1` volume, we will see the new file we have created in `mountpoint`.
|
||||
|
||||

|
||||

|
||||
|
||||
## fstab
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ A disk is a mass storage [block_device](/Operating_Systems/Devices.md) which we
|
|||
|
||||
The following diagram represents the basic anatomy of a disk device.
|
||||
|
||||

|
||||

|
||||
|
||||
- A disk is divided up into [partitions](/Operating_Systems/Disks/Partitions.md) which are subsections of the overall disk. The kernel presents each partition as a [block device](/Operating_Systems/Devices.md) as it would with an entire disk.
|
||||
- The disk dedicates a small part of its contents to a **partition table**: this defines the different partitions that comprise the total disk space.
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ It can be confusing to understand how the kernel and CPU interact with one anoth
|
|||
|
||||
However as a process, the kernel is the 'first amongst equals' given that it is the core embodiment of the operating system. At boot time, the kernel is injected into memory and at this point the CPU _looks to this address_ in memory in order to source its first instruction. That's how the kernel gets going. It is the first instruction that the CPU fetches and this is what allows the kernel to play its mediatory role. However most of the fetch, decode, execute cycles of the CPU take place independently of the kernel.
|
||||
|
||||

|
||||

|
||||
|
||||
> Fetch decode and execute refer to processor pipeline stages. They occur automatically as part of normal processor operation, the kernel doesn’t generally have any direct control over how that happens...When the boot loader loads the kernel, it points the CPU’s program counter to an entry point in the kernel’s code. From there, the CPU will continue executing (fetching decoding and executing) kernel code until you point the program counter to a userspace program, where it will continue executing userspace code until an interrupt points the program counter back into kernel code. That’s basically what the CPU will be doing from boot up to shut down; switching between executing kernel code and executing userspace code ([Reddit](https://www.reddit.com/r/osdev/comments/wdskj5/how_does_kernel_decide_if_use_cpu_or_gpu_after/))
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ Virtual memory is implemented at the level of the operating system and is an abs
|
|||
|
||||
When virtual memory is used, the CPU handles physical memory allocation and presents this to the kernel as an idealised representation. This means that the kernel and, by extension, programs and processes do not need to think about accessing the real memory blocks. This reduces complexity because often memory will be allocated in places that are non-contiguous with similar running processes or be located in the cache or swap memory on the disk.
|
||||
|
||||

|
||||

|
||||
|
||||
It would require considerable processing work for the kernel to be tracing these disparate memory sources at every instance. By working on an idealised (contiguous, unlimited) memory set the kernel can focus on task management and CPU sequencing as its primary task.
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ The final phase is unmounting: when the component is removed from the DOM:
|
|||
|
||||
6. `componentWillUnmount()`
|
||||
|
||||

|
||||

|
||||
|
||||
## Side-effects: why lifecycle phases matter
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ Many backend frameworks are synchronous but multithreaded. This means that a thr
|
|||
|
||||
If there was only one thread, this would be inefficient and unworkable. Therefore the framework will be multi-threaded: multiple request-response cycles can be executed at once by different threads.
|
||||
|
||||

|
||||

|
||||
|
||||
To accomodate the ability to increase the scale of synchronous applications you need to be able to spawn more threads commensurate to increased demand. This increases the resource consumption of the framework (more cores, more memory etc). Moreover it is possible to reach a point where all threads are active and no more can be spawned. In this case there will simply be delays in the return of data.
|
||||
|
||||
|
|
@ -29,7 +29,7 @@ To accomodate the ability to increase the scale of synchronous applications you
|
|||
|
||||
In contrast, Node only has a single thread but it works asynchronously, not synchronously. Thus it has a **single-threaded asynchronous architecture**. This means whilst there is only a single thread it can juggle responses by dispatching them asynchronously. When a request is made it sends it off and continues with its execution and handling new requests. Once these resolve, the data is returned to the main thread.
|
||||
|
||||

|
||||

|
||||
|
||||
## The Event Loop
|
||||
|
||||
|
|
@ -45,7 +45,7 @@ A running Node application is a single running process. Like everything that hap
|
|||
|
||||
The Event Loop comprises six phases. The Event Loop starts at the moment Node begins to execute your `index.js` file or any other application entry point. These six phases create one cycle, or loop, equal to one **tick**. A Node.js process exits when there is no more pending work in the Event Loop, or when `process.exit()` is called manually. A program only runs for as long as there are tasks queued in the Event Loop, or present on the [call stack](/Software_Engineering/Call_stack.md).
|
||||
|
||||

|
||||

|
||||
|
||||
The phases are as follows:
|
||||
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ We can pinpoint specific dependencies in the `package.json`, e.g. `npm view [pac
|
|||
|
||||
See whether your dependency version is out of date use `npm outdated`. This gives us a table, for example:
|
||||
|
||||

|
||||

|
||||
|
||||
- _Latest_ tells us the latest release available from the developers
|
||||
- _Wanted_ tells us the version that our `package.json` rules target. To take the first dependency as an example. We must have set our SemVer syntax to `^0.4.x` since it is telling us that there is a minor release that is more recent than the one we have installed but is not advising that we update to the latest major release.
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ router.get("/", (req, res) => {
|
|||
|
||||
Our server is now set up:
|
||||
|
||||

|
||||

|
||||
|
||||
> When creating our API this structure of creating handlers for specific routes will be iterated. Every endpoint will be specified with `[app].[http_request_type]` and followed by a callback.
|
||||
|
||||
|
|
|
|||
3
README.md
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
# computer-science
|
||||
|
||||
This repository contains notes from my autodidactic study of Computer Science. As well as standard CS curricula it also houses notes related to my professional development as a software engineer. So there is a lot of practical content mixed in, such as topics in DevOps, Git, shell scripting etc. I find it easier to have everything in one place and cross-referenced through YAML.
|
||||
|
|
@ -11,7 +11,7 @@ tags:
|
|||
This sets a general purpose computer aside from a special-purpose computer, like the one you might find in your dishwasher which may have its instructions hardwired or coded into the machine. Special purpose computers only perform a single set of tasks according to prewritten instructions. We’ll take the term _computer_ to mean general purpose computer.
|
||||
|
||||
Simplified model of what a computer is:
|
||||

|
||||

|
||||
|
||||
Although the input, output and storage parts of a computer are very important, they will not be the focus of this course. Instead we are going to learn all about the process part, which will focus on how the computer is able to follow instructions to make calculations.
|
||||
|
||||
|
|
@ -35,9 +35,9 @@ Although the input, output and storage parts of a computer are very important, t
|
|||
- But as these machines were expensive and slow, people used pre-computed tables in book form generated by human computers. Useful particularly for things like square roots.
|
||||
- Similarly range tables were created that aided the military in calculating distances for gunboat artillery which factored in contextual factors like wind, drift, slope and elevation. These were used well into WW2 but they were limited to the particular type of cannon or shell
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||
> Before the invention of actual computers, 'computer' was a job-title denoting people who were employed to conduct complex calculations, sometimes with the aid of machinery, but most often not. This persisted until the late 18th century when the word changed to include devices like adding machines.
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ tags:
|
|||
|
||||
A Turing Machine consists of an infinitely long tape, that has been divided up into cells. Each cell can contain either a 1, a 0 or an empty space. Above one cell of the tape is a head, which can either move left or right, and can read the symbols written in the cells. The head is also capable of erasing symbols and writing new symbols into the cells.
|
||||
|
||||

|
||||

|
||||
The direction that the head moves, which values it erases, and which values it writes in, are dependent on a set of instructions provided to the machine.0
|
||||
|
||||
Different sets of instructions can be divided into **states.** States are like sub-routines and can themselves feature as part of instructions.
|
||||
|
|
|
|||
BIN
_img/1.4-Input-Process-Output.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
_img/3-bit-adder-diagram.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
_img/74181aluschematic.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
_img/FL-Databases-1.5_terminology.gif
Normal file
|
After Width: | Height: | Size: 68 KiB |
BIN
_img/LMC_5.gif
Normal file
|
After Width: | Height: | Size: 6.9 MiB |
BIN
_img/Memory-Hierarchy.jpg
Normal file
|
After Width: | Height: | Size: 312 KiB |
BIN
_img/ORelim1.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
_img/ORelim2.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
_img/Pasted_image_20220319135558.png
Normal file
|
After Width: | Height: | Size: 3.2 KiB |
BIN
_img/Pasted_image_20220319135805.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
_img/Pasted_image_20220319135823.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
_img/Pasted_image_20220319174839.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
_img/Pasted_image_20220411082627.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/REST_request-load.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
_img/Screenshot_2020-08-09_at_21.34.48.png
Normal file
|
After Width: | Height: | Size: 724 KiB |
BIN
_img/Screenshot_2021-05-11_at_18.51.02.png
Normal file
|
After Width: | Height: | Size: 198 KiB |
BIN
_img/Screenshot_2021-05-11_at_18.55.23.png
Normal file
|
After Width: | Height: | Size: 232 KiB |
BIN
_img/Turing_machines_01.gif
Normal file
|
After Width: | Height: | Size: 3.6 MiB |
38
_img/analog-digital.svg
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Copyright 2017 mathsisfun.com -->
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="360" height="160.5" version="1.1" style="font-family:'Comic Sans MS'; font-size:11.9px; fill:#0065a4; stroke-width:1px;">
|
||||
<defs/>
|
||||
<g transform="translate(-132.996,-941.117)">
|
||||
<path transform="translate(132.996,941.117)" style="fill:none; stroke:#ef2929; stroke-width:1.31;" d="M 0.5 82.4 C 0.5 82.4 19.9 106.5 37.1 112.7 C 54.4 119 64 121.2 84.4 117.2 C 104.8 113.2 118.9 101.2 128.9 87.3 C 138.9 73.5 169.9 13.5 198.8 10.4 C 216.5 8.4 232.3 31.3 246.8 58.9 "/>
|
||||
<rect x="262.6" y="1012" width="15.9" height="9.2" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.67;"/>
|
||||
<rect x="328.5" y="952.8" width="15.9" height="68.5" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="394.4" y="-1051.2" width="15.9" height="29.9" transform="scale(1,-1)" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="344.9" y="962.1" width="15.9" height="59.1" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="361.4" y="984.1" width="15.9" height="37.2" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="312" y="955.6" width="15.9" height="65.6" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="295.5" y="968.4" width="15.9" height="52.8" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="279" y="988.6" width="15.9" height="32.7" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.7;"/>
|
||||
<rect x="377.9" y="1014.5" width="15.9" height="7" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.76;"/>
|
||||
<rect x="410.8" y="-1079.7" width="15.9" height="58.4" transform="scale(1,-1)" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="427.3" y="-1088.9" width="15.9" height="67.7" transform="scale(1,-1)" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="443.8" y="-1071.1" width="15.9" height="49.8" transform="scale(1,-1)" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="460.3" y="-1032.4" width="15.9" height="11.1" transform="scale(1,-1)" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<rect x="476.7" y="990.6" width="15.9" height="30.7" style="fill:#19aeff; fill-opacity:0.17; stroke:#007ad2; stroke-width:0.69;"/>
|
||||
<text x="264.1" y="1009.2" transform="scale(0.999821,1.00018)">12</text>
|
||||
<text x="329.5" y="949.9" transform="scale(0.999821,1.00018)">82</text>
|
||||
<text x="313.1" y="953.8" transform="scale(0.999821,1.00018)">78</text>
|
||||
<text x="295.8" y="965.1" transform="scale(0.999822,1.00018)">63</text>
|
||||
<text x="278.6" y="986" transform="scale(0.999822,1.00018)">39</text>
|
||||
<text x="345.5" y="959.9" transform="scale(0.999821,1.00018)">70</text>
|
||||
<text x="362.7" y="982.8" transform="scale(0.999821,1.00018)">44</text>
|
||||
<text x="382" y="1010.9" transform="scale(0.999821,1.00018)">9</text>
|
||||
<text x="390.8" y="1061.8" transform="scale(0.999822,1.00018)">-36</text>
|
||||
<text x="406" y="1092" transform="scale(0.999822,1.00018)">-69</text>
|
||||
<text x="425.7" y="1100.9" transform="scale(0.999821,1.00018)">-80</text>
|
||||
<text x="443.4" y="1080.6" transform="scale(0.999821,1.00018)">-59</text>
|
||||
<text x="462.2" y="1043.4" transform="scale(0.999822,1.00018)">-14</text>
|
||||
<text x="477.6" y="988.3" transform="scale(0.999822,1.00018)">42</text>
|
||||
<text x="160.8" y="1038.9" transform="scale(0.999822,1.00018)" style="font-family:Verdana; font-size:22.7px; fill:#ef2929;">Analog</text>
|
||||
<text x="393.6" y="984.4" transform="scale(0.999822,1.00018)" style="font-family:Verdana; font-size:22.7px;">Digital</text>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.8 KiB |
BIN
_img/and-gate-new-2.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
BIN
_img/and-transistor.png
Normal file
|
After Width: | Height: | Size: 5.3 KiB |
BIN
_img/apollo-explorer.png
Normal file
|
After Width: | Height: | Size: 91 KiB |
4
_img/async.svg
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- Do not edit this file with editors other than diagrams.net -->
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" style="background-color: rgb(255, 255, 255);" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="351px" height="100px" viewBox="-0.5 -0.5 351 100" content="<mxfile host="app.diagrams.net" modified="2022-01-28T16:40:19.569Z" agent="5.0 (Windows)" etag="79nfJ7VIocRGYK2v8O42" version="16.5.1" type="github"><diagram id="E9uSWFrlHMG1s9rWNVgx" name="Page-1">3VhNc9owEP01HNNBkm2cYyAknU477QyHpkdhL7ZSYRFZBMivr2TJXxgImRLyQQ5on3ZX0tvVc0yPjObrW0kX6Q8RA+/hfrzukesexsjzsf4yyMYiQYAskEgWO6camLAncGDfoUsWQ95yVEJwxRZtMBJZBpFqYVRKsWq7zQRvr7qgCXSASUR5F/3NYpVaNMSDGv8KLEnLlVFwaWfmtHR2J8lTGotVAyLjHhlJIZQdzdcj4Ia8khcbd7NnttqYhEwdEzB5+DZI89vh/OfkcnY3vvDvcXbhNvtI+dId2G1WbUoGpFhmMZgk/R4ZrlKmYLKgkZld6ZprLFVzri2khzPG+UhwIYtYMvPNn8ZzJcVfaMwExcdEiEw1cPvRuNsYSAXrvSdGFY+6AUHMQcmNdikDBo5613voMrD2qq6k71zSZhEdRl3vJFXmml49cAy/gG30qdnG74zt6uLV7EKsL7czhVSpSERG+bhGh23+a5/vQiwc6/eg1MYpFV0q0a4JrJm6M+FffGf9acxcr13mwtiURqbP2wgyZhVljDqssOq4+MponDYzkYFFbpihqZjv9EGIp6ToAztTKhru9lLsQxh7VWcY4g73heZZLGUEhwri9JvKBNQBv8HuPpPAqWKP7X3s6poiVBNDNw2HhWCZyhuZfxlgv1hgb0tOt/xJ4B/y1wO7g7p/q6P8R0s/LyA6i342wsvFI4wginY1zTT0Pb9/IpEItkUCdUQC7xAJ/FoiQc4kyfuEd79Un4BtTN6bJKMOu+eQ5HPJaxCFMJ0dJa8Uwll0Wnn1jpRXhN9CX3WntfUSBwf11fP6h/xfR1+9j66vGLVZfnN9HXxmfSX+8/pKzqmv4Q62A65XHcbs0SzIWZIVE8HD0rx4DjnMVG3pUWK+ab7JolSKTCzzMoPeUJHEenSqqFlU7VKVixVLkKFhmukX6ysHz1kcW32HnD3RaZHIdIBTEp3VH/b8a5NJS3pu1R11auqkudkYJaR7ony0oBOUu/OG45FOuVH/nLcLHfEP4ce9Xh56/noFp7le2qx/ibFPk/r3LDL+Bw==</diagram></mxfile>"><defs/><g><rect x="50" y="53" width="50" height="10" fill="#f5f5f5" stroke="#666666" pointer-events="all"/><rect x="0" y="53" width="50" height="10" fill="#f5f5f5" stroke="#666666" pointer-events="all"/><path d="M 50 68 L 50 97.06 L 245.06 97.06 L 245 63" fill="none" stroke="#82b366" stroke-width="2" stroke-miterlimit="10" pointer-events="stroke"/><ellipse cx="50" cy="58" rx="10" ry="10" fill="#f8cecc" stroke="#b85450" pointer-events="all"/><rect x="110" y="53" width="50" height="10" fill="#f5f5f5" stroke="#666666" pointer-events="all"/><path d="M 105 68 L 105.06 82.94 L 320 82.94 L 320 63" fill="none" stroke="#6c8ebf" stroke-width="2" stroke-miterlimit="10" pointer-events="stroke"/><ellipse cx="105" cy="58" rx="10" ry="10" fill="#f8cecc" stroke="#b85450" pointer-events="all"/><rect x="230" y="53" width="30" height="10" fill="#f5f5f5" stroke="#666666" pointer-events="all"/><rect x="0" y="0" width="100" height="20" fill="none" stroke="none" pointer-events="all"/><g transform="translate(-0.5 -0.5)"><switch><foreignObject style="overflow: visible; text-align: left;" pointer-events="none" width="100%" height="100%" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: flex; align-items: unsafe center; justify-content: unsafe flex-start; width: 1px; height: 1px; padding-top: 10px; margin-left: 2px;"><div style="box-sizing: border-box; font-size: 0px; text-align: left;" data-drawio-colors="color: rgb(0, 0, 0); "><div style="display: inline-block; font-size: 12px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; pointer-events: all; font-weight: bold; white-space: nowrap;"><div align="left">asynchronous</div></div></div></div></foreignObject><text x="2" y="14" fill="rgb(0, 0, 0)" font-family="Helvetica" font-size="12px" font-weight="bold">asynchronous</text></switch></g><rect x="290" y="53" width="60" height="10" fill="#f5f5f5" stroke="#666666" pointer-events="all"/></g><switch><g requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"/><a transform="translate(0,-5)" xlink:href="https://www.diagrams.net/doc/faq/svg-export-text-problems" target="_blank"><text text-anchor="middle" font-size="10px" x="50%" y="100%">Text is not SVG - cannot display</text></a></switch></svg>
|
||||
|
After Width: | Height: | Size: 4 KiB |
1
_img/atom-diagram.svg
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
_img/basic-circuit.png
Normal file
|
After Width: | Height: | Size: 6.3 KiB |
BIN
_img/bi-intro.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
_img/biconditional-elim.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
_img/breadboard-DIP.jpg
Normal file
|
After Width: | Height: | Size: 45 KiB |
39
_img/breakdown.svg
Normal file
|
After Width: | Height: | Size: 148 KiB |
4
_img/cell-comparison.svg
Normal file
|
After Width: | Height: | Size: 16 KiB |
4
_img/charge-cylinder.svg
Normal file
|
After Width: | Height: | Size: 9 KiB |
4
_img/circ-batt-final.svg
Normal file
|
After Width: | Height: | Size: 9.6 KiB |
BIN
_img/clock_pulses.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
4
_img/complex-tree.svg
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
_img/cond-elim.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
_img/cond-intro.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
4
_img/conditional-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
_img/conjunc-elim.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
_img/conjunc-intro.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
4
_img/conjunction-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
_img/derivation_from_contradiction.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
_img/diode-led.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
_img/diode.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
4
_img/dipole-again.svg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
_img/disjunc-elim.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
_img/disjunc-intro.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
4
_img/disjunction-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 9.6 KiB |
BIN
_img/draw.io-Page-8.drawio.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
_img/draw.io-Page-9.drawio.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
_img/drawio-Page-7.drawio.png
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
_img/dsfdsfsdfwe.png
Normal file
|
After Width: | Height: | Size: 99 KiB |
BIN
_img/em-spectrum.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
_img/em-wave.gif
Normal file
|
After Width: | Height: | Size: 848 KiB |
BIN
_img/equiv-fractions.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
_img/four-bit-adder.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
_img/full-adder-new.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
_img/graphQL_request_load.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/graphql-architecture.png
Normal file
|
After Width: | Height: | Size: 47 KiB |
4
_img/graphql-journey-two.svg
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/graphql_multiple_resources.png
Normal file
|
After Width: | Height: | Size: 36 KiB |
4
_img/greyscale-encoding.svg
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
_img/ground-symbol.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/grub.jpg
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
_img/half-adder-gates-three.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
_img/half-adder-new.png
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
BIN
_img/harddisk.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
_img/hardware-abstraction-hierarchy.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
_img/hardware-sim-basic.png
Normal file
|
After Width: | Height: | Size: 51 KiB |
BIN
_img/hd-sim-test.png
Normal file
|
After Width: | Height: | Size: 79 KiB |
BIN
_img/hertz_wave_freq.gif
Normal file
|
After Width: | Height: | Size: 95 KiB |
4
_img/hexadecimal-to-bytes.svg
Normal file
|
After Width: | Height: | Size: 29 KiB |
BIN
_img/htop.png
Normal file
|
After Width: | Height: | Size: 157 KiB |
BIN
_img/integrated-circuit.jpeg
Normal file
|
After Width: | Height: | Size: 59 KiB |
BIN
_img/javascript-recursion.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
_img/jk-flip-flops.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
_img/journald.png
Normal file
|
After Width: | Height: | Size: 167 KiB |
4
_img/kernel-cpu-interaction.svg
Normal file
|
After Width: | Height: | Size: 27 KiB |
1
_img/lin.svg
Normal file
|
After Width: | Height: | Size: 9.2 KiB |
4
_img/logical-equivalence-tree.svg
Normal file
|
After Width: | Height: | Size: 47 KiB |
4
_img/logical-falsity-tree.svg
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
_img/lsof.png
Normal file
|
After Width: | Height: | Size: 140 KiB |
BIN
_img/magnetic_field.png
Normal file
|
After Width: | Height: | Size: 190 KiB |
4
_img/memory-flow.svg
Normal file
|
After Width: | Height: | Size: 9 KiB |
BIN
_img/mongo-collection.png
Normal file
|
After Width: | Height: | Size: 99 KiB |
BIN
_img/mongo-compass.png
Normal file
|
After Width: | Height: | Size: 76 KiB |
4
_img/mongo-db-structure.svg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
_img/mongo-doc-added.png
Normal file
|
After Width: | Height: | Size: 96 KiB |
4
_img/mongoose-hierarchy.svg
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
_img/motherboard-pi.jpg
Normal file
|
After Width: | Height: | Size: 122 KiB |
BIN
_img/mount-directory.png
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
_img/multi_on_off.gif
Normal file
|
After Width: | Height: | Size: 668 KiB |
BIN
_img/multiple_circuits.gif
Normal file
|
After Width: | Height: | Size: 1.3 MiB |
BIN
_img/multiplication_01.gif
Normal file
|
After Width: | Height: | Size: 451 KiB |
BIN
_img/multiplication_02.gif
Normal file
|
After Width: | Height: | Size: 447 KiB |
BIN
_img/multiplication_03.gif
Normal file
|
After Width: | Height: | Size: 434 KiB |
BIN
_img/multiplication_04.gif
Normal file
|
After Width: | Height: | Size: 827 KiB |
BIN
_img/nand-gate-new.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
BIN
_img/nand-mem-demonstrated.gif
Normal file
|
After Width: | Height: | Size: 70 KiB |
BIN
_img/nand-mem-first.gif
Normal file
|
After Width: | Height: | Size: 45 KiB |
BIN
_img/nand-mem-second.gif
Normal file
|
After Width: | Height: | Size: 43 KiB |
BIN
_img/nand_latch_logic_circuit.png
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
_img/negate-elim.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/negate-intro.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
4
_img/negated-biconditional-decomposition-rule.drawio.svg
Normal file
|
After Width: | Height: | Size: 13 KiB |
4
_img/negated-conditional-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 12 KiB |
4
_img/negated-conjunction-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
4
_img/negated-disjunction-decomposition-rule.svg
Normal file
|
After Width: | Height: | Size: 11 KiB |
4
_img/node-event-loop.svg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
_img/nor-gate-new.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
_img/not-gate-new.png
Normal file
|
After Width: | Height: | Size: 2.6 KiB |
BIN
_img/one-eighth-a.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
_img/or-gate-new.png
Normal file
|
After Width: | Height: | Size: 2.2 KiB |
4
_img/or-transistor.svg
Normal file
|
After Width: | Height: | Size: 21 KiB |
689
_img/parallel-battery-diagram.svg
Normal file
|
|
@ -0,0 +1,689 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
width="167.85909mm"
|
||||
height="84.399048mm"
|
||||
viewBox="0 0 167.85909 84.399048"
|
||||
version="1.1"
|
||||
id="svg1594"
|
||||
sodipodi:docname="parallel-battery-diagram.svg"
|
||||
inkscape:version="1.2.1 (9c6d41e410, 2022-07-14)"
|
||||
inkscape:export-filename="parallel-batt2.svg"
|
||||
inkscape:export-xdpi="96"
|
||||
inkscape:export-ydpi="96"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg">
|
||||
<sodipodi:namedview
|
||||
id="namedview1596"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#eeeeee"
|
||||
borderopacity="1"
|
||||
inkscape:showpageshadow="0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pagecheckerboard="0"
|
||||
inkscape:deskcolor="#505050"
|
||||
inkscape:document-units="mm"
|
||||
showgrid="false"
|
||||
showguides="true"
|
||||
inkscape:zoom="3.9408307"
|
||||
inkscape:cx="505.85782"
|
||||
inkscape:cy="236.62524"
|
||||
inkscape:window-width="2346"
|
||||
inkscape:window-height="944"
|
||||
inkscape:window-x="26"
|
||||
inkscape:window-y="23"
|
||||
inkscape:window-maximized="0"
|
||||
inkscape:current-layer="layer1">
|
||||
<inkscape:grid
|
||||
type="xygrid"
|
||||
id="grid7029"
|
||||
originx="-11.038969"
|
||||
originy="-84.518999" />
|
||||
</sodipodi:namedview>
|
||||
<defs
|
||||
id="defs1591">
|
||||
<marker
|
||||
style="overflow:visible"
|
||||
id="Dot"
|
||||
refX="0"
|
||||
refY="0"
|
||||
orient="auto"
|
||||
inkscape:stockid="Dot"
|
||||
markerWidth="3.6670001"
|
||||
markerHeight="3.6670001"
|
||||
viewBox="0 0 5.6666667 5.6666667"
|
||||
inkscape:isstock="true"
|
||||
inkscape:collect="always"
|
||||
preserveAspectRatio="xMidYMid">
|
||||
<path
|
||||
transform="scale(0.5)"
|
||||
style="fill:context-stroke;fill-rule:evenodd;stroke:context-stroke;stroke-width:1pt"
|
||||
d="M 5,0 C 5,2.76 2.76,5 0,5 -2.76,5 -5,2.76 -5,0 c 0,-2.76 2.3,-5 5,-5 2.76,0 5,2.24 5,5 z"
|
||||
id="Dot1"
|
||||
sodipodi:nodetypes="sssss" />
|
||||
</marker>
|
||||
<inkscape:perspective
|
||||
sodipodi:type="inkscape:persp3d"
|
||||
inkscape:vp_x="0 : -64.100957 : 1"
|
||||
inkscape:vp_y="0 : 999.99998 : 0"
|
||||
inkscape:vp_z="210.00001 : -64.100957 : 1"
|
||||
inkscape:persp3d-origin="105.00001 : -113.60095 : 1"
|
||||
id="perspective1773" />
|
||||
</defs>
|
||||
<g
|
||||
inkscape:label="Layer 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-11.038969,-84.519)">
|
||||
<rect
|
||||
style="fill:#f2f2f2;fill-opacity:1;stroke:#000000;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="rect11490"
|
||||
width="167.25908"
|
||||
height="83.799049"
|
||||
x="11.338969"
|
||||
y="84.819"
|
||||
rx="0"
|
||||
ry="0" />
|
||||
<g
|
||||
id="g5763"
|
||||
transform="matrix(1,0,0,0.88297298,0,12.476157)"
|
||||
style="stroke-width:1.06421">
|
||||
<g
|
||||
id="g5561"
|
||||
style="stroke-width:0.638524;stroke-dasharray:none">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect1831"
|
||||
width="29.184156"
|
||||
height="42.17189"
|
||||
x="36.551899"
|
||||
y="107.70461"
|
||||
rx="15.868324"
|
||||
ry="5.9747577" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889"
|
||||
cx="51.225346"
|
||||
cy="111.95552"
|
||||
rx="14.632196"
|
||||
ry="4.1182208" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889-9"
|
||||
cx="51.205845"
|
||||
cy="110.72742"
|
||||
rx="14.536783"
|
||||
ry="4.1182208" />
|
||||
</g>
|
||||
</g>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="47.560608"
|
||||
y="129.51152"
|
||||
id="text2052"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="47.560608"
|
||||
y="129.51152">1.5 V</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="53.336403"
|
||||
y="103.73036"
|
||||
id="text2052-9"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-opacity:1"
|
||||
x="53.336403"
|
||||
y="103.73036">+</tspan></text>
|
||||
<g
|
||||
id="g5763-1"
|
||||
transform="matrix(1,0,0,0.88297298,79.433769,12.520703)"
|
||||
style="stroke-width:1.06421">
|
||||
<g
|
||||
id="g5561-7"
|
||||
style="stroke-width:0.638524;stroke-dasharray:none">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect1831-7"
|
||||
width="29.184156"
|
||||
height="42.17189"
|
||||
x="36.551899"
|
||||
y="107.70461"
|
||||
rx="15.868324"
|
||||
ry="5.9747577" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889-1"
|
||||
cx="51.225346"
|
||||
cy="111.95552"
|
||||
rx="14.632196"
|
||||
ry="4.1182208" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889-9-1"
|
||||
cx="51.205845"
|
||||
cy="110.72742"
|
||||
rx="14.536783"
|
||||
ry="4.1182208" />
|
||||
</g>
|
||||
</g>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="126.99438"
|
||||
y="129.55606"
|
||||
id="text2052-0"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-9"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="126.99438"
|
||||
y="129.55606">1.5 V</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="123.43864"
|
||||
y="95.87645"
|
||||
id="text2052-0-6"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-9-9"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:2.82222px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="123.43864"
|
||||
y="95.87645">1.5 V</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#0000ff;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="134.7086"
|
||||
y="98.829781"
|
||||
id="text2052-9-9-8"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-0-5"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#0000ff;stroke:none;stroke-width:0.131"
|
||||
x="134.7086"
|
||||
y="98.829781">-</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="100.20913"
|
||||
y="122.68433"
|
||||
id="text2052-9-9-8-2"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-0-5-5"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke:none;stroke-width:0.131"
|
||||
x="100.20913"
|
||||
y="122.68433">-</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="60.020687"
|
||||
y="104.97092"
|
||||
id="text2052-9-9-8-4"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-0-5-0"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke:none;stroke-width:0.131"
|
||||
x="60.020687"
|
||||
y="104.97092">-</tspan></text>
|
||||
<g
|
||||
id="g5763-11"
|
||||
transform="matrix(1,0,0,0.88297298,40.19319,29.941962)"
|
||||
style="stroke-width:1.06421">
|
||||
<g
|
||||
id="g5561-5"
|
||||
style="stroke-width:0.638524;stroke-dasharray:none">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect1831-9"
|
||||
width="29.184156"
|
||||
height="42.17189"
|
||||
x="36.551899"
|
||||
y="107.70461"
|
||||
rx="15.868324"
|
||||
ry="5.9747577" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889-8"
|
||||
cx="51.225346"
|
||||
cy="111.95552"
|
||||
rx="14.632196"
|
||||
ry="4.1182208" />
|
||||
<ellipse
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.638524;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="path1889-9-4"
|
||||
cx="51.205845"
|
||||
cy="110.72742"
|
||||
rx="14.536783"
|
||||
ry="4.1182208" />
|
||||
</g>
|
||||
</g>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="87.753799"
|
||||
y="146.97733"
|
||||
id="text2052-1"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-8"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="87.753799"
|
||||
y="146.97733">1.5 V</tspan></text>
|
||||
<path
|
||||
style="fill:none;stroke:#d40000;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 54.208389,109.75179 c 12.446443,5.3942 16.496376,8.26753 20.771904,12.94608 7.48606,8.19171 18.593709,4.01613 18.593709,4.01613"
|
||||
id="path9813"
|
||||
sodipodi:nodetypes="csc" />
|
||||
<g
|
||||
id="g5670-4"
|
||||
transform="translate(-23.391324,1.6043599)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8-7"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9-8"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7-4" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3-5" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6-0" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1-3" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2-6" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93-1" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1-0" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9-6" />
|
||||
</g>
|
||||
<path
|
||||
style="fill:none;stroke:#d40000;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Dot)"
|
||||
d="m 95.775941,127.05899 c 7.421559,4.76267 17.036309,2.97123 22.173259,1.46484 23.3666,-6.85216 14.97722,-30.962889 9.38445,-29.181746"
|
||||
id="path10059"
|
||||
sodipodi:nodetypes="csc" />
|
||||
<g
|
||||
id="g5670-4-1"
|
||||
transform="translate(16.801866,19.070165)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8-7-7"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9-8-5"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7-4-9" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3-5-6" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6-0-2" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1-3-1" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2-6-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93-1-85" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1-0-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9-6-4" />
|
||||
</g>
|
||||
<g
|
||||
id="g5670-4-4"
|
||||
transform="translate(56.042445,1.6489057)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8-7-8"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9-8-1"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7-4-2" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3-5-9" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6-0-3" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1-3-9" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2-6-0" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93-1-8" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1-0-8" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9-6-5" />
|
||||
</g>
|
||||
<path
|
||||
style="fill:none;fill-opacity:1;stroke:#1100cb;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 61.628334,110.67362 c 4.092734,12.58375 11.925523,16.26868 15.744737,21.51224 8.833664,12.12812 25.223209,-4.24691 25.582969,-4.69682"
|
||||
id="path10094"
|
||||
sodipodi:nodetypes="csc" />
|
||||
<g
|
||||
id="g5670"
|
||||
transform="translate(-17.161725,2.6692588)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9" />
|
||||
</g>
|
||||
<path
|
||||
style="fill:none;fill-opacity:1;stroke:#1100cb;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Dot)"
|
||||
d="m 101.38431,127.85411 c 6.14872,-2.76259 24.75068,-6.24215 29.54869,-6.4841 21.05827,-1.06189 6.53711,-22.349141 1.9878,-23.262611"
|
||||
id="path10876"
|
||||
sodipodi:nodetypes="csc" />
|
||||
<g
|
||||
id="g5670-8"
|
||||
transform="translate(23.031465,20.135064)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8-1"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9-0"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7-3" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3-0" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6-4" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1-4" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2-4" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93-4" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9-63" />
|
||||
</g>
|
||||
<g
|
||||
id="g5670-5"
|
||||
transform="translate(62.272044,2.7138047)">
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect2368-8-9"
|
||||
width="4.62432"
|
||||
height="5.5953016"
|
||||
x="75.821289"
|
||||
y="102.56096"
|
||||
rx="2.4116266"
|
||||
ry="0.74982649" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
id="rect5296-9-7"
|
||||
width="4.5780368"
|
||||
height="1.0768906"
|
||||
x="75.832077"
|
||||
y="102.5574"
|
||||
rx="2.4116263"
|
||||
ry="2.4116263" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.297111,103.46708 c -0.0043,4.34346 -0.01896,4.32759 -0.01896,4.32759"
|
||||
id="path5355-7-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 76.890223,103.65618 c -0.0043,4.34344 -0.01896,4.32758 -0.01896,4.32758"
|
||||
id="path5355-0-3-6" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.451286,103.71402 c -0.0043,4.38827 -0.01896,4.37224 -0.01896,4.37224"
|
||||
id="path5355-0-2-6-7" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 77.989636,103.71983 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-1-36" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 78.576586,103.71312 c -0.0043,4.43657 -0.01896,4.42036 -0.01896,4.42036"
|
||||
id="path5355-0-2-3-7-2-5" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.133333,103.69821 c -0.0043,4.35162 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-93-6" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 79.64944,103.60865 c -0.0043,4.35163 -0.01896,4.33573 -0.01896,4.33573"
|
||||
id="path5355-0-2-3-7-5-9-1-3" />
|
||||
<path
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.231;stroke-linecap:square;stroke-dasharray:none"
|
||||
d="m 80.08699,103.47617 c -0.0043,4.35163 -0.01896,4.33574 -0.01896,4.33574"
|
||||
id="path5355-0-2-3-7-5-9-2-9-9" />
|
||||
</g>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="93.286148"
|
||||
y="120.80184"
|
||||
id="text2052-9-3"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-03"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-opacity:1"
|
||||
x="93.286148"
|
||||
y="120.80184">+</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="139.54593"
|
||||
y="105.43155"
|
||||
id="text2052-9-9-8-2-2"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-0-5-5-2"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke:none;stroke-width:0.131"
|
||||
x="139.54593"
|
||||
y="105.43155">-</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="132.62296"
|
||||
y="103.54906"
|
||||
id="text2052-9-3-4"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-03-7"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-opacity:1"
|
||||
x="132.62296"
|
||||
y="103.54906">+</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#d20000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="122.45236"
|
||||
y="100.51137"
|
||||
id="text2052-9-0"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan2050-4-9"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:4.58611px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#d20000;fill-opacity:1;stroke:none;stroke-width:0.131;stroke-opacity:1"
|
||||
x="122.45236"
|
||||
y="100.51137">+</tspan></text>
|
||||
<path
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="path11212"
|
||||
sodipodi:type="arc"
|
||||
sodipodi:cx="132.90474"
|
||||
sodipodi:cy="98.110756"
|
||||
sodipodi:rx="0.79117769"
|
||||
sodipodi:ry="0.82409161"
|
||||
sodipodi:start="0"
|
||||
sodipodi:end="6.009063"
|
||||
sodipodi:open="true"
|
||||
sodipodi:arc-type="arc"
|
||||
d="m 133.69592,98.110756 a 0.79117769,0.82409161 0 0 1 -0.737,0.822157 0.79117769,0.82409161 0 0 1 -0.83794,-0.709559 0.79117769,0.82409161 0 0 1 0.62224,-0.919335 0.79117769,0.82409161 0 0 1 0.92316,0.583654" />
|
||||
<path
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.600001;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="path11212-4"
|
||||
sodipodi:type="arc"
|
||||
sodipodi:cx="127.33162"
|
||||
sodipodi:cy="99.361092"
|
||||
sodipodi:rx="0.79117769"
|
||||
sodipodi:ry="0.82409161"
|
||||
sodipodi:start="0"
|
||||
sodipodi:end="6.009063"
|
||||
sodipodi:open="true"
|
||||
sodipodi:arc-type="arc"
|
||||
d="m 128.1228,99.361092 a 0.79117769,0.82409161 0 0 1 -0.737,0.822158 0.79117769,0.82409161 0 0 1 -0.83794,-0.709561 0.79117769,0.82409161 0 0 1 0.62224,-0.919334 0.79117769,0.82409161 0 0 1 0.92316,0.583653" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 36 KiB |
BIN
_img/parallel-transmission.jpg
Normal file
|
After Width: | Height: | Size: 108 KiB |
BIN
_img/proof.png
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
_img/proofs-drawio-Page-5.drawio.png
Normal file
|
After Width: | Height: | Size: 9.9 KiB |
BIN
_img/proofs-drawio-Page-5.drawio_2.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
_img/proofs-drawio-Page-6.drawio.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
20
_img/queue.svg
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="437px" height="301px" viewBox="0 0 437 301" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>Artboard</title>
|
||||
<g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<rect fill="#FFFFFF" x="0" y="0" width="437" height="301"></rect>
|
||||
<g id="Data_Queue" transform="translate(47.000000, 22.000000)">
|
||||
<rect id="node0" stroke="#6D7278" stroke-width="1.00000924" fill-opacity="0.1" fill="#000000" fill-rule="nonzero" transform="translate(89.496750, 132.289251) rotate(89.753630) translate(-89.496750, -132.289251) " x="45.9963478" y="118.789126" width="87.0008043" height="27.0002496"></rect>
|
||||
<polygon id="path1446" stroke="#6D7278" fill="#6D7278" fill-rule="nonzero" points="324.901 146.491 326.067 163.674 315.986 149.682"></polygon>
|
||||
<path d="M58.158,130.233 L58.158,130.233 C4.629,121.641 13.264,92.714 13.264,92.714" id="path2432" stroke="#6D7278" stroke-width="0.7364"></path>
|
||||
<path d="M322.443,151.213 L322.443,151.213 C302.228,124.401 246.556,129.739 246.556,129.739" id="path3204" stroke="#6D7278" stroke-width="0.7313"></path>
|
||||
<rect id="rect2481" stroke="#6D7278" stroke-width="1.00000924" fill-opacity="0.1" fill="#000000" fill-rule="nonzero" transform="translate(124.496150, 132.289551) rotate(89.753630) translate(-124.496150, -132.289551) " x="80.9957478" y="118.789426" width="87.0008043" height="27.0002496"></rect>
|
||||
<rect id="rect2483" stroke="#6D7278" stroke-width="1.00000924" fill-opacity="0.1" fill="#000000" fill-rule="nonzero" transform="translate(159.496550, 132.290751) rotate(89.753630) translate(-159.496550, -132.290751) " x="115.996148" y="118.790626" width="87.0008043" height="27.0002496"></rect>
|
||||
<rect id="rect2485" stroke="#6D7278" stroke-width="1.00000924" fill-opacity="0.1" fill="#000000" fill-rule="nonzero" transform="translate(194.496250, 132.291151) rotate(89.753630) translate(-194.496250, -132.291151) " x="150.995848" y="118.791026" width="87.0008043" height="27.0002496"></rect>
|
||||
<rect id="rect2487" stroke="#6D7278" stroke-width="1.00000924" fill-opacity="0.1" fill="#000000" fill-rule="nonzero" transform="translate(229.495850, 132.291451) rotate(89.753630) translate(-229.495850, -132.291451) " x="185.995448" y="118.791326" width="87.0008043" height="27.0002496"></rect>
|
||||
<polygon id="path2489" stroke="#6D7278" fill="#6D7278" fill-rule="nonzero" points="52.739 125.016 69.294 129.764 52.706 134.485"></polygon>
|
||||
<rect id="rect2491" stroke="#FA6400" stroke-width="1.00000924" fill-opacity="0.426283189" fill="#FA6400" fill-rule="nonzero" transform="translate(14.499150, 44.249475) rotate(89.753630) translate(-14.499150, -44.249475) " x="-29.0012522" y="30.7493502" width="87.0008043" height="27.0002496"></rect>
|
||||
<rect id="rect2493" stroke="#6DD400" stroke-width="1.00000924" fill-opacity="0.423111069" fill="#6DD400" fill-rule="nonzero" transform="translate(329.494752, 212.751725) rotate(89.753630) translate(-329.494752, -212.751725) " x="285.99385" y="199.2516" width="87.0018043" height="27.0002496"></rect>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.2 KiB |
BIN
_img/react-lifecycle.png
Normal file
|
After Width: | Height: | Size: 35 KiB |
4
_img/red-encoding.svg
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
_img/reiteration.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
_img/serial-transmission.jpg
Normal file
|
After Width: | Height: | Size: 81 KiB |
28
_img/series-battcircuit.svg
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Generator: Circuit Diagram, cdlibrary.dll 4.0.0.0 -->
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg version="1.1" width="360" height="160" xmlns="http://www.w3.org/2000/svg">
|
||||
<line x1="230" y1="130" x2="277" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="277" y1="120" x2="277" y2="140" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="283" y1="125" x2="283" y2="135" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:3" />
|
||||
<line x1="283" y1="130" x2="330" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<text x="280" y="118" style="font-family:Arial;font-size:12px;text-anchor:middle" dominant-baseline="baseline" transform="rotate(0, 280, 118)">+1.5V</text>
|
||||
<line x1="130" y1="130" x2="177" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="177" y1="120" x2="177" y2="140" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="183" y1="125" x2="183" y2="135" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:3" />
|
||||
<line x1="183" y1="130" x2="230" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<text x="180" y="118" style="font-family:Arial;font-size:12px;text-anchor:middle" dominant-baseline="baseline" transform="rotate(0, 180, 118)">+1.5V</text>
|
||||
<line x1="30" y1="130" x2="77" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="77" y1="120" x2="77" y2="140" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="83" y1="125" x2="83" y2="135" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:3" />
|
||||
<line x1="83" y1="130" x2="130" y2="130" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<text x="80" y="118" style="font-family:Arial;font-size:12px;text-anchor:middle" dominant-baseline="baseline" transform="rotate(0, 80, 118)">+1.5V</text>
|
||||
<line x1="180" y1="60" x2="184" y2="60" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="184" y1="50" x2="184" y2="70" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="178" y1="55" x2="178" y2="65" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="172" y1="50" x2="172" y2="70" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="166" y1="55" x2="166" y2="65" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<line x1="166" y1="60" x2="170" y2="60" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
<text x="175" y="48" style="font-family:Arial;font-size:12px;text-anchor:middle" dominant-baseline="baseline" transform="rotate(0, 175, 48)">+4.5V</text>
|
||||
<line x1="30" y1="60" x2="330" y2="60" style="stroke:rgb(0, 0, 0);stroke-linecap:square;stroke-width:2" />
|
||||
</svg>
|
||||
245
_img/series-battery-diagram.svg
Normal file
|
|
@ -0,0 +1,245 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
width="208.46194mm"
|
||||
height="72.315628mm"
|
||||
viewBox="0 0 208.46193 72.315628"
|
||||
version="1.1"
|
||||
id="svg5"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg">
|
||||
<defs
|
||||
id="defs2">
|
||||
<marker
|
||||
style="overflow:visible"
|
||||
id="marker1226"
|
||||
refX="0"
|
||||
refY="0"
|
||||
orient="auto-start-reverse"
|
||||
markerWidth="5.3244081"
|
||||
markerHeight="6.155385"
|
||||
viewBox="0 0 5.3244081 6.1553851"
|
||||
preserveAspectRatio="xMidYMid">
|
||||
<path
|
||||
transform="scale(0.5)"
|
||||
style="fill:context-stroke;fill-rule:evenodd;stroke:context-stroke;stroke-width:1pt"
|
||||
d="M 5.77,0 -2.88,5 V -5 Z"
|
||||
id="path1224" />
|
||||
</marker>
|
||||
<marker
|
||||
style="overflow:visible"
|
||||
id="TriangleStart"
|
||||
refX="0"
|
||||
refY="0"
|
||||
orient="auto-start-reverse"
|
||||
markerWidth="5.3244081"
|
||||
markerHeight="6.155385"
|
||||
viewBox="0 0 5.3244081 6.1553851"
|
||||
preserveAspectRatio="xMidYMid">
|
||||
<path
|
||||
transform="scale(0.5)"
|
||||
style="fill:context-stroke;fill-rule:evenodd;stroke:context-stroke;stroke-width:1pt"
|
||||
d="M 5.77,0 -2.88,5 V -5 Z"
|
||||
id="path135" />
|
||||
</marker>
|
||||
<rect
|
||||
x="444.00934"
|
||||
y="391.71231"
|
||||
width="193.4772"
|
||||
height="38.969021"
|
||||
id="rect2563" />
|
||||
<rect
|
||||
x="644.48657"
|
||||
y="351.32187"
|
||||
width="131.46619"
|
||||
height="16.049915"
|
||||
id="rect2553" />
|
||||
</defs>
|
||||
<g
|
||||
id="layer1"
|
||||
transform="translate(-22.223583,-34.805419)">
|
||||
<rect
|
||||
style="fill:#f2f2f2;fill-opacity:1;stroke:#000000;stroke-width:0.431001;stroke-linecap:square;stroke-linejoin:miter;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="rect2573"
|
||||
width="117.65163"
|
||||
height="53.563263"
|
||||
x="26.310938"
|
||||
y="45.766743"
|
||||
rx="0"
|
||||
ry="0" />
|
||||
<rect
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.731;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect254"
|
||||
width="29.939589"
|
||||
height="14.958732"
|
||||
x="37.675056"
|
||||
y="69.985207"
|
||||
ry="1.9412589"
|
||||
rx="0.9042781" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.431001;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect935"
|
||||
width="1.9654146"
|
||||
height="6.303196"
|
||||
x="67.599091"
|
||||
y="74.227417"
|
||||
rx="0.59598941"
|
||||
ry="0.59598941" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.631;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
d="m 65.908805,70.363433 c 0.177472,14.483408 0.177472,14.483408 0.177472,14.483408"
|
||||
id="path991" />
|
||||
<rect
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.130999;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="rect993"
|
||||
width="0.40091172"
|
||||
height="7.495573"
|
||||
x="67.432716"
|
||||
y="73.648491"
|
||||
rx="0.59598941"
|
||||
ry="0.8551048" />
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="47.922768"
|
||||
y="78.70002"
|
||||
id="text2052"><tspan
|
||||
id="tspan2050"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="47.922768"
|
||||
y="78.70002">1.5 V</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="80.406326"
|
||||
y="58.732193"
|
||||
id="text2052-2"><tspan
|
||||
id="tspan2050-2"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="80.406326"
|
||||
y="58.732193">4.5 V</tspan></text>
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.731;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect254-8"
|
||||
width="29.939589"
|
||||
height="14.958732"
|
||||
x="69.647232"
|
||||
y="69.960724"
|
||||
ry="1.9412589"
|
||||
rx="0.9042781" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.431001;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect935-9"
|
||||
width="1.9654146"
|
||||
height="6.303196"
|
||||
x="99.571266"
|
||||
y="74.202934"
|
||||
rx="0.59598941"
|
||||
ry="0.59598941" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.631;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
d="m 97.880982,70.338953 c 0.177472,14.483408 0.177472,14.483408 0.177472,14.483408"
|
||||
id="path991-2" />
|
||||
<rect
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.130999;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="rect993-6"
|
||||
width="0.40091172"
|
||||
height="7.495573"
|
||||
x="99.404892"
|
||||
y="73.624008"
|
||||
rx="0.59598941"
|
||||
ry="0.8551048" />
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="79.894943"
|
||||
y="78.675537"
|
||||
id="text2052-6"><tspan
|
||||
id="tspan2050-4"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="79.894943"
|
||||
y="78.675537">1.5 V</tspan></text>
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.731;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect254-8-5"
|
||||
width="29.939589"
|
||||
height="14.958732"
|
||||
x="101.78661"
|
||||
y="70.082413"
|
||||
ry="1.9412589"
|
||||
rx="0.9042781" />
|
||||
<rect
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.431001;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
id="rect935-9-0"
|
||||
width="1.9654146"
|
||||
height="6.303196"
|
||||
x="131.71065"
|
||||
y="74.324623"
|
||||
rx="0.59598941"
|
||||
ry="0.59598941" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.631;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none"
|
||||
d="m 130.02036,70.460639 c 0.17747,14.483408 0.17747,14.483408 0.17747,14.483408"
|
||||
id="path991-2-4" />
|
||||
<rect
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.130999;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="rect993-6-8"
|
||||
width="0.40091172"
|
||||
height="7.495573"
|
||||
x="131.54427"
|
||||
y="73.745697"
|
||||
rx="0.59598941"
|
||||
ry="0.8551048" />
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.131;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="112.03432"
|
||||
y="78.797226"
|
||||
id="text2052-6-7"><tspan
|
||||
id="tspan2050-4-1"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52778px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;stroke-width:0.131"
|
||||
x="112.03432"
|
||||
y="78.797226">1.5 V</tspan></text>
|
||||
<path
|
||||
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.264583px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#marker1226);marker-end:url(#TriangleStart)"
|
||||
d="m 38.260003,62.143086 94.864147,0.03514"
|
||||
id="path2369" />
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52777px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.431001;stroke-linecap:square;stroke-linejoin:miter;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="22.439083"
|
||||
y="35.02092"
|
||||
id="text2549"><tspan
|
||||
id="tspan2547"
|
||||
style="stroke-width:0.431"
|
||||
x="22.439083"
|
||||
y="35.02092"> </tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
transform="scale(0.26458333)"
|
||||
id="text2551"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;white-space:pre;shape-inside:url(#rect2553);fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.62898;stroke-linecap:square;stroke-linejoin:miter;stroke-dasharray:none;stroke-opacity:1"><tspan
|
||||
x="644.48633"
|
||||
y="363.66183"
|
||||
id="tspan22930"> </tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:3.52777px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:0.431001;stroke-linecap:square;stroke-linejoin:miter;stroke-dasharray:none;stroke-opacity:1"
|
||||
x="224.51692"
|
||||
y="98.199669"
|
||||
id="text2559"><tspan
|
||||
id="tspan2557"
|
||||
style="stroke-width:0.431"
|
||||
x="224.51692"
|
||||
y="98.199669"> </tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
transform="scale(0.26458333)"
|
||||
id="text2561"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:Inter;-inkscape-font-specification:'Inter, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-east-asian:normal;white-space:pre;shape-inside:url(#rect2563);fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.62898;stroke-linecap:square;stroke-linejoin:miter;stroke-dasharray:none;stroke-opacity:1"><tspan
|
||||
x="444.00977"
|
||||
y="404.05245"
|
||||
id="tspan22932"> </tspan></text>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 12 KiB |
BIN
_img/server-listening.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
_img/signed-conversion.png
Normal file
|
After Width: | Height: | Size: 8.2 KiB |
BIN
_img/signed-to-unsigned.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
_img/sql-full-outer-join.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
_img/sql-inner-join.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
_img/sql-left-outer-join.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
_img/sql-right-outer-join.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
1
_img/square.svg
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/sr_latch_diagram.png
Normal file
|
After Width: | Height: | Size: 5 KiB |
BIN
_img/sr_latch_logic_circuit.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
17
_img/stack1.svg
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="372px" height="272px" viewBox="0 0 372 272" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>Artboard</title>
|
||||
<g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<rect fill="#FFFFFF" x="0" y="0" width="372" height="272"></rect>
|
||||
<g id="Group" transform="translate(40.000000, 51.000000)">
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="0" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="0" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="132" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="88" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="44" y="1" width="24" height="169"></rect>
|
||||
<rect id="rect2493" stroke="#6DD400" stroke-width="1.00000924" fill-opacity="0.423111069" fill="#6DD400" fill-rule="nonzero" transform="translate(188.500000, 85.000000) rotate(89.753630) translate(-188.500000, -85.000000) " x="104" y="73" width="169" height="24"></rect>
|
||||
<path id="Line" d="M283.5,108.5 L292.5,113 L283.5,117.5 L283.5,113.5 L220.5,113.5 L220.5,112.5 L283.5,112.5 L283.5,108.5 Z" fill="#979797" fill-rule="nonzero"></path>
|
||||
<path id="Line" d="M229.5,55.5 L229.5,59.5 L292.5,59.5 L292.5,60.5 L229.5,60.5 L229.5,64.5 L220.5,60 L229.5,55.5 Z" fill="#979797" fill-rule="nonzero"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.6 KiB |
17
_img/stack2.svg
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="269px" height="367px" viewBox="0 0 269 367" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>Artboard</title>
|
||||
<g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<rect fill="#FFFFFF" x="0" y="0" width="269" height="367"></rect>
|
||||
<g id="Group" transform="translate(130.500000, 178.000000) rotate(-90.000000) translate(-130.500000, -178.000000) translate(-16.000000, 93.000000)">
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="0" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="0" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="132" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="88" y="1" width="24" height="169"></rect>
|
||||
<rect id="Rectangle" stroke="#979797" fill="#D8D8D8" x="44" y="1" width="24" height="169"></rect>
|
||||
<rect id="rect2493" stroke="#6DD400" stroke-width="1.00000924" fill-opacity="0.423111069" fill="#6DD400" fill-rule="nonzero" transform="translate(188.500000, 85.000000) rotate(89.753630) translate(-188.500000, -85.000000) " x="104" y="73" width="169" height="24"></rect>
|
||||
<path id="Line" d="M283.5,108.5 L292.5,113 L283.5,117.5 L283.5,113.5 L220.5,113.5 L220.5,112.5 L283.5,112.5 L283.5,108.5 Z" fill="#979797" fill-rule="nonzero"></path>
|
||||
<path id="Line" d="M229.5,55.5 L229.5,59.5 L292.5,59.5 L292.5,60.5 L229.5,60.5 L229.5,64.5 L220.5,60 L229.5,55.5 Z" fill="#979797" fill-rule="nonzero"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.7 KiB |
BIN
_img/step1.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
_img/step2.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
_img/step3.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
_img/step4.png
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
_img/switch-and-gate.png
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
_img/switch-or-gate.png
Normal file
|
After Width: | Height: | Size: 4.2 KiB |
4
_img/sync-thread.svg
Normal file
|
After Width: | Height: | Size: 5.8 KiB |
BIN
_img/systemd-global-files.png
Normal file
|
After Width: | Height: | Size: 118 KiB |
BIN
_img/systemd-local-files.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
_img/t-flip-flops.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
_img/theoremproof.png
Normal file
|
After Width: | Height: | Size: 30 KiB |
4
_img/transistor-diag.svg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
_img/transistor-off.png
Normal file
|
After Width: | Height: | Size: 7.4 KiB |
BIN
_img/transistor-on.png
Normal file
|
After Width: | Height: | Size: 7.3 KiB |
BIN
_img/unsigned-to-signed.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
4
_img/valence-shell.svg
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
_img/vertical-circuit.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
_img/virtual-memory-diagram.jpg
Normal file
|
After Width: | Height: | Size: 130 KiB |
BIN
_img/voltage-drop.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
_img/xor-addition-four.png
Normal file
|
After Width: | Height: | Size: 164 KiB |
BIN
_img/xor-gate-new.png
Normal file
|
After Width: | Height: | Size: 2.7 KiB |
BIN
_img/xor-hdl.png
Normal file
|
After Width: | Height: | Size: 94 KiB |
4
_img/yellow-encoding.svg
Normal file
|
After Width: | Height: | Size: 18 KiB |
10
_scripts/clean_image_directory.sh
Executable file
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
# If there are images in _img/ that are not being used in the workspace, delete them
|
||||
find /home/thomas/repos/computer_science/_img -type f | while read filename; do
|
||||
rg "${filename##*/}" ../ --type markdown >/dev/null 2>&1
|
||||
if [ "$?" -eq 1 ]; then
|
||||
echo "Deleted unused image: ${filename##*/}"
|
||||
rm $filename
|
||||
fi
|
||||
done
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
# This script returns a random topic for me to revise
|
||||
|
||||
# Choose source directories...
|
||||
DIRS_TO_PARSE="../Computer_Architecture ../Electronics_and_Hardware ../Operating_Systems ../Programming_Languages/Shell "
|
||||
DIRS_TO_PARSE="../Computer_Architecture ../Databases ../Electronics_and_Hardware ../Operating_Systems ../Programming_Languages/Shell ../Logic"
|
||||
|
||||
# Return array of all files belonging to source dirs...
|
||||
for ele in $DIRS_TO_PARSE; do
|
||||
|
|
@ -14,4 +14,4 @@ done
|
|||
RANDOM_FILE_INDEX=$(( $RANDOM % ${#FILE_MATCHES[@]} + 0 ))
|
||||
|
||||
# Return file matching that index...
|
||||
echo "Revise this topic: ${FILE_MATCHES[$RANDOM_FILE_INDEX]}"
|
||||
echo "Revise this topic: ${FILE_MATCHES[$RANDOM_FILE_INDEX]}"
|
||||
|
|
|
|||
8
_scripts/rename_img_links.sh
Executable file
|
|
@ -0,0 +1,8 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Replace all instances of `img` in Markdown image links with `_img` (to reflect new directory structure)
|
||||
|
||||
find /home/thomas/repos/computer_science/ -type f -name "*.md" | while
|
||||
read file; do
|
||||
sed -i 's/\/img\//\/_img\//g' $file
|
||||
done
|
||||