qid
int64
1
4.65M
metadata
listlengths
3
3
prompt
stringlengths
31
25.8k
chosen
stringlengths
17
28.2k
rejected
stringlengths
19
40.5k
domain
stringclasses
28 values
54,212
[ "https://cs.stackexchange.com/questions/54212", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/47653/" ]
We are given two decision problems: $Q_1\colon I_1\to\{0,1\}$ and $Q_2\colon I_2\to\{0,1\}$. By definition, if there exists a function $f\colon I_1\to I_2$ such that for each $x\in I_1$ we have $Q_1(x)=Q_2(f(x))$ then $Q_1$ can be reduced to $Q_2$ by $f$. Now suppose that $Q_1$ can be reduced to $Q_2$ by a given $f$....
First, your definition of reducibility needs to include some sort of restriction on the power of $f$: typically, for example, we require the function to be computable. Without this restriction, any two decision problems (except the trivial problems "always yes" and "always no") are reducible to each other. Since...
No, you cant always find a reverse reduction. If $A$ is reducible to $B$ you should read it as: $A$ is not harder than $B$ (if i can decide membership to $B$, then i can decide membership to $A$), nothing is said about the opposite. For example, every decidable problem is reducible to the halting problem, but obviously...
https://cs.stackexchange.com
3,603,257
[ "https://math.stackexchange.com/questions/3603257", "https://math.stackexchange.com", "https://math.stackexchange.com/users/765867/" ]
Ella has 10% share because she invested 175 euro.<br> Chris has 10% share because he invested 175 euro. Nathan invests 100 euro, how many shares will he get? With some trial and error, I found the answer is 5.7142857143%. <blockquote> 5.7142857143 % of (175*10) </blockquote> But I'm sure there has to be a better...
Unitary Method: <span class="math-container">$175$</span> euros correspond to a <span class="math-container">$10\%$</span> share. <span class="math-container">$\\1$</span> euro -> <span class="math-container">$\frac{10}{175} \%$</span> share. <span class="math-container">$\\100$</span> euros -> <span class="math-conta...
We know that the percentage share and euros invested are directly proportional. Let <span class="math-container">$P$</span> denote percentage and <span class="math-container">$E$</span> denote euros then the following equation is valid for some constant <span class="math-container">$k$</span> <span class="math-contain...
https://math.stackexchange.com
106,903
[ "https://softwareengineering.stackexchange.com/questions/106903", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/36301/" ]
A few years ago I immigrated to another country and early last year I managed to get my master's degree. Back then I was desperately looking for a job and I was fortunate to get offered a job in a small software development company. For the record, back in my home company, I was a well-known developer with a very good ...
You could say that your current job is not challenging enough and you feel that you could do more than your job allows. Therefore, you are looking for new oportunities.
It's important to be honest in situations like these but you also don't want to seem petty. Don't go into too much detail but explain that your current manager isn't professional and you don't feel respected in the company. Give one quick (not too extreme) example of how they have been unprofessional in the past.
https://softwareengineering.stackexchange.com
20,476
[ "https://dba.stackexchange.com/questions/20476", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/9987/" ]
Just looking for some feedback here, there are lots of replication options out there, and I'd like to try something that those more expert than I have found to be successful. Here's my scenario: <ul> <li>1 SQL STD 2008 R2 SP2, few desktop clients, many web-clients edit and read;</li> <li>1 SQL ENT 2008 R2 SP2, deskto...
As some of your tables don't have a primary key, and I assume they don't have a unique index on them either, you are pretty much hosed. Anything which will be real time (transactional, merge, or peer to peer) will require either a primary key or that replication put it's own column in place called a rowguid (basically...
You will have to stop replication, make the schema changes and then reestablish replication. Also, since you are running SQL express clients, you will have to run the publisher at the main server instead of the clients. This means you will have to have your publisher push the entire database to the client. You mentione...
https://dba.stackexchange.com
13,557
[ "https://dba.stackexchange.com/questions/13557", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/6859/" ]
I'm trying to execute the below command as root user to provide accessiblity from my application. <code>GRANT ALL ON communitycourts.* TO 'root'@'%' WITH GRANT OPTION;</code> But it returns <code>0 rows affected</code>, but when I dont see this in result of <code>SHOW GRANTS</code>. Pelase help me
Two points to add: <ol> <li>It is recommended to use another user other than root to connect to your DB in your application. Try to use root account for administration only. This can be good only on testing machines.</li> <li>Don't forget to <code>flush privileges</code> for the changes to take effect. This is better ...
<code>0 rows affected</code> is normal for a successful <code>GRANT</code> command. Unsuccessful ones will display an error. If you see <code>1 warning</code> after <code>0 rows affected</code> you should type <code>SHOW WARNINGS;</code> and check whether the warning affects you or not. This one could: <pre><code>W...
https://dba.stackexchange.com
233,642
[ "https://softwareengineering.stackexchange.com/questions/233642", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/124584/" ]
I am only coding in Objective-C and I have no experience with backend coding, only a high-level understanding. I understand why a lot of programming projects require backend servers but I'm not absolutely clear on a high-level perspective why Mailbox needs their own. They get their data from the Gmail API, It is my ...
One good reason to build things with an intermediary service you control is so that you can control your own destiny and control when you need to change the app. For example, if your mobile app was talking directly to google and then they change the API surface you would have to push out an emergency update. This would...
Your suspicion is about right. There really should be nothing that the client couldn't be able to take care on its own unless the server also offered to save information that otherwise could not be saved using Gmail. It could be that, in fact, this is the reason and that Mailbox requires to store additional informati...
https://softwareengineering.stackexchange.com
103,171
[ "https://physics.stackexchange.com/questions/103171", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/40253/" ]
Why we say that EM waves are transverse in nature? I have seen some proofs regarding my question but they all calculate flux through imaginary cube. Here is My REAL problem that I can't here imagine infinitesimal area for calculating flux because em line of force will intersect (perpendicular or not) surface at only on...
<blockquote> Why we say that em waves are transverse in nature? </blockquote> In a region empty of electric charge, we have, from Maxwell's equations: $$\nabla \cdot \vec E = \nabla \cdot \vec B = 0$$ Since you don't yet know vector calculus, let's rewrite these divergence equations as so: $$\frac{\partial E_x}{\...
You say the <blockquote> em line of force will intersect (if perpendicular) surface at only one point. </blockquote> This is not the case for a plane wave, which is the simplest case one usually considers. I think I know what's going on to make you think this. This may or may not be the issue that helps you. Tak...
https://physics.stackexchange.com
369,736
[ "https://softwareengineering.stackexchange.com/questions/369736", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/169587/" ]
Suppose I have created an application that makes remote connections and does stuff, how does an anti-virus/anti-malware program decide if my app is harmful? I know there is a signature they check for to identify a program as either good or bad but it seems to me that would result in a lot of false positives because a ...
It doesn't know, it guesses based on a set of rules. Some rules, based on similarity to known malware, give reasonably reliable positives. Malware mutates and hides, so negatives are less reliable. Some rules are based on behavior, such as opening connection on certain ports. Some rules are based on cryptograph...
Mostly, it knows that Team Viewer and similar well-known programs aren't malware because the vendors have a database of cryptographic hashes of programs that have been manually checked, and Team Viewer will be on that database. The fact that the heuristics used by this kind of software often has false positives is hid...
https://softwareengineering.stackexchange.com
604,309
[ "https://physics.stackexchange.com/questions/604309", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/65337/" ]
On page 182 of Peskin &amp; Schroeder, equation (6.17) ends with the equality: <span class="math-container">$$2\log\left(\frac{p\cdot p’}{(E^2-p^2)/2}\right)=2\log\left(\frac{-(p’-p)^2}{m^2}\right),\tag{6.17}$$</span> where <span class="math-container">$p=E(1,\mathbf v)$</span> is the four-momentum of a particle with i...
They take the relativistic limit <span class="math-container">$\textbf{p}\rightarrow \infty$</span> and therefore: <span class="math-container">$$p\cdot p' - m^2 \approx p\cdot p'$$</span>.
You are right. This should not be an equality. It is an approximation which holds when <span class="math-container">$-q^2\gg m^2$</span>. Peskin's notation here is really a disaster, in my opinion. Let's clarify. The argument of the first log should be <span class="math-container">$$ \frac{p\cdot p'}{(E^2-|\mathbf p|^2...
https://physics.stackexchange.com
338,612
[ "https://electronics.stackexchange.com/questions/338612", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/147249/" ]
I want to measure the RMS value of voltage of half wave and full wave rectified sinusoidal wave using CRO itself. How do I go about it?
In the general case of some arbitrary waveform, a CRO is not the right tool for measuring RMS voltage. However, in your case you have a waveshape with fixed and known relationship between RMS and something easily measurable, like the peak voltage. For a sine, the peak is RMS x sqrt(2). Full-wave rectification doesn'...
Modern day oscilloscope contains a measure button (the first grey button of the image)clicking on it will fetch you all the value of all the important parameters some of which are time period ,v(peak to peak), v(rms ) ,v(max ) and so on.<img src="https://i.stack.imgur.com/ZU2b6.jpg" alt="enter image description here">...
https://electronics.stackexchange.com
26,141
[ "https://mechanics.stackexchange.com/questions/26141", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/15121/" ]
With enough time and skill sets, could a modern car be modded enough to work without microprocessors? Having machining skills and a fitted workshop, without buying a new motor block or transmission. Through modding of its parts or machining new ones. Discrete electronics could be used (to build multibrivators and con...
<h2>Yes, it is possible</h2> <em>Albeit with some trade-offs</em>. A modern-day road car is an amalgamation of several sub-systems, and electronics usually have an important role to play in them. The nice thing is that many of these sub-systems were present long before modern-day electronics became commonplace: <ul>...
There is such a beast known as an analog computer. The computer uses OpAmps to implement complex formulas in an entirely analog fashion. The formulas implemented take input from things like mas air flow, air temperature, coolant temperature, engine rpm and provide output to the fuel injectors. With enough time most i...
https://mechanics.stackexchange.com
42,710
[ "https://dsp.stackexchange.com/questions/42710", "https://dsp.stackexchange.com", "https://dsp.stackexchange.com/users/780/" ]
General questions: <ul> <li>Is the Kalman filter (they have used Unscented Kalman Filter) adaptive or not? Is the Unscented Kalman Filter used in the paper an adaptive algorithm? </li> <li>Adaptive algorithms such as Constant Modulus and Least Squares are adaptive. Why? What is being adapted ? Based on my understandin...
Adaptive Filters are called "Adaptive" when they can adapt to changes in data.<br> In the filters you mentioned above, which are part of the Linear Filters family the property means their coefficients are changing over time. Linear Filters are basically weighing and summing the data.<br> For instance, given no prior i...
An adaptive filter is one that updates its coefficients or parameters as a function of the input signal. Kalman filters are adaptive filters. On each time step, they update the estimate of the <em>states</em> they are tracking as well as the estimate of the <em>covariance</em> of these states.
https://dsp.stackexchange.com
7,808
[ "https://mathoverflow.net/questions/7808", "https://mathoverflow.net", "https://mathoverflow.net/users/184/" ]
Suppose that I have a map of simplicial spaces, $ f: X_* \to Y_*$, and that I know that the map on zero spaces $f_0: X_0 \to Y_0$ is n-connected. Can I conclude anything about the connectivity of the map of geometric realizations? $ |f|: |X| \to |Y|$ Are there any reasonable conditions I can place on the simplicial...
Yes it is a surjection on $\pi_0$, because each component of $|Y|$ has at least one component of $Y_0$. Beyond that there are no restrictions. For instance, you can get any homotopy type for $|X|$ and $|Y|$ and any homotopy type for the map between them with $X_0$ and $Y_0$ just one point, as long as you ask that $\p...
If you know the map on k-simplices is (n-k)-connected, you can deduce the map on realisations is n-connected. I don't think you can do better in any sort of generality.
https://mathoverflow.net
174,529
[ "https://electronics.stackexchange.com/questions/174529", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/65265/" ]
When I do prototyping I solder my PCBs by hand. That works fine most of the time, but I run into a problem when I have to solder chips with fine pitch (Google for VQ100 to get an idea of what I'm working with). The problem is not the soldering by itself but keeping the parts in place once the pins are aligned to the pa...
Have you tried bog standard thermal glue? They are not particularly strong, and the component can be slid with modest force to release from adhesion. The glue can be scraped off fairly easily, I don't know what solvent would remove it, but I can't imagine it would be easy to find one that does it. An alternative idea w...
I've used Kapton tape in the past for larger ICs that I need to keep down. Smaller ICs can be addressed by placing a small amount of solder paste on a corner pad. Place part and REflowing that corner pin. Very Small shifts can then be made to part before soldering the other corners then rest of pins.
https://electronics.stackexchange.com
176,661
[ "https://electronics.stackexchange.com/questions/176661", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/33138/" ]
I have a 9V AC source which will have a max load of 100mA. I'm trying to figure the value of a smoothing capacitor with less than a 10% ripple. I don't have a scope or else I'd just try a bunch out. I'm just a hobbyist, but I'm trying to understand this. Since I'm not sure if I'm doing this right, I'll just step th...
Your calculations are good but if you are using a full bridge rectifier (diode bridge, I think?), your frequency is the double of the input, so here 120Hz. Moreover, there is the voltage drop of the diodes, so with a full bridge it's roughly 1.2V. Hence Vp = 9-1.2 = 7.8V. Notice that a ripple of 10% is very good. Usu...
1000 microfarad is your recommended filter capacitance preffered value and yes it seems high but it must store energy between the rectified AC crests if the cap wasn't there you would get 48% ripple which is unworklable for most applications These days most powersupplies are switchmode which gives the designer the opti...
https://electronics.stackexchange.com
817,521
[ "https://math.stackexchange.com/questions/817521", "https://math.stackexchange.com", "https://math.stackexchange.com/users/109070/" ]
If $\tan^2 \theta = 1 + 2\tan^2 \phi$, show that $\cos 2\phi = 1 + 2\cos2\theta$. What I have done.. $$\implies \tan^2 \theta = 1 + 2\tan^2 \phi\\ \implies 1 + \tan^2 \theta = 2 + 2\tan^2 \phi\\ \implies 1 + \tan^2 \theta = 2(1 + \tan^2 \phi)\\ \implies \sec^2 \theta = 2(\sec^2 \phi)$$
Your steps are fine you just need to do the following (I'm putting your steps first): \begin{align*} \tan^{2}\theta &amp; = 1+2 \tan^{2}\phi\\ 1+\tan^{2}\theta &amp; = 2+2 \tan^{2}\phi\\ \sec^2 \theta &amp; = 2 \sec^2 \phi\\ \text{Do the following to continue:}\\ \frac{1}{\cos^2 \theta} &amp; = \frac{2}{\cos^2 \phi}\\...
Apply Componendo &amp; Dividendo on $$\frac{\tan^2\theta}1=\frac{1+2\tan^2\phi}1$$ $$\frac{1-\tan^2\theta}{1+\tan^2\theta}=\frac{1-(1+2\tan^2\phi)}{1+(1+2\tan^2\phi)}$$ $$\implies\cos2\theta=-\frac{\tan^2\phi}{1+\tan^2\phi}=-\sin^2\phi$$ $$\implies\cos2\theta=-\frac{1-\cos2\phi}2$$
https://math.stackexchange.com
264,138
[ "https://electronics.stackexchange.com/questions/264138", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/2713/" ]
I am reading some specs about Intel CPU. The word <code>bank</code> appears in the following contexts. I am not a native English speaker. Please help me understand its meaning. Thanks. From the <code>Intel Manual Vol. 3B Chapter 15.1</code>: <blockquote> The Pentium 4, Intel Xeon, Intel Atom, and P6 family processo...
It gives you a <em>big clue</em> in that last sentence. If you search for that particular bit 30, and then back up a bit, you will find some useful information here: <blockquote> 15.3.2 Error-Reporting Register Banks Each error-reporting register bank can contain the IA32_MCi_CTL, IA32_MCi_STATUS, IA32_MCi_ADD...
bank, n. "a set or series of similar things, especially electrical or electronic devices, grouped together in rows." Examples: bank of switches, bank of lights. Basically, 'bank' means 'group' or 'set'. When it comes to things like memory and registers, there is usually some addressing related connotation, perhaps...
https://electronics.stackexchange.com
173,052
[ "https://softwareengineering.stackexchange.com/questions/173052", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/45134/" ]
My team rarely does code review, mainly because we don't have enough time and people lack the energy and will to do so. But I would really like to know what people think about my code when they read it. This way, I have a better understanding how other people think and tailor my code accordingly so it's easier to read....
Having worked in places with code reviews and ones without, it has become one of my make-or-break issues in looking at new employment. The time you save avoiding emergencies because the problems didn't surface until you got to prod is much higher than the time you spend in code review. And that doesn't mention how much...
No fancy tools, in my opinion, could replace sitting with a senior developer or architect and walk through the code (or their code, and see what they did first hand). That said, I've found that unit testing code forces you to think in a reusable way, it also forces you to incorporate patterns that could make your code ...
https://softwareengineering.stackexchange.com
560,673
[ "https://physics.stackexchange.com/questions/560673", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/208833/" ]
I learned that a Hermitian matrix <span class="math-container">$A$</span> is defined as a matrix that satisfies <span class="math-container">$$A^\dagger=(A^*)^\intercal=A,$$</span> i.e. its Hermitian conjugate <span class="math-container">$A^\dagger$</span> is the same as the original matrix <span class="math-container...
<span class="math-container">$\langle f|Ag\rangle=\langle f|A|g\rangle$</span>. <span class="math-container">$\langle Af|g\rangle$</span>: <ul> <li><span class="math-container">$(\langle Af|) = (|Af\rangle)^\dagger =(A|f\rangle)^\dagger = \langle f |A^\dagger$</span>,</li> <li>so <span class="math-container">$\langle A...
In matrix form, <span class="math-container">$$\langle f|Ag\rangle = f^\dagger A g,$$</span> <span class="math-container">$$\langle Af|g\rangle= (Af)^\dagger g.$$</span> Using the matrix property of <span class="math-container">$(AB)^\dagger=B^\dagger A^\dagger$</span> on the latter expression, we get <span class="math...
https://physics.stackexchange.com
436,920
[ "https://electronics.stackexchange.com/questions/436920", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/-1/" ]
So I'm trying build a project that is based on the DTMF decoding IC. Obviously I want to simulate my project first on Proteus. Unfortunately, I can't find the DTMF IC mentioned above. Is there any library out there that I can use? or maybe a an equivalent element functionally? Thanks in advance
While I expect you could code up a model of the thing, I have to ask why anyone would bother simulating something like that? In my experience simulations shine for little bits of analogue (Filters, control loops, thing like that where you want a quick bode plot to sanity check your calcs), and for complex digital wher...
probably there's not. It's a pretty common task for an engineer to generate IC symbols and footprints for their EDA software (in your case, Proteus). It's less common to expect or make an electrical model for a DTMF chip. I'd argue that you probably can't without extensive measurements make one. Also, are you <em>sur...
https://electronics.stackexchange.com
701,050
[ "https://math.stackexchange.com/questions/701050", "https://math.stackexchange.com", "https://math.stackexchange.com/users/76718/" ]
I have been trying to prove this by induction on $n\in \mathbb{N}$, but this approach seemed to get me nowhere. I have a suspicion it might be necessary to express $\log{n}$ as $\int_1^n 1/x\text{ }dx$, but I could not build a rigorous argument from that. Any help greatly appreciated!
$$e^{H_n}=e^{1/1}e^{1/2}\cdots e^{1/n}\color{Red}{\gt}\left(1+\frac 11\right)\left(1+\frac 12\right)\cdots\left(1+\frac 1n\right)=n+1\gt n$$ $$\color{Red}{e^x\gt1+x}\tag{$x\gt0$}$$
Hint: The sum on the right is equivalent to an LRAM approximation with $\Delta x = 1$ of $\int_1^n \frac{1}{x} dx$. Since $\frac{1}{x}$ is decreasing, LRAM over-estimates. If you didn't know, LRAM = Left Rectangle Approximation Method. To estimate the area of a function $f(x)$ from $1$ to $n$ with $\Delta x = c$, we f...
https://math.stackexchange.com
163,630
[ "https://physics.stackexchange.com/questions/163630", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/40394/" ]
Nowadays, we now about $c$ the universal speed of light. This lets us define the notion of distance in terms of time (despite the fact that it works the opposite way for our common units.) Before this, how was time defined? Namely, if I said that two events had the same duration, what would I be saying? Note: I am als...
Time is what an ideal clock measures. So what's an ideal clock? It's something that measures time. In other words, physicists don't quite know what time is. That's okay. They don't quite know what space is, either. What they do know, and know very, very well, is how to measure both, and how the two (time and space) r...
Being able to sense phenomenon and being able to explain them are different animals. Consider how many millions of magnetic coils we employ in our daily lives. "Science" still cannot give a single, congruent, fully observable at every level, without referring to other phenomenon, explanation of WHY they work. Obviousl...
https://physics.stackexchange.com
55,084
[ "https://quant.stackexchange.com/questions/55084", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/47654/" ]
Recently I came across the following stochastic differential equation that &quot;predicts&quot; the value of a given stock: <span class="math-container">\begin{equation} dS_t = \mu S_t dt + \sigma S_tdW_t \\ S_t(0) =S_0 \end{equation}</span> where <span class="math-container">$S_t$</span> is the value of the stock, <sp...
The SDE you are describing is called the Geometric Brownian Motion. In the end its just a model, which underlies certain assumptions, which are usually not met in the real world scenarios. There are many further extensions and variation of SDEs for modelling prices f.e. including a jump component (jump diffusion models...
The GBM model is liked by practitioners for the modelling of stock prices for the following reasons: (i) The solution is log-normal, so the stock price distribution varies between zero and infinity: which is what we would expect from a real-world stock price. (ii) The model has independent increments, which means the f...
https://quant.stackexchange.com
76,660
[ "https://security.stackexchange.com/questions/76660", "https://security.stackexchange.com", "https://security.stackexchange.com/users/64016/" ]
I don't own a credit card but read much about fraud with stolen credit cards. Since I don't own one, I don't know how you exactly buy online using your credit card, so please correct me, if I am wrong (and I hope so). <ol> <li>Customer choses articles in online shop and puts them into shopping cart.</li> <li>Customer ...
The liability for a disputed transaction falls upon the merchant for Card-Not-Present transactions. Essentially, if you dispute a transaction, if the merchant doesn't have your signature, then if you persist they will end up footing the bill. By the same token, when a CNP merchant double bills you, they're going to e...
<h2>If you do it on a large scale, you get found out</h2> As with most crimes, there's really nothing that prevents you from doing it if you're determined, other than the risks and consequences of being found out. For small and rare events, it gets written off by the CC companies as a cost of doing business. For large...
https://security.stackexchange.com
18,791
[ "https://chemistry.stackexchange.com/questions/18791", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/4779/" ]
As the title says. What's the point of learning everything in 2D and trying to visualize and interpret stereochemistry, newman structures, isomers etc, with hundreds of hours wasted, when a 3d visualization suite could be used to teach everything instead, without any ambiguities as to what the structure looks like? The...
The problem is that 3d is not enough either. Most organic molecules can have multiple conformations, and drawing them all is impossible. However, influence of groups quickly reduces with distance growth, so only local 3d neighborhood is required most of the time, and it can be adequately described in 2d using shaded a...
Organic chemistry is often taught in 3D. There have long been 3D molecular models used in classrooms, as well as Fischer projections. Sometimes 2D is enough for a given situation. Maybe curved 4-dimensional spacetime is needed for some situations, vicinity of neutron stars or black holes lets say. Use the simpl...
https://chemistry.stackexchange.com
461,323
[ "https://physics.stackexchange.com/questions/461323", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/160629/" ]
What is the difference between a diode and a led? I know a led is a diode and I know how they are used and so on but I'm not really sure why a regular is not also light emitting. Therefore, what is the key aspect a diode is missing so it can emit light?
As others already pointed out, LEDs need to have a direct band gap, which means that the bottom of the conduction band and the top of the valence band must have the same momentum. This is necessary, because a photon at band gap energy carries almost no momentum, therefore the source and target state of the electron mus...
In semiconductor physics, there is 2 types of band gap, a direct band gap and an indirect band gap. Light-emitting and laser diodes are almost always made of direct band gap materials, and not indirect band gap ones like silicon.
https://physics.stackexchange.com
10,577
[ "https://physics.stackexchange.com/questions/10577", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/2578/" ]
So I was eating a plate of food one day and thought of entropy. As I understand the definition of entropy, it is the logarithm of the number of arrangements or states the object in question can be in, where the object is composed of N number of particles/food particles. Please edit my definition if this is wrong. So, ...
QEntanglement, the answer is simple. Your plate of food is not a closed system. For the system to close you need the plate, and the whole of you. with your chewing and digestion. Entropy increases in closed systems. Otherwise, think about it, could DNA exist, and the whole caboodle of organic life? We are factories th...
Entropy is the measure of the disorder or randomness in a system. In other words, if you drop a box of matches on the floor, the matches will fall all over the place, which is an increase in entropy. For an example of decreased entropy, if you build a house you are making order, not chaos, so the entropy-the disorder o...
https://physics.stackexchange.com
17,248
[ "https://physics.stackexchange.com/questions/17248", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/6261/" ]
Do you think it is possible to earn a PHD degree in Theoretical Physics on your own? I have a M. Sc. in Applied Computer Science but I really want to go in the direction of Physics. Is there a way one could perform a significant work in this field without a team of other PHD-students and/or lab experiments? Is it even ...
"Is it possible to earn a PHD degree in Theoretical Physics on your own?" I am still waiting for my PhD for 'solving', the Double Slit Experiment. But imagine my delight and satisfaction, when I saw Prof. Leonard Susskind, used a very similar diagram to mine, to explain the DSE in one of his own lectures. The simple...
This question does not belong here, but anyway. The answer is no. You need an accredited institution in which you will be under the supervision of some adviser and a committee that has to approve you thesis eventually. This is the way degrees are granted, you cannot get a degree on your own independent of any institut...
https://physics.stackexchange.com
17,213
[ "https://physics.stackexchange.com/questions/17213", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/1335/" ]
Some sources state that when the mass of a quark goes to zero, it allows for Spontaneous Breaking of Chiral Symmetry and gets a constituent mass of about $200\, \mathrm{MeV}$. Other sources state that when the masses of the light quarks go to zero, so does the pion mass. In this case, the explicit breaking of chiral s...
You are understanding correctly. In the massless up/down quark limit, chiral symmetry is restored, and the pion becomes massless but quarks are still confined, and baryons have about the same mass as they do now. This is exactly why the idea that the pion is made of quarks is nonsense. In the 1980s, many in the new ge...
Wow that theory stuff is all just amazing. Intuitively can we say a pion needs only one gluon to bind q anti-q pair whereas a baryon would have minimum of three gluons, one between each quark pair. Plus these 3 gluons have interactions amongst themselves bringing in another 3 gluons or so, whereas the pion gluon is alo...
https://physics.stackexchange.com
8,128
[ "https://dba.stackexchange.com/questions/8128", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/4571/" ]
We are just starting design for a new data warehouse and we're trying to design how our date and time dimensions will work. We need to be able to support multiple timezones (probably at least GMT, IST, PST and EST). We were initially thinking that we would have one wide combined date time dimension down to maybe 15 min...
Having the date and time separate will allow you to do aggregates by time much easily. for eg: if you want to run a query to find what time period of the day is most busy. This is much easily performed using a separate time dimension. Also, you should just have one timekey. Decide on either GMT/ EST time - then use th...
Just a follow up on how we decided to implement our DataWarehouse to support multiple Time Zones and be as efficient as possible: We chose to create a table of time zones (id, name, etc...) as well as a "Time Zone bridge" table that looks like this: <pre><code>time_zone_bridge --------------- date_key_utc time_key_utc...
https://dba.stackexchange.com
337,384
[ "https://softwareengineering.stackexchange.com/questions/337384", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/185297/" ]
While implementing one of my modules, I needed a singleton for one of my classes, say, ModuleManager. Instead of creating a class with singleton criteria, I created an interface ModuleManager to define the API and implemented this interface with an anonymous class so that there cannot be any other implementation or no ...
First of all, there can be <strong>other</strong> implementations of that interface. Nothing in your code would prevent people from implementing that interface multiple times. I would rather suggest to use an <strong>enum</strong> to implement that interface. As the JVM guarantees you that enum singletons are fully "c...
Acording to that rationale, every anonymous class is a singleton, since they have no name, you cannot instantiate it more than once. One issue is that they have to live inside another class. IMHO that is not an singleton. <strong>You can instantiate the class that contains it twice</strong> and though it's is true th...
https://softwareengineering.stackexchange.com
19,303
[ "https://biology.stackexchange.com/questions/19303", "https://biology.stackexchange.com", "https://biology.stackexchange.com/users/8129/" ]
I bought a blood pressure monitor (A&amp;D UA-851) which has the option to measure irregular heartbeat. I do understand what 'irregular' means, but why do irregular heartbeats happen and what are it's implications short and long term?
The normal cardiac cycle is comprised of two distinct phases: <strong>the systolic phase</strong> in which the heart contracts, ejecting the blood, followed by the <strong>the diastolic phase</strong> when the cardiac muscle relaxes, refilling the heart with blood. This cycle is assured by specialised cardiomyocytes (...
Very simply putting, irregular heat beat means that the pulse is not regular. It can be diagnosed by checking your pulse clinically. Irregularities are further classified as: <ol> <li>Regularly Irregular: this occurs in heart blocks where every second or third beat is skipped regularly causing a pattern. Usually as...
https://biology.stackexchange.com
116,627
[ "https://math.stackexchange.com/questions/116627", "https://math.stackexchange.com", "https://math.stackexchange.com/users/26302/" ]
How do I integrate $\displaystyle\int (x^2 + 2)\sqrt{1-x} \; dx$ ? I have feeling substitution might be used, but I just can't put my finger on it... Thank you.
The ‘problem child’ in your integrand is $\sqrt{1-x}$; that should immediately suggest substituting either $u=\sqrt{1-x}$ or $u=1-x$. The latter looks simpler, so let’s try it and see what happens. We get $du=-dx$, which is nice and simple, and it’s easy enough to solve for $x$ to find that $x=1-u$. Now substitute $1-u...
Note that $$x^2+2=(1-x)^2-2(1-x)+3,$$ which implies that $$(x^2+2)\sqrt{1-x}=(1-x)^\frac{5}{2}-2(1-x)^{\frac{3}{2}}+3(1-x)^{\frac{1}{2}}.$$ Therefore, let $u=1-x$, we have $dx=-du$, which implies that $$\int (x^2+2)\sqrt{1-x}dx=-\int u^\frac{5}{2}-2u^{\frac{3}{2}}+3u^{\frac{1}{2}}du$$ $$=-\frac{2}{7}u^{\frac{7}{2}}+\fr...
https://math.stackexchange.com
249,924
[ "https://mathoverflow.net/questions/249924", "https://mathoverflow.net", "https://mathoverflow.net/users/16356/" ]
I think it's well known that if $X\subset\mathbb{P}^3$ is a smooth cubic surface and we take the projection $\pi: X\rightarrow \mathbb{P}^2$ from a point off the surface, then it's branched over a sextic curve with 6 cusps. Why is this true? In particular, I'm not seeing the 6 cusps. <hr> Example of a statement of...
A slightly simpler way: if you project from $(0,0,0,1)$, after a change of coordinates you can write the equation of your surface as $T^3+PT+Q=0$, where $P$ and $Q$ are forms of degree $2$ and $3$ in $X,Y,Z$. The branch curve is given by $4P^3+27Q^2=0$, and it is fairly easy to see that the 6 points given by $P=Q=0$ ar...
If you put the point from which you are projecting at infinity in the $z$ axis, you can write your projection in affine coordinates as $\pi: (x,y,z) \mapsto (x,y)$. If the surface is given by a cubic $f=0$, then the ramification locus of $\pi$ is given by $f = \partial f/\partial z = 0$. Since $\partial f/\partial z$ i...
https://mathoverflow.net
30,969
[ "https://electronics.stackexchange.com/questions/30969", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/9508/" ]
I know next to nothing about electronics, so treat me accordingly :D I have these terminal blocks: <img src="https://i.stack.imgur.com/xdIEi.jpg" alt=""> To the best of my understanding, wires go in, and the levers clamp down to hold the wires in the place. 1) The levers are really stiff. Am I supposed to be able ...
They will probably be even stiffer to operate with the wires in place. The stripped wire ends go in the holes. Two sets of pins are provided to make a secure connection to the PCB. Such connectors are often end-stackable, so you should not have to cut them. If they are not end-stackable, find some that are, or use l...
To add to what Leon said, look at the opposite side of the connector to where the pieces of plastic are sticking out. There are probably grooves or slots there intended to mate with the plastic tabs on another connector. This is what is called <i>stackable</i>. You may have to slide two pieces together to get them t...
https://electronics.stackexchange.com
144,118
[ "https://softwareengineering.stackexchange.com/questions/144118", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/45857/" ]
I've been working in multiteam groups for as long as I've been a web developer, and in my experience, a team can be a lonely soldier or several people; generally a company will have multiple teams working on different projects and once the project is out in the wild, any team can perform maintenance on it. This is a s...
I worked for a fast-growing startup company that went from under 100 to 500+ people in two and a half years, where the issue of knowledge sharing quickly became a problem. The company built a strategy that worked reasonably well, and included three key components: <ul> <li>Documentation</li> <li>Standardization</li> <...
As programmers we sometimes erroneously look for technical solutions to what is fundamentally a people problem. There are always going to be inefficiencies in a large group. The best solution I'm aware of is the good old fashioned "grapevine." I ask the person I feel is best suited to answer a particular question. ...
https://softwareengineering.stackexchange.com
555,178
[ "https://physics.stackexchange.com/questions/555178", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/208138/" ]
I am familiar with isolated systems. They don't interact with the environment and no energy transfer takes place across the boundary of the system. My textbook says, <blockquote> <em>In an isolated system, if there are only conservative forces acting, its mechanical energy (potential &amp; kinetic) is conserved. Wh...
<blockquote> What I don't understand is, the book says no energy transfer takes place across the boundary of an isolated system. After the book and the surface get warm, they cool down after some time. Where does the internal energy of the system go? If it transfers to the environment, doesn't it contradict t...
<blockquote> After the book and the surface get warm, they cool down after some time. Where does the internal energy of the system go? </blockquote> It goes further into both bodies. The added internal energy is generated at the surface and then moves by conduction to the farther regions of the bodies. As the energy...
https://physics.stackexchange.com
76,892
[ "https://softwareengineering.stackexchange.com/questions/76892", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/10149/" ]
I am in the process of trying to identify a suitable project for my final year at university. How important is it that the project be unique? I really want to do a project with the Kinect and am eagerly awaiting the official SDK. As yet I am struggling for an idea. However, I have looked at kinecthacks.com to see wh...
It's perfectly ethical to take an idea from somewhere as long as: <ol> <li>You don't try to pass it off as yours.</li> <li>(Particularly important for university projects) You implement it yourself, or at least give due credit to those you borrowed from (e.g. libraries you used; open source projects you adapted). A go...
<blockquote> Would you think it ethical to take one of these ideas and implement yourself? Obviously try to implement additional functionality on top of what is already there? </blockquote> It's ethical as long as you credit the source. Any computer work builds on the work of others. You didn't write the operating...
https://softwareengineering.stackexchange.com
55,712
[ "https://quant.stackexchange.com/questions/55712", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/48096/" ]
Can you please explain <code>Martingale Representation Theorem</code> in a non-technical way that what is it and why is it required? Most of the stuffs I studied so far are quite technical, and I failed to grasp the underlying intuition.
Let me give my intuition as a former Electrical Engineer. This is going to be very sloppy. Suppose you have a Brownian Motion with increments (or &quot;noise term&quot; in EE language) <span class="math-container">$dB_t$</span>. Obviously you can generate a martingale by integrating these noise terms <span class="math-...
First, let us be clear with the fact that if a process is a martingale for some Probability measure, it may not be a martingale under a different probability measure. (refer Girsanov's theorem).<br> <br> Now intuitively, the Martingale Representation theorem (MRT) says that if a process <span class="math-container">$M(...
https://quant.stackexchange.com
123,857
[ "https://dba.stackexchange.com/questions/123857", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/80262/" ]
So we have a bad external application that connects to the database, executes a stored procedure and gets an answer. It never releases the database connection. I need a script that either kills all of the sessions for one user or I need a script that kills all of the sessions that have been inactive for x hours for a...
There's not really a reliable way to pin sessions to a specific database (<code>sysprocesses</code> has this, but it relies on an active query's database context, and <code>dm_exec_sessions</code> has <code>authenticating_database_id</code>, but this relies on the connection string, login's default database, etc). Tha...
Aaron, thank you - that led me to come up with a slightly modified solution. I commented out the login_name because I won't know it at execution time. Put in the app_name because that is constant. And changed <code>last_request_start_time</code> to <code>last_request_end_time</code> (just in case). Now off to package...
https://dba.stackexchange.com
93,452
[ "https://physics.stackexchange.com/questions/93452", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/21904/" ]
Suppose there is a lever arm fixed at one end, and it is parallel to the ground. There is an object resting somewhere on top of the lever arm (the object is not attached to the lever). At the moment when the lever arm is released, does the object have any angular velocity? According to my physics teacher, the answer is...
In general, invariance of the action under some transformations, such as Lorenz rotations, is an extra condition that we impose on a theory. This is not related to the extreme condition that just gives trajectories along which the classical evolution goes. In your case, I guess, there is some confusion in formulation...
The action is obviously not invariant because energy is different in different frames. What's invariant is the trajectory that makes the action stationary. Specifically, transforming frames will add a total derivative to the Lagrangian, thereby adding a constant to the action. See, for example, the first few pages of <...
https://physics.stackexchange.com
164,529
[ "https://softwareengineering.stackexchange.com/questions/164529", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/61509/" ]
I have written a small Java Swing desktop application. It seems like a natural step to port it to Android since I am interested in learning how to program for that platform. I believe that I can reuse some of my existing code base. (Of course, exactly how much reuse I can get out of it will only be determined as I star...
I'm actually working on the exact same thing at the moment. Personally, I find it easiest to keep everything in one repo, one branch. I use separate java packages for common, swing, and android code. I have interfaces for all the calls from the common package into the GUI packages, so the common code has no idea whi...
The correct way to go is to divide your code in three parts: common, Swing-desktop, Android. Whether you use one repo or three is up to you; three repos might make sense if their nature is going to be different: different committers, different branching/versioning policies, etc. or perhaps the repos are going to be hug...
https://softwareengineering.stackexchange.com
138,857
[ "https://softwareengineering.stackexchange.com/questions/138857", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/47546/" ]
In a stackOverflow question I have read that using a GUI designer program can generate lots of messy code and is considered to be a bad practice unless you're making smaller programs. My question is why and how. Is it bad to use a GUI designer program? Why? Additional details: <ul> <li>Programming on a Windows platf...
<strong>It is not bad practice to use GUI designer to design your forms, GUI. Esp in Visual Studio. They are there for this purpose and are extensively used.</strong> In web development, it is a different story. It is a bad practice to use GUI designer (for example Microsoft Front Page now superseded by WebMatrix). Th...
For a big and medium project, they should not be used, because the code they generate is not very nice to maintain. Unless you don't plan to clean up the code generated by a GUI designer, you are better without it. However, they are very good in next cases : <ul> <li>to create something quick and dirty (maybe for a p...
https://softwareengineering.stackexchange.com
28,305
[ "https://cs.stackexchange.com/questions/28305", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/20017/" ]
I have a really nasty problem (for me) at hand and I was wishing some of you may know an efficient algorithm to solve it. Thanks to all of you in advance. <hr> <h2>My problem</h2> I have a set of elements (that I would describe as a graph) that may be of three categories: <ul> <li>Provider nodes</li> <li>Consumer n...
OK, it sounds like your problem is the following: <blockquote> You have an undirected graph. Each vertex is either a consumer or a producer. Say that a consumer $c$ is connected to a producer $p$ if there is a path from $c$ to $p$ where all intermediate nodes are consumer nodes. You want to output a list of pairs...
I can't tell if my answer will be applicable because the question is not precisely defined. But let me make some guesses here: <strong>Input</strong> graphs with 2 types of vertex. <ol> <li>Provider node (P)</li> <li>Consumer node (C)</li> </ol> The edges are <strong>constrained</strong> by: <ol> <li>(P) can connec...
https://cs.stackexchange.com
2,598,040
[ "https://math.stackexchange.com/questions/2598040", "https://math.stackexchange.com", "https://math.stackexchange.com/users/23249/" ]
Suppose that $f:[0,\infty)\to[-1,1]$ is a continuous function at zero and at all but finite number of points such that $f(0)=1$ and $\int_0^\infty f^2(x)dx&lt;\infty$. Let $\{a_n\}_{n\ge1}$ be a sequence of positive integers such that $a_n\to\infty$ as $n\to\infty$. The right Riemann sum $$ \frac1{a_n}\sum_{j=1}^{a_n}f...
I'm not sure why you square $f.$ Why not just assume $f:[0,\infty)\to [0,1]$ continuously, and $\int_0^\infty f(x)\,dx &lt; \infty?$ A counterexample given by Alex Francisco shows the answer to your question is no. I'm going to describe another answer that uses the same idea, but may be simpler. Over each $n=2,3,\dot...
The last proposition is false. Define$$ f(x) = \begin{cases} \sqrt{-2x + 1}; &amp;\displaystyle 0 \leqslant x \leqslant \frac{1}{2}\\ \displaystyle \sqrt{\frac{1}{n} - \frac{2^n}{n} |x - n|}; &amp;\displaystyle \exists n \in \mathbb{N}_+,\ |x - n| &lt; \frac{1}{2^n}\\ 0; &amp; \text{otherwise} \end{cases}. $$ The gra...
https://math.stackexchange.com
2,450,837
[ "https://math.stackexchange.com/questions/2450837", "https://math.stackexchange.com", "https://math.stackexchange.com/users/426335/" ]
Say you have $50$ students in a class. You want to divide them into $10$ groups of $5$. How many different ways can you do this?
First method: Sort people into ten <em>labeled</em> groups and then recognize that you have overcounted. There are $\binom{50}{5,5,\dots,5}=\binom{50}{5}\binom{45}{5}\binom{40}{5}\cdots\binom{10}{5}=\frac{50!}{(5!)^{10}}$ ways that you can do this. Now, we recognize that each outcome we actually counted $10!$ differe...
The first $5$ students can be chosen in $\binom{50}{5}$ ways. The next $5$ in $\binom{45}{5}$ ways. The next $5$ in $\binom{40}{5}$ ways. ... The next $5$ in $\binom{10}{5}$ ways. The last $5$ can only be chosen in $1$ way. These $10$ groups of $5$ could have been chosen in $10!$ ways \begin{eqnarray*} \frac{1...
https://math.stackexchange.com
1,090,253
[ "https://math.stackexchange.com/questions/1090253", "https://math.stackexchange.com", "https://math.stackexchange.com/users/203291/" ]
Prove by induction $\forall n \in \mathbb{N} \cup \{0\}: \sum_{k=0}^{n} \frac{k}{2^{k}} = 2 - \frac{n + 2}{2^{n}}$ <strong>Step 1:</strong> Show true for n = 0: LHS: $\frac{0}{2^{0}}$ = 0 RHS = $2 - \frac{0+2}{2^{0}}$ = 0 <strong>Step 2:</strong> Show that it is true for $n = p$, it is true for $n = p + 1$ Startin...
You've just made a sign mistake: $$p+1-2(p+2)=-p-3=-(p+3)$$ and not $-(p-3)$. And then you're done, since $p+3=(p+1)+2=n+2$. Good job otherwise.
$\dfrac{p+1}{2^{p+1}} + 2 - \dfrac{p + 2}{2^{p}} = 2 + \dfrac{p + 1 - 2(p+2)}{2^{p+1}} = 2 + \dfrac{(-p - 3)}{2^{p+1}} = 2 - \dfrac{p+3}{2^{p+1}} = 2 - \dfrac{(p + 1)+2}{2^{p+1}}.$
https://math.stackexchange.com
8,514
[ "https://scicomp.stackexchange.com/questions/8514", "https://scicomp.stackexchange.com", "https://scicomp.stackexchange.com/users/5173/" ]
I was wondering why there are no online or offline computational science contests? At least I couldn't find much by googling. I mean, like a topcoder for computational sciences. I assume one reason is providing massive computational power for few areas of study which costs lot of money. Other might be to formulate righ...
I would say that there are a number of reasons why there are no computational science contests besides the potentially massive computational resources required. <ol> <li>Time limits: Writing scientific computing code is usually not something that you want to rush. A lot of emphasis is on making sure it is correct, and...
There is a lot of food for thought in this question. I would like to differentiate a bit with respect to the character of the contests. The subject of contests I know is fairly inconsequential. There are spelling bees, when it comes to mathematics, there are contests in symbolic integration, marshmallow eating contest...
https://scicomp.stackexchange.com
692,893
[ "https://physics.stackexchange.com/questions/692893", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/327381/" ]
I am doing a thought experiment in which two bodies are rigidly connected to each other and my force sensor is rigidly located between these two bodies. My system accelerates and brakes at regular intervals. Now I am wondering what the force sensor is measuring. On the one hand, of course, the resulting force <span cla...
To me you are describing the scenario in figure a) below, where <em>all</em> the connection forces go through the sensor <img src="https://i.stack.imgur.com/DO7v1.png" alt="fig_a" /> But the sensor has two parts, the base and the active part, separated with a little spring. More importantly, each part of the sensor has...
The <span class="math-container">$F_{resulting}$</span> is not relevant for the measurements. We could imagine for example an accelerated rocket with several tons, a sensor and a weight of some kg inside. Or after loosing some fuel, a ligther rocket with the same acceleration. The results of the measurements don't chan...
https://physics.stackexchange.com
55,687
[ "https://security.stackexchange.com/questions/55687", "https://security.stackexchange.com", "https://security.stackexchange.com/users/44515/" ]
A file is encrypted and placed on a secure FTP server. An MD5 hash is taken of the file and also placed on the FTP server. A userlogs in to the server and downloads both files, however, the hash fails to match the archive. In this case, what basic goal of a cryptosystem has failed? I have been trying to answer this qu...
This is a flawed system if its meant to ensure data wasn't tampered by a malicious attacker. Any attacker who can tamper with the transmission of the file (or the file on the FTP site), could have similarly tampered with the transmission of the md5sum (or the storage of the md5sum on the site) and changed it to some...
There are a lot of ways to look at security questions, and rarely a "right" answer. In this case, you might want to start by listing out what the basic goal(s) of the cryptosystem is/are; i.e., "what's the point?". From there, you can consider what is not being fulfilled if the hash doesn't match. In this case, you'r...
https://security.stackexchange.com
23,633
[ "https://chemistry.stackexchange.com/questions/23633", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/6925/" ]
$$\mathrm dG &lt; V\,\mathrm dp - S\,\mathrm dT$$ For a process at constant pressure and temperature ($\mathrm dp = \mathrm dT = 0$), and in the absence of any non-pV work, $\mathrm dG &lt; 0$. Since energy cannot be created or destroyed (and Gibbs free energy is a measure of energy) where does the energy go when this...
If you want to track where the energy is going, do a first-law analysis (compute heat and work for a given change in internal energy or enthalpy). If you want to predict whether a process occurs spontaneously or not, or you want to study an equilibrium, the second law is the tool you need. It's convenient to apply th...
Imagine you have a divided insulated container. On one side is helium gas and on the other side is neon gas. Both sides are uniformly at standard temperature and pressure. You remove the divider. What happens? The gases mix, because there are greatly more microstates we would consider "mixed" compare to not mi...
https://chemistry.stackexchange.com
178,234
[ "https://physics.stackexchange.com/questions/178234", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/57303/" ]
Consider for example a mass matrix $M$, $\lambda$ one eigenvalue and $X$ a corresponding eigenvector. Then $[M]=\text{mass}$ (the brackets indicate the "unit operator"), and $MX=\lambda X$ so $[M][X]=[\lambda][X]$, so $[\lambda]=\text{mass}$. That's why for example in oscillators, the pulsations $\omega$ are such that...
The units of the eigenvector can be anything you choose. Normally you want them to be dimensionless, but other choices can be sensible on occasion. The reason that any dimension is valid is because if $X$ is an eigenvector, then $\mu X$ is also an eigenvector for any scalar $\mu$, which can in principle have any dimen...
Not just with eigenvectors, but with any vector. I always wondered when you decompose any vector into magnitude and direction who gets the units. Is it $(1,0.1,0)\cdot3\mathrm{m}$ or $3\cdot(1\,\mathrm{m}, 10\,\mathrm{cm},0)$ ? I think it is up to the user to interpret a decomposition any way they see fit. With eige...
https://physics.stackexchange.com
38,291
[ "https://physics.stackexchange.com/questions/38291", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/12035/" ]
<img src="https://i.stack.imgur.com/6EXpa.png" alt="enter image description here"> Why does the object not go inward, into the circle if the acceleration is inward? I think its because the velocity to outward? So they sort of cancel each other out? But if the speed is kept constant and the acceleration is inward, won'...
I suspect Luboš's answer may be a bit complex for you so I'll attempt a simpler explanation (if I'm wrong just ignore this answer). When you say &quot;I think its because the velocity to outward&quot; you're getting close. To show what's going on I've zoomed in on the diagram you posted in your question. <img src="http...
No, a uniform circular motion has both constant speed and constant acceleration and it will continue indefinitely, never going inwards. If there were no inward acceleration, the object would move along the straight line in the direction of $\vec v$, and therefore away from the circle. To keep the object on the circle,...
https://physics.stackexchange.com
12,834
[ "https://cogsci.stackexchange.com/questions/12834", "https://cogsci.stackexchange.com", "https://cogsci.stackexchange.com/users/10073/" ]
In computer programming, when algorithms are using loops/recursion without an exit condition, the algorithm will never end or get out of resources. How does the brain work around getting into endless loops/recursions due to interconnected nets, i.e. when there are circularities in the nets? For example, neuron A activ...
The brain often does create looping conditions. When these loops involve a large number of neurons, we call it a seizure. An analogy in electrical engineering would be a feedback loop -- such as literal feedback between a microphone and speakers. In the brain, fortunately, these loops are usually self-dissolving since ...
The brain is full of neurotransmitters. These neurotransmitters are connected to more neurotransmitters, etc. And they're not just one-way. One thought leads to another which could lead back to the initial thought. And when you learn, you create new neural pathways which helps.
https://cogsci.stackexchange.com
427,994
[ "https://electronics.stackexchange.com/questions/427994", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/199610/" ]
Why do certain ICs like 74ALS174 use an inverter so as to make a Positive-going clock transitions occur instead of Negative-going ? Why can't we just save expense of an inverter by removing it and allowing the more natural Negative-going clock transitions? (CP in image) <img src="https://i.stack.imgur.com/pOSEM.jpg" a...
Note that in the specific example of the '174 that you show, the flip-flops themselves are shown with inverted clock inputs (falling edge), so the net effect of the inverting buffer is to make the chip overall work on the rising edge of the clock. As Tim Wescott mentioned in a comment, this sort of detail is normally ...
I suspect that it is partially the whim of the original designer, and then after that everyone selling the chip was locked into the pin-for-pin compatibility. The other part is because if there's internal fan-out (as there is here) you'd want to buffer the incoming signal, and an inverter is cheaper than a buffer. (In ...
https://electronics.stackexchange.com
438,806
[ "https://mathoverflow.net/questions/438806", "https://mathoverflow.net", "https://mathoverflow.net/users/95347/" ]
<blockquote> Is it possible to iterate elementary embeddability and reflect on those stages that are elementary embeddable to themselves? </blockquote> The following is a formal capture of that idea: To the language of <span class="math-container">$\sf ZF$</span> (i.e., mono-sorted <span class="math-container">$\sf FOL...
<span class="math-container">$\newcommand\Ord{\mathit{Ord}}$</span>The edit to the question has changed it enough so I think it deserves its own answer. I assume that in reflection we have <span class="math-container">$\forall \vec{x} \in W_\alpha \, (\phi \to \phi^{W_\alpha})$</span> holds for all ordinals <span clas...
Any model of <span class="math-container">$ZF$</span>+stationary proper class of <span class="math-container">$I3$</span> ordinals (whose consistency strength is at most <span class="math-container">$ZF$</span>+<span class="math-container">$I2$</span>) where <span class="math-container">$W_α$</span> is listing of <span...
https://mathoverflow.net
49,926
[ "https://physics.stackexchange.com/questions/49926", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/18739/" ]
Assuming no sliding and that the shoulder is 1.2m from the feet, what force is required to topple a person weighing 70 Kg standing with his feet spread 0.9 m? If possible, please include an explanation about your answer.
Approximate the person with a brick with a width of 0.9 m and a height of 1.2 meter. The torque around the tipping point caused by gravity is $mg\cdot l$, where $l$ is the horizontal distance from the tipping point to the center of mass of the brick, i.e. half the brick width assuming it has a uniform density. You need...
<ul> <li>The counterclockwise torque <span class="math-container">$T_a$</span> about this point produced by the applied force is:</li> </ul> <span class="math-container">$$T_a=F_a \cdot h =F_a \cdot 1.2 m$$</span> <ul> <li>The opposite restoring torque <span class="math-container">$T_w$</span> due to the person’s weigh...
https://physics.stackexchange.com
29,212
[ "https://softwareengineering.stackexchange.com/questions/29212", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/-1/" ]
Especially when writing new code from scratch in C, I find myself writing code for hours, even days without running the compiler for anything but an occasional syntax check. I tend to write bigger chunks of code carefully and test thoroughly only when I'm convinced that the code does what it's supposed to do by analys...
It REALLY depends on the aspect of the project you're working on. <ul> <li>When I do anything with OpenGL (which works like a state machine), I constantly compile and run to make sure that I didn't accidentally screw up anything. Setting one value without remembering to reset it at the end of a function can easily mak...
Personally, I must work in small chunks because I am not smart enough to keep hours worth of coding in my biological L1 cache. Because of my limited capabilities, I write small, cohesive methods and design objects to have very loose coupling. More powerful tools and languages make it easier to code longer without build...
https://softwareengineering.stackexchange.com
1,761,173
[ "https://math.stackexchange.com/questions/1761173", "https://math.stackexchange.com", "https://math.stackexchange.com/users/266108/" ]
Is this a true statement? (I found it as a theorem in a paper) <blockquote> If $S$ is a subset of a Hilbert space $H$ then $S^\perp$ is closed. </blockquote> If it were true then $(S^\perp)^\perp$ would be closed, that is $S$ would be closed. How can two complementary sets be closed? So to me it seems it is false....
It's true that $S^\perp$ is closed. This is trivial from the definition. This does not imply that $S$ is closed, because in general $S\ne S^{\perp\perp}$. In fact $S=S^{\perp\perp}$ if and only if $S$ is a <em>closed</em> <em>subspace</em> of $H$; in general $S^{\perp\perp}$ is the closure of the span of $S$.
Yes, this is true. Indeed, let $t_n$ be a sequence in $S^{\perp}$ and let $t$ be its limit. We want to show that $t \in S^{\perp}$. By the continuity of the inner product, we have that, for all $s \in S$ $$ \langle t, s \rangle = \lim_{n \to \infty} \langle t_n, s \rangle=0 $$ so that $t \in S^{\perp}$. The equalit...
https://math.stackexchange.com
101,546
[ "https://softwareengineering.stackexchange.com/questions/101546", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/27714/" ]
If this title is ambiguous, feel free to change it, I don't know how to put this in a one-liner. <strong>Example:</strong><br> Let's assume you have a html template which contains some custom tags, like <code>&lt;text_field /&gt;</code>. We now create a page based on a template containing more of those custom tags. Wh...
First of all, thanks for all your answers. It is even nicer here than on stackoverflow because the answers are having more details in general and can be discussed better. I have now found a more-or-less-solid solution for this (more-or-less because I am still experimenting with it) which I got accidentally while debug...
for your reference you can see Active directory implementation it is pretty much the same thing. but i would prefer you must use hierarchical database for this purpose. you problem has solution is in <strong>No-SQL</strong> database. there are many databases with <strong>key value store</strong> schema under no-SQL um...
https://softwareengineering.stackexchange.com
18,315
[ "https://engineering.stackexchange.com/questions/18315", "https://engineering.stackexchange.com", "https://engineering.stackexchange.com/users/2157/" ]
I'm looking for the best orientation (North-East-South-West) of a greenhouse (simplifiable as a rectangular solid).<br> My question is more specifically about the <strong>sun position effects</strong> (over the times of the day and over the days of the year).<br> With <em>sun effect</em> I mean both <strong>solar expos...
In general: if you are in the northern hemisphere, the sun will pass through the southern part of the sky. Therefore, a greenhouse which is built onto the side of an existing structure will be placed against its south-facing wall so it is not in the shadow of that structure, as it would be if it were affixed to its nor...
The angle will also depend on your objective. I use my green house to winter over various plants so my angle is set to maximize winter light , normal to the sun in mid November/January. If you are growing bedding plants from seed ,you probably want maximum sun in March / April ( northern hemisphere). I found trying to ...
https://engineering.stackexchange.com
70,109
[ "https://chemistry.stackexchange.com/questions/70109", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/35670/" ]
I know that a functional group gives definitive property to an organic compund. But my text book claims carboxylic acid is a functional group but isnt carboxyl the functional group with a formula -COOH , is the text book wrong or am i missing something? And similarly isnt hydroxyl the functional group of alcohols rathe...
Your books statement that "carboxylic acid is a functional group" doesn't seem quite right to me. I think it's better to say that a carboxylic acid is an organic molecule containing a carboxyl functional group. Similarly, I wouldn't say that an alcohol is a functional group, but that an organic molecule containing a...
Carboxyl, hydroxy, chloro, amino etc are prefixes which represent the functional group used. They are standard 'PREFIXES', note that, and not the functional groups themselves. They represent the functional group in the compound while naming.
https://chemistry.stackexchange.com
178,314
[ "https://softwareengineering.stackexchange.com/questions/178314", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/57027/" ]
In Objective-C, there are several methods like <code>initWithContentsOfFile:encoding:error:</code> where one passes in a reference to an <code>NSError</code> object for the <code>error:</code> parameter. In this example, the value of the <code>NSError</code> object passed in can change based on what goes on at runtime ...
In the case of the <code>NSString initWithContentsOfFile:encoding:error:</code> method that you cite, an error is handled by returning <code>nil</code> from the initializer. If this happens, then you can interrogate the <code>error</code> object (if you provided one) to get details about the error. <pre><code>NSError ...
IMO (emphasis on the O), you should avoid out parameters whenever you can. I don't know anything about Objective-C, but if this were Java you'd throw an exception instead of using an out parameter. Exceptions were created to keep your exceptional logic out of the way of normal flow control. In theory, this makes t...
https://softwareengineering.stackexchange.com
1,347,323
[ "https://math.stackexchange.com/questions/1347323", "https://math.stackexchange.com", "https://math.stackexchange.com/users/252053/" ]
I have an integral that I am not sure how to solve with the comparison theorem to see if it is divergent or convergent. $$\int_1^\infty\frac{e^{-2x}}{\sqrt{x+16}}\;dx$$ How can I solve this with the comparison theorem to see if it is divergent or convergent?
Call the vector $\mathbf{n}$, say. Then you could refer to the plane as a "normal plane to $\mathbf{n}$", or "normal plane to $\mathbf{n}$ through $O$" if you wish to specify the location of the plane relative to the origin as in your post.
Calling the plane/vector "perpendicular" to another vector is common and perfectly acceptable. Also common is the word "normal" (e.g. "the vector $(1, -1, 1)$ is normal to the plane $x - y + z = 3$.")
https://math.stackexchange.com
543,861
[ "https://physics.stackexchange.com/questions/543861", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/260641/" ]
Because linear velocity is a vector which I can agree as it's because of the direction of the displacement but in case of angular velocity it's angles covered in certain time but angles got no direction then how come it got any direction P.S I came to know it's something of a pseudo vector but didn't understand it s...
In the simplest case, a point mass or particle or any other suitable abstraction at (<span class="math-container">$\vec r$</span>) moving (at velocity <span class="math-container">$\vec v$</span>) through space (with an origin), one can define an angular velocity about the origin: <span class="math-container">$$ \vec ...
If a point moves in a circle , this circle lies on a plain, now if you want to describe tiis plain, you could give to vectors in this plain, you have many possibilities to chose them. or you take a single vector perpendicular to the plain and it describes the plain, so to dircribe the motion of the point in the plain, ...
https://physics.stackexchange.com
192,336
[ "https://security.stackexchange.com/questions/192336", "https://security.stackexchange.com", "https://security.stackexchange.com/users/122088/" ]
Lately, I was watching an online video about Microsoft Certified Solutions Associate (MCSA) and in one of the videos it says "<em>removing GUI from Windows server makes it less vulnerable.</em>" Is that true? If so, how does removing the GUI have that effect?
Removing the GUI is useful and recommended. It will remove unused components, a lot of libraries, and makes the install size smaller. How does this make it less vulnerable? Fewer components equal less attack surface. A vulnerability on a GUI component will not affect you. Attacks relying on GUI components won't work ...
Removing the GUI also has the side effect of making it a bit more "human safe" because put bluntly, it makes the OS more idiot proof. There are countless stories of small businesses having users reading mail and browsing the internet on the company DC. The user opens a bad attachment and suddenly everything is on fire...
https://security.stackexchange.com
322,602
[ "https://electronics.stackexchange.com/questions/322602", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/158951/" ]
Can you simply increase the voltage going to the antenna, or is it more complicated than that?
An antenna doesn't have range. A transceiver <em>system</em> has a range of operation. Often, that range is limited by the minimum SNR (Signal-to-Noise) that the receiver needs to operate successfully. In that case: Increasing the transmit power (which is what increasing signal voltages does) will increase the receive...
NASA uses 200 foot dishes in Madrid, Canberra and Goldstone, in the DeepSpace network. Despite these parabolic dishes, and liquid-helium-cooled maser-amplifiers up in the dish, datarates from Pluto were just a few hundred bits per second. Normal antennas are often single quarter-wave ( 1 inch for WIFI at 2.4MHz) piec...
https://electronics.stackexchange.com
179,281
[ "https://physics.stackexchange.com/questions/179281", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/42270/" ]
why is heat capacity at constant pressure higher than heat capacity at constant volume? It is supposed to be this way, since if you increase $C_p$ in volume work is being done, in other case not. This is not clear to me either...
Recall two things... <ul> <li>First that the 1st law is conservation of energy. </li> <li>Second that temperature is a non-decreasing function of internal energy.</li> </ul> So if we take two identical samples of gas and add the same heat $Q$ to each (increasing their internal energies), but allow one to do work $W$ ...
I still don't feel it on an intuitive level... When a gas is heated at constant volume,all the heat supplied is used to increase the internal energy of the gas.(since the volume is constant the gas cannot expand so) When a gas is heated at constant pressure ,the gas expands.It does work against the external pressure...
https://physics.stackexchange.com
548,005
[ "https://physics.stackexchange.com/questions/548005", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/244906/" ]
In many books, I've found that MOLAR HEAT CAPACITY <span class="math-container">$(C)$</span> is defined as the <strong><em>amount of heat required to change the temperature of 1 mole of a substance by 1K</em></strong>, which mathematically translates to <span class="math-container">$C=\frac{q}{n\Delta T}$</span> and ...
BOTH. In an isochoric process, the gas does not do any work - since <span class="math-container">$W=P\Delta V$</span> and the volume, being constant renders the work done zero. So,the first law of thermodynamics becomes, <span class="math-container">$$Q=\Delta U+W$$</span> Since <span class="math-container">$W=0$</spa...
The precise definition of Cv involves the partial derivative of U with respect to temperature at constant volume: <span class="math-container">$$C_v=\frac{1}{n}\left(\frac{\partial U}{\partial T}\right)_V$$</span>For an ideal gas, U and <span class="math-container">$C_v$</span> are functions only of temperature, so it...
https://physics.stackexchange.com
26,350
[ "https://mathoverflow.net/questions/26350", "https://mathoverflow.net", "https://mathoverflow.net/users/4971/" ]
I'm wondering (hoping) if an inequality is true. Please can anyone help me? Let $V$ be a complex vector space $dim_{\mathbb{C}}(V)=n$ with a hermitian scalar product $h$. Let $v,a, b \in V$. Is it true that $(h(v,v)h(a,a)-{|h(v,a)|}^{2})(h(v,v)h(b,b)-{|h(v,b)|}^{2})\geq |(h(v,v)h(a,b)-h(a,v)\overline{h(b,v)}|^{2}$...
Yes. The case where $v=0$ is trivial so suppose $v\ne0$. Consider the projection map from $V$ to the hyperplane orthogonal to $v$ and let $a'$ and $b'$ be the images of $a$ and $b$ under this projection. Then your inequality reduces to $$h(a',a')h(b',b')\ge\vert h(a',b') \vert^2,$$the Cauchy-Schwarz inequality.
Cauchy-Schwarz in the orthogonal complement to v?
https://mathoverflow.net
74,179
[ "https://mechanics.stackexchange.com/questions/74179", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/25720/" ]
Let's say I drive for a total of 20 mins, round trip, each day for 4 days a week (a normal commute to the train station each day for work). The problem is that it's likely not enough time to hit operating temperature and remain at operating temperature long enough to boil off the condensation that forms inside of the ...
As jwh20 states, there's a lot of factors here. However, 20 minutes of continuous driving should be enough to get rid of any condensation in the oil in most vehicles. While the coolant may take five minutes to get to temperature, it takes the oil longer. I say "most vehicles" because there are always those outliers whi...
I can't say that I have ever seen a hard-and-fast answer to this because there are many variables. Things like the engine's normal operating temperature, how much moisture we're talking about, etc. I've heard and read that about an hour of driving AFTER you get the engine to operating temperature will be sufficient t...
https://mechanics.stackexchange.com
132,982
[ "https://physics.stackexchange.com/questions/132982", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/58014/" ]
I have done a problem which asks us to find the charge on two equally 'massed and charged' pith balls which are left hanging on a string with a certain length that repels each other and attains an equilibrium point making an angle (the string) with the vertical. The problem was quite clear, what left me wondering was...
Your muscles do some work when you start to get you up to walking speed. According to physics there is no work being done once you get up to a constant speed. At a constant speed there is no acceleration, no force, and no work. Unfortunately, just because you aren't doing any work doesn't mean your muscles aren't consu...
Even just walking on flat ground is doing some work in the physics sense. Your center of mass will bounce up and down with each step. The up part requires work to be done, and the body has no mechanism to derive energy from joints being moved by external forces, so can't recover the work on the way down. At best the...
https://physics.stackexchange.com
128,791
[ "https://softwareengineering.stackexchange.com/questions/128791", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/28933/" ]
I am dealing around with C# .Net for almost around a year now. I got lots of experience (I owe most of it to guys at stackoverflow). Now I am thinking to start working with C++ as well. Mainly because I would like to be able write codes resulting in applications that are not .Net dependent so they can be executed in m...
Some warnings to avoid some common "detours": 1) C++ and C# looks very similar, but their similitude ends just there (in the look). 2) "Native application" -on both Windows and Linux- are not C++, but C since C is the native language for both the OS kernel API. In this sense, all C++ libraries interfacing the OS are ...
I have never used Visual C or windows environment, so my answer will be biased. I feel if you want to learn c++, you should do it in on Linux. As Linux is open source platform, and used extensively on heterogeneous environments such as server, mobile, desktop, you will find lot more support when you run into problems a...
https://softwareengineering.stackexchange.com
2,111,085
[ "https://math.stackexchange.com/questions/2111085", "https://math.stackexchange.com", "https://math.stackexchange.com/users/23173/" ]
I am trying to find $$\begin{bmatrix}t&amp;1-t\\1-t&amp;t\\\end{bmatrix}^n$$ in $\mathbb{Z}_n[t^{\pm 1}]/(t-1)^2$, where $n$ is a positive integer. My guess is that the result is the identity matrix but am not sure about a proof. Thanks for any help or hints!
<blockquote> <strong>Your approach is fine. I'm not sure if you were required or encouraged to apply the root test, but thought it might be useful to present an alternative way forward. To that end we proceed.</strong> </blockquote> <hr> Recalling that $\log(1-x)\le -x$ and $e^x\ge \frac12x^2$ for $x&gt;0$, we ha...
Alternate approach: For large $n,$ the terms are positive and bounded above by $(1-2/n)^{n^2} = ((1-2/n)^{n})^n.$ We know $(1-2/n)^n \to 1/e^2&lt;1/e.$ So for large $n,$ $(1-2/n)^n &lt; 1/e.$ Thus the terms are $&lt; (1/e)^n$ for large $n.$ Since $\sum (1/e)^n &lt;\infty,$ the original series converges.
https://math.stackexchange.com
252,036
[ "https://electronics.stackexchange.com/questions/252036", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/120557/" ]
What I'd like to know is how we can resolve the two statements, "Circuits/linear components will only draw what they need", and "V = IR". They seem to contradict one another, in my view. With a given voltage and a given resistance, current will be set by these two properties in the circuit, regardless of "the current c...
It is incorrect to say "components only draw what they need to from the circuit." That statement appears to relate to questions like: "I have a power supply that is rated 2 amps and I wast to connect it to a device that only needs 1 amp. Will the power supply give my device too much current?" The answer should be somet...
<blockquote> draw what they need to from the circuit </blockquote> I don't think this statement refers to single components.Put too much current through the LED it will be damaged or destroyed.If you put too much voltage across it,the same thing can happen. An assembly or a system of components,or,to be more specif...
https://electronics.stackexchange.com
119,134
[ "https://dba.stackexchange.com/questions/119134", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/31969/" ]
I have an equation <pre><code>((P.RealisedConsumption / (NULLIF((PO.ActualQty * P.QuantityPO), 0) / NULLIF(1000000, 0))) - 1) * 100 AS FibreScrapFactor </code></pre> This works for the example order that I am looking at. However if i take out the where clause (so i have all orders) i get divide by zero error. ...
Hi I ended up doing this... this resolved my issue... <pre><code>CASE WHEN (PO.ActualQty * P.QuantityPO / 1000000) &lt;&gt; 0 THEN ( P.RealisedConsumption / ( PO.ActualQty * P.QuantityPO / 1000000 ) - 1 ) * 100 END AS FibreScrapFactor </code></pre>
Since your data types are already decimal types, perhaps you need to remove NULL values with a <code>WHERE</code> clause instead of coalescing them to <code>0</code>, which would result in the "divide by zero" error. Something like: <pre><code>SELECT ((P.RealisedConsumption / (NULLIF((PO.ActualQty * P.QuantityPO), 0)...
https://dba.stackexchange.com
112,249
[ "https://mathoverflow.net/questions/112249", "https://mathoverflow.net", "https://mathoverflow.net/users/28037/" ]
Hi, Given C>0. Let $f,g,h$ be $L^2$ functions such that $f,g,h$ have a compact and finite-measure support, and $f*f(x)=g*g(x)=h*h(x)=f*g(x)=g*h(x)=f*h(x)=0$ (where $*$ is the convolution) for all $|x| &gt; C$. Does that imply $f(x)=g(x)=h(x)=0$ for all $x$? What is I won't require $f*f=g*g=h*h=0$? What if we had tw...
I don't know why you say "compact and finite measure". Every compact set has finite measure. Fourier transform of a function with compact support is an entire function. Fourier transform of a convolution is the square of the Fourier transform. So EACH of the equations $f*f=0$ or $f*g=0$ already implies that $f=0$ and $...
No: First: L^1 is an algebra under convolution, but if $f$ has compact support and is in $L^2$ then it is in $L^1$. Your functions have all compact support. Since $supp(f * g)\subseteq \pm supp(f) \pm supp(g)$ your condition with $C$ is always satisfied.
https://mathoverflow.net
17,265
[ "https://dba.stackexchange.com/questions/17265", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/8502/" ]
While connected to our production server (SQL Server 2008, very powerful machine), this SELECT statement takes <strong>2 seconds</strong>, spitting back all fields (4 MB of data in total). <pre><code>SELECT TOP (30000) * FROM person WITH(NOLOCK); </code></pre> From any <strong>other</strong> box on the same network ...
Your problem is definitely network related, based on your info. As such, it has to be dealt with with network professionals (I am not the one). Things that might help: <ul> <li>Faster NIC cards (on SQL server).</li> <li>Adding of allocated/specific NIC card/subnet between the servers (web-server and SQL Server).</li>...
This issue is now resolved. It was a network problem, and the SQL box was using a <strong>100 MB/s</strong> NIC card, instead of a <strong>10 GB/s</strong> NIC card... A network configuration change to use the correct network card has fixed the problem. Now we are getting similar performance for all queries from the...
https://dba.stackexchange.com
381,407
[ "https://electronics.stackexchange.com/questions/381407", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/192048/" ]
I m trying to read accelerometer values from mpu 6050 in atmega328p (Arduino UNO). I want an embedded c program that's why don't wanna use any external lib. So I read about I2C protocol, read the datasheet of MPU 6050, register sheet of MPU 6050 and developed a code as per my understanding. Here's the code <pre><code>...
We have talked to NXP. They had issues regarding the MMA8451 ealier. Back in 2012 they implemented more quality testing at their factories to help with the issue of a "sticky z-axis". We have checked our components, which are of newer dates (2016 / 2017). But we are still convinced that we see issues related to this. ...
There are two basic possibilities- that the chip is failing within its normal operation range, or that your application is exceeding some limit so damage is occurring. In the first case, I think the best option is to talk to NXP. But, I think it is much more likely that the chips are being abused in some manner. If ...
https://electronics.stackexchange.com
118,763
[ "https://mathoverflow.net/questions/118763", "https://mathoverflow.net", "https://mathoverflow.net/users/30601/" ]
Hello, Let $X'X$ be a positive definite matrix and let $\mathbf{1}$ denote the vector of ones. I'm hoping to construct a positive, diagonal matrix $W$ such that $$(W X'X W) \mathbf{1} = \mathbf{1}$$ $X$ and $W$ are all assumed to have real-valued entries, and $X'$ denotes the transpose of $X$. I don't, yet, have a...
Consider the simplex of nonzero diagonal matrices W with nonnegative entries up to scaling, and the simplex of nonzero vectors V with nonnegative entries up to scaling. There is a map, $V=\max(WX′XW\mathbf 1,0)$, from the first simplex to the second, with $\max(a,0)$ interpreted entrywise. This is well-defined because...
The relevant reference is Marshall, A. and Olkin, I. Scaling of Matrices to Achieve Specified Row and Column Sums. Numerische Mathematik 12, 83-90 (1968) who prove the result in the affirmative for positive definite matrices (and some generalizations). The proof is elegant and construction: the diagonal matrix can ...
https://mathoverflow.net
3,747,166
[ "https://math.stackexchange.com/questions/3747166", "https://math.stackexchange.com", "https://math.stackexchange.com/users/806400/" ]
my math professor just taught me directional derivatives and some of their identities, however he did not show us the proof to these identities. After a thorough comb through many textbooks and the internet, I am unable to find satisfactory proof of them, hence could I have some help in proving these? Thank you! <span ...
The definition of a directional derivative is as follows: <blockquote> Let <span class="math-container">$U \subset \Bbb{R}^n$</span> be open, let <span class="math-container">$v \in \Bbb{R}^n$</span>, <span class="math-container">$x \in U$</span>, and let <span class="math-container">$f:U \to \Bbb{R}$</span> be a funct...
For a differentiable function <span class="math-container">$f:\mathbb{R}^n\to \mathbb{R}$</span> the directional derivative of <span class="math-container">$f$</span> in the direction <span class="math-container">$v = (v_1, \dots, v_n)$</span> can be written <span class="math-container">$$ D_v(f) = \sum_{i=1}^nv_i\frac...
https://math.stackexchange.com
176,054
[ "https://mathoverflow.net/questions/176054", "https://mathoverflow.net", "https://mathoverflow.net/users/18017/" ]
I have a friend who wants to study something applied to neurosciences. He is going to begin his grad studies in mathematics. He asked me which areas of mathematics could be applied to neurosciences. Since I don't know the answer, I thought mathoverflow would be the right place to ask. I mean, there are many areas of m...
My wife is a neuroscientist. I can tell you what she uses: $\bullet$ a LOT of statistics.<br> $\bullet$ signal processing (such as wavelet transform).<br> $\bullet$ some baysian probability theory.
(just my two cents, but too long for a comment) Does your friend care more about the tools he uses in his research (e.g. theorem-proving vs. developing models vs. using known mathematics to analyze data and/or models) or the community in which his work has impact (e.g. mathematicians vs. applied scientists). If the...
https://mathoverflow.net
324,656
[ "https://softwareengineering.stackexchange.com/questions/324656", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/72448/" ]
I've been trying to learn some of the new features of ES6, and while most of it makes sense, I'm having trouble grasping the arrow function. I'm not asking so much why it exists as I am how to read it. Previously in JS, when a function was defined, the syntax reads really nicely. <code>var foo = function(property) { ...
<pre><code>const foo = (property) =&gt; { return property + 'bar' } </code></pre> In JavaScript, functions are objects. That means they can be passed around and assigned to variables (I mean, other languages support it too and are adapting it more and more, but JavaScript is pretty much build on that). In order to un...
<pre><code>const foo = (property) =&gt; { return property + 'bar' } </code></pre> <blockquote> How do I read that? </blockquote> Define a constant foo that equals a function which takes an argument, property, and returns property + bar. In general, <pre><code>(...) =&gt; { ... } </code></pre> is mostly equivale...
https://softwareengineering.stackexchange.com
347,652
[ "https://stats.stackexchange.com/questions/347652", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/11363/" ]
I am facing the following piece of legacy code, and there is no chance to speak with its author unfortunately. <pre><code>Model1_LM &lt;- lm(result ~ ., data = data) fit1_LM &lt;- stepAIC(Model1_LM, direction = 'backward') </code></pre> Here <code>data</code> is a dataframe which contains features and the target to ...
Here's a simple example that illuminates how the stepAIC() function from the MASS package works. <pre><code># consider the built-in mtcars data set; select variables of interest data &lt;- mtcars[,c("mpg","disp","hp","wt")] # examine the first 6 records of the data head(data) </code></pre> The first 6 records in ...
It is doing model selection based on Akaike's Information Criterion, which is calculated as AIC = 2k - 2lnL, where k is the number of parameters estimated by the model and lnL is the log likelihood of the data given the model. Basically, model selection with AIC attempts to select the model that best explains the data ...
https://stats.stackexchange.com
124,558
[ "https://electronics.stackexchange.com/questions/124558", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/39152/" ]
I am trying to fix my wireless router, but one of the parts is under a metal plate. <ol> <li>What are these metal plates called? </li> </ol> <img src="https://i.stack.imgur.com/39RD8.jpg" alt="Metal Plates"> This is what it looks like when it is removed: <img src="https://i.stack.imgur.com/3twnQ.jpg" alt="Board"> (...
That is a shield and is used for many purposes. It can be to protect a sensitive area from EMI/RFI, or it can be to protect the rest of the board from EMI/RFI generated in that area or to help pass emissions testing. If it is soldered down it can be problematic to remove as the large area acts as a heat sink preventi...
Existing answers are correct. It may be worth also noting that I've heard them referred to colloquially as "cans".
https://electronics.stackexchange.com
86,049
[ "https://chemistry.stackexchange.com/questions/86049", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/55104/" ]
<blockquote> A chemist adds <span class="math-container">$\pu{0.115 g}$</span> of a group 2 element to water and the resulting solution is made up to <span class="math-container">$\pu{400 cm3}$</span> by adding distilled water. The equation for the reaction is shown below. <span class="math-container">$\ce{M}$</span> r...
I'm not a chemist, but I doubt whether the mesomeric effect is "<em>more in case I than in III</em>" as you put it. I'm under the impression that the mesomeric effects (alone) in both cases activate the benzene ring to the <em>same</em> extent (If you try drawing the resonance structures, you'd probably feel the same...
The answer is II > I > III because in II and III resonance effect will be same because resonance does not depend on the distance but since inductive effect depends on distance so <em>-I</em> of <span class="math-container">$\ce{OCH3}$</span> will draw more electron density than <em>para</em> position hence will become ...
https://chemistry.stackexchange.com
71,961
[ "https://softwareengineering.stackexchange.com/questions/71961", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/9803/" ]
When a project has reached end of life and is being retired, either because the technology is obsolete, a newer version of the program has been rewritten, or it no longer solves a problem that is needed to be solved, what should be done with the code? Should it be deleted, or kept for future reference? This also appl...
Keep it. You may have to some day inspect the code to see e.g. assumptions, or how a specific thing was solved ("you had something that did this, and we want the same thing") and it is a bit easier if you actually have it. Source repositories are really cheap to keep on a corner of an official server somewhere.
If code has made it into the wild, you should <em>never</em> delete it. Users are very good at desperately needing help 5 minutes after you destroy your ability to support it. With the contracting side of your question you may be limited by confidentiality issues. I had one government agency expressly prohibit me fr...
https://softwareengineering.stackexchange.com
218,830
[ "https://physics.stackexchange.com/questions/218830", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/36562/" ]
While attempting problems of simple harmonic motion I came across this problem, which has gotten me confused. A fixed horizontal spring is stretched by a constant force $F$. I am required to obtain the maximum elongation of that spring. But the problem is which method is correct, the energy method or the force metho...
The first method is giving the correct answer. In writing the work done by the force, you are assuming that the force $F$ itself is constant throughout the extension. However, this is not true. While extending the spring in a quasi-static way, the force $F$ must always match exactly the spring force at that time. This ...
If you use a constant force along the path, the spring will move past the position where $F=kx$, because it will reach that point at some speed. Thus it is incorrect to use the force method in the way you used it, because at maximal extension $v=0$ but $a\neq0$. The energy method as you used it will give the correct an...
https://physics.stackexchange.com
17,383
[ "https://security.stackexchange.com/questions/17383", "https://security.stackexchange.com", "https://security.stackexchange.com/users/11338/" ]
I've been searching and searching, but I can't seem to find a good-enough technical explanation. From what I've gathered, there are two "things" able to secure VPNs: 1) Pre-Shared Key: This handles authentication, because each side has to have the same key. However, how are the actual packets encrypted, and how does t...
<ul> <li>The symmetric encryption key is derived using a key exchange, even in the case of using a pre-shared key (see RFC 2409 section 5, particularly at the end of page 8 and then at section 5.4).</li> <li>In the case of certificates, the public keys are used for the key exchange in order to negotiate a symmetric enc...
The abstract concepts you're looking for are Secure Channel and Hybrid Encryption. VPNs use both concepts to establish a secure tunnel. The wikipedia pages on this are surprisingly short, so here's a short explanation with some more terms to google: You first have a Key Exchange phase, typically involving some form of...
https://security.stackexchange.com
20,183
[ "https://dba.stackexchange.com/questions/20183", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/3698/" ]
We have a process that takes data from stores and updates a company-wide inventory table. This table has rows for every store by date and by item. At customers with many stores, this table can get very large-- on the order of 500 million rows. This inventory update process typically gets run many times a day as the ...
Looks like your clustered index page splits are going to be painful because the clustered index holds the actual data and this will need new pages to be allocated and the data moved to these. This is likely to cause page locking and thus blocking. Remember also that your clustered index key is 21 bytes and this will ...
With the multi-threaded approach, I'm wary of the insert into a table from which you must first check prior existence of a key. That sort of says to me that there is a concurrency issue on that PK index to that table no matter how many threads there are. For same reason, I don't like the NOLOCK hint on the inventory t...
https://dba.stackexchange.com
47,770
[ "https://dsp.stackexchange.com/questions/47770", "https://dsp.stackexchange.com", "https://dsp.stackexchange.com/users/27594/" ]
I am using the double median filtering of my data. For this, I perform median filtering of the signal in forward direction, then in reverse direction (from end to start). Results are averaged. Example of the MATLAB code: <pre><code>Signal=rnd(1,100); Mfw=medfilt1(Signal,10); Mrev=medfilt1(Signal(end:-1:1),10); M=mean(...
Globally, I do not know of a global name, because it is either a median or a (locally) linear filter with fluctuating tap locations: a median (odd length), a 3-tap Gaussian approximation (2-length) or a weighted average of at most 4 samples. <ul> <li>when the length is odd ($2l+1$): a simple median filter</li> <li>w...
I've held off on answering this because I don't have MATLAB to test any of this. I've employed the same trick with exponential smoothing. The purpose of this is to have the lags in the opposite direction cancel each other out, so the resultant smoothed signal is centered instead of shifted from the source signal. Fo...
https://dsp.stackexchange.com
10,787
[ "https://earthscience.stackexchange.com/questions/10787", "https://earthscience.stackexchange.com", "https://earthscience.stackexchange.com/users/9537/" ]
Is it possible to locate potential gold deposits using maps that describe dominant rock type, altitude, vegetation, or geological formations? (I realize that the location would probably still have to be verified by traveling to the actual site. I am only looking for information that serves as an indicator of potential...
On of the issues with geological maps is they have all required humans to walk over the ground and mark on a piece of paper the surface expressions of different types of rock and geological structures, such as faults and folds. Because of this process and the time constraints placed on people when they mapped the land...
If you were an exploration geologist tasked by a mining company with finding a new gold deposit you would start with a geologic map. In this sense, yes you would be using a map to locate potential gold deposits. But you would also do a lot more research reading geological survey reports about the geologic history of ...
https://earthscience.stackexchange.com
86,396
[ "https://mathoverflow.net/questions/86396", "https://mathoverflow.net", "https://mathoverflow.net/users/17525/" ]
It is an exercise in Hartshorne to classify nonsingular quartic curves in projective 3-space. I am interested in what happens when we allow singularities. In particular, I am looking for an explanation or source for how to exclude the possibility of a space curve of arithmetic genus 1 and a single node or cusp.
Singular nondegenerate irreducible degree $4$ curves certainly exist. They can be obtained as complete intersections of two quadric surfaces which are tangent at some point. Thinking differently, any curve of class $(2,2)$ on a nonsingular quadric $Q$ is a degree $4$ space curve. The series $|\mathcal{O}_Q(2)|$ is $...
Take a rational normal quartic curve $C$ in ${\mathbb P}^4$ and project it to ${\mathbb P}^3$ from a point $P\notin C$. The image $X$ of $C$ is a quartic. Moreover $X$ is smooth if $P$ is general, it has a node if $P$ lies on a secant line of $C$ and a cusp if $P$ lies on a tangent line to $C$. All rational irredu...
https://mathoverflow.net
20,372
[ "https://chemistry.stackexchange.com/questions/20372", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/-1/" ]
I was studying the types of stereo-isomerism E-Z, Cis-Trans and then I come across <strong>syn-anti stereo-isomerism</strong> this one is giving me a bit of fight in understanding, especially <strong>where lone pairs are taken into consideration</strong>.How do classify the molecules with lone pairs in consideration as...
Use of the terms "syn" and "anti" to describe the geometry about double bonds is no longer encouraged, but you'll still come across it, particularly in older articles. Syn and anti are identical to Z(usammen) and E(ntgegen) and were often used to describe the geometry about carbon-nitrogen double bonds. In such cases,...
There is another use of the terms anti and syn that is prevalent among steroid chemists. While the relationships between rings A and B/ B and C are described as trans in tricycles <strong>1</strong> and <strong>2</strong>, the relationship between rings A and C in the former is anti while in the latter it is syn.<br><b...
https://chemistry.stackexchange.com
242,337
[ "https://dba.stackexchange.com/questions/242337", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/1396/" ]
I'm looking to install several versions of SQL Server side-by-side to run simultaneously. I'd like to have them listen on different IP addresses. They will be running on Windows Server 2019 Core. I currently install using something like this: <pre><code>Setup.exe /qs /ACTION=Install /FEATURES=SQL /INSTANCENAME=MSSQL...
With SQL Server on Windows, the registry entries can be modified using PowerShell. Below is an example with SQL Server 2017 paths for the default instance. Of course, the instance will need to be restarted for changes to become effective. <pre><code>Set-ItemProperty -Path 'HKLM:\software\microsoft\microsoft sql server...
You can't have more than one IP adress for standalone sql servers. Which is server's IP adress. You can (and must) only set the port after setup.
https://dba.stackexchange.com
115,001
[ "https://mathoverflow.net/questions/115001", "https://mathoverflow.net", "https://mathoverflow.net/users/11927/" ]
Rencently a breakthrough was made in the context of the <strong>Minimal Model Program</strong> by the work of Birkar-Cascini-Hacon-McKernan. They proved that the canonical ring of a smooth or mildly singular projective algebraic variety is finitely generated. Since I'm a master student and so I have no a wide view of ...
[Just 'cause Artie asked:] :) Many parts of the mmp are not know for log canonical pairs. There are many results in that direction, but also many questions are open. In some sense log canonical is a more natural class than klt or even dlt and it is very important from the point of view of applications to moduli theory...
<ul> <li>The Abundance conjecture.</li> </ul> In its simplest form it says: If $X$ is a minimal variety (that is, the canonical divisor $K_X$ is nef and $X$ has terminal singularities) then some multiple $mK_X$ is base-point free. Thus sections of some power of the canonical bundle give a morphisms to projective space...
https://mathoverflow.net
87,373
[ "https://softwareengineering.stackexchange.com/questions/87373", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/11102/" ]
I am a proponent of Behavior Driven Development, mainly with Cucumber and RSpec, and at my current gig (a Microsoft shop) I am introducing SpecFlow as a tool to help with testing. I'd like to get the business analysts on my team involved in writing the features and scenarios, but they are put off by the "technical" as...
What I ended up doing is installing Visual Studio 2010 Express on their machines and setting up the SpecFlow templates. I showed them how to add a .feature file. We discussed how the features and scenarios should be written and off they went. I also showed them how to do the basic commits and pushes with TortoiseGit.
Part of your job as a developer is to map your tools and ideas to the tools and ideas that your stakeholders use. Domain-Driven Design (not BDD) can certainly help in this regard, because it can assist in creating the "ubiquitous," common language by which you and your stakeholders can communicate. But these folks ...
https://softwareengineering.stackexchange.com
46,853
[ "https://cs.stackexchange.com/questions/46853", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/37962/" ]
In Cormen's <em>Algorithms</em> textbook, the author casually mentions that ${n \choose 2}$ is $\Theta(n^2)$. Why is this so? In the calculation $$ {n \choose 2} = \frac{n!}{(n-2)!2!} $$ there are $n$ multiplication operations in the numerator and $n$ multiplications in the denominator. That means there are at most ...
You're assuming that $\Theta(\cdot)$ means something it doesn't mean. $\Theta(\cdot)$ is just a comparison between functions. It doesn't matter what those functions are being used to measure. Saying that $\binom{n}{2}=\Theta(n^2)$ means only that there are constants $c_1$ and&nbsp;$c_2$ such that, for all large enough...
$\Theta$-notation more generally refers to the growth of a function. In terms of computational complexity this function can be done in $O(1)$ as: $$\frac{n!}{(n-2)!2!} = \frac{n(n-1)}{2!} = \frac{n(n-1)}{2}$$ Since there are a finite number of multiplications and multiplication is sometimes treated as $O(1)$ this has...
https://cs.stackexchange.com
439,250
[ "https://stats.stackexchange.com/questions/439250", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/219255/" ]
The question is as follows; <strong><em>Grear Tires has produced a new tire with a mean mileage of 36500 miles and std dev of 5000 (assume normal). Grear has offered to refund a $1 per 100 miles short of 30000. For each tire sold, what is the expected cost of this offer?</em></strong> My approach was to find the prob...
Assuming that the problem is continuous and not discrete (i.e. the producer pays half a dollar for 50 miles below the threshold), this question can be solved analytically (i.e. a formula based solution, like you said) by explicitly writing the distribution and integral. The distribution of mileage is normal with known...
No. Using just PDF is incorrect. A more correct way is to use the corresponding differences of the tails of the distribution, which are the integrals of the PDF on the intervals <span class="math-container">$(-\infty,100]$</span>, <span class="math-container">$(100,200]$</span>, <span class="math-container">$(200,300]$...
https://stats.stackexchange.com
21,764
[ "https://quant.stackexchange.com/questions/21764", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/18065/" ]
I'm creating a Monte Carlo simulation model which I use to price an European option with various pay-off conditions, hence I can't use Black Scholes. I want to stop the simulation once I am 95% sure I am within 1% of the true value. To do this, I calculate the relative error (correct naming?) every 10 000 sims using:...
Yes, that's an excellent approach. The only time it might go wrong is if, say, you are integrating on some extreme tail event without using importance sampling. For example, let's say you were simulating expected loss on a portfolio of five bonds issued by the USA, Germany, Norway, Sweden and the Netherlands. After ...
You have the right idea, but it seems you don't know $\mu$, so using it in your error check doesn't seem correct. Also, checking the result every 10,000 iterations may not be optimal for deciding when to stop. To be clear, let $E(X) = \mu$ and $Var(X) = \sigma$. We're invoking the CLT when we write $$ P\left( \left|...
https://quant.stackexchange.com