OpenLLM-France/wikimedia huggingface dataset:
# Programming Mac OS X with Cocoa for Beginners 2nd Edition/What Is Cocoa?

Next Page: Installing Apple's Developer Tools

### The Cocoa Framework

Cocoa is a modern, object-oriented framework. The Cocoa framework contains the class definitions for classes that are generally useful to produce a graphical user interface (GUI) for applications to be run under Mac OS X. Cocoa also provides an object-oriented interface to the operating system (OS). Cocoa is what Apple itself uses to develop Mac apps that come with Mac OS X such as Finder, Mail, iTunes, etc.

## Cocoa.h

To use Cocoa in your apps, you import "Cocoa.h". The following code is from the file, "Cocoa.h". Go ahead and read the comment and the code.
Generally, for all our projects in this wikibook, we will import Cocoa.h with the following code:
Note that #import does something similar to what #include does in C. #import includes the specified file, but unlike #include in C, you don't have to worry about a file including itself or a file being included twice. The compiler takes care of that and just does the right thing. So, in this wikibook, we'll always use #import instead of #include, but keep in mind that Objective-C can do anything that C can do so #include would still work in any C code that used #include. You can mix C and Objective-C any which way.
Now looking at what is imported, Cocoa.h imports the interface to the Foundation Framework, the interface to the AppKit Framework, and the interface to the CoreData FrameWork. We'll cover these frameworks a little more later in this wikibook, but for now, you can just think of the Cocoa Framework as being built on top of these three other frameworks.

## Other APIs

Cocoa is an example of an application programming interface or API. Apple used to support two older APIs for Mac OS X, "Classic" and "Carbon", but these were both for backward compatibility applications developed for "Classic Mac OS", that is for versions of Mac OS before Mac OS X. If you read about the Classic API or the Carbon API and framework, just know that these are both history.

## Where Are Frameworks Located?

You can find the Cocoa framework, and many other frameworks from Apple in the System folder.
Boot Volume → System → Library → Frameworks → Cocoa.framework
You can look around inside of the System Folder and get an idea of what's there, but don't change anything there.
Third-party frameworks should be installed in the following location:
Volume → Library → Frameworks
There is one more place where frameworks might be and that is in the Developer directory:
Boot Volume → Developer → Library → Framework
Next Page: Installing Apple's Developer Tools
# Programming for Palm OS/C
## generic useful bits

To sleep for period milliseconds (typically only to 10ms precision):
To find the resolution of the screen:

## examples

* Hello World
* Fields
* Menus
* Fonts
* Serial communications
* Using custom events
* Off-screen windows
* Databases
# Programming for Palm OS

* Programming the Palm using SuperWaba
* Programming the Palm using PRC-Tools
* Using the PalmOS Emulator, POSE
* Programming the Palm using C
* PilRC - the PILot Resource Compiler
* Small fonts
# Programming for Palm OS/C/Fields

Fields can be described for PilRC like this:
If text fields can receive focus but not accept any input, maybe the application is accidentally handling keyDown events so that they never make it to FrmDispatchEvent at the end of the chain of command in the event loop.
Although having a field edit a MemHandle (such as a database record) is easy (with FldSetTextHandle), changing the text in a text field is rather more involved:
# Structural Biochemistry/Contentious Terms
### Contentious Terms

These are scientific terms that currently seems to be in dispute. Whether the meaning or the usage of the terms is controversial, these terms should be used with careful considerations.

## Homology
### Definition

"The most fundamental relationship between two entities is homology; two molecules are said to be homogous if they have been derived from a common ancestor." Homology are further divided into two classes: Paralogs and Orthologs. Simply, homology means to have common evolutionary origin.

### Controversy

The term, “homology” has been famous for being misused in the scientific communities including the scientific journals and letters. The battle to amend this misused word has a long history. Recently however, the scientific community have once again brought into a discussion for the outbreak of this misusage. 1987 was the pinnacle of this dispute with many prominent journals and scientist argued that the term homology was being misused as a concept of quantity and not quality. The term is defined as having a common evolutionary origin, but it is widely misused to explain the comparison of proteins.
A research was done recently to confirm the accuracy of the term usage after the heated argument 20 years ago. Through reviewing hundreds of Pubmed documentations published in 2007, every article with the term homology was read and verified. However, only 57% of the 1966 reviewed had used the term homology correctly. There is still a misleading idea that homology can be used quantitatively. Also, interestingly, the error in the terminology was significantly lower in articles with language other than English. This study ultimately shows that the debate from 1987 still hasn't been fully acknowledged or applied.

## References

* ↑ Marabotti, Anna, and Angelo Facchiano. "When It Comes to Homology, Bad Habits Die Hard." Trends in Biochemical Sciences 34.3 (2008). Print.
* ↑ Berg, Jeremy Mark., John L. Tymoczko, and Lubert Stryer. Biochemistry. New York: W.H. Freeman, 2007. Print.
# Structural Biochemistry/Cloning Tips
## Cloning Tips

Some general considerations in the process of cloning can enhance the efficiency of cloning. The following are some tips:
1. The DNA insert/PCR product and vector digested by appropriate restriction enzymes should be purified directly, or from an agarose gel. This gets rid of the primers or the restriction fragments that are not of interest.
2. When performing ligation, the insert:vector ratio should be tested for the optimal conditions. Generally, a 1:1 or 3:1 ratio works well.
3. Screening for correct clones containing the vector with the DNA of interest inserted is very important. Common methods such as blue/white screening for B-Galactosidase activity and antibiotic screening are applied.
4. Calf Intestinal Alkaline Phosphatase is a hydrolase enzyme that is responsible for removing phosphate groups from nucleotides, proteins, etc. This enzyme can be used after digestion with restriction enzymes.
5.ATP is required for ligation.
6. Enzymes are used to synthesize, degrade, join or remove portions of nucleic acids in a controlled and generally defined manner.
7. Cloning Enzymes, are those important in nucleic acid cloning procedures. Some cloning enzymes are used as ligases, kinases and phosphatases, and RecA proteins.
8. When using vectors with antibiotic resistance characteristics for selection, after transforming the cells allowing the cells to grow in appropriate growth medium and growth temperatures for several hours increases growth efficiency as well as antibiotic-resistance. This will allow for cells that successfully took up the cloned vectors to be better collected once plated onto antibiotic treated growth plates. The preliminary growth period in solution will stimulate cell activity in producing the antibiotic resistance characteristics.
9. Cross contamination when working with multiple cloned DNA vectors with similar antibiotic selections is a concerning issue. Washing, ethanol-treating, and flaming instruments is an important anti-cross-contamination measure to be taken seriously.
10. Sterile technique.
# Real Analysis/Limit Points (Accumulation Points)
## Definition

Let $(X,d)$ be a metric space, and let $A\subset X$. We call $x\in X$ a limit point of $A$ if for any $\epsilon >0$ there exists some $y\neq x$ such that $y\in B(x,\epsilon )\cap A$.
We denote the set $lim(A)$ the set of all $x\in X$ such that $x$ is a limit point of $A$.
# Real Analysis/Interior, Closure, Boundary
## Interior, Boundary, and Exterior

Let $A\subset X$, and $(X,d)$ a metric space.
We denote $int(A)=\{x\in X:\exists \epsilon >0,B(x,\epsilon )\subset A\}$
We denote $ext(A)=\{x\in X:\exists \epsilon >0,B(x,\epsilon )\subset X\backslash A\}$
Finally we denote $br(A)=\{x\in X:\forall \epsilon >0,\exists y,z\in B(x,\epsilon ),{\text{ }}y\in A,z\in X\backslash A\}$

## Theorem

Let $A\subset X$, and $(X,d)$ be a metric space.
$int(A)\cup br(A)\cup ext(A)=X$
$int(A)$, $br(A)$, and $ext(A)$ are disjoint.

## Closure

We denote $cl(A)=A\cup Lim(A)$

## Theorem

$cl(A)=A\cup br(A)$
# Real Analysis/Introduction

| ←Foreword | Real Analysis Introduction | Contents→ |

## Introduction

The subject of real analysis is concerned with studying the behavior and properties of functions, sequences, and sets on the Real number line, which we denote $\mathbb {R}$. Concepts that we wish to examine through real analysis include properties like Limits, Continuity, Derivatives (rates of change), Integration (amount of change over time). Many of these ideas that, on a conceptual or practical level, are dealt with at lower levels of mathematics, including a regular First-Year Calculus course, and so to the uninitiated reader the subject of Real Analysis may seem rather shallow and trivial. However, the depth and complexity (and arguably the beauty) of Real Analysis is that we wish to generalize these properties away from the "nice" functions and sets dealt with in everyday mathematics, and rigorously prove these properties for all objects in the universe of the Real numbers. Thus real analysis can to some degree be viewed as a development of a rigorous, well-proven framework to support spatial and conceptual ideas that we frequently take for granted.
Real Analysis is a very straightforward subject, in that it is simply a nearly linear development of the ideas mentioned above. However, as the object of Real Analysis is to make things that we may already "know" more rigorous and definite, we cannot begin our development on unproven assumptions. Thus the approach we take to set this matter straight is to define the real numbers axiomatically. In layman's terms, we set down the properties which we think define the real numbers. We then prove from these properties and these properties only that the real numbers behave in the way which we have come to understand that regular objects in space behave. Lastly, we build a number system, and show it satisfies these properties.
From that foundation, we will develop first a set of results about the real number line, and then move on to results on a two-dimensional plane of real numbers, and then eventually we will generalize many of our results into n-dimensions.
Note: A table of the math symbols used below and their definitions is available here.
# Real Analysis/Inverse Function Theorem

| ←Differentiation in R$^n$ | Real Analysis Inverse Function Theorem | Dedekind's Construction→ |
# Real Analysis/Limits and Continuity Exercises

| ←Exponential Function | Real Analysis Exercises | Differentiation→ |
These are a list of problems for the Limits and Continuity section of the wikibook.

### Unsorted 1

* Although the wikibook asserts the truth of the following questions in this table, it is a good exercise to prove them. Thus, given the continuous functions $f$ and $g$, prove the following
** $\lim _{x\rightarrow c}{(f+g)(x)}=f(c)+g(c)$
** $\lim _{x\rightarrow c}{(f\cdot g)(x)}=f(c)\cdot g(c)$
** $\lim _{x\rightarrow c}{\left({\dfrac {f}{h}}\right)(x)}={\dfrac {f(c)}{h(c)}}$, given that $h$ is a function such that $h(c)\neq 0$
* Given a continuous function $f$ and $g$ over any interval $I$, prove that $f\circ \lim _{x\rightarrow a}g(x)=\lim _{x\rightarrow a}f\circ g(x)$ for all $x$ in the interval $I$
Question 2 is the proof that a limit can "transfer" between a composition of functions.

### Unsorted 2

These problems are on the difficult or, to put it differently if not mildly, non-standard type. Try to work the problems without the hints because most times, you might have a different approach or way of thinking about a problem. Use the hints only if you are truly stuck! Without further ado, here are the problems:
* Prove that the function, f(x) = 1/x is not uniformly continuous on the interval (0,∞).
* Prove that a convex function is continuous (Recall that a function $f:(a,b)\rightarrow \mathbb {R}$ is a convex function if for all $x,y\in (a,b)$ and all $s,t\in [0,1]$ with $s+t=1$, $f(sx+ty)\leq sf(x)+tf(y)$)
* Prove that every continuous function f which maps [0,1] into itself has at least one fixed point, that is $\exists p\in [0,1]$ such that $f(p)=p$
* Prove that the space of continuous functions on an interval has the cardinality of $\mathbb {R}$
* Let $f:[a,b]\rightarrow \mathbb {R}$ be a monotone function, i.e. $\forall x,y\in [a,b];x\leq y\Rightarrow f(x)\leq f(y)$. Prove that $f$ has countably many points of discontinuity.
* Let $f:(a,b)\rightarrow \mathbb {R}$ be a differentiable function, and suppose there is some positive constant $K$ such that $|f'(x)|\leq K$ for all $x\in (a,b)$.
** Prove that $f$ is Lipschitz continuous on $(a,b)$
** Show that every function which is Lipschitz continuous is also uniformly continuous (and therefore the function $f$ you are working with is uniformly continuous).
The Mean Value Theorem can be used here.
# Real Analysis/Limits and Continuity Exercises/Hints

| ←Exponential Function | Real Analysis Exercises | Differentiation→ |
These are a list of problems for the Limits and Continuity section of the wikibook.

### Unsorted 1

* Although the wikibook asserts the truth of the following questions in this table, it is a good exercise to prove them. Thus, given the continuous functions $f$ and $g$, prove the following
** $\lim _{x\rightarrow c}{(f+g)(x)}=f(c)+g(c)$
** $\lim _{x\rightarrow c}{(f\cdot g)(x)}=f(c)\cdot g(c)$
** $\lim _{x\rightarrow c}{\left({\dfrac {f}{h}}\right)(x)}={\dfrac {f(c)}{h(c)}}$, given that $h$ is a function such that $h(c)\neq 0$
* Given a continuous function $f$ and $g$ over any interval $I$, prove that $f\circ \lim _{x\rightarrow a}g(x)=\lim _{x\rightarrow a}f\circ g(x)$ for all $x$ in the interval $I$
Question 2 is the proof that a limit can "transfer" between a composition of functions.

### Unsorted 2

These problems are on the difficult or, to put it differently if not mildly, non-standard type. Try to work the problems without the hints because most times, you might have a different approach or way of thinking about a problem. Use the hints only if you are truly stuck! Without further ado, here are the problems:
* Prove that the function, f(x) = 1/x is not uniformly continuous on the interval (0,∞).
* Prove that a convex function is continuous (Recall that a function $f:(a,b)\rightarrow \mathbb {R}$ is a convex function if for all $x,y\in (a,b)$ and all $s,t\in [0,1]$ with $s+t=1$, $f(sx+ty)\leq sf(x)+tf(y)$)
* Prove that every continuous function f which maps [0,1] into itself has at least one fixed point, that is $\exists p\in [0,1]$ such that $f(p)=p$
* Prove that the space of continuous functions on an interval has the cardinality of $\mathbb {R}$
* Let $f:[a,b]\rightarrow \mathbb {R}$ be a monotone function, i.e. $\forall x,y\in [a,b];x\leq y\Rightarrow f(x)\leq f(y)$. Prove that $f$ has countably many points of discontinuity.
* Let $f:(a,b)\rightarrow \mathbb {R}$ be a differentiable function, and suppose there is some positive constant $K$ such that $|f'(x)|\leq K$ for all $x\in (a,b)$.
** Prove that $f$ is Lipschitz continuous on $(a,b)$
** Show that every function which is Lipschitz continuous is also uniformly continuous (and therefore the function $f$ you are working with is uniformly continuous).
The Mean Value Theorem can be used here.

### Hints/Answers

* No hint.
* You may want to prove first that the region above a convex function is convex (i.e. any straight line joining two points in the region, lies wholly in the region) and then using this fact argue by way of contradiction to show that convex functions are indeed continuous (i.e. no jump or removable discontinuity)
* Consider the function $h(x)=f(x)-x$. Using the Intermediate Value Property, show that $\exists p$ such that $h(p)=0$.
* First show that the set of all infinite sequences of real numbers has the same cardinality as $\mathbb {R}$ and next show that every continuous function is determined by its values on $\mathbb {Q}$
* No hint.
* (a) Use mean value theorem, once we cover it. (b) Let $\delta =\epsilon /K$.
# Real Analysis/Landau notation

| ←Dedekind's Construction | Real Analysis Landau notation | Bibliography→ |
The Landau notation is an amazing tool applicable in all of real analysis. The reason it is so convenient and widely used is because it underlines a key principle of real analysis, namely estimation. Loosely speaking, the Landau notation introduces two operators which can be called the "order of magnitude" operators, which essentially compare the magnitude of two given functions.

## The little-o

The little-o provides a function that is of lower order of magnitude than a given function, that is the function $o(g(x))$ is of a lower order than the function $g(x)$. Formally,

### Definition

Let $A\subseteq \mathbb {R}$ and let $c\in \mathbb {R}$
Let $f,g:A\to \mathbb {R}$
If $\lim _{x\to c}{\frac {f(x)}{g(x)}}=0$ then we say that
"As $x\to c$, $f(x)=o(g(x))$"

### Examples

* As $x\to \infty$, (and $m<n$) $x^{m}=o(x^{n})$
* As $x\to \infty$, (and $n\in \mathbb {N}$) $\ln x=o(x^{n})$
* As $x\to 0$, $\sin x=o(1)$

## The Big-O

The Big-O provides a function that is at most the same order as that of a given function, that is the function $O(g(x))$ is at most the same order as the function $g(x)$. Formally,

### Definition

Let $A\subseteq \mathbb {R}$ and let $c\in \mathbb {R}$
Let $f,g:A\to \mathbb {R}$
If there exists $M>0$ such that $\lim _{x\to c}\left|{\frac {f(x)}{g(x)}}\right|<M$ then we say that
"As $x\to c$, $f(x)=O(g(x))$"

### Examples

* As $x\to 0$, $\sin x=O(x)$
* As $x\to {\tfrac {\pi }{2}}$, $\sin x=O(1)$

## Applications

We will now consider few examples which demonstrate the power of this notation.

### Differentiability

Let $f:{\mathcal {U}}\subseteq \mathbb {R} \to \mathbb {R}$ and $x_{0}\in {\mathcal {U}}$.
Then $f$ is differentiable at $x_{0}$ if and only if
There exists a $\lambda \in \mathbb {R}$ such that as $x\to x_{0}$, $f(x)=f(x_{0})+\lambda (x-x_{0})+o\left(|x-x_{0}|\right)$.

### Mean Value Theorem

Let $f:[a,x]\to \mathbb {R}$ be differentiable on $[a,b]$. Then,
As $x\to a$, $f(x)=f(a)+O(x-a)$

### Taylor's Theorem

Let $f:[a,x]\to \mathbb {R}$ be n-times differentiable on $[a,b]$. Then,
As $x\to a$, $f(x)=f(a)+{\tfrac {(x-a)f'(a)}{1!}}+{\tfrac {(x-a)^{2}f''(a)}{2!}}+\ldots +{\tfrac {(x-a)^{n-1}f^{(n-1)}(a)}{(n-1)!}}+O\left((x-a)^{n}\right)$
# Suicide/Controversial methods

This section lists methods that have some serious issues, and which might or might not be considered a bad idea.
In alphabetical order, the following methods are currently featured:
* Antipsychotic drugs and SSRIs
* Hydrogen sulfide (H2S)
* Morphine and heroin
* Nicotine poison
* Exit (plastic) bag combined with sedatives
Note: Some of these methods are also featured in our article about bad methods.
# Suicide/Firearm
## Suicide by Firearm
### History

Tewodros II also known as Theodore II, Emperor of Ethiopia from 1855 to 1868. Due to encroachment of Muslim powers on his empire, he wrote the Christian monarch, Queen Victoria asking for British assistance in the region. After a series of mishaps that resulted in the hostilization of the British and general loss of his power in the region. The British attempted to capture him and in Easter Monday, April 13, 1868, he committed suicide as the British troops stormed the citadel of Magdala, his last reduct, that had been shelled, killing most of his supporters. Ironically he used a pistol that Queen Victoria had sent him as a gift.
"Excuse all the blood; sorry for firing the weapon indoors."
# Suicide/Diseases

It is possible to seek for w:cancer, w:Bugchasing, malignancy, w:liver disease, w:kidney disease, digestive disease, w:Parkinson's disease, participate in a Corona Party, w:cirrhosis.
See also: cardiotoxic, nephrotoxic, hepatotoxic for specific organs
# Suicide/Exsanguination
## Exsanguination

Exsanguination means colloquially, bleeding out, it is ultimately a fatal process of total Hypovolemia (blood loss).

### Slitting the wrists
#### In warm bath

Loss of blood leads to a rapid decrease of in body temperature, in an attempt to correct this effect, people have opted to perform it in a warm bath.
# Suicide/Film

Suicide Filmography consists of films that not only document suicide methods, but also related issues such as living wills, applicable laws, and so forth. It should not include a work simply because suicide is mentioned or acted out.

## The Sunset Limited

The Sunset Limited is a 2011 television film based on the play written by Cormac McCarthy. The film stars Tommy Lee Jones and Samuel L. Jackson.

### Plot

Two men with opposing beliefs confront each other in an apartment.
The film starts out with Black (Samuel L. Jackson) and White (Tommy Lee Jones) conversing about White's attempted suicide. White feels as though everything ends up in death, and that his life is minuscule in the throes of time.
From White's point of view, no matter how great someone or something is, all that is created eventually fades away. This is the opposite of what Black believes. He believes that there is a God and that we all must go through the troubles of life to get to paradise (Heaven). By his own account, his story is that of a man who has committed murder and was far away from God, but has now changed.
Black feels that he can persuade White from committing suicide. With Black stopping White right before he was about to kill himself, Black feels that this is destiny. In the end, Black is not able to persuade White from suicide; he lets him leave the apartment. When White leaves, Black is left pondering why God would put him in a position to save this man's life knowing that there is nothing that he can do to stop White from going through with the suicide.
# Suicide/Kamikaze

Almost all Army Kamikaze pilots were between 17 and 22 during the Okinawan campaign in 1945. 16 years was the age of the youngest kamikaze pilot to die in a suicide attack.
Photo to the right shows Corporal Yukio Araki holding a puppy with four other young men of the 72nd Shinbu Corps around him. An Asahi Shimbun cameraman took this photo on the day before the departure of the 72nd Shinbu Corps from Bansei Air Base. Yukio Araki died at the age of 17 in a suicide attack on American ships near Okinawa on May 27, 1945.
Almost all Army kamikaze pilots during the Okinawan campaign were between 17 and 22 (Muranaga 1989, 12). The guides at the Chiran Peace Museum emphasize that the youngest kamikaze pilot was only 17 years old.