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 |
|---|---|---|---|---|---|
394,911 | [
"https://softwareengineering.stackexchange.com/questions/394911",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/341389/"
] | As I understand the "Same Origin Policy" is a browser security feature that aims to protect the user. It prevents scripts to load data from another webserver (typicall with ajax).
So esentially there are 3 actors:
<ul>
<li>The User in the Browser</li>
<li>The Original Website</li>
<li>The "other origin" Web Resource<... | It protects the legitimacy of the interaction between the user and the "original" website from malicious Javascript executed on the "other origin."
Suppose I am logged into a super-secret admin portal A. I've finished doing my admin work, so I decide to go off browsing and find myself on dodgy website B.
Dodgy websit... | I believe Same Origin Policy protects two things:
<ul>
<li><strong>The website's cookies</strong> from being sent by a hacker. (e.g. hackersareus.com cannot send Stack Exchange a request with their cookies in it) This is a preflight request.</li>
<li><strong>The website's public-facing pages</strong> from being scrape... | https://softwareengineering.stackexchange.com |
255,420 | [
"https://electronics.stackexchange.com/questions/255420",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/109119/"
] | I was reading one of my textbooks the other day about linear BJT emitter-follower amplifiers (non-relevant) and came across the following passage:
<blockquote>
Although the small-signal voltage gain of the emitter follower is slightly less than 1, the small signal current gain is normally greater than 1. Therefore t... | <blockquote>
It seems that whenever people talk about power, they are only really
concerned with current and not voltage
</blockquote>
Ignorant people perhaps, but every competent electrical engineer knows that <em>both</em> voltage and current must be taken into account.
<blockquote>
<strong>Although</strong> ... | You are correct that power is a function of both current and voltage.
There are circumstances where one is more significant than the other. Using the quoted example of an emitter follower (aka common collector) amplifier, the voltage gain is almost 1 (not very interesting) so all the power gain comes from the current ... | https://electronics.stackexchange.com |
133,222 | [
"https://softwareengineering.stackexchange.com/questions/133222",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/46750/"
] | I work in a small (7 developer) development team and we all work on our own projects. Some of the barriers to team work are the languages and platforms we work on (.NET vs mainframe RPG programming) but other barriers are just that we're all so busy we haven't taken the time to take a step back and organize teams. Me... | I can think of a few things to start with. This might not be an ideal list since this is something I see established teams wrestle with sometimes.
Firstly, if you don't have it, I'd get some necessary infrastructure in place. Things like source control, maybe a build server, and documentation couldn't hurt.
Secondly ... | Any time you face challenges, you can start a discussions with your colleagues to come up with a solution. You can share your ideas and they will come up with theirs for the problem at hand. This will help foster <strong>collaborative learning environment that fostered teamwork and team learning.</strong>
Good luck!
| https://softwareengineering.stackexchange.com |
20,983 | [
"https://scicomp.stackexchange.com/questions/20983",
"https://scicomp.stackexchange.com",
"https://scicomp.stackexchange.com/users/15195/"
] | I am looking at approximating my function <span class="math-container">$f(x)$</span> using a Chebyshev and Legendre series and I ran into this question.
<blockquote>
Is interpolation using <span class="math-container">$n+1$</span> Chebyshev nodes the same as representing the function using the first <span class="math-c... | The two are different. Taking <span class="math-container">$n=0$</span>, we see that the interpolation is <span class="math-container">$f(0)$</span>, whereas in the second one, the approximation is <span class="math-container">$\displaystyle\int_{-1}^1 \dfrac{f(y)}{\sqrt{1-y^2}}dy$</span>.
| What you are doing here is projecting a function onto a basis of a finite dimensional space of polynomials. All you use in the formulas you show is that the basis $T_k$ is orthogonal, i.e., that $\left<T_i,T_j\right>=0$ if $i\neq j$ with regard to some scalar product $\left<\cdot,\cdot\right>$. All of this ... | https://scicomp.stackexchange.com |
283,204 | [
"https://softwareengineering.stackexchange.com/questions/283204",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/164670/"
] | When designing a domain, either way of following approaches can be used to access list of child entities inside a parent entity.
<strong>1. Get/Set</strong>
Following approach is straight forward and simple to implement, but anyone can overwrite the Orders collection.
<pre class="lang-csharp prettyprint-override"><... | Important question: in the first example, where does the code that enforces the business invariant live?
The first approach looks simple and straight forward because all the hard stuff has been moved somewhere else!
So, in order:
<pre><code>public User
{
public IList<Order> Orders { get; set; }
}
</code><... | This is one reason why the IEnumerable interface is used. This allows your public getter property to return a collection you can iterate over but cannot add or remove items from. The underlying read/write collection could be an IList.
<pre class="lang-csharp prettyprint-override"><code>public class User
{
public U... | https://softwareengineering.stackexchange.com |
80,104 | [
"https://security.stackexchange.com/questions/80104",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/67070/"
] | I am developing an application the architecture of which is arranged as follows:
<code>Session host <---> Central relay server <---> Session client</code>
All communication between the initiating <code>session host</code> and the subsequently connecting <code>session client</code> is relayed through the c... | As you have said yourself, the hash becomes the password in this case. Therefore it's no more or less secure. And you again correctly identified that the only real benefit is that the user cannot expose their password in the case of re-use. Personally I'd be tempted to generate passwords for the host, and then give the... | In your scenario the hashes add little security because the client sends the hash to the central server, however the client should send the attempted password, the central server then checks the hash of the password against the submitted hash.
Hashing is very important in this scenario, because you may have a maliciou... | https://security.stackexchange.com |
345,288 | [
"https://softwareengineering.stackexchange.com/questions/345288",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/266714/"
] | We're in the process of migrating a monolithic application to microservice architecture. Due to some regulatory requirements, we have to keep client's data from different countries in separate (country specific) databases. I.e US db for US customers, UK db for UK customers...
The following designs that we are consider... | I think option 2 is not a bad one, but may not be needed. Micro services are for letting you deal with the needs of multiple applications.
A big factor here, is if there is any difference between the two schemas, and if there ever will be in the future.
Usually, I think using interfaces for repositories is unnecessar... | I would prefer Option 1 as this would make the application completely stateless. The db Url mapping can be passed as a part of configuration. Making the application stateless would mean easier failover and easier routing (load balancing). Option 2 would require application to be aware of region. For e.g. If one of your... | https://softwareengineering.stackexchange.com |
115,917 | [
"https://softwareengineering.stackexchange.com/questions/115917",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/13852/"
] | We're in the business of automated trading and our team consists of two bigger groups, I call them data producers and data consumers.
The producers' primary task is to maintain a chain of smaller tools that push some real-time data through an indicator system and out comes an order. All the data that was needed or pr... | I think it's appropriate to have someone who has a view into what each team is doing, and can identify potential problems, opportunities, redundant work and so on and make recommendations to improve things. It'd be that person's responsibility, from the technical side, to determine whether what the different groups are... | You're asking a very specific question based on a very specific project and set up but it actually points to a generic answer that applies to all projects:
<blockquote>
<strong>It's whoever it's agreed to be by the people involved.</strong>
</blockquote>
There is no one right team structure, even for a specific sit... | https://softwareengineering.stackexchange.com |
96,909 | [
"https://dba.stackexchange.com/questions/96909",
"https://dba.stackexchange.com",
"https://dba.stackexchange.com/users/62638/"
] | My simple <code>SELECT</code> statement on a view in Postgres 9.3.1 is pretty slow. The receipts table has 20 million entries and the other one has around 17k.
But I still think it should be faster than ~16 seconds?
Table <code>receipts</code>:
<pre><code> Column | Type | Modifiers | St... | I am pretty sure the reason is that <code>customerid</code> in the view is the result of:
<pre><code>COALESCE(b.customerid, s.customerid::bigint)
</code></pre>
After <code>LEFT JOIN</code>, cast & <code>COALESCE</code>, the predicate cannot be pushed down, so both tables have to be read in full, before the filter... | Do you have clustered and nonclustered indexes? Try clustered index on receipt number and date. And non clustered index on receipt number, receipt position, date, and price
| https://dba.stackexchange.com |
293,363 | [
"https://math.stackexchange.com/questions/293363",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/56763/"
] | So, Is a cancellation possible for the Cartesian product? ex. if you have two Cartesian products that are equal to eachother, do the 2nd sets for each product equal eachother?
Lets say you have AxB=AxC for the sets A, B, and C. Does it then follow that B=C?
I think it does, because for AxB to = AxC, B and C must be... | Your intuition that the claim is true is correct. Notice however that just like for cancelation with real numbers you need some condition on $A$.
So, you can prove that if $A\ne \emptyset$ and $A\times B = A\times C$ then indeed $B=C$. However, you can also prove that without the restriction $A\ne \emptyset$ it is po... | Hint: Use this fact that for two ordered pairs:
$$(a,b)=(a,c)\Longleftrightarrow b=c, a\in A,~ b\in B,~ c\in C$$
| https://math.stackexchange.com |
326,217 | [
"https://softwareengineering.stackexchange.com/questions/326217",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/75108/"
] | When writing custom deserialization code, what's the better practice: a static method that creates an uninitialised object (e.g. using the default constructor) and then performs deserialization, or a constructor that performs deserialization directly?
For example, deserializing a Foo:
<pre><code>class Foo
{
int b... | No, it should not.
Serialization is orthogonal to the object and thus should be kept outside. Custom serialization belongs in a customization to a serializer.
| I know this is old, but I'll throw in one more thought. Often you're deserializing a polymorphic object (which could be <code>Subclass1</code> or <code>Subclass2</code> of <code>Parent</code> for instance, and the data will tell you which one). In most languages a constructor can't/shouldn't return a derived object, so... | https://softwareengineering.stackexchange.com |
225,338 | [
"https://security.stackexchange.com/questions/225338",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/226389/"
] | I have a client that has a couple of machines that are build to cut kitchen tables. These machines still run on Windows XP and are connected to the internet.
Now I need to find a way that these people can run these machines as safely as possible without updating from OS (not possible, I asked the manufacturer from the... | It is not that uncommon to have these out-of-support and vulnerable machines in an organisation. It's important to perform a risk assessment to determine the impact of any vulnerabilities.
<h2>High-Level Risk Assessment</h2>
<h3>Threats:</h3>
<ul>
<li>Internet connections mean that remote threats are a problem</li>
<li... | Think about possible threats. How could an attacker gain access to the system?
<ul>
<li>An attacker could monitor the internet connection and block the updates or insert fake updates.<br>
=> To protect against modified (malicious) updates, the updates could be cryptographically signed.</li>
<li>A computer in the netwo... | https://security.stackexchange.com |
406,629 | [
"https://physics.stackexchange.com/questions/406629",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/146870/"
] | I am currently studying "Critical Dynamics - A Field Theory Approach to Equilibrium and Non-Equilibrium Scaling Behavior", and came across an issue I can't solve.
If you know about functional derivatives and/or Martin-Siggia-Rose formalism, please skip the rather long paragraph meant to bring some context. I hope the ... | There are two issues at stake here.
First, concerning the question itself :
By definition, $\Gamma$ is the Legendre transform of $W=\ln Z$,
$$
\Gamma[\phi]=-W[J]+\phi.J,\\
\frac{\delta \Gamma}{\delta\phi_A}=J_A,
$$
where I use condensed notations $J_A$, $\phi_A$, $J.\phi=J_A \phi_A$, etc. with $A$ collecting space-ti... | The trick to compute $\Gamma^{(1,1)}$ is to compute the cross derivative
$$
\frac {\delta^2 \Gamma}{\delta\Phi^\alpha(x,t)\delta j^\beta(x',t')}.
$$
This can be done in two ways. On one hand, you know the result is $\delta_{\alpha\beta} \delta(x-x') \delta(t-t')$, because this is simply the derivative of $j^\alpha(x,... | https://physics.stackexchange.com |
14,237 | [
"https://stats.stackexchange.com/questions/14237",
"https://stats.stackexchange.com",
"https://stats.stackexchange.com/users/5383/"
] | First off, I know little about statistics, so some of this question may seem naive.
I'm trying to perform linear regression to model the relationship between x and y where:
-x is a company's daily stock volume on a date
-y is variable that is taken from the same date, however is something unrelated to stock volume. ... | It's fairly common practice to log-transform financial data. You could also look through the rest of the family of Box-Cox transformations, and stop when you judge the distribution to be normal. You're idea to divide daily volume by total index volume is a good one, but that distribution STILL may not be normal.
Furt... | Honestly this is more of a finance question than a stats one. (I'm new to CV but have been finding a huge number of questions on here about forecasting financial time series!)
Anyway, it always helps to normalize your variables as much as possible. A guiding principle might be that we should always be able to meaningf... | https://stats.stackexchange.com |
561,760 | [
"https://physics.stackexchange.com/questions/561760",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/220004/"
] | I'm studying QFT, and Peskin is his book takes a couple of paragraphs to talk about causality in QFT, using the Klein-Gordon field as an example.
The book says on p. 28:
<blockquote>
To really discuss causality, however, we should ask whether [...] a measurement performed at one point can affect a measurement at anothe... | <blockquote>
All the calculations in Peskin's book are correct, but I'm not understanding his claim: if a commutator is zero, shouldn't this mean that the measurements can be done simultaneously?
</blockquote>
I think that you are confusing the notion of "<em>simultaneous measurement</em>" (or <em>"simul... | I'm not entirely sure, because I can't find it anywhere (and this is why I asked in the first place) but I think that <em>no measurement in the Klein-Gordon theory <strong>only</strong> can affect another measurement outside the light-cone</em>, meaning that other field theories, like the Dirac one, can and will violat... | https://physics.stackexchange.com |
277,442 | [
"https://physics.stackexchange.com/questions/277442",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/128737/"
] | Why do we use gravitational force in earth by relating just the mass of an object with the acceleration produced by the gravitational field:
$$
F_{g} = m\cdot \vec{g}
$$And when we're dealing with planets, we use a relation defined by the masses of two planets, distance squared and gravitational constant:
$$
F_{g} = G ... | The second equation is always correct, and you can derive the first equation from it.
Here on the surface of the Earth, $d$ is the radius of the Earth $r_e$ plus our height $h$.
$$
F = G \frac{M_e M_2}{(r_e + h)^2}
$$
The radius of the Earth (6,371 km) is huge compared to our height above the surface (at least, when... | We use the first formula for earth based calulations because $$
G \cdot \frac{M_{1}}{d^{2}}=g $$to a good approximation.
We used the second formula for planets because we do not have an easy simplification. So to put simply, they are the same formula but one just has a nice simplification.
| https://physics.stackexchange.com |
594,881 | [
"https://electronics.stackexchange.com/questions/594881",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/299922/"
] | I am trying to use an old phone charger with 5V DC output. I measured the output to be 6.4V.
It works for powering an ESP8266 through VIN but does not work to power an IR receiver I want to use.
The receiver works when I power it through a different source (5V or 3V and ground from an Arduino.) It also does not work w... | <blockquote>
<em>Can anyone explain this behavior to me?</em>
</blockquote>
Ground on one charger does not necessarily mean it connects to ground on another charger or "system". Ground is <strong>not</strong> "earth" so there is almost certainly a massive galvanic isolation between the two. Earth is... | IR Rx's require low ripple Vdc to function due to the AGC sensitivity to supply noise.
<strong>Your charger is unregulated and noisy</strong>, and therefore <strong>the IR Rx needs a linear regulator</strong> to remove the noise within it's DC operating range.
Ground is just a local 0V reference. PE or protective Eart... | https://electronics.stackexchange.com |
2,039,683 | [
"https://math.stackexchange.com/questions/2039683",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/338941/"
] | Prove that your function is one-to-one and onto the given codomain
A friend wrote this for this problem and I dont understand what they do for the onto part of the proof. Why can y be written as x+1. And is this correct.
F: $\mathbb N$ $\rightarrow \mathbb N$ - {1} F(x)=x+1
pf. Let y $\in$ $\mathbb N$ - {1} then y... | A better way to word the onto part:
Let $y \in \Bbb{N} \smallsetminus \{1\}$. Then $y - 1 \in \Bbb{N}$ and $F(y-1) = y - 1 + 1 = y$, so $y$ is in the image of $F$ and $F$ is onto.
| Let $x \in \mathbb{N} - \{ 1 \}$. Then, $x \geq 2$. So, $x - 1 = z$ for some $z \geq 1$ (i.e $z \in \mathbb{N}$). Hence, $x$ is of the form $z + 1$ where $z \in \mathbb{N}$. Hence, $F$ is onto, because $F (z) = x$.
| https://math.stackexchange.com |
51,880 | [
"https://mechanics.stackexchange.com/questions/51880",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/33052/"
] | How often do Tire Pressure Managemnt System (TPMS) sensors report? Is it a standard value? If not, what's the general range? Also, each sensor has its own ID, correct? Not one ID per vehicle?
| TPMS sensors do not report in real time. Anyone who's make such a statement clearly has a lack of engineering knowledge as it's physically impossible as there must be some amount of time between data transmissions how ever small whether its 1mS, 1s, 1 minute.
It varies depending on the manufacture and type of system f... | TPMS sensors report in real time.
For the other questions, I believe it's very manufacturer dependent. i.e. Volkswagen-Audi Group TPMS sensors will report the actual PSI of each tyre, while other manufacturers (Kia, Hyundai, etc) will simply display a warning light when one of the tyres are found to be "low". Hence a... | https://mechanics.stackexchange.com |
441,486 | [
"https://electronics.stackexchange.com/questions/441486",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/212151/"
] | Quite a simple question actually, does a poor mobile network signal cause faster battery drain?
If so, is there a difference between 2g/3g/4g/5g in the speed at which the battery drains.
| Actually, it's having a poor link back to the tower that does you in. Cell phones (and towers) interactively adjust their transmit levels to be just good enough for solid reception. So there's a command from the tower to the phone that pretty much boils down to "speak up, sonny!", but is probably named something bori... | <blockquote>
Quite a simple question actually, does a poor mobile network signal
cause faster battery drain?
</blockquote>
Yes, the problem is three fold:
<ul>
<li>The phone needs to use more CPU and radio resources to establish a link</li>
<li>A poor signal corresponds to higher packet loss. Whenever loss occurs... | https://electronics.stackexchange.com |
12,150 | [
"https://electronics.stackexchange.com/questions/12150",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/1240/"
] | Is there anything I need to he aware of when using K-type thermocouples?
I got the idea by touching the probe. I can get a reading when measuring temperature for 30 seconds using a DMM. A commercial electronic thermometer needs around minutes for the same result.
This gave me an idea to make a device which will use... | These themocouples have a tiny spot weld between two thin wires to make the active sensor element, which results in a very low thermal mass. Hence they change temperature quickly, which is the same thing as reacting to temperature changes quickly. As soon as you mount them in a larger substrate or coating (eg to provid... | Thermocouples are not stable enough to measure human body temperature (you want 0.05C accuracy there). It only gives about 1-2C long-term stability.
Platinum PT100/1000 RTD ones are much more suitable and way way more procise.
When you have this extra-accuracy, you can measure target temperature while ovserving how i... | https://electronics.stackexchange.com |
44,006 | [
"https://cs.stackexchange.com/questions/44006",
"https://cs.stackexchange.com",
"https://cs.stackexchange.com/users/35047/"
] | I need help on this exercise:
You are given an array of n elements, and you notice that some of the elements are duplicates; that is, they appear more than once in the array. Show how to remove all duplicates from the array in time O(n log n).
I find a solution but in O(n^2)... How can I apply D&C?
| Given an array of elements $a[i], 0\le i\le n-1$, we know we can sort it in time $O(n\log n)$. Then do the following to produce an array $b[\;]$:
<pre><code>declare b to be of size n
old = a[0]
b[0] = a[0]
j = 1
for i = 1, ... , n
if a[i] =/= old // found a new value
old = a[i] // save it
b[j] =... | This is my solution (pseudocode):
<pre><code>Duplicate(A: array):
Array B = Merge-sort(A)
Array Vect // New Vector
int p=2
Vect[1] = B[1]
for i=2 to B.lenght{
if (B[i]<>B[i-1]) then
Vect[p] = B[i]
p = p+1
}
return Vect
</code></pre>
is correct?
| https://cs.stackexchange.com |
627,540 | [
"https://electronics.stackexchange.com/questions/627540",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/315886/"
] | Let's say you have a power supply that at 110 V draws 1.3 A max in its steady state, but has an inrush of up to 50 A. If you want to limit that inrush current to 5 A, you could use a 22 ohm resistor. Easy enough.
What I'm unclear on is if you limit this inrush current to 5 A, will you prolong the length of the inrush? ... | For an RC circuit if we neglect the ESR of the capacitor and diodes, RC=T so by increasing R you increase T [seconds]. But you also reduce the I^2R=P power loss so as to reduce temperature rise, but still need to waste the same amount of energy in heat just spread out over a long time and lower.
Arrhenius Law is used ... | <blockquote>
<em>What I'm unclear on is if you limit this inrush current to 5a, will
you prolong the length of the inrush? 50a to 5a is a factor of 10.
Would inrush last 10 times as long? Or is it always a few milliseconds
whether current limited or not?</em>
</blockquote>
For a regular power supply, the inrush current... | https://electronics.stackexchange.com |
489,118 | [
"https://physics.stackexchange.com/questions/489118",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/235838/"
] | Say that you have a weight attached to a 2 metre long string, and you are rotating the weight at 5 m/s. Is every point on the string going to be rotating at that same velocity of 5 m/s, or is the velocity of the string going to change according to how far away you are from the centre of rotation?
I'm looking at the li... | For different points of the string to have same velocities, their direction of movement and speeds would to be the same as well. If the string is taut then all points are moving in the same direction at any given time, but it's easy to show that the speeds are not the same: If you have your 2 meter long string, the end... | For an object rotating about an axis, every point on the object has the same angular velocity. The tangential velocity of any point is proportional to its distance from the axis of rotation, i.e. <span class="math-container">$\mathbf{v_{\perp}} =
\boldsymbol{\omega} \times \mathbf{r}.$</span> So it depends what you me... | https://physics.stackexchange.com |
115,266 | [
"https://stats.stackexchange.com/questions/115266",
"https://stats.stackexchange.com",
"https://stats.stackexchange.com/users/54257/"
] | As far as I know, one can differentiate between two main goals of the regression analysis:
<ol>
<li>The goal is understanding causal relations between variables. Here, one has to check several common regression assumptions (main being linearity, normality, residuals zero mean, homoscedasticity, independence of errors)... | 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 |
220,367 | [
"https://electronics.stackexchange.com/questions/220367",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/-1/"
] | I want to find the inverse fourier transform of the following transfer function :
$$
H(iw) = \frac{10 + (iw)}{4 - w^2 + 4(iw)}
$$
So my first idea was to replace \$iw\$ with \$s\$. Then convert this into some euler formula. This gives me :
$$
h(t) = \frac{10 + s}{4-w^2 + 4s}
$$
But I can't really factor the denominato... | You are right, \$s=j\omega\$, so
$$ \omega = \frac{s}{j}= \frac{js}{j^2} = -j s $$
Substituting that into your transfer function
$$ H(j\omega) = \frac{10+j\omega}{4-\omega^2+4j\omega} = \frac{10+s}{4-\left(\frac{s}{j}\right)^2+4s} = \frac{10+s}{4+4s+s^2},$$
since \$\frac{1}{j^2} = \frac{1}{-1}=-1\$.
In order to find \... | Write \$H(s)\$ as $$H(s)= \frac{10}{s^2+4s+4}\:+\:\frac{s}{s^2+4s+4}$$
The time response for the first term is easily found from the Laplace Transform tables \$\small (\zeta=1\$, \$ \omega_n \small =2)\$; then differentiate this and divide by 10 for the time response of the second term.
This gives:
$$h(t)=e^{-2t}(1+8... | https://electronics.stackexchange.com |
20,172 | [
"https://mathoverflow.net/questions/20172",
"https://mathoverflow.net",
"https://mathoverflow.net/users/3818/"
] | I come across the following problem in my study.
Let <span class="math-container">$x_i, y_i\in \mathbb{R}, i=1,2,\cdots,n$</span> with <span class="math-container">$\sum\limits_{i=1}^nx_i^2=\sum\limits_{i=1}^ny_i^2=1$</span>, and <span class="math-container">$a_1\ge a_2\ge \cdots \ge a_n>0 $</span>. Is it true <sp... | [Wrong ounter-example deleted]
This it true for all $n$. The case $n=2$ is handled by Hailong Dao, let's reduce the general case to $n=2$.
First, we may assume that $a_1=1$ and $a_n=0$ as others mentioned. So remove the denominator in LHS. Then forget the condition that $a_i$ are monotone, let's only assume that they... | The inequality is true for all <span class="math-container">$n$</span>.
First of all, we can simplify it a little - from Douglas Zare's comment, we can assume <span class="math-container">$a_0 = 1$</span>, <span class="math-container">$a_n = -1$</span>, and try to maximize the LHS by varying the <span class="math-cont... | https://mathoverflow.net |
84,084 | [
"https://dba.stackexchange.com/questions/84084",
"https://dba.stackexchange.com",
"https://dba.stackexchange.com/users/53270/"
] | I have two tables :
Table1 (col1, col2, col3, col4, val1, status)<br>
Table2 (col1, col2, col3, col4, val2)
For Table1 and Table2, The columns (col1, col2, col3, col4) are the composite primary key.
Table2 may have duplicated rows, for that reason I would like to <code>group by (col1, col2, col3, col4)</code> and <c... | If you have a primary key, you don't have duplicate rows.
In Oracle, you do multi-table UPDATEs by using MERGE, and not UPDATE, because that is inefficient.
<pre><code>merge into table1
using (select col1, col2, col3, col4, sum(val2) sum_val2 from table2 group by col1, col2, col3, col4) table2
on (table1.col1 = tabl... | Grouping a Primary Key is wasted time, since you get groups of one record only. Hence, the SUM function is unnecessary, you just need to get the column.
But, the real problem you are trying to solve, is a bit unclear. If you ever have 2 tables in a database, with EXACTLY the same Primary Key, there is something wrong... | https://dba.stackexchange.com |
47,074 | [
"https://dba.stackexchange.com/questions/47074",
"https://dba.stackexchange.com",
"https://dba.stackexchange.com/users/26416/"
] | I'm fairly new to Oracle database. I have installed <code>Oracle Database 11g R2</code> on <code>Oracle Linux 6</code>. I have successfully created a new database with <code>dbca</code> and connected to the database using:
<pre><code>$ sqlplus "/ as sysdba"
</code></pre>
I successfully created a table and inserted so... | You created the table in the <code>SYS</code> schema (which you should <strong>never</strong>, ever do. Really, <strong><em>never</em></strong>).
When you log in as <code>teacher1</code> any statement looks for objects in that schema. But there is no <code>TEACHER1.INSTRUCTORS</code> table, because the real name is ... | my answer is just write table name with login credentials of "sys" or/and "xe"
like
for my program change
ur table name is EMP then write XE.EMP
like "select * from XE.EMP"
| https://dba.stackexchange.com |
373,653 | [
"https://softwareengineering.stackexchange.com/questions/373653",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/307455/"
] | I have been developing Cloud Broker system so I have Users. Users can register with phone number and code. How should I design the User class?
<pre><code>Class User
{
public string User_Name{get;private set;}
}
</code></pre>
Or
<pre><code>Class User
{
public string User_Name{get;private;}
public string Phone_Num... | First, it is always a good idea for not abusing variables with a specific name for holding completely different data. Do the maintenance programmer (which could be actually you) a favor by <strong>not</strong> putting phone numbers into a member variable called <code>User_Name</code>, or vice versa.
So if I got you ri... | Does not really matter. If you are following an Object-Oriented paradigm, then <em>functionality</em> is what you have to think about.
So instead of adding data, think about what this data will be used <em>for</em>, and add that to the <code>User</code> class. If you want to <em>authenticate</em>, then add an <code>Au... | https://softwareengineering.stackexchange.com |
186,408 | [
"https://mathoverflow.net/questions/186408",
"https://mathoverflow.net",
"https://mathoverflow.net/users/1048/"
] | The set of 5-tuples of lines in $\mathbf{P}^3$ is parametrized by the 20-dimensional product of Grassmannians $G(2,4)^{\times 5}$. The set of cubic surfaces is parametrized by a 19-dimensional projective space.
I can present a line in $\mathbf{P}^3$ as a $2 \times 4$ matrix (the projectivization of the row span) and ... | It's a <span class="math-container">$20 \times 20$</span> determinant. Take each <span class="math-container">$2 \times 4$</span> matrix
<span class="math-container">$$L = \begin{pmatrix}
s & t & u & v \\
w & x & y & z \\
\end{pmatrix}$$</span>
and turn it into the <span class="math-container">$... | I would write it differently. First, consider the universal space $M$ consisting of tuples $(S,L_1,\dots,L_5)$, where $S$ is a cubic surface and $L_i$ are lines on $S$. This space lies inside the product $P^{19}\times Gr(2,4)^5$ and can be described as the zero locus of a canonical global section of the vector bundle
$... | https://mathoverflow.net |
580,784 | [
"https://physics.stackexchange.com/questions/580784",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/275098/"
] | My Grandparent asked me this question a few years ago, and I am getting around to giving him an answer, but I don't know the answer. Can anyone help?
<blockquote>
"A pickup truck is speeding along a highway at 60 mph. One man (c) is standing on the side of the highway at point A. Two men (a and b) are standing in... | This experiment implies retrocausality <em>if</em> you assume a classical way of thinking. The point of these experiments is to demonstrate that either retrocausality is real <em>or</em> the physics of the world are not precisely classical. The QM community, of course, would prefer to argue that their causal model is... | Suppose you have a bowl containing two red slips and two black slips. You draw a slip. If it's red, you draw another one. The second one will be black in about 2/3 of the trials, because there are two black slips and one red one left in the bowl when you draw it.
Now consider a variation of this experiment with the dra... | https://physics.stackexchange.com |
236,126 | [
"https://electronics.stackexchange.com/questions/236126",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/110382/"
] | I have quite a few Radio Controlled Toys, Some I have hacked so that they become autonomous.
This gave rise to a question:<br>
<strong>Can all Receiver (RX) and Transmitter (TX) chip be somehow made compatible with each other ?</strong> Say I have RX-2 and TX-2 chips. Can I use a remote from 1 toy to control the oth... | A lot of modern RC toys use 2.4 GHz chips originally intended for other purposes, such as wireless mice and keyboards. Generally each manufacturer of one of the original designs chose their own modulation and packet framing details uniquely - it would be possible to make a universal chip that handled all of those, tho... | "Q.1) Is it possible to use RX / TX chips from two different toys together?"
Maybe, if the two chips use the same protocol and frequency. In the old days, with 27 MHz radio controlled model planes and such, there was one dominant protocol and the only variation was the 27 MHz sub-band that was used, so exchaning a cry... | https://electronics.stackexchange.com |
1,974 | [
"https://robotics.stackexchange.com/questions/1974",
"https://robotics.stackexchange.com",
"https://robotics.stackexchange.com/users/1139/"
] | I want to steer a RC car in a straight line.The car has 4 sharp IR sensors on each corner of the car to help it steer the corridor.The corridor is irregular and looks something similar to the picture below.
The car needs to be stay exactly at the middle(shown by lighter line) and take help of the IR sensors to correct... | If you have a map, then you can use a Kalman filter with a motion update based on odometry and a sensor update based on the actual IR sensor readings and the expected sensor readings given your current position and the map. The PID control you implemented will only be able to make the vehicle drive in the actual center... | You could have it keep track of the last distance read from the IR sensors and if it changes more than a certain amount (2%? not sure what would work for you) calculate the difference between the measured distance and the expected distance. Save that difference as an offset, which you apply to the reading from that IR ... | https://robotics.stackexchange.com |
13,470 | [
"https://softwareengineering.stackexchange.com/questions/13470",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/3382/"
] | I'm thinking about leaving my current employer and wondering how one goes about that process in the programming world. We have a lot of projects on the go at the moment and I'm the only developer. We have 4-5 projects that are fairly big and need to be done in the next few months and even a few longer than that.
I'm l... | Assuming that you've made your decision to leave, you should put it in writing. Whether this is an actual letter, an e-mail or a form you fill out will depend on the company and culture, but it should be written down and not a phone call, text message or even just face to face. If you do one of the latter things it's o... | You should just tell them, that the way things are, you are unwilling to stay.
<ul>
<li>Worst case, they take it very personally and start yelling at you. Since you intend to leave, you don't have to take it, just leave.</li>
<li>Maybe, they simply don't care. There's no discussion, they just let you go and you don't ... | https://softwareengineering.stackexchange.com |
1,167 | [
"https://dsp.stackexchange.com/questions/1167",
"https://dsp.stackexchange.com",
"https://dsp.stackexchange.com/users/759/"
] | I have trouble distinguishing between these two concepts. This is my understanding so far.
A stationary process is a stochastic process whose statistical properties do not change with time. For a strict-sense stationary process, this means that its joint probability distribution is constant; for a wide-sense stationar... | A random process is a collection of random variables, one for each time instant under consideration. Typically this may be continuous time (<span class="math-container">$-\infty < t < \infty$</span>) or discrete time (all integers <span class="math-container">$n$</span>, or all time instants <span class="math-co... | Let us consider a hypothetical random process where the sample functions are DC values and are different from each other:
<blockquote>
X<sub>1</sub>(t) = constant= mean of X<sub>1</sub>(t)
X<sub>2</sub>(t) = constant= mean of X<sub>2</sub>(t)
</blockquote>
The temporal mean of <span class="math-container">$X_1(t)$</s... | https://dsp.stackexchange.com |
228,025 | [
"https://electronics.stackexchange.com/questions/228025",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/106314/"
] | If a transistor works as a 'switch' and I turn it on using a controller (Arduino), how can I burn the controller?
I pass a 5v, 0.02A charge from my Arduino controller to transistor's base. The transistor opens and lets the electricity flow from the collector to the emitter powering on my other larger 40v device.
Can... | From a voltage standpoint, yes it could be done.
However, voltage is not everything. You need to look at the datasheet for the coin cells to see if they can supply enough current. In almost all cases (apart from some Li-Ion rechargeable ones), the rated continuous current sourcing capability is only ~2mA at most - typ... | Just the core CPU - yes, it'll easily run from a single coin cell.<br>
BLE bluetooth radio - yes. Although you'd want to aim for a fairly low level of activity on the radio link or you ruin the battery life.<br>
LEDs - not well. You need to be careful, pwm the brightness and only light one at a time. If you try turning... | https://electronics.stackexchange.com |
3,269 | [
"https://mathoverflow.net/questions/3269",
"https://mathoverflow.net",
"https://mathoverflow.net/users/290/"
] | Serre's <em>A Course in Arithmetic</em> gives essentially the following proof of the three-squares theorem, which says that an integer $a$ is the sum of three squares if and only if it is not of the form $4^m (8n + 7)$ : first one shows that the condition is necessary, which is straightforward. To show it is sufficie... | The intuition for this method of passing from a rational solution to an integral solution seems pretty simple to me: passing from a rational solution to a nearby integral point (not necessarily a solution) is passing to a point whose denominators are 1, so you can anticipate that when you intersect the line through you... | A few days ago Serre told me about some modest improvements to the proof, based on Weil's book <em>Number theory: an approach through history from Hammurapi to Legendre</em> and on a 1998 letter from Deligne to Serre; I will paraphrase these below.
According to Weil (p. 292), the ``magical'' argument is due to an amat... | https://mathoverflow.net |
3,737,193 | [
"https://math.stackexchange.com/questions/3737193",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/800978/"
] | This is what I have:
<span class="math-container">$\lim_{x \to 0} x \cdot |x|=0$</span>
And I know:
<span class="math-container">$$|x|=\begin{cases}x,&\text{if }|x|\ge 0\\-x,&\text{if }x <0\;.\end{cases}$$</span>
Case 1:
<span class="math-container">$\lim_{x \to 0^+}=0$</span>
<span class="math-container">$(... | To start with, let's ignore any value of <span class="math-container">$x \ge 1$</span>. We only need to consider function values close to <span class="math-container">$0$</span>, so for our intents and purposes, <span class="math-container">$f(x) = |x|$</span>. The only thing we need to be careful of is ensuring that <... | Sorry, but you're quite far from a proof. Using <span class="math-container">$\delta=\varepsilon$</span> is not sufficient and you're never actually using the function that you want to find the limit of.
There is no need to go to one-sided limits. Your purpose is, given <span class="math-container">$\varepsilon>0$</... | https://math.stackexchange.com |
201,782 | [
"https://math.stackexchange.com/questions/201782",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/40130/"
] | I have difficulties in evaluating $$\lim_{x\to 1} \frac{\sqrt{3+x}-2}{\sqrt[3]{7+x}-2}$$
Could you give me a hint how to start solving this? (I know the result is $3$)
Thanks a lot !
| You know that $$(x^3-y^3)=(x-y)(x^2+xy+y^2)$$ and $$(a^2-b^2)=(a-b)(a+b)$$ so if $a=\sqrt{3+x}$ and $b=2$, we have $(a^2-b^2)=(\sqrt{3+x}-2)(\sqrt{3+x}+2)=3+x-4$. The same calculation can be done for another identity by taking $x=\sqrt[3]{7+x}$ and $y=2$. In fact you have $$(\sqrt[3]{7+x}-2)\big((\sqrt[3]{7+x})^2+2\sqr... | Use L'Hospital's Rule.
If we want to avoid explicit mention of L'Hospital's Rule, rewrite our expression as
$$\frac{\sqrt{3+x}-2}{x-1}\frac{x-1}{\sqrt[3]{7+x}-2},$$
and observe that
$$\lim_{x\to 1}\frac{\sqrt{3+x}-2}{x-1}\quad\text{and}\quad \lim_{x\to 1}\frac{\sqrt[3]{7+x}-2}{x-1}$$
are each derivatives.
If we wa... | https://math.stackexchange.com |
143,035 | [
"https://stats.stackexchange.com/questions/143035",
"https://stats.stackexchange.com",
"https://stats.stackexchange.com/users/71805/"
] | I have a conceptual question that I haven't managed to grasp yet and is most likely a econometrics 101 question by here it goes:
If we estimate a GARCH model for a time series, how do we then use this in my model for the returns? For example; I have the return data of an index. I know that I have volatility clustering... | Suppose the conditional mean of returns is constant. A GARCH model gives you a fitted value of the conditional variance for each data point. These fitted values can be used to weight the data points to construct an efficient estimate of the mean (e.g. using weighted least squares); data points with high fitted conditio... | Consider the data generating process (DGP):
$y_{t}= x_{t}^{\prime}\beta+\varepsilon_{t}$ (1)
$\varepsilon_{t}= \sigma_{t}z_{t},\quad z_{t}\sim i.i.d.\, N\left(0,\,1\right)$ (2)
$\sigma_{t}^{2}= \sigma^{2}+\alpha\varepsilon_{t-1}^{2}+\beta\sigma_{t-1}^{2}$ (3)
Equation (1) is a model for the conditional mean of the ... | https://stats.stackexchange.com |
26,477 | [
"https://dsp.stackexchange.com/questions/26477",
"https://dsp.stackexchange.com",
"https://dsp.stackexchange.com/users/16293/"
] | While learning about Fourier Transform after Fourier Series, That we can calculate Fourier transform of periodic signals too. If we can take the Fourier transform of periodic signal too then my question is why we Fourier series if Fourier transform can be calculated for both periodic and aperiodic?
| You can't take the Fourier transform of a periodic signal, the integral diverges for all multiples of the period.
This can be handled by the theory of distributions, but the Fourier series is a better fit.
| The difference between a series and a function is, algebraically speaking, the field over which you define the mapping, and important concepts like convergence and differentiability. Your choice of whether you're after the Fourier Series representation or the Fourier Transform doesn't depend on what you want to analyze... | https://dsp.stackexchange.com |
122,558 | [
"https://math.stackexchange.com/questions/122558",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/26081/"
] | I am given <span class="math-container">$((0,1),*)$</span> where <span class="math-container">$x,y\in (0,1)$</span> and <span class="math-container">$*$</span> is defined as
<span class="math-container">$$x*y=\frac{xy}{1-x-y+2xy}$$</span>
How should I go about finding the inverse of an element and identity element?
| Well, to find the identity, you need to find an element $y$ such that for every $x$,
$$x*y = \frac{xy}{1-x-y+2xy} = x.$$
This leads to
$$xy = x - x^2 - xy + 2x^2y$$
or
$$x^2-x = (2x^2-2x)y$$
hence to
$$y = \frac{x^2-x}{2x^2-2x} = \frac{1}{2}.$$
Now verify that $\frac{1}{2}$ is actually the identity of this operation.
... | If the problem is to verify that $G = ((0, 1), \ast)$ is a group, in fact what we have to show the first is whether the associativity holds or not. Let
$$ f(z) = \frac{1-z}{z} $$
with the inverse
$$ f^{-1}(w) = \frac{1}{1+w}.$$
Then
$$\frac{xy}{1-x-y+2xy} = \frac{xy}{(1-x)(1-y) + xy} = \frac{1}{\left(\frac{1-x}{x}... | https://math.stackexchange.com |
86,395 | [
"https://mathoverflow.net/questions/86395",
"https://mathoverflow.net",
"https://mathoverflow.net/users/17588/"
] | Is there a classification of the algebraically closed fields that have maximal proper subfields ?
And if an algebraically closed field has a maximal proper subfield, is that subfield unique ?
Summarizing the answers, an algebraically closed field has a maximal subfield if and only if its characteristic is zero and ... | If $F$ is a maximal proper subfield of a field $K$, then $K=F(x)$ for any $x\in K\setminus F$. Next, $x$ must be algebraic over $F$ (otherwise $F\subsetneq F(x^2)\subsetneq F(x)\subset K$). So $K$ is finite over $F$, and if $K$ is algebraically closed it is well known (cf. KConrad's comment) that $F$ is a real closed f... | This occurs iff the field has characteristic 0. By KConrad's comment, being characteristic 0 is certainly a necessary condition. Conversely, given an algebraically closed field K of characteristic 0, we can use Zorn's Lemma to find a maximal ordered subfield F. Since K is algebraically closed, F must be real closed.... | https://mathoverflow.net |
140,086 | [
"https://electronics.stackexchange.com/questions/140086",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/36799/"
] | When writing assembly code, say R1 = R2 + R3, it is pretty easy to understand the addressing procedure because all registers are close to the ALU. But I find it hard to see how does the ALU go to the memory in R2 in instructions like R1 = R1 + M[R2]. It could be very far away, and I don't see it going checking and matc... | The hex number is a convenience based on the hardware of the processor and memory. A 4 digit hex number like FA3B represents 16 digits in binary (1111 1010 0011 1011), which are the 16 address lines of the system memory. There is a physical 1 to 1 relationship between the binary numbers and the hardware "wires". They a... | In my opinion: R1 = R1 + M[R2] is not one of the most basic instructions that CPU can execute in only one clock cycle.
If the CPU does not support this instruction, the compiler should translate this into 2 simpler ones: the first loads data into a temporary register, the second adds that values to R1. Notice that, th... | https://electronics.stackexchange.com |
555,109 | [
"https://electronics.stackexchange.com/questions/555109",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/253350/"
] | I know FPGA/ASIC are for a specific task and they are not microprocessors and an OS is needed mainly if multiple processes (tasks) need to be run concurrently.
Just wondering if an FPGA/ASIC can have an operating system. Is there any real time need which may require this?
| Well, you can use without doubt an FPGA without software, in fact many are used to support booting more complex systems (power sequencing, for example). But you can also define some kind of embedded soft processor needing an OS.
On the other hand no CPU <em>really</em> requires an operating system, you could probably p... | You can put a soft processor into the FPGA logic, and there are a lot of FPGA parts with integrated hard processors, these processors are running software, so can and in a lot of cases do run an OS.
The FPGA itself though is a bunch of logic, it's not 'running code' so the idea of an OS doesn't make sense.
| https://electronics.stackexchange.com |
322,218 | [
"https://softwareengineering.stackexchange.com/questions/322218",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/154753/"
] | We have a problem at our org where we have the need to know "with very high certainty" what specific versions of each app/web service/etc. is deployed to a given node and/or environment at any given point in time.
Some ideas have been kicked around, such as:
<ul>
<li>A custom deploy tool that is backed by a DB, and o... | I'm thinking you might want to pop this question over to Server Fault and turn it around: how do sysadmins for big corporations know what versions of what software is installed on their client machines. There might be some industry-standard solution that looks at, say, the version of DLL's in a predefined location on e... | First off, there are tools out there that can scan ports and network traffic to help you discover your software catalog but the bottom line is in order to be highly accurate you will have to touch every web-service or application and redeploy them to properly report their build versions and other information you want f... | https://softwareengineering.stackexchange.com |
164,128 | [
"https://softwareengineering.stackexchange.com/questions/164128",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/3124/"
] | I'm working with a SQL Server database with 1000+ tables, another few hundred views, and several thousand stored procedures. We are looking to start using Entity Framework for our newer projects, and we are working on our strategy for doing so. The thing I'm hung up on is how best to split the tables into different m... | Personally, I've tried making one huge schema for all my entities on a fairly complex but small project(~300 tables) . We had an extremely normalized database (5th form normalization (I say that loosely)) with many "many to many" relationships and extreme referential integrity enforcement.
We also used a "single inst... | Let me start by simple clarification: I don't have experience with such large database so the rest of my answer is not based on the real world example.
So you have a BIG database and you want to use it with ORM / EF. I would go with the second choice. Here is my simple explanation why:
<ul>
<li>Mapping adds complexit... | https://softwareengineering.stackexchange.com |
62,033 | [
"https://mathoverflow.net/questions/62033",
"https://mathoverflow.net",
"https://mathoverflow.net/users/14464/"
] | It is known that cos(N) spans a countable dense set in [-1,1].
(N: any natural number)
As far as I know generally, for any continuous function f defined in [a,b],
f is Riemann integrable where its domain is a countable dense set in [a,b].
<strong>My question: will cos[t_n*Log(p)] Spans a countable dense set in [-1,1... | For any fixed real $\alpha$, the fractional parts of the numbers $\alpha \gamma$, where $\beta+i\gamma$ runs over all zeros of $\zeta(s)$ in the critical strip with $0<\gamma < T$, become uniformly distributed in $\mathbf{R}/\mathbf{Z}$ as $T\to \infty$. This is a theorem of Fujii; see his paper "On the zeros o... | If the cosine values only related to the zeros on the critical line span a countable dense set, every cosine value determined by all the nontrivial zeros can span a countable dense set, too. n can be varied from 1 to infinity, and this I think will make a dense set. Do you agree?
| https://mathoverflow.net |
22,238 | [
"https://robotics.stackexchange.com/questions/22238",
"https://robotics.stackexchange.com",
"https://robotics.stackexchange.com/users/26977/"
] | This may be a noob question. I am sorry if it is but I am new to this field. I am working on a design of SCARA Robot and I am using Stepper Motors to drive it. In many youtube videos, I have seen that they increase the torque using timing belts. Now I understand that in most cases timing belts are used for keeping moto... | Even at zero speed, stepper motors have a max torque, called the holding torque. If your design needs even higher torque than that, you <em>could</em> use a bigger (heavier, more expensive) motor. Alternatively, use a ratio in the belt drive.
To be concrete: a 1:2 ratio will double the available torque, but at the expe... | As r-bryan answered they do increase the effective torque. However that also increases the effective resolution giving you better repeatability. As an example a direct drive motor that provided a 0.1 degree repeatability using a 4 to 1 ratio belt drive would give you a 0.025 degree resolution. The trade off is a lower ... | https://robotics.stackexchange.com |
6,052 | [
"https://physics.stackexchange.com/questions/6052",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/2300/"
] | Decades ago I was in a physics Ph.D. program, made a hash of things, and quite rightly was dropped from the program. Since then I've had a very satisfying career as a computer programmer, and picked up an M.S. in Applied Math. I'm currently working in a bioinformatics research lab, and really enjoying myself.
I think ... | The point of PhD programs is to produce future scientists; it seems unlikely that any decent department would admit someone who indicates that they "have no intention of seeking a further career in physics."
Since you do have a background in physics, math, and computing, it does seem like you could earn your keep in... | After getting a Engineers degree from Naval postgrad in his youth and working twenty-five years as a industry researcher, my father went back to school and got his Piled Higher and Deeper in M.E. a few years after I finished mine in physics{*}, and I had a grad school colleagues in his late fifties.
Neither seems to m... | https://physics.stackexchange.com |
597,837 | [
"https://physics.stackexchange.com/questions/597837",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/281328/"
] | I understand that different atoms have specific electronic configurations that allow them to absorb specific energies of photons, so their electrons can excite and deexcite in steps to release photons of particular frequencies. However I am confused as to what happens to the other wavelengths of light as they strike fo... | You have that
<span class="math-container">$$
\begin{equation}
\begin{cases}
mg=N \sin \theta \\
m\frac{v^2}{r}=N \cos \theta\\
r=h \tan \theta \\
\end{cases}
\end{equation}
$$</span>
where <span class="math-container">$\vec{N}$</span> is the normal force of the cone against the gravity,
solving this system you obtain ... | This problem is ideal for the Virial Theorem, which relates the average kinetic energy (<span class="math-container">$\bar T$</span>) and total potential energy (<span class="math-container">$U$</span>) in a <span class="math-container">$r^n$</span> potential via:
<span class="math-container">$$ 2\bar T = nU $$</span>
... | https://physics.stackexchange.com |
111,184 | [
"https://electronics.stackexchange.com/questions/111184",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/40382/"
] | In my project, the current budget is very tight.
With less than 1mA, I have to isolate sensor's signal voltage and be able to measure it with ADC on the other side of the isolation barrier.
What I have thought of is that using VF conversion and send the digital signal via photocoupler.
I have looked for commerciall... | An electric clothes dryer has two main components - the heating element and the motor. The spec label tells you the total current drawn by the dryer and they also tell you how much of that current is for the motor.
Also note that (usually) the motor current comes from one phase only (at least, in North America). That... | What do you mean by an "Electric Dryer"?
Hair dryers often operate the motor off a tap on the heating element so that some/most of the heating current also goes through the motor. The voltage across the motor is very low so that the majority of the power is dissipated in the heating element.
| https://electronics.stackexchange.com |
77,593 | [
"https://cs.stackexchange.com/questions/77593",
"https://cs.stackexchange.com",
"https://cs.stackexchange.com/users/74557/"
] | (From CLRS -- 3-4,d)
Let $f(n)$ and $g(n)$ be asymptotically positive functions.
I tried to prove that $$f(n) = O(g(n)) \implies 2^{f(n)} = O\left(2^{g(n)}\right) .$$
I know that the above statement is false, so where have I gone wrong in my proof?:
<blockquote>
Suppose $f(n) = O(g(n)).$ Then there exist positive... | You should be able to work out the answer yourself. Here's the general procedure:
Since you know of a counterexample to the original claim, plug those $f,g$ into each step of your proof and find the first step in your proof where the proof goes wrong. In other words, find the first claim made in the proof that isn't... | Your mistake seems to be in assuming that $a^n \cdot a^m = a^{nm}$. Rather, we have $a^n \cdot a^m = a^{n + m}$.
| https://cs.stackexchange.com |
66,650 | [
"https://mathoverflow.net/questions/66650",
"https://mathoverflow.net",
"https://mathoverflow.net/users/3757/"
] | Like many of my questions, this question is actually aimed at $p$-adic analysis.
One of the main obstacles in doing analysis $p$-adically ist that the $\mathbb{Q}_p$ is totally disconnected.
From previous answers and reading I learned that one tries to circumvent these problems
and the result are things like "rigid a... | After seeing wood's last comment (comment #2 under his question), I've decided to add a few words (a bit too many for a comment) which hopefully make clear the force of Qiaochu's answer.
Generally speaking, the categorical meaning of "completion" refers to taking a left adjoint of a <i>full</i> inclusion of categorie... | The two-point discrete space already doesn't have a (universal) connectification, in the sense that two points don't have a coproduct in the category of connected spaces. If $X$ were such a coproduct, then given any pair of points in a connected space $C$ there would have to be a unique compatible map $X \to C$. But le... | https://mathoverflow.net |
59,733 | [
"https://physics.stackexchange.com/questions/59733",
"https://physics.stackexchange.com",
"https://physics.stackexchange.com/users/6764/"
] | Lets say we have a finite square potential well like below:
<img src="https://i.stack.imgur.com/3PGLK.png" alt="finite well">
This well has a $\psi$ which we can combine with $\psi_I$, $\psi_{II}$ and $\psi_{III}$. I have been playing around and got expressions for them, but they are not the same for ODD and EVEN sol... | Wavefunctions are found by solving the time-independent Schrödinger equation, which is simply an eigenvalue problem for a well-behaved operator:
$$ \hat{H} \psi = E \psi. $$
As such, we expect the solutions to be determined only up to scaling. Clearly if $\psi_n$ is a solution with eigenvalue $E_n$, then
$$ \hat{H} (A ... | I found the case myself. There was a mistake in a GNUPLOT script. The line:
<pre><code>g(x) = -( A*exp(-L*(d/2)) )/( sin(L*(d/2)) )*sin(L*x)
</code></pre>
Should have $\mathcal K$ in place of the first $\mathcal L$. This was the first mistake but after i fixed it my graphs still were sloppy, so i redid all the readi... | https://physics.stackexchange.com |
188,092 | [
"https://stats.stackexchange.com/questions/188092",
"https://stats.stackexchange.com",
"https://stats.stackexchange.com/users/98975/"
] | I completed Andrew Ng's Machine Learning course around a year ago, and am now writing my High School Math exploration on the workings of Logistic Regression and techniques to optimize on performance. One of these techniques is, of course, regularization.
The aim of regularization is to prevent overfitting by extending... | If you use <em>regularization</em> you're not only minimizing the in-sample error but $OutOfSampleError \le InSampleError + ModelComplexityPenalty$.
More precisely, $J_{aug}(h(x),y,\lambda,\Omega)=J(h(x),y)+\frac{\lambda}{2m}\Omega$ for a hypothesis $h \in H$, where $\lambda$ is some parameter, usually $\lambda \in (... | I'm not sure if I really know what I'm talking about but I'll give it a shot. It isn't so much having small weights that prevents overfitting (I think), it is more the fact that regularizing more strongly reduces the model space. In fact you can regularize around 10000000 if you wanted to by taking the L2 norm of you... | https://stats.stackexchange.com |
2,401,405 | [
"https://math.stackexchange.com/questions/2401405",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/87884/"
] | Is the below matrix an Identity Matrix?
\begin{equation*}
\mathbf{A}=
\begin{bmatrix}
0 & 0 & 0 & 1 \\
0 & 0 & 1 & 0 \\
0 & 1 & 0 & 0 \\
1 & 0 & 0 & 0
\end{bmatrix}
\end{equation*}
As \begin{equation*} \mathbf{A^{-1}} = \mathbf{A} \end{equation*}
\be... | It's certainly not true that $A^{-1}A=A$ for this $A$. On the standard basis,
$$ Ae_1 = e_4,\quad Ae_2=e_3,\quad Ae_3 = e_2,\quad Ae_4=e_1, $$
so $A^2e_i = e_i$ for all $i$. Hence $A^{-1}=A$, but $A^{-1}A=A^2$ has matrix
$$ \begin{pmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 &... | The definition of the identity matrix is a matrix $I$ such that for every matrix $A$
$$AI= IA =A$$ However your matrix does not satisfy this condition. What you've listed are just properties of $I$ not the definition
| https://math.stackexchange.com |
376,229 | [
"https://stats.stackexchange.com/questions/376229",
"https://stats.stackexchange.com",
"https://stats.stackexchange.com/users/198058/"
] | Two variables that are uncorrelated are not necessarily independent, as is simply exemplified by the fact that <span class="math-container">$X$</span> and <span class="math-container">$X^2$</span> are uncorrelated but not independent. However, two variables that are uncorrelated AND jointly normally distributed are gua... | The the joint probability density function (pdf) of bivariate normal distribution is:
<span class="math-container">$$f(x_1,x_2)=\frac 1{2\pi\sigma_1\sigma_2\sqrt{1-\rho^2}}\exp[-\frac z{2(1-\rho^2)}], $$</span>
where
<span class="math-container">$$z=\frac{(x_1-\mu_1)^2}{\sigma_1^2}-\frac{2\rho(x_1-\mu_1)(x_2-\mu_2... | Joint normality of two random variables <span class="math-container">$X,Y$</span> can be characterized in either of two simple ways:
<ul>
<li>For every pair <span class="math-container">$a,b$</span> of (non-random) real numbers, <span class="math-container">$aX+bY$</span> has a univariate normal distribution.</li>
<li... | https://stats.stackexchange.com |
139,141 | [
"https://softwareengineering.stackexchange.com/questions/139141",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/37962/"
] | If I want to host a website from my home, I buy a domain name. Then, I get a static IP from my ISP. Next, I point it to the IP address of my home system. I can even use the SQL server installed in my system and not worry about the size. I am not talking about piles of servers here. Just one server.
I was wondering if ... | This is a great idea. Not only will you learn a lot about multiple topics (system administration, security, HTTP, the value of logging, detecting loss of contact with outer world, etc etc etc etc), but you will be keeping The Internet more personal, more human, more of what drew us to it in the first place.
Did everyo... | It depends. If it's a small personal website, why not. If it's an enterprise-scale website requiring 99,99% or more service availability, it's certainly a bad idea.
Firstly, think about the cost:
<ul>
<li>Windows Server and Microsoft SQL Server already have a <strong>substantial price per licence</strong>. Do you pre... | https://softwareengineering.stackexchange.com |
818,161 | [
"https://math.stackexchange.com/questions/818161",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/75843/"
] | Suppose that repetitions are not allowed.
There are $6 \cdot 5 \cdot 4 \cdot 3 $ numbers with $4$ digits , that can be formed from the digits $1,2,3,5,7,8$.
How many of them contain the digits $3$ and $5$?
I thought that I could subtract from the total number of numbers those,that do not contain $3 \text{ and } 5$.I... | You have used a correct Stars and Bars argument to show that there are $462$ ways to distribute $6$ objects in $6$ boxes.
However, if we assume that the dice are fair, and do not influence each other, then these $462$ possibilities are <em>not all equally likely</em>.
Let us look at a much smaller example, two ident... | There are $6!$ combinations of six different numbers, and there are $6^6$ combinations of six rolls. The probability is then:
$$
p = \frac{6!}{6^6}
$$
| https://math.stackexchange.com |
77,886 | [
"https://softwareengineering.stackexchange.com/questions/77886",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/25765/"
] | I have been working for 5 years at the same company now. I want to go and find a new job. Finding jobs or getting interview calls has been difficult, there are have far and few. And to compound the problem I need work permit(H1b) to work.
My question is how do network with other programmers and increase my chances of ... | You can't "network to get a job," it's impossible to do well, and it's a big turn-off to have someone get to know you and lose interest when you can't help them get a position at your company.
Networking is like farming. You plant seeds, cultivate and weed consistently, and harvest at the right time.
What you should ... | The most profound network is rediscovering the network you already have - my best job opportunities have come from previous colleagues. I'd recommend that, no matter what channel you use, you make a point of reviewing your address book and hunting down people you've lost touch with. A "hi, how are you doing?" email, ... | https://softwareengineering.stackexchange.com |
73,598 | [
"https://dba.stackexchange.com/questions/73598",
"https://dba.stackexchange.com",
"https://dba.stackexchange.com/users/45313/"
] | I tried to solve the following problem for about one hour now and still didn't get any further with it.
Okay, I have a table (MyISAM):
<pre><code>+---------+-------------+------+-----+-------------------+----------------+
| Field | Type | Null | Key | Default | Extra |
+---------+--------... | I have three suggestions
<h1>SUGGESTION #1 : Rewrite the query</h1>
You should rewrite the query as follows
<pre><code>SELECT http,
COUNT( http ) AS count
FROM reqs
WHERE date >= ( DATE(NOW() - INTERVAL 1 DAY) + INTERVAL 0 SECOND )
GROUP BY http
ORDER BY count;
</code></pre>
or
<pre><code>SELECT * FROM
(
SELEC... | Change your date column type to an integer. Store the date as a Unix date in integer. Timestamp Is a lot larger than an int. You'd get some bang out of that.
| https://dba.stackexchange.com |
1,875,103 | [
"https://math.stackexchange.com/questions/1875103",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/203030/"
] | <blockquote>
Find a function $f: \mathbb{R} \rightarrow \mathbb{R}$ that is Riemann
integrable on every bounded and closed interval, such that the
function $$ g: \mathbb{R} \rightarrow \mathbb{R}: x \mapsto
\int_{0}^{x} f$$ is not differentiable in at least one point.
</blockquote>
I was looking for a function ... | Just take the function $f(x)=1$ for $x>0$ and $f(x)=0$ for $x\leq 0$. The integral should have a corner at $x=0$.
| It seems that a good approach to this problem is to look for $g$ first, then "differentiate it" to get $f$.
Of course, you won't technically be able to differentiate everywhere (that's the point!), but it's a useful source of inspiration.
So we're looking for a function $g$ that is (say) differentiable everywhere exce... | https://math.stackexchange.com |
7,958 | [
"https://cardano.stackexchange.com/questions/7958",
"https://cardano.stackexchange.com",
"https://cardano.stackexchange.com/users/4375/"
] | Is there a way for <code>cardano-cli</code> to generate stake registration certificate using the extended stake address verification key (<code>stake_xvk</code>) that was generated from <code>cardano-address</code> CLI?
Steps to generate extended stake address verification key:
<pre><code> cardano-address recovery-phra... | I think there might be a misunderstanding in the fact that a transaction has several "outputs" - and those outputs are called "UTXO"'s <em>(as long as they are unspent; hence "unspent transaction outputs")</em> - and those can be spent separately.
So one of the UTXOs created by your first ... | <ol>
<li>In the first transaction (starting with 23141), there is a single input UTXO with three outputs - the first output (4.5 ADA) going to a non-staking address, the second <em>and</em> third outputs are going <strong>back</strong> to the sender's address, likely as change.
</li>
<li>The second transaction (startin... | https://cardano.stackexchange.com |
69,766 | [
"https://softwareengineering.stackexchange.com/questions/69766",
"https://softwareengineering.stackexchange.com",
"https://softwareengineering.stackexchange.com/users/23386/"
] | As a software development professional in a fairly conservative large-firm, I always had a much more action-oriented bent, as my job was fairly stable and all that mattered was doing as I was told and completing tasks that were germane to the career of a benevolent dictator (i.e., my boss' boss).
Now that I'm no longe... | <strong>You need both.</strong>
If you don't know where you want to go, you're not likely to get there. But you also need to actually get started, and to take every step along the way.
But as you make that transition from corporate drone to entrepreneur, you shouldn't think that you either remain an obedient servant ... | It's nice to have visions, but they don't put bread on the table. In fact most often they lead to big financial losses as people end up chasing rainbows rather than creating practical products that can be sold to real customers for a decent profit in a reasonable amount of time.
| https://softwareengineering.stackexchange.com |
1,080,055 | [
"https://math.stackexchange.com/questions/1080055",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/203076/"
] | How do I solve something like:
$$f(x) = \frac{1}{\sqrt{2 \pi}} \int_{-\infty}^\infty e^{\frac{-(y - x/2)^2}{2}}f(y)\:\mathrm{d}y$$
for $f(x)$?
Is there also a general formula that this falls under? The closest thing I found was the Fredholm integral equation, but those (I believe) assume that the eigenfunction is li... | It is correct to deduce that, for an arbitrary element $x$ of $A$, since $A ⊆ B \cup C$, it follows that either $x \in B$ or $x \in C$.
But we can have $x_1 \in A$ such that $x_1 \in B$ and $x_2 \in A$ such that $x_2 \in C$, and both $x_1, x_2 \in B \cup C$.
The wrong step is to conclude from $x \in B$, since $x$ w... | $A \subseteq B \cup C$, so $x\in B$ or $x\in C$ for all $x\in A$, but there is no reason to think, that ALL $x\in A$ are in $B$ or ALL are in $C$. Some might be in $B$, others in $C$.
Specifically: $$\forall x\in A : x\in B \text{ or }x\in C$$ does <em>not</em> imply:
$$\forall x \in A : x\in B\text{ or } \forall x \i... | https://math.stackexchange.com |
25,837 | [
"https://cs.stackexchange.com/questions/25837",
"https://cs.stackexchange.com",
"https://cs.stackexchange.com/users/17185/"
] | Given a graph $G = (V,E)$, assume that we have two disjoint vertex sets $N = \{n_1, n_2 ...\} \subset V$ and $P = \{p_1, p_2, ...\} \subset V$ such that $N \bigcup P \neq V$.
I want to find if there exists an edge subset such that $\{<n_i,p_l>, <n_j,p_l>, <n_k, p_l>\}$ i.e. three nodes from $N$ and o... | To find such triples of edges, partition the adjacency list $L_i$ of each node $p_i$ in $P$ into three sets: $P_i$, the set of neighbors in $P$, $N_i$, the set of neighbors in $N$, and $Q_i$, the set of neighbors in $V \setminus (N \cup P)$. If each vertex is labeled with which set it belongs to, then the partitioning ... | If you can find a single node in $V$ of degree $3$, you know that there exists the $N$ and $P$ for the edge subset you are looking for.
Finding every possible combination of triplets is slower than $O(n)$.
However checking the degree of each node in $V$ is $O(n)$.
So which is more efficient?
| https://cs.stackexchange.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.