text:
# Solving second-order ODE using an integrating factor

Solve the ODE
$$\frac{\partial^{2} u }{\partial \eta^{2}} + \frac{\eta}{2\nu} \frac{\partial}{\partial\eta} = 0$$

The book uses integrating factor = $e^{\int\frac{\eta}{2\nu} d\eta}$

Can someone explain from here, how to proceed?

I get $IF = e^\frac{\eta^{2}}{4\nu}$. Multiply this with the ODE. Not sure what to do next? Because the answer the book gives is
$$\frac{\partial u}{\partial \eta} = A e^{\frac{-\eta^{2}}{4/nu}}$$ and I don’t understand how to get this.

#### Solutions Collecting From Web of "Solving second-order ODE using an integrating factor"

$$u”(\eta)+\frac{u'(\eta)\eta}{2\nu}=0\Longleftrightarrow$$

Let $u'(\eta)=w(\eta)$, which gives $u”(\eta)=w'(\eta)$:

$$w'(\eta)=-\frac{\eta w(\eta)}{2\nu}\Longleftrightarrow$$
$$\frac{2vw'(\eta)}{w(\eta)}=-\eta\Longleftrightarrow$$
$$\int\frac{2\nu w'(\eta)}{w(\eta)}\space\text{d}\eta=\int-\eta\space\text{d}\eta\Longleftrightarrow$$
$$2\nu\ln(w(\eta))=-\frac{\eta^2}{2}+\text{C}\Longleftrightarrow$$
$$w(\eta)=e^{-\frac{\eta^2-2\text{C}}{4\nu}}\Longleftrightarrow$$
$$w(\eta)=e^{-\frac{\eta^2+\text{C}}{4\nu}}\Longleftrightarrow$$
$$u'(\eta)=e^{-\frac{\eta^2+\text{C}}{4\nu}}\Longleftrightarrow$$
$$u(\eta)=\int e^{-\frac{\eta^2+\text{C}}{4\nu}}\space\text{d}\eta$$


text:
### DOE accepted the working group’s recommendations covering the use of alternative energy determination methods (AEDMs).

https://facilityexecutive.com/2014/01/u-s-department-energy-rules-finalized-rating-commercial-systems/
DOE accepted the working group’s recommendations covering the use of alternative energy determination methods (AEDMs).

# U.S. DOE Rules Finalized For Rating Commercial Systems

Posted by Heidi Schwartz

The U.S. Department of Energy (DOE) has finalized new methods for rating and certifying commercial air conditioning, heating, water heating, and refrigeration equipment. The negotiated rule, which DOE published on December 31, 2013, was developed by the first working group convened by DOE’s Appliance Standards Rulemaking Federal Advisory Committee (ASRAC).

“DOE’s energy efficiency standards for commercial HVAC, water heating and refrigeration products promise significant energy savings,” said Andrew deLaski, executive director of the Appliance Standards Awareness Project (ASAP). “By accepting the consensus rule developed by the multi-stakeholder working group, DOE now has the tools to implement these important, energy-saving standards fairly and cost-effectively.”

DOE accepted the working group’s recommendations covering the use of alternative energy determination methods (AEDMs). These methods employ computer modeling or mathematical tools to forecast the rated energy performance of products, which eliminates the need to perform costly laboratory tests for each product sold. Used as prescribed by the negotiated rule, AEDMs can accurately predict the rated energy usage of products covered under federal energy efficiency requirements.

format: plain


text:
emacs-devel
[Top][All Lists]

Re: contextual help on new features

 From: Richard Stallman Subject: Re: contextual help on new features Date: Sat, 26 Mar 2005 22:54:05 -0500

    For example, the the first time "\pi" automatically turns into a greek
symbol in the current buffer, you might see a message telling you
what's just happened.  In addition to being informative, this message
should have an "actionable" aspect to it -- specifically, the user
could be given the choice to either "accept" the new feature, or
"reject" it.  Upon accepting the feature, this particual message would
go away.  Upon rejecting the feature, not only would the messages go
away, but your .emacs would get set up with a configuration item that
stops the feature from activating in the future.

It is an interesting idea to develop for a future release.


text:
SMS scnews item created by Kevin Coulembier at Wed 19 Apr 2017 1151
Type: Seminar
Distribution: World
Expiry: 31 May 2017
Calendar1: 28 Apr 2017 1200-1300
CalLoc1: Carslaw 375
CalTitle1: Algebra Seminar: Bruhat order, weak order and closure operators on root systems
Auth: kevinc@120.88.165.116 (kcou7211) in SMS-WASM

# Algebra Seminar: Dyer -- Bruhat order, weak order and closure operators on root systems

Matthew Dyer (University of Notre Dame)

Friday 28 April, 12-1pm, Place: Carslaw 375

Title: Bruhat order, weak order and closure operators on root systems

Abstract: Reflection orders of Coxeter groups are certain total orders of the
reflections (or positive roots).  They are analogues for infinite Coxeter groups of
reduced expressions of longest elements of finite Coxeter groups.  Their initial
sections parameterise (actually or conjecturally, depending on context) natural twists
of certain algebraic, geometric, combinatorial and representation theoretic objects
attached to Coxeter groups, such as Bruhat order.  Many long standing conjectures
concerning initial sections may be viewed as natural extensions, to a completion by
"infinitely long elements", of trivial or well known properties of weak order of
Coxeter groups.  This talk will survey recent results, some due to Francois Viard and
Weijia Wang, arising from attempts to refine, test and prove (at least in tractable
special cases) these conjectures.

If you are registered you may mark the scnews item as read.
School members may try to .


text:
Sciencemadness Discussion Board » Fundamentals » Reagents and Apparatus Acquisition » Gas Flow Rate Meter Select A Forum Fundamentals   » Chemistry in General   » Organic Chemistry   » Reagents and Apparatus Acquisition   » Beginnings   » Responsible Practices   » Miscellaneous   » The Wiki Special topics   » Technochemistry   » Energetic Materials   » Biochemistry   » Radiochemistry   » Computational Models and Techniques   » Prepublication Non-chemistry   » Forum Matters   » Legal and Societal Issues

Author: Subject: Gas Flow Rate Meter
mrjeffy321
Hazard to Others

Posts: 149
Registered: 11-6-2005
Member Is Offline

Gas Flow Rate Meter

I am trying to come up with a better way to measure the rate of gas production in one of my Chemical reactions.

The "get by" method I have been using is basically to collect the gas over water and time how long it takes to get a specific volume (example, 500 mL / 4 minutes). However, this requires a lot of manual labor on my part to keep track of everything while the production gets faster and faster (it is gets pretty hectic at 9 L/min). Also, the data I collect using this method is naturally flawed in that I am not getting an instantaneous rate, rather I am getting an average over the period of time it took to collect.
What I can do is when production is slow, collect very small samples (100 to 200 mL) and when it speeds up collect larger samples (1 L), but still, when I graph the rate, it is obvious that it isn’t too actuate.

What I would like is some system that would involve much less work on my part and could give me a higher degree of accuracy and a more instantaneous rate. (It would be wonderful if I could connect it to a computer and collect data that way.) [And it would be even more wonderful if this system didn’t cost me hundreds of dollars as well.]

Any thoughts?
Magpie
lab constructor

Posts: 5939
Registered: 1-11-2003
Location: USA
Member Is Offline

Mood: Chemistry: the subtle science.

Look into the cost of rotameters. This will give you an instantaneous rated but not an integrated total volume. You should be able to find some that aren't too expensive.

The single most important condition for a successful synthesis is good mixing - Nicodem
Cyrus
National Hazard

Posts: 397
Registered: 24-4-2004
Location: Ancient Persia
Member Is Offline

Mood: No Mood

For another "instantaneous" gas measuring device, I had the following idea. (Taken from a book on pottery kilns, it is used to measure the flow of natural gas- granted, that's a much larger flow, but the idea can be adapted.)

Have a tube that narrows to a very small and precisely drilled hole. (easy to do with plumbing fittings, put a sheet metal piece w/ hole btw. two fittings and screw tight, or something similar.)

Now drill 2 holes in the side of this tube- one before the sheet metal piece, and one after. (or use plumbing "T" fittings and hose barbs) Then connect a rubber tube or similar to each of these barbs/holes, and connect each end of the rubber tube to a "U" shaped tube (drying tube, etc.) Mount the U shaped tube upright to something nice, draw measurements on it, and fill it partially with water. You can tell the pressure difference before and after the sheet metal constriction in the tube, and with a bit of math, you can calculate the flow.

As long as the hole is drilled accurately, this should be a very accurate way to measure pressure and thus flow. (Assuming your flow is reasonably constant, of course.)

Of course you can drill the right sized hole for any amount of gas- 1/4" for nat. gas for a kiln or so , or a pinhole sized hole for your purposes, perhaps. If your interested I can post pictures of the concept and see if I can dig out the equations.

I thought it was a very interesting concept, and if I build another kiln, I would like to run it off of natural gas and measure the flow this way... (OT, I know...)

Cy

mrjeffy321
Hazard to Others

Posts: 149
Registered: 11-6-2005
Member Is Offline

I was able to find several rotometers/flowrate meters that might work for me on eBay. The price isnt too bad, the only problem, most of them either are calibrated to either measure very small flow rates or large rate, my expected rate will be somewhere in between most of the time.

Cyrus, I had originally considered trying something like what you suggested (using Bernoulli's principle), but couldnt figure out quite how to set it up. Now I know.
I have never been taught any of that fluid dynamics stuff in school, so I was looking through my physics book for the equations and whatnot and what do I find? One of the example problems has a diagram of exactly what you were describing.
The only dissadvantage to this approach is that , one I would actually have to build it rather than relying on some factory calibrated device.

I am still trying to decide what I will do. I think it might be hard for me to find the propper materials to build the Venturi meter in such a way to get accurate results.
Twospoons
International Hazard

Posts: 1209
Registered: 26-7-2004
Location: Middle Earth
Member Is Offline

Mood: A trace of hope...

The orifice flowmeter, which is what Cyrus is describing, can also be used with a differential pressure transducer - which would make it computer connectable. The whole thing is probably available OTC at a reasonable price (if you hunt long enough). The equations governing these devices are well known, you should be able to find them in a fluid mechanics text book ( mine's at home somewhere). Be aware the charactistics will vary somewhat depending on the composition of the gas you are measuring, and also on the gas density (= pressure and temperature).

Helicopter: "helico" -> spiral, "pter" -> with wings
Cyrus
National Hazard

Posts: 397
Registered: 24-4-2004
Location: Ancient Persia
Member Is Offline

Mood: No Mood

Obviously you're going to need to choose compatible materials and the right sized orifice, but if the gas isn't too corrosive, plain old materials from the hardware store ought to suffice. What gas are you going to be using?

edit- this should be very accurate. Can you drill a 1/16" hole in a piece of plastic? (The author of the book I mentioned recommended using steel and a long hole through a thicker/multiple pieces of the material. I don't see why plastic wouldn't work.)

Cy

[Edited on 3-3-2006 by Cyrus]

mrjeffy321
Hazard to Others

Posts: 149
Registered: 11-6-2005
Member Is Offline

This flowmeter will be used for primarily Hydrogen gas.

I have a question concerning your diagram.
The two latex tubes leading to the measurement apparatous both connect to the same size diameter "Cast Iron T", meaning that the gas will be traveling the same speed through both sections, meaning that the pressures will be equal. The flow through the very tiny "orifice" is where thr gas will be traveling fastest and where one of the tubes should connect to, I think.

I did a few calculations on just how much of a elevation difference there would be in the water.
If we assume a constant flow of 9 Liters per minute (1.5 E-4 m^3/s), through a 1/4" diameter pipe, the gas will be traveling at about 4.7 m/s. if the pipe then contracts to half the diameter (to 1/8"), the gas will increase its speed to 18.7 m/s. This change in flow speed is caused by a pressure difference of about 163.8 Pascals of pressure.
This pressure difference will cause a difference of about 16.4 cm in the height of the water (assuming my calculations are correct).

[Edited on 3-3-2006 by mrjeffy321]
Twospoons
International Hazard

Posts: 1209
Registered: 26-7-2004
Location: Middle Earth
Member Is Offline

Mood: A trace of hope...

 Quote: Originally posted by mrjeffy321 The flow through the very tiny "orifice" is where thr gas will be traveling fastest and where one of the tubes should connect to, I think.

Don't get confused with a venturi flowmeter, which measures the pressure drop in the fast flow section of a convergent/divergent nozzle.

[Edited on 3-3-2006 by Twospoons]

Helicopter: "helico" -> spiral, "pter" -> with wings
mrjeffy321
Hazard to Others

Posts: 149
Registered: 11-6-2005
Member Is Offline

I went ahead and build a venturi flowmeter (not an orifice flowmeter) out of 17 different brass pipe couplings and adapters.

I use 1/4 inch diameter tubing for almost everything, so my flowmeter takes the 1/4" tube, enlarges it to a 1/2 inch pipe (to which I connect one end of the pressure tube), then shrink it down to a 1/8 inch diameter pipe (to which I connect the other end of the pressure tube) and then re-enlarge it to 1/4" as the glas flows out.

I have not put the meter into actual use yet, I still need to test it.
When I simply blow through the end of the pipe with water in the pressure tube, I can see the water level rise a good 2 cm (meaning it must be dropping 2 cm on the other side). it works pretty well I think.

However, I am having trouble trying to design the srt up for the actual pressure tube with water in it when it goes into actual use. I wanted to build something like the one in the picture above, but it is proving more difficult than it might seem.
I am thinking, maybe just skip it all and use the differential pressure transducer that Twospoons had suggested so I can hook it up to a compuer. Anyone know where I can find a good differential pressure transducer? I fond one on ebay, but it is $75 and I am not sure if that is exactly what I am looking for. As soon as I can find my digital camera, I will upload a picure of what my flow meter looks like. mrjeffy321 Hazard to Others Posts: 149 Registered: 11-6-2005 Member Is Offline Beautiful isnt it [picture attached]. Now all I need to do is try to find a manometer in my price range to measure the difference in pressure, if I sacrifice the R232 port, I can knock off about$40-$50. Twospoons International Hazard Posts: 1209 Registered: 26-7-2004 Location: Middle Earth Member Is Offline Mood: A trace of hope... How are your electronic skills? Because you can get the pressure sensor element from Freescale for a lot less than$75. You might even score a free sample. But then you have to build the interface. For which one of the Cypress PSoC devices might be good.

Helicopter: "helico" -> spiral, "pter" -> with wings
Magpie
lab constructor

Posts: 5939
Registered: 1-11-2003
Location: USA
Member Is Offline

Mood: Chemistry: the subtle science.

Making a manometer is simple and cheap as long as you don't expect more than about 30 " H2O pressure difference. Just take a flat board and nail a yardstick to it. Along side that attach a U-tube made of small diameter Tygon tubing. Fill U-tube halfway full of colored water. Done.

The single most important condition for a successful synthesis is good mixing - Nicodem
mrjeffy321
Hazard to Others

Posts: 149
Registered: 11-6-2005
Member Is Offline

 Quote: Originally posted by Twospoons How are your electronic skills?

Terrible. If it goes beyond simple circuits, I am lost. I once tried to build an amp hour meter out of electrical components thinking I could make and program it myself....nope.
I could probably handle programming the serial interface between the manometer and the computer, but I'd just as soon not risk it.

I am in no hurry to get a fancy, digital, manometer; my homemade substitute is working fine for now. I hot glued a rubber tub to a board, drew 1/2 cm markings and connected up the flow meter, it works pretty nicely. But for practical use in the long run, the digital manometer will be much more convenient.
Tacho
International Hazard

Posts: 582
Registered: 5-12-2003
Member Is Offline

Mood: No Mood

There is a simple device that can be homebuilt with ease. Do a google search on 'soap film flowmeter'.

It's tube with a bubble. Not really a bubble, but a flat soap film. As gas flows , the bubble moves. Measure the time the buble takes to pass through two calibration marks, look up at a table you made previosly and that's it.

The tube has to be wet, the soap mixture must have some glicerin to prevent drying and you must figure some way to make the soap film as needed. Try to copy the desings on the net. Google gives 60.000 hits. There is a description of one here:

http://jchemed.chem.wisc.edu/HS/Journal/Issues/2005/Feb/clic...

I would use a disposable syringe barrel as the tube. It already has volume marks.

Another idea for small flows:
Use a bubbler. Count how many bubbles per minute and look at a conversion table you made previously. Maybe a more viscous liquid would allow larger bubles and, therefore, measurement of larger flows, but I'm not sure. An optic electronic bubble counter would be nice.

 Sciencemadness Discussion Board » Fundamentals » Reagents and Apparatus Acquisition » Gas Flow Rate Meter Select A Forum Fundamentals   » Chemistry in General   » Organic Chemistry   » Reagents and Apparatus Acquisition   » Beginnings   » Responsible Practices   » Miscellaneous   » The Wiki Special topics   » Technochemistry   » Energetic Materials   » Biochemistry   » Radiochemistry   » Computational Models and Techniques   » Prepublication Non-chemistry   » Forum Matters   » Legal and Societal Issues


text:
# Why does the neural network logistic regression cost function sum for all layers only for lambda?

I'm taking Andrew Ng's machine learning course and week 5 covers the training of neural networks. The modified cost function for neural network training is derived from the logistic regression cost function, and is described as follows:

$$\begin{gather*} J(\Theta) = - \frac{1}{m} \sum_{i=1}^m \sum_{k=1}^K \left[y^{(i)}_k \log ((h_\Theta (x^{(i)}))_k) + (1 - y^{(i)}_k)\log (1 - (h_\Theta(x^{(i)}))_k)\right] + \frac{\lambda}{2m}\sum_{l=1}^{L-1} \sum_{i=1}^{s_l} \sum_{j=1}^{s_{l+1}} ( \Theta_{j,i}^{(l)})^2\end{gather*}$$

Here, K is the number of output units, L is the total number of layers in the network, and ${s_l}$ is the number of units in layer l.

I don't understand why the second half of the cost function, intended to prevent over-fitting by minimizing the values of the theta parameters, is summed across the entire network while the first half of the equation which actually determines theta is only for a specific layer. If each layer's cost function already includes a minimization parameter for that layer's theta values, why is it necessary to perform this minimization globally for every layer in the cost function J?

As I understand it, in training a neural network you mainly treat each layer as completely separate from the next (and in fact, that is one of the major selling points of the NN approach, wherein solving L layers independently of one-another lets you use a simple approach to obtain powerful results) - so why are we summing the second half of the equation over all layers?

The first term depends on the output of the entire network, i.e., on all the parameters for all layers, not just a single layer's parameters.

This is an application of the empirical risk minimization framework for training a classifier, with regularization. The cost function $J(\Theta)$ has the form

$$J(\Theta) = \text{empirical risk} + \text{regularization penalty}.$$

Denote the empirical risk by $R(\Theta)$; it depends on the parameters $\Theta$ (for all layers). Denote the regularization penalty by $P(\Theta)$; it depends on the parameters $\Theta$ (for all layers).

The empirical risk $R(\Theta)$ is the sum of the loss for each instance in the training set, i.e., it has the form

$$R(\Theta) = {1 \over m} \sum_{i=1}^m \ell(h_\Theta(x^{(i)}), y^{(i)}),$$

where $\ell$ is a loss function, $x^{(i)},y^{(i)}$ is the $i$th instance in the training set, and $h_\Theta(x)$ denotes the output of the classifier on input $x$ when the parameters are $\Theta$. Note that the output of the classifier depends on all the parameters for all the layers, so $R(\Theta)$ depends on all the parameters for all layers (not just a single layer).

A comment on notation: We use $\Theta$ to denote all of the parameters, i.e., a single vector that concatenates the parameters for each layer. Here it appears $\Theta^{(l)}$ has been used to denote the parameters for the $l$th layer, so $\Theta = (\Theta^{(1)}, \dots, \Theta^{(L)})$.

In your specific example, we use the cross-entropy loss for $\ell$ (this is also known as the logistic loss function, where there are only two classes). That's how we get the first term.

Also the regularization penalty $P(\Theta)$ depends on all of the parameters, for all layers; it is a sum of penalties for each layer.

If you work through the math, you'll see how we get something of the form you've shown in the question. As this answer hopefully makes clear, each term depends on the parameters for all the layers, not just a single layer.

• Thank you, that makes perfect sense. What I was missing at a higher level is that this is the cost/error function for the entire network, not for a single unit/node or layer. – Mahmoud Al-Qudsi Mar 14 '17 at 1:42


text:
# Right triangle trigonometrics

Calculate the size of the remaining sides and angles of a right triangle ABC if it is given: b = 10 cm; c = 20 cm; angle alpha = 60° and the angle beta = 30° (use the Pythagorean theorem and functions sine, cosine, tangent, cotangent)

Correct result:

a =  17.3205 cm
C =  90 °

#### Solution:

$C=180-\left(60+30\right)=9{0}^{\circ }$

Try calculation via our triangle calculator.

We would be very happy if you find an error in the example, spelling mistakes, or inaccuracies, and please send it to us. We thank you!

Tips to related online calculators
Pythagorean theorem is the base for the right triangle calculator.

#### You need to know the following knowledge to solve this word math problem:

We encourage you to watch this tutorial video on this math problem:

## Next similar math problems:

• The right triangle
In the right triangle ABC with right angle at C we know the side lengths AC = 9 cm and BC = 7 cm. Calculate the length of the remaining side of the triangle and the size of all angles.
• Isosceles triangle
Calculate the size of the interior angles and the length of the base of the isosceles triangle if the length of the arm is 17 cm and the height to the base is 12 cm.
• Right triangle
Calculate the length of the remaining two sides and the angles in the rectangular triangle ABC if a = 10 cm, angle alpha = 18°40'.
• Right angle
In a right triangle ABC with a right angle at the apex C, we know the side length AB = 24 cm and the angle at the vertex B = 71°. Calculate the length of the legs of the triangle.
• Height 2
Calculate the height of the equilateral triangle with side 38.
• The cable car
The cable car is 2610 m long and rises at an angle of 35°. Calculate the height difference between the lower and upper station of the cable car.
• RT - inscribed circle
In a rectangular triangle has sides lengths> a = 30cm, b = 12.5cm. The right angle is at the vertex C. Calculate the radius of the inscribed circle.
• Flowerbed
Flowerbed has the shape of an isosceles obtuse triangle. Arm has a size 5.5 meters and an angle opposite to the base size is 94°. What is the distance from the base to opposite vertex?
• Cosine
The point (8, 6) is on the terminal side of angle θ. cos θ = ?
• Right triangle
A right triangle ABC is given, c is a hypotenuse. Find the length of the sides a, b, the angle beta if c = 5 and angle alfa = A = 35 degrees.
• The cable car
The cable car has a length of 3,5 kilometers and an angle of climb of 30 degrees. What is the altitude difference between Upper and Lower Station?
• Cable car 2
Cable car rises at an angle 41° and connects the upper and lower station with an altitude difference of 1175 m. How long is the track of cable car?


text:
# Tag Info

16

After a lengthy study (I'm using version 8) I conclude that there is a bug in Mathematica in the Integrate function when applied to a Sqrt integrand. Ok. let's go (some patience is required because of the long text) Let us define the functions corresponding to your integrals. Remark: because of the relation $1 + cos(2x) = 2 cos^2(x)$ the two forms of ...

12

In this second answer I give the cause for the mismatch in the integrals, show how to remove it, and make a suggestion to improve the function Integrate[]. Simplified restatement of the problem In order to focus on the core of the problem we consider the simpler integral $\int_0^1 \sqrt{\cos (2 π k r)+1} \, dr$. It has the square root and the cosine ...

10

Here is the derivation promised earlier. I have chosen to create a new answer in order not to mix things up and because it shows some handling which I like to call "man-machine" interaction with Mathematica. And, sorry for the "Greeks", but I find it very cumbersome to reedit them :-( $Version "8.0 for Microsoft Windows (64-bit) (October 7, 2011)" ... 9 In Mathematica 10, this computation may be made as follows: Clear @ r volSphere9[r_] = RegionMeasure[Ball[ConstantArray[0, 10], r]] (π^5 r^10)/120 volSphere9[1000.] 2.55016*10^30 8 Update The updated question clarifies the problem. As far as I can tell, this is a bug, a rather strange bug. I've tracked the problem down to the definition L = 1 still existing on the parallel kernels. This removes the problem: Put ParallelEvaluate@ClearAll["GlobalL"] after the second ClearAll["Global*"] halfway through the code. Then ... 8 From Weierstrass Approximation Theorem we know there is such a polynomial, moreover there are infinitely many polynomials satisfying given criterion. Therefore we would like to find those ones of the minimal order. Since we are supposed to exploit series approximations we define a polynomial of n - th order approximating 6 ArcTan[x] for x such that ... 7 The sum of the squares should be less than or equal to r^2 rather than r. d = 10; r = 1000; F = Piecewise[{{1, Sum[x[i]^2, {i, d}] <= r^2}}, 0]; NIntegrate[F, {x[1], -1000, 1000}, {x[2], -1000, 1000}, {x[3], -1000, 1000}, {x[4], -1000, 1000}, {x[5], -1000, 1000}, {x[6], -1000, 1000}, {x[7], -1000, 1000}, {x[8], -1000, 1000}, {x[9], -1000, 1000}, ... 6 It is not quite clear, what do you you want to get out of the answer. Would you like to compare Maple and Mma and understand, which one is better ? Or would you like to understand the alternative forms of taking this integral? Or the reason, why the results of Marple and Mma are different? Or transform the Mma result in terms of xand y? Or, ... 6 Taylor polynomials of order n aren't necessarily the nth degree polynomials that optimally approximate a function on a given interval. We can use linear least squares to find the optimal polynomials for a fixed n. inn[f_, g_, x_] := Integrate[f g, {x, -1/Sqrt[3], 1/Sqrt[3]}] LeastSquarePolynomial[f_, x_, n_] := With[{pows = x^Range[0, n]}, pows . ... 5 We can find a 7th order polynomial that meets the requirement if we minimise the$\infty$-norm. For simplicity I construct an array of {x, 6 ArcTan[x]} over the required range and plug it into FindFit, no doubt there are better ways. {a, b} = {-1, 1}/Sqrt[3]; data = Table[{x, 6 ArcTan[x]}, {x, a, b, (b - a)/1000.}]; n = 7; expr = Sum[c[i] x^i, {i, 1, n, ... 4 Here is another way to get points equally spaced by chord-length. It will give a good result if the chord length is relatively small compared to the maximum radius of curvature along the curve. (If, say, the chord length is no greater than the maximum radius, then between successive points, the turning will be less 60 deg., and the difference between the ... 4 The exact analytic soultion 1. Introduction The problem was still intriguing me with the result of a further study which I present in the following, for clarity as another solution. I have chosen to write the formulas in the more theoretical text in traditonal form. Abstract We calculate here the explcit analytic solution for the integral$f(k,R)=\int ...

4

ImplicitRegion (and ParametricRegion) represent a region. They are not for plotting. Thus RegionPlot is not even remotely an alternative. You can do many operations on regions that you can look up in the documentation centre. Just a few examples: you can compute their size, decide if a point is within, compute the distance between them, find their ...

4

Mathematica 10 provides new functionality dealing with curves, (see e.g. the Vector Analysis tutorial) like ArcLength, ArcCurvature and especially FrenetSerretSystem: FrenetSerretSystem[{ x1, ..., xn}, t] gives the generalized curvatures and Frenet-Serret basis for the parametric curve x[t] i.e. it returns {{ k1, ..., k(n-1)}, { e1, ..., en}}, where ki ...

4

To compute $\nabla^nr$ for arbitrary integer $n$, you can use the built-in tensor derivative syntax. For example, you can compute the second-derivative $\nabla^2r$ using r = Sqrt[x^2 + y^2 + (z - a)^2]; X = {x, y, z}; D[r, {X, 2}] To get an answer in terms of $r$, you can sort of cheat your way to the correct answer via the following modification: r = ...

4

These singularities in $g(\cdot,y)$ are all removable. There are eight singular values of y, depending only on a, and you can take the limit as $y\rightarrow s$ for each singular value $s$ and obtain limit for all but finitely many values of $x$. Those are also removable by taking a limit. The function is still continuous, smooth, bounded, etc. The values ...

4

I said in a comment that one could "factor" out ((-1 + a y^2 (1 + y)^2)^2 from the numerator. What I meant was that numerator is $O(((-1 + a y^2 (1 + y)^2)^2)$. The integral is a complicated expression, so the easiest way to examine it, it seemed to me, is to look at the coefficients of the power series expansion about the real roots of the denominator. ...

4

Partial sums of this sequence are given by: Sum[(-1)^(n + 1) Cos[3^n x]^3/3^n, {n, 1, m}] (* output: 1/4 Cos[3 x] - 1/4 (-(1/3))^m Cos[3^(1 + m) x] *) For real $x$, we know this converges because $\cos(3^{1+m}x)$ is bounded. Mathematica does not assume $x$ is real and, as Bob Hanlon notes, will produce the correct result by evaluating a partial sum, ...

4

In Version 10 you can now create ImplicitRegions and Integrate over them: region = ImplicitRegion[And @@ {0 <= x, x <= 1 - y, -1 <= y, x + 2 y <= 2}, {x, y}] Now Integrate[x + y, {x, y} ∈ region] 2/3

4

There exist few typos in your kernel definition. This is how your kernel looks assuming a=2 (we denote it as A while defining the kernel as Kpart in the following). Please utilize the code from here to solve your problem. Below I changed the constants and functional arguments of FredholmKind2 to fit your particular problem. n = 20;(*number of ...

3

Your equation has a sign error for the inverse Fourier transform. A simpler prescription is I InverseFourierTransform[FourierTransform[f[t], t, w]/w, w, x] Although there is a lrge range of function for which this works, it will of course fail for all those functions for which the Fourier transform can't be calculated. Anyway, it does work for ...

3

My version of Mathematica has no problems calculating analytically the integral $\int_{x-b}^{b+x} 2 r (l-r) \cos ^{-1}\left(\frac{s^2+x^2-b^2}{2 s x}\right) \, dr$ The result looks nice (IMHO) rather than "ugly". \$\frac{1}{9} b^3 \left(9 L \pi -2 (2+z) (8+z (2+z)) \text{EllipticE}\left[\frac{4 (1+z)}{(2+z)^2}\right]+2 z (2+z)^2 ...

2

A fix For s, you could use s = x \[Function] Piecewise[{{Cos[x], -Pi/2 <= Mod[x, 2 π, -π] <= Pi/2}}]; Integrate[s[t], {t, -8, 6}] (* 5 + Sin[6] *) The problem The problem with the original ff and s is that the function calls itself. Now consider ff[t] or s[t]. None of the conditions will evaluate to False so "the Piecewise function is returned ...

2

In mathematics, a set can be write in two(or more) form: one is {3x | x in [0,1]}, the other {x | P(x)}, where P is called a propositional function or predicate. Since Mathematica have a great power of dealing with quantifiers, once you can write a set in the second form above, you can do plenty of things and tricks that you would have thought to have ...

2

I think I solved this problem. The error message was due to the fact that Mathematica cannot perform the internal integration, so I split the two integrations and used NIntegrate instead of the symbolic integration: p[z1_?NumericQ, R_?NumericQ, z_?NumericQ] := -NIntegrate[ BesselK[0, x/Ld]*x* ArcSin[(2*x)/( Sqrt[(z1)^2 + (x + 7.6)^2] + ...

2

Assuming by ln you mean the natural logarithm, in Mathematica this is entered as Log Integrate[t^z Log[t], {t, x, y}, Assumptions -> {z ∈ Integers, 0 < x < y}]

1

As I said in a comment I object to the downvaluing of my solution by somebody anonymus without giving the reasong for it. Now you can convince yourself here that my solution of the real problem is correct. And, consequently, that the second integral of "identy" (and sequel) is not. Here we go: I gather from your first lines that you wanted to calculate ...

1

No apparent complication in v10 under Windows: Integrate[Sqrt[w/2 (w/2 + u + v)], w] (Sqrt[w] Sqrt[2 u + 2 v + w] (Sqrt[w] (u + v + w) Sqrt[2 u + 2 v + w] - 2 ((u + v)^2) Log[Sqrt[w] + Sqrt[2 u + 2 v + w]]))/(4 Sqrt[w (2 u + 2 v + w)])

1

You could define your function as f[x_] := 2 Mod[x, 1] then Integrate[f[x], {x, 0, 5}] yields 5 (as expect 5 triangles of area 1) To plot: Plot[f[x], {x, -4, 4}, Exclusions -> None]

1

I assume that |...| means Abs[...]. Define the symbolic integral. int[r0_?NumericQ, k_?NumericQ] := Integrate[Sqrt[r] Abs[Cos[(k + 1/2) \[Pi] r]], {r, r0, 1}] Define the numerical integral. intN[r0_?NumericQ, k_?NumericQ] := NIntegrate[Sqrt[r] Abs[Cos[(k + 1/2) \[Pi] r]], {r, r0, 1}] Compare these integrals for your chosen parameter values, using 1/2 ...

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


text:
# The average of 11 numbers is 18. Out of these 11 numbers, the average of 9 numbers is 17. If the ratio of the remaining two numbers is 2 : 3. What is

11 views
in Aptitude
closed
The average of 11 numbers is 18. Out of these 11 numbers, the average of 9 numbers is 17. If the ratio of the remaining two numbers is 2 : 3. What is the smaller number?
1. 27
2. 18
3. 19
4. 20
5. 15

by (54.3k points)
selected

Correct Answer - Option 2 : 18

Given:

The average of 11 numbers = 18

The average of 9 numbers = 17

The ratio of the remaining 2 numbers = 2 : 3

Calculation:

Total of the 11 numbers = 11 × 18

⇒ 198

Total of the 9 numbers = 9 × 17

⇒ 153

∴ Total of the remaining 2 numbers = 198 – 153

⇒ 45

Let the remaining two numbers be 2x and 3x.

∴ 2x + 3x = 45

⇒ 5x = 45

⇒ x = 9

∴ the smaller number = 2x

⇒ 2 × 9

⇒ 18

∴ the smaller number is 18.


text:
# How to Latex-print matrices as a bold uppercase letter?

Hello Sage users!

I was reading the documentation and trying to find a solution for my personal chimera of LaTeX usage: if I define $\mathbf A$ to be a matrix at some scope (document, chapter or section for example), why do I have to explictly write \mathbf every time?

So my question for Sage is this: say I have a simple 2x2 matrix

$$\mathbf A = \left[ \begin{array}{rr} a & b \\ c & d \end{array} \right]$$

I want to, at times, do symbolic manipulations with the letter representation of this matrix, then use the latex(...) command to print it as a bold upcase letter, and to use the full matrix form at other times (with its corresponding LaTeX form).

Example of what I want:

sage: A = matrix(2,2,var('a', 'b', 'c', 'd'))
sage: latex(A)
\left(\begin{array}{rr}
a & b \\
c & d
\end{array}\right)
sage: latex(A.as_symbol())
\Bold{A}

Similarly, I would like it very much to perform symbolic calculations with A in sage defined as an "abstract matrix", i.e., a symbol of type matrix, that will render as a bold uppercase A (because is of type matrix) but will be used as a symbol in computations. Example.

sage: var('A', 'B', 'c')
sage: A,B :: AbstractMatrix
sage: latex(A)
\Bold{A}
sage: A*B
A*B
sage: (A+B)*c
A*c + B*c
sage: latex(A*B)
\Bold{A}\Bold{B}
sage: latex((A+B)*c)
\Bold{A}*c +  \Bold{B}*c

Is it possible to do this in Sage? And how?

edit retag close merge delete

( 2019-09-07 06:48:08 -0500 )edit

Added examples of what I meant.

( 2019-09-13 03:54:13 -0500 )edit

Sort by » oldest newest most voted

Ragarding the first question, you should understand that when you write:

sage: A = matrix(2,2,var('a', 'b', 'c', 'd'))

A is a Python name, that is a kind of pointer to the matrix object, but the matrix object doesn't know anything about which names point to it. For example, you can then do:

sage: B = A

Here B is just another Python name pointing to the very same object in memory as you can check with:

sage: B is A
True

So, if you want to type A.as_symbol(), there is nowhere in the matrix object that registered the fact that the matrix has "A" as a string representation.

We can define a function that finds one of the Python names of the matrix object within the globals() dictionary and pick the first one that appears (and that is not ugly like _42), but it is kind of artificial, like:

sage: def sym(a):
....:     for i in globals():
....:         if not i.startswith('_') and globals()[i] is a:
....:             return SR.var(i, latex_name="\Bold{{{}}}".format(i))

You have:

sage: latex(sym(A))
{\Bold{A}}

But of course:

sage: latex(sym(B))
{\Bold{A}}

Regarding the second question, it is a bit different, since the symbolic variable knows a string reprentation of itself, and you can even tune a latex one as follows:

sage: A = SR.var('A', latex_name="\Bold{A}")
sage: B = SR.var('B', latex_name="\Bold{B}")
sage: c = SR.var('c')
sage: A*B
A*B
sage: latex(A*B)
{\Bold{A}} {\Bold{B}}

sage: e = (A+B)*c
sage: e
(A + B)*c
sage: e.expand()
A*c + B*c
sage: latex(e.expand())
{\Bold{A}} c + {\Bold{B}} c
more

## Stats

Seen: 83 times

Last updated: Sep 13 '19


text:
Question

Complex Analysis

\text { The function } g(x)=\frac{x+1}{x+2} \text { has vertical asymptote at } x=-2 \text { . }

TRUE FALSE


text:
## Stream: maths

### Topic: list.maximum should return option

#### Chris Hughes (Aug 12 2019 at 06:06):

Would it be better for list.maximum to return an optional value, instead of asking for an inhabited instance. I'm working with list (fin m), where I don't know if my list is empty or not (I want to case split on this) and fin m is obviously not necessarily inhabited, and it would be a lot nicer to have an option in this situation.

#### Scott Morrison (Aug 12 2019 at 06:50):

I always thought requiring inhabited here was strange, but I know some people have found it convenient.

#### Scott Morrison (Aug 12 2019 at 06:50):

Would list.maximum.iget be significantly too painful for people who want the old behaviour?

#### Andrew Ashworth (Aug 12 2019 at 08:38):

Haskell's data.list.safe package requires the type to be nonempty, finite, and have an ordering as a precondition, it might have come from there.

#### Andrew Ashworth (Aug 12 2019 at 08:41):

of course both signatures are provided, the option kind is maximumMay :: (Foldable t, Ord a) => t a -> Maybe a...

#### Andrew Ashworth (Aug 12 2019 at 08:42):

so it would be useful to have both versions

Last updated: May 14 2021 at 20:13 UTC


text:
need help figuring out how they came up with answer. I have attached an advanced accounting problem.

need help figuring out how they came up with answer. I have attached an advanced accounting problem (5-15) . 15. Gibson Corp. owned a 90% interest in Sparis Co. Sparis frequently made sales of inventory to Gibson. The sales, which include a markup over cost of 25%, were $420,000 in 2010 and$500,000 in 2011. At the end of each year, Gibson still owned 30% of the goods. Net income for Sparis was $912,000 during 2011. What was the noncontrolling interest's share of Sparis' net income for 2011? A.$85,680. B. $90,600. C.$90,720. D. $91,680. E.$91,800.
Document Preview:

15. Gibson Corp. owned a 90% interest in Sparis Co. Sparis frequently made sales of inventory to Gibson. The sales, which include a markup over cost of 25%, were $420,000 in 2010 and$500,000 in 2011. At the end of each year, Gibson still owned 30% of the goods. Net income for Sparis was $912,000 during 2011. What was the noncontrolling interest's share of Sparis' net income for 2011? A.$85,680. B. $90,600. C.$90,720. D. $91,680. E.$91,800.

Attachments:

QUESTION: Gibson Corp. owned a 90% interest in Sparis Co. Sparis frequently made sales of inventory to Gibson. The sales, which include a markup over cost of 25%, were $420,000 in 2010 and$500,000 in 2011. At the end of each year,...

Related Questions in Financial Accounting - Others

• 15. Gibson Corp. owned a 90% interest in Sparis Co. Sparis frequently made sales of inventory to...

(Solved) July 17, 2015

15 . Gibson Corp . owned a 90 % interest in Sparis Co . Sparis frequently made sales of inventory to Gibson . The sales, which include a markup over cost of 25 %, were $420,000 in 2010 and$ 500,000 in 2011 . At the end of each year , Gibson still owned 30 % of the goods. Net income for Sparis was...


text:
# Economics ?

1. Mar 26, 2008

### RufusDawes

What are your opinions on the discipline of Economics ? Do you think it has the potential to be used to help people or do you think it is simply a tool used by the rich and powerful.

Is Economics a science ? Is the mathematics behind it sound ?

I have friends who say it is fluff, that it is nothing more.

What do you think about Economics ? I have noticed as of late that policies that can be demonstrated to help the average person (such as higher minimum wages) under the right conditions are largely ignored.

I am interested to hear what some of you sound mathematicians think of Economics.

Last edited: Mar 26, 2008
2. Mar 26, 2008

### Staff: Mentor

You have a degree in economics and can't answer these questions yourself? What do you think the answers are?

Saying that economics is a too for the rich and powerful sounds pretty silly to me. Economics is merely the study of how the economy works. Anyone who wants to understand how the economy works can use it and benefit from the knowledge (and presumably get a job in a related field).

Policies like a higher minimum wage are problematic due to the secondary effects. As you know, the labor market is a real market, and supply and demand applies. So if the price of labor increases, the demand will decrease - unemployment will increase. How much....well, that's what economists are for. But such policies are also understandably politicised.

Last edited: Mar 26, 2008
3. Mar 26, 2008

### RufusDawes

frankly...we can do so many cool things with science and engineering with perfect precision but we can't somehow organise our economy, to FEED and give everyone a job...and not have to live in relative poverty.

What ? the mathematicians can't figure that one out ? or are we being run by flambouyant retards (economists) ?

4. Mar 26, 2008

### Staff: Mentor

I am not sure whose economy you are talking about. It certainly isn't the US economy.

There is no real poverty in the US (relative poverty is rather meaningless), nor is hunger a real problem (obesity is the number one health problem for our "poor"), and unemployment is about as low as it can be without causing real problems (full employment would be disasterous to the economy).

The flambouyant retards (politicians) try to mess things up, but so far the people have managed to keep them away enough to not cripple the economy.

Last edited: Mar 26, 2008
5. Mar 27, 2008

### RufusDawes

That is exactly what I mean. 'Relative poor is rather meaningless" why so ? who's purpose does it serve to ignore relative poverty ?

You're just excluding the concept of poverty based on a comparison to a different beast (a developing nation). Could an engineer get away with similar ? comparing an aspect of his design to something made in the 50's ? ''Relative inefficiency is meaningless".

6. Mar 27, 2008

### Staff: Mentor

Relative inefficiency is meaningless too, an engineer would never quote an efficiency number in terms of other designs, past or present. An engineer would simply tell you what the efficiency of his design is. It is a meaningful number on its own.

Relative poverty is a silly concept precisely because it is relative*. A person living in a $500k home eating 5,000 calories per day would be considered impoverished if his neighbors had more. That is a meaningless definition of poverty, and since it is meaningless it best serves everyone (including the relative poor) to ignore it. A better question is "relative poverty is a meaningless concept so whose purpose does it serve to support it?" *Relative numbers can only be meaningful in general if they are referenced to a stable standard. This is the case for e.g. kilograms, but not the case for poverty. Last edited: Mar 27, 2008 7. Mar 27, 2008 ### RufusDawes The poverty line is at something between 10,000-18,000 per year I fail to see how many people living that cheap would have a 500,000 home. What you described is relative wealth not relative poverty. 8. Mar 27, 2008 ### russ_watters ### Staff: Mentor Are you really an economist? I guess it shouldn't surprise me, I have seen such things before, but it truly disappoints and disturbs me when I see such things. Last edited: Mar 27, 2008 9. Mar 27, 2008 ### russ_watters ### Staff: Mentor The point is that using that standard as our poverty line then requires defining probably about 90% of the world population as impoverished. The way we define poverty enables people with cars, refrigerators, and air conditioning to be labeled as "impoverished" while in other places in the world there are people in real need of basic necessities such as food and shelter. The way the word is used by those in a position to define it (ie, government agencies and the UN) is not based on real need/material condition. And this is in an era where technological and economic advancement have enabled rapid and truly spectacular improvements in material condition. The way the word is used it is intentionally deceptive and manipulative - it is used for political purposes only and has no real basis in objectivity. It is unscientific. Ie, it can be said that the poverty rate in the US has not decreased significantly in the past 50 years or so (using the definitions given by the government agencies responsible for tracking it). A logical person would take this to mean that the human condition is not improving in the US. But that isn't true. In fact, living conditions have improved dramatically in the US in the last 50 years. You asked the question and you yourself may be the answer: Economics is capable of being science and probably should be scientific (it claims to be, afterall), but whether it is treated scientifically by economists is another matter entirely. It appears to me that a great many economists are more politicians than scientists and use economics as a political game rather than a real scientific endeavour. I believe that a field that claims to be scientific really should be scientific. It should be based on math and logic. Last edited: Mar 27, 2008 10. Mar 28, 2008 ### RufusDawes I don't see the need to try and be so insulting. Mine is simply a different point of view based on my experiences. 11. Mar 28, 2008 ### Dale ### Staff: Mentor You obviously missed my point completely, so I will try again. My point is that no honest person would consider someone in a big house eating lots of food to be impoverished, but that is precicely the sort of thing that can happen under the current relative definition of poverty. The definition of poverty is someone that makes less than half of the median income. So, let's say that the median income level today is$36k. A median income of $36k provides for a comfortable lifestyle that nobody would call impoverished: 4,000-5,000 calorie/day diet, ~2400 sq. ft. home, utilities, health care, car, cable tv, a/c, etc. Now, assume that GDP goes up by 6%/year and that inflation goes up by 3%/per year over 25 years. After 25 years it will take an income of$75k to purchase the exact same comfortable lifestyle that nobody would call impoverished. However, the median income is now $155k, so suddenly the$75k (4,000-5,000 calorie/day diet, ~2400 sq. ft. home, utilities, health care, car, cable tv, a/c, etc) is considered impoverished. That is silly.

Similarly, by this definition of poverty (half the median income), if half of the population were starving then there would be a large portion of the population between the median income and the poverty income that would be starving but not considered poor. That is also silly.

Anyway you look at it a relative definition of poverty is silly and it benefits noone other than politicians.

12. Mar 28, 2008

### RufusDawes

"Anyway you look at it a relative definition of poverty is silly and it benefits noone other than politicians."

It benefits the relatively poor people when the government decides to try and help them specifically.

13. Mar 28, 2008

### Ronnin

Economics is far from "fluff". The mathematics are very sound and are used to a very high degree of accuracy. Now, the models or statistics being used in calculations may not be as accurate as one would like. If the methods of economics were just "fluff" I doubt Wall Street would employ the amount of intelectual capital, man and computer power that they do. The purpose of economics is not to establish any kind of "fairness" in the marketplace, that is regulated by economic policy and trade law. Knowlege of economics would certainly benefit anyone who wishes to learn it. Perhaps the knowlege of economics and its application helped contribute to the acquisition of some of that wealth those wealthy people obtained.

14. Mar 28, 2008

### Staff: Mentor

I disagree completely. It does a man no good for someone else to do something for him that he can and should do for himself. It ruins his integrity, his work ethic, his self respect, his value to the community, and his capacity to do good. It breeds in him a sense of entitlement and corrupts his morals to the point that he thinks it is virtuous of him to forcibly take another man's property at the point of a gun.

15. Mar 28, 2008

### RufusDawes

We are never going to agree on any of that. To me what you are saying is total madness, to you a pay rate of $20 an hour for a retail worker would seem crazy. However, that is the reality of things in my country, a retail worker does get paid roughly$20 an hour. Many goods that in the United States are on a user pays basis are provided and regarded as a basic human entitlement. However this is obviously not without its costs.

16. Mar 29, 2008

### Staff: Mentor

Given the lack of thought and reason displayed in your posts this is hardly surprising.

17. Mar 29, 2008

### RufusDawes

Yes, ok in a global context any reference to poverty in the western world silly.

In local context I think it is a very useful measure that should not be ignored. Largely has been ignored to the detriment of the local economy. In that regard I am questioning the merits of economics as a means of helping people.

18. Mar 30, 2008

### Staff: Mentor

OK, for the sake of argument, let's pretend that relative poverty has been largely ignored. I have two questions for you:

1) How is the number of people earning less than half the median income a useful measure of anything?
2) How has ignoring it been detrimental to the local economy?

19. Apr 1, 2008

### Economist

I am an econ major and intend on going to grad school in the discipline.

In my own personal view, you have a "backwards" view of the discipline. You can't think of economics like it will allow you to be some sort of social engineer. What economics has taught me is that many individuals have different preferences, values, wants, etc, and by interacting with others "the system" works out fairly well. Try reading books by F.A. Hayek, Milton Friedman, etc, and then see if you still feel the same way about economics as a socially engineering tool.

20. Apr 2, 2008

### mulp

I think I know the problem you are having, because I had the same problem trying to figure out why economic theory seemed correct, but required so many "bags on the side of the machine" to make it work. It's like everytime you turn around, some god of externality needs to be invoked to fix some illogical conclusion.

Then I read the first page of Eco-economy by Lester Brown and the flaw was revealed. A different version of the same essay is available here at
http://www.theglobalist.com/DBWeb/StoryId.aspx?StoryId=2234
A bit of it...
Remember that the ecology of trees and birds and waters and fish is also the ecology all people live in.

People, rich, poor, young, old, sick, healthy, working, retired, are all consumers. Yet the economic model excludes all but the worker from this list of consumers.

The handwave is that all consumers are tied to a worker or capital. But when confronted with a person that isn't, the god of externality explains the wayward consumer crossing the economic flow.

Think of the magic of labor appearing when consumers demand more that the existing pool of labor can produce. It's like a god makes them appear, as in a video game. When demand no longer requires as much labor, poof, the person disappears.

The same is true for other natural resources. The economic model demands clean water? Poof clean water materializes. Toxic waste as a byproduct? Poof it vanishes from the economy.

I believe economic theory suffers from arrested development.

I think it traces to the cold war when it was the god ordained free world against the godless commies, and in the US, socialism and Marx, neither of which had anything to do with the Soviet Union or Red China. But in any case, all discussion about poverty stimulated a knee-jerk claim of becoming like the evil commies.

I liked Milton Friedman, not because I always agreed with him, but because he recognized the problems, like poverty. He proposed market solutions that acknowledged the existence of poverty.

But the problem is that he saw poverty as something that arises from something external, yet still considering the economy to be the whole. By taking that approach, the people who the economy makes believe don't exist end up being special cases that need to be treated specially every time they can no longer be ignored by the pressure on the economists to deal with them.

The economy takes place in the physical world and is absolutely constrained by the physical world, just as the actors in the physical and economic world are.

Economic theory like supply and demand can be seen as like Newton's Laws, useful simple rules that explain a small aspect of the laws of motion and energy. But they are lies, as Einstein showed. But still useful for many problems.

But economic theory has only partially embraced Newton's level of abstraction. Newton incorporated time, something that economic theory rarely does. Supply and demand is static, not explicitly dynamic, except for handwaves, like "in the short run" and "in the long run."

Going back to the Ptolemy vs Copernican difference; before discarding the earth centric model, special rules of astronomy were used to explain comets and to explain the planets. Economics seems to be doing the same thing with special versions of economic theory, like environmental economics that come up with special rules rather than fixing a single set of rules to apply generally.

The physical sciences has divisions, but all divisions operate by the same rules. Even the social sciences, where economic theory is placed, connects to the physical sciences increasingly in the search for understanding; behavior is not considered separate from environment or the physical nature of the person. Yet economic theory seems to seek to escape from the confines and limitations of the physical world.

To see the degree to which economics seeks to exclude the real world, consider the many models for labor supply curves and the explanations for the shapes of the curves. No where do I see an explanation of what happens to the people who clearly exist to provide the points on the curve. A curve might represent the supply of workers who can't be supplied if the pay is too low, like below the cost of bus fare to get to the job, but nothing is said about the people who can't work - where are they in the economic model - they still exist in the physical world.

To recognize those people as part of the economy takes you into the territory covered by Marx which means communism which means evil which means that all reasoning must cease.

Time to move past the constraints of the inquisition: McCarthyism is nearly dead. You won't be black listed as a commie if you say that people are more important than property or money. Time to stop dividing economics into capitalism vs socialism vs communism vs who knows how many other ideologies there are.


text:
# Derived categories bleg

Is the following theorem true, and if so, where is the reference?

Theorem? Let $D$ be a triangulated category with finite homological dimension, and let $\{L_1,\ldots, L_n\}$ be a finite set of objects which generate $D$ and whose classes are a basis of the Grothendieck group, such that $\mathrm{Ext}^{-k}(L_i,L_j)=0$ for all $k>0$. Then there exists a $t$-structure on $D$ such that the $L_i$ are the set of simple objects in the heart.

These conditions are obviously necessary, but I’m a bit less confident that they are sufficient.

Hmmm, I guess this means we’re going to have to explain what a $t$-structure is now, doesn’t it?

EDIT: I found the theorem I wanted in the paper David mentioned, by Bezrukavnikov.  Roughly, the right theorem is that the $L_i$‘s are the simple objects in the heart of a $t$-structure if there is a semi-simple abelian subcategory of  the triangulated category in which they are the simple objects, and they satisfy the conditions above.

## 6 thoughts on “Derived categories bleg”

1. The LaTeX paste didn’t work in your post!

2. Hi Ben –
I assume
1. you know this reference, and
2. someone will have a better answer,
but in the meanwhile I can say the closest things that comes to mind
is the paper “Quasi-exceptional sets and..” (arXiv:0102039)
by Bezrukavnikov (in particular Proposition 1) where he
characterizes t-structures generated by a quasi-exceptional
set, which can be constructed from your data under
some conditions.. I think there is a theory by Cline-Parshall-Scott
(or some subset) formalizing various properties of categories
like category O, that might be useful in this context..
(then again many of the world’s experts on just this kind
of problem are within 1/2 a mile of you right now, might be more
efficient to stand outside and shout out the problem?)

3. anonymous says:

I doubt it. Is the bounded derived category of modules over C[x] a counterexample? Take n =1, L_1 = C[x] itself. But I haven’t thought it through: it may be harder to show “there is no t-structure” than I think.

4. right, another obvious necessary condition is that Ext^0(L_i,L_i) = k
-otherwise you want to modify the question to talk about
constituents of the L_i rather than the L_i themselves..

5. b says:

Shouldn’t one require that the {L_i} be orthogonal in a stronger sense than just K-theory? If not, there could be non-zero maps L_i -> L_j for i != j, ruining simplicity. For example, consider the bounded derived category of coherent sheaves on P^1 with L_1 = O, and L_1 = O(-1).


text:
# 83

Suppose a general-population survey shows that people who exercise less, weigh more. You don't have any known direction of time in the data - you don't know which came first, the increased weight or the diminished exercise. And you didn't randomly assign half the population to exercise less; you just surveyed an existing population.

The statisticians who discovered causality were trying to find a way to distinguish, within survey data, the direction of cause and effect - whether, as common sense would have it, more obese people exercise less because they find physical activity less rewarding; or whether, as in the virtue theory of metabolism, lack of exercise actually causes weight gain due to divine punishment for the sin of sloth.

# vs.

The usual way to resolve this sort of question is by randomized intervention. If you randomly assign half your experimental subjects to exercise more, and afterward the increased-exercise group doesn't lose any weight compared to the control group [1], you could rule out causality from exercise to weight, and conclude that the correlation between weight and exercise is probably due to physical activity being less fun when you're overweight [3]. The question is whether you can get causal data without interventions.

For a long time, the conventional wisdom in philosophy was that this was impossible unless you knew the direction of time and knew which event had happened first. Among some philosophers of science, there was a belief that the "direction of causality" was a meaningless question, and that in the universe itself there were only correlations - that "cause and effect" was something unobservable and undefinable, that only unsophisticated non-statisticians believed in due to their lack of formal training:

"The law of causality, I believe, like much that passes muster among philosophers, is a relic of a bygone age, surviving, like the monarchy, only because it is erroneously supposed to do no harm." -- Bertrand Russell (he later changed his mind)

"Beyond such discarded fundamentals as 'matter' and 'force' lies still another fetish among the inscrutable arcana of modern science, namely, the category of cause and effect." -- Karl Pearson

The famous statistician Fisher, who was also a smoker, testified before Congress that the correlation between smoking and lung cancer couldn't prove that the former caused the latter.  We have remnants of this type of reasoning in old-school "Correlation does not imply causation", without the now-standard appendix, "But it sure is a hint".

This skepticism was overturned by a surprisingly simple mathematical observation.

Let's say there are three variables in the survey data: Weight, how much the person exercises, and how much time they spend on the Internet.

For simplicity, we'll have these three variables be binary, yes-or-no observations: Y or N for whether the person has a BMI over 25, Y or N for whether they exercised at least twice in the last week, and Y or N for whether they've checked Reddit in the last 72 hours.

Now let's say our gathered data looks like this:

Overweight Exercise Internet #
Y Y Y  1,119
Y Y N  16,104
Y N Y  11,121
Y N N  60,032
N Y Y  18,102
N Y N  132,111
N N Y  29,120
N N N  155,033

And lo, merely by eyeballing this data -

(which is totally made up, so don't go actually believing the conclusion I'm about to draw)

- we now realize that being overweight and spending time on the Internet both cause you to exercise less, presumably because exercise is less fun and you have more alternative things to do, but exercising has no causal influence on body weight or Internet use.

"What!" you cry. "How can you tell that just by inspecting those numbers? You can't say that exercise isn't correlated to body weight - if you just look at all the members of the population who exercise, they clearly have lower weights. 10% of exercisers are overweight, vs. 28% of non-exercisers.  How could you rule out the obvious causal explanation for that correlation, just by looking at this data?"

There's a wee bit of math involved.  It's simple math - the part we'll use doesn't involve solving equations or complicated proofs -but we do have to introduce a wee bit of novel math to explain how the heck we got there from here.

Let me start with a question that turned out - to the surprise of many investigators involved - to be highly related to the issue we've just addressed.

Suppose that earthquakes and burglars can both set off burglar alarms.  If the burglar alarm in your house goes off, it might be because of an actual burglar, but it might also be because a minor earthquake rocked your house and triggered a few sensors. Early investigators in Artificial Intelligence, who were trying to represent all high-level events using primitive tokens in a first-order logic (for reasons of historical stupidity we won't go into) were stymied by the following apparent paradox:

• If you tell me that my burglar alarm went off, I infer a burglar, which I will represent in my first-order-logical database using a theorem  ALARM → BURGLAR. (The symbol "" is called "turnstile" and means "the logical system asserts that".)

• If an earthquake occurs, it will set off burglar alarms. I shall represent this using the theorem  EARTHQUAKE → ALARM, or "earthquake implies alarm".

• If you tell me that my alarm went off, and then further tell me that an earthquake occurred, it explains away my burglar alarm going off. I don't need to explain the alarm by a burglar, because the alarm has already been explained by the earthquake. I conclude there was no burglar. I shall represent this by adding a theorem which says  (EARTHQUAKE & ALARM) → NOT BURGLAR.

Which represents a logical contradiction, and for a while there were attempts to develop "non-monotonic logics" so that you could retract conclusions given additional data. This didn't work very well, since the underlying structure of reasoning was a terrible fit for the structure of classical logic, even when mutated.

Just changing certainties to quantitative probabilities can fix many problems with classical logic, and one might think that this case was likewise easily fixed.

Namely, just write a probability table of all possible combinations of earthquake or ¬earthquake, burglar or ¬burglar, and alarm or ¬alarm (where ¬ is the logical negation symbol), with the following entries:

Burglar Earthquake Alarm %
b e a .000162
b e ¬a .0000085
b ¬e a .0151
b ¬e ¬a .00168
¬b e a .0078
¬b e ¬a .002
¬b ¬e a .00097
¬b ¬e ¬a .972

Using the operations of marginalization and conditionalization, we get the desired reasoning back out:

Let's start with the probability of a burglar given an alarm, p(burglar|alarm). By the law of conditional probability,

$p(b|a) = \frac{p(ab)}{p(a)}$

i.e. the relative fraction of cases where there's an alarm and a burglar, within the set of all cases where there's an alarm.

The table doesn't directly tell us p(alarm & burglar)/p(alarm), but by the law of marginal probability,

$p(ab) = p(abe) + p(ab\neg e) = .000162 + .0151 = .0153$

Similarly, to get the probability of an alarm going off, p(alarm), we add up all the different sets of events that involve an alarm going off - entries 1, 3, 5, and 7 in the table.

So the entire set of calculations looks like this:

• If I hear a burglar alarm, I conclude there was probably (63%) a burglar.

$p(b|a) = \frac{p(ab)}{p(a)} = \frac{.0153}{.000162 + .0151 + .0078 + .00097} = .63$

• If I learn about an earthquake, I conclude there was probably (80%) an alarm.

$p(a|e) = \frac{p(ae)}{p(e)} = \frac{.000162 + .0078}{.000162 + .0078 + .0000085 + .002} = .8$

• I hear about an alarm and then hear about an earthquake; I conclude there was probably (98%) no burglar.

$\frac{p(ae\neg b)}{p(ae)} = \frac{p(ae\neg b)}{p(aeb) + p(ae\neg b)} = \frac{.0078}{.000162 + .0078} = .98$

Thus, a joint probability distribution is indeed capable of representing the reasoning-behaviors we want.

So is our problem solved? Our work done?

Not in real life or real Artificial Intelligence work. The problem is that this solution doesn't scale. Boy howdy, does it not scale! If you have a model containing forty binary variables - alert readers may notice that the observed physical universe contains at least forty things - and you try to write out the joint probability distribution over all combinations of those variables, it looks like this:

 .0000000000112 YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY .000000000000034 YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYN .00000000000991 YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYNY .00000000000532 YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYNN .000000000145 YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYNYY ... ...

(1,099,511,627,776 entries)

This isn't merely a storage problem. In terms of storage, a trillion entries is just a terabyte or three. The real problem is learning a table like that. You have to deduce 1,099,511,627,776 floating-point probabilities from observed data, and the only constraint on this giant table is that all the probabilities must sum to exactly 1.0, a problem with 1,099,511,627,775 degrees of freedom. (If you know the first 1,099,511,627,775 numbers, you can deduce the 1,099,511,627,776th number using the constraint that they all sum to exactly 1.0.) It's not the storage cost that kills you in a problem with forty variables, it's the difficulty of gathering enough observational data to constrain a trillion different parameters. And in a universe containing seventy things, things are even worse.

So instead, suppose we approached the earthquake-burglar problem by trying to specify probabilities in a format where... never mind, it's easier to just give an example before stating abstract rules.

First let's add, for purposes of further illustration, a new variable, "Recession", whether or not there's a depressed economy at the time. Now suppose that:

• The probability of an earthquake is 0.01.

• The probability of a recession at any given time is 0.33 (or 1/3).

• The probability of a burglary given a recession is 0.04; or, given no recession, 0.01.

• An earthquake is 0.8 likely to set off your burglar alarm; a burglar is 0.9 likely to set off your burglar alarm.  And - we can't compute this model fully without this info - the combination of a burglar and an earthquake is 0.95 likely to set off the alarm; and in the absence of either burglars or earthquakes, your alarm has a 0.001 chance of going off anyway.

 p(r) 0.33 p(¬r) 0.67
 p(a|be) 0.95 p(a|b¬e) 0.9 p(a|¬be) 0.797 p(a|¬b¬e) 0.001 p(¬a|be) 0.05 p(¬a|b¬e) 0.1 p(¬a|¬be) 0.203 p(¬a|¬b¬e) 0.999
 p(e) 0.01 p(¬e) 0.99
 p(b|r) 0.04 p(b|¬r) 0.01 p(¬b|r) 0.96 p(¬b|¬r) 0.99

According to this model, if you want to know "The probability that an earthquake occurs" - just the probability of that one variable, without talking about any others - you can directly look up p(e) = .01. On the other hand, if you want to know the probability of a burglar striking, you have to first look up the probability of a recession (.33), and then p(b|r) and p(b|¬r), and sum up p(b|r)*p(r) + p(b|¬r)*p(¬r) to get a net probability of .01*.66 + .04*.33 = .02 = p(b), a 2% probability that a burglar is around at some random time.

If we want to compute the joint probability of four values for all four variables - for example, the probability that there is no earthquake and no recession and a burglar and the alarm goes off - this causal model computes this joint probability as the product:

$p(\neg e)p(\neg r)p(b|\neg r)p(a|b\neg e) = .99 * .67 * .01 * .9 = .006 = 0.6%$

In general, to go from a causal model to a probability distribution, we compute, for each setting of all the variables, the product

$p(\mathbf{X}=\mathbf{x})= \prod_i p(X_i=x_i|\mathbf{PA_i}=\mathbf{pa_i})$

multiplying together the conditional probability of each variable given the values of its immediate parents.  (If a node has no parents, the probability table for it has just an unconditional probability, like "the chance of an earthquake is .01".)

This is a causal model because it corresponds to a world in which each event is directly caused by only a small set of other events, its parent nodes in the graph. In this model, a recession can indirectly cause an alarm to go off - the recession increases the probability of a burglar, who in turn sets off an alarm - but the recession only acts on the alarm through the intermediate cause of the burglar.  (Contrast to a model where recessions set off burglar alarms directly.)

# vs.

The first diagram implies that once we already know whether or not there's a burglar, we don't learn anything more about the probability of a burglar alarm, if we find out that there's a recession:

$p(a|b) = p(a|br)$

This is a fundamental illustration of the locality of causality - once I know there's a burglar, I know everything I need to know to calculate the probability that there's an alarm.  Knowing the state of Burglar screens off anything that Recession could tell me about Alarm - even though, if I didn't know the value of the Burglar variable, Recessions would appear to be statistically correlated with Alarms.  The present screens off the past from the future; in a causal system, if you know the exact, complete state of the present, the state of the past has no further physical relevance to computing the future.  It's how, in a system containing many correlations (like the recession-alarm correlation), it's still possible to compute each variable just by looking at a small number of immediate neighbors.

Constraints like this are also how we can store a causal model - and much more importantly, learn a causal model - with many fewer parameters than the naked, raw, joint probability distribution.

Let's illustrate this using a simplified version of this graph, which only talks about earthquakes and recessions. We could consider three hypothetical causal diagrams over only these two variables:

 p(r) 0.03 p(¬r) 0.97
 p(e) 0.29 p(¬e) 0.71

## p(E&R)=p(E)p(R)

 p(e) 0.29 p(¬e) 0.71
 p(r|e) 0.15 p(¬r|e) 0.85 p(r|¬e) 0.03 p(¬r|¬e) 0.97

## p(E&R) = p(E)p(R|E)

 p(r) 0.03 p(¬r) 0.97
 p(e|r) 0.24 p(¬e|r) 0.76 p(e|¬r) 0.09 p(¬e|¬r) 0.91

## p(E&R) = p(R)p(E|R)

Let's consider the first hypothesis - that there's no causal arrows connecting earthquakes and recessions. If we build a causal model around this diagram, it has 2 real degrees of freedom - a degree of freedom for saying that the probability of an earthquake is, say, 29% (and hence that the probability of not-earthquake is necessarily 71%), and another degree of freedom for saying that the probability of a recession is 3% (and hence the probability of not-recession is constrained to be 97%).

On the other hand, the full joint probability distribution would have 3 degrees of freedom - a free choice of (earthquake&recession), a choice of p(earthquake&¬recession), a choice of p(¬earthquake&recession), and then a constrained p(¬earthquake&¬recession) which must be equal to 1 minus the sum of the other three, so that all four probabilities sum to 1.0.

By the pigeonhole principle (you can't fit 3 pigeons into 2 pigeonholes) there must be some joint probability distributions which cannot be represented in the first causal structure. This means the first causal structure is falsifiable; there's survey data we can get which would lead us to reject it as a hypothesis. In particular, the first causal model requires:

$p(er) = p(e)p(r)$

or equivalently

$p(e|r) = p(e)$

or equivalently

$p(r|e) = p(r)$

which is a conditional independence constraint - it says that learning about recessions doesn't tell us anything about the probability of an earthquake or vice versa. If we find that earthquakes and recessions are highly correlated in the observed data - if earthquakes and recessions go together, or earthquakes and the absence of recessions go together - it falsifies the first causal model.

For example, let's say that in your state, an earthquake is 0.1 probable per year and a recession is 0.2 probable. If we suppose that earthquakes don't cause recessions, earthquakes are not an effect of recessions, and that there aren't hidden aliens which produce both earthquakes and recessions, then we should find that years in which there are earthquakes and recessions happen around 0.02 of the time. If instead earthquakes and recessions happen 0.08 of the time, then the probability of a recession given an earthquake is 0.8 instead of 0.2, and we should much more strongly expect a recession any time we are told that an earthquake has occurred. Given enough samples, this falsifies the theory that these factors are unconnected; or rather, the more samples we have, the more we disbelieve that the two events are unconnected.

On the other hand, we can't tell apart the second two possibilities from survey data, because both causal models have 3 degrees of freedom, which is the size of the full joint probability distribution. (In general, fully connected causal graphs in which there's a line between every pair of nodes, have the same number of degrees of freedom as a raw joint distribution - and 2 nodes connected by 1 line are "fully connected".) We can't tell if earthquakes are 0.1 likely and cause recessions with 0.8 probability, or recessions are 0.2 likely and cause earthquakes with 0.4 probability (or if there are hidden aliens which on 6% of years show up and cause earthquakes and recessions with probability 1).

With larger universes, the difference between causal models and joint probability distributions becomes a lot more striking. If we're trying to reason about a million binary variables connected in a huge causal model, and each variable could have up to four direct 'parents' - four other variables that directly exert a causal effect on it - then the total number of free parameters would be at most... 16 million!

The number of free parameters in a raw joint probability distribution over a million binary variables would be 21,000,000. Minus one.

So causal models which are less than fully connected - in which most objects in the universe are not the direct cause or direct effect of everything else in the universe - are very strongly falsifiable; they only allow probability distributions (hence, observed frequencies) in an infinitesimally tiny range of all possible joint probability tables. Causal models very strongly constrain anticipation - disallow almost all possible patterns of observed frequencies - and gain mighty Bayesian advantages when these predictions come true.

To see this effect at work, let's consider the three variables Recession, Burglar, and Alarm.

Alarm Burglar Recession %
Y Y Y .012
N Y Y .0013
Y N Y .00287
N N Y .317
Y Y N .003
N Y N .000333
Y N N .00591
N N N .654

All three variables seem correlated to each other when considered two at a time. For example, if we consider Recessions and Alarms, they should seem correlated because recessions cause burglars which cause alarms. If we learn there was an alarm, for example, we conclude it's more probable that there was a recession. So since all three variables are correlated, can we distinguish between, say, these three causal models?

 $p(rba) = p(r)p(b|r)p(a|b)$ $p(rba)=p(r)p(a)p(b|ra)$ $p(rab)=p(r)p(a|r)p(b|a)$

Yes we can! Among these causal models, the prediction which only the first model makes, which is not shared by either of the other two, is that once we know whether a burglar is there, we learn nothing more about whether there was an alarm by finding out that there was a recession, since recessions only affect alarms through the intermediary of burglars:

$p(a|br) = p(a|b)$

But the third model, in which recessions directly cause alarms, which only then cause burglars, does not have this property. If I know that a burglar has appeared, it's likely that an alarm caused the burglar - but it's even more likely that there was an alarm, if there was a recession around to cause the alarm! So the third model predicts:

$p(a|br) \neq p(a|b)$

And in the second model, where alarms and recessions both cause burglars, we again don't have the conditional independence. If we know that there's a burglar, then we think that either an alarm or a recession caused it; and if we're told that there's an alarm, we'd conclude it was less likely that there was a recession, since the recession had been explained away.

(This may seem a bit clearer by considering the scenario B->A<-E, where burglars and earthquakes both cause alarms. If we're told the value of the bottom node, that there was an alarm, the probability of there being a burglar is not independent of whether we're told there was an earthquake - the two top nodes are not conditionally independent once we condition on the bottom node.)

On the other hand, we can't tell the difference between:

# vs.

using only this data and no other variables, because all three causal structures predict the same pattern of conditional dependence and independence - three variables which all appear mutually correlated, but Alarm and Recession become independent once you condition on Burglar.

Being able to read off patterns of conditional dependence and independence is an art known as "D-separation", and if you're good at it you can glance at a diagram like this...

...and see that, once we already know the Season, whether the Sprinkler is on and whether it is Raining are conditionally independent of each other - if we're told that it's Raining we conclude nothing about whether or not the Sprinkler is on. But if we then further observe that the sidewalk is Slippery, then Sprinkler and Rain become conditionally dependent once more, because if the Sidewalk is Slippery then it is probably Wet and this can be explained by either the Sprinkler or the Rain but probably not both, i.e. if we're told that it's Raining we conclude that it's less likely that the Sprinkler was on.

Okay, back to the obesity-exercise-Internet example. You may recall that we had the following observed frequencies:

Overweight Exercise Internet #
Y Y Y  1,119
Y Y N  16,104
Y N Y  11,121
Y N N  60,032
N Y Y  18,102
N Y N  132,111
N N Y  29,120
N N N  155,033

Do you see where this is going?

"Er," you reply, "Maybe if I had a calculator and ten minutes... you want to just go ahead and spell it out?"

Sure! First, we marginalize over the 'exercise' variable to get the table for just weight and Internet use. We do this by taking the 1,119 people who are YYY, overweight and Reddit users and exercising, and the 11,121 people who are overweight and non-exercising and Reddit users, YNY, and adding them together to get 12,240 total people who are overweight Reddit users:

Overweight Internet #
Y Y 12,240
Y N 76,136
N Y 47,222
N N 287,144

"And then?"

Well, that suggests that the probability of using Reddit, given that your weight is normal, is the same as the probability that you use Reddit, given that you're overweight. 47,222 out of 334,366 normal-weight people use Reddit, and 12,240 out of 88,376 overweight people use Reddit. That's about 14% either way.

"And so we conclude?"

Well, first we conclude it's not particularly likely that using Reddit causes weight gain, or that being overweight causes people to use Reddit:

If either of those causal links existed, those two variables should be correlated. We shouldn't find the lack of correlation or conditional independence that we just discovered.

Next, imagine that the real causal graph looked like this:

In this graph, exercising causes you to be less likely to be overweight (due to the virtue theory of metabolism), and exercising causes you to spend less time on the Internet (because you have less time for it).

But in this case we should not see that the groups who are/aren't overweight have the same probability of spending time on Reddit. There should be an outsized group of people who are both normal-weight and non-Redditors (because they exercise), and an outsized group of non-exercisers who are overweight and Reddit-using.

So that causal graph is also ruled out by the data, as are others like:

Leaving only this causal graph:

Which says that weight and Internet use exert causal effects on exercise, but exercise doesn't causally affect either.

All this discipline was invented and systematized by Judea Pearl, Peter Spirtes, Thomas Verma, and a number of other people in the 1980s and you should be quite impressed by their accomplishment, because before then, inferring causality from correlation was thought to be a fundamentally unsolvable problem. The standard volume on causal structure is Causality by Judea Pearl.

Causal models (with specific probabilities attached) are sometimes known as "Bayesian networks" or "Bayes nets", since they were invented by Bayesians and make use of Bayes's Theorem. They have all sorts of neat computational advantages which are far beyond the scope of this introduction - e.g. in many cases you can split up a Bayesian network into parts, put each of the parts on its own computer processor, and then update on three different pieces of evidence at once using a neatly local message-passing algorithm in which each node talks only to its immediate neighbors and when all the updates are finished propagating the whole network has settled into the correct state. For more on this see Judea Pearl's Probabilistic Reasoning in Intelligent Systems: Networks of Plausible Inference which is the original book on Bayes nets and still the best introduction I've personally happened to read.

[1] Somewhat to my own shame, I must admit to ignoring my own observations in this department - even after I saw no discernible effect on my weight or my musculature from aerobic exercise and strength training 2 hours a day 3 times a week, I didn't really start believing that the virtue theory of metabolism was wrong [2] until after other people had started the skeptical dogpile.

[2] I should mention, though, that I have confirmed a personal effect where eating enough cookies (at a convention where no protein is available) will cause weight gain afterward. There's no other discernible correlation between my carbs/protein/fat allocations and weight gain, just that eating sweets in large quantities can cause weight gain afterward. This admittedly does bear with the straight-out virtue theory of metabolism, i.e., eating pleasurable foods is sinful weakness and hence punished with fat.

[3] Or there might be some hidden third factor, a gene which causes both fat and non-exercise. By Occam's Razor this is more complicated and its probability is penalized accordingly, but we can't actually rule it out. It is obviously impossible to do the converse experiment where half the subjects are randomly assigned lower weights, since there's no known intervention which can cause weight loss.

Mainstream status:  This is meant to be an introduction to completely bog-standard Bayesian networks, causal models, and causal diagrams.  Any departures from mainstream academic views are errors and should be flagged accordingly.

Part of the sequence Highly Advanced Epistemology 101 for Beginners

Next post: "Stuff That Makes Stuff Happen"

Previous post: "The Fabric of Real Things"


text:
# Exponents.

• Oct 2nd 2011, 11:02 AM
habibixox
Exponents.
Solve for http://webwork.rutgers.edu/webwork2_...dd0b8b8e91.png:
http://webwork.rutgers.edu/webwork2_...095126dd01.png

I know 9 is 3^2 and 4 is 2^2

but how can i simplify this while knowing the above?
• Oct 2nd 2011, 11:05 AM
Siron
Re: Exponents.
To make it easy you can take the $\log$ of both sides and use $\log(a^b)=b\log(a)$ and you can also use $a^{x+y}=a^{x}\cdot a^{y}$ in the first place
• Oct 2nd 2011, 11:11 AM
habibixox
Re: Exponents.
so would it be

9x/3 log 9 = 8x/2 log 4 ?
• Oct 2nd 2011, 11:15 AM
Siron
Re: Exponents.
If you use the rule I suggested then you get:
$9^{9x-3}=4^{8x-2}$
$\Leftrightarrow \log(9^{9x-3})=\log(4^{8x-2})$
$\Leftrightarrow (9x-3)\log(9)=(8x-2)\log(4)$
$\Leftrightarrow 9x\log(9)-3\log(9)=8x\log(4)-2\log(4)$
$\Leftrightarrow 9x\log(9)-8x\log(4)=3\log(9)-2\log(4)$
$\Leftrightarrow x[9\log(9)-8\log(4)]=3\log(9)-2\log(4)$
$\Leftrightarrow ...$
• Oct 2nd 2011, 11:19 AM
habibixox
Re: Exponents.
ohh!!! ah oki i gotcha now :)
all the rules of exponents just confuse me!

thanks so much! do you mind taking a look at my half life problem i posted earlier?
• Oct 2nd 2011, 11:41 AM
Siron
Re: Exponents.
You're welcome! :)

To solve exponential equations then you really have to know this basic rules.


text:
# Is MLE of the mean of a distribution always the sample average?

From the connotation of "Maximum likelihood estimator" I am inclined to think that the maximum likelihood estimator of the mean of a distribution should equal the mean of the sample values drawn from that distribution. What else could the "maximum likelihood estimate" of the mean be?

Also, by calculus, the least squares estimator of the mean is again equal to the mean of the sample values of a sample drawn from the distribution. So is the MLE of the mean of a distribution always equal to the least squares estimator of the mean? If it is not, can someone give a counter-example?

• The lognormal distribution family provides a familiar counterexample. – whuber Nov 12 '19 at 15:37
• i can imagine fat tailed distributions (pareto?) where sample mean is definitely not a good estimate of the mean. But my calculus is pretty much nonexistent, so I don't know if that is the correct answer. – rep_ho Nov 12 '19 at 16:37
• Consider Laplace distribution, whose MLE is sample median. – Zhanxiong Nov 12 '19 at 17:27
• @whuber Why did you not post the following as an answer? "The lognormal distribution family provides a familiar counterexample." – user17144 Nov 13 '19 at 8:10
• Because Xi'an has already supplied that answer along with a clear explanation. – whuber Nov 13 '19 at 13:26

A generic contradiction to your intuition is that the MLE is invariant by transformations, while the mean is not. In particular, in exponential families, the MLE is the empirical mean of the natural statistics, but not of other transforms of the sample. For instance, in a Normal $$X\sim \mathcal N(\theta,1)$$ sample, the MLE of $$\theta$$, mean of $$X$$, is $$X$$, but the MLE of the mean of $$\exp(X)$$, $$\exp\{\theta+1/2\}$$, is $$\exp\{X+1/2\}$$ and not $$\exp\{X\}$$.

See also the connected discussion on when is the MLE a biased estimator of the mean.

• Can you please see my comments addressed to whuber right below the question? I think the reason for the MLE not being the sample average for lognormal is that the algebra for making them equal is messed up, and not that the mean is not invariant under transformations. Even if the mean were invariant under transformation, the MLE for the lognormal mean would still be only the GM of the sample and not the AM..In any case, thank you for your answer. – user17144 Nov 14 '19 at 12:32

maximum likelihood estimator of the mean of a distribution

I don't think I've ever seen the mean be computed via MLE. Remember, MLE is about parameters, not moments of the distribution.

For a lot of distributions, the parameters just happen to be best estimated by the sample mean (see $$\mu$$ for the normal, $$\lambda$$ for the poisson), but this isn't always the case (see $$\lambda$$ for the exponential, but this depends on the parameterization).

• The mean can always be considered a parameter. What might illuminate your point would be an example of a family of distributions in which all have the same mean. A Normal$(0,\sigma^2)$ family would work fine for that purpose, for instance. – whuber Nov 12 '19 at 15:44
• How will this example illuminate Demetri's point? – user17144 Nov 12 '19 at 15:51
• In this example, the MLE of the mean is $0,$ which will almost surely not equal the sample mean. – whuber Nov 12 '19 at 16:18
• @Cagdas Many authors conceive of a "parameter" as a (reasonably nicely behaved) function $\theta:\Omega\to\mathbb{R}$ where $\Omega$ is the set of possible probability distributions (such as the Normal ones). In this sense not only are $\mu$ and $\sigma^2$ parameters of the Normal$(\mu,\sigma^2)$ family, but so are $\sigma$ (the SD), $1/\sigma^2$ (the precision), the skewness, and so on. Typically a parameter is estimated directly, but in MLE it suffices to estimate any set of numbers that identify one distribution $\hat F\in\Omega$ uniquely, for then $\hat\theta=\theta(\hat F).$ – whuber Nov 12 '19 at 20:28
• @whuber I understand. I have learned something new today. Thank you. – Cagdas Ozgenc Nov 12 '19 at 20:48

Following @ZhanXiong's Comment. Suppose we look at $$n = 10^5$$ samples of size $$n = 5$$ from a Laplace (double exponential) population centered at $$10.$$ That is, population mean and median are both 10.

The following simulation in R, illustrates that the sample means $$\bar X = A$$ and $$\tilde X = H$$ have $$E(A) = E(H) = 10,$$ so that both the sample mean and median are unbiased estimators of the center. However, the sample means have a larger standard deviation than the sample medians. Thus, according to one frequently-used criterion, the sample median is a "better" estimator of the center than the sample mean.

set.seed(1112)
m = 10^5;  n = 5
x = rexp(m*n)-rexp(m*n)+10
DTA = matrix(x, nrow=m)
a = rowMeans(DTA)
mean(a);  sd(a)
[1] 9.997945          # aprx E(A) = 10
[1] 0.6317852         # aprx SD(A) = sqrt(2/5) =  0.6325

h = apply(DTA,1,median)
mean(h);  sd(h)
[1] 9.997512          # aprx E(H) = 10
[1] 0.5910876         # SD(H) < SD(A)

par(mfrow=c(2,1))
hist(a, prob=T, br=40, col="skyblue2", xlim=c(6,15),
main="Aprx Dist'n of Sample Meane")
hist(h, prob=T, br=40, col="skyblue2", xlim=c(6,15),
main="Aprx Dist'n of Sample Medians")
par(mfrow=c(1,1))


text:
Welcome to mathimatikoi.org forum; Enjoy your visit here.

## Continuous map

General Topology
Grigorios Kostakos
Founder
Articles: 0
Posts: 460
Joined: Mon Nov 09, 2015 1:36 am
Location: Ioannina, Greece

### Continuous map

Let $E_1\,,\; E_2$ be metric spaces and $f:E_1\longrightarrow E_2$ a map such that for every compact subspace $S$ of $E_1$ the restriction $f|_S:S\subseteq E_1\longrightarrow E_2$ is continuous. Prove that $f$ is continuous on $E_1$.
Grigorios Kostakos
jason1996
Articles: 0
Posts: 2
Joined: Sat Nov 12, 2016 3:50 pm

### Re: Continuous map

We suppose that $x_{n}\rightarrow x_{0}$. The set $\left \{ x_{1},x_{2},.... \right.\left. \right \}\cup \left \{ x_{0} \right.\left.\right \}$ is compact and from the hypothesis(the restriction of f in every compact set is continuous) we obtain that $f(x_{n})\rightarrow f(x_{0})$. So the proof has finished.

Question: Is this true for topological (not necessarily metric) spaces? If yes prove it, if not find a counterexample.
Riemann
Articles: 0
Posts: 169
Joined: Sat Nov 14, 2015 6:32 am
Location: Melbourne, Australia

### Re: Continuous map

jason1996 wrote:
Question: Is this true for topological (not necessarily metric) spaces? If yes prove it, if not find a counterexample.
Hello jason1996,

well the answer to your question is yes under one condition. $f$ must be defined on either closed or open subsets of the topological space. Try looking up for the final topology.

A little bit general result is the following:

Let $X$ be a topological space and $A_1$ and $A_2$ be subspaces of $X$. Let $g_{i}:A_i\rightarrow Y$ be continous for $i=1,2$. If $g_1$ and $g_2$ coincide on $A_1\cap A_2$ and $A_1$ and $A_2$ are either both open or both closed, then the function $f:X\rightarrow Y$ defined by $f(x)=g_1(x)$ if $x \in A_1$ and $f(x)=g_2(x)$ otherwise is continuous.

Assume that $g_1$ and $g_2$ are given continuous functions that satisfy the hypothesis and $A_1$ and $A_2$ are both open (respectively closed). Let $U$ be an open set (respectively closed set) of $Y$. Then,
$$f^{-1} = g_1^{-1}\cup g_2^{-1}$$ which is a binary union of open (respectively closed) sets in $X$, hence open (closed) by continuity of $g_i$ ($i=1,2$). Hence $f$ is continuous.
$\displaystyle \sum_{n=1}^{\infty}\frac{1}{n^s}= \prod_{p \; \text{prime}}\frac{1}{1-p^{-s}}$


text:
# Demo warning-box

## Usage

Warning boxes allow you to notify the reader of something important details to keep in mind. To use the warning box, include them in your markdown document, and utilize the content variable to contain your text.

Note that you can still use markdown inside the "" where your text is placed. In this example I’m using markdown to create a list inside the warning box.

## Example

{% include warning-box content="Stop! This is an important message! Did you check out the plugins categories page? What do you think? Make sure you wash your hands! Okay please continue reading.
" %}

 Stop! This is an important message! Did you check out the plugins categories page? What do you think? Make sure you wash your hands! Okay please continue reading.


text:
## Bifurcation question

Find the bifurcations (if any) and their type:

$x'=x^3-sinh(x+ \mu^3)$

So if we call that function f, I need f = f' = 0 right?

Well that gives me

$x^3-sinh(x+\mu^3)=3x^2-cosh(x+\mu^3)=0$

Some simple manipulation gives:

$cosh(x+\mu^3)^3-27cosh(x+\mu^3)^2+27=0$

What am I doing wrong? I cannot solve this.