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
579,107
[ "https://physics.stackexchange.com/questions/579107", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/274459/" ]
That may sound very silly questions but believe me I'm unable to understand that . I'm unable to visualise how solid can be said to have distinct boundaries . Please help me so I can make the picture of it in my mind . If I'm missing something related to question please let me known. Thank you!!
Your calculation is correct. The question can be answered in two ways, depending on what you're trying to do. <ol> <li>It could be a tautology. &quot;Fermionic&quot; and &quot;bosonic&quot; often refer to a <span class="math-container">$Z_2$</span>-grading in which the product of two odd-graded operators is even-graded...
Remember <span class="math-container">$[b,b^{\dagger}]$</span> is a c-number, so it equals its own spectation value. And as <span class="math-container">$&lt;0|c_{i}^{\dagger}c_{i}|0&gt;=0$</span>, then you obtain the known result.
https://physics.stackexchange.com
8,157
[ "https://chemistry.stackexchange.com/questions/8157", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/1027/" ]
I live in the tropics, and have a water tank that sits in the sun, forming algae. Every year, I need to scrub the thing out. The plumber I’ve hired for the job wants to flush my water pipes with HCl to kill any residual algae. The pipes are mostly PVC, with braided metal hose and metal fittings here and there. Should I...
Are they metal pipes? If you want to kill algae as such, flush with a diluted quaternary ammononium disinfectant, let sit a day, then flush everything very well indeed, and again. If you have rubber or polymer fittings, don't do that, either, for the stuff diffuses in.
Clean the tank with bleach and flush it several times. Once clean, put a piece of copper pipe in the tank and that should help it stay clean. Don't use HCl, too strong for the job.
https://chemistry.stackexchange.com
155,905
[ "https://softwareengineering.stackexchange.com/questions/155905", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/50730/" ]
I am relatively new to iOS development, so after watching a bunch of WWDC videos announcing new awesome features for the iPhone SDK, I still got a few questions regarding their support for older devices. Specifically: <ul> <li>Do the new compiler features (such as literals support, auto-synthesize, etc) require iOS 6 ...
So I’ve tried this out myself, by running a test app with some new SDK features in the iOS 5 simulator, and the findings are practically as expected though still somewhat disappointing. The compiler features, such as literals and auto-synthesize, work fine and good. However, if the app tries to access an IB file that ...
My understanding is that features implemented by the compiler, such as object literals, can be deployed on older systems. Features that require support from the runtime or from new/modified frameworks, probably including auto layout, will require iOS 6. It's trivial to figure out whether any given feature will work on...
https://softwareengineering.stackexchange.com
53,346
[ "https://chemistry.stackexchange.com/questions/53346", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/27575/" ]
Although Wikipedia says that EDTA is a very soluble salt, preparing a solution (.5M) is a pain in the neck. It takes a lot of time and still doesn't dissolve. Although addition of a few drops of NaOH makes the process a bit easier (still takes a lot of time) Now, it did not make sense to me of why NaOH made EDTA more ...
A disodium salt of EDTA also has two remaining carboxylic-acid groups, which can be deprotonated by addition of base, like $\ce{NaOH}$. By the way, higher pH is generally better <em>especially if you plan to use it for chelation, i.e. cation-capture</em>. The labs I've taught in the past use buffers of pH ~10 with EDTA...
Also be aware that the so called disodium salt is almost never sold as declared (it's not that easy to get the stoichiometry right on industrial skale), and you usually end up with a mixture of compounds that have 2/3 carboxylic acids protonated per molecule. That is the reason why EDTA is not a primary analytical stan...
https://chemistry.stackexchange.com
433,230
[ "https://physics.stackexchange.com/questions/433230", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/40292/" ]
Imagine an LC circuit in which the capacitor consists of two metal discs of area <span class="math-container">$A$</span> and spacing <span class="math-container">$D_0$</span> which is connected to a solenoid coil which for convenience has length <span class="math-container">$D_0$</span>, cross-sectional area <span clas...
Interesting question, unfortunately circuit theory is non relativistic. Circuits that satisfy the assumptions of circuit theory in their rest frame do not satisfy them in other frames. For example, one of the assumptions of circuit theory is that all of the components of a circuit have no net charge (Nilsson and Riedel...
Basic idealized analogue circuit theory is based on Maxwell's equations. Such ideas have without a doubt a relativistic version. One must be careful with the formulas to know which ones change and which ones remain valid. Capacitance and Inductance are geometrically defined. For example in a circular loop, if the obje...
https://physics.stackexchange.com
139,435
[ "https://mathoverflow.net/questions/139435", "https://mathoverflow.net", "https://mathoverflow.net/users/20052/" ]
Let $G$ be a compact semisimple group and let $\Gamma$ be a finite subgroup of $G$. I am interested, for $(\pi,V)\in \widehat G$ (irred rep of $G$), in a formula for $\mathrm{dim} V^\Gamma$, the dimension of the invariant space of $V$ by $\Gamma$. When $\Gamma$ is the trivial group, Weyl dimension formula says that $$ ...
Probably there is no explicit formula of the type you want. In any case, it's important to look first at the most accessible special cases (even though Weyl's formulas may be kept in the background). For example, consider $G= \mathrm{SU}(2)$ and its finite subgroups, using both the McKay correspondence and the Lie ...
Your idea seems to have already been implemented, see Section 2 of Chenevier and Renard's "Level one algebraic cusp forms of classical groups of small ranks". But it appears to be not as straightforward as just applying the ordinary Weyl character formula - you need a certain "degenerate" version of it.
https://mathoverflow.net
98,587
[ "https://mathoverflow.net/questions/98587", "https://mathoverflow.net", "https://mathoverflow.net/users/17582/" ]
Let $F$ be an algebraically closed field and let $L$ be a simple Lie algebra of dimension $n$ over $F$. Let $ad: L\longrightarrow End_F(L)$ denote the adjoint representation of $L$. If $F$ has characteristic zero, then it is well-known that, for every linear transformation $f\in ad(L)$, the semisimple and nilpotent pa...
Any finite dimensional simple Lie algebra over an algebraically closed field of characteristic $p&gt;3$ contains a nonzero element $x$ such that $ad(x)$ is semisimple. This is a nontrivial fact, and the only proof I can think of relies on the classification. For $p&gt;3$, the simple Lie algebras split into three famili...
The question is ambiguous in prime characteristic, since the meaning of "semisimple element" isn't straightforward for a simple Lie algebra consisting of matrices. Possibly what's meant here is "semisimple as a matrix in the given realization of <em>L</em>". but there's no reason for this property to be intrinsic to ...
https://mathoverflow.net
9,553
[ "https://electronics.stackexchange.com/questions/9553", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/2824/" ]
I'm a Trainee electrician and pc hardware enthusiast. I was just wondering why a mixture of inductors and capacitors are used on motherboards? Why not just use capacitor? I thought the inductor stores electrical charge but it uses magnetism. What's so special about storing it as magnetism?
To answer this properly, you should know the properties of a capacitor and an inductor. Inductors are one of the primary components required by a switching regulator. A capacitor and an inductor are similar in the way that a capacitor resists a change of a voltage and an inductor resists a change in current. The "stre...
The basic electrical property of a capacitor is that the voltage across a capacitor cannot change instantaneously, whereas the basic property of inductance is that the current through an inductor cannot change instantaneously. Capacitors preserve voltage by storing energy in an electric field, whereas inductors preserv...
https://electronics.stackexchange.com
598,002
[ "https://physics.stackexchange.com/questions/598002", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/205112/" ]
Having the Rindler metric given as <span class="math-container">$$ g_{\mu \nu} = e^{2 a \xi} (-d\tau^2+d\xi^2) \quad (1) $$</span> I would like to calculate the trajectory of a light beam in the coordinates <span class="math-container">$\tau$</span> and <span class="math-container">$\xi$</span>. There would be an easy ...
<span class="math-container">$$ g_{\mu \nu} u^{\mu } u^{\nu} =0 \quad (2)$$</span> gives <span class="math-container">$$e^{2 a \xi} \left(-\left(\frac{d\tau}{d\lambda}\right)^2+\left(\frac{d\xi}{d\lambda}\right)^2\right)= 0$$</span> which implies <span class="math-container">$$\frac{d\tau}{d\lambda} = \pm \frac{d\xi}{...
Your second derivation leads to the solution with <span class="math-container">$$ g_{\mu \nu} u^{\mu} u^{\nu}=0 $$</span> but is a mistake use <span class="math-container">$ g_{\mu \nu} u^{\mu} u^{\nu}=-1$</span> because is only valid for massive particles.
https://physics.stackexchange.com
325,359
[ "https://mathoverflow.net/questions/325359", "https://mathoverflow.net", "https://mathoverflow.net/users/134910/" ]
Consider the higher Cantor space <span class="math-container">$2^\kappa$</span> with the <span class="math-container">${&lt;}\kappa$</span>-box topology (<span class="math-container">$\kappa$</span> at least inaccessible). This canonically defines the notion of higher Borel sets. A higher Borel code <span class="math-...
Welcome new contributor. It is best to think about these kinds of examples on one's own. Thus, <i>please try this for yourself before reading the following</i>. Let <span class="math-container">$(Y,Z)$</span> be any pair of a Noetherian scheme <span class="math-container">$Y$</span> and a nonempty closed subset <s...
A non-coherent ring whose stalks are noetherian, constructed by Harris and Nagata, is described on p. 51 in S. Glaz, <em>Commutative coherent rings,</em> Lecture Notes in Math. 1371, Springer, Berlin, 1989. (Noetherianness of the stalks of the structure sheaf of a scheme does not imply local noetherianness of the sche...
https://mathoverflow.net
117,008
[ "https://electronics.stackexchange.com/questions/117008", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/35526/" ]
Although there are many similar questions to this one, I wish to get your attention to this specific board layout. The main power on the board will be 5V, and one of the layers is dedicated for this. However, the board will be connected to a 12V power, so I am using an LDO to drop the voltage to 5V. Keeping in mind cur...
I'm not sure that I know the best way to build the board, but I know what I would do. <ol> <li>The location of the 12V-to-5V regulator, whether linear or switching, will not matter. The corner of the board is fine.</li> <li>I would not bother with filling either top or bottom of the board with ground planes. The imped...
I think the general practice should be to maintain a solid plane where possible, and then place noisy components near the periphery so they don't contaminate sensitive nodes. You can place your LDO wherever you want if you are going to put it's output to the plane. The periphery, near the 12V header might be a natural...
https://electronics.stackexchange.com
143,138
[ "https://mathoverflow.net/questions/143138", "https://mathoverflow.net", "https://mathoverflow.net/users/27125/" ]
What can we say about the quotient of an abelian surface by an antisymplectic involution?
Denote by $\sigma$ the involution on the abelian surface $A$ and set $X:=A/\sigma$. The eigenvalues of the action of $\sigma$ on $H^0(\Omega^1_A)$ are $+1$ and $-1$. So $\sigma$ has no isolated fixed points and it follows that $X$ is smooth with $h^1(\mathcal O_X)=1$. There are two possibilities: 1) $\sigma$ has no fi...
Averaging a Kaehler class over the involution, and taking the corresponding Ricci-flat metric, we may assume that the involution preserves a flat metric on a torus. At each fixed point, the eigenvalues of the involution are +1, -1, and the fixed point set is a subtorus $T_0\subset T$. This means that the involution ac...
https://mathoverflow.net
33,124
[ "https://physics.stackexchange.com/questions/33124", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/4846/" ]
Would it be possible to determine the rest mass of a particle by computing the potential energy related to the presence (existence) of the particle, if this potential energy could be determined accurately enough? I noticed from the answers to a recent question that I always assumed this to be true, without even thinki...
The answer is ultimately no, but this is a reasonable idea, although old. This idea was floating around in the late 19th century, that the mass of the electron is due to the energy in the field around the electron. The concept of potential energy is refined in field theories to field energy. The fields have energy, an...
No. The rest mass is determined by the kinetic energy, not by the potential energy. Indeed, one can move a particle of arbitrary rest mass $m$ in a potential with arbitrary potential energy $V(q)$, using the Hamiltonian H=$\frac{p^2}{2m}+V(q)$ (or, relativistically, $H=\frac{p^2}{m+\sqrt{p^2+m^2}}+V(q)$).
https://physics.stackexchange.com
292,337
[ "https://dba.stackexchange.com/questions/292337", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/201049/" ]
I have a legacy application which queries one of its database (MySQL on AWS Aurora) tables extensively. Lots of queries and lots of query types. 90% of the rows in this table are outdated and are marked <code>is_deleted</code>. I want to try and make the performance better so I thought of partitioning the table by <cod...
You need to iterate over all key/value pairs in order to compare them using <code>lower()</code> Something along the lines: <pre><code>select mt.* from my_table_name mt where exists (select * from jsonb_each_text(mt.tags) as t(tag, value) where lower(t.tag) = 'key1' and low...
Using the JSONPATH query language, you could query <pre><code>SELECT * FROM my_table_name WHERE jsonb_path_match( tags, '$.keyvalue().key like_regex &quot;^key1$&quot; flag &quot;i&quot; &amp;&amp; $.keyvalue().value like_regex &quot;^value1$&quot; flag &quot;i&quot;' ); </code></pre>
https://dba.stackexchange.com
89,919
[ "https://dba.stackexchange.com/questions/89919", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/41938/" ]
I have using Oracle GTT tables with condition ON COMMIT DELETE ROWS. Now i know GTT tables data is only session specific. 1 session cannot see the GTT data of other session in General. But is their any way to access/read GTT table that belongs to another session?
No that is not possible, only session accessing the GTT can see it. IF you wish, you can use a physical table and model it as if it s a GTT. It isn't difficult, but isn't very efficient either.
A database table can be considered to be a logical definition (the columns and data types, name, constraints etc), and the physical implementation, which is one or more data segments where the data is stored. Normally the data segments are visible and accessible to all users who have privileges to select/insert/update...
https://dba.stackexchange.com
344,584
[ "https://softwareengineering.stackexchange.com/questions/344584", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/75283/" ]
I will be developing a mobile app, which will mainly act as a client. There will be an API on the cloud that these mobile clients will interact with, and there will also be a web application for administrative purposes. I'm thinking if I should use two separate applications for the API and the admin application. My th...
As you are already writing an API for your app clients to consume, you already have a library of business models and logic. Having the admin system access the data via the API means you don't have to replicate that logic, meaning less chance of a discrepancy between the client app interactions with your data and your a...
Creating an API and creating an administration panel are two completely separate things. API is meant to be as lightweight and fast as possible, administration panel is supposed to be user-friendly. As the project's responsibilities completely differ so do the team members who work on them. Besides many other things....
https://softwareengineering.stackexchange.com
3,791,835
[ "https://math.stackexchange.com/questions/3791835", "https://math.stackexchange.com", "https://math.stackexchange.com/users/674560/" ]
If <span class="math-container">$x$</span> is a nonnegative real number, then find the minimum value of <span class="math-container">$$\sqrt{x^2 +4} + \sqrt{x^2 -24x+153}$$</span> How can I approach this? Thanks
Thinking geometrically, you want to minimise the sum of distances from <span class="math-container">$(x,0)$</span> to <span class="math-container">$(0,2)$</span> and <span class="math-container">$(x,0)$</span> to <span class="math-container">$(12,3)$</span>. Reflect the point <span class="math-container">$(12,3)$</span...
<strong>Process 1</strong>: Derivate it to zero <strong>Process 2</strong>: Using triangle inequality, Given,<span class="math-container">$$\sqrt{x^2 +4} + \sqrt{x^2 -24x+153}$$</span> <span class="math-container">$$\rightarrow\sqrt{x^2+2^2}+\sqrt{\left(-x+12\right)^2+3^2}\geq \sqrt{\left(x-x+12\right)^2+(2+3)^2} = \sq...
https://math.stackexchange.com
13,463
[ "https://dsp.stackexchange.com/questions/13463", "https://dsp.stackexchange.com", "https://dsp.stackexchange.com/users/5800/" ]
Thanks for reading my question. Please refer good books(links, if possible) for the following topics in Image processing. Your help is very much appreciated. <em>UNIT II SEGMENTATION</em> <strong>Fuzzy clustering, Watershed algorithm, Active contour methods, Texture feature based segmentation, Model based segmentatio...
for Multiresolution based fusion discrete wavelet transform you may refer the following " A Wavelet based image fusion tutorial " by Gonzalo Pajares ( available at: www.ELSEVIERcomputer science.com) "Wavelet based image fusion techniques - An introduction ,review and comparison by Krista Amolins for Curvelet transfor...
For first two: Feature Extraction &amp; Image Processing for Computer Vision, by Mark Nixon and Alberto S Aguado Computer Vision: Algorithms and Applications (Texts in Computer Science) by Richard Szeliski For last one Sparse Image and Signal Processing Wavelets, Curvelets, Morphological Diversity AUTHORS: Jean-Luc...
https://dsp.stackexchange.com
195,151
[ "https://stats.stackexchange.com/questions/195151", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/62173/" ]
I run Dickey Fuller test in order to know if stock returns are stationary. I get that no matter which stock I take, his return is stationary. I don't know why I get this result since it is clear that volatility depends on time (hence, returns are not stationary since their variance depends on time). I'd like to get bo...
I think your problem is that you confuse the UNconditional variance and the conditional variance. Indeed, you can have a time-varying conditional volatility but a constant unconditional variance. First, I illustrate what Dickey-Fuller does and why it is a very specific test. Second, I explain why you can have a time-v...
The augmented Dickey-Fuller test assesses whether the time series under inspection has a unit root or not. The test is designed specifically for that purpose. It either rejects the null of unit root or fails to reject it. Rejection of the unit root should not be interpreted as presence of stationarity, though. Presen...
https://stats.stackexchange.com
621,512
[ "https://physics.stackexchange.com/questions/621512", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/208833/" ]
In Sean Carroll's GR book, pg 83, between eqs. (2.69-70), the Levi-Civita symbol with raised indices is defined as <span class="math-container">$$\tilde{\epsilon}^{\mu_1\mu_2...\mu_n}=\text{sgn}(g)\tilde{\epsilon}_{\mu_1 \mu_2...\mu_n}$$</span> where <span class="math-container">$\text{sgn}(g) = \frac{g}{|g|}$</span> i...
To me, a more conceptually direct derivation goes as follows. The Levi-Civita symbol is a <em>symbol</em>, not a geometrical object. We can denote its value in a coordinate system <span class="math-container">$x$</span> as <span class="math-container">$\tilde \epsilon_{(x)\mu\nu\rho\sigma}$</span>. On its face, this ...
I believe the answer lies in plain sight. Carroll defines weight as the power of det(∂x'/∂x). Apply (2.66) in Carroll's book and replace |M| by det(∂x'/∂x). Multiply sgn(g') to LHS and sgn(g) to RHS. The equation still holds since they are equal. Then you get an equation similar to (2.67) and the first item of RHS is 1...
https://physics.stackexchange.com
1,993,624
[ "https://math.stackexchange.com/questions/1993624", "https://math.stackexchange.com", "https://math.stackexchange.com/users/374729/" ]
<strong>Question:</strong> Suppose $\pi \in \mathbb{Z}[i]$ is irreducible. Prove that there exists a prime number $p$ such that $N(\pi) = p$ or $N(\pi) = p^2$. <strong>My attempt:</strong> I genuinely do not know where to begin. There is a hint which says that I must take an ordinary prime number $p$ such that it is ...
Remember that the norm is multiplicative. If $\pi = \alpha \beta$, then $N(\pi) = N(\alpha) N(\beta)$. If $\pi$ is indeed irreducible and prime, that means either $N(\alpha) = 1$ or $N(\beta) = 1$. But if $N(\alpha) \neq 1$ <em>and</em> $N(\beta) \neq 1$, then $\pi$ is not irreducible as originally asserted. Then cons...
Have you learned about the difference between unique factorization domains (UFDs) and non-UFDs yet? $\mathbb Z[i]$ is a UFD, which makes certain things easier. Suppose $N(\pi) = pq$, where $p$ and $q$ are "ordinary" primes, and $p \neq q$. Since we're working in a UFD, this means that we can find Gaussian integers $a$...
https://math.stackexchange.com
4,442,880
[ "https://math.stackexchange.com/questions/4442880", "https://math.stackexchange.com", "https://math.stackexchange.com/users/973892/" ]
I am trying to find <span class="math-container">$$\int\frac{3+\cos(x)}{2-\cos(x)}dx$$</span> I did long division and got the <strong>integrand</strong> to be <span class="math-container">$$-(1+\frac{5}{\cos(x)-2})$$</span> To simplify the second term, I tried conjugate multiplication as well as Trigonometric Identiti...
An approach: with the change of variables <span class="math-container">$\displaystyle u=\tan\frac{x}{2}$</span> we have <span class="math-container">$\displaystyle u'(x)=\frac{1}{2}\sec^{2}\frac{x}{2}$</span> and using <span class="math-container">$\displaystyle \sin(x)=\frac{2u}{u^{2}+1}$</span> and <span class="math-...
Let given integral be <span class="math-container">$I$</span>, <span class="math-container">\begin{align*} I &amp;= \int \frac{3+\cos x}{2-\cos x} dx \\ &amp;= \int \frac{5-(2-\cos x)}{2-\cos x} dx \\ &amp;=\int \frac{5}{2-\cos x} dx - \int dx \\ &amp;= 5 \int \frac{\sec^2\frac x2}{2(1+\tan^2\frac x2)- (1-\tan^2\fra...
https://math.stackexchange.com
675,789
[ "https://physics.stackexchange.com/questions/675789", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/317893/" ]
I have observed that the aglet in the laces of my jacket hood swing like a pendulum when I walk. I cannot think of any forces which are the cause of its movement in this way.<br /> So why is it like this.
The aglet, on its lace, is performing <em>forced oscillations</em>. The periodic movement of your body as you walk causes a periodic force on the top of the lace, making the aglet swing like a pendulum. The oscillations are usually noticeably large only when the frequency of the periodic force from you is quite close t...
When you walk normally at a steady pace, the motion of your body is fairly periodic. The motion of your arms and upper body for example, closely resembles harmonic motion, and so any object hanging from your body as in this case or a necklace, will move like a pendulum in rhythm with your body's motions.
https://physics.stackexchange.com
183,760
[ "https://softwareengineering.stackexchange.com/questions/183760", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/10869/" ]
<strong>Disclaimer</strong>: Not as exaggerated as the title suggests, but it still makes me uncomfortable. I'm just going to express honestly, so take it with a grain of salt. Just pretend that I'm talking about <em>that</em> coding standard that you don't like working with. <strong>Edit</strong>: The fact that I don...
If you want to get over this — there was a quote by Torvalds: <blockquote> Bad programmers worry about the code. Good programmers worry about data structures and their relationships. </blockquote> Now consider, where does it put programmers who worry about such a minor thing like bracing style enforced by their cod...
Some people like it your way and other people don't. Either way someone is going to be annoyed. It is just your turn this time. Suck it up and get on with the job.
https://softwareengineering.stackexchange.com
115,279
[ "https://stats.stackexchange.com/questions/115279", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/2676/" ]
Suppose I have a multivariate normal ${\bf{Y}}|{\bf{\theta}} \sim {\bf{MVN}}(X {\bf{\beta}}, \sigma^{2}H(\phi))$ where ${\bf{Y}}$ is a set of observations ${\bf{Y}} = \{y({\bf{s}}_{1}),y({\bf{s}}_{2}),... ,y({\bf{s}}_{n})\}$ and $H(\phi)$ is a covariance matrix $H(\phi) = \rho({\bf{s}}_{i} - {\bf{s}}_{j};\phi)$. Now I ...
I think for prediction, the only thing that matters is validating properly to avoid overfitting. By "prediction" I mean that the output of the model is a point estimate of some future response. On the other hand, if the output includes not only the point estimate but also CI, then it's different. Imagine you know the ...
@James makes a great point on estimating prediction intervals, but I don't think you want to say that the only thing that matters for point prediction is validating to avoid overfitting. Some of those regression diagnostics have clear implications for improving a model's predictive performance. One obvious case is if...
https://stats.stackexchange.com
130,178
[ "https://security.stackexchange.com/questions/130178", "https://security.stackexchange.com", "https://security.stackexchange.com/users/117638/" ]
While connected to my router, whenever I open any web page in a browser, on any device, it opens 3 tabs of ads instead of the page I want. "Clean" devices that I connect to the same router also exhibit the behavior. When devices which exhibit the behavior are connected to a different router or hotspot, they function no...
This may not be as dire as it is being made out to be. Two of the functions of a consumer-grade router are Dynamic Host Configuration Protocol (DHCP) and Domain Name Service (DNS). The first function is used to provide the various parameters your devices need to connect to the network, such as IP addresses, network mas...
Sadly it looks like you've taken ALL the steps in working to try and find where this problem lives, and it indeed lives on your router. The problem is that in the core tennants of security: <blockquote> If one part is compromised, ALL parts are considered compromised until investigation is complete. </blockquote> <...
https://security.stackexchange.com
88,736
[ "https://cs.stackexchange.com/questions/88736", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/85021/" ]
I was given the following problem as homework: <blockquote> Let $x$, $y$ be words over an alphabet $Σ$. Prove that $xy = yx$ iff there exists a word $z$ such that $x^2y^2 = z^2$. </blockquote> I was hinted that I am supposed to approach this problem using structural induction. Considering the case where $|x| = |...
One direction is easy: if $xy = yx$ then $x^2y^2 = xxyy = xyxy = (xy)^2$. In the other direction, we split into cases. If $|x|=|y|$ then, as you mention, $x = y$. If $|x|&lt;|y|$ then let $y=y_1y_2$, where $|y_1|=|y|-|x|$ and $|y_2|=|x|$. We have $z = x^2y_1$ and $z = y_2y = y_2y_1y_2$. Since $|x| = |y_2|$, it follow...
From $xy = yx$, we can say $x^2y^2 = x (xy) y = x (yx) y = (xy)^2$, Hence $z = xy$. Hence, first part is proved. Now, suppose there exists a word $z$ such that $x^2 y^2 = z^2$. Moreover, suppose $|x| &lt; |y|$ w.l.o.g. Hence there is a $w$ such that $x^2w = w'y$, $ww'=y$, $|w| = |y|-|x|$, and $|w'| = |x|$. As $x^2w = ...
https://cs.stackexchange.com
351,546
[ "https://physics.stackexchange.com/questions/351546", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/164488/" ]
I know that the Pauli Exclusion Principle does not allow two identical fermions to have the same set of quantum numbers. But can they share the same location in space if they are uncharged such as two neutrons? If not, why not because there is no quantum number associated with position. Thanks
The wavefunction for fermions has a spatial part too, and this is what describes the <em>location</em> of a particle at best in QM. Pauli Exclusion Principle forbids two identical fermions from having the very same wavefunction. For example, you can have spin-up fermions both in s- and p-waves, but of course no two spi...
The principle forbids two fermions of the same species from sharing the same <em>quantum state</em>. Let's first carefully look at where the idea comes from. This principle arises simply because the spin statistics theorem implies that half integer spin particles - <em>i.e.</em> fermions - have antisymmetric multipart...
https://physics.stackexchange.com
463,577
[ "https://physics.stackexchange.com/questions/463577", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/212614/" ]
Okay this is a question I’ve asked a lot of places but I always get its the flow of charges and it’s like a property. What I don’t really understand is how is this flow of charges creating electric current. My guess is that as these charges get closer to the desired potential(to satisfy potential difference) Energy i...
First of all you have to understand that flow of electrical current and dissipation of energy are two completely different concepts. <strong>Electrical current:</strong> The flow of electrical charges is called electrical current. This is like a definition and has nothing to do with dissipation. There are systems, whe...
As Bill N said, electric current, <span class="math-container">$i(t)$</span> through a surface is defined as the rate of charge transport through that surface, or <span class="math-container">$$i(t)=\frac{dq(t)}{dt}$$</span> Where <span class="math-container">$q(t)$</span> denotes instantaneous charge. Electrical c...
https://physics.stackexchange.com
66,884
[ "https://dsp.stackexchange.com/questions/66884", "https://dsp.stackexchange.com", "https://dsp.stackexchange.com/users/50071/" ]
Let <span class="math-container">$x[n]$</span> be a discrete signal of 2 samples. We know that its DFT with N=4 is <span class="math-container">$X[k]=[0, 1+j, 2, 1-j]$</span>. Without calculating <span class="math-container">$x[n]$</span>, how can we know the DFT with N=2? I have tried to use the relation between DFT ...
<span class="math-container">$$X_4[0] = x[0] + x[1]$$</span> <span class="math-container">$$X_4[2] = x[0] - x[1]$$</span> Now <span class="math-container">$$X_2[0] = x[0] + x[1]$$</span> <span class="math-container">$$X_2[1] = x[0] - x[1]$$</span> Therefore <span class="math-container">$$X_2[0] = X_4[0]$$</span> <...
Simple explanation: Zero padding in one domain is simply interpolation in the other. Doing a 4-point DFT over a 2-point sequence can be interpreted as zero padding to 4 points. Hence the 4-point DFT is just an up-sampled version of the 2-point DFT and simple decimation will yield the 2-point DFT.
https://dsp.stackexchange.com
65,769
[ "https://electronics.stackexchange.com/questions/65769", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/6862/" ]
What does a PLC read if I have an unconnected input? I know that I can test it, but I want to know whether there is any default ?
The default logic level is probably undefined or at best written in the datasheet of the device. You don't want to rely on a default like this unless explicitly defined there as the reading may be influenced due to noise. PLCs are commonly used in very noisy environmnents.
For digital inputs it will read zero. For analog inputs it depends - for example in 4..20mA signals you know when you have a wire break, but in 0..20mA you don't.
https://electronics.stackexchange.com
21,355
[ "https://stats.stackexchange.com/questions/21355", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/2149/" ]
Given a population to be divided between treatment / control, if I believe a variable is distributed lognormal in the population, how do I know what the necessary control size is in order to guarantee a difference in means is significant at some arbitrary level for a specific effect size? (Reference to R or SAS examp...
If you're willing to express the smallest effect you want to be able to detect as a ratio of geometric means, you can work on the log scale and perform a standard sample size calculation for the case of two normal distributions.
To follow up on @Onestop's answer, you'll need a means of doing power analysis. You can check around the web for a power calculator that fits your particular test (<em>T</em>-test?). Or you can download the free and pretty versatile program GPower.
https://stats.stackexchange.com
182,797
[ "https://mathoverflow.net/questions/182797", "https://mathoverflow.net", "https://mathoverflow.net/users/17599/" ]
Cayley's formula states that the number of labeled trees on $n$ vertices is $n^{n-2}$. My question is: Is there a generalization of this formula for forests? Let $f_{n,k}$ denote the number of forests with $k$ connected components on $n$ vertices. For example, $f_{n,1} = n^{n-2}$ by Cayley's formula and $f_{n,n-1} = \...
A formula as a single sum is $$f_{n,k} = \binom nk \sum_{i=0}^k \left(-\frac12\right)^i (k+i)\,i!\, \binom{k}{i}\binom{n-k}{i} n^{n-k-i-1}.$$ This formula can be found in J. W. Moon's <em>Counting Labelled Trees</em>, Theorem 4.1. He attributes it to A. Rényi, <em>Some remarks on the theory of trees</em>, Publication...
A straightforward formula: $f_{n,k}$ is the coefficient of $x^n$ in $$\frac{n!}{k!}\cdot\left( \sum_{i=1}^{\infty} \frac{i^{i-2}x^i}{i!}\right)^k$$ (clearly, the sum here can be restricted to first $n$ terms).
https://mathoverflow.net
24,135
[ "https://dsp.stackexchange.com/questions/24135", "https://dsp.stackexchange.com", "https://dsp.stackexchange.com/users/11096/" ]
I have a fixed point DSP library fft function that does not use a block exponent. I don't have prior knowledge of that implementation but whatever I could read online, my understanding is that its used in each butterfly stage to determine redundant sign bits and hence left shift by same amount.However, in my case, lib...
i don't have a C version of fixed-point FFT, but i have an old 56K version. i used to have a 68K version but that's in a Mac that has died decades ago. if you can get a good fixed-point version of the FFT in C that you like, i can show you where to place the magnitude tests and where to kick it into <em>"divide-by-tw...
Block (floating point) has been implemented in a Vector Signal Processor developed by Zoran (sold by now) over 30 years ago. You may get very close results to such implementation by employing a floating point (even double precision) and than scale the result so the maximal value of the FFT uses all 24 bits (usually yo...
https://dsp.stackexchange.com
87,471
[ "https://electronics.stackexchange.com/questions/87471", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/7567/" ]
As shown in the block diagram below. I generate a 128KHz clock and a stream of known number of pulses in 10msec (the 10msec timer is implemented in the pulse counter by dividing the 128KHz by 1280) and send them to the pulse counter in the system under test. <img src="https://i.stack.imgur.com/Tukzs.png" alt="System ...
It sounds as though the drive from the optocoupler is marginal for the FPGA. The fact that the scope probe loads it enough to make things much worse seems to confirm it. This is probably capacitance rather than resistance. For example, a Tek P2200 1x/10x passive probe in the 1x position can put 80 pF on the circuit ...
Here, probably the optocouplers does not transmit 128Khz signal with good quality (what is very easy with wrong designed schematic). So, the pulse counter (what is the input?) simply misses some of the pulses. In addition, when you connect the probe capacitance in the circuit, the quality of the signal becomes even w...
https://electronics.stackexchange.com
40,327
[ "https://security.stackexchange.com/questions/40327", "https://security.stackexchange.com", "https://security.stackexchange.com/users/11679/" ]
I use the Windows 8 operating system. Whenever I navigate to the login page of Internet Explorer 10, or even the login screen of the operating system, I see an eye symbol at the end of the password input. <img src="https://i.stack.imgur.com/BCfEr.jpg" alt="Screenshot of wifi input box: &quot;Enter the network securit...
You are far too paranoid. The "eye" is simply what it is, a way for you to unmask the password in the password field. It is good from a security perspective to mask passwords as you are typing it to protect against shoulder surfers and the like. However, it can be annoying if you accidentally mistype passwords and hav...
Masking a password is like tinting the windows of a vehicle. To a computer there is no difference between an unmasked password and a masked password. The masked password is a feature that is implemented so people around your vicinity cannot see your password, also if someone is watching your monitor live through some...
https://security.stackexchange.com
62,590
[ "https://security.stackexchange.com/questions/62590", "https://security.stackexchange.com", "https://security.stackexchange.com/users/50516/" ]
Assume a web site with some kind of mailer option, that doesn't implement any rate limiting: This enables users to send an unlimited amount of email per second. Will SMTP face possible DoS attacks for that? Or any kind of problems? Can anyone explain this?
No matter if you use rate limiting or not. If you're running a public server, which accepts incoming connections, it is always and anywhere vulnerable for a DDoS. Rate limiting can be useful to not congest the system, it could be a possible countermeasure against DoS but does not, by far, protect fully against a DoS at...
One of the difficulties in securing SMTP lies in the protocol itself, specifically the admonitions in RFC 5321 which give proscriptions on timing out a session. A faithful implementation provides no facility for timing a session out. Ideally one would want to ignore those recommendations, and set a session timeout fo...
https://security.stackexchange.com
630,518
[ "https://physics.stackexchange.com/questions/630518", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/268529/" ]
I was given the question: <blockquote> A parallel plate air capacitor has capacity <span class="math-container">$\mathrm{C}$</span>, the distance of separation between plates is <span class="math-container">$\mathrm{d}$</span> and a potential difference <span class="math-container">$\mathrm{V}$</span>is applied between...
To answer your question: The way you have written it, <span class="math-container">$V = E\, d$</span> is the potential due to <em>both</em> disks of the capacitor. When considering the force on just one of the disks, however, you must take <em>half</em> of that potential, since each disk as a whole does not &quot;feel&...
I believe there's a glitch in what you call E.<br> If you write the equation V = Ed, E stands for the electric field between the two plates. If you write F = QE, E stands for the electric field produced by one of the plates. And you must understand that these are different.<br> Let's call the electric field produced by...
https://physics.stackexchange.com
405,317
[ "https://stats.stackexchange.com/questions/405317", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/228541/" ]
This is my first question at stats. I need to impute some factors and numbers in my data set in R. What are my best options regarding packages and also a source to read more about the theory.
My Master's thesis revolved around the use of the mice package in R and I have only good things to say about it. I tried to use Amelia II but it just wasn't well suited to my data so I can't comment too much on that. The approach of the two packages does differ though so you may want to research which is better suited ...
I found Chapter 3 in <em>Regression Modeling Strategies</em> by Frank Harrell to be a good overview. It covers types of missing data, strategies for imputation, and discusses simplistic and advanced methods. The packages recommended in that chapter are MICE and aregImpute in R.
https://stats.stackexchange.com
42,603
[ "https://engineering.stackexchange.com/questions/42603", "https://engineering.stackexchange.com", "https://engineering.stackexchange.com/users/27982/" ]
A composite action beam may have a concrete section the top, carrying the compression load, and steel at the bottom, carrying tension. But I have always thought that concrete had lower strength for a given mass then steel, compressive or otherwise. So why do engineers build steel concrete composite action floor systems...
Some other answer have touched upon this, but I think it needs to be made explicit: Your mistake is in thinking that civil engineering is about making the lightest structure possible. It's not. Instead, it's about making the most <em><strong>cost-effective</strong></em> structure possible. Give me a material that weigh...
The most important advantage of reinforced concrete over pure steel structure is availability. Many countries/regions on earth rely on imports for general goods production needs, the cost of steel can run prohibitively high compared to concrete. The next advantage is weight. In certain types of structure weight counts,...
https://engineering.stackexchange.com
195,004
[ "https://dba.stackexchange.com/questions/195004", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/6503/" ]
Here is an example of what I'm asking: Detail Table: <pre><code>HeaderId | DetailId 1 100 1 101 2 100 2 101 3 101 3 102 3 103 </code></pre> I'm looking for a query strategy that will get me all header ids with the same set of ...
You can backup to multiple files and restore these files with backup compression these files should be a lot smaller then your databasesize. Example <pre><code>BACKUP DATABASE [YourDatabase] TO DISK = N'\\YourDriveOrNetworkFolder\YourFOlder\MNGDB_2.bak', DISK = N'\\YourDriveOrNetworkFolder\YourFOlder\MNGDB_1.bak'...
Yes you can achieve that based on the size of the data files and log. You can do a restore with a move option to split the locations of the database files (mdf/ndf and ldf) to the mentioned drives based on the size of the files and available space on the drives. Sample script will perform this task: <pre><code>RESTORE...
https://dba.stackexchange.com
574,610
[ "https://electronics.stackexchange.com/questions/574610", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/69058/" ]
Looking at the top distributors, seems only N-channel power SiC are carried. Why is that?
Not just SiC. All high-voltage MOSFETs. There's no point due to how they are or would be used. SiC is for high voltage and the max gate-source voltage is the limiting factor when using a PMOS high-side switch to simplify gate drive. 30V is pushing it, let alone 600V. So for high-side, high-voltage switches you need gat...
I believe the process of producing them is more complicated but I am not sure. They do have a higher on-resistance than N-channel MOSFETs this is disadvantageous due to higher power losses. So therefore most people prefer N-channel MOSFETS. Also, they are enabled when applying a negative voltage to the gate compared to...
https://electronics.stackexchange.com
1,539
[ "https://ai.stackexchange.com/questions/1539", "https://ai.stackexchange.com", "https://ai.stackexchange.com/users/8/" ]
How does employing evolutionary algorithms to design and train artificial neural networks have advantages over using the conventional backpropagation algorithms?
Unlike backpropagation, evolutionary algorithms do not require the objective function to be differential with respect to the parameters you aim to optimize. As a result, you can optimize "more things" in the network, such as activation functions or number of layers, which wouldn't be possible in the standard backpropag...
Further to Franck's answer, there may be better optima (even global optima) that exist in the opposite direction to the gradient (which may be in the direction of some local optima). Evolutionary algorithms have scope to search the surrounding area, while backpropagation will always move in the direction of the gradien...
https://ai.stackexchange.com
109,505
[ "https://electronics.stackexchange.com/questions/109505", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/40047/" ]
Let's say we have the following circuit with silicon transistor 2N3904 (the transistor has \$\beta = 125\$): <img src="https://i.stack.imgur.com/2XDk0.jpg" alt="circuit"> I am trying to calculate the DC voltage between the collector and the emitter. One of the solutions I found is the following: $$Ι_b = \frac{V_{bb...
The answer given is correct. \$V_{BE}\$ and \$V_{CE}\$ are equal to \$V_{B}\$ and \$V_{C}\$ respectively when the emitter is grounded, however no ground is shown in your circuit, so it's not 100% clear what \$V_{B}\$ and \$V_{C}\$ would mean.
The other equations are correct. Yours are correct only in this specific circuit if we assume the negative terminals of the voltage supplies are at gnd. In this specific circuit with that assumption, they are equivalent, but that's only because the Emitter is grounded (at 0 volts), therefore, Vbe = Vb and Vce = Vc. Nor...
https://electronics.stackexchange.com
403,949
[ "https://softwareengineering.stackexchange.com/questions/403949", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/173899/" ]
I've noticed on web and mobile apps, when scrolling down to the bottom of a list with thousands of entries it reaches the bottom instantly but appears to be scrolling through every entry. How is this visual effect achieved? What is the common way to implement this simulation of fast-scroll?
In software, just as in movies, illusion of movement is created by presenting frames in quick succession. If you want to create the illusion of scrolling from item 1 to item 1000 in a second, you divide the number of items to scroll by the frame rate (e.g. 60fps) and move by a corresponding number of items (possibly fr...
With memory. So long as you have more memory than your monitor requires you can render things that aren't on the screen yet. When you load a webpage the scroll bar thumb starts to shrink as the page grows off the screen. Just because it's off the screen doesn't mean it isn't rendered in memory. Then to scroll to any p...
https://softwareengineering.stackexchange.com
298,102
[ "https://physics.stackexchange.com/questions/298102", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/138929/" ]
The melting point of ice (H2O) is at 273K, and one of salt (NaCl) is at 1074K. However, if one dissolves salt in water, the melting point of the solution will be at ~250K. Why is it so low if the contained ice must melt at 273K and salt at 1074K?
One can explain this phenomenon with entropy change. <strong>I am moving from liquid state to solid state</strong> As we reach the melting point of a pure solvent the entropy goes on decreasing. As entropy is defined as 'randomness' it can be said that when we add a solute in a solvent the entropy increases. So, to ag...
First, this only happens for dilute solutions. And in this case, it does not matter what you put in the solvent, the melting/freezing point will always decrease. The solute particles displace some solvent molecules in the liquid phase and therefore reduce the concentration of solvent. The reduced the concentration of...
https://physics.stackexchange.com
428,169
[ "https://stats.stackexchange.com/questions/428169", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/245759/" ]
I do not understand the intuition behind why the median is the best estimate if we are going to judge prediction accuracy using the Mean Absolute Error. Let's say you have a random variable <span class="math-container">$X$</span> and you want to predict what the next <span class="math-container">$X$</span> is. Let's ...
Here is an intuitive argument with light math. Let's say we have a <span class="math-container">$d$</span> claiming to be minimizing the MAE of points <span class="math-container">$x_i$</span>. And, let's say we have <span class="math-container">$n_l$</span> and <span class="math-container">$n_r$</span> points on its l...
gunes has already presented a wonderful answer with simple formulas. Here is my a numerical example to test it: consider the set {1, 1, 1, 1, 1, 1, 1, 1, 1, 11}; that is, nine 1s and a single 11. The mean is 2, the median is 1. When you consider the sum of absolute values as the sum of distances, the median will have ...
https://stats.stackexchange.com
3,119
[ "https://mechanics.stackexchange.com/questions/3119", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/1581/" ]
I didn't do anything to "winterize" it, but we only had a few stretches of really cold weather (less than 20F) and the majority of the winter was between 20F and 50F. Should I do anything before firing it up and mowing the lawn?
Two-Stroke or Four? If four, check the oil. Check the general condition, e.g. check that the fuel lines are secure and in good condition. If it is water-cooled (I don't think they usually are?), check the coolant level and condition of radiator/hoses. Take the plug out, clean and re-gap. Empty out any old fuel and put ...
Nothing bad about all the things Nick C suggested, but for a simple push mower I think it's overkill, I'd just check the oil, top off the gas, and pull the cord! :-) If it sounds like it has a misfire, then next time around I'd check the plug(s). The plugs can go a very long time without maintenance unless they get ...
https://mechanics.stackexchange.com
107,439
[ "https://cs.stackexchange.com/questions/107439", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/103368/" ]
I'm a bit confused on what exactly the meaning of a 'key' is in computer science. I understand key-value pairs, primary keys, etc... But I can't find a definition of what the term 'key' means by itself. As far as I can tell it just means a piece of data. In CLRS, data associated with tree nodes are referred to as 'key...
In the most general sense, a key is a piece of information required to retrieve some data. However, this meaning plays out differently depending on exactly what situation you're dealing with. In the contexts you mention, a key is a <strong>unique identifier</strong> for the complete data used to retrieve it from some ...
A <em>key</em> in the context of data structures (such as in the book CLRS) is a value (often an integer) that is used to identify a certain component of a data-structure. Often, keys determine how the underlying data is stored or manipulated. For example, in <em>binary search trees</em> we have that for every node, th...
https://cs.stackexchange.com
69,337
[ "https://quant.stackexchange.com/questions/69337", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/36150/" ]
I'm a software developer want to know a little about quant basics. My undserstanding of PFE is that a PFE of a trade at a future time point is commonly defined by taking the average of the highest (or worst) 10% exposure of, say, 2000 projections calculated from curent value of the contract using a model and implied vo...
Potential future exposure (PFE) is a concept in <em>credit analysis</em>, that is we are investigating the risk that a counterparty will not be able to pay us in the future. In a typical derivative deal between two parties (for example a swap) when the deal is opened the value is zero, so neither party owes anything to...
The higher the value of the contract, the higher the counterparty credit risk the bank's is taking from that contract. That's why banks set PFE limits to each counterparty.
https://quant.stackexchange.com
276,412
[ "https://dba.stackexchange.com/questions/276412", "https://dba.stackexchange.com", "https://dba.stackexchange.com/users/3742/" ]
I am trying to upgrade 9.5.5 to 12.3 using pg_uprade, got the following error <em>Old and new pg_controldata maximum relation segment sizes are invalid or do not match</em> <strong>9.5.5</strong> Blocks per segment of large relation: 8388608 <strong>12.3</strong> Blocks per segment of large relation: 131072 8388608 blo...
So after numerous tests, I found the issue. If I run the configure --with-segsize=64 on RHEL 6.10, the segment size will not get set to 64 GB, but if I run it on RHEL 7.8, it does. Seems like a bug with RHEL 6.10.
You seem to have posted the <code>pg_controldata</code> output for PostgreSQL 9.5 twice. Anyway, you'll have to configure PostgreSQL v12 with a non-standard table segment size: <pre class="lang-bash prettyprint-override"><code>./configure --prefix=/opt/pgsql/PostgreSQL-12 --with-segsize=64 </code></pre> Also, during <c...
https://dba.stackexchange.com
49,987
[ "https://cs.stackexchange.com/questions/49987", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/42896/" ]
Does every pure function have a branchless equivalent? By <em>pure</em> function I understand a function that uses only its input values and no global state to produce the output. By <em>branchless</em> function I understand a function that does not use if/else during its execution. A loop contains a branch with and ...
The general answer to your question is no. Consider a function which measures the length of a linked list. How would you implement that without a branch? But if you just stick with functions which (say) take a machine word and return a machine word (which your example does) then the answer is "yes, sort of". In fact, ...
Here is a pure function which cannot be written without if/else. It takes one number and if the number is even it returns "EVEN" string or else it returns "ODD" string. Also, in your second code sample the expression (x > 0) is internally a branching and it returns a boolean value and you cannot subtract boolean value...
https://cs.stackexchange.com
493,874
[ "https://electronics.stackexchange.com/questions/493874", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/133221/" ]
I have a <strong>TRIO KA-9900 amplifier</strong> which is the Japanese equivalent of a <strong>KENWOOD KA-907 amplifier</strong>. My amplifier runs on Japanese AC voltage. What is the <strong>appropriate capacity</strong> of a <strong>step-down transformer</strong> for <strong>use in a country that runs on 230v</stro...
Your earlier commentators are accurate I'd say. The criteria for judging any semiconductor devices as "pass" or "fail" when fabricated is dependent on the parameterisation - the measures used to test as good or bad and those which are tolerable over a fair range. This is why most 'semis' manufacture entails finding...
That will absolutely depend on the type of component you're producing, the kind of process you have, and the actual fab. Since this is only kind of a failure process, I don't think any of your simple statistics will actually represent any "continuous metric" of "die quality" (whatever that might be) overly well. With f...
https://electronics.stackexchange.com
15,058
[ "https://quantumcomputing.stackexchange.com/questions/15058", "https://quantumcomputing.stackexchange.com", "https://quantumcomputing.stackexchange.com/users/1923/" ]
If we have a composite system over five qubits (<span class="math-container">$|\psi\rangle = |a\rangle|b\rangle|c\rangle|d\rangle|e\rangle$</span>), and I want to project into a specific subspace of the first three systems, I can build a projector of the form <span class="math-container">$|011\rangle\langle011| \otimes...
Your slicing is correct, and gives the right answer in your example. Here is a generalization of your slicing, for the case where you may have a different string of bits. <pre><code>import numpy as np def return_indices(subspace): n_qubits = len(subspace) indices = np.array(range(32)).reshape((2,)*n_qubits) ...
In your slicing, your taking the elements of the `integers' <span class="math-container">$\{4p, 4p+1, 4p+2, 4p+3\}$</span>. For <span class="math-container">$p = 3$</span>, that's <span class="math-container">$\{12, 13, 14, 15\}$</span> or <span class="math-container">$\{01100,01101,01110,01111\}$</span> in binary - so...
https://quantumcomputing.stackexchange.com
946,864
[ "https://math.stackexchange.com/questions/946864", "https://math.stackexchange.com", "https://math.stackexchange.com/users/68477/" ]
<img src="https://i.stack.imgur.com/luolU.png" alt="enter image description here"> <strong>Attempt.</strong> Rewriting this we have, $$\sum_{n=1}^{\infty} \lvert a_n-a_{n+1}\rvert&lt; \infty \,\,\,\Longrightarrow\,\,\, \exists N \in \mathbb{N}\ \ s.t,\ \ \sum_{n \geq N}^{\infty} \lvert a_n-a_{n+1}\rvert &lt; \infty$...
If the series $\,\,\sum_{n=1}^\infty\lvert a_{n+1}-a_n\rvert\,\,$ converges, then for every $\varepsilon&gt;0$, there exists an $N$, such that $$ \sum_{n=N}^\infty\lvert a_{n+1}-a_n\rvert&lt;\varepsilon. $$ Therefore, if $m\ge n\ge N$, then $$ \lvert a_m-a_n\rvert\le\lvert a_{n+1}-a_n\rvert+\lvert a_{n+2}-a_{n+1}\rver...
I'd go like this: Assuming $\;m&gt;n\;$ , we have $$|a_m-a_n|=|a_m-a_{m-1}+a_{m-1}-a_{m-2}+a_{m-2}-a_{m-3}+\ldots+a_{n+1}-a_n|\le$$ $$\le\sum_{k=0}^{m-n-1}|a_{m-k}-a_{m-k-1}|\xrightarrow[m,n\to\infty]{}0$$ The last limit is not actually a double one, but rather "make $\;n\to \infty\;$ and thus <em>also</em> $\;m\to...
https://math.stackexchange.com
3,657
[ "https://electronics.stackexchange.com/questions/3657", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/230/" ]
Does anyone have any directions on what ICEs exist for MSP430s. I currently use the MSP430F148. I have others in use, and plan to switch to some higher end in the future. I would be interested in ICE or any other solutions people know of. We have some real time systems where power consumption is more important than s...
It seems there are not any major ICEs available for the MSP430. I thought I had seen one, but cannot find it and find other places where people state there are not ICEs. If this is incorrect, please post. Tomorrow I am going to accept my answer if there is not one. I will always go back and switch to an answer that ha...
I use the TI FET tool. I started out with the parallel port version but now use the USB FET430UIF. This has been used successfully with the F149 and the new F5438 and F5418 devices, programming over the full JTAG and Spy-Bi-Wire interfaces. I use the IAR tools but it is supported by all of the main development tools...
https://electronics.stackexchange.com
299,539
[ "https://physics.stackexchange.com/questions/299539", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/131639/" ]
I know that if two sources are out of phase by $a$, both with wavelength $b$, $(a\cdot b)/2\pi$ must be added to the path difference when calculating interference. Why is this? And what is the intuition behind it?
you are moving currently downward,but your speed is decreasing ,that would mean you are accelerating upward. In that case also your apparent weight will be given by, $n=m(g+a)$ ,where $m$ and $a$ are mass of you and acceleration of the elevator respectively. Only acceleration matters not your current velocity ,this is...
You don't increase your weight you increase the gravity on your body while you accelerate away from the Earth and visa versa when you travel towards Earth. Once you stop increasing your speed the increase of gravity will stop. You can stand on a scale and see how much Gs are being applied when you go up.
https://physics.stackexchange.com
560,743
[ "https://physics.stackexchange.com/questions/560743", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/102785/" ]
I am confused about how the law of the conservation of (kinetic) energy and the law of conservation of momentum can both hold true. If we observe a certain collision, then depending on the final velocities there might be a reduction in the total kinetic energy in the system. Where does the energy go? Here's an example ...
The <span class="math-container">$23.75J$</span> energy can't have gone anywhere. What this means is that your construction is impossible. If there is no friction, no deformation, etc, then in an elastic collision the projectile cannot bounce back with <span class="math-container">$5 m/s$</span>. It must go faster. The...
Predicting the results of an elastic collision can be tricky. In 1D if you want to start with the conservation equations, rearrange the energy equation so that you have a difference of two squares on each side. Factor these; then divide by the momentum equation (also rearranged). An approach which is quicker and easie...
https://physics.stackexchange.com
3,729,445
[ "https://math.stackexchange.com/questions/3729445", "https://math.stackexchange.com", "https://math.stackexchange.com/users/778899/" ]
There's 3 balls in the basket - White, red and black. Three people chose one ball after the other with return. <span class="math-container">$X$</span> is the various colors that got chosen. <span class="math-container">$Y$</span> is the number of people that chose white.<br /> I need to calculate <span class="math-cont...
It’s correct. In particular, <span class="math-container">$C\cup D$</span> <strong>is</strong> a metric space with the metric that it inherits from <span class="math-container">$X$</span>. However, the result is true for arbitrary topological spaces, though part of the proof has to be changed slightly. If <span class="...
The usual topological def'n is that <span class="math-container">$f:P\to Q$</span> is continuous iff <span class="math-container">$f^{-1}E$</span> is open in <span class="math-container">$P$</span> whenever <span class="math-container">$E$</span> is open in <span class="math-container">$Q.$</span> There are many conseq...
https://math.stackexchange.com
284,018
[ "https://physics.stackexchange.com/questions/284018", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/108801/" ]
The actual melting temperature of gold is 1000° C. However, I noticed when pure gold wire whose diameter is 3 mills is put into the molten blob of solder (60% tin + 40% lead), which is at only 300° C, the gold melts and gets alloyed up with the molten tin. How does the tin-lead alloy reduce the melting temperature ...
The gold doesn't melt, it dissolves in the molten solder forming another alloy. You can observe the same thing dissolving ordinary table salt, sodium chloride, in water. Sodium chloride melts at 801 C, but dissolves readily in water.
Arbitrarily mixable alloys with two components have a melting temperature that can be considerable lower than the melting temperatures of its constituents. The mixture with the lowest melting temperature is called eutectic. Gold probably forms an alloy with a component of the solder (e.g. Sn). Therefore it "melts" by f...
https://physics.stackexchange.com
1,133,739
[ "https://math.stackexchange.com/questions/1133739", "https://math.stackexchange.com", "https://math.stackexchange.com/users/45220/" ]
Does the system of equations have a solution? : $a=3d$ $3b=3a+d+9e$ $3c=3b+e+9f$ $f+3c=0$ I was told by someone online that they solved it in terms of the variable $d$, in other words they got all the other variables as a function of $d$. This seems impossible because the system has more variables than equations. ...
Noticing the first and fourth equations make for a couple of substitutions: $3b=3(3d)+d+9e \iff 3b-10d-9e=0 \iff 3b=10d+9e$ $-f=3b+e+9f \iff 3b+e+10f=0 \iff 3b=-e-10f$ $10d+9e=-e-10f \iff 10d+10e+10f=0 \iff d+e+f=0 \iff e = -d-f$ Thus, allowing $f,d$ to be free, the solution can be expressed this way using the equ...
It does not have a unique solution, since, as you note, it has 6 unknowns and 4 equations. <em>If</em> every variable can be expressed as a function of $d$, we still have that $d$ can can take on any value in the domain. There would be as many solutions as there are values in the domain: infinitely many. Once $d$ woul...
https://math.stackexchange.com
37,535
[ "https://physics.stackexchange.com/questions/37535", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/12268/" ]
I often read that the Lorentz symmetry is manifest in the path integral formulation but is not in the canonical quantization - what does this really mean?
Manifest Lorentz symmetry means that one can see Lorentz invariance directly from the way the theory is formulated; typically when space and time are treated on the same footing as components of a 4-vector. In these cases, the Lorentz group generators are represented in a simple way (hence the ''manifest'' symmetry), b...
The canonical formulation is based on a Hamiltonian framework which requires the definition of a time coordinate. So, all of the quantities you calculate depend on this choice of time, and so it is not obvious that everything is Lorentz invariant. Path integrals respect lorentz invariance from start to finish, as t...
https://physics.stackexchange.com
16,040
[ "https://softwareengineering.stackexchange.com/questions/16040", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/6415/" ]
Often in C code (and some other languages as well) I have seen a section in the top-level comments for mod lines. These include the date a modification to the file was made, the user who made the modification, and a brief description of what was changed. I have not yet seen an equivalent of this in Java. I think this ...
I see no reason to have those useless comments in any source file. Its just reinventing version control extremely poorly.
I've often seen Java files with a header including the original date created and the author, but not "mod lines". Version control would make that rather superfluous, as it tracks changes on a per-line basis by user. As for why they're used in C, perhaps it's an old custom from before the days of VC.
https://softwareengineering.stackexchange.com
76,790
[ "https://electronics.stackexchange.com/questions/76790", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/22865/" ]
I've googled almost 100 times, unable to find what transimpedance really is. Every search displayed results about transimpedance amplifiers, but didn't explain the term transimpedance.
<em>Impedance</em> means a circuit element that produces a voltage when a current is applied. For example, if you apply 1 A to a 1 Ohm resistor, 1 V will be generated across the resistor. <em>Transimpedance</em> applies to a 2-port (or n-port) device, rather than a simple single-branch circuit element, and it means t...
Consider a amplifier that takes current as input and produces a voltage proportional to that current. How would you define its gain? In a normal voltage-in voltage-out amplifier, the gain is the change in output voltage divided by the change in the input voltage that caused it. This is a dimensionless quantity since...
https://electronics.stackexchange.com
12,116
[ "https://engineering.stackexchange.com/questions/12116", "https://engineering.stackexchange.com", "https://engineering.stackexchange.com/users/8626/" ]
I'm doing a project which simulates a car accident, with a cube block which has sensors on it crashing into a wall. This object is on a 3&nbsp;m track mounted on a linear bearing to reduce friction. So this object needs to be travelling at a speed and it impacts a solid wall (with about 40&nbsp;G of deceleration in t...
Lets say we want 40 MPH (since I don't even have enough information to verify that it will give you the 40 G's). As Olin mentioned, $40 MPH \approx 18 m/s$. I feel like in this situation, a spring would be your best bet. We want it to be travelling at 18 m/s at the end of the 3 m path. Potential energy in a spring ...
First, start by using consistent units. 40 miles/hour is 18 m/s. For steady acceleration, the average speed when starting at 0 is therefore 9 m/s. You have 3 m of acceleration distance, so the acceleration time is &frac13; second. That means the acceleration is 54 m/s<sup>2</sup>. That's about 5&frac12; g. How mu...
https://engineering.stackexchange.com
321,574
[ "https://mathoverflow.net/questions/321574", "https://mathoverflow.net", "https://mathoverflow.net/users/18974/" ]
Say that an infinite (connected) graph (with vertices of bounded degree) satisfies a <span class="math-container">$\ell_1$</span>-pseudo-Poincaré inequality if there is a constant <span class="math-container">$C&gt;0$</span> so that for any <span class="math-container">$n \in \mathbb{N}$</span> for any function <span ...
A counterexample is the subgraph of the <span class="math-container">$\mathbb{Z}^2$</span> Cayley graph found by taking squares <span class="math-container">$S_i$</span> of side <span class="math-container">$i$</span> and arranging them along a (near)diagonal in a chain so that each <span class="math-container">$S_i$</...
Why I do not have a relevant counterexample yet, I decided to write an extended comment on related Poincaré and Sobolev inequalities. The purpose was to place the question in the right context, provide a source that contains many related references and mention a result (inequality (*)) in the positive direction that is...
https://mathoverflow.net
313,371
[ "https://physics.stackexchange.com/questions/313371", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/51950/" ]
Why is angular momentum defined as $ \vec{r} \times \vec p $ and not as $ \vec p \times \vec r$ ?
Because you need to choose a convention: it doesn't matter which one, but you need to choose one of the two signs, or you're just unable to move. Ultimately, this is a choice of handedness: in the usual convention, if you use your right-hand fingers to curl with the rotational motion, your thumb points along $\vec L$. ...
The alternative you propose would multiply all angular momenta by $-1$. There's no physical reason we can't do that. One advantage to the usual definition is that $\mathbf{r},\,\mathbf{p},\,\mathbf{L}$ form a right-handed coordinate system for radial forces, since then $\mathbf{L}$ is conserved and the motion is plana...
https://physics.stackexchange.com
322,014
[ "https://physics.stackexchange.com/questions/322014", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/150220/" ]
I'm currently working through Robert Klauber's Student Friendly Quantum Field Theory, which by the way is much more accessible than other texts like, say, Peskin and Schroeder, for others also coming into QFT via the self-study path. Anyhow, he mentioned something that never really jumped out at me before, like it is...
Radiation in this context refers to radioactivity which simply means energy is transmitted from an unstable nucleus. The form of energy transfer may happen in forms of particles (such as alpha) or photons (gamma). The terms alpha, beta and gamma originated at a time when sub-atomic structure was not properly understoo...
The word "to radiate" means "to move outward" as in the same root as "radius." Thus the same word gets used for things that spread out from a point source but are otherwise are very different from one another, such as electromagnetic radiation (light waves) and nuclear radiation (alpha particles). It is not implying ...
https://physics.stackexchange.com
1,424,802
[ "https://math.stackexchange.com/questions/1424802", "https://math.stackexchange.com", "https://math.stackexchange.com/users/153974/" ]
$$\Large{\lim_{x\to 0}\frac{7x^3-4x^2}{\sin(3x^2)}}$$ I know how to find this Limit only by using L’Hopital’s. Here's How: $$={\lim_{x\to 0}\frac{7x^3-4x^2}{\sin(3x^2)}}$$ $$={\lim_{x\to 0}\frac{21x^2-8x}{6x\cos(3x^2)}}$$ $$={\lim_{x\to 0}\frac{x(21x-8)}{6x\cos(3x^2)}}$$ $$={\lim_{x\to 0}\frac{(21x-8)}{6\cos(3x^2)...
using the fact that $\sin (3x^2) = 3x^2 + \cdots,$ you get $${\lim_{x\to 0}\frac{7x^3-4x^2}{\sin(3x^2)}} = \lim_{x\to 0}\frac{-4x^2 + \cdots}{3x^2 + \cdots} = -\frac 43. $$
So we have $$\lim_{x\to 0} \frac{7x^3 - 4x^2}{\sin(3x^2)}.$$ First, we have to factor the numerator so $x^3 - 4x^2 = x^2(7x - 4)$. Therefore, we have $$\lim_{x\to 0} \frac{x^2(7x - 4)}{\sin(3x^2)}.$$ After this, we multiply the numerator and the denominator by $3x^2$. Note $\frac{3x^2}{3x^2}=1$ so we aren't doing anyth...
https://math.stackexchange.com
1,607,589
[ "https://math.stackexchange.com/questions/1607589", "https://math.stackexchange.com", "https://math.stackexchange.com/users/304216/" ]
How do you prove that for any given $c$, there exists an $n$ such that $$cn &lt; n^{\log_{2}n}$$ ? I know that I have to write $n$ in terms of $c$, but I'm having trouble with the log in the exponent.
As updated in Clayton's comment, just require that $n \gt 4$, then the log is greater than $2$, and say $n^{\log_2 n} \gt n^2$. Now use your argument that eventually $n^2 \gt cn$. This will not necesarily find you the minimum $n$ that works, but you were not asked for that.
I think choice of n has to depend on c otherwise we can always contradict it by choosing a c higher than $n^{log_2 n}/n$. $nc&lt;n^{log_en/log_e2}$ $\implies$ $nc&lt;n^{(ln(n))^2/(ln(n)ln(2))}$ $\implies$ $nc&lt;n^{(log_nn) (ln(n)/ln(2))}$ $\implies$ $nc&lt;nn^{ln(n)/ln(2)}$ $\implies$$c&lt;n^{ln(n)/ln(2)}$ $\implies$...
https://math.stackexchange.com
105,002
[ "https://softwareengineering.stackexchange.com/questions/105002", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/30988/" ]
I've been interested in iPhone development since the release of the iPhone, however, I am on a limited personal budget. I've never been willing/able to fork out the money necessary for an iPhone and a Macbook. I know, some may argue that it's not that expensive, but for a hobby it hasn't been worth the price. By som...
The simplest way is to get two user accounts on the Macbook and switch between user sessions whenever you want to switch between work project and hobby project.
Yes, you absolutely can use multiple developer accounts with Xcode. You can set each one up in Xcode preferences, and Xcode will show each one when in places you would expect: signing apps, provisioning devices, etc.
https://softwareengineering.stackexchange.com
149,240
[ "https://softwareengineering.stackexchange.com/questions/149240", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/40390/" ]
I have a method that looks like this: <pre><code>Public Function NormalizeStreetAddress(country As Namespace.Country, streetAddress As Namespace.StreetAddress) _ As Namespace.StreetAddress Dim _streetAddress As New Namespace.StreetAddre...
The names of the variables must be explicit, i.e., when possible, the reader must know what is the variable just by looking at its name. If you have both <code>streetAddress</code> and <code>_streetAddress</code> in the same code, there is a huge problem. Since the two variables are referring to something different, t...
This is largely opinion, the only thing I care about when it comes to variable names is consistency. You want to have a flow from your project that is continued in all its facets. I don't see why it would matter what it's named as long as it's not actively confusing it's function. Furthermore, I'd really like to see ...
https://softwareengineering.stackexchange.com
9,154
[ "https://mechanics.stackexchange.com/questions/9154", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/4750/" ]
We live in the temperate Northern California foothills, and lo these many months ago, my wife took my father's 2001 Infinity up the Reno mountain pass without seeing (or checking) the dangerously low oil gauge. It overheated on the long climb up, engine died on the freeway, and had to get towed back home, and has reste...
Presumably you have already bought a replacement car, given that you left that one standing for a year - so you aren't relying on the Infiniti for anything - and it is currently effectively worthless? In my opinion, it wouldn't be worth the cost of getting a replacement engine professionally fitted - as well as the co...
I would never even consider buying a new engine and get it installed if the price of the engine was even remotely close to the resale value of a working car of the same model.
https://mechanics.stackexchange.com
4,494,602
[ "https://math.stackexchange.com/questions/4494602", "https://math.stackexchange.com", "https://math.stackexchange.com/users/1068764/" ]
Let <span class="math-container">$A$</span> be <span class="math-container">$n\times n$</span> symmetric matrix, and <span class="math-container">$\lambda_1\geqq \cdots \geqq \lambda_n$</span> be eigenvalues of <span class="math-container">$A.$</span> And let <span class="math-container">$\{0\}\neq V$</span> be subspac...
As you have mentioned, if <span class="math-container">$u_k\in V$</span>, then you are done. If <span class="math-container">$u_k\notin V$</span>, then at least one among <span class="math-container">$u_{k+1},\ldots, u_n$</span> is in <span class="math-container">$V$</span>. This is because <span class="math-container"...
<em>Hint.</em> Use a dimension argument to show that <span class="math-container">$V\cap\operatorname{span}\{u_k,u_{k+1},\ldots,u_n\}$</span> is a non-trivial subspace. Now pick any unit vector <span class="math-container">$v$</span> from this intersection.
https://math.stackexchange.com
28,259
[ "https://quant.stackexchange.com/questions/28259", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/22695/" ]
Would anyone know what does it mean to value an asset in "forward space" versus "zero space" ? where does one start from when trying to dig into the meaning of this? Thanks in advance.
In interest rate land you can look at the yield curve in 3 ways: par space (a chart of the par swap rates of different maturities) , zero space (the zero coupon swap rates) and forward space (usually the 3 month forward rates for various maturities). These are equivalent ways to display the prevailing market rates. Pe...
This sounds to me like an unclear reference to the difference between the spot risk-neutral measure ('zero' curves relate to rates starting today which is generally called 'spot') and the forward measure. These are different ways to formulate the pricing of derivative securities. They use different numeraires (the id...
https://quant.stackexchange.com
73,106
[ "https://softwareengineering.stackexchange.com/questions/73106", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/5094/" ]
I believe that I read somewhere that Google has a rule of thumb that an excellent developer is around 300 times more productive than an average one. Does anyone have any rules of thumb used by large companies or maybe there are even some empirical studies on this?
Different studies have found different answers to this question, usually in the 10-fold to 100-fold range. The one I trust most is the classic book <em>Peopleware</em>. They reported on a set of coding wars that they had between programmers from different companies, with the programmers in the corporate environment. ...
The studies I've seen suggest a factor of ten between best and worst (measured by time taken to accomplish tasks of small or medium difficulty), and my interpretation of the data suggests this might be conservative. It could be that the lower end degrades disproportionately fast given big, complicated, and/or innova...
https://softwareengineering.stackexchange.com
75,479
[ "https://softwareengineering.stackexchange.com/questions/75479", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/18074/" ]
Every time I check out a web page dedicated to some programming language I always see the word <em>"powerful"</em> in the list of idiosyncrasies / attributes. If every programming language is powerful why do they put that word in the tutorials / documentations?
I can't think of a language that was ever described as weak. Yes, I see it as marketing blurb, not only that, it places the onus for failure on the programmer rather than on the core capacities of the language. I mean, the language is powerful, so if there are problems with code it clearly cannot lie with the specifica...
Rule #207 of programming languages is that they're all good at some things (i.e., are powerful) and really suck at others. The marketing material falls short in describing <em>where</em> the language it's pushing is powerful. For example, Perl is great at text processing because it has some powerful features that mak...
https://softwareengineering.stackexchange.com
15,795
[ "https://quant.stackexchange.com/questions/15795", "https://quant.stackexchange.com", "https://quant.stackexchange.com/users/6661/" ]
Suppose that: <ul> <li>$W^*_t$ is a Wiener process under probability measure $\mathbb{P}^*$ and;</li> <li>$\tilde{S}_t=S_0+\sigma\int_{0}^{t}S(u)dW^*_s$.</li> </ul> In my lecture notes, it says that $\tilde{S}_t$ is a martingale under $\mathbb{P}^*$ "<strong>due to the fact that the stochastic integral from 0 to t wi...
In the integral <span class="math-container">$$\int_0^t S_u dW^{*}_u \, ,$$</span> <span class="math-container">$dW^{*}_u \equiv W^{*}_{u+du} - W^{*}_u$</span> is independent from the integrand <span class="math-container">$S_u$</span>. So, <span class="math-container">$\mathbb{E}\left[ \int_0^t S_u dW^{*}_u\middl...
I aim to give a <strong>careful mathematical treatment</strong> to this answer, whilst following the fantastic book "Basic Stochastic Processes" by Brzezniak and Zastawniak. The reason I am putting this answer on is twofold: first, to compliment @ William S. Wong's answer by adding greater mathematical intricacy for ...
https://quant.stackexchange.com
112,338
[ "https://stats.stackexchange.com/questions/112338", "https://stats.stackexchange.com", "https://stats.stackexchange.com/users/45603/" ]
I'm trying to better understand some of the theory behind fitting models that have a nonlinear link between the response and the predictors. <pre><code>set.seed(1) #Create a random exponential sample n&lt;-1000 y&lt;-rexp(n=n,rate=.01) y&lt;-y[order(y)] x&lt;-seq(n) df1&lt;-data.frame(cbind(x,y)) plot(x,y) </code></...
In your simulation you are trying to model the $i$-the order statistic, $Y_{(i)}$ of an exponential distribution of an exponentially distributed sample of size $n$ as a function of $i$. This is not an exponential function, so your fitted exponential curves failed. In fact, you are essentially estimating the quantile fu...
To me it looks like your models are all off. For some reason, you decided to use the vector x = seq(n) = (1, 2, ..., n) as a covariate which doesn't make sense. Use a vector of 1s instead (an intercept-only model) and see how it goes. In fact, you don't need to create it because you can use something like: model = glm...
https://stats.stackexchange.com
236,230
[ "https://electronics.stackexchange.com/questions/236230", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/80618/" ]
<strong>Could you please let me know if it's possible to design a PCB layout without a schematic diagram?</strong> I outsourced the development and manufacturing of the ARM board which has 512MB DDR3 RAM and 4GB eMMC. The outsourcing company promised to make it in 45 days, but they didn't give me the product even it'...
It is technically possible to design a PCB layout without first completing a schematic, but extremely unlikely. It just makes it unnecessarily complicated. I think whoever you hired is not being fully honest with you. I think a likely alternate explanation is that the company you hired turned around and outsourced the...
Is very possible that the pcb files you have do not correspond to the circuit you want. it "smells" like they just took a similar board and just gave you the finish board. Not supplying the schematic is a bad sign. my humble oppinion is they are playing with you. Be carefull, never pay for dev in advance, or bad stu...
https://electronics.stackexchange.com
139,026
[ "https://chemistry.stackexchange.com/questions/139026", "https://chemistry.stackexchange.com", "https://chemistry.stackexchange.com/users/97890/" ]
Hybridisation is the mixing of orbitals of similar energies, so when we perform hybridisation, why don't we prefer <span class="math-container">$4\mathrm s$</span> in place of the <span class="math-container">$3\mathrm d$</span> orbital for hybridisation, even though <span class="math-container">$4\mathrm s$</span> has...
M. Farooq is correct that hybridization is a concept that seems to lead students astray more often than not, but your intuition within this simple concept is entirely correct. When s, p and d orbitals are all involved in bonding (I'll avoid the word &quot;hybridization&quot;), it is most often the orbitals that are clo...
I would suggest that this entire factory of bogus hybridization stories should be eliminated from general and organic chemistry curricula. The word mixing is worse, as it is a jug where one can add different orbitals and run a blender and here is the mixture. This stuff is good for rote memorization only. Only after a ...
https://chemistry.stackexchange.com
7,281
[ "https://mechanics.stackexchange.com/questions/7281", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/3743/" ]
My car is a keyless ignition and as such just has a button I press to have it start. My question is... what happens if I hit it while I'm driving?
Nothing. It could work exactly the same as a keyed ignition, in which case your starter motor would engage, but manufacturers (and I think this is true for all) have added a simple piece of logic which only engages the starter if the engine is not already running. This would be the ideal solution for keyed ignition a...
I rented a ford mustang, while reaching to adjust the a/c controls while driving on the interstate my finger accidentally hit the stop start button and at 70 mph the engine immediately shut down. The only way to restart was to coast across 3 lanes of traffic, stop the car, put it in park, put my foot on the brake and ...
https://mechanics.stackexchange.com
78,284
[ "https://mathoverflow.net/questions/78284", "https://mathoverflow.net", "https://mathoverflow.net/users/14574/" ]
I am looking for a reference with definitions on what it means for an algebraic group to be split, quasi-split, and non-split. I would like to see some examples of the different "types". Thanks, Tom
A much more general fact is true: <em>any</em> isometry of <em>any</em> closed negatively curved Riemannian manifold is not homotopic to the identity. There are many proofs of this; one (perhaps not the most natural) is as follows. Hartman proved that if two harmonic maps $f_0,f_1\colon M\to N$ are homotopic, where $M$...
If a surface-diffeomorphism $h$ acts trivially on rational cohomology, the Lefschetz number of $h$ is equal to the Euler characteristic of the surface $\Sigma$. By the Lefschetz fixed-point formula, this number equals the intersection number, in $\Sigma \times \Sigma$, of the graph of the automorphism with the diagonal...
https://mathoverflow.net
339,883
[ "https://electronics.stackexchange.com/questions/339883", "https://electronics.stackexchange.com", "https://electronics.stackexchange.com/users/148544/" ]
What causes a mobile phone charger or any adapter to increase the current on same voltage. I saw that chargers are rated with different amp on same volt ( 5v.1A 5v,500ma 5v,250ma). Ohm law says (V=IR) I am confused....!!!
<blockquote> since the cable impedance is 75 ohms, and the load is also 75 impedance at the end of the cable, is n't the cable already devoid of reflections ? </blockquote> Nobody's perfect. The cable geometry won't be exactly perfect, so its characteristic impedance won't be exactly 75 ohms. It might be 73 or 78 o...
Double termination ensures any reflections from the far end, and any capacitance at the far end will cause reflections back to the DAC output pin, are mostly absorbed at the DAC. Thus double-termination improves settling.
https://electronics.stackexchange.com
50,483
[ "https://cs.stackexchange.com/questions/50483", "https://cs.stackexchange.com", "https://cs.stackexchange.com/users/43431/" ]
I am reading Skiena but do not have a formal background in Computer Science. On page 457 he discusses generating set partitions via restricted growth functions. Here's specifically what he says: <blockquote> <blockquote> Set partitions can be generated using techniques akin to integer partitions. Each set partit...
We want to define a sequence of nonnegative integers $[a_1, a_2,\dotsc, a_n]$ with $a_1=0$ such that for each $1\le i\le n$ we'll have $a_i\le 1+\max\{a_1,\dotsc, a_{i-1}\}$ (Note the last index; the definition you gave would allow $a_i$ to be anything). This condition doesn't uniquely determine $a_i$, rather it gives ...
The restricted growth function encodes which part a given integer belongs to: $$ \begin{array}{|c|c|c|c|c|c|c|} \hline 1&amp;2&amp;3&amp;4&amp;5&amp;6&amp;7\\\hline 0&amp;1&amp;1&amp;2&amp;0&amp;3&amp;1\\\hline \end{array} $$ Part 0 contains $\{1,5\}$. Part 1 contains $\{2,3,7\}$. Part 2 contains $\{4\}$. Part 3 conta...
https://cs.stackexchange.com
3,108,304
[ "https://math.stackexchange.com/questions/3108304", "https://math.stackexchange.com", "https://math.stackexchange.com/users/291190/" ]
I know that a strictly convex quadratic programming problem has a unique solution, but I'm curious about the following situation: If <span class="math-container">$Q$</span> is positive definite, does the following problem: <span class="math-container">$$\min\limits_{x\in\mathbb{R}^n,y\in\mathbb{R}^m }\{x^TQx+{c^1}^Tx+...
Let <span class="math-container">$I=\int{\int_{R}{f(x,y)dxdy}}$</span>, and take the change of variables <span class="math-container">$x=-z$</span>, <span class="math-container">$y=-w$</span>, then <span class="math-container">$$I=\int{\int_{R}{f(-z,-w)dzdw}}=-\int{\int_{R}{f(z,w)dzdw}}=-I$$</span> So we have, <span c...
<strong>Hint</strong> Try the substitution <span class="math-container">$s=-x, t=-y$</span>.
https://math.stackexchange.com
175,173
[ "https://math.stackexchange.com/questions/175173", "https://math.stackexchange.com", "https://math.stackexchange.com/users/36528/" ]
If $\{a_{n}\}_{n\geq 1}$ is a decreasing sequence of real numbers, $a_{n}\in (0,1)$ and $\lim_{n\to \infty} a_{n}=0$. What we can say about $$\lim_{n\to\infty}\frac{a_{n-1}}{a_{n}}$$
Probably not much. Let $a_n = b^{-n}$ for any constant $b &gt; 1$, so then $a_n \in (0, 1)$. Then, $$\lim_{n \to \infty} \frac{a_{n-1}}{a_n} = \lim_{n \to \infty} \frac{b^{-n + 1}}{b^{-n}} = \lim_{n \to \infty} b = b.$$ So, any real number greater than 1 is possible. And, if $a_n = \frac{1}{n}$, then a limit of 1 ...
Let $b_1,...,b_n,...$ be any sequence of positive real numbers such that $\sum_{i=1}^\infty b_i$ diverges. Then let $a_0 = 1$ and $a_{n+1} = \frac{a_n}{1+b_n}$. Then $a_{n-1}/a_{n}= 1+b_{n-1}$. Now, since $\sum b_i$ diverges, $\prod_{i=1}^\infty (1+b_i)$ diverges. But $a_{n} = \frac{1}{\prod_{i=1}^n (1+b_i)}$ So $...
https://math.stackexchange.com
659,880
[ "https://physics.stackexchange.com/questions/659880", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/307740/" ]
So, I've been following the <em>Lectures on the Geometric Anatomy of Theoretical Physics</em> by Frederic Schuller on Youtube (I'm about half way in) and now I've been looking at some special relativity (something I haven't really touched in 1-2 years). Let us start with a short naration about what I think I have clari...
The position <span class="math-container">$x^\mu$</span> is <em>not</em> a four-vector - it is a co-ordinate. <span class="math-container">$x^\mu=\phi(p)$</span> where <span class="math-container">$\phi$</span> is a chart and <span class="math-container">$p\in M$</span> is an event in Minkowski space. Since Minkowski s...
In special relativity, the metric in standard <span class="math-container">$(t, x, y, z)$</span> coordinates is just the identity matrix, with either the tt component equal to -1, or all of the spatial indices equal to -1. In this basis, when you compute the lorentz transformation matrices, you will find that the inver...
https://physics.stackexchange.com
226,257
[ "https://physics.stackexchange.com/questions/226257", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/79444/" ]
We can express supersymmetric transformations as $$\delta F = B\epsilon, \tag{1} $$<br> $$\delta B = F\bar{\epsilon},\tag{2}$$ where $B$ and $F$ denote the bosons and fermions, respectively, in the theory and is the local supersymmetry parameter. My question could be silly, but if the phrase in <strong>bold</strong> ...
You're just not parsing the sentence correctly, or rather, you're just being too nitpicky. When one says that supersymmetry <em>"transforms bosons into fermions and vice versa"</em>, one means that, under an <em>infinitesimal transformation</em>, the variation is purely fermionic for bosons, i.e. $$ B\mapsto B+\delta B...
The $\epsilon$ parametrizes the amount of symmetry transformation. Suppose you don't want any symmetry transformation in the field configuration. So what we want to do is to take the field congiguration and take it to itself. This is the case when $\epsilon = 0.$ So going by your definition, we will get $F = 0$ and con...
https://physics.stackexchange.com
161,510
[ "https://physics.stackexchange.com/questions/161510", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/71583/" ]
Thank you ahead of time for taking to look at this. For this following problem we were given an answer however I am almost positive the given answer is wrong. It doesn't even make sense. So here is the question: <blockquote> The sweep-second hand of a clock is 3.4 cm long. What are the magnitudes of: a) the magnitude o...
What follows is a version of the statement you want to prove which assumes that any two frames are related by a spacetime transformation that leaves time invariant up to translation and that preserves Euclidean distances. Because of these hypotheses, the statement below is a Newtonian answer to the question. I'm conf...
Consider time reversal or parity transformations. Because some physics doesn't have this symmetry, there are separate in-equivalent classes of inertial frames. In each class, the physics will appear the same, and you can rotate, translate, or boost from one inertial coordinate system to another in the same class. Bu...
https://physics.stackexchange.com
86,105
[ "https://datascience.stackexchange.com/questions/86105", "https://datascience.stackexchange.com", "https://datascience.stackexchange.com/users/96612/" ]
I would like to ask you some questions on how to consider (good or not) the following results: <pre><code>OVER-SAMPLING precision recall f1-score support 0.0 1.00 0.85 0.92 873 1.0 0.87 1.00 0.93 884 accuracy ...
In order to get accurate results, you should <strong>not</strong> oversample the test set! Otherwise you are simply evaluating on synthetic samples that you yourself have created. The support on your classification report should mirror the imbalance in your dataset. From what I understand you have 3500 samples, then yo...
In order to detect overfitting you need to separate your data in a training set - that you use to estimate the parameters of you model - and a test set - where you evaluate your model keeping the parameters fixed, this is usually called cross-validation. I understand from your results that you are not doing such separa...
https://datascience.stackexchange.com
6,708
[ "https://mechanics.stackexchange.com/questions/6708", "https://mechanics.stackexchange.com", "https://mechanics.stackexchange.com/users/3346/" ]
When doing a DIY brake job, I understand that it's necessary lubricate several components of the pad/caliper assembly. From various sources, I have been told that the following are the places where brake grease should be applied: <ol> <li>The slide pins connecting one side of the caliper to the other (generously).</li...
Personally, I'm not the hugest fan of anti-seize. I feel like you use it once and it follows you around for the next month. You end up finding it in your sock drawer for heaven's sake. I use similar lube except it's a gold color. It seems to be do lot less following me around, and applies in a much cleaner fashion. <h...
To be safe, the general consensus appears to advocate SilGlyde type grease for the piston area, also the sliding pins of the caliper; many who tried other lubes regret it eventually as the moly greases slowly swell the rubber of the boots and bushings. The moly type generic "brake grease" is to be applied sparingly to ...
https://mechanics.stackexchange.com
31,813
[ "https://security.stackexchange.com/questions/31813", "https://security.stackexchange.com", "https://security.stackexchange.com/users/21401/" ]
There is a website that tenants can use to pay their rent. That website uses an http address but apparently uses a third-party product, which embeds an iframe into the page. The source of that iframe is https and all forms within the page are within that iframe. I'm wondering what are the security risks of this type ...
<blockquote> I'm wondering what are the security risks of this type of setup for the users. </blockquote> It's almost as bad as serving everything over plain HTTP. You get protection against purely passive listening attacks, but really anyone in the position to do that kind of man-in-the-middle attack is very likel...
Mixing HTTP and HTTPs pretty much destroys most advantages of HTTPS. For one, an attacker could present you with a malicious parent HTTP frame, with the iframe linking to his own site. The browser wouldn't find it suspicious. Neither would the user. The iframe URL is hidden, and the iframe isn't claiming to be HTTP. No...
https://security.stackexchange.com
336,167
[ "https://physics.stackexchange.com/questions/336167", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/155397/" ]
I already know mathematical proof which states velocity of electron increases with increase in atomic number,but what is the intuition behind it?
The same reason the Earth would move faster should the mass of the sun increase: centripetal force grows. In the case of Bohr's model, the force grows as $\sim Z$, $$ F_e = \frac{k Ze^2}{r^2} $$ Newton's law thus results in $$ \frac{mv^2}{r} = F_e = \frac{k Ze^2}{r^2} $$ leading to $v \sim Z^{1/2}$
As others have mentioned already, it is a classical mechanics problem. Assuming an already circular orbit, the magnitude of the centripetal force (v^2/rho) is what is necessary to keep the object in circular orbit at speed v. This force is generated by the nucleus, and this relationship is bilateral, meaning that if t...
https://physics.stackexchange.com
453,401
[ "https://physics.stackexchange.com/questions/453401", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/140512/" ]
The results for deriving the density of states in different dimensions is as follows: <ul> <li>3D: <span class="math-container">$g(k)dk = 1/(2\pi)^3 4 \pi k^2 dk$</span></li> <li>2D: <span class="math-container">$g(k)dk = 1/(2\pi)^2 2 \pi k dk$</span></li> <li>1D: <span class="math-container">$g(k)dk = 1/(2\pi) 2 dk$<...
The problem is underspecified. Consider the collision in the centre of mass frame, where the particles have momentum <span class="math-container">$\vec{p}$</span> and <span class="math-container">$-\vec{p}$</span>. Then so long as after the collision both particles come out in opposite directions with equal momenta bot...
1D is just a special case of 2D which is a special case of 3D. The difference is not physical but mathematical. Certain modes can be idealized as 1D while others cannot. Is the motion is defined along a line or on a plane or two skew lines?
https://physics.stackexchange.com
103,263
[ "https://softwareengineering.stackexchange.com/questions/103263", "https://softwareengineering.stackexchange.com", "https://softwareengineering.stackexchange.com/users/30960/" ]
I'm starting with SCRUM and I have a problem understanding one thing. How does SCRUM handle backlog items that take longer than one sprint?
Such items are either called Epic and must be divided into smaller user stories which are shorter then a single sprint and because of that can be planned, or Theme which will be divided into Epics and those into common stories. Epics and Themes share the main characteristic - high level of uncertainty = they cannot be ...
You don't have such items. If you have, then the backlog item isn't specific enough and hasn't been properly broken down into smaller items. Some people call them not backlog, but <em>fatlog</em> items and in Scrum they are considered a anti-pattern. The cake analogy user story: As a cake-eater, I want to eat cake in ...
https://softwareengineering.stackexchange.com
1,047,517
[ "https://math.stackexchange.com/questions/1047517", "https://math.stackexchange.com", "https://math.stackexchange.com/users/64184/" ]
Let $(M,g)$ be a Riemannian manifold and $\Gamma(S^2M)$ the space of symmetric 2-covariant tensors. Define the <strong>gravitation operator</strong> as the map \begin{align*} G:\Gamma(S^2M)&amp;\rightarrow\Gamma(S^2M)\\ h&amp;\mapsto Gh:=h-\frac{1}{2}(\text{tr}_gh)g, \end{align*} where the metric trace $\text{tr}_gh=g...
Setting $k=Gh$, see if you can write $\mathrm{tr}_gk$ in terms of $\mathrm{tr}_gh$ (and thus vice versa). You should find a relatively clean expression, and from there it's just simple algebra: suppose $\mathrm{tr}_gh = f(\mathrm{tr}_gk)$ for some $f$. Then $k_{ij}=h_{ij}-\frac12f(\mathrm{tr}_gk)g_{ij}$, so $h_{ij}=k...
It is not invertiable at least when the dimension $n$ of $M$ is two. Take $h = g$. Then $$(Gh)_{ij} = (Gg)_{ij} = g_{ij} - \frac{1}{2} g^{kl}g_{kl} g_{ij} = g_{ij} - \frac{n}{2} g_{ij} = 0 . $$
https://math.stackexchange.com
411,600
[ "https://physics.stackexchange.com/questions/411600", "https://physics.stackexchange.com", "https://physics.stackexchange.com/users/193942/" ]
<blockquote> An object is moving along X axis with position as a function of time given by <span class="math-container">$x = x(t)$</span>. Point <span class="math-container">$O$</span> is at <span class="math-container">$x = 0$</span>. The object is definitely moving towards <span class="math-container">$O$</span> wh...
If the body were a discrete set of point mass objects rotating around an axis, you would write $I=\sum_j m_j r_j^2$ For a continuous body the sum goes over into an integral. You consider it as smaller and smaller mass objects. You think of, say, a brick as being made up of grains of rock, then atoms... The objects ge...
Conceptually, each little piece of an object contributes to the total moment of inertia. Each little piece of an object consists of a volume of matter so that each piece has some small mass, $$\delta m = \rho\left(\vec{r}\right) \delta V.$$ $\rho\left(\vec{r}\right)$ is a density function whose value depends on the po...
https://physics.stackexchange.com
193,906
[ "https://security.stackexchange.com/questions/193906", "https://security.stackexchange.com", "https://security.stackexchange.com/users/99312/" ]
<strong>I am trying to demo an exploit and here is the scenario:</strong> A service is running with SYSTEM privileges where the executable it is running (binpath) can be modified by any user. The exploit consists of replacing the target binary with a malicious one so that on startup of the machine the malicious execut...
Generally, binaries can be renamed while they are executing, unless the process (or some other process) explicitly prevents this. Simply rename the binary and then drop a malicious one in with the old name. When the computer reboots (or the service restarts), it'll run your version. Another approach is DLL planting. F...
From an infosec perspective, yes, there are several ways of accomplishing this depending on the level of access to the server. You cannot trust binaries to remain static once installed, and so HIPS/HIDS or whitelisting are important layers of defense. Incorrect permissions on the executable already allow anyone to ove...
https://security.stackexchange.com
308,393
[ "https://mathoverflow.net/questions/308393", "https://mathoverflow.net", "https://mathoverflow.net/users/10007/" ]
I am interested in any adjunctions between any of the familiar categories of Groupoids and the category of finite dimensional Hilbert spaces. Do any exist? Are there any well know monads on the category of groupoids of this type, ie, generated by such an adjunction? For instance, are there any interesting adjunction...
One suggested variant was to ask whether there are any interesting adjunctions between the category $FinGpd$ of finite groupoids and the category $FinHilb$ of finite-dimensional Hilbert spaces, which is still undefined. The answer is still no. First let me suppose that the morphisms of $FinHilb$ are all linear maps. T...
I don't know what morphisms you intend for the category of finite-dimensional Hilbert spaces, but it doesn't actually matter. The answer is <em>no, there are no interesting adjunctions between the category of groupoids and the category of finite-dimensional Hilbert spaces</em>. More generally, <blockquote> If $C$ i...
https://mathoverflow.net