text:
# Tag Info

12

this paper http://else.econ.ucl.ac.uk/papers/uploaded/243.pdf (Choi 2007) has a nice state of the art experiment that deals with rationality and expected utility is a special case of it. In general only 17% of consumers are compatible with rationality ergo the remaining part cannot be expected utility maximizers. Quah has a nice paper on the revealed ...

11

It is. Prior to continuity, which is a property of the preference relation, the preference relation $\succsim$ itself has been defined to be a binary relation that is characterized by transitivity, and, to begin with, by completeness. Then if $S_1\cup S_2 \neq [0,1]$, it means that there exist some values of $\alpha$ somewhere in $[0,1]$, call them $\... 11 Well there is no opinion poll among economists on specifically this problem, but what can be judged from reaction of economists the consensus is that the Ole Peters paper is misguided and irrelevant at best. I think the economists' consensus was already very well and succinctly summed up by Doctor, Wakker and Wang you cite (and is an example of this ... 9 No, not necessarily. Without the independence axiom (or something else to replace it) there is not much you can infer about preferences over (non-degenerate) lotteries from knowing preferences over outcomes only. For instance, let$p^L_n$be the probability of outcomes$n \in \{1, 2, 3\}$. Then preferences over lotteries$\succeq^*$represented by the ... 9 The name for the amount$56.25 is certainty equivalent. The expected utility for the individual from taking the bet is calculated as follows: $$E[U]=\frac12U(100+125)+\frac12U(100-100)=75$$ Suppose the individual can pay an amount of money $x$ so that she can avoid taking the bet (which leads to expected utility $75$). What's the maximum amount of money $x$ ...

9

Adding to the list of paradoxes, consider Machina's paradox. It is described in Mas-Colell, Whinston and Green's Microeconomic Theory. A person prefers a trip to Paris to watching a television program about Paris to nothing. Gamble 1: Win a trip to Paris 99% of the time, the television program 1% of the time. Gamble 2: Win a trip to Paris 99% of the time, ...

9

In order to understand this problem, I will work through the generic case. Say that a user had generalized quadratic (Bernoulli) utility, similar to your problem: $$u(x) = \beta x^2 + \gamma x$$ and suppose that there is a distribution for the outcome of $x$, denoted $F(x)$. Thus, utility over this distribution is equal to \begin{align} \int u(x) \text{... 8 Consider the version of the paradox from Wikipedia: A casino offers a game of chance for a single player in which a fair coin is tossed at each stage. The pot starts at 2 dollars and is doubled every time a head appears. The first time a tail appears, the game ends and the player wins whatever is in the pot. Thus the player wins 2 dollars if a tail ... 8 The primary literature concerned with this type of question (at least where classical results break down) is behavioral economics. There's a great general compilation of papers put together by the Russell Sage Foundation called the "Behavioral Economics Reading List" that includes, among other things, a General Introduction section with overview papers by ... 8 \begin{eqnarray*} \displaystyle U(L) & = &\sum_{s=1}^{S}\pi_s U(Y_s) = \sum_{s=1}^{S} \left(-\frac{1}{2}\pi_s(\alpha - Y_s)^2\right) = -\frac{1}{2}\sum_{s=1}^{S} \left(\pi_s(\alpha^2 + Y_s^2-2\alpha Y_s)\right) \\ &=& -\frac{1}{2}\left(\alpha^2\sum_{s=1}^{S} \pi_s + \sum_{s=1}^{S} \pi_sY_s^2-2\alpha \sum_{s=1}^{S} \pi_sY_s\right) = -\frac{1}{... 7 Here is an "expected utility maximization/ game theoretic" approach to the matter (with a dash of set-theoretic probability). In such a framework, the answers appear clear. PREMISES We are told in absolute honesty that, for x a strictly positive monetary amount, the following two tickets were placed in a box : \{A=x, B= 2x\} with assigned ... 7 Not all cdf’s have a density function, (for example if F is not differentiable). However, when they do have a density, the notation dF(z) is equivalent to f(z)dz. When performing integrals. However, even if the density does not exists, you can still write the expectation using the notation dF(z). The details of what it actually means and the subtle ... 6 I'm somewhat surprised that no one has linked to this paper: Backus, Routledge, and Zin (2004) Exotic Preferences for Macroeconomists (this version has some fixed typos, vs the NBER print). Their abstract is concise and extremely descriptive: We provide a user's guide to 'exotic' preferences: nonlinear time aggregators, departures from expected utility, ... 6 No, I would not say that this resolves the Machina paradox, because it is exactly the same as the Machina paradox: the paradox does indeed require from you to look at the three possible outcomes. The M-C/W/G book discuss only the B and C outcomes because it is there where the paradox focuses on whether a violation of the axiom of independence may happen. ... 6 This won't get at individual choice, but how about evolutionary approaches? Perhaps this isn't what you are looking for, but one way to model decisions is to wander from the rational paradigm entirely. All changes in behavior are driven by natural selection, and so an equilibrium is based on stability. In a symmetric normal form game, an evolutionarily ... 6 I think I've found an answer to my question, in this excerpt from Nobel laureate John C. Harsanyi's 1994 paper "Normative validity and meaning of von neumann-morgenstern utilities", presented at the Ninth International Congress of Logic, Methodology and Philosophy of Science. Harsanyi starts by proving the same lemma that Alecos proved in his answer, namely ... 6 Is there any (economic) rational for the first-order expansion of the RHS? And for its different neighborhood evaluation? As for your first question: This is a purely mathematical tactic in order to obtain an (approximate) equation for R. The expansion of first order on the RHS is motivated by this fact, i.e. to bring R alone "in the surface". The ... 6 Gains and losses presuppose a reference point, which is not a feature in standard expected utility theory. In this theory, the only argument in the utility over wealth is w, the absolute level of wealth. A common form of utility function is the constant relative risk aversion (CRRA) form: $$u(w)=\frac{w^{1-\rho}}{1-\rho},$$ ... 6 Junior econ professor here. I saw Ole Peter's work and I was intrigued, so I actually looked into it to see if there was something original/insightful for me to learn. I even run a little simulation of what he calls the "St. Petersburg Paradox", to make sure I understood what the guy is actually talking about. Just to be clear, I didn't spend days ... 6 I’am the guy who wrote the short note that was mentioned in the original question. You can reach the note here. https://osf.io/preprints/socarxiv/axkfg/ I got interested in Peter's paper because of my interest in evolutionary games, where the question of whether the equilibrium selection process is or is not ergodic plays a crucial role. I agree that most ... 5 The utility function is a representation of preferences, which are traditionally inferred from choices. Preferences come before utility. I would not call the connection between utility and preferences causality, just a mathematical relationship. Risk aversion (risk preference) is not connected to discounting, which measures time preference. It does not make ... 5 A first price standard and reverse auction are formally equivalent to each other, and the same method can be used to solve both: First Price Auction In a first price auction, n bidders choose their bid, b_i, as a function of their value v_i (distributed according to F. They seek to maximise their expected payoff:[v_i-b_i(v_i)]\Pr(b_i\geq\max_j ...

5

Following @Pburg answer and the subsequent discussion in the comments, I wanted to post an alternative Machina Paradox I thought of. Although it might be less pervasive in real life, it seems stronger to me in the sense that it does not rely on some kind of complementarity between the "different" components of each outcome. Consider the following alternative ...

5

This is perhaps a good opportunity to point out that the "certainty equivalence" concept means one thing in microeconomics/choice under uncertainty theory, while it means something different in macroeconomics. Microeconomics/choice under uncertainty The Certainty Equivalent of a lottery/gamble, is the amount of wealth which, if given with certainty, ...

5

Suppose that the vector $W=\left(w_1,w_2,\dots,w_n\right)$ represents wealth in $n$ possible states. In addition, assume the probability of each state occurring is represented by the vector $\pi=\left(\pi_1,\pi_2,\dots,\pi_n\right)$. We can express this as the simple gamble: $$g = \left(\pi_1\circ w_1,\pi_2\circ w_2, \dots, \pi_n\circ w_n\right)$$ The ...

5

As pointed in the comments this was done by Ragnar Frisch. At least Barten and Böhm. (1982) as well as Johansen (1969) attribute these axioms to one of these two publications: Frisch, Ragnar (1926). "Sur un problème d'économie pure [On a problem in pure economics]". Norsk Matematisk Forenings Skrifter, Oslo. 1 (16): 1–40 Frisch,(1926). "...

5

$$\left(\frac{2}{100} \cdot 1000 \oplus \frac{98}{100}\cdot 0\right)$$ is the lottery where you get $1000$ with probability $2/100$ and $0$ with probability $98/100$. The expression $$20 \sim \left(\frac{2}{100} \cdot 1000 \oplus \frac{98}{100}\cdot 0\right)$$ usually says that the decision maker is indifferent (in terms of preferences) between taking ...

4

I think you are correct that this solves the Machina Paradox but I am not sure I would associate your reformulation of the model with the idea of state-dependent utility. State-dependent utility is more than a mere extension or modification of the set of outcomes of the expected utility model. To make sense of state dependent utility, you need to have a ...

4

Picking up my comment under this answer. One striking issue relevant to decisions not captured by expected utility is the framing effect discussed by Tversky and Kahneman (1981) and others. In their experimental study, they let two different (but with the same characteristics) groups choose between two options. Both groups actually face the same choices, ...

4

Let me mention another quite well-known one: The calibration theorem by Rabin (2000) and Rabin and Thaler (2002). The idea is that over small stakes individuals must be essentially risk-averse, but in reality they are not. Only assuming a weakly concave and strictly increasing utility function, Rabin shows that risk aversion on small stakes implies ...

Only top voted, non community-wiki answers of a minimum length are eligible


text:
# Listings package for C#

I intend to use the package listings for including C# code in a LaTeX document. There are a lot of languages supported by this package, but C# lacks at all. Is there an extension for adding support for this language? or where should I add the C# (ver 4.0) keywords to see them highlighted? Note that the support for Java/C++ does not suffice, as there are some keywords not introduced in these languages: ref, out, var etc.

-

The listings package supports it (see the manual, page 12). Your document could look something like this:

\documentclass{scrartcl}
\usepackage{listings}
\usepackage{xcolor}

\lstdefinestyle{sharpc}{language=[Sharp]C, frame=lr, rulecolor=\color{blue!80!black}}

\begin{document}

\lstset{style=sharpc}
\begin{lstlisting}

As I don't know C#, I also don't know if the language definition of listings is sufficient for you, but it offers morekeywords key, so you can add the ones you are missing
@DmitriNesteruk You find it on page 12 of the manual. And it's [Sharp]C, which means use language C, the dialect Sharp. Without this listings would choose the standard dialect (ANSI in this case, therefore it is underlined in the manual). Although I don't use Lyx, I don't see any reason for it not to work. –  Tom Bombadil Apr 27 '12 at 16:24

format: plain


text:
# Download A blowing-up branch of solutions for a mean field equation by Lucia M. PDF

By Lucia M.

We give some thought to the equationIf Ω is of sophistication , we convey that this challenge has a non-trivial answer u λ for every λ ∊ (8π, λ*). the worth λ* depends upon the area and is bounded from under by way of 2 j zero 2 π, the place j zero is the 1st 0 of the Bessel functionality of the 1st form of order 0 (λ*≥ 2 j zero 2 π > eight π). in addition, the kinfolk of resolution u λ blows-up as λ → eight π.

Similar mathematics books

Love and Math: The Heart of Hidden Reality

What for those who needed to take an artwork classification within which you have been in simple terms taught the way to paint a fence? What when you have been by no means proven the work of van Gogh and Picasso, weren’t even advised they existed? lamentably, this is often how math is taught, and so for many folks it turns into the highbrow an identical of observing paint dry.

singularities of transition processes in dynamical systems: qualitative theory of critical delays

The paper supplies a scientific research of singularities of transition methods in dynamical structures. common dynamical platforms with dependence on parameter are studied. A method of leisure instances is built. every one leisure time will depend on 3 variables: preliminary stipulations, parameters $k$ of the approach and accuracy $\epsilon$ of the relief.

Additional resources for A blowing-up branch of solutions for a mean field equation

Sample text

Then ∠AP B = ∠AP Q + ∠BP Q = ∠P DA + ∠P CB. Define θ1 , . . , θ8 as in Figure 1. Then θ2 + θ3 + ∠AP B = θ2 + θ3 + θ5 + θ8 = 180◦ . (1) Similarly, ∠BP C = ∠P AB + ∠P DC and θ4 + θ5 + θ2 + θ7 = 180◦ . (2) Multiply the side-lengths of the triangles P AB, P BC, P CD, P AD by P C ·P D, P D·P A, P A · P B, P B · P C, respectively, to get the new quadrilateral A B C D as in Figure 2. 37 DA · P B · P C D A θ1 θ6 θ8 PB · PC · PD θ3 PA · PB · PC P CD · P A · P B AB · P C · P D PC · PD · PA PD · PA · PB θ2 θ7 θ4 θ5 BC · P D · P A C B Figure 2 (1) and (2) show that A D B C and A B C D .

In fact, the common value of AP 2 + P D2 , BP 2 + P E 2 , CP 2 + P F 2 is equal to 8R2 − s2 , where R is the circumradius of the triangle ABC and s = (BC + CA + AB)/2. We can prove this as follows: Observe that the circumradius of the triangle IA IB IC is equal to 2R since its orthic triangle is ABC. It follows that P D = P IA − DIA = 2R − rA , where rA is the radius of the excircle of the triangle ABC opposite to A. Putting rB and rC in a similar manner, we have P E = 2R − rB and P F = 2R − rC .

Set the coordinate system as in the following figure. 40 y D Γ4 Γ1 θ C x A B θ Γ2 Γ3 We may assume that Γ1 : x2 + y 2 + 2ax sin θ − 2ay cos θ = 0, Γ3 : x2 + y 2 − 2cx sin θ + 2cy cos θ = 0, Γ2 : x2 + y 2 + 2bx sin θ + 2by cos θ = 0, Γ4 : x2 + y 2 − 2dx sin θ − 2dy cos θ = 0. Simple computation shows that A B C D 4ab(a + b) sin θ cos2 θ 4ab(a − b) sin2 θ cos θ ,− 2 , − 2 a + b2 + 2ab cos 2θ a + b2 + 2ab cos 2θ 4bc(b − c) sin θ cos2 θ 4bc(b + c) sin2 θ cos θ ,− 2 , b2 + c2 − 2bc cos 2θ b + c2 − 2bc cos 2θ 4cd(c + d) sin θ cos2 θ 4cd(c − d) sin2 θ cos θ , , c2 + d2 + 2cd cos 2θ c2 + d2 + 2cd cos 2θ 4da(d − a) sin θ cos2 θ 4da(d + a) sin2 θ cos θ , .


text:
# yasa.spindles_detect¶

yasa.spindles_detect(data, sf=None, ch_names=None, hypno=None, include=1, 2, 3, freq_sp=12, 15, freq_broad=1, 30, duration=0.5, 2, min_distance=500, thresh={'corr': 0.65, 'rel_pow': 0.2, 'rms': 1.5}, multi_only=False, remove_outliers=False, verbose=False)[source]

Spindles detection.

Parameters
dataarray_like

Single or multi-channel data. Unit must be uV and shape (n_samples) or (n_chan, n_samples). Can also be a mne.io.BaseRaw, in which case data, sf, and ch_names will be automatically extracted, and data will also be automatically converted from Volts (MNE) to micro-Volts (YASA).

sffloat

Sampling frequency of the data in Hz. Can be omitted if data is a mne.io.BaseRaw.

Tip

If the detection is taking too long, make sure to downsample your data to 100 Hz (or 128 Hz). For more details, please refer to mne.filter.resample().

ch_nameslist of str

Channel names. Can be omitted if data is a mne.io.BaseRaw.

hypnoarray_like

Sleep stage (hypnogram). If the hypnogram is loaded, the detection will only be applied to the value defined in include (default = N1 + N2 + N3 sleep).

The hypnogram must have the same number of samples as data. To upsample your hypnogram, please refer to yasa.hypno_upsample_to_data().

Note

The default hypnogram format in YASA is a 1D integer vector where:

• -2 = Unscored

• -1 = Artefact / Movement

• 0 = Wake

• 1 = N1 sleep

• 2 = N2 sleep

• 3 = N3 sleep

• 4 = REM sleep

includetuple, list or int

Values in hypno that will be included in the mask. The default is (1, 2, 3), meaning that the detection is applied on N1, N2 and N3 sleep. This has no effect when hypno is None.

freq_sptuple or list

Spindles frequency range. Default is 12 to 15 Hz. Please note that YASA uses a FIR filter (implemented in MNE) with a 1.5Hz transition band, which means that for freq_sp = (12, 15 Hz), the -6 dB points are located at 11.25 and 15.75 Hz.

Broad band frequency range. Default is 1 to 30 Hz.

durationtuple or list

The minimum and maximum duration of the spindles. Default is 0.5 to 2 seconds.

min_distanceint

If two spindles are closer than min_distance (in ms), they are merged into a single spindles. Default is 500 ms.

threshdict

Detection thresholds:

• 'rel_pow': Relative power (= power ratio freq_sp / freq_broad).

• 'corr': Moving correlation between original signal and sigma-filtered signal.

• 'rms': Number of standard deviations above the mean of a moving root mean square of sigma-filtered signal.

You can disable one or more threshold by putting None instead:

thresh = {'rel_pow': None, 'corr': 0.65, 'rms': 1.5}
thresh = {'rel_pow': None, 'corr': None, 'rms': 3}

multi_onlyboolean

Define the behavior of the multi-channel detection. If True, only spindles that are present on at least two channels are kept. If False, no selection is applied and the output is just a concatenation of the single-channel detection dataframe. Default is False.

remove_outliersboolean

If True, YASA will automatically detect and remove outliers spindles using sklearn.ensemble.IsolationForest. The outliers detection is performed on all the spindles parameters with the exception of the Start, Peak, End, Stage, and SOPhase columns. YASA uses a random seed (42) to ensure reproducible results. Note that this step will only be applied if there are more than 50 detected spindles in the first place. Default to False.

verbosebool or str

Verbose level. Default (False) will only print warning and error messages. The logging levels are ‘debug’, ‘info’, ‘warning’, ‘error’, and ‘critical’. For most users the choice is between ‘info’ (or verbose=True) and warning (verbose=False).

New in version 0.2.0.

Returns
spyasa.SpindlesResults

To get the full detection dataframe, use:

>>> sp = spindles_detect(...)
>>> sp.summary()

This will give a pandas.DataFrame where each row is a detected spindle and each column is a parameter (= feature or property) of this spindle. To get the average spindles parameters per channel and sleep stage:

>>> sp.summary(grp_chan=True, grp_stage=True)

Notes

The parameters that are calculated for each spindle are:

• 'Start': Start time of the spindle, in seconds from the beginning of data.

• 'Peak': Time at the most prominent spindle peak (in seconds).

• 'End' : End time (in seconds).

• 'Duration': Duration (in seconds)

• 'Amplitude': Peak-to-peak amplitude of the (detrended) spindle in the raw data (in µV).

• 'RMS': Root-mean-square (in µV)

• 'AbsPower': Median absolute power (in log10 µV^2), calculated from the Hilbert-transform of the freq_sp filtered signal.

• 'RelPower': Median relative power of the freq_sp band in spindle calculated from a short-term fourier transform and expressed as a proportion of the total power in freq_broad.

• 'Frequency': Median instantaneous frequency of spindle (in Hz), derived from an Hilbert transform of the freq_sp filtered signal.

• 'Oscillations': Number of oscillations (= number of positive peaks in spindle.)

• 'Symmetry': Location of the most prominent peak of spindle, normalized from 0 (start) to 1 (end). Ideally this value should be close to 0.5, indicating that the most prominent peak is halfway through the spindle.

• 'Stage' : Sleep stage during which spindle occured, if hypno was provided.

All parameters are calculated from the broadband-filtered EEG (frequency range defined in freq_broad).

For better results, apply this detection only on artefact-free NREM sleep.

Warning

A critical bug was fixed in YASA 0.6.1, in which the number of detected spindles could vary drastically depending on the sampling frequency of the data. Please make sure to check any results obtained with this function prior to the 0.6.1 release.

References

The sleep spindles detection algorithm is based on:

Examples

For a walkthrough of the spindles detection, please refer to the following Jupyter notebooks:

https://github.com/raphaelvallat/yasa/blob/master/notebooks/01_spindles_detection.ipynb

https://github.com/raphaelvallat/yasa/blob/master/notebooks/02_spindles_detection_multi.ipynb

https://github.com/raphaelvallat/yasa/blob/master/notebooks/03_spindles_detection_NREM_only.ipynb

https://github.com/raphaelvallat/yasa/blob/master/notebooks/04_spindles_slow_fast.ipynb


text:
# Spivak's Calculus: Chapter 12, Problem 26

Suppose that $f(x) > 0$ for all $x$, and that $f$ is decreasing. Prove that there is a continuous decreasing function $g$ such that $0 < g(x) \le f(x)$ for all $x$.

To be quite honest, I have no idea how to approach this problem. (I also have no clue about the second part, but I imagine a hint at this solution will help me along for part b.)

I thought about setting $g(x) = f(x + k)$ for some $k > 0$, but I don't know how to get continuity. I should also note that this is in the "Inverse Functions" chapter, so that must play some sort of role here, but I'm not sure how really.

Any hint at how to think about the problem, specifically about the "continuous" part of it would be much appreciated. Thanks.

-
just in case yoyo's answer is not helpful, the way to think about this is as follows: worst case, $f$ has jump discontinuities which jump downwards. Now convince yourself that we can construct a piecewise linear continuous function beneath $f$. There are still some technical things: for example, how do we know that $f$ is piecewise continuous on intervals? How bad could it be? –  Glen Wheeler Apr 5 '11 at 5:56

define $g$ to be piecewise linear with $g(n)=f(n+1)$


text:
## Thursday, 25 June 2009

### Angles and Demons

Since writing down the standard model back in the summer of love the only progress in particle theory has been the discovery that neutrinos have masses. This fact makes the leptons similar in spirit to the quarks in the sense that transitions between different flavors are possible. In both cases the flavor eigenstates, that is the states to which the W bosons couple, are not the same as the mass eigenstates but linear combinations thereof. This fact opens the door to a fascinating endeavor of measuring the angles in the unitary matrix that relates the flavor and the mass eigenstates.

The angles in the quark sector have been measured from every angle. The final conclusion is that what they taught at school was right: the sum of the angles in a (unitarity) triangle is equal to 180 degrees. In the lepton sector, experiment is lagging behind: so far we know only two of the angles. The one known as the atmospheric or $\theta_{23}$ angle (responsible in particular for the transitions of atmospheric muon neutrinos into tau ones) is close to 45 degrees. The solar or $\theta_{12}$ angle (responsible for the vanishing of electron neutrinos produced in the Sun) turned out to be a bit smaller, about 30 degrees. For the last angle, at the moment we have only an upper bound from the CHOOZ reactor experiment: $\theta_{13} < 11$ degrees at 90 percent C.L.

Now what have demons to do with it? I recently came across a talk from the MINOS collaboration a few month ago in Fermilab. MINOS, when on leave from Hades, studies the muon neutrino beam sent over the distance of 735 kilometers from Fermilab to a far detector located in the Soudan mine in Minnesota. One reason to bother (just imagine what it takes to dig such a long tunnel to send the neutrino beam over several states) is a precise measurement of the angle $\theta_{23}$ which controls the fraction of muon neutrinos that disappear on the way. But there may be more fun than that. Most of the muon neutrinos that vanish turn into tau neutrinos who escape detection. However, if $\theta_{13}$ is non-zero then a small fraction of the muon neutrinos should turn into electron neutrinos, and those receive a warm welcome in Soudan. Thus, MINOS is one in a long queue of experiments trying to pinpoint $\theta_{13}$.

In February this year MÌNOS announced their first results concerning the electron neutrino appearance. They see 35 electron event, roughly 1.5 sigma above the expected background of $27$ events. Not too significant, but already tantalizing. Moreover, if the MINOS data are combined with all available neutrino data the hint for a non-zero $\theta_{13}$ is strengthened to 2 sigma. The central value for $\theta_{13}$ inferred from the overall fit is 8 degrees (plus minus 4) - just below the CHOOZ limit.

If the current hints converge to a full-fledged measurement of $\theta_{13}$ in the 5-10 degrees ballpark then there are some far reaching consequences. First of all, measuring the $\theta_{13}$ angle paves the way to measuring yet another angle (isn't particle physics exciting?), more precisely the CP violating phase in the neutrino mixing matrix. Secondly, it would appear that the mixing angles in the lepton sector are pretty random numbers with no structure, in stark contrast to the quark sector where the CKM matrix displays a very hierarchical structure. In other words, neutrinos would prove to be anarchic. That would mean that anarchy is at rule, at least in the lepton sector, for the first time since Barcelona'36.

## Friday, 12 June 2009

### Boston Tea Party

Last weekend I made a trip to Boston and had a privilege to see bits of the SUSY'09 conference. Backreaction and Quantum Diaries have already run their stories but in my opinion they did not fully capture the grandeur of the event. 9 days in a row, including foreplay. Over 400 participants, not counting squatters. 42 plenary speakers, most of whom witnessed the glorious days when supersymmetry was conceived. Seven parallel parallel sessions to cover every aspect of supersymmetry that has not yet been covered thoroughly enough. Royal coffee break menu fully adequate to the royal conference fee. And so on and on since 16 years and into the future.

Meanwhile, there is no single hint from experiment that supersymmetry is realized in nature... but that should not upset anyone. As my fellow blogger skillfully put it, supersymmetry is the "shining beacon", the "raison d’etre" and for this reason "the conundrum is how it will be discovered, not if". That's why every year we come together to enjoy old familiar faces and old familiar talks. The point is, while waiting for the inevitable, to maintain that kind of spirit that David Lodge praised in his books.

On the picture below, the photographer about to make a photograph of the SUSY'09 participants.

## Tuesday, 9 June 2009

### Life After FERMI

I mean, after FERMI's first electron data that shed new light on the currently hottest topic in astroparticle physics - the origin of the cosmic-ray positron excess measured by PAMELA. The PAMELA anomaly trumpeted last summer, combined with the data from ATIC (who claims a spectacular excess of electrons at few hundred GeV), prompted zillions of publications that speculate of its dark matter origin. A few weeks ago FERMI revealed their first measurement of the electron+positron cosmic ray spectrum up to 1 TeV. Here is my summary of what that implies for the models of dark matter.

Let's begin with a handful of facts:
• Thanks to FERMI and HESS we now have a pretty accurate picture of the cosmic-ray electron+positron spectrum. Up to 1 TeV, the spectrum is well approximated by power law, $\sim E^{-3}$, while above TeV it becomes softer (larger power).
• ATIC screwed: there is no clear feature in the electron spectrum. In principle, one should describe the present situation as "two experiments giving inconsistent results", given that ATIC's brand new data continue displaying a distinct bump with even smaller errorbars. But, somehow, the public opinion prefers a fancy high-tech satellite over a dirty leaking balloon somewhere in the cold Antarctica. More seriously, FERMI simply beats ATIC with a hundred times more statistics.
• The electron spectrum near TeV is above the background predicted by conventional cosmic-ray propagation models (which prefer a larger power, $\sim E^{-3.3}$) in which the electrons are produced by scattering of cosmic ray protons. But that alone is hardly an anomaly, and the spectrum can be easily fitted by cranking up the propagation model.
• However, combining FERMI with the PAMELA positron data strongly indicates the presence of a new primary component of electrons/positrons (as opposed to the secondary production by protons) .
• The primary component could be injected by nearby pulsars, or by another so far unidentified astrophysical process, or by dark matter annihilating or decaying in our galaxy. We have to wait for the jury to reach the verdict.
• But, light (less than 1 TeV) dark matter particle as a source of the PAMELA and FERMI excess is now strongly disfavored. The reason is that a light particle would lead to sharp spectral features at energies comparable to its mass, whereas FERMI sees none of that. If dark matter is the cause of the excess, it has to be relatively heavy, 1 TeV or more.

In fact, the new FERMI data did not really lead to a slaughter of the dark matter models or its authors. New papers keep appearing in which the excess is fitted with axions, neutralinos, winos, KK particles, F-theory or three little pigs. But Occam is waving his razor menacingly, and we are reaching the point where boring astrophysics becomes the simplest explanation of all available data. The dark matter models, although still viable, have to be intelligently designed to yield observable signals in the positron and electron channels, but none in antiprotons, gamma rays or neutrinos. Incidentally, the electron channel is the one where the astrophysical background is most difficult to control...

The cool thing is that by the end of this summer we may further disfavor dark matter or return it to grace. The new crucial piece of information will be FERMI's measurement of the diffuse gamma ray spectrum that will extend its previous measurement to larger energies. If the electrons and positrons observed by PAMELA and FERMI originate from dark matter it means that they are produced all over the galaxy. Once produced, the electrons lose their energy by scattering on starlight and on the CMB or by synchrotron radiation in the galactic magnetic fields, which leads to a diffuse flux of photons at energies of a few hundred GeV. Given the number of electrons needed to explain PAMELA and FERMI, the diffuse signal should be detectable by 1-year FERMI data. The important thing is that boring astrophysics cannot easily fake that signal. On the other hand, the absence of features in diffuse gamma would be a huge setback for the dark matter interpretation. The experimental data are expected on August 12, so just a little patience please...

For more details and plots see the slides of Alessandro Strumia's talk at Planck'09; check also for the connection between dark matter and dialectic materialism.


text:
# zbMATH — the first resource for mathematics

Asymptotic links. (Enlacements asymptotiques.) (French) Zbl 0913.58003
The paper deals with four different invariants for certain diffeomorphisms and vector fields. The first two invariants are for measure preserving diffeomorphisms of $$D^2$$, which are the identity near the boundary. They were introduced by E. Calabi [Probl. Analysis Sympos. in Honor of S. Bochner, Princeton Univ. 1969, 1-26 (1970; Zbl 0209.25801)], resp. by D. Ruelle [Ann. Inst. Henri Poincaré, Phys. Théor. 42, 109-115 (1985; Zbl 0556.58026)]. The second two invariants are for certain vector fields on three-dimensional manifolds. They were first defined by V. I. Arnol’d [Sel. Math. Sov. 5, 327-345 (1986); translation from Mater. Vses. Skh. Differ. Uravn. Beskonechnym Chislom Nezavisimykh Din. Syst. Beskonechnym Chislom Stepenej Svobodny, Dilizhane, May-June 1973, Akad. Arm. SSR, Erevan, 229-256 (1974; Zbl 0623.57016)] resp. by D. Ruelle [loc. cit.].
The authors study properties of these invariants, and show relations between them. They prove that the invariants of Calabi and those of Ruelle are topological invariants.

##### MSC:
 58C25 Differentiable maps on manifolds 37C10 Dynamics induced by flows and semiflows 28D05 Measure-preserving transformations
Full Text:


text:
# Holt Winter’s, Series Decomposition and Wavelet Benchmarks

How much accuracy shall you expect from time-series forecasting algorithms? As you already know a Mean Absolute Percent Error of 10% can be considered very good but normally this error measure stands in the range 20% to 30%.

To show you how good a forecast produced with IPredict be, we prepared a simple model:

where $\omega$ is a random number with uniform distribution.

this model is periodic and with a linear trend, a situation that is very typical for a lot of businesses and also for the financial markets. On this simple model we calculated a forecast using the three Holt Winter’s methods, the two Series Decomposition methods and IPredict’s unique Wavelet Forecast method. Finally we computed the Mean Absolute Percent Error all the predictions.

The Holt Winter’s predictions look like this:

The Series Decomposition predictions look like this:

The Wavelet prediction looks like this:

As you can see from the two pictures the random noise makes it very difficult to identify correctly the model.

Here you can find also the Mean Absolute Percent Error of this benchmark:

 Holt Winter’s Multiple 10.20% Holt Winter’s Multiplicative 16.60% Holt Winter’s Additive 14.36% Additive Decomposition 14.37% Multiplicative Decomposition 20.08% Wavelet 10.42%

As you can see the best algorithms have a Mean Absolute Percent Error around 10%, a very good result. Less surprisingly the multiplicative models are worse than the additive ones (excluding Wavelet that is neither additive nor multiplicative) since the time series we used is an additive one. The proprietary algorithms are the ones that score better and between them and the best ‘classical’ algorithms there is an outstanding 40% difference.

 Forecasting Methods Holt Winter’s, Series Decomposition and Wavelet Benchmarks Time Series Forecasting Use of the Moving Average in Time-series Forecasting Forecasting Concepts Denoising Techniques Error Statistics Computational Performance Fast Fourier Transform Moving Averages Kernel Smoothing Active Moving Average Savitsky-Golay Smoothing Fractal Projection Downloading Financial Data from Yahoo Multiple Regression Digital Signal Processing Principal Component Analysis Curve Analysis Options Pricing with Black-Scholes Markowitz Optimal Portfolio Time-series preprocessing


text:
# Guido was right, there should be no lambda in Python.

4th March 2018

Python has support for lambda functions, Haskell is built upon lambda calculus. The two are not the same and this is the reason why lambda should have been removed in Python3. This post examines the differences, reviews the use in Python, and offers a more pythonic, honest syntax.

LAMBDA IN Python has been derived from functional programming, however there is nothing that lambda can do that can’t be done with the usual def foo(*args, **kwargs): ... syntax. At the advent of Python3 Guido proposed to remove lambda from Python, but relented and allowed it to stay.

Haskell is a canonical functional programming language, it relies heavily on lambda calculus, although it does have a lambda syntax : (\x -> x + 1), this is equivalent to (+1). How can this be? Every function is a lambda function.

We’ll take a quick look at lambda calculus using Python. Then I’ll claim we don’t use lambda calculus in Python, despite all the great advantages it gives Haskell programmers. Finally we’ll look at how we use lambda in Python and discuss why it should have been changed going into Python3.

I know this will be an aggravating read for many pythonistas, but please try to remain calm and keep an open mind. Don’t comment without reading first!

## Lambda Calculus

(\lambda x. \lambda y. x + y)(2)(3) = (\lambda y. 2 + y)(3) = 2 + 3

LAMBDA CALCULUS (aka. $\lambda$-calculus) is Turing Complete, meaning we can make programs from just lambda. In lambda calculus, the function lambda x: x would be written as $\lambda x.x$.

In Python we have some syntactic sugar, lambda x, y: x + y is actually accepting a tuple of arguments. In the examples I’m being strict and passing arguments individually as per the maths syntax $\lambda x. \lambda y. x + y$.

To resolve a lambda expression, we substitute in arguments. I’ve shown it in Python syntax so you can run the functions.

(lambda x: (lambda y: x + y))(2)(3)
(lambda y: 2 + y)(3)
2 + 3

You can use this syntax to create all manner of programs because you can substitute functions as well as values.

Here we have a function that accepts another function and a single argument. It is given a function that adds 1 to a single argument, and then it is given 4 as an argument.

(lambda f: (lambda a: f(a)))(lambda x: x + 1)(4)
(lambda a: (lambda x: x + 1)(a))(4)
(lambda a: a + 1)(4)
4 + 1

As a glimpse into what can be done with lambda calculus, here’s an ‘if-then-else’ branching function where we’ve broken the rules of lambda calculus by naming the functions to aid readability.

For more about lambda calculus in Python syntax, I’d recommend a talk from EuroPython 2017 by Anjana Vakil, called “Mary had a little lambda”.

TRUE = lambda x: lambda y: x
FALSE = lambda x: lambda y: y
IFELSE = lambda p: lambda a: lambda b: p(a)(b)

print(IFELSE(TRUE)(1)(2))
# Output: 1
print(IFELSE(FALSE)(1)(2))
# Output: 2

## Lambda Calculus: +

LAMBDA, WHEN used in a programming language to define functions gives you currying and thus partial application built in. If you’ve read Python Partial: Code Your Intention, you’ll know I’m a big fan of this.

Lambda calculus can provide features we find in Python, which we know and love, such as first-class functions and higher-order functions, because we can pass functions around.

It can also be used for lazy evaluation: the substitutions can be undertaken without executing the functions. This also allows a compiler, such as the Haskell compiler, to reduce the computation required when composing functions together.

## No Lambda in Python

I LOVE the benefits of lambda calculus, I love Python. The two do not mix. In Python our functions are not curried or evaluated using lambda calculus, we know this because functions need all their arguments when called. Consider the difference between these two addition functions.

l_add needs the arguments passed one at a time. We never see this syntax with multiple parenthesis in Python. It works and it has many benefits built in, but it would be a paradigm shift to expect pythonistas to start writing their programs this way, it’s just not Pythonic.

def add(a, b):
return a + b

l_add = lambda a: lambda b : a + b

Compare this to Haskell, which is built for using lambda calculus. Haskell’s syntax is less verbose, easier to write, there’s no annoying parenthesis and the benefits of currying are built in.

-- declaring the function
l_add a b = a + b
-- calling the function

-- partial application
-- calling the partial function
incr 2

## But That’s Not How We Use Lambda In Python

I KNOW! In Python we call our functions with all their arguments at the same time, even lambda x, y: x + y is expecting both arguments together. Typical use cases in Python are for very short inline functions, usually when being passed to a higher-order function.

During the debate about removing lambda from Python3, Kay Schluehr proposed an inline syntax, it should be possible to make use of the use of _ with inline to create anonymous functions that fulfil our requirement, encode our intention, and stay pythonic.

In Python lambda is a short, inline, anonymous function. But, an anonymous function is not a calculus.

# Typical use cases
map(lambda x: x + 1, range(5))
max(my_tuples, key=lambda t: t[1])

# More pythonic? Closer to the user intent?
map(inline _(x): x + 1, range(5))
max(my_tuples, key=inline _(t): t[1])

PYTHON IS capable of lambda calculus, but it is not considered pythonic to use it. If a library like datetime were to use lambda calculus there would be outcry from the community, no-one would want to call functions with a set of parenthesis for each argument.

But the normal way to call a function could be made syntactic sugar for the lambda calculus way. Just like in Haskell, Python would not need a lambda syntax. This imaginary case reveals how the lambda syntax is not being used appropriately. If def foo(x): ... were this syntactic sugar, how would we declare our inline anonymous functions?

# Normal python call:
datetime.date(2018, 3, 4)

# Lambda calculus call:
datetime.date(2018)(3)(4)

If you like that syntactic sugar, check out toolz curry. Wouldn’t it be nice if we didn’t have to use the decorator?

## Conclusion

IF EVERY function were a lambda function with some syntactic sugar, we’d still need a way to declare inline anonymous functions. This brings us back to needing something like inline _(): .... This also brings back my argument for all the functional programming techniques I have covered in this blog so far: Code the authors intention.

In Python, we do not use lambda with the intention of using lambda calculus. Our syntax needs to encode our intention in the places we have used it, and where we will use it. These use cases are inline, anonymous functions.

Love it? Hate it? What do you think? Let me know in the comments and happy coding.

Paul

### All Tags

LIFE IS better when we share.


text:
Dmpfold error "No such file or directory: 'best_qdope.pdb'" when running "run_dmpfold.sh"?

I am running DMPfold, "seq2maps.sh" ran successfully, but whrn running "run_dmpfold.sh", it gives me this error:

   Note: The following floating-point exceptions are signalling: IEEE_UNDERFLOW_FLAG IEEE_DENORMAL
Note: The following floating-point exceptions are signalling: IEEE_UNDERFLOW_FLAG IEEE_DENORMAL
seed =  30603
Note: The following floating-point exceptions are signalling: IEEE_UNDERFLOW_FLAG IEEE_DENORMAL
/media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/run_dmpfold.sh: line 177: c600m2-tail-before-lysin-sequence_[1-9]*.pdb: No such file or directory
No atoms read from PDB file
0 models read from PDB file
Outliers:

Traceback (most recent call last):
File "/media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/nn/dmp-softmax/pytorch_dmp_iterdistpred_cb.py", line 82, in <module>
main()
File "/media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/nn/dmp-softmax/pytorch_dmp_iterdistpred_cb.py", line 55, in main
with open(sys.argv[3], 'r') as refpdbfile:
FileNotFoundError: [Errno 2] No such file or directory: 'best_qdope.pdb'
Traceback (most recent call last):
File "/media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/nn/dmp-hb/pytorch_iterdmp_hbpred.py", line 75, in <module>
main()
File "/media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/nn/dmp-hb/pytorch_iterdmp_hbpred.py", line 53, in main
with open(sys.argv[3], 'r') as refpdbfile:
FileNotFoundError: [Errno 2] No such file or directory: 'best_qdope.pdb'
No valid current contacts.

Can you please let me know how this can be solved?

the comand line is:

run_dmpfold.sh sequence.fasta sequence.21c sequence.map ./dmpfold-lysin 10 500 &> dmpfold-log.log

Thanks!

• Please edit your question and show us line 177 of /media/Deepak/NPRP10/softwares/dmpfold/DMPfold-master/run_dmpfold.sh. As you can see in the error message, the script is looking for files named c600m2-tail-before-lysin-sequence_[1-9]*.pdb and it is doing so on line 177. What is this script? Where did you get it? Could it have hard-coded input files? All of your errors are about missing files. Sep 11 '19 at 15:41

The target variable, which is set to the first part of the sequence file name, should be sequence according to your given command line. However the error message thinks it is c600m2-tail-before-lysin-sequence. Have you edited the command line for simplicity?

I'm a little worried about the floating point errors, which are almost certainly from CNS as there are 3 CNS calls and the error shows up 3 times. I would test your CNS installation to see if everything is okay - maybe try some examples from their website. An error there would explain why no output is generated.

You can ignore any errors below line 5 of the above program output for now, as they are follow-on errors. In particular the question title isn't the 'real' error here, the real error is that no PDB files are generated on line 160.

By the way, I wouldn't use 10 500 as parameters for iteration number and number of models. It will take ages to run. I'd just use the defaults (omit the arguments), which we find gives good results.

Finally, I'll point out that the DMPfold repository has an issue tracker where you can raise any future issues. Though we may as well finish debugging this one here since we've started!

• Ok, I cant ask more questions on this thread as stated by the person below. So, I will be asking next questions in another thread with title "DMPfold: is it suitable to get 5000 models to compare with rosetta". Sep 12 '19 at 10:17

thanks! I figured out the solution, it was the cns. I downloaded the binaries instead of compiling from source and it works!

• Thanks for posting your solution! But please ask a new question for the follow-up question. This site is not a forum, so we don't do discussions, only questions and answers. You might want to take the tour or visit our help center to understand more. In the mean time, I have removed the question from this answer, but please feel free to ask it as a new question. Sep 12 '19 at 10:12


text:
# EXERCISE 24.2

QUESTION 1

Find the co-ordinates of the center and radius of each of the following circles:

(i)

Sol :

The given equation can be rewritten as

Center

= 7

(ii)

Sol :

The given equation can be rewritten as

Center

(iii)

Sol :

The given equation can be rewritten as

Center

= 3

(iv)

Sol :

The given equation can be rewritten as

Center

QUESTION 2

Find the equation of the circle passing through the points:

(i) and

Sol :

Let the required circle be

It passes through and

Substituting the coordinates of these points in equation (1) :

Simplifying (2),(3) and (4)

Equation of the required circle:

(ii) and

Sol :

Let the required circle be

It passes through and

Substituting the coordinates of these points in equation (1) :

Simplifying (2),(3) and (4)

The equation of the required circle is

(iii) and

Sol :

Let the required circle be (1)

It passes through and

Substituting the coordinates of these points in equation (1):

(3)

Simplifying and

The equation of the required circle is

(iv) and

Sol :

Let the required circle be

It passes through and

Substituting the coordinates of these points in equation (1):

Simplifying (2),(3) and (4)

The equation of the required circle is

QUESTION 3

Find the equation of the circle which passes through and has its center on the line

Sol

Let the required equation of the circle be (1)

It is given that the circle passes through

The center lies on the line

Solving (2),(3) and g=\frac{3}{2}f=6c=2x^{2}+y^{2}+3 x+12 y+2=0

*** QuickLaTeX cannot compile formula:

QUESTION 4
Find the equation of the circle which passes through the points

*** Error message:
Missing $inserted.  (3,7),(5,5)x-4 y=1x^{2}+y^{2}+2 g x+2 f y+c=0 . \ldots(1)(3,7),(5,5)58+6 g+14 f+c=0 \ldots(2)50+10 g+10 f+c=0 \quad \ldots(3) *** QuickLaTeX cannot compile formula: The center *** Error message: Missing$ inserted.

(-g,-f)x-4 y=1-g+4 f-1=0 \quad \ldots .(4)(4) :

Hence, the required equation of the circle is

QUESTION 5

Show that the points and are concyclic.

Sol :

Let the required equation of the circle be

It is given that the circle passes through

Solving (2),(3) and (4)

Therefore, the equation of the circle is

We see that the point satisfies the equation (5)

Hence, the points and are concyclic.

QUESTION 6

Show that the points and all lie on a circle, and find its equation, center and radius.

Sol :

Let the required equation of the circle be

It is given that the circle passes through

Solving (3) and (4) by subtracting ,we get

then substituting value of in equation (2) and (3) we get

Solving (5) and (6) by subtracting , we get

then substituting value of f in equation (6) , we get

Thus, the equation of the circle is

We see that the point satisfies equation (7)

Hence, the points and lie on the circle.

Also, center of the required circle

QUESTION 7

Find the equation of the circle which circumscribes the triangle formed by the lines :

(i) and

Sol :

In

Let represent the line

Let BC represent the line

Let CA represent the line

Let A,B,C are the points of intersection of lines (i) and (ii) , (ii) and (iii) , (iii) and (i) respectively

are the co-ordinates

Now A circle

Circle passes through

Solving (1),(2),(3) we get

Hence, the required equation of the circumcircle is

(ii) and

Sol :

In

Let AB represent the line

Let BC represent the line

Let CA represent the line

Intersection point of and is

Intersection point of and is

Intersection point of and is

The coordinates of and are and respectively.

Let the equation of the circumcircle be
It passes through and

Hence, the required equation of the circumcircle is

(iii) and

Sol :

In

Let AB represent the line

*** QuickLaTeX cannot compile formula:

*** Error message:
Undefined control sequence \Idots.

Let BC represent the line

Let CA represent the line (3)

Intersection point of (1) and (3) is

Intersection point of (1) and (2) is

Intersection point of (2) and (3) is

The coordinates of and are and respectively.

Let the equation of the circumcircle be

It passes through A,B and C

Hence, the required equation of the circumcircle is

(iv) and

Sol :

In

Let represent the line

Let BC represent the line

Let CA represent the line

Intersection point of (1) and (3) is

Intersection point of (1) and (2) is

Intersection point of (2) and (3) is

Therefore, the coordinates of and are and respectively.

Let the equation of the circumcircle be
It passes through and

Hence, the required equation of the circumcircle is

QUESTION 8

Prove that the centers of the three circles and are collinear.

Sol :

The given equations of the circles are as follows:

The center of circle (1) is

The center of circle (2) is

The center of circle (3) is

The area of the triangle formed by the points and is

= 0

Hence, the centers of the circles and are collinear.

QUESTION 9

Prove that the radii of the circles and are in A.P.

Sol :

Let the radii of the circles , and be and

, ,

Now ,

and are in A.P

QUESTION 10

Find the equation of the circle which passes through the origin and cuts off intercept of lengths 4
and 6 on the positive side of the x-axis and y-axis respectively.

Sol :

According to the question, the circle passes through the origin.

Let the equation of the circle be

The circle cuts off chords of lengths 4 and 6 on the positive sides of the x-axis and the y- axis, respectively.

Center

Required equation :

QUESTION 11

Find the equation of the circle concentric with the circle and double of its area.

Sol :

Let the equation of the required circle be

The center of the circle is

Area of the required circle

Here, radius of the given circle

Area of the required circle

Let R be the radius of the required circle.

Thus, the equation of the required circle is i.e.

QUESTION 12

Find the equation to the circle which passes through the points and whose radius is 1 .Show that there are two such circles.

Sol :

Let the equation of the required circle be

It passes through and

From (1) and (2), we have:

From and we have:

by using

Solving (4) and (5) , we get

Therefore, the required equations of the circles are and

Hence, there are two such circles.

QUESTION 13

Find the equation of the circle concentric with and which touches the y-axis.

Sol :

since, the circles are concentric Centre of required circle = Centre of

The centre of the required circle is

We know that if a circle with centre touches the -axis, then is the radius of the circle.

Equation of the circle:

QUESTION 14

If a circle passes through the point then find the coordinates of its center .

Sol :

The general equation of the circle is

Now, it is passing through

Also, it is passing through

Again, it is passing through

The coordinates of its centre are given by

QUESTION 15

Find the equation of the circle which passes through the points and and the center lies on the straight line

Sol :

The general equation of the circle is where the center of the circle is

Now, it is passing through

Also, it is passing through

Now, the center lies on the straight line   , satisfies this equation

Solving (1),(2) and (3), we get

and

The equation of the circle is given by


text:
Wily Waves: Build an Oscillating Water Column to Extract Energy from Ocean Waves

 Areas of Science Energy & Power Difficulty Time Required Average (6-10 days) Prerequisites You should have fairly easy access to the ocean or to a deep body of water. Find a location where the surface of the water is within easy access of a pier, a dock, or a boat slip, and where the water is about 5 feet deep. You could also do this project in a swimming pool. Material Availability See the Materials and Equipment list for more details. Cost High ($100 -$150) Safety Be sure to wear safety equipment, such as safety goggles and gloves, when working with power tools and other equipment. Parental supervision is required.

Abstract

The ocean is a wondrous force of nature. It affects the weather, and provides us with food and renewable energy to power our lives. How can the ocean provide us with renewable energy? One way is to extract the energy that is in the waves. There are many kinds of power systems that can be installed to extract energy from the waves, depending on the location. In this energy and power science project, you will build and test a simple model of an oscillating water column device to create power. How many of these oscillating water columns will it take to power a lightbulb? If you want the answer, read on!

Objective

To build a simple and functional oscillating water column device.

Credits

Michelle Maranowski, PhD, Science Buddies

This science project is based upon the following Science Buddies Clever Scientist Award winning project:
Dreszer, Natalya. (2010). Catching the Wave.

General citation information is provided here. Be sure to check the formatting, including capitalization, for the method you are using and update your citation, as needed.

MLA Style

Science Buddies Staff. "Wily Waves: Build an Oscillating Water Column to Extract Energy from Ocean Waves." Science Buddies, 1 Dec. 2020, https://www.sciencebuddies.org/science-fair-projects/project-ideas/Energy_p037/energy-power/build-an-oscillating-water-column-to-extract-energy-from-ocean-waves. Accessed 3 Dec. 2020.

APA Style

Science Buddies Staff. (2020, December 1). Wily Waves: Build an Oscillating Water Column to Extract Energy from Ocean Waves. Retrieved from https://www.sciencebuddies.org/science-fair-projects/project-ideas/Energy_p037/energy-power/build-an-oscillating-water-column-to-extract-energy-from-ocean-waves

Last edit date: 2020-12-01

Introduction

It's a beautiful day and you're walking along the beach, when an ocean wave hits the shore and almost pushes you over. Just like your high-energy friend who runs over to tag you as "it," moving water also has energy. But from where does this energy, in the form of ocean waves, come? Waves are generated by disturbances, ranging from underground earthquakes to a boat moving through the water, but the wind is the most common source of waves. The wind causes ripples on the surface of the ocean, but the strength of the wind, the distance in which the wind blows, and the duration of the wind gust all determine how big the ripples will become.

A wavelength is the distance between 2 crests of a wave, the wave height is measured from the bottom of the trough to the top of the crest.

Figure 1. This figure shows some of the characteristics of a wave. (Courtesy of the Office of Naval Research, 2009.)

Waves are characterized by their wavelength and their height. Every kind of wave—whether it is a sound wave, a light wave, or an ocean wave—has a crest and a trough. The crest is the highest point of the wave and the trough is the lowest point of the wave. The wavelength is the distance between two consecutive wave crests. The height is the difference between the wave crest and the next wave trough. Another important characteristic of waves is the wave period. This is defined as the time between two consecutive crests (or troughs) as the crests (or troughs) pass a stationary point. Figure 1 depicts these characteristics of waves.

As ocean waves move forward, you might think that the water is moving forward; however, this is not the case. The water actually moves in vertical circles and there is little forward motion of the individual water particles in a wave. A wave is just forward motion of energy or momentum. Scientists gather data from the oceans—such as water temperature, wind speed, wind direction, wave height, and wave period—using ocean buoys, which are devices that float in the oceans.

How can we capture the energy associated with the waves and convert it to something we can use, like electricity? According to the U.S. Department of Energy (U.S. DOE), at any given moment, there is enough energy in the oceans' waves around the world to provide up to 2 trillion watts (W) of electricity! Since the oceans will always provide waves, wave energy is a renewable and sustainable form of energy. There are certain parts of the world that are especially rich in wave power. These include the western coasts of Scotland, Australia, South Africa and northern Canada. The northeastern and western coasts of the United States are also good locations to extract wave energy.

The U.S. DOE separates wave energy power systems into two categories: onshore systems and offshore systems. Onshore wave energy power devices include oscillating water columns, tapchans, and pendulor devices. In an oscillating water column, a partially submerged structure has an opening below the waterline to the ocean. It encloses a column of air on top of a column of water. As the column of water rises, due to incoming waves, the column of air is compressed and is forced past a turbine. This causes the turbine to rotate and generate electricity. When the wave recedes, the column of air is depressurized and air rushes past the turbine in the other direction. This causes the turbine to rotate again and generate more electricity. This is illustrated in Figure 2.

Air is trapped in a column by a wall that goes into a body of water. Water is allowed to pass under the wall and when it rises the air within the column is pushed upwards into a turbine at the top of the column. As the air is pushed and then pulled by the waves, the turbine is spun and generates electricity.

Figure 2. This image shows how an oscillating water column functions. (Energy Futures: MIT Energy Initiative, 2009.)

This video shows several different types of wave energy-harvesting devices, including an oscillating water column:

In this energy and power science project, you will build and test an oscillating water column device. You will build the oscillating water column from readily available parts and a computer cooling fan, then test it by submersing part of the column into a deep body of water. The fan will create a voltage (measured in volts) and a current (measured in amperes) that you will be able to detect with a multimeter when air pushes past it. You can read more about voltage and current in the Science Buddies Electricity, Magnetism, & Electromagnetism Tutorial. Will your oscillating water column create enough energy to light a compact fluorescent lightbulb?

Terms and Concepts

• Energy
• Crest
• Trough
• Wavelength
• Period
• Momentum
• Renewable
• Sustainable
• Oscillating water column
• Turbine
• Submerse
• Voltage (measured in volts, V)
• Current (measured in amperes, A)
• Multimeter
• Skew

Questions

• How does a tapchan device work? How does a pendulor device work?
• What are some devices that can be used to extract energy from ocean tides?
• Can all of the devices discussed in the introduction function efficiently at any location? Why or why not?

Bibliography

The following sites discuss power and energy. You should review these sites to help you determine how much power and energy your oscillating water column harnesses.

News Feed on This Topic

, ,
Note: A computerized matching algorithm suggests the above articles. It's not as smart as you are, and it may occasionally give humorous, ridiculous, or even annoying results! Learn more about the News Feed

Materials and Equipment

You will need the following materials, available from a hardware store or Jameco Electronics:

• ABS pipe, 4-in. diameter x 10-ft. length
• Tape measure
• Rubber band
• ABS pipe saw
• Volunteer
• Safety goggles (2 pairs)
• Gloves
• ABS cap hub, 4-in. diameter
• Drill with a set of drill bits, including a 1 3/8-in. step bit
• Ruler
• Crayon, white or yellow
• ABS cement, 4 ounces (oz.)
• Rubber gasket material or rubber packing; available in the plumbing repair aisle of a hardware store or home improvement center, such as Home Depot model # 59849
• Scissors
• Computer cooling fan, 80 mm x 80 mm, available from Jameco Electronics
• Wire strippers, available at a hardware store or Jameco Electronics
• Digital multimeter, available from Jameco Electronics
• Electrical tape in a variety of colors, at least 4 (such as red, yellow, green, and white)
• Alligator clip cables (2), available from Jameco Electronics
• Lab notebook
• Graph paper

Disclaimer: Science Buddies participates in affiliate programs with Home Science Tools, Amazon.com, Carolina Biological, and Jameco Electronics. Proceeds from the affiliate programs help support Science Buddies, a 501(c)(3) public charity, and keep our resources free for everyone. Our top priority is student learning. If you have any comments (positive or negative) related to purchases you've made for science projects from recommendations on our site, please let us know. Write to us at scibuddy@sciencebuddies.org.

Experimental Procedure

Building the Oscillating Water Column

1. Find a location where you can easily dunk or submerse the oscillating water column into water, such as a pool, lake, or ocean.
1. The water depth should be at least 8 feet.
2. You should find a location at a boat slip, edge of a swimming pool, or a pier so that while you are dunking the oscillating water column, you can lean against or hold onto something.
3. There shouldn't be a lot of other people wandering around while you do your experiment.
2. Once you have found an acceptable location, use your tape measure to measure the distance between the boat slip, pool edge, or pier and the surface of the water. You can imagine that the length of the whole tape measure will be the length of the oscillating water column. Mark the distance down in your lab notebook. Record the distance as a minimum of 5 feet in your lab notebook, even if the actual distance is less than 5 feet. This is the minimum value required to construct a functioning oscillating water column for this science project.
3. Once you've returned home, use the tape measure and mark the value that you recorded in step 2 on the ABS pipe with the rubber band. Now add 3 feet to where the first rubber band is placed. Place a second rubber band at this location. Remove the first rubber band. The purpose of this extra few feet is to give you something to hold on to while you are dunking the oscillating water column.
4. Now cut the ABS pipe at the rubber band with the ABS saw. Put on your safety goggles and gloves. Your volunteer should put on a pair of goggles, too. Have your volunteer hold the pipe on the ground so that you can cut the pipe.
5. Measure out a 3-in. hole in the top, flat part of the ABS cap hub. Mark the hole with the crayon and make sure that it is in the center of the cap hub. Place the cooling fan on top of the hole to make sure that the hole is about the same size as the fan. There are four screw holes in each corner of the fan case. Make a mark in the cap to match each of the corner holes in the fan case.
6. Put your safety goggles back on and drill each of the four corner holes and the 3-in. hole with the drill and the appropriate drill bit.
1. Your volunteer should also put back on his or her safety goggles and then help by holding the cap while you carefully drill the hole.
2. Use a smaller bit like a 1/4-in bit for the four corner screw holes.
3. Use a larger bit, like a 1/2-in drill bit, to make a pilot hole in the center of the 3-in hole. Then use the 1 3/8-in step bit to widen the hole. Go back to the 1/2-in bit and carefully shave off the extra material until the hole is 3 inches wide. Remember to stay within the crayon marking that you made in step 5.
4. Make sure that the drilled screw holes are not too big or too small for the screws.
7. Cut the gasket rubber with the scissors. Make a hole in the center where you marked with crayon, the same size as the hole in the cap hub. Also cut out the four holes to accommodate the fan's four corner screw holes. The purpose of the gasket is to make a seal between the cap and cooling fan.
8. Cut off the connectors from the end of the wires of the fan with the wire strippers. Use the wire strippers and strip off ½ in. of plastic from both ends of the wires.
9. Place the gasket material over the holes in the cap hub and then the fan, face-side down, on top of the gasket. Cut any excess gasket material off with the scissors. The gasket should make a good seal between the cooling fan and the cap hub. Make sure to place the fan wires in the case groove, located on the front face, and bring them back behind the fan through the hole. Once you are sure that the fan, gasket, and cap hub are aligned, attach the fan by screwing it down in each corner. Figure 4 shows what a completed fan and cap hub assembly should look like.

Figure 4. Completed fan and cap hub assembly. (Device made by Natalya Dreszer, 2010.)
1. Now glue the fan and cap hub assembly together with the pipe that you cut in step 4, as follows. Read the directions for the ABS cement. Spread the cement around the outside top end of pipe and the inside of the fan and cap hub assembly. Note: Make sure that you don't get any cement on the fan. Attach the two pieces together and let it harden for the recommended amount of time. The oscillating water column is now complete. Figure 5 depicts a completed version of a test oscillating water column.

Figure 5. A completed version of the test oscillating water column. (Device made by Natalya Dreszer, 2010.)

Testing the Oscillating Water Column

1. Prepare the oscillating water column for testing. Wrap a piece of red electrical tape around the oscillating water column, 2 ft. from the open end. Wrap a piece of yellow electrical tape 4 ft. from the open end. Wrap a piece of green electrical tape 5 ft. from the open end of the tube. Wrap a piece of white electrical tape 6 ft. from the open end of the tube.
2. Open the multimeter and read the included instructions. You must get familiar with the multimeter and learn how to measure voltage and current before you begin testing. If you need help using a multimeter, check out the Science Buddies reference How to Use a Multimeter.
3. Clip each of the wires from the fan to the leads of the multimeter with the alligator clip cables. Your volunteer will hold onto the multimeter and monitor the readings while you dunk the oscillating water column in the following steps.
4. Go to the location by the water that you found earlier. Submerge the open end of the oscillating water column 2 ft. into the water (to the red tape mark on the tube). Turn on the multimeter and monitor the voltage.
5. Then practice quickly dunking the water column in and out 2 ft. from the red tape on the tube to the yellow tape. When you feel confident doing this, start recording the peak voltage readings from the multimeter in your lab notebook. Quickly dunk the tube from the red tape to the yellow tape 12 times and with each dunk, record the peak voltage reading in your lab notebook. Dunking the water column 2 ft. represents a 2-ft. wave.
6. Repeat step 4, but this time, record the peak current readings in your lab notebook.
7. Repeat steps 4–6, dunking the water column 3 ft., moving from the red tape to the green tape. Dunking the water column 3 ft. represents a 3-ft. wave. Record all data in your lab notebook.
8. Repeat steps 4–6, dunking the water column 4 ft., moving from the red tape to the white tape. Dunking the water column 4 ft. represents a 4-ft. wave. Record all data in your lab notebook.

1. Now plot your data on graph paper. First plot the voltage data for each wave height. Label the x-axis Wave. You will have 12 data points for waves, since you dunked the water column 12 times. Label the y-axis Volts. You can plot the data for all three wave heights on the same plot.
2. Now plot the current data for each wave height. Label the x-axis Wave. You will have 12 data points for waves since you dunked the water column 12 times. Label the y-axis Amperes. You can plot the data for all three wave heights on the same plot. Note: Keep in mind that your current measurements will not be in the full ampere range, but more likely in the milliampere range and you will have to account for this in your plot.
3. Now average the peak voltage data and the peak current data for each wave height. For each set of data, remove the highest and lowest reading before averaging to prevent skewing the data too high or low. Once you have calculated the average voltage and current for each wave height, calculate the average peak power. Equation 1 shows how to calculate the average peak power that the water column harnessed.

Equation 1:
• P = Average peak power, in watts (W)
• I = Average current, in amperes (A)
• V = Average voltage, in volts (V)
1. Plot the average power that the water column harnessed at each wave height. Label the x-axis Wave Height and the y-axis Watts.
2. Review the references in the Bibliography to understand what power and energy are. How much energy does your oscillating water column harness in a day? How much energy does a typical lightbulb use in a day? How many oscillating water columns would you have to build to use a typical lightbulb for a day?
.

If you like this project, you might enjoy exploring these related careers:

Career Profile
Environmental engineers plan projects around their city or state—like municipal water systems, landfills, recycling centers, or sanitation facilities—that are essential to the health of the people who live there. Environmental engineers also work to minimize the impact of human developments, like new roads or dams, on environments and habitats, and they strive to improve the quality of our air, land, and water. Read more
Career Profile
If you turned on a faucet, used a bathroom, or visited a public space (like a road, a building, or a bridge) today, then you've used or visited a project that civil engineers helped to design and build. Civil engineers work to improve travel and commerce, provide people with safe drinking water and sanitation, and protect communities from earthquakes and floods. This important and ancient work is combined with a desire to make structures that are as beautiful and environmentally sound, as they… Read more
Career Profile
Just as a potter forms clay, or a steel worker molds molten steel, electrical and electronics engineers gather and shape electricity and use it to make products that transmit power or transmit information. Electrical and electronics engineers may specialize in one of the millions of products that make or use electricity, like cell phones, electric motors, microwaves, medical instruments, airline navigation system, or handheld games. Read more
Career Profile
Mechanical engineers are part of your everyday life, designing the spoon you used to eat your breakfast, your breakfast's packaging, the flip-top cap on your toothpaste tube, the zipper on your jacket, the car, bike, or bus you took to school, the chair you sat in, the door handle you grasped and the hinges it opened on, and the ballpoint pen you used to take your test. Virtually every object that you see around you has passed through the hands of a mechanical engineer. Consequently, their… Read more

Variations

• How big would your oscillating water column have to be to completely provide energy to run your house for a day? Look at your family's electric bill to find out how much energy your house uses in a day.
• Build an oscillating water column using a 3-in.-diameter tube. What is the difference in power and energy harnessed between the 3-in. oscillating water column and the 4-in. oscillating water column?

Share your story with Science Buddies!

The Ask an Expert Forum is intended to be a place where students can go to find answers to science questions that they have been unable to find using other resources. If you have specific questions about your science fair project or science fair, our team of volunteer scientists can help. Our Experts won't do the work for you, but they will make suggestions, offer guidance, and help you troubleshoot.


text:
# How to draw random sample from an empirical joint distribution?

I want to draw a random sample from a known joint distribution. what I have now is the number of people in each age and income bracket (as shown in the example below):0.12 0.42 0.06 16 0.08 0.28 0.04

                   income $1-10,000 income$10,001-20,000
15-20 years old      0.12                      0.08
21-25 years old      0.42                      0.28
26-30 years old      0.06                      0.04

Using this I will get the joint distribution of income and age. But I am not sure where to go from here in terms of drawing samples.

Any thoughts are appreciated. My knowledge in statistics is quite limited...

• This is not an empirical joint distribution--it is merely a summary of data. In what way do you hope to use it to infer or represent a distribution?
– whuber
Nov 8, 2016 at 15:41
• After the edit it is still just a data summary. If by "joint distribution" you mean the discrete distribution for the six groups you have shown, then sample it as you would any discrete distribution. But if you want to sample from some hypothetical underlying distribution that gave rise to the data shown here, then you must make some strong assumptions about that distribution, fit it to the data, and then proceed to sample.
– whuber
Nov 8, 2016 at 16:44
• I see. Let me try to sample a discrete distribution first. Thanks!
– whyq
Nov 8, 2016 at 16:48

dist = [(("15-20 yr", "$1-10000"), 0.12), (("15-20 yr", "$10000-20000"), 0.08), ...]


text:
Department of Pre-University Education, KarnatakaPUC Karnataka Science Class 11

# Find the Equations of the Sides of the Triangles the Coordinates of Whose Angular Point is Respectively (1, 4), (2, −3) and (−1, −2). - Mathematics

Find the equations of the sides of the triangles the coordinates of whose angular point is respectively (1, 4), (2, −3) and (−1, −2).

#### Solution

Let the given points be A (1, 4), B (2, −3) and C (−1, −2).

Let $m_1 , m_2 \text { and } m_3$ be the slopes of the sides AB, BC and CA, respectively.

$\therefore m_1 = \frac{- 3 - 4}{2 - 1}, m_2 = \frac{- 2 + 3}{- 1 - 2} \text { and } m_3 = \frac{4 + 2}{1 + 1}$

$\Rightarrow m_1 = - 7, m_2 = - \frac{1}{3} \text { and } m_3 = 3$

So, the equations of the sides AB, BC and CA are

$y - 4 = - 7\left( x - 1 \right), y + 3 = - \frac{1}{3}\left( x - 2 \right) \text { and } y + 2 = 3\left( x + 1 \right)$

$\Rightarrow 7x + y = 11, x + 3y + 7 = 0\text { and } 3x - y + 1 = 0$

Is there an error in this question or solution?

#### APPEARS IN

RD Sharma Class 11 Mathematics Textbook
Chapter 23 The straight lines
Exercise 23.5 | Q 2.1 | Page 35

Share


text:
# Jefferson disk

Jefferson's disk cipher

The Jefferson disk, or wheel cypher as Thomas Jefferson named it, also known as the Bazeries Cylinder, is a cipher system using a set of wheels or disks, each with the 26 letters of the alphabet arranged around their edge. The order of the letters is different for each disk and is usually scrambled in some random way. Each disk is marked with a unique number. A hole in the centre of the disks allows them to be stacked on an axle. The disks are removable and can be mounted on the axle in any order desired. The order of the disks is the cipher key, and both sender and receiver must arrange the disks in the same predefined order. Jefferson's device had 36 disks. [Kahn, p. 194]

Once the disks have been placed on the axle in the agreed order, the sender rotates each disk up and down until a desired message is spelled out in one row. Then the sender can copy down any row of text on the disks other than the one that contains the plaintext message. The recipient simply has to arrange the disks in the agreed-upon order, rotate the disks so they spell out the encrypted message on one row, and then look around the rows until he sees the plaintext message, i.e. the row that's not complete gibberish. There is an extremely small chance that there would be two readable messages, but that can be checked quickly by the person coding.

First invented by Thomas Jefferson in 1795, this cipher did not become well known and was independently invented by Commandant Etienne Bazeries, the conqueror of the Great Cipher, a century later. The system was used by the United States Army from 1923 until 1942 as the M-94.

This system is not considered secure against modern codebreaking if it is used to encrypt more than one row of text with the same ordering of disks (i.e. using the same key). See #Cryptanalysis.

## Operation

To encrypt a message, Alice rotates the disks to produce the plaintext message along one "row" of the stack of disks, and then selects another row as the ciphertext. To decrypt the message, Bob rotates the disks on his cylinder to produce the ciphertext along a row. It is handy if both Alice and Bob know the offset of the row, but not really necessary since Bob can simply look around the cylinder to find a row that makes sense.

For example, a simplified "toy" Bazeries cylinder using only ten disks might be organised as shown below, with each disk "unwrapped" into a line and each marked with a designating number:

 1: < ZWAXJGDLUBVIQHKYPNTCRMOSFE < 2: < KPBELNACZDTRXMJQOYHGVSFUWI < 3: < BDMAIZVRNSJUWFHTEQGYXPLOCK < 4: < RPLNDVHGFCUKTEBSXQYIZMJWAO < 5: < IHFRLABEUOTSGJVDKCPMNZQWXY < 6: < AMKGHIWPNYCJBFZDRUSLOQXVET < 7: < GWTHSPYBXIZULVKMRAFDCEONJQ < 8: < NOZUTWDCVRJLXKISEFAPMYGHBQ < 9: < XPLTDSRFHENYVUBMCQWAOIKZGJ < 10: < UDNAJFBOWTGVRSCZQKELMXYIHP <

If the "key", the sequence of disks, for this Bazeries cylinder is

7,9,5,10,1,6,3,8,2,4

and Alice wants to send the message "retreat now" to Bob, she rearranges the disks as per the key and rotates each disk to obtain the plaintext, which is shown at the left, with spacing added for clarity:

 7: < R AFDCE O NJQGWTHSPYBXIZULVKM < 9: < E NYVUB M CQWAOIKZGJXPLTDSRFH < 5: < T SGJVD K CPMNZQWXYIHFRLABEUO < 10: < R SCZQK E LMXYIHPUDNAJFBOWTGV < 1: < E ZWAXJ G DLUBVIQHKYPNTCRMOSF < 6: < A MKGHI W PNYCJBFZDRUSLOQXVET < 3: < T EQGYX P LOCKBDMAIZVRNSJUWFH < 8: < N OZUTW D CVRJLXKISEFAPMYGHBQ < 2: < O YHGVS F UWIKPBELNACZDTRXMJQ < 4: < W AORPL N DVHGFCUKTEBSXQYIZMJ <

She then selects the ciphertext from the sixth row of the cylinder up from the plaintext. This ciphertext is also highlighted above with spacing, and gives:

OMKEGWPDFN

When Bob gets the ciphertext, he rearranges the disks on his cylinder to the key arrangement, rotates the disks to give the ciphertext, and then reads the plaintext six rows down from the ciphertext, or simply looks over the cylinder for a row that makes sense.

## Basis for military ciphers

The Bazeries cylinder was the basis for the US "M-94" cipher machine, which was introduced in 1922 and derived from work by Parker Hitt. In 1914, Hitt had experimented with the Bazeries device, building one prototype using slides on a wooden frame, with the cipher alphabets printed twice consecutively on the slides, and then another using disks of wood. He forwarded his experiments up the Signal Corps chain of command, and in 1917 Joseph Mauborgne refined the scheme, with the final result being the M-94.

The M-94 used 25 aluminium disks on a spindle. It was used by the Army, Coast Guard, and the Radio Intelligence Division of the Federal Communications Commission until early in World War II. The Army changed back to Hitt's original slide scheme with the "M-138-A" cipher machine, which was introduced in the 1930s and was used by the US Navy and US State Department through World War II. The M-138-A featured 100 strips, with 30 selected for use in any one cipher session. It was a considerable improvement in security for the State Department, which during the interwar years had used laughably insecure codes, even in one case a standard commercial telegraph code. They were much more easily broken.

## Cryptanalysis

The Bazeries cylinder was a relatively strong system at the time (compared to many other systems in use), and Etienne Bazeries, a competent but very opinionated man, is said to have regarded it as indecipherable. In fact, it is hardly impregnable, and the "Pers z" code-breaking group of the German Foreign Office cracked the M-138-A in 1944. However, by that time the Americans had much more sophisticated cipher systems in operation. Many of the decrypts of Allied communications presented to the German high command were disregarded, because all they did was confirm bad news that nobody wanted to acknowledge in an environment where defeatism was potentially a capital crime.[citation needed]

de Viaris (aka Marquis Gaetan Henri Leon Viarizio di Lesegno) who is famous for one of the first printing cipher devices (1874), solved the Bazeries cylinder in 1893, so Bazeries' alleged confidence in the system was ill-placed.

One major weakness of the Bazeries cylinder is that the offset from the plaintext letter to the ciphertext letter for the cipher alphabet on each disk will be exactly the same. In the example shown above, this offset is six letters.

Suppose a cryptanalystHolmes, say — has captured the simplified Bazeries cylinder described in the example above, with ten disks. This should not be enough to permit him to decipher messages with it, since he also has to know the key, or the arrangement of the disks on the cylinder. Even for this simplified Bazeries cylinder, the number of possible permutations of the disks are:

$10! = 3,628,800$

— which makes trial and error testing of the arrangement of the disks perfectly impractical to perform by hand; computers would make such a break near trivial for 10 disks, but not for the 36 disks that Jefferson used, as 36! ≈ 2138.

Now, further suppose that Holmes has a crib. For example, suppose he knows that the first block of plaintext enciphered by the simplified Bazeries cylinder is the string:

heilhitler

Conveniently, this is exactly ten letters long, and can be enciphered in a single pass with the simplified Bazeries cylinder. The corresponding ciphertext is:

AZNCZEAPBH

The remainder of the message is of course a complete mystery for the moment. Fortunately, Holmes can use this crib to allow him to decipher all the following blocks of the message.

Holmes has no idea of which disk is used to encipher which letter, but he does know that the offset between the plaintext letter and the ciphertext letter must be the same for all ten characters. This gives him a way of penetrating the cipher by lining up the plaintext and ciphertext characters of the crib; forming them into pairs; determining the offsets for the plaintext letters and ciphertext letters for each disk; and then searching for a common offset in the matrix of offset.

Holmes knows that the correspondence between the two sets of letters is as follows:

• hA
• eZ
• iN
• lC
• hZ
• iE
• tA
• lP
• eB
• rH

Now Holmes takes disk 1, which has the cipher alphabet:

1: < ZWAXJGDLUBVIQHKYPNTCRMOSFE <

The first letter pair is "h:A", and Holmes counts along the disk to determine that the offset between the two letters is 15. The second letter pair is "e:Z", and he sees right away that the offset is 1. He continues this process for each letter pair for disk 1, and then goes through the same procedure for the nine other disks, producing the following table:

       h:A  e:Z  i:N  l:C  h:Z  i:E  t:A  l:P  e:B  r:H
________________________________________________
1:    15    1    6   12   13   14   10    9   10   19
2:    14    5    6    3   16    4   22   23   25    7
3:    15   15    4    2   17   12   14   25   10    7
4:    18    7   10    7   14   20   12   25    1    6
5:     4   14   20   13   20    7   21   14   25   24
6:    22   16    3   17   10   19    1   14   14   14
7:    14   15   14    8    7   12   15   19   12   13
8:    21   12   12   22    5    2   14    8    8   14
9:    11   14   15   14   15   14   16   25    5    2
10:    5   23    5   21   17   21   20    6   14   12

As Holmes prepares the table, the value "14" quickly jumps out at him as a common element, and in completion of the table proves to be the only common element. This is obviously the row offset from the plaintext to the ciphertext. He strips the other values out for clarity:

       h:A  e:Z  i:N  l:C  h:Z  i:E  t:A  l:P  e:B  r:H
________________________________________________
1:     -    -    -    -    -   14    -    -    -    -
2:    14    -    -    -    -    -    -    -    -    -
3:     -    -    -    -    -    -   14    -    -    -
4:     -    -    -    -   14    -    -    -    -    -
5:     -   14    -    -    -    -    -   14    -    -
6:     -    -    -    -    -    -    -   14   14   14
7:    14    -   14    -    -    -    -    -    -    -
8:     -    -    -    -    -    -   14    -    -   14
9:     -   14    -   14    -   14    -    -    -    -
10:    -    -    -    -    -    -    -    -   14    -

Now Holmes rearranges the disks to reflect the correct order of the letters on the cylinder. This is done by rearranging the rows of the table so that the value "14" appears in every cell along the table's main diagonal. In this case, there are no ambiguities in the arrangement of the disks; but if there had been, a little testing of subsequent blocks of the ciphertext would reveal the proper order.

       h:A  e:Z  i:N  l:C  h:Z  i:E  t:A  l:P  e:B  r:H
________________________________________________
2:    14    -    -    -    -    -    -    -    -    -
5:     -   14    -    -    -    -    -   14    -    -
7:    14    -   14    -    -    -    -    -    -    -
9:     -   14    -   14    -   14    -    -    -    -
4:     -    -    -    -   14    -    -    -    -    -
1:     -    -    -    -    -   14    -    -    -    -
3:     -    -    -    -    -    -   14    -    -    -
6:     -    -    -    -    -    -    -   14   14   14
10:    -    -    -    -    -    -    -    -   14    -
8:     -    -    -    -    -    -   14    -    -   14

This gives the key:

2,5,7,9,4,1,3,6,10,8

In the real world, a Bazeries cylinder has more disks (commonly, 20 or 30 rather than 10), and it less likely there would be a single crib that would span the entire cylinder. Nevertheless, the approach described above still works. Even if the cylinder had 30 disks and a crib only had five letters, Holmes could build up a table of the offsets for each of the 30 disks for the five letter pairs, and use it to narrow down the possibilities for the offset and the disks used for the crib.

Holmes could repeat the procedure with several independent cribs in the same message, almost certainly pinning down the offset quickly and giving an improved knowledge of the order of the disks. Once the offset has been determined, then Holmes would have what amounted to a straight transposition of the letters not determined by tinkering with the cribs, and use methods such as multiple anagramming to crack it.

## Sources

• The Codebreakers, David Kahn, 1967, pp. 192–195


text:
Difference between revisions of "2011 AMC 10A Problems/Problem 23"

Problem

Seven students count from 1 to 1000 as follows:

•Alice says all the numbers, except she skips the middle number in each consecutive group of three numbers. That is, Alice says 1, 3, 4, 6, 7, 9, . . ., 997, 999, 1000.

•Barbara says all of the numbers that Alice doesn't say, except she also skips the middle number in each consecutive group of three numbers.

•Candice says all of the numbers that neither Alice nor Barbara says, except she also skips the middle number in each consecutive group of three numbers.

•Debbie, Eliza, and Fatima say all of the numbers that none of the students with the first names beginning before theirs in the alphabet say, except each also skips the middle number in each of her consecutive groups of three numbers.

•Finally, George says the only number that no one else says.

What number does George say?

$\textbf{(A)}\ 37\qquad\textbf{(B)}\ 242\qquad\textbf{(C)}\ 365\qquad\textbf{(D)}\ 728\qquad\textbf{(E)}\ 998$

Solution

First look at the numbers Alice says. $1, 3, 4, 6, 7, 9 \cdots$ skipping every number that is congruent to $2 \pmod 3$. Thus, Barbara says those numbers EXCEPT every second - being $2 + 3^1 \equiv 5 \pmod{3^2=9}$. So Barbara skips every number congruent to $5 \pmod 9$. We continue and see:

Alice skips $2 \pmod 3$, Barbara skips $5 \pmod 9$, Candice skips $14 \pmod {27}$, Debbie skips $41 \pmod {81}$, Eliza skips $122 \pmod {243}$, and Fatima skips $365 \pmod {729}$.

Since the only number congruent to $365 \pmod {729}$ and less than $1,000$ is $365$, the correct answer is $\boxed{365\ \mathbf{(C)}}$.