text:
# FFT showing peaks at 0Hz?

so I've been attempting to do a FFT on some data and I'm seeing a peak at 0Hz, which I can't really comprehend why since I'm quite new to signal processing. I read in my file using pandas, saved them to arrays and used scipy's FFT function on the y data. But when plotting it against a frequency linspace the results seem odd to me. I'm not quite sure how to get the time domain into the frequency domain. Any help would be much appreciated, thank you. (Note: The data isn't perfectly horizontal).

• Show the plot, please, and tell us in general what data you're taking. – TimWescott May 11 at 20:37
• Most probably your data has some DC bias. I don't see any detrending or windowing -- am I missing it? – TimWescott May 11 at 20:39
• On the $[0,2000]$ interval, I can spot something like an $y$ offset above the decaying trend. Or a little jump around $2000$. Once you remove the trend, this might be seen as a two-level bias, of very low sequency, which could explain the remaining low-frequency component in the FFT – Laurent Duval May 12 at 10:26
• @Boyon I'd be happy to redact the edits, but can you please leave a question that can be answered or delete the whole thing? I can redact after you delete. – Peter K. May 13 at 17:43
• @PeterK. I can leave a question sure, but I haven't been able to delete it since it got a lot of attention. I even emailed the website and they said they wouldn't, which I'm surprised given the nature of my request. – Boyon May 13 at 18:24

[EDITED FROM DISCUSSION]

On the first order, your data looks like a decay with a positive origin on a small-valued range $$[0.7 \; 0.49]\times 10^{-7}$$, and very tiny fluctuations with respect to the area under the curve.

So from afar, your data is much closer to an almost constant function than to some putative oscillations. So the the zero, or DC-component, is important. Indeed, the amplitude of your maximum FFT is around $$5.9 \times 10^{-7}$$, which happens to match the average value of your data, if I use the trapezoidal approximation $$(0.7+0.49)/2= 0.595$$ (I hope your FFT is normalized).

For second order observations, you can try to remove the exponential-looking decay trend (by an exponential fit, or a low-degree polynomial, of 2nd or 3rd order for instance). With the sufficiently dense number of points, you can also try again on the derivative (taking care of end-points) or second derivative, to see if periodic phenomena appear. But this is likely to amplify noise.

At the third order, on the index interval $$[0,\,2000]$$, I see a kind of dropout around an order of magnitude of $$0.05 \times 10^{-7}$$. Once you remove the trend, this could appear like a single step down, which may cause a low-frequency effect in your signal.

• For sure, I'll give it a try and get back to you. Thanks again. – Boyon May 11 at 22:35
• If there's a peak close to zero then you've probably done your best. If there's a peak at zero then you can force it to zero by subtracting whatever residual mean there is after subtracting out the parabola, or by choosing a way to compute the parabola that forces its mean to equal your data's mean. – TimWescott May 12 at 0:58
• Manually removing some low-frequency component before doing a FT is a bit like digging a hole for a single potato right before ploughing the entire field. – leftaroundabout May 12 at 11:49
• @CarlWitthoft yeah... though a) FFT is so cheap and double-precision so abuntant that there's no need to worry except in extreme applications b) scaling up before or after trafo doesn't make any difference in floating-point c) hm, doesn't the outermost recursion of an FFT basically calculate average and remove that anyway? Not sure right now if that's equivalent to the manual version. – leftaroundabout May 12 at 13:22
• @TimWescott right, the real problem is that Fourier doesn't like nonperiodic functions and thus it makes sense to fake periodicity with a window. – leftaroundabout May 12 at 16:31

Because your data is (I assume) composed of some interesting stuff times a teeny number, plus the -- presumably uninteresting -- $$k_0 + N\,k_1 + N^2\,k_2$$, where $$N$$ is your "epoch".

So the Fourier transform of the data as a whole is dominated by the Fourier transform of $$k_0 + N\,k_1 + N^2\,k_2$$.


text:
# Problem after withdrawal non hard fork ethereum

I have a problem, I successfully withdraw some ETC but when I tried another time to withdraw the rest I think I put in more ETC and I didn't receive anything and now when I try again to withdraw any amount it won't work, not even with 1 ETC. In mist appears like the transaction was successful but the coin never reached the exchange. Can someone please help me?

I'm assuming you are sending your transactions from the hard-forked ETH chain, and your transactions are being replayed on the non-hard-forked ETC chain.

If this is the case, your problem is most likely due to the error transaction on the ETC chain causing the transaction nonce (see 1 and 2) to be out of sync between the two chains.

Subsequent transactions sent from the ETH chain would have the transaction nonce out of sequence and would therefore fail.

Here is an example:

Transaction ETH Nonce ETH Chain Status ETC Chain Status
----------- --------- ---------------- ---------------------------------
1           1         Success          Success
2           2         Success          Success
3           3         Success          Error Tx Value > Account Balance
4           4         Success          Error, expecting nonce #3
5           5         Success          Error, expecting nonce #3

If you want to execute a transaction on the ETC chain, you will have to start a node on the ETC chain and send your transaction from this node. The correct nonce will be used by your wallet software.

I've just set up a separate computer for to keep the ETH and ETC chain data separate. And use a conditional contract to make sure that your replayed transactions don't end up unexpectedly transferring amounts into incorrect accounts on the other chain.

format: plain


text:
Helper function for ggstatsplot::ggdotplotstats to apply this function across multiple levels of a given factor and combining the resulting plots using ggstatsplot::combine_plots.

grouped_ggdotplotstats(
data,
x,
y,
grouping.var,
title.prefix = NULL,
output = "plot",
...,
plotgrid.args = list(),
title.text = NULL,
title.args = list(size = 16, fontface = "bold"),
caption.text = NULL,
caption.args = list(size = 10),
sub.text = NULL,
sub.args = list(size = 12)
)

## Arguments

data A dataframe (or a tibble) from which variables specified are to be taken. A matrix or tables will not be accepted. A numeric variable from the dataframe data. Label or grouping variable. A single grouping variable (can be entered either as a bare name x or as a string "x"). Character string specifying the prefix text for the fixed plot title (name of each factor level) (Default: NULL). If NULL, the variable name entered for grouping.var will be used. Character that describes what is to be returned: can be "plot" (default) or "subtitle" or "caption". Setting this to "subtitle" will return the expression containing statistical results. If you have set results.subtitle = FALSE, then this will return a NULL. Setting this to "caption" will return the expression containing details about Bayes Factor analysis, but valid only when type = "parametric" and bf.message = TRUE, otherwise this will return a NULL. For functions ggpiestats and ggbarstats, setting output = "proptest" will return a dataframe containing results from proportion tests. Arguments passed on to ggdotplotstats point.argsA list of additional aesthetic arguments passed to geom_point. test.valueA number specifying the value of the null hypothesis (Default: 0). test.kInteger denoting the number of decimal places expected for test.value label. (Default: 0 ). test.value.lineLogical that decides whether a line corresponding to the test.value should be superimposed on the plot. test.value.line.argsA list of additional aesthetic arguments to be passed to the geom_line used to display the lines corresponding to the centrality parameter and test value. test.value.label.argsA list of additional aesthetic arguments to be passed to the geom_label used to display the label corresponding to the centrality parameter and test value. centrality.parameterDecides which measure of central tendency ("mean" or "median") is to be displayed as a vertical line. To not show any parameter, set this to "none". centrality.kInteger denoting the number of decimal places expected for centrality parameter label. (Default: 2). centrality.line.argsA list of additional aesthetic arguments to be passed to the geom_line used to display the lines corresponding to the centrality parameter and test value. centrality.label.argsA list of additional aesthetic arguments to be passed to the geom_label used to display the label corresponding to the centrality parameter and test value. xlabLabels for x and y axis variables. If NULL (default), variable names for x and y will be used. subtitleThe text for the plot subtitle. Will work only if results.subtitle = FALSE. captionThe text for the plot caption. typeType of statistic expected ("parametric" or "nonparametric" or "robust" or "bayes").Corresponding abbreviations are also accepted: "p" (for parametric), "np" (nonparametric), "r" (robust), or "bf"resp. bf.priorA number between 0.5 and 2 (default 0.707), the prior width to use in calculating Bayes factors. bf.messageLogical that decides whether to display Bayes Factor in favor of the null hypothesis. This argument is relevant only for parametric test (Default: TRUE). effsize.typeType of effect size needed for parametric tests. The argument can be "d" (for Cohen's d) or "g" (for Hedge's g). conf.levelScalar between 0 and 1. If unspecified, the defaults return 95% lower and upper confidence intervals (0.95). nbootNumber of bootstrap samples for computing confidence interval for the effect size (Default: 100). kNumber of digits after decimal point (should be an integer) (Default: k = 2). results.subtitleDecides whether the results of statistical tests are to be displayed as a subtitle (Default: TRUE). If set to FALSE, only the plot will be returned. ggplot.componentA ggplot component to be added to the plot prepared by ggstatsplot. This argument is primarily helpful for grouped_ variant of the current function. Default is NULL. The argument should be entered as a function. ggthemeA function, ggplot2 theme name. Default value is ggplot2::theme_bw(). Any of the ggplot2 themes, or themes from extension packages are allowed (e.g., ggthemes::theme_fivethirtyeight(), hrbrthemes::theme_ipsum_ps(), etc.). ggstatsplot.layerLogical that decides whether theme_ggstatsplot theme elements are to be displayed along with the selected ggtheme (Default: TRUE). theme_ggstatsplot is an opinionated theme layer that override some aspects of the selected ggtheme. ylabLabels for x- and y- axis variables, respectively (Defaults: "regression coefficient" and "term"). A list of additional arguments to cowplot::plot_grid. String or plotmath expression to be drawn as title for the combined plot. A list of additional arguments provided to title, caption and sub, resp. String or plotmath expression to be drawn as the caption for the combined plot. A list of additional arguments provided to title, caption and sub, resp. The label with which the combined plot should be annotated. Can be a plotmath expression. A list of additional arguments provided to title, caption and sub, resp.

## References

https://indrajeetpatil.github.io/ggstatsplot/articles/web_only/ggdotplotstats.html

grouped_gghistostats, ggdotplotstats, gghistostats

## Examples

# \donttest{
# for reproducibility
set.seed(123)

# removing factor level with very few no. of observations
df <- dplyr::filter(.data = ggplot2::mpg, cyl %in% c("4", "6", "8"))

# plot
ggstatsplot::grouped_ggdotplotstats(
data = df,
x = "cty",
y = "manufacturer",
grouping.var = "cyl",
test.value = 15.5,
title.prefix = "cylinder count",
ggplot.component = ggplot2::scale_x_continuous(
sec.axis = ggplot2::dup_axis(),
limits = c(12, 24),
breaks = seq(12, 24, 2)
),
messages = FALSE
)#> Scale for 'x' is already present. Adding another scale for 'x', which will
#> replace the existing scale.#> Scale for 'x' is already present. Adding another scale for 'x', which will
#> replace the existing scale.#> Scale for 'x' is already present. Adding another scale for 'x', which will
#> replace the existing scale.# }


text:
# How do you factor x^3+6x^2+3x-10?

Apr 10, 2016

y = (x - 1)(x + 2)(x + 5)

#### Explanation:

Since a + b + c + d = 0, f(1) = 0. One factor is (x - 1).
After division -->
$y = \left(x - 1\right) \left({x}^{2} + 7 x + 10\right)$
The trinomial in parentheses can be factored
Find 2 numbers knowing sum (7) and product (10). They are 2 and 5.
${x}^{2} + 7 x + 10 = \left(x + 2\right) \left(x + 5\right)$
$y = \left(x - 1\right) \left(x + 2\right) \left(x + 5\right)$


text:
## Monday, July 1, 2019

### Stats LLC's "Marshall Faulk Number"

LOOKING BACK
By John Turney
Just under twenty years ago Stats, LLC (then Stats, Inc and now is STATS and purports to be "STATS is the world's leading sports data and technology company") published preseason books reviewing the previous NFL seasons. Often they'd list new and innovative stats or would simply make observations on unique players or teams.

One of those things was called the "Marshall Faulk number". It was meant to measure running backs who run the ball well and caught the ball well. They'd take the rushing yards and the receiving yards and do a harmonic mean.

According to WikipediaThe harmonic mean can be expressed as the reciprocal of the arithmetic mean of the reciprocals of the given set of observations. As a simple example, the harmonic mean of 1, 4, and 4 is
${\displaystyle \left({\frac {1^{-1}+4^{-1}+4^{-1}}{3}}\right)^{-1}={\frac {3}{{\frac {1}{1}}+{\frac {1}{4}}+{\frac {1}{4}}}}={\frac {3}{1.5}}=2\,.}$
Essentially it's a mean that Stats, LLC. best expressed the average between the rushing and receiving numbers.

Well, they began that in 1999 if memory serves and today we will update it. However, we did it by average rushing/receiving yards per game, not the season totals so it will better include players from the 14- and 12-game seasons.

Faulk dominates the top six but other great names are listed including Lenny Moore, Chuck Foreman and others.

Here are all the players who averaged (harmonic mean) 58.0 yards per game.

#### 2 comments:

1. John, I hope you don't take this as either cheeky or churlish, but....does this have any application in the "real world"? how would an offensive coordinator of an NFL team approach this data?

1. I don't think an offensive coordinator would have any use for that statistic. Or 90% of all statistics.

It's a stat for fans


text:
# Intrinsically safe circuits

Is there a power threshold below which a circuit is considered to be intrinsically safe? For example, if one were to power a tiny Arduino circuit at 5vdc / 30mA = .15W could such a device be considered Intrinsically Safe and used in ATEX Zone 2 or Zone 0 WITHOUT going through certification?

Alternatively are there IS enclosures that are also RF (2.4Ghz) 'transparent'?

• Not really my area of expertise, but my understanding has always been a system can't be considered intrinsically safe until it has been certified as such, aka. no self certification. Think about it, is that something you really want to chance? – Matt Young Aug 26 '15 at 18:25
• Seeing what my hardware colleague is going through to make sure everything is fine for a circuit to be intrinsically safe, I guess this question will get to broad. And it is also my understanding that you need a certification, so an authority will double check and question your design. – Arsenal Aug 26 '15 at 18:28
• I agree with Matt, you cannot self certify for intrinsically safe, it must be done by an agency. However, standards like CAN/CSA-C22.2 NO. 157-92, do have some charts about energy calculations. Aside that they also require some redundancies etc.. its pretty deep waters – Kvegaoro Aug 26 '15 at 18:36
• – Adam Haun Aug 26 '15 at 18:42
• If you keep total capacitance and inductance low and operate with low current at a voltage below 6V, you may be able to get a certification more easily (cheaper) because it won't have to be electrically tested. However, the certifying body will be the one to determine that it doesn't need to be tested. – TimH Dec 8 '15 at 22:22

As has already been mentioned, you need to have a recognized certifying authority test your device to ensure that it meets the requirements for Intrinsic Safety.

Your power level is fine but you have to ensure that the total amount of stored energy is below the limit for your voltage rating. That means that capacitors can't be larger than some value; same for inductors.

Another option that you can explore is to use a certified Explosion-Proof enclosure. Again, there are rules that specify how the connections are made to such an enclosure (epoxy-sealed conduit, etc). However, if you are building only a few devices, this can be a less expensive method than going for full Intrinsic Safety certification.

FWIW - it costs us anywhere between Can $5,000 to$10,000 for Intrinsic Safety certification for each of the hazardous-location devices that we manufacture. There are also quarterly inspections that each cost several hundred dollars for devices that are type-approved.

What would this circuit be powered by and the energy stored in the source is it substantial ? Low voltage isn't going to be an issue if you have no boosters or chargpumps that can fail and push voltage to 20V or so even temporarily. Other issue though is short-circuit currents through high enough inductances that may unload the energy stored in forms of small enough sparks, but small enough to ignite say hydrogen etc. the 60079 standards provide empiricaly sources graphs for ignition of various gases with respect to inductances and/or capacitances. there will be no way you could bypass a certification body, but a simple circuit will always help with spedding up things and keeping costs down. Simple enough would be an alkaline cell with maximum possible voltage of 1,65Volts and an LED and resistor in series, and this would require probabaly the least risk analysys of any useful circuit, but then certification would still cost in the orders of a few thousand (just for getting the stamp on a paper)

Intrinsically safe device does not create sparks of sufficient energy to ignite certain explosive atmosphere (what gases and what energy depends on classification).

With no certification approval, you could not go to zone 0, however the zone 2 of Ex i in concept can be self-declared by manufacturer in Europe (ATEX).


text:
# The writers of the u.s constitution were most positively influenced by: A: Enlightenment thinkers B. the Boston tea party C. the British government D. the articles of confederation

###### Question:

the writers of the u.s constitution were most positively influenced by:
A: Enlightenment thinkers
B. the Boston tea party
C. the British government
D. the articles of confederation

### An engineer has designed a valve that will regulate water pressure on an automobile engine. The valve was tested on 110 engines and the mean pressure was 4.6 lbs/square inch. Assume the standard deviation is known to be 0.8. If the valve was designed to produce a mean pressure of 4.5 lbs/square inch, is there sufficient evidence at the 0.02 level that the valve does not perform to the specifications?

An engineer has designed a valve that will regulate water pressure on an automobile engine. The valve was tested on 110 engines and the mean pressure was 4.6 lbs/square inch. Assume the standard deviation is known to be 0.8. If the valve was designed to produce a mean pressure of 4.5 lbs/square inch...

### Complete the sentences as you like with a correct comparative. 1-You run _________ me. 2-She sleeps________ her brother. 3-My parents travel __________ me. 4-She always goes to bed _________ us. 5-We arrived _______ them.

Complete the sentences as you like with a correct comparative. 1-You run _________ me. 2-She sleeps________ her brother. 3-My parents travel __________ me. 4-She always goes to bed _________ us. 5-We arrived _______ them....

### According to rotter's expectancy theory, what sorts of conditions would lead to someone having a studious personality? 1. placing a high value on academic success 2. an internal locus of control 3. the expectancy that studying will lead to good grades

According to rotter's expectancy theory, what sorts of conditions would lead to someone having a studious personality? 1. placing a high value on academic success 2. an internal locus of control 3. the expectancy that studying will lead to good grades...

### Describe three advantages an individual organism might have by living in a population with a clumped dispersal pattern

Describe three advantages an individual organism might have by living in a population with a clumped dispersal pattern...

### Do you feel Shay's Rebellion was successful? Using two pieces of evidence, explain your answer.

Do you feel Shay's Rebellion was successful? Using two pieces of evidence, explain your answer....

### And an experiment which variable changes in response to the manipulation of another variable

And an experiment which variable changes in response to the manipulation of another variable...

### PLS GIVE A STEP BY STEP EXPLANATION 25 POINTS FOR ANSWERING + BRAINLIEST IF YOU GET IT RIGHT The diagram shows 3 identical circles inside a rectangle Each circle touches two other circles and the sides of a rectangle as shown in a diagram The radius of each circle is 24mm. Work out the area of the rectangle Give the correct answer to three significant figures.

PLS GIVE A STEP BY STEP EXPLANATION 25 POINTS FOR ANSWERING + BRAINLIEST IF YOU GET IT RIGHT The diagram shows 3 identical circles inside a rectangle Each circle touches two other circles and the sides of a rectangle as shown in a diagram The radius of each circle is 24mm. Work out the area of the r...

### I spent $4.25 for lunch every school day for a week. On Saturday I spend$5.75 . How much do I spend in all?

I spent $4.25 for lunch every school day for a week. On Saturday I spend$5.75 . How much do I spend in all?...

### What international security issues confront the post cold war world

What international security issues confront the post cold war world...

### Determine next 3 sequences of 1.1, 1.11, 1.111, 1.1111

Determine next 3 sequences of 1.1, 1.11, 1.111, 1.1111...

### Natasha ran 3.1 km. Tonya ran4 meters more than half as far as Natasha. How many meters did Tonya run?

Natasha ran 3.1 km. Tonya ran4 meters more than half as far as Natasha. How many meters did Tonya run?...

### The word which derives from the latin meaning a covering is

The word which derives from the latin meaning a covering is...

### Primates are able to acquire language about as fast as speaking children can.Please select the best answer from the choices provided. O T O Fplease answer correctly :)

Primates are able to acquire language about as fast as speaking children can.Please select the best answer from the choices provided. O T O Fplease answer correctly :)...

### Which of the following is NOT a major difference between "bryophytes" and ALL other plant phyla? a) seedless (bryophytes) vs. seed condition (all others) b) absence (bryophytes) vs. presence (all others) of xylem and phloem c) absence (bryophytes) vs. presence (all others) of differentiated body plan (true roots, stems and leaves) d) haploid (bryophytes) vs. diploid (all others) condition of the conspicuous life e) stage absence (bryophytes) vs. presence (all others) of lignin.

Which of the following is NOT a major difference between "bryophytes" and ALL other plant phyla? a) seedless (bryophytes) vs. seed condition (all others) b) absence (bryophytes) vs. presence (all others) of xylem and phloem c) absence (bryophytes) vs. presence (all others) of differentiated body pla...

### 9(p+2)<=3(3p-5) solve the inequality

9(p+2)<=3(3p-5) solve the inequality...

### Both pyrrole and pyridine are aromatic compounds, and undergo electrophilic aromatic substitution (EAS). Using a resonance argument, predict the regiochemistry of EAS on both pyrrole and pyridine. As part of your argument, you must draw resonance structures for the arenium ion leading to each possible regiochemistry, and compare the stabilities of the resonance hybrids. In addition, make a reasoned statement about whether you think each one would react faster or slower than benzene and why.

Both pyrrole and pyridine are aromatic compounds, and undergo electrophilic aromatic substitution (EAS). Using a resonance argument, predict the regiochemistry of EAS on both pyrrole and pyridine. As part of your argument, you must draw resonance structures for the arenium ion leading to each possib...

### Conclusion for primary memory

Conclusion for primary memory...

### A well-regulated militia, being necessary to the security of a free state, the right of the people to keep and bear arms (have weapons), shall not be infringed. Source: 2nd Amendment, U.S. Constitution What does this source tell you about the United States at the time of its conception (beginning)?

A well-regulated militia, being necessary to the security of a free state, the right of the people to keep and bear arms (have weapons), shall not be infringed. Source: 2nd Amendment, U.S. Constitution What does this source tell you about the United States at the time of its conception (beginning)?...
### If a firm holds a pure monopoly in the market and is able to sell 5 units of output at $4.00 per unit and 6 units of output at$3.90 per unit, it will produce and sell the sixth unit if its marginal cost is what? Hint: What is the marginal revenue of the sixth unit of output?
If a firm holds a pure monopoly in the market and is able to sell 5 units of output at $4.00 per unit and 6 units of output at$3.90 per unit, it will produce and sell the sixth unit if its marginal cost is what? Hint: What is the marginal revenue of the sixth unit of output?...


text:
An electron (mass 9.108 x 10-31 kg, charge 1.602 x 10-19 C) is moving in a vacuum ina region wehre the intensity of the magnetic field is10-3  T. At agiven moment, the electron's velocity is

a) Calculate the radius of the electron's spiraltrajectory.
b) Calculate the period of the rotation in the y-zplane.
c) Calculate the pitch of the spiral (the distance traveled inthe direction in thecourse of a completely revolution in the y-z plane).


text:
# Is the absolute drain current max rating of 8 A the total for 2 elements?

Latest Updated:10/01/2007

## Question:

The uPA2755A power MOSFET is a product with 2 elements, but is the absolute maximum rating of drain current of 8 A the total for the two elements?


text:
## Pat(A) 1091. Acute Stroke (30)

### 1091. Acute Stroke (30)

One important factor to identify acute stroke (急性脑卒中) is the volume of the stroke core. Given the results of image analysis in which the core regions are identified in each MRI slice, your job is to calculate the volume of the stroke core.

Input Specification:

Each input file contains one test case. For each case, the first line contains 4 positive integers: M, N, L and T, where M and N are the sizes of each slice (i.e. pixels of a slice are in an M by N matrix, and the maximum resolution is 1286 by 128); L (<=60) is the number of slices of a brain; and T is the integer threshold (i.e. if the volume of a connected core is less than T, then that core must not be counted).

Then L slices are given. Each slice is represented by an M by N matrix of 0's and 1's, where 1 represents a pixel of stroke, and 0 means normal. Since the thickness of a slice is a constant, we only have to count the number of 1's to obtain the volume. However, there might be several separated core regions in a brain, and only those with their volumes no less than T are counted. Two pixels are "connected" and hence belong to the same region if they share a common side, as shown by Figure 1 where all the 6 red pixels are connected to the blue one.

Figure 1
Output Specification:

For each case, output in a line the total volume of the stroke core.

Sample Input:
3 4 5 2
1 1 1 1
1 1 1 1
1 1 1 1
0 0 1 1
0 0 1 1
0 0 1 1
1 0 1 1
0 1 0 0
0 0 0 0
1 0 1 1
0 0 0 0
0 0 0 0
0 0 0 1
0 0 0 1
1 0 0 0

Sample Output:
26

### 代码

#include "iostream"
#include "queue"
using namespace std;

struct node{
int l;
int m;
int n;
};

int G[65][1300][130];
int M,N,L,T;
int ans = 0;
int X[6] = {1, 0, 0, -1, 0, 0};
int Y[6] = {0, 1, 0, 0, -1, 0};
int Z[6] = {0, 0, 1, 0, 0, -1};

bool judge(int x, int y, int z) {
if(x < 0 || x >= L || y < 0 || y >= M || z < 0 || z >= N) return false;
if(G[x][y][z] == 0) return false;
return true;
}

void init(){
cin>>M>>N>>L>>T;
int i,j,k;
for(i = 0; i < L; i++){
for(j = 0; j < M; j++){
for(k = 0; k < N; k++)
scanf("%d",&G[i][j][k]);
}
}
}

int bfs(int x, int y, int z){
queue<struct node> que;
int cnt = 0;
struct node temp;
temp.l = x;
temp.m = y;
temp.n = z;
G[x][y][z] = 0;
que.push(temp);
while(!que.empty()){
struct node top = que.front();
que.pop();
cnt ++;
for(int i = 0; i < 6; i++) {
int tx = top.l + X[i];
int ty = top.m + Y[i];
int tz = top.n + Z[i];
if(judge(tx, ty, tz)) {
G[tx][ty][tz] = 0;
temp.l = tx, temp.m = ty, temp.n = tz;
que.push(temp);
}
}
}
return (cnt>=T)?cnt:0;
}

int main(){
init();
int i,j,k;
for(i = 0; i < L; i++){
for(j = 0; j < M; j++){
for(k = 0; k < N; k++)
if(G[i][j][k])
ans += bfs(i,j,k);
}
}
cout<<ans<<endl;
//system("pause");
}

还没有人评论...


text:
# A SHM problem of floating

1. Feb 15, 2007

### crossfacer

1. The problem statement, all variables and given/known data
There is a ship of mass M floating on a river. The upper portion of the ship has a uniform cross-sectional area A and the density of water is d. Now the ship is displaced a further depth y into the water and released.
What is the resultant force acting on the ship when it is displaced a further depth y into the water?

3. The attempt at a solution
d = m / v where m is the mass of water and v is volume of water being pushed by ship
m = d (A*y)
net F= Mg - mg
net F= g [ M - d (A*y) ]

The correct answer is F= - dgAy. Why isn't the weight of the ship taken into account?
Thank you so much!

2. Feb 15, 2007

### AlephZero

The ship is floating on the river. So the buoyancy force for the part of the ship that was below the waterline when y = 0 equals its weight Mg.

3. Feb 15, 2007

### chaoseverlasting

Initially, $$F_b=dAy_o$$ where $$y_o$$ is the intial depth of the ship. The depth of the ship when its pushed down by a length dy (or y) is $$y_o+dy (or y_o+y)$$


text:
# Sampling rate conversion for audio using ffmpegwrapper in python

I have many audio files @ 22kHz. I want to convert it to 44.1kHz. Since I have many files to convert, I am looking for an easy solution. I came across ffmpegwrapper for python. I installed the package for python. But I couldnt find out the command to resample. Can anyone please help me ? This is the link for the wrapper. https://pypi.python.org/pypi/ffmpegwrapper

Use SoX to easily convert your files in one go.

Here are some examples:

Alternatively, if you want to do this from Python, use librosa. An example:

By default, librosa will resample the signal to 22050Hz.

You can change this behavior by saying:


text:
1. limit cotx

here is the problem

lim x approaches pi of cotx

would anyone please tell me how to prove the limit doesnt exist by using sided limit from both sides. my prof told me that i have to show x approaches PI from the left and from the right.

thank you

2. Yes, you have to do what your professor told you to do. Recall that:

$\cot{x} = \frac{\cos{x}}{\sin{x}}$

======

EXTRA:

$\sin{\pi} = 0$

$\cos{\pi} = -1$

3. thank you for your help. i knew what you said but i got stuck in showing x approaches PI from the left and from the right


text:
2 s / 256 MB

# #83. [CSP-S2 2019] D1T3 树上的数

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


text:
# Absolute Value of Signed Measure Bounded Above by Variation

## Theorem

Let $\struct {X, \Sigma}$ be a measurable space.

Let $\mu$ be a signed measure on $\struct {X, \Sigma}$.

Let $\size \mu$ be the variation of $\mu$.

Then:

$\size {\map \mu A} \le \map {\size \mu} A$

for each $A \in \Sigma$.

## Proof

Let $\tuple {\mu^+, \mu^-}$ be the Jordan decomposition of $\mu$.

Then:

$\mu = \mu^+ - \mu^-$

and:

$\size \mu = \mu^+ + \mu^-$

We have:

 $\ds \size {\map \mu A}$ $=$ $\ds \size {\map {\mu^+} A - \map {\mu^-} A}$ $\ds$ $\le$ $\ds \size {\map {\mu^+} A} + \size {\map {\mu^-} A}$ Triangle Inequality $\ds$ $=$ $\ds \map {\mu^+} A + \map {\mu^-} A$ since $\mu^+ \ge 0$ and $\mu^- \ge 0$ $\ds$ $=$ $\ds \map {\size \mu} A$

$\blacksquare$


text:
## Octave – Grafici – XII – 76

Copio qui continuando da qui.

Uso della proprietà interpreter
All text objects—such as titles, labels, legends, and text—include the property "interpreter" that determines the manner in which special control sequences in the text are rendered.
The interpreter property can take three values: "none", "tex", "latex". If the interpreter is set to "none" then no special rendering occurs—the displayed text is a verbatim copy of the specified text. Currently, the "latex" interpreter is not implemented and is equivalent to "none".
The "tex" option implements a subset of TeX functionality when rendering text. This allows the insertion of special glyphs such as Greek characters or mathematical symbols. Special characters are inserted by using a backslash (\) character followed by a code, as shown in Table 15.1 [qui, non la copio].

Note that for on-screen display the interpreter property is honored by all graphics toolkits. However for printing, only the "gnuplot" toolkit renders TeX instructions.
Besides special glyphs, the formatting of the text can be changed within the string by using the codes

• \bf Bold font
• \it Italic font
• \sl Oblique Font
• \rm Normal font

These codes may be used in conjunction with the { and } characters to limit the change to a part of the string. For example, xlabel ('{\bf H} = a {\bf V}') where the character ‘a‘ will not appear in bold font. Note that to avoid having Octave interpret the backslash character in the strings, the strings themselves should be in single quotes.
It is also possible to change the fontname and size within the text

• \fontname{fontname} Specify the font to use
• \fontsize{size} Specify the size of the font to use

The color of the text may also be changed inline using either a string (e.g., "red") or numerically with a Red-Green-Blue (RGB) specification (.e.g., [1 0 0], also red).

• \color{color} Specify the color as a string
• \color[rgb]{R G B} Specify the color numerically

Finally, superscripting and subscripting can be controlled with the ‘^‘ and ‘_‘ characters. If the ‘^‘ or ‘_‘ is followed by a { character, then all of the block surrounded by the { } pair is superscripted or subscripted. Without the { } pair, only the character immediately following the ‘^‘ or ‘_‘ is changed.
E qui viene la famosa Tabella che non riporto, è qui.

A complete example showing the capabilities of the extended text

x = 0:0.01:3;
plot (x, erf (x));
hold on;
plot (x,x,"r");
axis ([0, 3, 0, 1]);
text (0.65, 0.6175, strcat ('\leftarrow x = {2/\surd\pi', ' {\fontsize{16}\int_{\fontsize{8}0}^{\fontsize{8}x}}', ' e^{-t^2} dt} = 0.6175'))

Continuo, passo qui.

Stampare e salvare grafici
The print command allows you to send plots to you printer and to save plots in a variety of formats. For example, print -dpsc prints the current figure to a color PostScript printer. And, print -deps foo.eps saves the current figure to an encapsulated PostScript file called foo.eps.

Nonostante il warning il file foo.eps viene prodotto (13.4 MB), questo

Viene prodotto anche con estensione sbagliata, ovvamente sempre postscript. Per ottenere il .png il comando è print -dpng foo.png (572 kB).

The different graphic toolkits have different print capabilities. In particular, the OpenGL based toolkits such as fltk do not support the "interpreter" property of text objects. This means special symbols drawn with the "tex" interpreter will appear correctly on-screen but will be rendered with interpreter "none" when printing. Switch graphics toolkits for printing if this is a concern.

Function File: print ()
Function File: print (options)
Function File: print (filename, options)
Function File: print (h, filename, options)

Print a plot, or save it to a file.
Both output formatted for printing (PDF and PostScript), and many bitmapped and vector image formats are supported.
filename defines the name of the output file. If the file name has no suffix, one is inferred from the specified device and appended to the file name. If no filename is specified, the output is sent to the printer.
h specifies the handle of the figure to print. If no handle is specified the current figure is used.
For output to a printer, PostScript file, or PDF file, the paper size is specified by the figure’s papersize property. The location and size of the image on the page are specified by the figure’s paperposition property. The orientation of the page is specified by the figure’s paperorientation property.
The width and height of images are specified by the figure’s paperpositon(3:4) property values.

The print command supports many options (segue tbella kilometrica che non riporto).

Esempi

Print to a file using the pdf device.
figure (1);
clf ();
surf (peaks);
print figure1.pdf

Print to a file using jpg device.
clf ();
surf (peaks);
print -djpg figure2.jpg

Print to a file using png device.
clf ();
surf (peaks);
print -dpng ping.png

Print to printer named PS_printer using ps format.
clf ();
surf (peaks);
print -dpswrite -PPS_printer Ovviamente PS_printer deve esistere; io ottengo questo:

Function File: saveas (h, filename)
Function File: saveas (h, filename, fmt)

Save graphic object h to the file filename in graphic format fmt.
fmt should be one of the following formats: ps, eps, ipg, png, emf, pdf.
All device formats specified in print may also be used. If fmt is omitted it is extracted from the extension of filename. The default format is "pdf".

Function File: orient (orientation)
Function File: orient (hfig, orientation)
Function File: orientation = orient ()
Function File: orientation = orient (hfig)

Query or set the print orientation for figure hfig.
Valid values for orientation are "portrait", "landscape", and "tall".
The "landscape" option changes the orientation so the plot width is larger than the plot height. The "paperposition" is also modified so that the plot fills the page, while leaving a 0.25 inch border.
The "tall" option sets the orientation to "portrait" and fills the page with the plot, while leaving a 0.25 inch border.
The "portrait" option (default) changes the orientation so the plot height is larger than the plot width. It also restores the default "paperposition" property.
When called with no arguments, return the current print orientation.
If the argument hfig is omitted, then operate on the current figure returned by gcf.

clf ();
h = surf (peaks);
saveas (h, "p-ls.png", "png")

clf ();
orient ("landscape")
h = surf (peaks);
saveas (h, "ls.png", "png")

clf ();
orient ("portrait")
h = surf (peaks);
saveas (h, "po.png", "png")

Sì, a me sembrano invertiti, ma è così (pare) 😳

print and saveas are used when work on a plot has finished and the output must be in a publication-ready format. During intermediate stages it is often better to save the graphics object and all of its associated information so that changes—to colors, axis limits, marker styles, etc.—can be made easily from within Octave. The hgsave/hgload commands can be used to save and re-create a graphics object.
Qui dissento, ma forse sono solo io…

Function File: hgsave (filename)
Function File: hgsave (h, filename)
Function File: hgsave (h, filename, fmt)

Save the graphics handle h to the file filename in the format fmt.
If unspecified, h is the current figure as returned by gcf.
When filename does not have an extension the default filename extension .ofig will be appended.
If present, fmt should be one of the following:

• -binary, -float-binary
• -hdf5, -float-hdf5
• -V7, -v7, -7, -mat7-binary
• -V6, -v6, -6, -mat6-binary
• -text
• -zip, -z

Function File: h = hgload (filename)
Load the graphics object in filename into the graphics handle h.
If filename has no extension, Octave will try to find the file with and without the standard extension of .ofig.

e poi

Posta un commento o usa questo indirizzo per il trackback.


text:
The Laboratory for Computational Physiology (LCP) at MIT hosts several large-scale databases of hospital intensive care units (ICUs), two of which can be either downloaded in full (MIMIC-III and eICU ) or as demo subsets (MIMIC-III demo and eICU demo), while a third data set is available only in full (HiRID ). While demo data sets are freely available, full download requires credentialed access which can be gained by applying for an account with PhysioNet . Even though registration is required, the described datasets are all publicly available. With AmsterdamUMCdb , a non-PhysioNet hosted data source is available as well. As with the PhysioNet datasets, access is public but has to be granted by the data collectors.

data

Format

The exported data environment contains all datasets that have been made available to ricu. For datasets that are attached during package loading (see attach_src()), shortcuts to the datasets are set up in the package namespace, allowing the object ricu::data::mimic_demo to be accessed as ricu::mimic_demo (or in case the package namespace has been attached, simply as mimic_demo). Datasets that are made available after the package namespace has been sealed will have their proxy object by default located in .GlobalEnv. Datasets are represented by src_env objects, while individual tables are src_tbl and do not represent in-memory data, but rather data stored on disk, subsets of which can be loaded into memory.

Details

Setting up a dataset for use with ricu requires a configuration object. For the included datasets, configuration can be loaded from

system.file("extdata", "config", "data-sources.json", package = "ricu")

by calling load_src_cfg() and for dataset that are external to ricu, additional configuration can be made available by setting the environment variable RICU_CONFIG_PATH (for more information, refer to load_src_cfg()). Using the dataset configuration object, data can be downloaded (download_src()), imported (import_src()) and attached (attach_src()). While downloading and importing are one-time procedures, attaching of the dataset is repeated every time the package is loaded. Briefly, downloading loads the raw dataset from the internet (most likely in .csv format), importing consists of some preprocessing to make the data available more efficiently (by converting it to .fst format) and attaching sets up the data for use by the package. For more information on the individual steps, refer to the respective documentation pages.

A dataset that has been successfully made available can interactively be explored by typing its name into the console and individual tables can be inspected using the $ function. For example for the MIMIC-III demo dataset and the icustays table, this gives mimic_demo  ## <mimic_demo_env[25]> ## admissions callout caregivers chartevents ## [129 x 19] [77 x 24] [7,567 x 4] [758,355 x 15] ## cptevents d_cpt d_icd_diagnoses d_icd_procedures ## [1,579 x 12] [134 x 9] [14,567 x 4] [3,882 x 4] ## d_items d_labitems datetimeevents diagnoses_icd ## [12,487 x 10] [753 x 6] [15,551 x 14] [1,761 x 5] ## drgcodes icustays inputevents_cv inputevents_mv ## [297 x 8] [136 x 12] [34,799 x 22] [13,224 x 31] ## labevents microbiologyevents outputevents patients ## [76,074 x 9] [2,003 x 16] [11,320 x 13] [100 x 8] ## prescriptions procedureevents_mv procedures_icd services ## [10,398 x 19] [753 x 25] [506 x 5] [163 x 6] ## transfers ## [524 x 13]  mimic_demo$icustays

## # <mimic_tbl>: [136 x 12]
## # ID options:  subject_id (patient) < hadm_id (hadm) < icustay_id (icustay)
## # Defaults:    intime (index), last_careunit (val)
## # Time vars:   intime, outtime
##     row_id subject_id hadm_id icustay_id dbsource first_careunit last_careunit
##      <int>      <int>   <int>      <int> <chr>    <chr>          <chr>
##   1  12742      10006  142345     206504 carevue  MICU           MICU
##   2  12747      10011  105331     232110 carevue  MICU           MICU
##   3  12749      10013  165520     264446 carevue  MICU           MICU
##   4  12754      10017  199207     204881 carevue  CCU            CCU
##   5  12755      10019  177759     228977 carevue  MICU           MICU
## ...
## 132  42676      44083  198330     286428 metavis~ CCU            CCU
## 133  42691      44154  174245     217724 metavis~ MICU           MICU
## 134  42709      44212  163189     239396 metavis~ MICU           MICU
## 135  42712      44222  192189     238186 metavis~ CCU            CCU
## 136  42714      44228  103379     217992 metavis~ SICU           SICU
## # ... with 126 more rows, and 5 more variables: first_wardid <int>,
## #   last_wardid <int>, intime <dttm>, outtime <dttm>, los <dbl>

Table subsets can be loaded into memory for example using the base::subset() function, which uses non-standard evaluation (NSE) to determine a row-subsetting. This design choice stems form the fact that some tables can have on the order of 10^8 rows, which makes loading full tables into memory an expensive operation. Table subsets loaded into memory are represented as data.table objects. Extending the above example, if only ICU stays corresponding to the patient with subject_id == 10124 are of interest, the respective data can be loaded as

subset(mimic_demo\$icustays, subject_id == 10124)

##    row_id subject_id hadm_id icustay_id dbsource first_careunit last_careunit
## 1:  12863      10124  182664     261764  carevue           MICU          MICU
## 2:  12864      10124  170883     222779  carevue           MICU          MICU
## 3:  12865      10124  170883     295043  carevue            CCU           CCU
## 4:  12866      10124  170883     237528  carevue           MICU          MICU
##    first_wardid last_wardid              intime             outtime     los
## 1:           23          23 2192-03-29 10:46:51 2192-04-01 06:36:00  2.8258
## 2:           50          50 2192-04-16 20:58:32 2192-04-20 08:51:28  3.4951
## 3:            7           7 2192-04-24 02:29:49 2192-04-26 23:59:45  2.8958
## 4:           23          23 2192-04-30 14:50:44 2192-05-15 23:34:21 15.3636

Much care has been taken to make ricu extensible to new datasets. For example the publicly available ICU database AmsterdamUMCdb provided by the Amsterdam University Medical Center, currently is not part of the core datasets of ricu, but code for integrating this dataset is available on github.

MIMIC-III

The Medical Information Mart for Intensive Care (MIMIC) database holds detailed clinical data from roughly 60,000 patient stays in Beth Israel Deaconess Medical Center (BIDMC) intensive care units between 2001 and 2012. The database includes information such as demographics, vital sign measurements made at the bedside (~1 data point per hour), laboratory test results, procedures, medications, caregiver notes, imaging reports, and mortality (both in and out of hospital). For further information, please refer to the MIMIC-III documentation.

The corresponding demo dataset contains the full data of a randomly selected subset of 100 patients from the patient cohort with conformed in-hospital mortality. The only notable data omission is the noteevents table, which contains unstructured text reports on patients.

eICU

More recently, Philips Healthcare and LCP began assembling the eICU Collaborative Research Database as a multi-center resource for ICU data. Combining data of several critical care units throughout the continental United States from the years 2014 and 2015, this database contains de-identified health data associated with over 200,000 admissions, including vital sign measurements, care plan documentation, severity of illness measures, diagnosis information, and treatment information. For further information, please refer to the eICU documentation .

For the demo subset, data associated with ICU stays for over 2,500 unit stays selected from 20 of the larger hospitals is included. An important caveat that applied to the eICU-based datasets is considerable variability among the large number of hospitals in terms of data availability.

HiRID

Moving to higher time-resolution, HiRID is a freely accessible critical care dataset containing data relating to almost 34,000 patient admissions to the Department of Intensive Care Medicine of the Bern University Hospital, Switzerland. The dataset contains de-identified demographic information and a total of 681 routinely collected physiological variables, diagnostic test results and treatment parameters, collected during the period from January 2008 to June 2016. Dependent on the type of measurement, time resolution can be on the order of 2 minutes.

AmsterdamUMCdb

With similar time-resolution (for vital-sign measurements) as HiRID, AmsterdamUMCdb contains data from 23,000 admissions of adult patients from 2003-2016 to the department of Intensive Care, of Amsterdam University Medical Center. In total, nearly 10^9^ individual observations consisting of vitals signs, clinical scoring systems, device data and lab results data, as well as nearly 5*10^6^ million medication entries, alongside de-identified demographic information corresponding to the 20,000 individual patients is spread over 7 tables.

MIMIC-IV

With the recent v1.0 release of MIMIC-IV, experimental support has been added in ricu. Building on the success of MIMIC-III, this next iteration contains data on patients admitted to an ICU or the emergency department between 2008 - 2019 at BIDMC. Therefore, relative to MIMIC-III, patients admitted prior to 2008 (whose data is stored in a CareVue-based system) has been removed, while data onward of 2012 has been added. This simplifies data queries considerably, as the CareVue/MetaVision data split in MIMIC-III no longer applies. While addition of ED data is planned, this is not part of the initial v1.0 release and currently is not supported by ricu. For further information, please refer to the MIMIC-III documentation .

References

Johnson, A., Pollard, T., & Mark, R. (2016). MIMIC-III Clinical Database (version 1.4). PhysioNet. https://doi.org/10.13026/C2XW26.

MIMIC-III, a freely accessible critical care database. Johnson AEW, Pollard TJ, Shen L, Lehman L, Feng M, Ghassemi M, Moody B, Szolovits P, Celi LA, and Mark RG. Scientific Data (2016). DOI: 10.1038/sdata.2016.35.

Johnson, A., Pollard, T., Badawi, O., & Raffa, J. (2019). eICU Collaborative Research Database Demo (version 2.0). PhysioNet. https://doi.org/10.13026/gxmm-es70.

The eICU Collaborative Research Database, a freely available multi-center database for critical care research. Pollard TJ, Johnson AEW, Raffa JD, Celi LA, Mark RG and Badawi O. Scientific Data (2018). DOI: http://dx.doi.org/10.1038/sdata.2018.178.

Faltys, M., Zimmermann, M., Lyu, X., Hüser, M., Hyland, S., Rätsch, G., & Merz, T. (2020). HiRID, a high time-resolution ICU dataset (version 1.0). PhysioNet. https://doi.org/10.13026/hz5m-md48.

Hyland, S.L., Faltys, M., Hüser, M. et al. Early prediction of circulatory failure in the intensive care unit using machine learning. Nat Med 26, 364–373 (2020). https://doi.org/10.1038/s41591-020-0789-4

Thoral PJ, Peppink JM, Driessen RH, et al (2020) AmsterdamUMCdb: The First Freely Accessible European Intensive Care Database from the ESICM Data Sharing Initiative. https://www.amsterdammedicaldatascience.nl.

Elbers, Dr. P.W.G. (Amsterdam UMC) (2019): AmsterdamUMCdb v1.0.2. DANS. https://doi.org/10.17026/dans-22u-f8vd

Johnson, A., Bulgarelli, L., Pollard, T., Horng, S., Celi, L. A., & Mark, R. (2021). MIMIC-IV (version 1.0). PhysioNet. https://doi.org/10.13026/s6n6-xd98.

Goldberger, A., Amaral, L., Glass, L., Hausdorff, J., Ivanov, P. C., Mark, R., ... & Stanley, H. E. (2000). PhysioBank, PhysioToolkit, and PhysioNet: Components of a new research resource for complex physiologic signals. Circulation (Online). 101 (23), pp. e215–e220.


text:
# Once a Week (magazine)/Series 1/Volume 2/About cotton

More cotton is bought and sold at Liverpool than at any other place in the world. The locality where cotton brokers “most do congregate,” is the area enclosed by the Liverpool Exchange-buildings, on the east side of which they may be seen gathered together every forenoon. Although “the flags” is their particular meeting-place, however, they are not in the habit of behaving after the manner of the sharebrokers hard by, of whom it is related, that having subjected the curious or unwary invader of their domain to the extremities of contumely and ill-usage, they finally deposit him outside the sacred precincts, presenting an appearance strongly contrasting with that which he bore previously to his ill-advised entry. It would probably strike a stranger on his first visit to “the flags,” that there was no such appearance of hurry or bustle as his previous notions of the magnitude of the cotton-trade would have led him to expect; and he would perhaps be tempted to suppose from finding those whom he should meet there perfectly willing to enter into conversation on the current topics of the day (occasionally interrupted, it is true, to answer an inquiry as to Bowed at 6${\displaystyle {\frac {5}{8}}}$, or Surat at 5 to 5${\displaystyle {\frac {1}{8}}}$), and from his observation of the easy style of talk going on around him, that he had happened to make his appearance at a time when no particular business was going forward; and yet very likely he would be told on inquiry that the sales for the day would probably be 8000 or 9000 bales—which latter is about the average—worth perhaps 100,000l. By way of getting a clearer idea of the manner in which this amount of business is transacted, let us take the liberty of paying a visit to one of the sale-rooms in the immediate vicinity of the Exchange area: and here on entering we see conveniently disposed a large number of brown paper parcels, a glance at the open ends of which is sufficient to inform us that they are cotton samples. We do not wait here long before an individual enters, and says interrogatively to the presiding salesman, “Bowed,”—or it maybe Orleans or Mobile—“six three?” which demand, being interpreted, signifies that the inquirer is a buyer of Bowed—so called from a former method of cleaning by means of a bow—Orleans, or Mobile cotton, at 6${\displaystyle {\frac {3}{4}}}$d. per pound. Sundry of the brown paper parcels are opened and spread out before him, showing that every one of them contains perhaps 25 pieces of cotton, each piece the sample of a bale; and after a very brief inspection, he desires that certain of these may be “sent in to him.” This he does in order that he may view them at “his own light,” and may compare them with other samples which in his tour round the market he has seen and had sent to him from various sale-rooms. It may be here explained, that these sale-rooms are plentifully supplied with north or east light, and that each broker, from custom, is able to judge better as to the colour and general appearance of the cotton—on which in a measure its value and suitability for his particular purpose depend—in his own sale-room than elsewhere. West or south light is never used.

Other buyers enter, in rapid succession, the sample-room in which we have taken up our position, and inquiries are made for cotton of various kinds and prices: for Maranhams, Pernams (a contraction for Pernambuco), or Bahias; for Egyptians, or possibly for Dhollerahs, Comptas, Tinnevellies, or Oomrawhuttees, all which strange sounds represent varieties of East Indian growth. It will be observed, that the word cotton is seldom, if ever, mentioned; contraction is the order of the day; time and breath are saved by asking for “Orleans,” or “Maranham.” It will also be noticed that American descriptions are vastly more inquired for than any other kinds; which arises from a reason analogous to that assigned as the cause of white sheep eating so much more than black ones; viz., that there arc so many more of them. The differences in the requirements of buyers cannot fail to have been remarked: thus, one “doesn’t care for colour, but must have staple;” another “isn’t so particular about staple, but wants colour;” another “can’t do with sand” (on which point more hereafter); and so on. Amongst other things, it is very likely blue or red cotton will be spoken of. But is not all cotton white? Broadly speaking, no doubt it is; but there are various tints of blue, yellow, and red, not certainly approaching indigo on the one hand, or scarlet on the other; but still sufficiently marked to be readily distinguished by anyone when attention is drawn to the subject, and comparison instituted between different samples; and perceptible at a glance to the practised eye of the broker. From all these inquiries it may be gathered that the value of cotton depends upon the length, strength, and fineness of the fibre or “staple,” modified by conditions of colour and cleanliness. Accordingly, with reference to the first of these points, the article is divided into “long” and “short” stapled. To the former of these divisions belongs that class of American called Sea Island, which takes its name from the place of its growth, and which is the finest and highest priced cotton known; also all cotton from Brazil, the West Indies, and Egypt. The second division includes all kinds of American, save Sea Island, and all descriptions of East Indian. It has been already stated that America supplies by far the largest quantity of cotton; in proof whereof, I here venture to present some figures, at the prospect of which, however, as they shall be few in number, I respectfully submit that no lady or gentleman who may honour me by reading this paper has any cause for alarm. During the year 1859, the total import into the kingdom was 2,828,000 bales, of which 2,085,000 were American, 510,000 East Indian, leaving only 233,000 as import from Brazil, the West Indies, and Egypt.

Of these 2,828,000, 2,709,000 were received into Liverpool, against about 119,000 into London, Glasgow, and Hull, the only other places which import the article. One week’s sales in Liverpool have before now been as much as the whole of last year’s import into the rest of the United Kingdom. A price current, now before the writer, gives nearly one hundred quotations of different descriptions and grades, varying from 4d. a pound for ordinary Surat, to 2s. for fine Sea Island. The grades quoted in each different description of cotton are, “ordinary,” “middling,” “fair,” “good fair,” “good,” and “fine,” which one would suppose to be a division sufficiently nice. But in practice, a much more minute subdivision is used, and it is common enough to hear brokers speak of “low and good ordinary,” “barely middling,” “middling fair,” “fully fair,” and so on.

These explanations may be supposed to have been offered in the sale-room to which we are paying an imaginary visit, and the buyer whom we first saw, has in the mean time examined the samples sent in to him, and now comes to make an offer. “We’ll give you 6${\displaystyle {\frac {5}{8}}}$ for the B A 100 by the Mississippi,” says he. “Can’t take it.” “Well, will ${\displaystyle {\frac {11}{16}}}$ths buy them?” “I don’t know, but I’ll see our principal, and if you’ll call in five minutes I’ll give you an answer.” Accordingly, when the buyer calls at the expiration of that time, he is told, “We’ll put those hundred down to you at 6${\displaystyle {\frac {11}{16}}}$ths:” he gives the name of the spinner for whom he acts, and the affair is settled. This is all that passes in a transaction involving perhaps 1200l. or 1400l; nay, in busy times, thousands of bales are often bought on the first inspection of the samples, without leaving the spot. No contract other than an oral one passes between buyer and seller: such bargains are annually entered into to the amount of dozens of millions sterling, yet disputes are almost unknown, and are, when they occur, generally settled without trouble or expense by reference to brokers not interested in the disputed transactions.

Payment for cotton bought, is due (less three months’ interest) in ten days from the date of purchase. In the supposed sale just recorded, the buyer paid for the cotton ${\displaystyle {\frac {1}{16}}}$th of a penny per pound less than the price first asked, and if the seller had not made this concession, the transaction would probably not have taken place; and though at first ${\displaystyle {\frac {1}{16}}}$th of a penny appears a trifling matter, yet when it is stated that the average weight of American bales is about 440 lbs., it will be seen that on one hundred such, this ${\displaystyle {\frac {1}{16}}}$ths represents to the spinner a saving of between 11l. and 12l., sufficient to pay part of the carriage to his mill, besides his broker’s commission for buying, viz. 10s. per 100l. value. This does not seem a very large remuneration, yet a little calculation shows that the buying and selling commission on the average daily sales of 9000 bales must amount to nearly 1000l. per diem, or at the rate of more than 300,000l. per annum. In addition to this commission, the samples are for the most part, after they have served their purpose, a perquisite of the broker;—no insignificant one either, though each separate sample weighs but a few ounces; it being understood that the yearly value to many firms is sufficient to defray all their counting-house expenses.

We noticed that many of the buyers, in making known their wants, objected to “sand,” and it was intimated that there was something further to be stated on this point. Of course everybody has heard of what is called the San Juan difficulty; but not everybody, perhaps, has heard of another dispute respecting American territory which is now in progress. The American nation not being particularly ready to cede to Great Britain, or to any other Power, that to which it conceives it has any claim, it will probably surprise many people to be told that a large portion of American soil has lately passed into British possession; and not only so, but that it is absolutely in England at the present moment, though it must be confessed that England has paid pretty dearly for its acquisition. It was not to be expected that an article of such importance as cotton could escape the usual lot, and remain free from adulteration. Accordingly, when the spinner comes to open and inspect his purchases at the mill, he frequently finds concealed therein substances which are certainly not cotton. Formerly flint stones were the principal articles selected as substitutes; and the manufacturer used often to discover that instead of the “fair bowed” which he had bought and paid for, he was favoured with a considerable weight of geological specimens. But it seems at length to have struck certain individuals on the other side of the Atlantic, that this was at best but a coarse and vulgar fraud, unworthy of an enlightened age and people, and that it was possible to carry out the principle of sophistication on a far more extended scale, and in a much more refined manner.

Accordingly the system of “sanding” sprung up, and instead of bales consisting of American cotton, they are frequently found to consist of America itself, to the extent of 10, 20, or in many instances of more than 30 per cent.

The extent to which this practice has reached may be imagined, when it is known that, taking the adulteration at 10 per cent. on the import of the last crop, which is stated to be a very low estimate, a quantity of sand equal in weight to more than 200,000 bales, or 40,000 tons, is found to have been bought and paid for as cotton by Great Britain, at an expense of upwards of 2,000,000l. sterling; and that there are now lying at Liverpool at least 100,000 bales of this sanded cotton, which spinners will not buy at any price.

But it may be asked, “cannot they purchase it at an allowance in price proportionate to the amount of adulteration?” To this it must be answered that cotton is now bought by sample and not by inspection of the bulk of the article, which indeed would be almost impracticable from the nature of the packages and other causes. When the cotton is warehoused on its arrival from abroad, a sample is taken from each of the bales, but these are pressed so hard, that it is impossible to penetrate more than a few inches into them. If, therefore, as is generally the case, the surface layer be clean cotton, it is evident that the sample can be of no value as an index of quality; but supposing the sample when first drawn to be fair, in the very act of drawing, and at every subsequent examination it is liable to lose some of the sand which it contains, and very shortly to become nothing better than “a delusion, a mockery, and a snare.”

This sandy adulteration, too, is more difficult to deal with than the simpler one before mentioned: when stones are found in cotton bales, it is at once evident that they have no business there; they were not represented in the sample, and were, therefore, not expected; consequently an affidavit is made of their presence, and a claim for compensation is preferred. It is true that a spinner has occasionally suffered the inconvenience of having his mill burned down, in consequence of contact between a flint and the iron machinery; but as this is not of very frequent occurrence it may, perhaps, be taken out of the account.

But as regards sand, which is nominally, if not actually or fairly, represented in the sample, it is plain that if the spinner make a claim on this score, he is liable to be told that the price he paid, was calculated upon the fact of the presence of this sand, and that it would be a point of no small difficulty to settle such a claim equitably, if allowed at all. No wonder, therefore, that there are so many bales of cotton at Liverpool which manufacturers decline to touch.

The money actually paid to America for this stuff does not represent the extent of the evil; freight, warehouse rent, and other charges are all incurred on this mass of useless earth, just as though it were what it ought to be; to say nothing of the damage caused to machinery, and the detriment to the health of the work-people in factories where the adulterated cotton is used.

This fraud has assumed such proportions that active steps are taking for its abatement. It is clear that the check must ultimately come from the consumer, for as long as a market exists for such cotton, so long will people be found to supply it. Whatever may be the result of the means adopted with a view to the suppression of this gigantic swindle, it cannot be denied that its perpetration is a strong argument against our remaining, longer than can be avoided, dependent upon one country for the largest supply of so important an article as cotton.

It is stated by those whose assertions are worthy of respect, that cotton could be grown in Africa, and laid down in England at considerably lower price—quality for quality—than that brought from New Orleans. No doubt time and capital are requisite to render Africa to any extent available as a source of supply; but most certainly 2,000,000l. sterling might have been far better spent in this direction during the past year, than in paying for an enormous quantity of useless and mischievous rubbish, and in thus helping to encourage and support a shameful and systematic fraud.

C. P. William.


text:
## [7860bc]: thys / Locally-Nameless-Sigma / document / root.tex  Maximize  Restore  History

### 104 lines (78 with data), 3.0 kB

 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 \documentclass[11pt,a4paper]{article} \usepackage{isabelle,isabellesym} % further packages required for unusual symbols (see also % isabellesym.sty), use only when needed %\usepackage{amssymb} %for \, \, \, \, \, \, %\, \, \, \, \, %\, \, \ %\usepackage[greek,english]{babel} %option greek for \ %option english (default language) for \, \ %\usepackage[latin1]{inputenc} %for \, \, \, \, %\, \, \ %\usepackage[only,bigsqcap]{stmaryrd} %for \ %\usepackage{eufrak} %for \ ... \, \ ... \ (also included in amssymb) %\usepackage{textcomp} %for \, \ % this should be the last package used \usepackage{pdfsetup} % urls in roman style, theory text in math-similar italics \urlstyle{rm} \isabellestyle{it} \begin{document} \title{Locally Nameless Sigma Calculus} \author{Ludovic Henrio and Florian Kamm\"uller and Bianca Lutz and Henry Sudhof} \maketitle \begin{abstract} We present a Theory of Objects based on the original functional $\varsigma$-calculus by Abadi and Cardelli \cite{AC96a} but with an additional parameter to methods. We prove confluence of the operational semantics following the outline of Nipkow's proof of confluence for the $\lambda$-calculus reusing his general \texttt{Commutation.thy} \cite{nip:01} a generic diamond lemma reduction. We furthermore formalize a simple type system for our $\varsigma$-calculus including a proof of type safety. The entire development uses the concept of Locally Nameless representation for binders \cite{ACPPW:POPL08}. We reuse an earlier proof of confluence \cite{HK:FMOODS07} for a simpler $\varsigma$-calculus based on de Bruijn indices and lists to represent objects. \end{abstract} \tableofcontents % sane default for proof documents \parindent 0pt\parskip 0.5ex % generated text of all theories \input{session} % optional bibliography %\bibliographystyle{abbrv} %\bibliography{root} \bibliographystyle{entcs} \begin{thebibliography}{10} \bibitem{AC96a} M. Abadi and L. Cardelli. \newblock {A Theory of Objects''}. \newblock Springer, New York, 1996. \bibitem{ACPPW:POPL08} B. Aydemir, A, Chargu��raud, B.~C. Pierce, R. Pollack, and S. Weirich. \newblock Engineering formal metatheory. \newblock {\em Princ. of Programming Languages, POPL'08}, ACM, 2008. \bibitem{HK:FMOODS07} L. Henrio and F. Kamm��ller. \newblock A mechanized model of the theory of objects. \newblock {\em Formal Methods for Open Object-Based Distributed Systems,}. LNCS \textbf{4468} Springer, 2007. \bibitem{nip:01} Tobias Nipkow. \newblock{More Church Rosser Proofs.} \newblock{\em Journal of Automated Reasoning}. \newblock{\textbf{26}:51--66, 2001.} \end{thebibliography} \end{document} %%% Local Variables: %%% mode: latex %%% TeX-master: t %%% End: