OpenLLM-France/wikimedia huggingface dataset:
# 0.999.../Decimal multiplication by a small number

Multiplication of infinite decimals is usually challenging because it involves a great deal of carrying. Fortunately, as in the cases of addition and subtraction, we are interested in identities that involve no carrying at all.

## Assumptions

* Definition from series
* Term-by-term operations on series

## Theorem
### Statement

If there are two decimals A = a$_0$.a$_1$a$_2$a$_3$… and B = b$_0$.b$_1$b$_2$b$_3$… and an integer m such that for every index n, m × a$_n$ = b$_n$, then m × A = B.

### Proof

We apply the definition of an infinite decimal as a series:
    $B=\sum _{n=0}^{\infty }{\frac {b_{n}}{10^{n}}}=\sum _{n=0}^{\infty }m{\frac {a_{n}}{10^{n}}}.$
Next we apply the fact that a scalar multiple of a series can be computed term-by-term:
    $B=m\sum _{n=0}^{\infty }{\frac {a_{n}}{10^{n}}}=mA.$
# 0.999.../Proof by equality of Dedekind cuts
## Assumptions

* Construction of the real numbers from Dedekind cuts
* Definition from Dedekind cuts

## Proof

In the Dedekind cut approach, the real number 1 is the set of all rational numbers that are less than 1.
    $1=\left\{r|r\in {\textbf {Q}}\land r<{\tfrac {1}{1}}\right\}$
Meanwhile, the real number 0.999... is the set of rational numbers r such that r < 0, or r < 0.9, or r < 0.99, or r is less than some other number of the form
    $1-{\tfrac {1}{10^{n}}}$
In full
    $0.999...=\left\{r|r\in {\textbf {Q}}\land \exists n\in {\textbf {N}}:r<1-{\tfrac {1}{10^{n}}}\right\}$
The proof that these two Dedekind cuts are equal then relies on proving that these two set conditions are equivalent.
It can be shown that any number rational number smaller than 0.999... is also smaller than 1, since any non-negative n will give a value of 1-(1/10)^n which is smaller than 1.
All that remains is to prove that if a rational is smaller than 1, that it is always in 0.999... that:
    $r<1\rightarrow \exists n\in {\textbf {N}}:r<1-{\tfrac {1}{10^{n}}}$
for any r in Q
Substituting r for a natural fraction a/b
    ${\tfrac {a}{b}}<1\rightarrow \exists n\in {\textbf {N}}:{\tfrac {a}{b}}<1-{\tfrac {1}{10^{n}}}$
And letting n in the Quantification equal the denominator b gives
    ${\tfrac {a}{b}}<1-{\tfrac {1}{10^{b}}}$
cross-multiplication by 10^b gives
    $a\times 10^{b}<b\times 10^{b}-b$
and since we know that a is smaller than b, and 10 is positive, this will always be true.
Thus the two sets are equivalent, and 0.999... = 1.
# 0.999.../Proof by equivalence of Cauchy sequences
## Assumptions

* Construction of the real numbers from Cauchy sequences
* Definition from Cauchy sequences
* The limit of a geometric sequence

## Proof

In this formalism the task is to show that the sequence of rational numbers
    $\left(1-0,1-{9 \over 10},1-{99 \over 100},\dots \right)=\left(1,{1 \over 10},{1 \over 100},\dots \right)$
has the limit 0.
# 0.999.../Proof by limit manipulation
## Assumptions

* Definition from sequences
* Term-by-term operations on sequences
* The limit of a geometric sequence

## Proof

    $0.999\ldots =\lim _{n\to \infty }0.\underbrace {99\ldots 9} _{n}=\lim _{n\to \infty }\sum _{k=1}^{n}{\frac {9}{10^{k}}}=\lim _{n\to \infty }\left(1-{\frac {1}{10^{n}}}\right)=1-\lim _{n\to \infty }{\frac {1}{10^{n}}}=1.\,$
# 0.999.../Proof by nested intervals
## Assumptions

* Definition from nested intervals

## Proof

Applying the nested-intervals definition of the value of an infinite decimal, 0.999... is the unique real number that lies in all of the intervals [0, 1], [0.9, 1], [0.99, 1], and [0.99...9, 1] for every finite string of 9s. Since 1 is an element of each of these intervals, 0.999... = 1.
# .NET Development Foundation/Value types
## Value Types

Data types, such as integers and floating-point numbers that are copied when they are passed as arguments (that is, they are passed by value). In the .NET Framework, these are called value types. The runtime supports two kinds of value types: Built-in value types and User-defined value types.
Value types are stored as efficiently as primitive types, yet you can call methods on them. You can create instances of value types, pass them as parameters, store them as local variables, or store them in a field of another value type or object. Value types do not have the overhead associated with storing an instance of a class and they do not require constructors.
For each value type, the runtime supplies a corresponding boxed type, which is a class that has the same state and behavior as the value type. When you define a value type, you are defining both the boxed and the unboxed type.
Value types can have fields, properties, and events. They can also have methods.
* reference: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconvaluetypes.asp
# 0.999.../Proof by multiplication by 10
## Assumptions

* Decimal addition and subtraction
* Decimal multiplication by 10

## Proof

    ${\begin{aligned}x&=0.999\ldots \\10x&=9.999\ldots \\10x-x&=9.999\ldots -0.999\ldots \\9x&=9\\x&=1.000\ldots \\\end{aligned}}$
# 0.999.../Decimal addition and subtraction

Addition and subtraction of infinite decimals includes some easy problems and some hard problems. Even for finite decimals, identities without carrying are easy to verify (123456 + 654321 = 777777), whereas calculations with long runs of carrying are relatively hard to perform (3456 + 6549 = ???). A similar phenomenon occurs for infinite decimals.
Fortunately, we will not be encountering any addition problems with carrying, so we can concentrate on a few simple proofs of identities without carrying.

## Assumptions

* Definition from series
* Term-by-term operations on series

## Theorems
### Addition by digits is correct
#### Statement

If there are three decimals A = a$_0$.a$_1$a$_2$a$_3$…, B = b$_0$.b$_1$b$_2$b$_3$…, and C = c$_0$.c$_1$c$_2$c$_3$… such that for every index n, a$_n$ + b$_n$ = c$_n$, then A + B = C.

#### Proof

We apply the definition of an infinite decimal as a series:
    $C=\sum _{n=0}^{\infty }{\frac {c_{n}}{10^{n}}}=\sum _{n=0}^{\infty }{\frac {a_{n}+b_{n}}{10^{n}}}.$
Next we apply the fact that sums of series can be computed term-by-term:
    $C=\sum _{n=0}^{\infty }{\frac {a_{n}}{10^{n}}}+\sum _{n=0}^{\infty }{\frac {b_{n}}{10^{n}}}=A+B.$

### Subtraction by digits is correct
#### Statement

If there are three decimals A = a$_0$.a$_1$a$_2$a$_3$…, B = b$_0$.b$_1$b$_2$b$_3$…, and C = c$_0$.c$_1$c$_2$c$_3$… such that for every index n, a$_n$ − b$_n$ = c$_n$, then A − B = C.

#### Proof

The proof is almost identical to the previous proof:
    $C=\sum _{n=0}^{\infty }{\frac {c_{n}}{10^{n}}}=\sum _{n=0}^{\infty }{\frac {a_{n}-b_{n}}{10^{n}}}=\sum _{n=0}^{\infty }{\frac {a_{n}}{10^{n}}}-\sum _{n=0}^{\infty }{\frac {b_{n}}{10^{n}}}=A-B.$

## The road not taken

If A and B are arbitrary infinite decimals, then it can be tricky to compute the decimal expansion of A + B = C. The problem is caused by the phenomenon of carrying from one digit to the next. To compute any given digit of C, one might need to inspect many more digits of A and B to make sure that their sum doesn't carry into the target digit.
This book does not explore the addition of arbitrary decimals, mostly because it is difficult and unnecessary.
* ↑ ఝ
# Annotated Republic of China Laws/Copyright Act/Article 90-4

| ←Article 90-3 | Copyright Act Republic of China (Taiwan) Law Article 90-4 | Article 90-5→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-4

    An Internet service provider shall be entitled to the application of Article 90sexies to Article 90novies regarding the limitation on liability only if the service provider—
    1. by contract, electronic transmission, automatic detective system or other means, informs users of its copyright or plate right protection policy, and takes concrete action to implement it; and
    2. by contract, electronic transmission, automatic detective system or other means, informs users that in the event of repeat alleged infringements up to three times the service provider shall terminate the service in whole or in part; and
    3. publicly announces information regarding its contact window for receipt of notification documents.
    4. accommodate and implement the technical measure described in paragraph 3.
    A connection service provider that, after receiving notification by a copyright holder or plate rights holder of alleged infringement by a user, has forwarded the notification to that particular user by electronic mail is deemed to have met the requirement in the preceding paragraph, subparagraph 1.
    If a copyright holder or plate rights holder has provided technical measures which have been developed based on a broad consensus and are used to identify or protect copyrighted or plate-righted works, the Internet service provider shall accommodate and implement the measures if the technical measures has been ratified by the competent authority.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-4". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-6

| ←Article 90-5 | Copyright Act Republic of China (Taiwan) Law Article 90-6 | Article 90-7→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-6

    A caching service provider shall not be liable for damages for infringement of the copyright or plate rights of another by a user of its service if—
    1. the service provider does not make any modification to the cached information；
    2. when the person who made the original information available subsequently update, deletes, or blocks access to it, the cached information is done in the same way as a result of an automatic technical process; and
    3. the service provider responds expeditiously to remove, or disable access to, the allegedly infringing content or related information upon notification by a copyright holder or plate rights holder of the alleged infringement by the user of the service provider.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-6". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-10

| ←Article 90-9 | Copyright Act Republic of China (Taiwan) Law Article 90-10 | Article 90-11→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-10

    An Internet service provider shall not be liable for damages to the allegedly infringing user if the service provider—
    1. removes, or disables access to, the allegedly infringing content or related information in accordance with Articles 90septies to 90novies; or
    2. upon obtaining knowledge of suspected infringement by the user, acts in good faith belief to remove, or disable access to, the allegedly infringing content or related information.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-10". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-5

| ←Article 90-4 | Copyright Act Republic of China (Taiwan) Law Article 90-5 | Article 90-6→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-5

    A connection service provider shall not be liable for damages for infringement of the copyright or plate rights of another by a user of its service if—
    1. the transmission of the information was initiated by or at the request of the user; and
    2. the transmission, routing, provision of connections, or storage is carried out through an automatic technical process, without any selection of the material or modification of its content by the connection service provider.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-5". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-3

| ←Article 90-1 | Copyright Act Republic of China (Taiwan) Law Article 90-3 | Article 90-4→ |

## Newly adopted and promulgated on 2003-07-09
### Article 90-3

    Whoever violates any provision of Article 80bis, thereby causing damage to the copyright owner, shall be liable for damages. If there are multiple violators, they shall bear joint and several liability for damages.
    The provisions of Article 84, Article 88bis, Article 89bis, and Article 90bis shall apply mutatis mutandis to violations of Article 80bis.

## Promulgated amendment on 2004-09-01
### Article 90-3

    Whoever violates any provision of Article 80bis or Article 80ter, thereby causing damage to the copyright owner, shall be liable for damages. If there are multiple violators, they shall bear joint and several liability for damages.
    The provisions of Article 84, Article 88bis, Article 89bis, and Article 90bis shall apply mutatis mutandis to violations of Article 80bis or Article 80ter.

## Annotated by Wikibooks

* ↑ "Copyright Act". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2003-07-09. Retrieved 2016-11-23.
* ↑ "Copyright Act: Article 90-3". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-11

| ←Article 90-10 | Copyright Act Republic of China (Taiwan) Law Article 90-11 | Article 90-12→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-11

    A person who misrepresents an Internet service provider with a notification or counter notification out of intention or negligence shall be liable for damages for any injury incurred on the user, copyright holder, plate right holder or Internet Service Provider.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-11". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-7

| ←Article 90-6 | Copyright Act Republic of China (Taiwan) Law Article 90-7 | Article 90-8→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-7

    An information storage service provider shall not be liable for damages for infringement of the copyright or plate rights of another by a user of its service if the service provider—
    1. does not have knowledge of the allegedly infringing activity of the user;
    2. does not receive a financial benefit directly attributable to the infringing activity of the user; and
    3. responds expeditiously to remove, or disable access to, the allegedly infringing content or related information upon notification by a copyright holder or plate rights holder of the alleged infringement by the user of the service provider.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-7". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-8

| ←Article 90-7 | Copyright Act Republic of China (Taiwan) Law Article 90-8 | Article 90-9→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-8

    A search service provider shall not be liable for damages for infringement of the copyright or plate rights of another by a user of its service if the service provider—
    1. does not have knowledge that the searched or linked information may be infringing;
    2. does not receive a financial benefit directly attributable to the infringing activity of the user; and
    3. responds expeditiously to remove, or disable access to, the allegedly infringing content or related information upon notification by a copyright holder or plate rights holder of the alleged infringement by the user of the service provider.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-8". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# Annotated Republic of China Laws/Copyright Act/Article 90-12

| ←Article 90-11 | Copyright Act Republic of China (Taiwan) Law Article 90-12 | Article 91→ |

## Newly adopted and promulgated on 2009-05-13
### Article 90-12

    The information in connection with the public announcement of the contact window under Article 90quinquies, and the content of the notification and counter notification, required particulars, supplementation or correction, and other requisite matters under Articles 90septies through 90decies shall be prescribe by the competent authority.

## Annotated by Wikibooks

* ↑ "Copyright Act: Article 90-12". Laws & Regulations Database of The Republic of China. Ministry of Justice (Taiwan). 2014-01-22. Retrieved 2016-11-24.
# A-level Computing 2009/AQA/Problem Solving, Programming, Operating Systems, Databases and Networking/Problem Solving/Finite State Machines

Finite State Machines in unit 3 are exactly alike as you have learnt from unit 1. They are just slightly more complex with a few more states. To recap your memory, visit the unit 1 page here.
# A-level Computing 2009/AQA/Problem Solving, Programming, Operating Systems, Databases and Networking/Problem Solving/Backus-Naur Form (BNF)

Backus-Naur Form (also known as Backus Normal Form (BNF) or BNF for short) is a notation technique to express syntax of languages in computing. The expression is put in lists and can be used to see if syntax that is written is valid. Backus-Naur means "not in normal form compared to convention".

## Structure and Layout
### Symbols

BNF is represented using the following symbols:
The way that these symbols are laid out are as such:
In plain English, the expression above means "The parent expression is defined as the child expression 1 or the child expression 2". This means that to make up the parent expression, it must have a child expression and a child expression is made up of other things.

## Example

In this example, The BNF structure is breaking down the syntax to create
* Backus-Naur Form Breakdown of a Home Address
* <Address> ::= <House Number> <Street Name> <Town Name> <City Name> <Country> <Postcode> | <House Number> <Street Name> <City Name> <Country> <Post Code>
* <Postcode> ::= <Area Code> <Street Code>
* <Area Code> ::= <City Prefix> <digit> | <City Prefix> <digit> <digit>
* <Street Name> ::= <Name> <Street Type>
* <Flat Number> ::= <character> | <digit>
* <House number>::= <digit> | <digit> <House number>
* <Street Type> ::= <string>
* <City Prefix> ::= <string>
* <Street Code> ::= <string>
* <Town Name> ::= <string>
* <City Name> ::= <string>
* <Country> ::= <string>
* <Name>::= <string>
* An Image to show how the address BNF would be laid out.

## Practice Questions

* Using the BNF from the example above about addresses, state whether each input is a valid input.
* 15 Jubilee Lane Blackpool England FY98 5ER
* Answer:
* YES
* 15 Jubilee Lane Blackpool England FY423 5ER
* Answer:
* NO
* 32 Parkstone Road Syston England Leicester LE7 3ZY
* Answer:
* NO
# A-level Computing 2009/AQA/Problem Solving, Programming, Operating Systems, Databases and Networking/Problem Solving/Reverse Polish notation

Reverse Polish notation is an alternative way of writing mathematical expressions.

## Infix expressions

You will already be familiar with infix expressions where the operator is between two operands. E.g. 4 + 5 where the numbers 4 and 5 are the operands and + is the operator. The operators you will need to be familiar with are + (addition), - (subtraction), * (multiplication), / (division) and ↑(exponent).
When we write expressions in infix notation it can be confusing as to which operation should be performed first. For example, in the expression 4 + 5 * 6 we only know that the multiplication operation should be performed first because we have learnt the BIDMAS (or equivalent) rules. A computer does not automatically know this and would have to be programmed with the rules in order to carry out these operations correctly.

## Reverse Polish notation (RPN)

RPN is a way of getting round this and provides a way to write expressions without the need for brackets. This makes it much easier for a computer to evaluate the expressions. RPN places the operator after the operands it is to operate on. E.g. 54 + 20 would be written as 54 20 + in RPN.

## Examples

* Examples
* Q: Write the infix expression x + y in Reverse Polish notation
* A: x y +
* Q: Write the infix expression (x - y)*7 in RPN
* A: x y - 7 *
* Q: Write the RPN expression x 2 ↑ in infix form
* A: x$^2$
* Q: Write the RPN expression x y + x y - * in infix form
* A: (x + y)*(x - y)

## Practice Questions

* Exercise: Convert from infix to RPN
* Write the infix expression (x + y)/3 in RPN
* Answer:
* x y + 3 /
* Exercise: Convert from RPN to infix
* Write the RPN expression 6 x + 4 y + * as an infix expression
* Answer:
* (6 + x)*(4 + y)
# A-level Computing 2009/AQA/Problem Solving, Programming, Operating Systems, Databases and Networking/Problem Solving/Turing Machines

* From the Specification : Turing Machine and the Universal Machine.
* The abstract model of the Turing Machine and the Universal Machine..

## Recap

Before attempting to study Turing Machines you should ensure you are familiar with Finite State machines from the AS Computing specification and the few additional FSM concepts added to the A2 course.

## Definition

Turing machines provide a general or formal model of computation and can be used to determine whether or not a task is computable.

## Universal Turing Machine

A universal Turing machine (UTM) is a Turing machine that can execute other Turing machines by simulating the behaviour of any Turing machine. If a sequence is computable then a UTM will be able to execute it. A UTM behaves as an interpreter which is just what a PC does when it runs a Java applet or Flash script.
Principle of Universality: A universal machine is a machine capable of simulating any other machine.

## Examples of mechanical Turing Machines

* A Turing Machine "in the classic style" has an excellent video depicting the operation of a physical Turing machine

## Simulations

* Turing Kara has some excellent instructions to help you get to grips with the basic operations of a turing machine

## Example Questions

* Exercise: Turing Machines
* What is a Turing machine?
* Answer:
* A Finite State Machine that operates one or more tapes where at least one tape is infinitely long

## Revision

* Turing machines flash cards with test and other activities
# A-level Computing 2009/AQA/Problem Solving, Programming, Operating Systems, Databases and Networking/Programming Concepts/Abstract data types and data structures

In Computer Science an abstract data type (ADT) is a mathematical model for a certain data types or structures. This doesn't mean that the ADTs can't be programmed, but that we must first understand them mathematically before we can implement them. ADTs are generally complex things that you have functions and procedures to interface with.
Several of the ADTs we are going to look at will be 'dynamic', this means that they can change in size at run time, taking up more or less memory depending on the what is needed