text
stringlengths
1
1.11k
source
dict
tinyxml, nodelet, macos, rosmake, macos-lion boost::checked_delete( p ); ^ /opt/local/include/boost/smart_ptr/shared_ptr.hpp:183:44: note: in instantiation of function template specialization 'boost::detail::shared_count::shared_count<nodelet::NodeletListRequest_<std::allocator<void> > >' requested here explicit shared_ptr( Y * p ): px( p ), pn( p ) // Y must be complete ^ /Users/luca/Software/ros/electric/ros_comm/clients/cpp/roscpp/include/ros/service_callback_helper.h:70:10: note: in instantiation of function template specialization 'boost::shared_ptr<nodelet::NodeletListRequest_<std::allocator<void> > >::shared_ptr<nodelet::NodeletListRequest_<std::allocator<void> > >' requested here return boost::shared_ptr<M>(new M); ^
{ "domain": "robotics.stackexchange", "id": 7517, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "tinyxml, nodelet, macos, rosmake, macos-lion", "url": null }
entanglement, terminology-and-notation Bipartite mixed state: Let $\rho_{AB}$ be a mixed state on a composite system $A\cup B$. Then we say $\rho_{AB}$ is a bipartite mixed state on $\mathcal{H}_A\otimes\mathcal{H}_B$ and write $\rho_{AB}=\sum_{ij}p_{ij}\rho_{A}^i\otimes \rho_{B}^j$ where $\{\rho_A^i\}$ and $\{\rho_B^j\}$ are bases of density operators in $A$ and $B$ respectively. Note that if $\mathcal{H}_A$ has a basis of density operators $\{\rho_A^i\}$ and $\mathcal{H}_B$ has a basis of density operators $\{\rho_B^j\}$ then then $\{\rho_A^i\otimes \rho_B^j\}$ is automatically a basis for mixed states on $\mathcal{H}_A\otimes \mathcal{H}_B$.
{ "domain": "quantumcomputing.stackexchange", "id": 727, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "entanglement, terminology-and-notation", "url": null }
4. (5%) Multiple answer question. (It is possible that more than one of the choices are correct. Find out all correct choices.) A hash table of length 10 uses the hash function $h(k) = k \, mod \, 10$ and the linear probing for handling overflow. After inserting 6 values into an initially empty hash table, the table is as shown below. Which one(s) of the following choices gives a possible order in which the key values could have been inserted in the table? (A) 46, 42, 34, 52, 23, 33 (B) 34, 42, 23, 52, 33, 46 (C) 46, 34, 42, 23, 52, 33 (D) 42, 46, 33, 23, 34, 52 (E) 42, 23, 34, 46, 52, 33 5. (5%) Fill in the six black (I, II, …, and VI) in the following program that implements a queue by using 2 stacks.
{ "domain": "eecsmt.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9854964177527898, "lm_q1q2_score": 0.8712175423026254, "lm_q2_score": 0.884039278690883, "openwebmath_perplexity": 925.3434884990481, "openwebmath_score": 0.3205425441265106, "tags": null, "url": "https://eecsmt.com/graduate-school/exam/108-nthu-cs-ds/" }
quantum-mechanics, wavefunction, potential, schroedinger-equation, parity For some symmetry operations, "being an eigenstate of $\hat S$" can be a fairly complicated property that requires some analysis, such as e.g. when $\hat S$ is a rotation or a translation. (As an important note: when we deal with rotationally-invariant hamiltonians, we often have more than one symmetry operator ─ say, we might have three rotation generators $\hat S_1, \hat S_2, \hat S_3$ ─ where those operators don't commute with each other, which complicates things. In these cases, the language shifts over to group representation theory: you have a symmetry group, and you're guaranteed that each eigenspace is/carries a representation of that group. This is the case e.g. with rotations in three dimensions.)
{ "domain": "physics.stackexchange", "id": 60623, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, wavefunction, potential, schroedinger-equation, parity", "url": null }
observational-astronomy, space, big-bang-theory, movement Title: Why can't we determine the center of the universe I find this baffling. If we can observe objects moving away from us and each other, than it stands to reason that we can track their paths (relative to each other and ourselves) backward to find a point of origin. In this question answers given suggest that there is no center of the universe. I'm looking for clarification as to why we cannot reverse engineer (to some degree) where this point of origin exists, even if a simple general direction relative to us. I understand that paths may be distorted and skewed by forces as time goes on, but I still don't grasp the concept that we have no way to determine a point of origin or general sense thereof. Help wrapping my inferior brain around this is much appreciated. There is no point of origin! It is a misconception that the universe started as a single point within space. Indeed, measurements since the 1990s seem to show that the universe is infinite in size, which means that the
{ "domain": "astronomy.stackexchange", "id": 458, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "observational-astronomy, space, big-bang-theory, movement", "url": null }
electromagnetism, general-relativity, velocity During class, it has been said that if $E=0$, thus the equation is autonomous and also $|u^{\prime}|=a$ for some positive constant $a$. Could someone please explain me why that is true? Thank you. To start, I can't help but comment that using $u$ for position and $c$ for a speed that is not the speed of light is extremely confusing. But anyway, the reason is the same as in the classical equation: the acceleration is orthogonal to the velocity. In more detail, the left hand side of the equation is equal to $f(u') u''$, with some function $f(u')$. The time derivative of $|u'|^2$ is $2 u' \cdot u''$. If we take the Lorentz force equation and dot it with $u'$, the right hand side gives zero because of the cross product. We then get $f(u') u' \cdot u'' = 0$, so that $u' \cdot u'' = 0$ and the magnitude of $u'$ is constant.
{ "domain": "physics.stackexchange", "id": 93340, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "electromagnetism, general-relativity, velocity", "url": null }
cosmology $$\xi(r) = {1 \over 2\pi^2} \int dk\ k^2 P(k) {\sin(kr) \over kr}$$ They are (sort of) the Fourier transform of each other. It should not surprise, then, that a peak in one becomes a series of oscillations in the other. Just like the fourier transform of a sinusoidal wave is a dirac delta. Keep also in mind that the first figure in the question is not exactly the power spectrum. As indicated by the y-axis label, a baseline has been subtracted and it is showing only the oscillations over that baseline. The full power spectrum looks like this one:
{ "domain": "astronomy.stackexchange", "id": 5911, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "cosmology", "url": null }
moveit Can I use them side by side? Using the move-group-interface there I can just find the command group.setGoalTolerance(0.001), which sets both angle and position tolerance at the same time, I think Oh! No I was wrong! There is also group.setGoalOrientationTolerance(). But there I can't limit the tolerance to one angle around an axis, can I? The page I linked is a bit more low-level. The page you linked describes using moveit_msgs::OrientationConstraint, but as far as I know such a constraint will influence planning of the whole trajectory, not just the state at the end. The methods you mention don't seem to support what you want. From the moveit::planning_interface::MoveGroup::setGoalTolerance docs: Set the tolerance that is used for reaching the goal. For joint state goals, this will be distance for each joint, in the configuration space (radians or meters depending on joint type). For pose goals this will be the radius of a sphere where the end-effector must reach. [..]
{ "domain": "robotics.stackexchange", "id": 21627, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "moveit", "url": null }
complexity-theory, time-complexity, sorting, quicksort, radix-sort Your radix sort does an awful lot of copying, and worse, uncached copying. Your radix sort doesn't produce a correctly sorted result if digits is an odd number. Your qsort call doesn't produce a correctly sorted result if the array contains very large and very small numbers.
{ "domain": "cs.stackexchange", "id": 15986, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "complexity-theory, time-complexity, sorting, quicksort, radix-sort", "url": null }
acoustics, frequency, string, wavelength Title: How is length of string and frequency of sound related in musical instruments like guitar, violin etc? Also differentiate between note and tone I read a sentence that a guitarist set his strings before performance then he is changing frequency of sound. I was wondering in which case frequency will be more, if length of string is large or small. Also I am really confused between note and tone. First of all, let's clear up the terminology. Pitch means the same as frequency - it is the number of vibrations per second. If a tone contains several harmonics then "pitch" usually means its fundamental pitch.
{ "domain": "physics.stackexchange", "id": 83634, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "acoustics, frequency, string, wavelength", "url": null }
infinite-impulse-response, butterworth Title: While converting discrete filter specs into continuous filter specs, why do we multiply gain by T As I know so far that when we trying to design a DF(discrete filter) with specific specs "in terms of $\omega$", we take these specs and map it into continuous domain $H(j\Omega)$ using a certain method as "Impulse invariance" and design it by continuous design methods like "Butterworth". As impulse invariance method says: $$\omega = \Omega.T$$ and that part is fine to map $\omega_p(passband),\omega_s(stopband)$ But do we have to map also the gain of the filter? i.e. $\delta_1,\delta_2$ and multiply them by $T$ it is, in my biased opinion, because nearly every textbook with the sampling theorem puts the $T$ gain factor in the wrong place.
{ "domain": "dsp.stackexchange", "id": 4664, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "infinite-impulse-response, butterworth", "url": null }
quantum-mechanics, quantum-entanglement, measurements If I've read your question correctly, it seems that your confusion comes from believing that the measurement results of entangled particles must always be identical. Barring experimental error, this is only the case when the measurement bases, A and B, are identical. If A and B were both the standard basis, then there would be perfect correlation between the A measurements and the B measurements. If on the other hand, B is a basis like $\{ \vert + \rangle, \vert - \rangle \}$ where $\vert + \rangle = \frac{1}{\sqrt{2}}(\vert 0 \rangle + \vert 1 \rangle)$, and $\vert - \rangle = \frac{1}{\sqrt{2}}(\vert 0 \rangle - \vert 1 \rangle)$, then we only expect a 50% correlation between the results of A measurements on X and B measurements on Y.
{ "domain": "physics.stackexchange", "id": 1073, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, quantum-entanglement, measurements", "url": null }
Another way of saying this is that we can see that the distribution of d starts out pretty big, at max(x_i), and then dies really quickly, in fact exponentially quickly. I’d go with the plumped up version though if I were asked. I’ve so far avoided looking at references to think about this but I’d like to know how my “plumped up” version of max(x_i) relates to that distribution. It’s not the average value, for example, which is pretty easily computed to be log_{n+1}(2) max(x_i). Like • October 15, 2013 at 2:04 am Hi Cathy. Big fan of your blog. I think the approach you’ve taken is essentially the method of moments estimator (albeit the 1st moment of the max, a sufficient statistic, not the moment of the entire sample…). This underperforms the MLE in many cases, but in this case I think your approach is much more reasonable… though I can’t quite quantify why. Like • October 15, 2013 at 7:17 am
{ "domain": "mathbabe.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.986151386528394, "lm_q1q2_score": 0.8085389478465682, "lm_q2_score": 0.8198933337131076, "openwebmath_perplexity": 595.9504617279572, "openwebmath_score": 0.7527331709861755, "tags": null, "url": "https://mathbabe.org/2013/10/13/7673/?like_comment=38269&_wpnonce=4546503ca4" }
## Empty one year ago Prove the following: 1. Empty If n>1 and $$\phi(n)$$ is Euler's totient function, then $\phi(n) \equiv 1 \mod 2$ implies that $$n=2$$ 2. ganeshie8 Consider two cases : 1) If $$n$$ has a factor of odd prime, $$p$$, then $\phi(n)=\phi(p^km)=\phi(p^k)\phi(m)=(p-1)(p^k-1)\phi(m)\equiv 0\pmod{2}$ 2) if $$n$$ has no odd prime factors, then $\phi(n)=\phi(2^k)=2^k-2^{k-1}=2^{k-1}\equiv 0\pmod{2} ~~\text{for k} \gt 1$ 3. ganeshie8 that proves the contrapositive : $$n\ne 2 \implies \phi(n)\not\equiv 1\pmod{2}$$ 4. Empty Interesting! I had come up with this problem through a slightly different way so it was nice to see that this could be proven this way! Thanks! 5. ganeshie8 May I know your different way... There is an interesting alternative proof using below property of $$\phi$$ function : $\large \sum\limits_{1\le k\lt n, ~\gcd(n,k)=1}~k~ = ~\frac{1}{2}n\phi(n)$ 6. Empty
{ "domain": "openstudy.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9780517430863701, "lm_q1q2_score": 0.8233490494316819, "lm_q2_score": 0.8418256551882382, "openwebmath_perplexity": 344.43165424136487, "openwebmath_score": 0.9242546558380127, "tags": null, "url": "http://openstudy.com/updates/55c967d6e4b0016bb015bfcf" }
neural-network, recommender-system, cosine-distance Title: Item-to-Item recommendation using DNN I am new to DNN still learning, have a need to build item-to-item content based recommendation using DNN. For example, say I have a column of strings where each row represents a document I need to compute the cosine similarity of this column and recommend similar documents. id document 1 "hi this document is about science" 2 "hi this document is about wars" 3 "This document is about peace"
{ "domain": "datascience.stackexchange", "id": 8477, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "neural-network, recommender-system, cosine-distance", "url": null }
models, approximations Also, why don't we see a bright sky at "night"? Because of physics (universe expansion, etc). My question is, how can we depend on mathematics 100% in physics if it leads to obstacles like these? Instead, if we took it with a large grain of salt, it could work. Mathematics is just a systematic way of stating facts about the world. It is only useful inasmuch as it is internally self-consistent. The latter fact means that there is nothing to "assume" about mathematics. It is a relationship between axioms and conclusions that enables one to succinctly summarize many observations.
{ "domain": "physics.stackexchange", "id": 9758, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "models, approximations", "url": null }
Then, for problem 1: let $\beta = a$ Then using the property that $\hat{f} = F$ and $\hat{F} = f$, we can note: the fourier transform of the above is merely $\frac{1}{x^2 + a^2} \ times \frac{2a}{\sqrt{2\pi}}$. The above property then implies that some multiple of the function $e^{-a|k|}$ is our desired function for the fourier transform, specifically: $g(k) = \frac{\sqrt{2\pi}}{2a} e^{-a|k|}$ 's fourier transform, $\hat{g(x)} = \frac{\sqrt{2\pi}}{2a} \ times \frac{2\beta}{x^2 + a^2} \times \frac{1}{\sqrt{2\pi}} = \frac{1}{x^2 + a^2}$ as desired. For the second function's fourier transform: note that $g(x) = xf(x) \rightarrow \hat{g(k)} = i\hat{f'(k)}$ is a property, and that the second function is x times the previous problem's function. Thus, take the derivative of $\hat{f(k)}$ i.e. $\frac{d}{dk} ( e^{-a|k|}) = \frac{-ak e^{-a|k|}}{|k|}$ So then: the forward fourier transform is: $\frac{-i\sqrt{\pi}k e^{-a|k|}}{\sqrt{2}|k|}$ #### George Lu
{ "domain": "toronto.edu", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.975576911366069, "lm_q1q2_score": 0.8292122561519935, "lm_q2_score": 0.8499711775577736, "openwebmath_perplexity": 3067.0717559641243, "openwebmath_score": 0.9393656253814697, "tags": null, "url": "https://forum.math.toronto.edu/index.php?topic=1068.0" }
javascript, typescript, cache Really appreciate any feedback on how to improve. I took a look at it and will elaborate on my few findings below. First of all, your default export is wrong, but most likely you knew about it and you have already fixed it in your local version (might be also some pasting issue) - it's a no brainer. SimpleLocalStorageCache vs. CacheSimpleLocalStorageCache. Also I don't think it's necessary to export the interface CacheItem as it's most likely an internal interface to be used. Do not leak it, to prevent misuse :-) Next, looking at the constructor constructor(private key: string, private durationInSeconds: number) {} it's quite nice that you've used constructor assignment, thumbs up for that. What I think is a bit weird though, is the fact, that you've decided that the consumer of the API has to pass in seconds. That's a bit odd if we look at for example the parameters of setTimeout.
{ "domain": "codereview.stackexchange", "id": 39094, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "javascript, typescript, cache", "url": null }
turing-machines However, I don't think this method works very often in practice because it is more common for TMs to run off infinitely in one direction than to stay on a small section of tape.
{ "domain": "cstheory.stackexchange", "id": 2901, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "turing-machines", "url": null }
if the line touches the original function in more than one place it fails the horizontal line test, and the inverse of the function is not a function. Properties of a 1 -to- 1 Function: Is each input only paired with only one output? Let’s use highest order term analysis to find the horizontal asymptotes of the following functions. have the same y-value. The vertical Line test. B) Yes, it is a function because it passes the vertical line test. Put another way, on a perfectly horizontal line, all values on the line will have the same y-value. Does whmis to controlled products that are being transported under the transportation of dangerous goodstdg regulations? The horizontal line test for inverse functions states that a function f has an inverse that is a function, f Superscript negative 1 , if there is no horizontal line that intersects the graph of the function f at more than one point. R If no horizontal line intersects the graph of the function f in more than one point, then the
{ "domain": "talentelgia.com", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.956634196290671, "lm_q1q2_score": 0.8277029531588749, "lm_q2_score": 0.865224091265267, "openwebmath_perplexity": 317.87194996529325, "openwebmath_score": 0.6791102886199951, "tags": null, "url": "http://talentelgia.com/6wtp0/why-is-there-no-horizontal-line-test-for-functions-c66f7d" }
$$A\implies B$$: • If $$a$$ is not nilpotent, localize at the infinite multiplicative subset $$A \coloneqq\left\{{1, a, a^2, \cdots}\right\}$$ to obtain $$R \left[ { \scriptstyle { {A}^{-1}} } \right]$$. Since $$0\not\in A$$, this is not the zero ring. • By the universal property, there is a map $$\phi: R\to R \left[ { \scriptstyle { {A}^{-1}} } \right]$$, and the claim is that $$\phi(a)$$ is a unit in $$R \left[ { \scriptstyle { {A}^{-1}} } \right]$$. • More directly, $$\phi(a) = [a/1] \in \left\{{p,q {~\mathrel{\Big\vert}~}p\in R, q\in A}\right\}$$, which has inverse $$[a/1]$$. ### Spring 2021 #5 Suppose that $$f(x) \in ({\mathbb{Z}}/n{\mathbb{Z}})[x]$$ is a zero divisor. Show that there is a nonzero $$a\in {\mathbb{Z}}/n{\mathbb{Z}}$$ with $$af(x) = 0$$.
{ "domain": "dzackgarza.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9908743636887527, "lm_q1q2_score": 0.8030827774478073, "lm_q2_score": 0.8104789132480439, "openwebmath_perplexity": 362.4303021135475, "openwebmath_score": 0.9997151494026184, "tags": null, "url": "https://quals.dzackgarza.com/10_Algebra/TexDocs/QualAlgebra_stripped.html" }
object-oriented, design-patterns, vba Dim order As SqlResultRow Set order = NewOrderHeader(number:=orderNumber) Dim orderId As Long orderId = Repository.FindId(order) If orderId = 0 Then MsgBox StringFormat(GetResourceString("InvalidOrderNumberMessageText"), orderNumber), _ vbExclamation, _ GetResourceString("InvalidOrderNumberTitle") Exit Function End If ExecuteFindCommand = orderId End Function Private Property Let IPresenter_MasterId(ByVal value As Long) this.MasterId = value End Property Private Property Get IPresenter_MasterId() As Long IPresenter_MasterId = this.MasterId End Property Private Property Set IPresenter_Repository(ByVal value As IRepository) Set Repository = value End Property Private Property Get IPresenter_Repository() As IRepository Set IPresenter_Repository = Repository End Property Private Sub IPresenter_Show() 'not implemented End Sub
{ "domain": "codereview.stackexchange", "id": 9158, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "object-oriented, design-patterns, vba", "url": null }
wants to choose uniformly at random between the two activities. Explain your answer. Probability. For example, if you want to know the theoretical probability that a die will land on a number “3” when rolled, you must determine how many possible outcomes there are. The solutions given to the questions for the in between exercises and exercises given at the end of the chapter are prepared by our subject matter experts in a simple and lucid language. 12 HYPERGEOMETRIC DISTRIBUTION Examples: 1. It is our intention to place items related to this book at vii. Probability. Probability Density Functions Let's consider the temperature example again. ADVERTISEMENTS: After reading this article you will learn about the meaning and theories of probability. Here is a set of 14 GMAT probability questions, all in the Problem Solving style on the test, collected from a series of blog articles. Probability implies 'likelihood' or 'chance'. Then the probability of tossing a head or tail is 1/2.
{ "domain": "24-aktuell.de", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9850429103332288, "lm_q1q2_score": 0.8229871369414111, "lm_q2_score": 0.8354835391516132, "openwebmath_perplexity": 577.1692155592605, "openwebmath_score": 0.7442626357078552, "tags": null, "url": "http://rqck.24-aktuell.de/probability-examples-and-solutions.html" }
homework-and-exercises, newtonian-mechanics, kinematics, projectile, drag $t$ = Time $\tau$ = Time constant (defined by $\frac{m}{k}$ where $m$ is the mass of the ball and $k$ is a constant defined drag equation (i.e. $k = \frac{\rho AC_d}{2}$). (I got the above equations from this video, and the equations depend on linear air resistance. Please let me know if I should use quadratic air resistance instead). Now, for the project, I want to figure out a way to use the above equations to calculate the initial launch velocity needed to launch the ball given the X and Y displacement of the basket and the initial launch angle. I rearranged the above equations into the below equations to find the initial components: $$ v_{x0} = \frac{x}{\tau(1-e^\frac{-t}{\tau})} $$ $$ v_{y0} = \frac{y + v_tt}{\tau(1-e^\frac{-t}{\tau})}-v_t $$ So, can I use the above equations to solve for my initial velocity? I'm a bit worried that the equations don't fully define the parameters of my trajectory in order to solve for the initial launch velocity.
{ "domain": "physics.stackexchange", "id": 67656, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "homework-and-exercises, newtonian-mechanics, kinematics, projectile, drag", "url": null }
to find the least squares regression line equation, slope and Y-intercept values. least squares solution). Node 13 of 18 Node 13 of 18 The Mixed Integer Linear Programming Solver Tree level 1. Order fractions from least to greatest or from greatest to least. The computational burden is now shifted, and one needs to solve many small linear systems. I'd like to know how to solve the least squares non linear regression in java only by passing a matrix A and a vector b like in python. Heh--reduced QR left out the right half of Q. SOLVING DIFFERENTIAL EQUATIONS WITH LEAST SQUARE AND COLLOCATION METHODS by Katayoun Bodouhi Kazemi Dr. 00004849386 0. The Excel Solver can be easily configured to determine the coefficients and Y-intercept of the linear regression line that minimizes the sum of the squares of all residuals of each input equation. Certain types of word problems can be solved by quadratic equations. In this lesson, we will explore least-squares regression and show how this method
{ "domain": "agence-des-4-fontaines.fr", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9902915215128426, "lm_q1q2_score": 0.8603917800815063, "lm_q2_score": 0.8688267660487572, "openwebmath_perplexity": 651.6307704769378, "openwebmath_score": 0.4954856038093567, "tags": null, "url": "http://khhk.agence-des-4-fontaines.fr/least-squares-solver.html" }
distribution, mixtures of normals can capture. The commonly adopted Bayesian setup involves the conjugate prior, multivariate normal distribution for the regression coefficients and inverse Wishart specification for the covariance matrix. Bruce Schaalje, second edition, Wiley, 2008. dmvnorm gives the density and rmvnorm generates random deviates. Introduction to Normal Distribution Nathaniel E. Joint and Conditional Distributions, Stochastic Independence Aim of this section: ' Multidimensional random variables (random vectors) (joint and marginal distributions) ' Stochastic (in)dependence and conditional distribution ' Multivariate normal distribution (definition, properties) Literature:. There are several equivalent ways to define a multivariate normal, but perhaps the most succinct and elegant is this one, which I took from Wikipedia: "a random vector is said to be $$r$$-variate normally distributed if every linear combination of its $$r$$ components has a univariate normal
{ "domain": "heimambiente.de", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9843363549643401, "lm_q1q2_score": 0.8093106582622971, "lm_q2_score": 0.8221891370573388, "openwebmath_perplexity": 532.9972113997312, "openwebmath_score": 0.7368945479393005, "tags": null, "url": "http://aeoq.heimambiente.de/multivariate-normal-distribution.html" }
of Pascal 's triangle ( named after Blaise Pascal, a famous French Mathematician and )! Every adjacent pair of numbers and write the sum of the current cell the most interesting patterns. More general result, see the reference generate the nth row and exactly top of n... B ) What patterns do you notice in Pascal 's triangle can be created as follows in! Is found by adding two numbers which are residing in the Auvergne region of on! Number the rows starting with row n = 0 1 '' at the top row you. Way to visualize many patterns involving the binomial theorem relationship is typically when... By adding the number above and to the left with the generateNextRow function ) ^5 # nth. Is the sum of the Pascal triangle, each entry of a is. Nth row of Pascal 's triangle in pre-calculus classes many o… Pascal triangle. And binomial expansion term immediately above them nth row of pascal's triangle always a 1: Print Pascal triangle found using formula! ( 2x + y ) ^4 # some of the ways this can
{ "domain": "simplifiedfs.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9546474220263198, "lm_q1q2_score": 0.8674097376385066, "lm_q2_score": 0.9086179018818865, "openwebmath_perplexity": 1008.0969693486851, "openwebmath_score": 0.7812725305557251, "tags": null, "url": "http://simplifiedfs.com/qe75bncx/fa54ef-nth-row-of-pascal%27s-triangle" }
terminology Title: Verb for subtracting the mean? Is there a verb for removing the mean or DC component of a signal? I am trying to name a flag for doing just that. "Normalize" can mean many things, so I don't think that would be a good choice. I've heard this referred to as demeaning a signal, or applying a DC notch (or, in some more hardware-related domains, a DC block). More generally, it might be called just highpass filtering the signal to remove the DC component.
{ "domain": "dsp.stackexchange", "id": 6512, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "terminology", "url": null }
ros Original comments Comment by barrybear on 2012-12-08: Wow thanks! Thats alot of information provided :) However if I may ask, the laser_scan_matcher library is able to obtain input from not only the laser range scanner, but also wheel odometry, velocity model, etc but the hector_mapping only uses laser range scanner right? Comment by barrybear on 2012-12-08: So, does that mean I can just use either one of these libraries? And also, would a pan-tilt-unit be signifcant in obtaining more accurate results but also may cause complex programming for the sensor fusion? Comment by Ivan Dryanovski on 2012-12-08: laser_scan_matcher accepts these as inputs to help the scan matching, but doesn't fuse them in the filter sense. I believe hector_mapping accepts IMU. You can try either any laser / camera odometry package and see what performance you get. Comment by Ivan Dryanovski on 2012-12-08:
{ "domain": "robotics.stackexchange", "id": 12008, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros", "url": null }
Since the quadcopter is traversing a pre-defined circular trajectory of fixed radius, the position data is regular and hence, the value of approximate entropy is low. ## Input Arguments collapse all Uniformly sampled time-domain signal, specified as either a vector, array, or timetable. If `X` has multiple columns, `approximateEntropy` computes the approximate entropy by treating `X` as a multivariate signal. If `X` is specified as a row vector, `approximateEntropy` treats it as a univariate signal. Embedding dimension, specified as a scalar or vector. `dim` is equivalent to the '`Dimension`' name-value pair. Time delay, specified as a scalar or vector. `lag` is equivalent to the '`Lag`' name-value pair. ### Name-Value Arguments
{ "domain": "mathworks.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9896718456529513, "lm_q1q2_score": 0.818173387060986, "lm_q2_score": 0.8267117940706734, "openwebmath_perplexity": 1500.6804039491237, "openwebmath_score": 0.8486752510070801, "tags": null, "url": "https://es.mathworks.com/help/predmaint/ref/approximateentropy.html" }
optics, waves, electromagnetic-radiation, huygens-principle Title: Huygens principle: which are the sources? I have an extremely basic doubt about Huygens Principle: Every point on the wavefront may be considered a source of secondary spherical wavelets which spread out in the forward direction at the speed of light. The new wavefront is the tangential surface to all these secondary wavelets.
{ "domain": "physics.stackexchange", "id": 67609, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "optics, waves, electromagnetic-radiation, huygens-principle", "url": null }
matlab, snr Where x is original signal and E is error/noise signal I am confused which formula is correct/proper? Becuase if we use former formula we get different results and if we use latter formula we get different results Based upon answer of MR Dan, i have updated my question and also included the MATLAB code we saw in our Lab clc %clears all the text from the Command Window clear all %clear/delete the variables created in close all %delete all the figures whose handles are not f=100%signal frequecny Fs=200; %sampling frequency Ts=1/Fs n=4; %number of bits L=2.^n; %quantization levels t=0:Ts:0.1; %time interval x=cos(2.*pi.*f.*t); %Signal x(t) D=(max(x)-min(x))/(L-1); xq=quant(x,D); %quantization E=x-xq; %error calculation SQNR=10*log10(sum(x.^2)/sum(E.^2)) The given formula 6.02 db(per bit)+1.76 dB is specifically that for a full scale sine wave, meaning a sine wave as big as it can be just prior to clipping. Please see this post where I detail how that is derived.
{ "domain": "dsp.stackexchange", "id": 11828, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "matlab, snr", "url": null }
java, game, ai int skipX = (getWidth() - occupiedWidth) / 2; int skipY = (getHeight() - occupiedHeight) / 2; g.setColor(borderColor); // Draw horizontal borders. for (int y = 0; y <= verticalCells; ++y) { g.fillRect(skipX, skipY + y * (borderWidth + cellLength), horizontalCells * (borderWidth + cellLength) + borderWidth, borderWidth); } // Draw vertical borders. for (int x = 0; x <= horizontalCells; ++x) { g.fillRect(skipX + x * (borderWidth + cellLength), skipY, borderWidth, verticalCells * (borderWidth + cellLength) + borderWidth); }
{ "domain": "codereview.stackexchange", "id": 16086, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "java, game, ai", "url": null }
motors, rail An additional reason to reject such temperature sensors as the main basis for thermal protection, is the fact that the traditional Resistance Temperature Detector (RTD) has a relatively slow reaction time and can’t respond adequately to the high speed of the heating process during motor acceleration. Also, this model ensures greater transparency between motor manufacturer and stakeholder (as manufacturer supplies a family of characteristic curves for the motor): Another important part of thermal model implementation is “Expected values stored in Motor Protection Device”. This term implies that information is available from the motor designer and motor manufacturer, that is related to the thermal reserve, allowed performance and thermodynamics of the motor in question. This paper goes on to further discuss the terminology like thermal capacity used and allowed performance and is a great read if you want to build a model.
{ "domain": "engineering.stackexchange", "id": 3323, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "motors, rail", "url": null }
atomic-physics, quantum-electrodynamics, renormalization, half-life, lamb-shift Title: Why does Lamb shift renormalization not affect decay rate? As a preface, I know there are "more" correct ways to calculate the Lamb shift and decay rate through full blown QED, but this is what's most familiar with me, so I would appreciate an answer in this realm (without going to full QED and talking about poles etc.) When following the Wigner-Weisskopf method for spontaneous decay of a hydrogen atom, we assume an exponential ansatz. Using this method, we can find a real and imaginary exponent for the initial state lifetime. This represents the decay rate, and the Lamb shift. We get a finite lifetime, but the Lamb shift diverges. Typically at this point we say that the Lamb shift needs to be dealt with through renormalization, but are happy with the finite decay rate (which is apparently quite close to experiment).
{ "domain": "physics.stackexchange", "id": 98739, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "atomic-physics, quantum-electrodynamics, renormalization, half-life, lamb-shift", "url": null }
as the length of the opposite side divided by the length of the adjacent side. All equilateral triangles are acute triangles. Construct an acute angle triangle which has a base of 7 cm and base angles 65. It means that all the angles are less than 90 degrees, A triangle in which one angle measures 90 degrees and other two angles are less than 90 degrees (acute angles). Or more clearly formulated: sin(x) = opposite/hypothenuse; cos(x) = adjacent/hypothenuse; tan(x) = opposite/adjacent; Calculating an Angle in a Right Triangle CBSE Previous Year Question Papers Class 10, CBSE Previous Year Question Papers Class 12, NCERT Solutions Class 11 Business Studies, NCERT Solutions Class 12 Business Studies, NCERT Solutions Class 12 Accountancy Part 1, NCERT Solutions Class 12 Accountancy Part 2, NCERT Solutions For Class 6 Social Science, NCERT Solutions for Class 7 Social Science, NCERT Solutions for Class 8 Social Science, NCERT Solutions For Class 9 Social Science, NCERT Solutions For Class 9
{ "domain": "mediatorchrzanow.pl", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9759464513032269, "lm_q1q2_score": 0.837135739880428, "lm_q2_score": 0.8577681068080749, "openwebmath_perplexity": 483.28947291875033, "openwebmath_score": 0.4953753352165222, "tags": null, "url": "https://mediatorchrzanow.pl/baek-jong-pzlv/acute-angle-triangle-24f2f8" }
java, beginner, fractals Title: Chaos with Newton’s method The following is the program 3.2.6. from the book Computer Science An Interdisciplinary Approach by Sedgewick & Wayne: // This data type is the basis for writing Java programs that manipulate complex numbers. public class Complex { private final double re; private final double im;
{ "domain": "codereview.stackexchange", "id": 39439, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "java, beginner, fractals", "url": null }
of all exact numbers. The letter $$e$$ was first used to represent this number by the Swiss mathematician Leonhard Euler during the 1720s. 6.7.6 Prove properties of logarithms and exponential functions using integrals. $$A(\dfrac{1}{2})=P+(\dfrac{r}{2})P=P(1+(\dfrac{r}{2}))$$. Its domain is $$(0,∞)$$ and its range is $$(−∞,∞)$$. A quantity grows linearly over time if it increases by a fixed amount with each time interval. (adsbygoogle = window.adsbygoogle || []).push({}); © Copyright 2020 W3spoint.com. Suppose $$500$$ is invested in an account at an annual interest rate of $$r=5.5%$$, compounded continuously. (A(t)=750e^{0.04t}\). The polynomials, exponential function e x, and the trigonometric functions sine and cosine, are examples of entire functions. Logarithmic functions can help rescale large quantities and are particularly helpful for rewriting complicated expressions. Let $$t$$ denote the number of years after the initial investment and A(t) denote the amount of money in the
{ "domain": "unhcr.gr", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9728307716151472, "lm_q1q2_score": 0.8169190437220336, "lm_q2_score": 0.8397339676722393, "openwebmath_perplexity": 510.0705390698259, "openwebmath_score": 0.9006687998771667, "tags": null, "url": "http://donors.unhcr.gr/h96l64a/viewtopic.php?9b4489=limits-of-exponential-logarithmic-and-trigonometric-functions" }
python, beginner, python-3.x, pig-latin Title: Pig Latin Translator in Python I am a relatively new Python programmer and made a simple Pig Latin to English translator and vice versa. I would just like it if someone reviewed my code and see if anything can be done to make it more Pythonic or efficient. from time import sleep def main(): to_piglatin = input("Do you want to translate something to piglatin[P], or to english[E]: ") while to_piglatin not in("p", "e"): to_piglatin = input("[P/E]") to_piglatin = ("e", "p").index(to_piglatin.lower()) if to_piglatin: lang = "pig latin" else: lang = "english" question = "Enter a sentence to translate it into {}: ".format(lang) sentence = input(question) if not sentence.isalpha(): print("Invalid input, please do not use numbers or punctuation marks") sleep(1) main() split_sentence = sentence.split()
{ "domain": "codereview.stackexchange", "id": 19881, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, beginner, python-3.x, pig-latin", "url": null }
python, python-3.x, wrapper, device-driver return enabled_options etc. I don't know enough about the domain to comment towards correctness or if there is an easier way to handle these things, but in terms of readability and general Pythonicness, here is a full rewrite of things I would change. import ctypes import threading import time xinput = ctypes.windll.xinput1_3 class ControllerManager(): buttons = map("{}_button".format, ('y', 'x', 'b', 'a')) shoulders = map("{}_shoulder".format, ('right', 'left')) dpads = map("{}_bumper".format, ('right', 'left')) sticks = map("{}_stick".format, ('right', 'left')) bumpers = map("{}_bumper".format, ('right', 'left')) triggers = map("{}_trigger".format, ('right', 'left')) thumbs = map("thumb_{}".format, ('lx', 'ly', 'rx', 'ry')) variables = buttons + shoulders + dpads + sticks + bumpers + triggers + thumbs
{ "domain": "codereview.stackexchange", "id": 16747, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, wrapper, device-driver", "url": null }
c#, community-challenge, lexical-analysis } return stringBuilder.ToString(); } private void Unget() { if (EOF) { EOF = false; } else { if (CurrentPosition > 0) { CurrentPosition--; } else if (CurrentLineNumber > 0) { while (string.IsNullOrEmpty(Lines[--CurrentLineNumber])) ; CurrentPosition = Lines[CurrentLineNumber].Length - 1; } } } private void Unget(int count) { for (int i = 0; i < count; i++) { Unget(); } } } } TokenKind.cs using System; namespace Compiler.Lexer { // do not change token numbers public enum TokenKind : ushort { UnknownToken = 0,
{ "domain": "codereview.stackexchange", "id": 41081, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c#, community-challenge, lexical-analysis", "url": null }
of the two cases, let's take a portion of sequence A. If your device is not in landscape mode many of the equations will run off the side of your device (should be able to scroll to see them) and some of the menu items will be cut off due to the narrow screen width. Series 58:56; The Integral Test and Estimates of Sums 35:15; The Comparison Test 30:46; Alternating Series 30:52; Absolute Convergence and The Ratio and Root Tests 62:59; Power Series; Representations of Functions as Power Series 44:25; Taylor and Maclaurin Series 80:41. Basic Electronics Tutorials and Revision is a free online Electronics Tutorials Resource for Beginners and Beyond on all aspects of Basic Electronics. • In practice, it is a matter of extreme importance to be able to tell whether a given series is convergent. For example, For example, x = 42; if exist( 'myfunction. Here’s a list of recommended number series questions to train with. The alternating series test states that if fa ngis a positive decreasing
{ "domain": "citylinker.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9830850877244272, "lm_q1q2_score": 0.8234516931407722, "lm_q2_score": 0.837619961306541, "openwebmath_perplexity": 1062.0543476437563, "openwebmath_score": 0.7435677647590637, "tags": null, "url": "http://citylinker.it/tkiz/alternating-series-test-practice-problems.html" }
ros-kinetic And then you'd be using the keys described on the teleop_twist_keyboard page. If you really want to change the keys used in the turtle_teleop_key node from the tutorial, then the only way to do that would be to have a copy of the source code for the turtlesim package in your workspace, edit the source code, and then recompile. The keys used for driving the turtle are defined here, and they are processed in this case statement. If you wanted to use "wsad", you could change the top defines to be: #define KEYCODE_R 0x64 #define KEYCODE_L 0x61 #define KEYCODE_U 0x77 #define KEYCODE_D 0x73 #define KEYCODE_Q 0x71 To read more about why, in the original code, the arrow keys are the specific values they are (e.g. Right=0x43), you could read the following: https://stackoverflow.com/a/11432632/1082525 https://en.wikipedia.org/wiki/ANSI_escape_code https://viewsourcecode.org/snaptoken/kilo/02.enteringRawMode.html
{ "domain": "robotics.stackexchange", "id": 30167, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros-kinetic", "url": null }
8. Jul 18, 2009 ### mXSCNT Well, suppose that the x's are {1, 2}, and the y's are {101, 102}. If x and y were taken from populations with different means, then you'd expect the variance of those populations to be quite small (since x and y each have variances of only 1/2). On the other hand if x and y were taken from populations with the same mean, then you'd expect the variance of that population to be comparatively large, since x and y are separated by about 100 units.
{ "domain": "physicsforums.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9890130599601177, "lm_q1q2_score": 0.8241689018087119, "lm_q2_score": 0.8333245891029456, "openwebmath_perplexity": 525.4828280426759, "openwebmath_score": 0.9245573878288269, "tags": null, "url": "https://www.physicsforums.com/threads/variance-of-the-union-of-two-samples.325534/" }
machine-learning, deep-learning Title: The Bias-Variance Trade-Off I'm reading "An Introduction to Statistical Learning: With Applications in R". In the Paragraph 2.2.2 The Bias-Variance Trade-Off, the authors say: I'm not able to understand why the bias tends to initially decrease faster than the variance increases. Can you help me ? Both rigorous and intuitive explanations are greatly appreciated One way to look at this is through the idea of under-/overfitting First off, here is a sketch of the generally observed relationship between bias and variance, in the context of model size/comlpexity:
{ "domain": "datascience.stackexchange", "id": 3377, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "machine-learning, deep-learning", "url": null }
waves, boundary-conditions The profile of the wave in the time domain (displacement vs time at a fixed point on the string) remains the same along the string, even when in regions where wave speed is different. The time delay between any two reference points on the wave passing a fixed point on the string is the same at all points along the string. The 2 reference points cross the boundary and enter the slower region separated by the same time delay, so they retain the same separation in the slower region. Hence the pulse duration is the same in the slower region. However, in the space domain (displacement vs distance along the string at a fixed instant in time), which is used in the diagram in your question, the length of the wave can change. The wave-length and speed change in proportion, the constant of proportionality being the duration of the wave.
{ "domain": "physics.stackexchange", "id": 47183, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "waves, boundary-conditions", "url": null }
quantum-mechanics, locality, epr-experiment I was wondering how the local variable system, by defining two random variables $A(a, \lambda)$ and $B(b, \lambda)$ on a probability space $(\Lambda, p(\lambda))$ denoting the values taken by the measurements $A$ and $B$. Rectify the above paradox. The idea that you could explain QM by local hidden variables was eventually proven false by Bell's theorem, but I wanted to understand why this was the attempt to complete QM with respect to this example in the first place. If we have local hidden variables, then there's no real "collapse". When the particles were created, they had definite "plans" for what they would do if they encountered a detector aligned along any conceivable axis. What we call a "singlet state" is just a conspiracy that the two particles entered into when they were created, comparing each other's "plans" and making sure that if particle A came out of a detector spin-up, then particle B would come out of the same kind of detector spin-down.
{ "domain": "physics.stackexchange", "id": 83906, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, locality, epr-experiment", "url": null }
gazebo-1.0 Title: Multithreading gzserver Is it possible to run gzserver over multiple cores does gzserver incorporate multithreading? When running gzserver all the physics and plugin modelling is really only run over a single core, my computer has 4 cores and 8 threads and I was wondering if it were possible to run gzserver across more than one core inorder to get better performance. If gzclient is run a the same time, it spreads itself over the remaining cores, but for my application the gui is not really that important. when running htop with gazebo running the gzserver runs over two threads, utilising one at 114% and the other at 98% but still only getting a real time factor of 0.08 Any suggestions?
{ "domain": "robotics.stackexchange", "id": 2888, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "gazebo-1.0", "url": null }
strings, f#, palindrome, dynamic-programming while i >= 0 && j >= 0 do let NW = SafeIndex c (i - 1) (j - 1) let N = SafeIndex c (i - 1) j let W = SafeIndex c i (j - 1) if N > NW && i > 0 then i <- i - 1 else if W > NW && j > 0 then j <- j - 1 else if NW < c.[i, j] then mylcs <- x.[i].ToString() + mylcs i <- i - 1 j <- j - 1 else i <- i - 1 j <- j - 1 mylcs //Longest Common Subsequence, dynamic programming //x and y are sequences over a given alphabet //c is a 2d array, where c.[i, j] is the length of the longest // common subsequence between x.[0] .. x.[i] and y.[0] .. y.[j] let LCS (x: string) (y: string) = let c = Array2D.init x.Length y.Length (fun i j -> 0)
{ "domain": "codereview.stackexchange", "id": 10110, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "strings, f#, palindrome, dynamic-programming", "url": null }
javascript, node.js, angular.js Pinboardservice.deleteBookmark(bookmarkItem.data.href) .then(function(result) { if(result.result_code === 'done') { console.log('delete request completed.'); Utilservice.removeItemFromCollection('hash', bookmarkItem.data.hash, $scope.data.items); Appstatusservice.updateStatus('deleted bookmark, hash: ' + bookmarkItem.data.hash + '.'); } else { responseFailed(result); } }, function(reason) { responseFailed(reason); }); };
{ "domain": "codereview.stackexchange", "id": 10602, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "javascript, node.js, angular.js", "url": null }
Let $a/b\in K$, $a\in D$ and $0\neq b\in D$, hence $a,b\in F$, it follow that $a$ and $1/b$ are in $F$ so $a. (1/b)=a/b\in F$. Thus $K\subseteq F$. • Is your extension of $f$ well defined? – layman Oct 11 '14 at 19:26 • I guess it is since $f$ is a homomorphism, and if $a/b = c/d$, then $ad = bc$, so $f(a)f(d) = f(b)f(c)$ which implies $f(a)/f(b) = f(c)/f(d)$. – layman Oct 11 '14 at 19:28 • Yes $b\neq 0$ implies $f(b)\neq 0$ because $f(0)=0\neq f(b)$ ($f$ is injective). – Hamou Oct 11 '14 at 19:28 • I guess I would need to do a little bit more work because I would need to show the image of the field $F$ under the extension of $f$ is a field. – layman Oct 11 '14 at 19:29 • When $\frac ab\neq 0$, $\tilde f(a/b)\tilde f(b/a)=1$, hence $\tilde f(a/b)$ is invertible is in $\tilde f(F)$. – Hamou Oct 11 '14 at 19:32
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9719924769600771, "lm_q1q2_score": 0.8638668668346455, "lm_q2_score": 0.8887587993853654, "openwebmath_perplexity": 110.9001599027239, "openwebmath_score": 0.9469299912452698, "tags": null, "url": "https://math.stackexchange.com/questions/968206/prove-the-fractional-field-of-an-integral-domain-is-the-smallest-field-containin" }
• Assuming $a<b,$ since $[a,b]$ is uncountable there is no bounded sequence with that range. – coffeemath Oct 4 '20 at 16:01 • Apologies, it did not occur to me that this is not possible, do you happen to have a link that could elaborate on that a bit more or if you could outline the reason why such a bounded sequence does not exist, thank you! – sunnydk Oct 4 '20 at 16:06 • A sequence $\{X_n\}$ has a finite or countably infinite range because that range can be covered by the real numbers $X_1,X_2,\cdots .$ So it cannot be all of $[a,b]$ assuming $a<b,$ since the latter is not countable. (one doesn't need boundedness for this argument) – coffeemath Oct 4 '20 at 16:41
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9759464450067471, "lm_q1q2_score": 0.8068264323016564, "lm_q2_score": 0.8267117898012104, "openwebmath_perplexity": 121.50568795235304, "openwebmath_score": 0.980423629283905, "tags": null, "url": "https://math.stackexchange.com/questions/3851364/find-the-set-of-sub-sequential-limits-of-a-bounded-sequence-with-infinite-range" }
Find all polynomial $P$ that $$P(Q(x))=Q(P(x))$$ or $$P \circ Q = Q \circ P$$ therefore $$P \circ Q^n = Q^n \circ P$$ and @Hurkyl showed that all $$P=Q^n$$ are solutions I checked for $degree(P)$ from $0$ to $16$ that there are only the following polynomials: $$-\frac{\sqrt{3}i-1}{2} \\ \frac{\sqrt{3}i+1}{2} \\ x \\ x^2+1 \\ x^4+2x^2+2 \\ x^8+4x^6+8x^4+8x^2+5 \\ x^{16}+8x^{14}+32x^{12}+80x^{10}+138x^8+168x^6+144x^4+80x^2+26 \\$$ Besides the constatn solutions the only solutions that exists where the solutions @Hurkyl found. Let $P$ be a polynomial that fullfills the equation $P * Q = Q *P$. We showed that $a_0$=0 if $degree(P)$ is odd. Therefore $P(0) =0$ and also $$P(Q^n(0))=Q^n(P(0))=Q^n(0)$$ So $Q^n(0), n=0,1,2,3,\ldots$ is a strictly increasing and therefore infinite sequence with $P(x)=x$ and therefore $P(x)-x=0$. But if a polynomial $P(x)-x$ is $0$ for
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9711290955604489, "lm_q1q2_score": 0.8050065993040729, "lm_q2_score": 0.8289388125473628, "openwebmath_perplexity": 226.1756979719164, "openwebmath_score": 0.9598512053489685, "tags": null, "url": "http://math.stackexchange.com/questions/271337/find-all-polynomials-p-such-that-px21-px21/271396" }
c#, json Title: Web Request Utility Our company consumes a lot of telemetered data from sensors which we consume via an API. So I wrote a method to consume them a bit easier for internal applications. I didn't add a generic to the method, mostly because JSON.NET didn't always build the object correctly. I'd like to remedy that in the future, but as it stands: public object DownloadFromApi(string url) { if (WebRequest.Create(url) is HttpWebRequest request) { request.Method = "GET"; request.ContentType = "application/json";
{ "domain": "codereview.stackexchange", "id": 30318, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c#, json", "url": null }
homework-and-exercises, energy, potential, orbital-motion, satellites Since the small force was in the direction of the velocity, an increase in veloctiy should result in a DECREASE in the radius meaning that the new orbit is closer in according to this equation. Why is it that the first equation is correct to use, while the second one is wrong? Why is the second equation not working here? Thanks! Others correctly state that the trajectory is no longer circular. Your second equation $$v^2=\frac{GMm}{r}$$ was probably derived from uniform circular motion: $$\frac{mv^2}{r}=\frac{GMm}{r^2}.$$ If motion is not circular (as is the case), the above equation will not hold. As for your first equation, the more general form is $$E_T=-\frac{GMm}{2a},$$ where $a$ is the semi-major axis. For circular orbits, $a=r$ (the radius of the orbit). Your previous reasoning still works here: the total energy of this two-body system arguably increases, $a$ must increase as well since an increase in $a$ would correspond to an energy closer to zero; that is, higher than before.
{ "domain": "physics.stackexchange", "id": 10151, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "homework-and-exercises, energy, potential, orbital-motion, satellites", "url": null }
quantum-mechanics, homework-and-exercises, quantum-spin, quantum-entanglement, spinors Magnetic Field What are the terms for the influence of the magnetic field. Well that's an easy one: in the ordering we have studied above, the uncoupled Hamiltonian will be: $$\hat{H} = \gamma_{\frac{1}{2}}\left(\sigma_x\,B_x + \sigma_y\,B_y+ \sigma_z\,B_z\right)\otimes 1_{3\times3} + \gamma_1\,I_{2\times2}\otimes\left(S_x\,B_x + S_y\,B_y+ S_z\,B_z\right)$$ where $\gamma_{\frac{1}{2}}$ and $\gamma_1$ are the respective gyromagnetic ratios.
{ "domain": "physics.stackexchange", "id": 21186, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, homework-and-exercises, quantum-spin, quantum-entanglement, spinors", "url": null }
logic, notation Title: Question on interpreting logical notation, relating to alphabets, theoretical comp sci $\exists x \in \Sigma^* (t=sx)$ Have I interpreted the above into words correctly?: "There exists a symbol 'x', which is a member of the set which contains all possible strings of alphabet sigma, where sigma contains string 't', which is a concatenation of string x and string s." I'm not clear on how/whether t=xs is an alphabet. Note: an earlier version of this question, with some errors, was posted at Math.SE. Since $t$ and $s$ aren't quantified, the expression $\exists x\in\Sigma^*\;(t=sx)$ is a predicate $P(s, t)$ in inputs $t$, and $s$. In other words, we could write $$ P(s, t)\stackrel{\text{def}}{\equiv}\exists x\in\Sigma^*\;(t=sx) $$
{ "domain": "cs.stackexchange", "id": 6051, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "logic, notation", "url": null }
gazebo, urdf, ros-kinetic <!-- these are the arguments you can pass this launch file, for example paused:=true --> <arg name="paused" default="false"/> <arg name="use_sim_time" default="true"/> <arg name="gui" default="true"/> <arg name="headless" default="false"/> <arg name="debug" default="false"/> <!--arg name="model" default="$(find bender_model)/model.urdf.xacro"/--> <!-- Robot pose --> <arg name="x" default="0.1"/> <arg name="y" default="0.5"/> <arg name="z" default="0"/> <arg name="roll" default="0"/> <arg name="pitch" default="0"/> <arg name="yaw" default="0"/>
{ "domain": "robotics.stackexchange", "id": 30407, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "gazebo, urdf, ros-kinetic", "url": null }
volcanology, geochemistry, volcanoes, petrology Title: Why would magma have high amounts of nickel and chromium? I am doing a research project on Mount Lamington and through my research I have found that its magma has unusually high amounts of chronium and nickel. What would cause this to happen? Is there science behind it, or is it unexplained? The current thinking according to modelling and previous observations is that the high amounts of $\ce{MgO}$, $\ce{Cr}$ and $\ce{Ni}$ is due to the magma feeding the Mt. Lamington volcano being contaminated by the nearby Papuan Ultramafic Belt (Smith, 2014; Arculus et al. 1983). The Papuan Ultramafic Belt is, according to Lus et al. (2001), a early Neogene (Tertiary) ophiolite. The region itself is not associated with an active Wadati-Benioff Zone (Smith, 2004).
{ "domain": "earthscience.stackexchange", "id": 310, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "volcanology, geochemistry, volcanoes, petrology", "url": null }
c#, strings, parsing public bool Matches(ControlString controlString) { return Matchers.Matches(controlString); } public string Match(ControlString controlString) { if (!Matches(controlString)) { throw new ArgumentException("Argument cannot be matched by this matcher.", "controlString"); } return Matchers.Match(controlString); } } Here, ValueControlStringMatcher is a simple combination of a ContextControlStringMatcher and a FuncControlStringMatcher for ease of use. At a quick glance the ControlStringFinder.FindAllControlStrings() method would benefit from the usage of the String.IndexOf(char, int) method. public IEnumerable<ControlString> FindAllControlStrings(string input) { for (var i = 0; i < input.Length; i++) { if (input[i] == controlStringStarter) { var end = input.IndexOf(controlStringTerminator, i + 1);
{ "domain": "codereview.stackexchange", "id": 13298, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c#, strings, parsing", "url": null }
image-processing, computer-vision, thresholding 7. Question: What is a "within class variance" and a "between class variance" in plain English? I can see the formula, but it makes no sense. Is the within class variance just a way of saying "how much the dark pixels vary with respect to mid-darkest pixel plus how much the light pixels vary with respect to the mid-lightest pixel"? 8. Question: What is a "between class variance" in plain English? The formula itself is odd, because there is no variance, but just a sum of the wights and means. But still, what does it mean in plain English, in terms of the pixels?
{ "domain": "dsp.stackexchange", "id": 5493, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "image-processing, computer-vision, thresholding", "url": null }
root calculator below to find the square root of negative... Just like your shadow in the next section, we place a negative number simplifying square... And any negative number as the square root of a negative number methods we have shown here to simplify roots. We write \ ( \sqrt { −25 } \ ) for the radical sign is how to simplify the root... Next section, we place a negative number is not a real number for all values a. Methods we have shown here to simplify each one n is an inverse of! Positive square root by the smallest prime number possible with our negative numbers as numbers! The radical sign, because both are alike under the Algebra II Math Mission root is an inverse of. Is called the degree of the root is how to simplify them each square chart. Below to find the negative square root also positive ( s ) addition! Simplify √12 two important rules to rewrite the square root of complex numbers the negative square of. Front of the radical sign indicates the positive one number
{ "domain": "com.br", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9637799441350252, "lm_q1q2_score": 0.8210950293208885, "lm_q2_score": 0.8519528076067262, "openwebmath_perplexity": 636.2207573290367, "openwebmath_score": 0.8082594871520996, "tags": null, "url": "http://vinds.com.br/bb9td/simplify-roots-of-negative-numbers-1d2647" }
Hint: For your first question, write down $\phi(a)$ and $\phi(b)$ (go ahead, write down the matrices on a sheet of paper). Now, if those two are equal, what does it tell you? The other parts are obviously different, but the idea is the same: just look at the matrices involved and use what you know about matrix multiplication (for the last part). • Thank you. I understand one-to-one after writing out the steps. I'm struggling with onto. Let me make sure I'm thinking correctly. I'm trying to find $\phi(?)=n$. Is there a different way? I'm not able to see what I'm supposed to do. – maidel b Oct 23 '15 at 17:50 • @ShayAbbott No. You want to take an arbitrary $g\in G$ and find an $n\in Z$ so that $\phi(n)=g$. But if $g\in G$, then you know what $g$ looks like... – Teepeemm Oct 23 '15 at 18:09
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.976310532836284, "lm_q1q2_score": 0.8692036231816407, "lm_q2_score": 0.8902942188450159, "openwebmath_perplexity": 211.27958985589848, "openwebmath_score": 0.9290165901184082, "tags": null, "url": "https://math.stackexchange.com/questions/1493945/matrix-group-isomorphic-to-mathbb-z" }
general-relativity, special-relativity, reference-frames, metric-tensor $$g_{\mu\nu}=e_{\mu}^{a}e_{\nu}^{b}\eta_{ab}$$ In the latter two equations the distinction between lorentzian indices and coordinate ones (Latin and Greek respectively as is standard) seems to be null as far as the Two Minkowski metrics are concerned. (They would be numerically identical for any given coordinate system). This seems to imply that: $$e_{\mu}^{a}e_{\nu}^{b}=\Omega^{2}(x^{i})$$ However; that doesn't seem right since we need a scalar unless we write it as: $$e_{\mu}^{a}e_{a}^{\mu}=e_{\mu}^{a}(e_{\mu}^{a})^{T}=\Omega^{2}$$ where we've disregarded indices and there seems to be a natural requirement that all other terms would be vanish.
{ "domain": "physics.stackexchange", "id": 47189, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "general-relativity, special-relativity, reference-frames, metric-tensor", "url": null }
time-dilation Title: Time dilation (special and general relativity) In special relativity we get a time dilation for high velocities near by c and in general relativity we get also a time dilation near by strong gravity fields. But what about a combination of these two effects? So if a object has a high velocity and is in a strong gravity field, would the effect of time dilation higher or will the effects cancle each other? Both effects operate independently. A good example is the GPS signal. The GPS clocks need to be accurate to within $30ns$ to achieve the required positioning accuracy. However, GPS satellites orbit the earth; in other words they go fast, and at high altitude. Their speeds slows down time, and the reduced gravity makes it flow faster. Hence there are 2 adjustments that need to be made. Their speed (almost $14,000km/h$)implies the clocks will be slow by about $7\mu$$s$ Because of their altitude (about $20,000km$), their clocks will run fast by about $45\mu$$s$ per day.
{ "domain": "physics.stackexchange", "id": 26095, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "time-dilation", "url": null }
python, python-3.x, regex What does it do? Well, it appears to be used to extract the first matching pattern as the "key" for each name in the list. So let's write a function for this: def extract_key(name): """ Extract unique pattern from a scaffold name. Apparently, patterns are just the first three characters, so don't use regexes, just grab the substring. """ return name[:3] Use the standard library You have a separate function that pulls out the keys (unique patterns) from the names, and returns a uniquified list of them, which you apparently use only to initialize the keys of a dictionary. Instead of doing that, just use collections.defaultdict to create a dictionary that starts with empty lists: import collections groups = collections.defaultdict(list)
{ "domain": "codereview.stackexchange", "id": 35906, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, regex", "url": null }
- Draw a graph of $$f(x) = |x|$$ Then ask yourself, how does one obtain $$g(x) = |x-2|$$ from the graph of $f(x)$. Once you figure out how the graph looks, the question that you asked is simply asking to find all the possible $x$ values such that $g(x) < 1$. You can draw a horizontal line $y=1$ on the graph of $g(x)$ and observe the $x$ values that satisfy. $|x-2| < 1\iff-1<x-2<1\iff2-1<2+x-2<2+1\iff1<x<3$
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9796676508127574, "lm_q1q2_score": 0.8751463168433056, "lm_q2_score": 0.8933093954028816, "openwebmath_perplexity": 183.16324154476547, "openwebmath_score": 0.9113469123840332, "tags": null, "url": "http://math.stackexchange.com/questions/442173/what-does-x-2-1-mean" }
php, classes, database /** * @return bool */ public function isConnected() { return ($this->db instanceof PDO); } /** * @ return PDO */ final protected function getConnection() { if ($this->db === null) {//connect last-minute $this->db = new PDO( $this->dsn, $this->user, $this->pass, $this->attributes ); } return $this->db; } } //usage $inst = new MyDB('...', 'usr', 'pass'); var_dump($inst->isConnected());//false $stmt = $inst->getStatement('SELECT foo, bar, FROM db.tbl WHERE id = :id'); var_dump($inst->isConnected());//true //re-using a prepared statement: $ids = [123, 4556]; $found = []; foreach ($ids as $id) { $stmt->execute([':id' => $id]); $found[] = $stmt->fetch(PDO::FETCH_OBJ); $stmt->closeCursor(); }
{ "domain": "codereview.stackexchange", "id": 9952, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "php, classes, database", "url": null }
ros, ros-melodic, hardware-interface Title: While rotating in place diff-drive-rotation package is losing orientation Dear Ros Community, I implemented diff-drive-controller package for my custom robot. I tested the generated odometry information while moving back and forward which works perfectly. However, while my robot is turning in place with a zero linear velocity and an angular velocity of 0.21, the generated odometry value moves faster than my robot. For example, when I rotate into 45 degree, my robot model rotates into 90 degree. I believe it is about slippage and there should be a slippage coefficient but I couldn't find something like that in the documentations. How does diff drive controller deals with in place rotations? What should I do for my robot? Originally posted by wallybeam on ROS Answers with karma: 57 on 2020-07-24 Post score: 0 It seems there isn't a slippage value. My problem solved when I change the wheel_seperate distance. It was smaller than the real value. Thank you for this amazing package.
{ "domain": "robotics.stackexchange", "id": 35321, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros, ros-melodic, hardware-interface", "url": null }
Sobre o autor
{ "domain": "quali-a.com", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9693241929723293, "lm_q1q2_score": 0.8455874213852973, "lm_q2_score": 0.8723473813156294, "openwebmath_perplexity": 328.20553820293884, "openwebmath_score": 0.8399621844291687, "tags": null, "url": "https://quali-a.com/4tltokh/20zft.php?af6199=is-zero-a-rational-number" }
telescope, optics, infrared, interferometry You can read more about it in: JWST's NIRISS Aperture Masking Interferometry ArXiv NIRISS aperture masking interferometry: an overview of science opportunities The JAM Team's: Non-Redundant Aperture Masking Interferometry (AMI) and Segment Phasing with JWST-NIRISS Below: MeerKAT array core from Google Maps at (30.7136109S, 21.4399576E).
{ "domain": "astronomy.stackexchange", "id": 2645, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "telescope, optics, infrared, interferometry", "url": null }
python, pygame, mathematics Now when the player moves the screen, the mouse is offset from the rest of the world and doesn't place the blocks to a 32x32 grid relative to the rest of the blocks.. so.. how can I fix this? Here is the whole code: import pygame,random from collections import namedtuple from pygame.locals import * pygame.init() pygame.display.set_caption('PiBlocks 0.1| By Sam Tubb') screen=pygame.display.set_mode((640,480)) instancelist=[] players=[] clock=pygame.time.Clock() texdir='org_texture' Move = namedtuple('Move', ['up', 'left', 'right']) ingame=0 max_gravity = 100 #load sprites grass=pygame.image.load(texdir+'\\grass.png').convert() dirt=pygame.image.load(texdir+'\\dirt.png').convert() stone=pygame.image.load(texdir+'\\stone.png').convert() psprite=pygame.image.load(texdir+'\\player.png').convert() curs=pygame.image.load(texdir+'\\cursor.png').convert() curs.set_colorkey((0,255,0)) cursrect=curs.get_rect(x=32,y=32) blocksel=dirt
{ "domain": "codereview.stackexchange", "id": 4727, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, pygame, mathematics", "url": null }
infinite-impulse-response Use floating point whenever possible. Fixed point IIR requires very careful analysis and application specific implementation. Whether optimization is worth it really depends on the application. Requirements can be all over the place: precision, speed, memory, mips, ease of us, stability against outlier condition, etc.
{ "domain": "dsp.stackexchange", "id": 4148, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "infinite-impulse-response", "url": null }
### Generalized mean inequality In general, if p < q, then ${\displaystyle M_{p}(x_{1},\dots ,x_{n})\leq M_{q}(x_{1},\dots ,x_{n})}$ and the two means are equal if and only if x1 = x2 = ... = xn. The inequality is true for real values of p and q, as well as positive and negative infinity values. It follows from the fact that, for all real p, ${\displaystyle {\frac {\partial }{\partial p}}M_{p}(x_{1},\dots ,x_{n})\geq 0}$ which can be proved using Jensen's inequality. In particular, for p in {−1, 0, 1}, the generalized mean inequality implies the Pythagorean means inequality as well as the inequality of arithmetic and geometric means. ## Proof of power means inequality We will prove weighted power means inequality, for the purpose of the proof we will assume the following without loss of generality: {\displaystyle {\begin{aligned}w_{i}\in [0,1]\\\sum _{i=1}^{n}w_{i}=1\end{aligned}}} Proof for unweighted power means is easily obtained by substituting wi = 1/n.
{ "domain": "orange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9944450749670488, "lm_q1q2_score": 0.8083519030793342, "lm_q2_score": 0.8128673201042493, "openwebmath_perplexity": 811.6538144172787, "openwebmath_score": 0.9486809968948364, "tags": null, "url": "https://zims-en.kiwix.campusafrica.gos.orange.com/wikipedia_en_all_nopic/A/Generalized_mean" }
homework-and-exercises, classical-mechanics Title: Trajectory of two joined points I'm wondering how could I calculate the trajectory of two joined points with some weight (let's say they are joined in the way they are forced to be always at the same distance) if there exerts a constant force in the perpendicular angle to the line between the two points in one of the points. So as these points move and rotate, the force F moves and rotates with them. Let's assume the two masses are equal. You must first solve for the rotation in the referential of the center of mass. $$F. \frac{L}{2}=I \frac{d \omega }{dt} $$ From which you get the angular velocity and angle: $$ \omega (t)= \frac{F.L}{2I}t $$ and the angle: $$ \theta (t)=\frac{F.L}{4I}t^{2}$$ Now you have to calculate the trajectory of the center of mass. The force $ \overrightarrow{F}$ is time dependent because of the rotation. $$ \overrightarrow{F} = \begin{cases}F.cos \big( \theta (t)+ \frac{ \pi }{2} \big) \\F.sin\big( \theta (t)+ \frac{ \pi }{2} \big)\end{cases}$$
{ "domain": "physics.stackexchange", "id": 90084, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "homework-and-exercises, classical-mechanics", "url": null }
ds.algorithms, time-complexity, matrices, nt.number-theory, gr.group-theory 0 \\ \vdots\\ 0 \end{pmatrix} \begin{matrix} \mod M\\ \mod M\\ \vdots\\ \mod M \end{matrix} $$ As it is proven in 1, if we sample $t+\lceil\log|G|\rceil$ random solutions of this system of equations we will obtain a generating set of $H^{\perp}$ with probability exponentially close to one $p\geq 1 -1/2^{t}$. Now to sample from this equations write them in matrix form $AX=0 \pmod M$. Here $A$ is a rectangular matrix over the integers modulo $M$ for which an algorithm given in 2 allows to efficiently compute its Smith normal decomposition. The algorithm returns a diagonal matrix $D$ and two invertible matrices $U$, $V$ such that $D=UAV$. Using this formula the system of equations can be written as $DY=0 \pmod M$ with $X=VY$. Now it is possible to randomly compute solutions of $DY=0\pmod M$ using Euclid's algorithm, since this is a system of equations of the form $d_i y_i =0 \pmod M$. Finally, computing $X=VY$ one obtains a random element of the orthogonal group $H^{\perp}$ as desired.
{ "domain": "cstheory.stackexchange", "id": 1194, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ds.algorithms, time-complexity, matrices, nt.number-theory, gr.group-theory", "url": null }
special-relativity, group-theory, representation-theory, poincare-symmetry $$ \Lambda = \begin{pmatrix} 1 & 0 \\ 0 & R \end{pmatrix} \tag{2} $$ with $R$ a rotation matrix ie a $3\times 3$ satisfying $RR^T = I_3$. For boosts, you can't rigorously talk about a representation as they do not form a subgroup of the Lorentz group (this is the origin of the famous Thomas precession). This subset can be parametrised by a $3$ vector $v$ with corresponding Lorentz factor $\gamma = (1-v^Tv)^{-1/2}$ by: $$ \Lambda = \begin{pmatrix} \gamma & \gamma v^T \\ \gamma v & I_3+\frac{-1+\gamma}{v^T v}v v^T \end{pmatrix} \tag{3} $$ Note that there is another convenient way of representing the Lorentz group as a matrix subgroup. It is the mathematical trick of homogenising The idea is to add an extra dimension. You can view them as $5\times 5$ the matrices of the form: $$ \begin{pmatrix} 1 & 0 \\ u & \Lambda \end{pmatrix} \tag{4} $$
{ "domain": "physics.stackexchange", "id": 89369, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "special-relativity, group-theory, representation-theory, poincare-symmetry", "url": null }
c++, functional-programming, c++11, iterator References and performance: Theoretically, the only things that (I believe) should be copied are iterators, but I'm not sure how to confirm this. I'm hoping that this has very little overhead (A couple of pointer dereferences maybe?), but I'm not sure how to check something like this. Correctness: Are there any hidden bugs that aren't showing up in my use case? Technically, the code isn't really working as "expected" (it should spit out copies of the values for "auto i", and only allow modification of the original containers values with "auto& i", and there should be a version that allows you to look, but not touch: "const auto& i"), but I'm not sure how to fix that. I expect I need to create a const version for the const auto& i mode, but I'm not sure how to make a copy for the auto i version.
{ "domain": "codereview.stackexchange", "id": 17061, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, functional-programming, c++11, iterator", "url": null }
regex, lua, tex Here, I'm storing the operands as nodes in a stack. I tested the above function for the inputs: local s = { "((a)/(b))/(c)", "(a)/((b)/(c))", "(a)/((b)/(c))/(d)", "(a)/(b)/(c)/(d)", "((a)/(b))/((c)/(d))", } for k, v in pairs(s) do print( v, ToFrac(v) ) end The final results were: ((a)/(b))/(c) \dfrac{\dfrac{a}{b}}{c} (a)/((b)/(c)) \dfrac{a}{\dfrac{b}{c}} (a)/((b)/(c))/(d) \dfrac{\dfrac{a}{\dfrac{b}{c}}}{d} (a)/(b)/(c)/(d) \dfrac{\dfrac{\dfrac{a}{b}}{c}}{d} ((a)/(b))/((c)/(d)) \dfrac{\dfrac{a}{b}}{\dfrac{c}{d}}
{ "domain": "codereview.stackexchange", "id": 15545, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "regex, lua, tex", "url": null }
only finitely many Delaunay polytopes modulo $GL(n,\mathbb Z)$.</p> <p>One place where the Voronoi tilings appear is tropical geometry. Indeed, a principally polarized tropical abelian variety $A$ is just the real torus $\mathbb R^n / \mathbb Z^n$ together with the positive definite form $q$. Then the $(n-1)$-skeleton of the Voronoi tiling modulo $\mathbb Z^n$ is the theta divisor on $A$. See Mikhalkin-Zharkov <a href="http://arxiv.org/abs/math/0612267" rel="nofollow">http://arxiv.org/abs/math/0612267</a> for more details. </p> http://mathoverflow.net/questions/20696/a-question-regarding-a-claim-of-v-i-arnold/20720#20720 Answer by VA for A question regarding a claim of V. I. Arnold VA 2010-04-08T12:39:40Z 2012-04-09T19:40:03Z <p>Here is a problem which I heard Arnold give in an ODE lecture when I was an undergrad. Arnold indeed talked about Barrow, Newton and Hooke that day, and about how modern mathematicians can not calculate quickly but for Barrow this would be a one-minute
{ "domain": "mathoverflow.net", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9840936054891429, "lm_q1q2_score": 0.8022650731317889, "lm_q2_score": 0.8152324826183822, "openwebmath_perplexity": 1032.683736208798, "openwebmath_score": 0.8992882966995239, "tags": null, "url": "http://mathoverflow.net/feeds/user/1784" }
ros, ros-kinetic, bash, ubuntu, ros-electric Originally posted by gvdhoorn with karma: 86574 on 2018-10-23 This answer was ACCEPTED on the original site Post score: 2 Original comments Comment by Samah on 2018-10-23: Thank you, it worked. No, it wasn't during the installation. I had a problem with bash before so I probably copied an answer on a forum that contained electric. Comment by gvdhoorn on 2018-10-23:\ so I probably copied an answer on a forum that contained electric.
{ "domain": "robotics.stackexchange", "id": 31949, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros, ros-kinetic, bash, ubuntu, ros-electric", "url": null }
experimental-realization, complexity-theory Title: On the complexity of an oracle for a classical function Let us assume that we have a classical function $f:\{0\,;\,1\}^n\to\{0\,;\,1\}^m$ which is efficiently computable. Then, its oracle is defined with $\mathbf{U}_f\,|x\rangle\,|y\rangle=|x\rangle\,|y\oplus f(x)\rangle$. I quite often read that if $f$ is efficiently computable, then so is $\mathbf{U}_f$. Why is it the case? Where is the computational cost of evaluating $f$ taken into account? Since $\mathbf{U}_f$ is a permutation matrix, one can implement it with at most $2^{n+m}$ SWAP gates, but this is not very efficient. What am I missing? Another related question is: given a permutation matrix, how can one find the appropriate CNOT/SWAP gates succession to implement it? Even if an efficient solution exists, how does one find it? There are several different issues all bundled together here.
{ "domain": "quantumcomputing.stackexchange", "id": 1476, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "experimental-realization, complexity-theory", "url": null }
lua function exp_update(xp, gold, kills, str, con, dex, wis, int, luck, trivia, btrains, pracs, trains, qp, quests, pups, levels, bonusxp, campaigns) local vars = { Exp = tonumber(xp) or 0, Gold = tonumber(gold) or 0, Kills = tonumber(kills) or 0, BonusStr = tonumber(str) or 0, BonusCon = tonumber(con) or 0, BonusDex = tonumber(dex) or 0, BonusWis = tonumber(wis) or 0, BonusInt = tonumber(int) or 0, BonusLuck = tonumber(luck) or 0, Trivia = tonumber(trivia) or 0, BonusTrains = tonumber(btrains) or 0, Pracs = tonumber(pracs) or 0, Trains = tonumber(trains) or 0, Qp = tonumber(qp) or 0, Quests = tonumber(quests) or 0, Pups = tonumber(pups) or 0, Levels = tonumber(levels) or 0, BonusExp = tonumber(bonusxp) or 0, Campaigns = tonumber(campaigns) or 0, } exp_update_actual(vars) end
{ "domain": "codereview.stackexchange", "id": 12475, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "lua", "url": null }
quantum-mechanics, general-relativity, spacetime, curvature, probability Title: Probabilistic spacetime curvature as the union of general relativity and quantum mechanics? General relativity says that an electron exists at some position from where it curves the spacetime around it. Quantum mechanics says that an electron does not exist at any position, but is just a bunch of probability values across space. So to combine these ideas, we make spacetime curvature probabilistic? Like, the probability of existence of a particular spacetime curvature corresponding to a particular electron position is that same as the probability of the existence of the electron at that position. What's wrong with this method? There is a nice brief discussion of this kind of thing in Wald, General Relativity, sec. 14.1. A longer discussion is given in the book Feynman Lectures on Gravitation (not the same thing as the Feynman lectures). Wald writes with 20-20 hindsight about why such attempts failed. Feynman writes a first-hand account of how you would go about constructing such
{ "domain": "physics.stackexchange", "id": 74742, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, general-relativity, spacetime, curvature, probability", "url": null }
## Areas between or under curves Doctor Fenton picked up the question again, discussing the topic in general: The general description of the problem is to find the area between two curves over a bounded interval.  Usually, these are two graphs of the form y=f(x) and y=g(x) over the interval [a,b] (with a < b), or graphs of the form x=h(y) and x=k(y) for y in the interval [c,d]. When the graphs are y=f(x) and y=g(x), then one curve will be above the other over some interval.  If f(x) > g(x) over [a,b], then the area bounded by the two curves will be b ∫ f(x)-g(x) dx . a This will be a positive number, since f(x) > g(x) on the interval.  However, if the two graphs intersect, then they may change places as to which is the upper curve and which is the lower curve.  If f(x)≥g(x) for a ≤ x ≤ c but f(x)g(x) over c ≤ x ≤ b, then y=f(x) is the upper curve on [a,c], and the lower curve on [c,b].  In this case, the total area is
{ "domain": "themathdoctors.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9838471642306268, "lm_q1q2_score": 0.8322780642271109, "lm_q2_score": 0.8459424334245618, "openwebmath_perplexity": 421.76228204656167, "openwebmath_score": 0.799259603023529, "tags": null, "url": "https://www.themathdoctors.org/integrals-and-signed-areas/" }
c++, c++14 template<typename T> constexpr List<T>::List() : length {0} , array {0} { } template<typename T> constexpr List<T>::List(std::initializer_list<T> l) : length {static_cast<int>(l.size())} , array {0} { for (auto it = l.begin(); it != l.end(); ++it) { array[it - l.begin()] = *it; } } template<typename T> constexpr T List<T>::head() const { return array[0]; } template<typename T> constexpr List<T> List<T>::tail() const { List<T> l; l.length = length - 1; for (int i = 0; i < l.length; ++i) { l.array[i] = array[i + 1]; } return l; } template<typename T> constexpr List<T> List<T>::add(T t) const { List<T> l {*this}; l.array[l.length++] = t; return l; } template<typename T> constexpr List<T> List<T>::merge(List<T> l) const { for (int i = l.length - 1; i >= 0; --i) { l.array[i + length] = l.array[i]; } for (int i = 0; i < length; ++i) { l.array[i] = array[i]; } l.length += length; return l; }
{ "domain": "codereview.stackexchange", "id": 15485, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, c++14", "url": null }
molecular-biology, synthetic-biology Title: Can we dilute PureExpress Cell Free Mix to increase number of reactions? Since the PureExpress Cell Free mix is so expensive, I was wondering if it might be possible to just dilute the mix to increase the number of reactions we need to use. From this image I found:
{ "domain": "biology.stackexchange", "id": 11264, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "molecular-biology, synthetic-biology", "url": null }
special-relativity I'm not too familiar with Special relativity but, A is stationary relative to the equilibrium position of the pendulum so he will observe the period of the pendulum according to T = 2π√(l/g) The pendulum is moving relative to B and so B will observe the effects of time dilation, length contraction etc and the period of the pendulum will be greater than that observed by A. But the length of the pendulum is unchanged (I think), but the angle it makes with the vertical is changed and so is the period. However, according to Special Relativity, the Laws of Physics are the same in inertial frames, so T = 2π√(l/g) should hold for B's frame of reference as well so the gravitational field observed by A and B should be different.
{ "domain": "physics.stackexchange", "id": 39114, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "special-relativity", "url": null }
thermal-radiation $$ m_\text{equiv} = \frac E{c^2} = \frac{\rm4\times10^5\,J}{\rm9\times10^{16}\,m^2/s^2} \approx \rm\frac 12\times10^{-11}\,kg \approx \rm 4\,nanogram $$ So no: the state of the art for high-precision mass measurements would need to improve its precision by about four orders of magnitude to see the effect you have in mind.
{ "domain": "physics.stackexchange", "id": 40911, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "thermal-radiation", "url": null }
python, python-2.x, api def normalized_votes_for(self, option): """ Returns the fraction of votes an option recieved Return None if no such option exists """ return self.normalize()[self.options.index(option)] def winner(self): """ Returns the option that got the most votes """ most_popular_index = self.votes.index(max(self.votes)) return self.options[most_popular_index] def loser(self): """ Returns the option that got the least votes """ least_popular_index = self.votes.index(min(self.votes)) return self.options[least_popular_index] def to_clean_dict(self): """ Cleans up self.__dict__ so that it is accepted as json by strawpoll API """ cdict = self.__dict__ for key in cdict.keys(): if cdict[key] == None: del cdict[key] return cdict
{ "domain": "codereview.stackexchange", "id": 15863, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-2.x, api", "url": null }
python, beginner, python-2.x, playing-cards while True : try: clear_output() print"You have Gone Broke. So What? You Were Born to Overcome. You are not Destined to Lose." val = int(raw_input("1. Enter Money to Bank\n2.GO Broke:P\nEnter Your Choice : ")) except: print "Looks like you did not enter a valid choice !\nTry Some Numbers." continue else: if(val == 1): while True : try: print"You have Gone Broke. So What? You Were Born to Overcome. You are not Destined to Lose." self.new_amount = int(raw_input("Empty Your Pockets :) Add Money To Casion Bank ! : ")) except: print "Looks like you did not enter a valid choice !\nTry Some Numbers." continue
{ "domain": "codereview.stackexchange", "id": 26207, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, beginner, python-2.x, playing-cards", "url": null }
particle-physics, standard-model, superposition, quarks, mesons \overline{\mathrm{y}}_{_{12}} & \overline{\mathrm{y}}_{_{22}} & \overline{\mathrm{y}}_{_{32}}\\ \overline{\mathrm{y}}_{_{13}} & \overline{\mathrm{y}}_{_{23}} & \overline{\mathrm{y}}_{_{33}} \end{bmatrix} \tag{017}\label{017} \end{equation} Now, under a unitary transformation $\;W \in SU(3)\;$ in the 3-dimensional space of quarks $\;\mathbf{Q}\;$, we have \begin{equation} \BoldExp{\boldsymbol{\xi}}{'} = W\boldsymbol{\xi} \tag{018}\label{018} \end{equation} so in the space of antiquarks $\overline{\mathbf{Q}}\;$, since $\;\BoldExp{\boldsymbol{\zeta}}{'}=W \boldsymbol{\zeta}\;$ \begin{equation} \overline{\BoldExp{\boldsymbol{\zeta}}{'}}= \overline{W}\;\overline{\boldsymbol{\zeta}} \tag{019}\label{019} \end{equation} and for the meson state \begin{align}
{ "domain": "physics.stackexchange", "id": 58814, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "particle-physics, standard-model, superposition, quarks, mesons", "url": null }
c++, vectors, numerical-methods, c++20 Title: Linear Interpolation for sorted arrays I have made a linear interpolation functions as a side project of mine. It assumes everything is sorted before hand - x and f(x) are the same length. I would like to ask for: general recommendations if I can improve the design (generalize it to all iterables like std::array etc...) and for further performance optimizations. #include <algorithm> #include <cmath> #include <type_traits> #include <vector> #if (__cplusplus < 202002L) template <typename T, typename = std::enable_if_t<std::is_floating_point<T>::value>> T lerp(T a, T b, T t) noexcept { return a + t * (b - a); } #else using std::lerp; #endif template <typename T, typename = std::enable_if_t<std::is_floating_point<T>::value>> class ListLerp { public: explicit ListLerp(const std::vector<T>& xp, const std::vector<T>& yp) : xp(xp), yp(yp) { b = this->xp.begin() + 1; }
{ "domain": "codereview.stackexchange", "id": 38197, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, vectors, numerical-methods, c++20", "url": null }
graph-theory, approximation-algorithms, bipartite-graphs Note that each element of $V_1$ has exactly two neighbors (which is ok since $d \ge 2$). This reduction is clearly polynomial time, since each part of the output instance can be computed from the input instance very quickly. Suppose the input instance in a yes instance. Then let $B$ be a clique in $G'$ of size $k'$ (which exists since the input instance is a yes instance). Let $A \subseteq E'$ contain those edges of $G'$ which are not in the clique $B$. There are $\frac{k'(k' - 1)}{2}$ edges in the clique, so $|A| = |E'| - \frac{k'(k' - 1)}{2}$. Thus we have found $A \subseteq V_1$ and $B \subseteq V_2$ with $|A| \le l = |E'| - \frac{k'(k' - 1)}{2}$ and $|B| \le k = k'$. The only thing left to do in order to show that the output instance is a yes instance is to show that $A \cup B$ is a vertex cover.
{ "domain": "cstheory.stackexchange", "id": 3345, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "graph-theory, approximation-algorithms, bipartite-graphs", "url": null }
thermodynamics, electromagnetic-radiation, photons, energy Is it only lower frequency photons that interact with chemical bonds? Vibrational transitions typically require an amount of energy that corresponds to a photon in the infrared region of the spectrum. Rotational levels are even closer, and are usually measured using combined rotational-vibrational transitions. This leads to the usual ladder of spectroscopy: Vibration (with or without rotation): infrared Electronic excitation (outer electrons, or small atoms) : visible / ultraviolet (UV) Electronic excitation (inner electrons, large atoms): X-ray Nuclear excitation: gamma-ray
{ "domain": "physics.stackexchange", "id": 16110, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "thermodynamics, electromagnetic-radiation, photons, energy", "url": null }
# Is the pseudoinverse of a singular, lower triangular matrix itself lower triangular? Suppose $L\in\mathbb{R}^{n\times n}$ is a singular, lower triangular matrix. Is its psuedoinverse, $L^\dagger\in\mathbb{R}^{n\times n}$, also lower triangular? I have already proved by induction that the product of two lower triangular matrices is lower triangular, and I also proved that the inverse of a (non-singular) lower triangular matrix is lower triangular. I have shown by working out an example with lower triangular $L\in\mathbb{R}^{2\times 2}$ that the pseudoinverse, $L^\dagger\in\mathbb{R}^{2\times 2}$, does not have to be lower triangular, but I was wondering if there might be a better way to prove this than just by showing through an example in $\mathbb{R}^{2\times 2}$ that $L^{\dagger}$ is not necessarily lower triangular.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9814534382002797, "lm_q1q2_score": 0.8509552224423845, "lm_q2_score": 0.8670357546485408, "openwebmath_perplexity": 111.60296327251775, "openwebmath_score": 0.948116660118103, "tags": null, "url": "https://math.stackexchange.com/questions/682714/is-the-pseudoinverse-of-a-singular-lower-triangular-matrix-itself-lower-triangu" }
# An application of Urysohn's lemma Let $X$ be a Compact Hausdorff space. Assume that the vector space of real valued continuous functions on $X$ is finite dimensional. Show that $X$ is finite. Suppose $X$ is infinite, given any $n\in \mathbb{N}$ we get a collection of distinct elements $x_1,\dots,x_n\in X$.. For simplicity and to study first possible non trivial case we consider $n=3$... As $X$ is Hausdoorff for each pair of distinct elements there exists disjoint open sets containing each element.. As $x_1\neq x_2$ there exists disjoint open sets $U_{1,2}$ and $V_{1,2}$ containing $x_1$ and $x_2$ respectively... As $x_2\neq x_3$ there exists disjoint open sets $U_{2,3}$ and $V_{2,3}$ containing $x_2$ and $x_3$ respectively... As $x_1\neq x_3$ there exists disjoint open sets $U_{1,3}$ and $V_{1,3}$ containing $x_1$ and $x_3$ respectively...
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9891815535796247, "lm_q1q2_score": 0.8243093219214626, "lm_q2_score": 0.8333245994514084, "openwebmath_perplexity": 99.09377998867093, "openwebmath_score": 0.9336989521980286, "tags": null, "url": "https://math.stackexchange.com/questions/1690725/an-application-of-urysohns-lemma/1691286" }
black-hole, roche-limit Title: Do Roche limits apply to black holes? Consider black hole A, a super massive black hole at the center of the galaxy. Orbiting it is black hole B, a much less massive black hole. If some passing body were to modify black hole B's orbit such that it fell within the Roche limit of black hole A, what would happen to black hole B? If it were to turn into a ring, would the black hole matter re-inflate since it wouldn't be under such high gravity? Do black holes even respond to Roche limits like regular matter does? The Roche limit applies when a smaller body that would be held together by its own self-gravity is in the gravitational field of another, such that the tidal forces of the latter are stronger than the self-gravity of the latter, thus destroying the smaller body.
{ "domain": "astronomy.stackexchange", "id": 702, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "black-hole, roche-limit", "url": null }
c++, linked-list if (next) next->_prev = prev; --_size; return List_iterator<T>{next}; } auto pop_front() { erase(begin()); } }; Design I prefer using a sentinel node in doubly linked list. This is a fake node with no data. That always exists. B?y using the sentinal you vastly reduce the complexity of your code (as you no longer need to check for nullptr as there is always one element in the list). Code Review Please avoid useless comments. List_node *_start{nullptr}; ///< The first node of the list size_t _size{0}; ///< Amount of elements in the list
{ "domain": "codereview.stackexchange", "id": 28937, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, linked-list", "url": null }
ros, catkin Title: python errors on sourcing devel/setup.zsh When I source devel/setup.zsh in a catkin_tools workspace while using zsh I get python errors on Bionic using Melodic: % source devel/setup.zsh File "<string>", line 1 from __future__ import print_function ^ SyntaxError: invalid syntax File "<string>", line 1 from __future__ import print_function ^ Has anyone else seen this? Do you have any idea how to troubleshoot this? Originally posted by tyler-picknik on ROS Answers with karma: 241 on 2021-01-05 Post score: 0 This was cause by issues in my python enviroment. Closing as this is not an issue with zsh. Originally posted by tyler-picknik with karma: 241 on 2021-01-05 This answer was ACCEPTED on the original site Post score: 0
{ "domain": "robotics.stackexchange", "id": 35932, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros, catkin", "url": null }