text
stringlengths
49
10.4k
source
dict
atomic-physics, semiconductor-physics, notation, orbitals, term-symbols Title: Energy levels and bands in solids: What does $^4\text{F}_{3/2}$ and $^4\text{I}_{11/2}$ mean? I am currently studying Diode Lasers and Photonic Integrated Circuits, second edition, by Coldren, Corzine, and Mashanovitch. In chapter 1.2 ENERGY LEVELS AND BANDS IN SOLIDS, the authors say the following: In gas and solid-state lasers, the energy levels of the active atomic species are only perturbed slightly by the surrounding gas or solid host atoms, and they remain effectively as sharp as the original levels in the isolated atom. For example, lasers operating at the $1.06 \ \text{$\mu$m}$ wavelength transition in Nd-doped YAG, use the $^4\text{F}_{3/2}$ level of the Nd atom for the upper laser state #2 and the $^4\text{I}_{11/2}$ level for the lower laser state #1. I don't understand what is meant in this part: For example, lasers operating at the $1.06 \ \text{$\mu$m}$ wavelength transition in Nd-doped YAG, use the $^4\text{F}_{3/2}$ level of the Nd atom for the upper laser state #2 and the $^4\text{I}_{11/2}$ level for the lower laser state #1.
{ "domain": "physics.stackexchange", "id": 68732, "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, semiconductor-physics, notation, orbitals, term-symbols", "url": null }
Your email address will not be published. For x = 0. exponential distribution probability function for x=0 will be, Similarly, calculate exponential distribution probability function for x=1 to x=30. The exponential distribution is often concerned with the amount of time until some specific event occurs. 4. For example, the amount of time (beginning now) until an earthquake occurs has an exponential distribution. MathsResource.com | Probability Theory | Exponential Distribution A random variable with this distribution has density function f(x) = e-x/A /A for x any nonnegative real number. The probability that more than 3 days elapse between calls is Values for an exponential random variable occur in the following way. Solve for k: ${k}=\frac{ln(1-0.80)}{-0.1}={16.1}$. P(X > 5 + 1 | X > 5) = P(X > 1) = e(–0.5)(1) ≈ 0.6065. We must also assume that the times spent between calls are independent. The cumulative distribution function P(X ≤ k) may be computed using the TI-83, 83+,84, 84+ calculator with the command poissoncdf(λ, k). Other examples include the length of time, in minutes, of long distance business telephone calls, and the amount of time, in months, a car battery lasts. Save my name, email, and website in this browser for the next time I comment. The expected value of X is this term. Suppose that $X$ is a continuous random variable whose probability density function is... How to Use the Z-table to Compute Probabilities of Non-Standard Normal Distributions, Condition that a Function Be a Probability Density Function. Can a Student Pass By Randomly Answering Multiple Choice Questions? When the store first opens, how long on average does it take for three customers to arrive? percentile, k: k = $\frac{ln(\text{AreaToTheLeftOfK})}{-m}$. The mean or expected value of an exponentially distributed random variable X with rate parameter λ is given by Tags: expectation expected value exponential distribution exponential random variable integral by parts standard deviation variance. Other examples include the length, in minutes, of long distance business telephone calls, and the
{ "domain": "elingrelsson.se", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9615338112885302, "lm_q1q2_score": 0.8153496631742639, "lm_q2_score": 0.8479677506936879, "openwebmath_perplexity": 603.5606432501596, "openwebmath_score": 0.6828079223632812, "tags": null, "url": "https://elingrelsson.se/cteen-choice-qqptpb/27194d-exponential-distribution-expected-value" }
vba, excel Debug.Print "Report Generated secs " & Timer - tm End If 'Set Report = Nothing 'Application.ScreenUpdating = True 'Application.Calculation = xlCalculationAutomatic 'Application.EnableEvents = True MsgBox difference & " cells contain different data! ", vbInformation, "Comparing Two Worksheets" End Sub How do I run this code? I add the code into a module and then create a button and do the following. The first picture shows how I call the sub to compare the two sheets The second pictures shows how I open up another file and compare two Excel files. This answer assumes that all Names in the data are unique. There is no provision in this example to handle duplicate Names except to issue a note in the debug output. This answer will involve Dictionaries. Please review this website for complete information on how and why they are an efficient way to store unique data. The short answer is that you can create a large dictionary by looking at a unique "key", which is a string that uniquely represents some data that you want to track. In your case, you've asserted that all of the Names are unique. Dictionaries exist for speedy access to any single entry -- no looping through 200k entries to find the one you want. Use your unique key string and you have near-instant access to the data associated with that key. For your situation, my example builds two Dictionaries, one for each set of data. The keys are the Names. The values associated with each key (Name) is the row number on which each Name is used. The row numbers will play a major role later on. As with the other Code Review for your previous version of code, I'll reiterate: Identify your function parameters ByRef or ByVal Declare your variables as close to their first use as possible. As an example: Dim arr1 As Variant Dim arr2 As Variant arr1 = BuildDataArrays(ws1, startRow:=2) arr2 = BuildDataArrays(ws2, startRow:=2) You'll see that there is a call to a BuildDataArrays function. That brings me to
{ "domain": "codereview.stackexchange", "id": 35650, "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": "vba, excel", "url": null }
capacitance $$V_T=\frac{Q}{A\epsilon _0}\left(\frac{t_1}{\epsilon 1}+\frac{t_2}{\epsilon _2}\right)\:\left[9\right]$$ $$\frac{\left(V_T\epsilon _{0\:}A\right)}{Q}=\left(\frac{t_1}{\epsilon 1}+\frac{t_2}{\epsilon _2}\right)\:\left[10\right]$$ $$\frac{Q}{V_T\epsilon _0A}=\frac{1}{\left(\frac{t_1}{\epsilon \:1}+\frac{t_2}{\epsilon \:_2}\right)}\:\left[11\right]$$ $$C=\frac{A\epsilon _{0\:}}{\left(\frac{t_1}{\epsilon \:1}+\frac{t_2}{\epsilon \:_2}\right)}\:\left[12\right]$$ where $A$=$S$ As you can see I have an extra epsilon but I cant see how the epsilon has be canceled out. Just nomenclature. Your $\epsilon_1$ is relative permittivity while their $\epsilon_1$ is permittivity.
{ "domain": "physics.stackexchange", "id": 46047, "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": "capacitance", "url": null }
ros, universal-robot Thank you for your help and bringing ROS (community) further. Originally posted by toriori on ROS Answers with karma: 1 on 2017-02-08 Post score: 0 You don't tell us what you've already tried, so: have you seen wiki/universal_robot? As to the sensor: you don't tell us what (kind of) sensor you have, so there I cannot help you. Edit: this is probably not what you want to hear, but I have to ask: have you looked at any of the tutorials, read a book or experimented a bit with ROS before you set out to work with your UR5? I ask because your questions seem to suggest that you might be struggling with the basic setup of a ROS workspace, downloading, understanding and compiling packages and then using them. If you have already looked at them, please ignore, but I'll just include a link to the basic ROS tutorials and to (one example of) a book: A Gentle Introduction to ROS (there are many more, but this one is available for free). If this is your first experience with ROS, please spend some time studying these resources, as they will let you avoid lots and lots of frustration and "spend[ing] hours on hours on" issues like the current one. Now as to your questions: 1 . Is it possible to have a "tf monitor" like in this video (minute 6:40) for the current status of the roboter? When yes, how ? tf_monitor is a tool in the tf package, which is a basic part of all ROS installations, so you should have it already. For visualisation of TF frames, use the TF Display in RViz. 2 . When I follow the link wiki/universal_robot [..] which of the folders (on GitHub) should I put in source folder? First: determine whether you really need to build the packages from source or if you could just use the binary packages that have already been prepared for you. Are you going to work on the source code of the UR drivers? Or do you just want to interface with your robot? Are you runing ROS Kinetic?
{ "domain": "robotics.stackexchange", "id": 26951, "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, universal-robot", "url": null }
homework-and-exercises, special-relativity, metric-tensor, tensor-calculus, inertial-frames -\frac{v_1+v_2}{1+v_1+v_2} & 1 \\ \end{bmatrix} \end{align*} \begin{align*} &\text{with:}\\\\ &\gamma(v_1\,,v_2)=\frac{1}{\sqrt{1-v_1^2}}\,\frac{1}{\sqrt{1-v_2^2}} (1+v_1\,v_2)=\frac{1}{\sqrt{1-\left(\frac{v_1+v_2}{1+v_1\,v_2}\right)^2}}\\\ &\Rightarrow\\ &\text{The Lorentz transformation matrix between $(t"\,,x")$ and $(t,x)$ is:}\\\\ &L(v_1,v_2)=\frac{1}{\sqrt{1-v_g^2}} \begin{bmatrix} 1 & -v_g \\ -v_g & 1 \\ \end{bmatrix}\quad, \text{with:}\\\\ &\boxed{v_g=\frac{v_1+v_2}{1+\frac{v_1\,v_2}{c^2}}}\quad \text{Einstein velocity addition equation in Minkowski space} \end{align*}
{ "domain": "physics.stackexchange", "id": 51991, "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, special-relativity, metric-tensor, tensor-calculus, inertial-frames", "url": null }
general-relativity, special-relativity, differential-geometry, tensor-calculus, curvature $$ and so on. Therefore, for the Riemann tensor to be invariant, the components transform as $$ R^\rho{}_{\sigma\mu\nu} = \Lambda^\mu{}_{\hat{\alpha}} \Lambda^{\hat{\beta}}{}_\sigma \Lambda^{\hat{\gamma}}{}_\mu \Lambda^{\hat{\delta}}{}_\nu R^{\hat{\alpha}}{}_{\hat{\beta}\hat{\gamma}\hat{\delta}} $$ Notice that this transformation is straightfowardly inverted, which allows one to find the components of the transformed Riemann tensor in terms of the components in the old coordinate system. This would correspond with the frame of the moving observer in your case. So, in summary: yes, you can find the components of the Riemann tensor in the frame of the moving observer in terms of the static observer in the way you suspected. In fact, this is how the components of the Riemann tensor in the inertial frame were calculated to begin with; from the transformation of the components in the curved frame. See equation (8) in your reference. Do note that Morris and Thorne perform this final coordinate transformation on the components of the Riemann tensor with all indices down.
{ "domain": "physics.stackexchange", "id": 70330, "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, differential-geometry, tensor-calculus, curvature", "url": null }
physical-chemistry, electrochemistry, reduction-potential Title: Oxidation of metals/halogens by oxygen gas in acidic aqueous solution I had some confusion about the correct answer to the following question: Which substance can be oxidized by $\ce{O2(g)}$ in acidic aqueous solution? Two of the answer choices were metal cations (usually not oxidized further). The remaining three choices were: $\ce{Br2(l)}$, $\ce{Ag(s)}$ and $\ce{Br-(aq)}$. The standard reduction potentials were given: $$ \begin{align} \ce{O2(g) + 4 H+(aq) + 4 e- &→ 2 H2O(l)} &\quad E^\circ &= \pu{+1.23 V} \\ \ce{Ag+ + e- &→ Ag(s)} &\quad E^\circ &= \pu{+0.799 V} \\ \ce{Br2(l) + 2 e- &→ 2 Br-(aq)} &\quad E^\circ &= \pu{+1.065 V} \end{align} $$
{ "domain": "chemistry.stackexchange", "id": 11757, "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": "physical-chemistry, electrochemistry, reduction-potential", "url": null }
python Title: Function calls as parameters for other functions I am in two minds about function calls as parameters for other functions. The doctrine that readability is king makes me want to write like this: br = mechanize.Browser() raw_html = br.open(__URL) soup = BeautifulSoup(raw_html) But in the back of my mind I feel childish doing so, which makes me want to write this: br = mechanize.Browser() soup = BeautifulSoup(br.open(__URL)) Would it actually look unprofessional to do it the first way? Is there any serious reason to choose one method over the other? I'm typically an advocate of liberal use of space, but in this situation, I'd go with the third option: soup = BeautifulSoup(mechanize.Browser().open(__URL)) (I'm not actually sure if that's valid syntax or not. I'm not very familiar with Python [I think it's Python?].) I find that just as readable. There are of course situations where you must separate it though. The first thing that comes to mind is error handling. I suspect that open throws exceptions, but if it were to return boolean false on failure rather than a string, then I would be a fan of option two. Option two would still be brief, but would allow for properly checking for the false return. I think this really comes down to personal taste. There's no magical rule book for this type of thing (though I'm sure there are convoluted, borderline-dogmatic metrics somewhere that support one way or the other). I tend to just eyeball things like this and see if they make me visually uncomfortable or not. For example: superLongVariableNameHere(someParamWithLongName, someFunctionLong(param1, param2), someFunc3(param, func4(param1, param2, func5(param))) Makes me cry a little whereas: func(g(x), y(z)) Seems perfectly fine. I just have some weird mental barrier of what length/nesting level becomes excessive.
{ "domain": "codereview.stackexchange", "id": 3120, "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", "url": null }
We will study the expected value of random vectors and matrices in more detail in a later section. In both the one and $$n$$-dimensional cases, a function $$g: S \to \R$$ is concave (or concave downward) if the inequality in the definition is reversed. Jensen's inequality also reverses. ### Expected Value in Terms of the Quantile Function If $$X$$ has a continuous distribution with support on an interval of $$\R$$, then there is a simple (but not well known) formula for the expected value of $$X$$ as the integral the quantile function of $$X$$. Here is the general result: Suppose that $$X$$ has a continuous distribution with support on an interval $$(a, b) \subseteq \R$$. Let $$F$$ denote the cumulative distribution function of $$X$$ so that $$F^{-1}$$ is the quantile function of $$X$$. If $$g: (a, b) \to \R$$ then (assuming that the expected value exists), $\E[g(X)] = \int_0^1 g\left[F^{-1}(p)\right] dp, \quad n \in \N$ Proof
{ "domain": "libretexts.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9933071478869498, "lm_q1q2_score": 0.8002402095651502, "lm_q2_score": 0.8056321866478978, "openwebmath_perplexity": 125.24691044188918, "openwebmath_score": 0.9755764603614807, "tags": null, "url": "https://stats.libretexts.org/Bookshelves/Probability_Theory/Probability_Mathematical_Statistics_and_Stochastic_Processes_(Siegrist)/04%3A_Expected_Value/4.02%3A_Additional_Properties" }
python However, although neater than your current code, this is still relatively inefficient, as it builds multiple lists; you could instead try something like: set2 = [s for s in set2 if s['LEAD_TIME'] >= 0 and all(s[key] != excl for key, excl in conditions)] which reduces it to a single list comprehension. An alternative would be to incorporate e.g.: INVALID_WRK = { 'INDEPENDENT CONTRACTOR', ... } ... s['WRK_RLTN_DSC'] not in INVALID_WRK ... as you check that key multiple times.
{ "domain": "codereview.stackexchange", "id": 33266, "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", "url": null }
c, tree, hash-map if (!p_ret) return NULL; p_ret->p_key = p_key; p_ret->p_value = p_value; p_ret->p_left = NULL; p_ret->p_right = NULL; p_ret->p_parent = NULL; p_ret->height = 0; return p_ret; } /******************************************************************************* * Returns the height of an entry. The height of a non-existent entry is * * assumed to be -1. * *******************************************************************************/ static int height(map_entry_t* p_node) { return p_node ? p_node->height : -1; }
{ "domain": "codereview.stackexchange", "id": 15453, "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, tree, hash-map", "url": null }
$$a_n = a_{n-1}+a_{n-2}-a_{n-5}-2a_{n-7}+a_{n-9}+a_{n-1}+a_{n-11}+a_{n-12}-2a_{n-14}-a_{n-16}+a_{n-19}+a_{n-20}-a_{n-21}$$ where $a_0=1$ and $a_n=0$ for all $n<0$. One could come up with something else similar from first principles by noting that the number $a_n$ we seek is going to equal $$a_n=p_6(n)+p_5(n)+p_4(n)+p_3(n)+p_2(n)+p_1(n)+p_0(n)$$ where $p_k(n)$ counts the number of partitions of $n$ into at most $k$ parts. One could calculate $p_k(n)$ recursively by noting $p_k(n)=p_{k}(n-k)+p_{k-1}(n-1)$ with initial conditions $p_0(0)=1$ and $p_k(n)=0$ whenever $n\leq 0$ or $k\leq 0$ but not both. (The brief reasoning behind this recurrence is that any partition of $n$ into $k$ parts either has all of its parts of size at least 2, or it has at least one part of size one. In the first case, by removing one from each of its parts, we are left with a partition of $n-k$ into $k$ parts. In the second case, by removing one of the parts of size one, we are left with a partition of $n-1$ into $k-1$ parts.)
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9783846640860381, "lm_q1q2_score": 0.8044172341495356, "lm_q2_score": 0.8221891283434877, "openwebmath_perplexity": 133.78327469631242, "openwebmath_score": 0.6950575113296509, "tags": null, "url": "https://math.stackexchange.com/questions/2544575/how-to-exclude-similar-pairs-from-a-series" }
javascript, sorting test("Can compare null code with given code", function() { var result = [{code: null}, {code: 'A'}].sort(myComparer); strictEqual(result[0].code, null); strictEqual(result[1].code, 'A'); }); test("Can compare null code with given code - reverse", function() { var result = [{code: 'Z'}, {code: null}].sort(myComparer); strictEqual(result[0].code, null); strictEqual(result[1].code, 'Z'); }); test("Will sort on label before code", function() { var result = [ {id: 1, label: 'Z', code: 'Z'}, {id: 2, label: 'Z', code: 'A'}, {id: 3, label: 'A', code: 'Z'}, {id: 4, label: 'A', code: 'A'}].sort(myComparer); strictEqual(result[0].id, 4); strictEqual(result[1].id, 3); strictEqual(result[2].id, 2); strictEqual(result[3].id, 1); }); <script src="http://code.jquery.com/qunit/qunit-1.12.0.js"></script> <link href="http://code.jquery.com/qunit/qunit-1.12.0.css" rel="stylesheet"/> <div id="qunit"></div> <div id="qunit-fixture"></div> Using the conditional-expression operator greatly shortens the code, but the biggest gain comes from using a function for common code. I also rearranged the conditional logic so that it doesn't have to make as many comparisons.
{ "domain": "codereview.stackexchange", "id": 40769, "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, sorting", "url": null }
sql, sql-server, null In the past (before the case statement was available) I used to do calculations like the above, but depending on the circumstances, it can be less readable than the case. In this instance, I think the case is still better.
{ "domain": "codereview.stackexchange", "id": 10098, "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": "sql, sql-server, null", "url": null }
java, algorithm Note that your implementation, and this revised one, has three problems which should be dealt with at some point: The spaces are not taken into account for the maximum line length. It prints an extra space at the end of each line. How a word should be treated that is longer than the maximum line length. ...and just use pointers instead of split(),... There is no such thing as "a pointer for strings" in Java. Though, you most likely mean, to iterate over the String and keep track of the index, but "pointer" is a heavily prejudiced word, and I would stay clear of it and instead use "index". int lastWhitespaceIdx = -1; Don't shorten names just because you can, it does make the code harder to read in the end of the day. int lineCount = 0; The name of this variable is incorrect, it does not count lines, it counts characters on the current line, it should be named accordingly. while (i < s.length()) { Not sure why you use a while when a for would be perfect for what you're doing here. System.out.print(s.charAt(i)); Printing single characters at a time can be quite wasteful, depends on whether the stream supports some sort of buffer or not. You could use String.indexOf(String) and String.index(String, int) to iterate over the string and simplify your logic. Then use substring to extract the part of the String between the spaces and print that, or print that part character by character.
{ "domain": "codereview.stackexchange", "id": 39571, "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, algorithm", "url": null }
Can you now relate now $\alpha, \beta, \gamma$ with $p$ and $q$? Do we get any relation between $\alpha, \beta, \gamma$? Yes, from $$(x-\alpha)(x-\beta)(x-\gamma)=x^3+px+q$$ one obtains $\alpha \beta + \alpha \gamma + \beta\gamma= p$, $\alpha \beta \gamma =-q$, and $\alpha + \beta + \gamma=0$. Due to this latter relation, one can also write $(\alpha + \beta + \gamma)^2=0$, i.e., $\alpha^2 +\beta^2 +\gamma^2=-2(\alpha \beta + \alpha \gamma + \beta\gamma)=-2p$ and also $(\alpha \beta)^2 + (\alpha \gamma)^2 + (\beta \gamma)^2=(\alpha \beta + \alpha \gamma + \beta \gamma)^2-2(\alpha \beta\gamma)(\alpha +\beta+\gamma)=(\alpha \beta + \alpha \gamma + \beta \gamma)^2=p^2$ After this, consider a degree 3 function that has roots $\frac{\alpha \beta}{\gamma}, \frac{\alpha \gamma}{\beta}, \frac{\alpha \gamma}{\beta}$:
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9808759626900699, "lm_q1q2_score": 0.8297645987656974, "lm_q2_score": 0.8459424334245618, "openwebmath_perplexity": 231.44962760653493, "openwebmath_score": 0.9039620757102966, "tags": null, "url": "https://math.stackexchange.com/questions/2009903/transformation-of-roots-for-a-cubic-polynomial/2009945" }
php, mysqli, session, authentication // *** what happens here, you let the script continue regardless of the error? } // Pretty much kicks out a user once they revisit this age and is logged in // *** It is best to test isset($_SESSION["name"]), otherwise php will generate a warning if 'name' index is not set. // you can also test for !empty($_SESSION["name"]), as empty detects if a value is not set, but it will also detect 0 as empty, so use with caution // if( $_SESSION["name"] ) if( isset($_SESSION["name"]) && $_SESSION["name"] ) { echo "You are already logged in, ".$_SESSION['name']."! <br> I'm Loggin you out M.R .."; unset( $_SESSION ); session_destroy(); // *** The empty quotes do nothing // exit(""); exit; } $loggedIn = false; // *** While or is nice solution, it doesn't take into account when the 'name' index is not set, which generates a php warning // $userName = $_POST["name"] or ""; $userName = isset($_POST["name"]) ? $_POST["name"] : null; // *** same change as above // $userPass = $_POST["pass"] or ""; $userPass = isset($_POST["pass"]) ? $_POST["pass"] : null;
{ "domain": "codereview.stackexchange", "id": 7408, "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, mysqli, session, authentication", "url": null }
c#, linq, file-system, wpf, xaml <Grid Background="LightGray"> <Grid.RowDefinitions> <RowDefinition Height="1*"/> <RowDefinition Height="10*"/> <RowDefinition Height="1*"/> </Grid.RowDefinitions> <Label VerticalAlignment="Bottom" HorizontalContentAlignment="Center" FontWeight="Bold" Background="GhostWhite" Content="Drag and Drop Files from one List to another to sort them."/> <Grid Name="grid_AllLists" Grid.Row="1"> <Grid.ColumnDefinitions> <ColumnDefinition Width="3*"/> <ColumnDefinition Width="2*"/> <ColumnDefinition Width="2*"/> </Grid.ColumnDefinitions> <Grid Margin="5" Grid.Column="0" HorizontalAlignment="Stretch"> <Grid.RowDefinitions> <RowDefinition Height="Auto"/> <RowDefinition Height="*"/> </Grid.RowDefinitions> <Label HorizontalContentAlignment="Center" Grid.Row="0" FontWeight="Light" Content="SORTED FILES"/>
{ "domain": "codereview.stackexchange", "id": 18059, "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#, linq, file-system, wpf, xaml", "url": null }
comparative-review, error-handling, file-system, go Title: Go functions to create a directory if it doesn't exist Which of the 2 solutions is written better? Personally I prefer the one line method but it does make it slightly more difficult to debug. Is perhaps doing it the long way first then refactoring to the second method once we know all is tested to be working. Please note Environment var "FT_SOURCE" is set to "c:\filemover\" Original solution... func ensureDirold(dirName string) (string, error) { err := os.Mkdir(dirName, os.ModeDir) if err == nil || os.IsExist(err) { return dirName, nil } else { return dirName, err } } Usage... func OldWay() { dir := os.Getenv("FT_SOURCE") //is set to c:\filemover fmt.Print(ensureDirold(dir)) _, err := os.Create(dir + "myfile-old.txt") check(err) } Alternate Solution... type strerr struct { str string err error } func ensureDirnew(dirName string) strerr { err := os.Mkdir(dirName, os.ModeDir) if err == nil || os.IsExist(err) { return strerr{ str: dirName, err: nil, } } else { return strerr{ str: dirName, err: err, } } } Usage... func NewWay() { _, err := os.Create(ensureDirnew(os.Getenv("FT_SOURCE")).str + "myfile.txt") check(err) } Create a directory if it doesn't exist. Don't report an error if the directory exists.
{ "domain": "codereview.stackexchange", "id": 35513, "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": "comparative-review, error-handling, file-system, go", "url": null }
measurement Title: Generalized measurement interpreted as entanglement unitary + measurement. Why is it indeed a unitary? A generalized measurement can be defined as follow: It is a set of operators $\{M_m \}$ such that, given an initial quantum state $|\psi\rangle$, we have the state after measurement being: $$|\psi\rangle \rightarrow \frac{M_m |\psi\rangle}{\langle \psi | M_m^{\dagger}M_m |\psi\rangle} $$ The probability to find the outcome $m$ is: $p(m)=\langle \psi | M_m^{\dagger}M_m |\psi\rangle$ We can interpret the generalized measurement as entanglement unitary between a system and an ancillary system, and then a measurement on this ancillary system via the following: $$U |\psi \rangle |0 \rangle = \sum_m M_m |\psi \rangle |m \rangle$$ My question is: how to prove that this $U$ is indeed a unitary ? I guess we also have to define its action on other states than $|0\rangle$ in the ancillary system, but how to do it ? It is not necessary to define the action of $U$ on other states. It is sufficient to know that the defined action is compatible with being a unitary (i.e. inner produces are preserved between all inputs) because there always exists an extension of the defined action such that it is unitary. So, all you really have to check is that $$ \left(\langle\psi|\langle 0|\right)\left(|\phi\rangle|0\rangle\right)=\left(\langle\psi|\langle 0|U^\dagger\right)\left(U|\phi\rangle|0\rangle\right)=\sum_n\langle\psi|M_n^\dagger\langle n|\sum_mM_m|\phi\rangle|m\rangle. $$ The right-hand side simplifies to $$
{ "domain": "quantumcomputing.stackexchange", "id": 1204, "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": "measurement", "url": null }
quantum-algorithms, entanglement, teleportation Qbit 2 and 3 are in Bell state: $\frac{1}{\sqrt{2}}(|00\rangle + |11\rangle)$. The full state of three Qbits 1, 2, 3 is $(\alpha_0 |0\rangle+\alpha_1|1\rangle) \otimes \frac{1}{\sqrt2}(|00\rangle+|11\rangle)$. In an extended (more painful) notation it would be: $$\frac{\alpha_0}{\sqrt2}|000\rangle + 0 \cdot |001\rangle + 0 \cdot|010\rangle+ \frac{\alpha_0}{\sqrt2}|011\rangle + $$ $$\frac{\alpha_1}{\sqrt2}|100\rangle + 0 \cdot|101\rangle + 0 \cdot|110\rangle+ \frac{\alpha_1}{\sqrt2}|111\rangle + $$ Now I'd like to apply a CNOT gate (Controlled Not) to Qbits 1 and 2, and finally H gate (Hadamard transform) to Qbit 1. I know how CNOT operation affects Qbit 1 and 2, but it's not completely clear how does it affect Qbit 3. I'm wondering what is the $8 \times 8$ Matrix that is applied to the state (in extended notation) when is applied CNOT on Qbit 1 and 2. Whenever you have a quantum gate (like a CNOT) acting on some qubits but not others, it is assumed that the other qubits are acted on with the identity operator. This is done using the "Left Kronecker product" or the "tensor product". So the 8x8 matrix is made by applying CNOT to qubits 1 & 2 and the identity matrix to qubit 3: $$ \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \end{bmatrix}\otimes
{ "domain": "quantumcomputing.stackexchange", "id": 271, "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-algorithms, entanglement, teleportation", "url": null }
astrophysics, classical-mechanics http://en.wikipedia.org/wiki/Declination which is the ordinary Earth's latitude above which the object is located. It's changing between 37 and 43 (plus means North Hemisphere): the planes of orbits differ. From the changes of these two coordinates, you may deduce the angular velocity. The declination changed from 37.5 to 42.5 i.e. by 5 degrees = $pi/36$ radian. At distance of 5471 km I announced above, it's 477 kilometers. It took some time - the difference between 8:21.60 and 8:20.73 which is 0.87 minute i.e. 52 seconds, so you can see that the speed was about 10 km/s in your table The table also includes Delta which I am not sure about now; distance from the Sun in AU called $r$ (which is obviously not too far from one), and elongation http://en.wikipedia.org/wiki/Elongation_%28astronomy%29 which is the angle between the object and the Sun, as seen from the Earth. The distance from the Earth is not directly listed because it's not directly measured. One only knows the angle and the redshift. $V$ is not the velocity you want - which I calculated above.
{ "domain": "physics.stackexchange", "id": 45565, "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": "astrophysics, classical-mechanics", "url": null }
java, html, parsing, regex, web-scraping Title: HTML downloader and parser for CR This program downloads a Code Review HTML file and parses it. Could you review my program? Main.java import java.net.URL; public class Main { public static void main(String[] args) throws Exception { final String site1 = "http://codereview.stackexchange.com/questions/"; String site2; String site3; URL url; HtmlGetter htmlGetter = new HtmlGetter(); while(true) { site2 = "69"; site3 = "is-this-implementation-of-shamos-hoey-algorithm-ok"; url = new URL(site1 + site2 + "/" + site3); htmlGetter.setFileName("[" + site2 + "]" + site3 + ".html"); htmlGetter.download(url); htmlGetter.parse(); break; } } } HtmlGetter.java import java.io.File; import java.io.InputStream; import java.io.OutputStream; import java.io.FileInputStream; import java.io.FileOutputStream; import java.net.URL; import java.util.Scanner; import org.apache.commons.lang3.StringEscapeUtils; import org.apache.commons.io.IOUtils; public class HtmlGetter { private String fileName; public void setFileName(String fileName) { this.fileName = fileName; } public String getFileName() { return fileName; } public void download(URL url) throws Exception { final InputStream in = url.openStream(); final OutputStream out = new FileOutputStream(fileName); IOUtils.copy(in, out); in.close(); out.close(); }
{ "domain": "codereview.stackexchange", "id": 1723, "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, html, parsing, regex, web-scraping", "url": null }
ros, object-detection Your best bet is to edit the wiki so it points to the correct resource. See my answer, that would be impossible in this case. And @burn10: I do agree with @kscottz: posting here on ROS Answers to request a page on the ROS wiki be updated which is maintained by the zed-ros-wrapper maintainers is not the most efficient way to go about it. I'd suggest contacting the maintainers via their issue tracker, or indeed updating the link yourself, if you know the correct one. The ROS wiki is a wiki after all. Comment by gvdhoorn on 2021-02-08: Seems you've posted on the issue tracker: stereolabs/zed-ros-wrapper#667. It's not just that link: none of the messages from the zed_interfaces package have working ROS msg API links. It seems the source repository (stereolabs/zed-ros-wrapper) was never registered for indexing by the ROS buildfarm (or at least, it isn't in any of the distribution.yaml files for Kinetic, Melodic or Noetic), which means none of the API docs was ever generated. And even if the package was registered, the link still wouldn't work, as messages use CamelCase. It should be zed_interfaces/ObjectStamped. I would very much appreciate if the said link was repaired. I would suggest you post an issue on the zed issue tracker, pointing the authors/maintainers to your question on ROS Answers (ie: this one) and the Indexing Your ROS Repository for Documentation Generation page on the ROS wiki. But note again: after the maintainers have registered the repository for indexing, the wiki page will have to be updated to use CamelCase everywhere for the messages in the zed_interfaces package. Originally posted by gvdhoorn with karma: 86574 on 2021-02-06 This answer was ACCEPTED on the original site Post score: 1
{ "domain": "robotics.stackexchange", "id": 36049, "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, object-detection", "url": null }
energy, work, torque, rotation Title: While unwrapping a rope the torque due to tension shouldn't do work as the point of contact does not move while the torque is being applied? This explains my question in more detail If you don't get what I am asking feel free to comment I would try to improve my question Your are right in thinking that work is done by the indicated applied force on the pulley. The torque from the force continuously increases its rotational kinetic energy, an evidence of work being done. You argue that since the portion of the rope that applied torque during the time $[t,t+dt)$, thus inducing an angular change $d\theta$ in the orientation of the pulley, is no longer in touch with the original point of contact, "hence no work should be done". Fine - post contact no work is done. But what about the work done when it $was$ in contact? It did do work then. It was $dW=\tau d\theta$. Similarly, the next part that follows touches during $(t+dt, t+2dt)$, also similarly does work during its contact. By imagining these sections to be infinitesimally small $(dt\to0)$, you get the continuous case of the rope, applying constant torque and doing work. On a different note, contact isn't necessary to do work. Imagine, err, non-contact forces.
{ "domain": "physics.stackexchange", "id": 79910, "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": "energy, work, torque, rotation", "url": null }
quantum-field-theory, particle-physics, standard-model, quarks However, there exists a linear superposition of the states in the Hilbert space that is a mass eigenstate (if the particle is in the rest frame, it's the same thing as an energy eigenstate). The corresponding linear superpositions are known as $K_{0S}$ and $K_{0L}$ where L,S stand for long-lived and short-lived. If a kaon is a $K_{0S}$, then it will be a $K_{0S}$ until the end of its (short) life: it will never become a long-lived one. And similarly $K_{0L}$ will remain a $K_{0L}$ until the end of its (a bit longer) lifetime; it will never be the short-lived one. So they don't oscillate; however, they still have an exponentially decaying probability of staying alive because they decay, with different decay rates (which really determine the imaginary part of their mass). Again, for the mass eigenstates, it's true that two $K_{0S}$ particles are indistinguishable but $K_{0L}$ is distinguishable from a $K_{0S}$. If you have two kaons that oscillate and each of them is exactly in some phase of the oscillation, then they're partly distinguishable, partly indistinguishable. Just write the two-particle state as a linear superposition of some basis vectors, e.g. $$ |K_{0S},K_{0S}\rangle, \quad |K_{0S},K_{0L}\rangle, \quad |K_{0L},K_{0S}\rangle, \quad |K_{0L},K_{0L}\rangle, \quad $$
{ "domain": "physics.stackexchange", "id": 3584, "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-field-theory, particle-physics, standard-model, quarks", "url": null }
bioinformatics Title: Topic in bioinformatics I am looking for a presentation topic in bioinformatics. I haven't occupied with this field yet, but I find it really interesting. It would be nice if the topic would include an algorithm. What source do you suggest to me? A fairly easy to get to grips with topic, but that digs down to the meat of bioinformatics algorithms, is sequence alignment. Read around Needleman-Wunsch and Smith-Waterman alignment algorithms. Wikipedia will be a perfectly adequate starting place :) - steal all the references at the bottom of the page! I don't know how strong you maths ability is, but you'll find quite a few equations while you dig around in the bases of bioinformatics algorithms!
{ "domain": "biology.stackexchange", "id": 6479, "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": "bioinformatics", "url": null }
python, beginner, csv, file-system, pandas Tracking an Index If you ever find yourself doing the following: counter = 0 for x in iterable: something[x] = 1 counter += 1 It's probably better to use enumerate to track the index: l = list('abcd') for idx, item in enumerate(l): print(idx) 0 1 2 3 You can also provide a start kwarg to tell enumerate where to begin: l = list('abcd') for idx, item in enumerate(l, start=1): print(idx) 1 2 3 4 So in your identifyFields function, I would definitely leverage that: for counter, field_name in enumerate(df.columns, start=1): # rest of loop Counter When you are iterating over your file to get character counts, you are losing speed with extra steps by converting to list, then checking for \n, then building your Counter. Counter will consume a string, and \n is a single string object. Move that into a separate function for separation of concerns: def read_file(filepath): # It is much better practice to open files using the with context manager # it's safer and less error-prone with open(filepath) as fh: char_counts = [] for line in fh: # don't construct a list, there's no need, # just check if startswith, which is the same # as line[0] == '\n' if not line.startswith('\n'): # Counter will consume a string char_counts.append(Counter(line)) return char_counts char_counts = read_file(name) Or, a bit more succinctly as a list comprehension: def read_file(name): with open(filename) as fh: return [Counter(line) for line in fh if not line.startswith('\n')]
{ "domain": "codereview.stackexchange", "id": 35200, "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, csv, file-system, pandas", "url": null }
java, beginner, swing, pokemon This... isn't quite preferred. Normal convention dictates something like this, again for clarity: case <n>: ... break; default: break; Use a better class name TypeChecker can imply lots of types checking. You can easily rename it as PokemonTypeChecker. :) Consider a CustomRenderer for your JComboBox? I am a little unsure of this suggestion (I have to do some reading for myself as well), but maybe you can consider a CustomRenderer for your JComboBox?
{ "domain": "codereview.stackexchange", "id": 9226, "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, swing, pokemon", "url": null }
Sort by: yes sir but when the value of k is increased in polar form of (i)^(square root of 2), we do not get the solutions that superimpose the previous solutions. so we instead get infinite no of solutions. it form a circle with magnitude equal to one and center as origin in Argand Plane after k becomes infinite. so does that mean (i)^(any irrational number) forms a circle with magnitude of value one and center at origin.and get same set of solutions. does this mean (i)^any irrational number has same set of values. - 9 months, 2 weeks ago The basic way to define powers of complex numbers is via the formula $z^w \; = \; e^{w\log z}$ and so the whole business revolves around the definition of the logarithm of complex numbers. We need $\log z \; = \; \ln |z| + i\mathrm{Arg}\,z$ and here is the real problem. There is no way of defining the argument function continuously (let along differentiably) on the whole complex plane. Since we want the argument (and hence the logarithm) to be differentiable, it has to be defined on an open set (so that we can consider its derivative at all points), and complex functions are considered on open connected domains. The standard way of doing this for the argument is to cut the plane. This means considering the domain formed by the complex numbers with a straight line out from $$0$$ to infinity removed. The argument can be defined uniquely (and differentiably) on any such domain, and so can the natural logarithm of the modulus (since we have removed $$0$$).
{ "domain": "brilliant.org", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9736446456243804, "lm_q1q2_score": 0.8559765552355414, "lm_q2_score": 0.879146780175245, "openwebmath_perplexity": 694.9014525476272, "openwebmath_score": 0.9641269445419312, "tags": null, "url": "https://brilliant.org/discussions/thread/what-happens-to-iirrational-number/" }
What's the distribution of $(a-d)^2+4bc$, where $a,b,c,d$ are uniform distributions?
{ "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.8035576403009771, "lm_q2_score": 0.8267117898012104, "openwebmath_perplexity": 772.0392508118454, "openwebmath_score": 0.7386404871940613, "tags": null, "url": "https://stats.stackexchange.com/questions/144138/whats-the-distribution-of-a-d24bc-where-a-b-c-d-are-uniform-distributi?noredirect=1" }
java, socket /** * Blocking method. */ public String takeNextMessage() throws InterruptedException { return blockingQueue.take(); } public void startReceivingMessages() { Executors.newSingleThreadExecutor().submit(() -> { try { String fullMessage = ""; String line; while ((line = reader.readLine()) != null) { if (line.startsWith(MESSAGE_SEPARATOR)) { if (!fullMessage.isEmpty()) blockingQueue.put(fullMessage); fullMessage = ""; } fullMessage += line; } if (!fullMessage.isEmpty()) blockingQueue.put(fullMessage); } catch (Exception e) { e.printStackTrace(); } }); } I hope you can appreciate how hugely simpler this is. It's not just that it is shorter, but that there is absolutely no reasoning to do about which variable in which thread has to be synchronized, and how and where does variables, or code blocks, should synchronize. With the modern constructs, there is no need to use synchronized, wait/notify, volatile, or xxxx.lock() in the vast majority of problems. The code is much much easier to read and reason about.
{ "domain": "codereview.stackexchange", "id": 8250, "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, socket", "url": null }
fcsi, 76q, sxxs, fon, rv, 45wx7, oub, tb, dg, qsax,
{ "domain": "menubuddy.sg", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.992422760300897, "lm_q1q2_score": 0.8204475964078123, "lm_q2_score": 0.8267117898012105, "openwebmath_perplexity": 683.347574851877, "openwebmath_score": 0.8974097967147827, "tags": null, "url": "http://menubuddy.sg/ls-swap-p4psh/lkgvx---curl-in-cylindrical-coordinates-calculator---du3s.html" }
fluid-dynamics, energy-conservation Consider the element of the liquid helium at a height $h$ above the fluid surface and distance $y$ from the wall. To raise that element above the fluid surface costs an energy $mgh$, but because there is a Van der Waals attraction between the helium atoms and the wall you get back an energy $E_{VdW}$. Dzyaloshinskii et al give the energy change per unit mass as: $$ \Delta E = gh - \frac{\alpha}{y^n} $$ where $\alpha$ is constant giving the strength of the Van der Waals attraction and $n$ is in the range 3 - 4 depending on the film thickness. So it is energetically favourable to lift the fluid up the wall if the Van der Waals attraction outweighs the gravitational potential energy making $\Delta E$ negative. Since $y$ can be taken arbitrarily small (well, at least down to a few times the He atom size) $\Delta E$ will be negative for all heights $h$ and the film covers the whole wall. The resulting equation for the film thickness $d$ as a function of height is given (without derivation) as: $$ d \approx \left( \frac{\alpha}{gh} \right)^{1/n} $$ Since the liquid film will have a non-zero thickness at the top of the container wall it can flow over the wall and then down the outside. Even though the film thicknesses work out to be only a few tens of nanometres the zero viscosity of the superfluid helium allows an appreciable flow rate. Indeed, later in the book flow velocities of 30 cm/s are mentioned. In principle this would apply to all fluids, however for normal fluids the flow rate in a film a few tens of nanometres thick would be infinitesimally small so the climbing is never observed.
{ "domain": "physics.stackexchange", "id": 10858, "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": "fluid-dynamics, energy-conservation", "url": null }
navigation, turtlebot, amcl-demo.launch, ros-hydro, amcl Title: turtlebot amcl hydro rapp scenario -- goal position I have a problem with my Turtlebot and amcl, but I don't know exactly how to describe it. I am working on a project that uses programming elements to direct a turtlebot from a remote computer over an internet connection. I use rosbridge server to direct the turtlebot. I can, for instance, perform simple tele-op in this way. I also want to remotely start the gmapping and amcl functions. I can use gmapping to make a map, and then in amcl load the map and even track it on rviz. That is where I have my problem. I can give amcl my start position, and then when I give it the goal position it doesn't go to the new place. I have gone through the turtlebot howto demos online. I can do all the three functions teleop, mapping, and amcl. In the demos in amcl I can set the start position, the goal position, and watch my turtlebot move from one to the other. I have used the launch file from amcl_demo.launch as the basis for my own launch file. In my application there is a central launch file called 'app_manager.launch'. It starts the app manager application. I then launch the amcl launch file as a rapp. This way I can launch an amcl rapp, a gmapping rapp, or a teleop rapp. The topic names for the rapps are all converted to '/app_manager/application/name' where 'name' is the name of the original topic. This means I have to send all my messages to '/app_manager/application/name' not '/name'. The name of my catkin package is 'tele_presence'. (My python code in 'tele_presence' minimal.launch loads maps and saves maps to the mongodb instance...) This is my 'app_manager.launch' file. It's part of my 'tele_presence' package. <launch>
{ "domain": "robotics.stackexchange", "id": 17416, "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": "navigation, turtlebot, amcl-demo.launch, ros-hydro, amcl", "url": null }
Section 2. Calculus Overview. AP Calculus Notes and Videos Videos on YouTube Playlist - Notes PDF - Practice PDF - Practice YouTube Playlist: 1. 750 Chapter 11 Limits and an Introduction to Calculus The Limit Concept The notion of a limit is a fundamental concept of calculus. See more ideas about Calculus, Precalculus and Ap calculus. 4 Calculus: Graphical, Numerical, Algebraic Answers Chapter 2 Limits and Continuity Exercise 2. /6 (a) f(0) (b) o lim ( ) 0 f x x (c) lim f (x) (d) o lim ( ) 0 f x x (e) f( 3) (f) o lim ( ) 3. Derivatives Without a Careful Definition of Limits 46 3. ID: 1 AP Calculus Name_ AP Review: Limits and Continuity Practice Test Date_. Computer programs which will generate numerical evidence for determining a limit. Created by a professional math teacher, BeyondCalculus. The concept of the Limits and Continuity is one of the most crucial things to understand in order to prepare for calculus. 1 Limit of a Function Suppose f is a real valued function de ned on a subset Dof R. DIFFERENTIAL AND INTEGRAL CALCULUS, I i Preliminaries Preparatory reading. Exercise Set 2. 9/24 Short Quiz; Section 2. Calculus Problems for Cutting and Pasting By: Patrick Bourque Chapter The First: Limits and Continuity 1. Calculus Quality Standards Seamless Education Workshop Quality Standard #1: Understand and use the concepts of limits and continuity. Diagrams may be printed and attached to the page. Here you'll find everything you need to know about solving calculus problems involving limits. Mean Value 2. Continuity connotes unity; discreteness, plurality. Shed the societal and cultural narratives holding you back and let free step-by-step Thomas' Calculus textbook solutions reorient your old paradigms. Find out more about limits and some of the terminology we use with them. Calculus of Complex Functions. 2 Calculus: Graphical, Numerical, Algebraic Answers Chapter 2 Limits and Continuity Exercise 2. Calculus Continuity and One-Sided Limits ©Z W2H0b1u5X WK]uCtKaA WSJolfNt[wEaOrHej mLALnCa. Limits, Continuity, IVT Calculus AB Lecture 1 (continuity) Calculus AB Lecture 2 (IVT) Calculus AB Lecture 3 (limits at infinity) Derivatives Derivative Video 1 Derivative Video 2 AB - Derivative Quiz Part 1 AB -
{ "domain": "mpl-bauen.de", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9921841121351556, "lm_q1q2_score": 0.8088607214044506, "lm_q2_score": 0.8152324871074608, "openwebmath_perplexity": 889.8697081744517, "openwebmath_score": 0.7563655376434326, "tags": null, "url": "http://kohq.mpl-bauen.de/calculus-limits-and-continuity-pdf.html" }
c, linked-list | | | | | (25) calling ‘append_sll’ from ‘main’ | +--> ‘append_sll’: events 26-27 | | 58 | void append_sll(int elm) | | ^~~~~~~~~~ | | | | | (26) entry to ‘append_sll’ | 59 | { //O(1) | 60 | Node* cur = create_node(elm); | | ~~~~~~~~~~~~~~~~ | | | | | (27) calling ‘create_node’ from ‘append_sll’ | +--> ‘create_node’: events 28-31 | | 14 | Node* create_node(int elm) | | ^~~~~~~~~~~ | | | | | (28) entry to ‘create_node’ |...... | 17 | if (!node) { return node; } | | ~ ~~~~ | | | | | | | (31) ...to here | | (29) ‘tail’ is NULL | | (30) following ‘true’ branch (when ‘node’ is NULL)... | <------+ | ‘append_sll’: events 32-35 | | 60 | Node* cur = create_node(elm); | | ^~~~~~~~~~~~~~~~ | | | | | (32) returning to ‘append_sll’ from ‘create_node’ | 61 | if (!head) { | | ~ | | | | | (33) following ‘false’ branch... |...... | 64 | tail->next = cur; | | ~~~~~~~~~~~~~~~~ | | | | | | | (35) dereference of NULL ‘tail’ | | (34) ...to here |
{ "domain": "codereview.stackexchange", "id": 44395, "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 }
java, comparative-review, xml, null to nullIfEmpty(xmlObject.getIdentifiers()) != null ... which helps a lot in readability. Edit: one more afterthought. As bowzerfood mentioned nulls and equals in his answer, I'd like to point out additionally, that today you can use Objects.equals(a, b) instead of a.equals(b) which handles nulls correctly and without resorting to third-party libraries.
{ "domain": "codereview.stackexchange", "id": 30904, "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, comparative-review, xml, null", "url": null }
electricity, mean-free-path Title: What does this equation represent? While doing the Franck-Hertz experiment I noticed that I have been asked to write the current as a function of the Mean Free Path as following: $$ I=a\cdot e^{-\frac{b}{\lambda}}$$ I- current $\lambda$ - mean free path a,b some constants that I try to figure out what they represent. So far, by simple dimension analysis, I understand $a$ should be current and $b$ should be length. If anyone can tell me the name of that equation (if there is one) it will be much helpful I'm not sure that it has a particular name in this context. In the context of light moving through an absorbing medium, it's known as the Beer-Lambert law; but more broadly speaking, it's a general property of particles moving through a medium that can scatter them. Similar equations exist for x-ray transmission and neutron transmission, and I'm not sure there's a specific name for those equations either.
{ "domain": "physics.stackexchange", "id": 76822, "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": "electricity, mean-free-path", "url": null }
$\begin{equation*} \begin{split} 57 \div& 2 (1)\\ 28 \div& 2 (0)\\ 14 \div& 2 (0)\\ 7 \div& 2 (1)\\ 3 \div& 2 (1)\\ 1 \div& 2 (1) \end{split} \end{equation*}$ By extracting all the remainders of the divisions we get the binary representation of the decimal number. The remainder of the first division represents the first bit (from right). By putting all the remainders on next to another we get the binary representation of the decimal number: $\begin{equation*} \begin{split} 111001 \end{split} \end{equation*}$ Finally, the representation of 57 in binary format is: $\begin{equation*} \begin{split} 57_{10} = 111001_{2} \end{split} \end{equation*}$ Obviously we got the same result as with Method 1. If we need to represent the decimal number on 8 bits we only need to fill up the left side of the binary representation with 0 until we have a total of 8 bits: $\begin{equation*} \begin{split} 57_{10} = 00111001_{2} \end{split} \end{equation*}$ #### Scilab: using while loop The Scilab script below coverts a given decimal number decNo into a binary number binNo using the division by 2 method into a while loop: // Decimal number to be converted decNo = 57; // Display decimal number mprintf("Decimal: %d",decNo) // Binary string initialization binNo = []; // While loop while (decNo >= 1) remNo = modulo(decNo,2); // calculate remainder decNo = floor(decNo/2); // divide by 2 and keep integer if remNo binNo = ['1' binNo]; // if remainder is 1 add 1 to string else binNo = ['0' binNo]; // if remainder is 0 add 0 to string end end
{ "domain": "x-engineer.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9859363725435203, "lm_q1q2_score": 0.8128670052444257, "lm_q2_score": 0.8244619306896955, "openwebmath_perplexity": 1267.3689058240066, "openwebmath_score": 0.7052956819534302, "tags": null, "url": "https://x-engineer.org/undergraduate-engineering/mathematics/arithmetics/decimal-to-binary-conversion/" }
human-biology, sensation Title: Why can you not tickle yourself? It's the age old question, why can't we tickle ourselves? If you rub your fingers along your skin, sure there's sensation but you don't break down into a laughing fit (at least I don't :P), if someone else does it to you, you're rolling around on the ground begging them to stop tickling you. Why is it that other people can tickle us but we can't tickle ourselves by touch? (I'm aware that if you use a feather or foreign object on yourself you can be tickled by it so that doesn't count.) In short, it's because your brain processes external and self-produced stimuli differently. If someone tickles you, you feel that ticklish feeling, but when trying to tickle yourself, there is a reduction in the sensation. When you are tickled by someone, a part of your brain activates causing you to laugh, etc., but it seems that when you trying tickling yourself, your brain doesn't react the same way and that section of the brain does not activate as if someone were tickling you. Blakemore, S.J., D.M. Wolpert, and C.D. Frith. 1998. Central cancellation of self-produced tickle sensation. Nature Neuroscience 1(7): 635–640. doi:10.1038/2870
{ "domain": "biology.stackexchange", "id": 8733, "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": "human-biology, sensation", "url": null }
quantum-mechanics, harmonic-oscillator, fermions Title: How fermions arrange themseves when there are more allowed states than particles in the system? I'm considering the problem of three fermions in a system where spin is considered and there are two possible orbital wavefunctions, $\phi_{1}$ and $\phi_{2}$. This amounts to a problem with three particles in a four-state system. In this case, we can have two fermions in the same orbital state with opposite spins and the remaining fermion in the remaining orbital state with one of two possible spins. There are four ways to do this: $ \phi_{1+}\,\,\phi_{1-}\,\,\phi_{2+} \\ \phi_{1+}\,\,\phi_{1-}\,\,\phi_{2-} \\ \phi_{1+}\,\,\phi_{2+}\,\,\phi_{2-}\\ \phi_{1-}\,\,\phi_{2+}\,\,\phi_{2-}$ We can build a Slater determinant with each line and coordinates $r_1,\,r_2,$ and $r_3 $, obtaining then all four possible antisymmetrical wavefunctions. Now, if $E_{i}$ is the energy associated to the state $\phi_{i}$ and if $E_{1}<E_{2}$ how will the fermions distribute themselves? If we're considering three fermions in a harmonic oscillator-like potential we say that the fermions will fill the ground state before occupying the levels with greater energy, so only the first two lines would be possible, but why? Why do they have to fill the ground state? Couldn't one of them be so energetic it jumps to the next level, leaving a hole in the ground state? Does it have to do with the probability of the wavefunctions generated by the first two lines?
{ "domain": "physics.stackexchange", "id": 41181, "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, harmonic-oscillator, fermions", "url": null }
machine-learning, deep-learning, gradient-descent In the case of a feed-forward network, each layer's processing is independent from the next, so you only have a complex rule to follow if you have a complex layer. You can write the back propagation equations down so that they relate gradients in one layer to the already-calculated gradients in the layer above (and ultimately to the loss function evaluated in the output layer). It doesn't directly matter what the activation function was in the output layer after you backpropagate the gradient from it - at that point the only difference is numeric, the equations relating deeper layer gradients to each other do not depend on the output at all. Finally, if you want to just use a neural network library, you don't need to worry much about this, it is usually just done for you. All the standard activation functions and layer architectures are covered by existing code. It is only when creating your own implementations from scratch, or when making use of unusual functions or structure, that you might need to go as far as deriving the values directly.
{ "domain": "datascience.stackexchange", "id": 1135, "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, gradient-descent", "url": null }
java Documentation! And a README. Try to avoid class names starting with Set in the future in order to avoid setter starting with setSet which hurt the eyes. It's not worth refactoring that. Some fields, like Game.ocean, aren't encapsulated. catch(Exception e) { e.getCause(); } has no effect and most likely leads to useless An error occured messages at the end of the development cycle. If you don't pass on an exception, but catch it you need to handle it, throw a RuntimeException or inform an online service like sentry.io about it. try-catch(Exception) is almost never right... Your project has no pom.xml, but IDE-related files in .idea. I'd provide a command-line based cross-platfrom, cross-IDE build command as early as possible in order to make is as easy as possible for others to build and run your project. Your questions: I don't see dependency injection in your code. Use a FLOSS framework following Java specification for it, that's why there're there. public abstract class SetOnOceanBase implements SetOnOcean { ... private final boolean horizontally; //only expose to subclasses' constructors @Override public void setShip(int x, int y, MaritimeElement ship) throws SpecificException { for (int i = 0; i < ship.val(); i++) { if(horizontal) { ... x y coordinate stuff }else { ... } ocean.setMaritime(xCoordinate, yCoordinate, ship); ocean.setShipsPlaced(xCoordinate,yCoordinate); } } } Abstracting interfaces is neat, but if you do it for anything you touch you quickly get into a YAGNI logic, especially when it comes to data containers (which roughly spoken shouldn't implement interfaces), so do it for new stuff if you can think of a use case for the interface within 5 seconds - my rule of thumb for hobby projects without technical specification and sophisticated class diagram. Later, the extraction of an interface is only one or two clicks in any modern IDE.
{ "domain": "codereview.stackexchange", "id": 25751, "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", "url": null }
c++, reinventing-the-wheel, vectors *ret = std::move(std::forward<Args>(args_)...); if (size() * 2 >= capacity()) reserve(capacity() * m_growing_rate); return ret; } template <class Allocator> constexpr typename vector<bool, Allocator>::iterator vector<bool, Allocator>::insert(const_iterator pos_, const bool &val_) { iterator ret = const_cast<iterator>(pos_); ++m_size; std::move_backward(ret, end() - 1, end()); *ret = val_; if (size() * 2 >= capacity()) reserve(capacity() * m_growing_rate); if (empty()) { *begin() = val_; ++m_size; return begin(); } return ret; } template <class Allocator> constexpr typename vector<bool, Allocator>::iterator vector<bool, Allocator>::insert(const_iterator pos_, bool &&val_) { iterator ret = const_cast<iterator>(pos_); ++m_size; std::move_backward(ret, end() - 1, end()); *ret = std::move(val_); if (size() * 2 >= capacity()) reserve(capacity() * m_growing_rate); if (empty()) { *begin() = std::move(val_); ++m_size; return begin(); } return ret; } template <class Allocator> constexpr typename vector<bool, Allocator>::iterator vector<bool, Allocator>::insert(const_iterator pos_, size_type count_, const bool &val_) {
{ "domain": "codereview.stackexchange", "id": 35177, "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++, reinventing-the-wheel, vectors", "url": null }
ros Originally posted by Handwerker with karma: 51 on 2016-02-08 This answer was ACCEPTED on the original site Post score: 0 Original comments Comment by haley on 2022-03-24: No, OP is publishing /turtle1/cmd_vel to move the turtle, then trying to subscribe to /turtle1/pose to see where the turtle is! I have the same problem. I've changed the name of the topic to /turtle1/pose, but no luck.
{ "domain": "robotics.stackexchange", "id": 23667, "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 }
signal-power, signal-energy So we have $$\begin{align}\sum_{n=-\infty}^{\infty}e^{-|t-n|}&=\sum_{n=1}^{\infty}e^{t-n}+\sum_{n=-\infty}^{-1}e^{n-t}+e^{-t}\\&=\left(e^t+e^{-t}\right)\sum_{n=1}^{\infty}e^{-n}+e^{-t}\\&=\frac{e^t+e^{-t}}{e-1}+e^{-t},\qquad 0\le t\le 1\tag{3}\end{align}$$ Using $(3)$ we can compute $P_x$ by solving an elementary integral: $$P_x=\int_0^1\left[\frac{e^t+e^{-t}}{e-1}+e^{-t}\right]^2dt\approx 4.0053\tag{4}$$ We can cross-check our result by using another way to compute $P_x$. From Parseval's identity for Fourier series we know that $$P_x=\sum_{k=-\infty}^{\infty}|c_k|^2\tag{5}$$ where $c_k$ are the complex Fourier coefficients of $x(t)$. Using Poisson's sum formula we get $$\sum_{n=-\infty}^{\infty}g(t-nT)=\frac{1}{T}\sum_{k=-\infty}^{\infty}G\left(\frac{2\pi k}{T}\right)e^{j2\pi kt/T}\tag{6}$$
{ "domain": "dsp.stackexchange", "id": 11474, "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": "signal-power, signal-energy", "url": null }
$$\ell ^{-1} \{ F(P)\} = \ell ^{-1} \left\{ \frac{1}{2}\left[ \frac{-1+i}{P-(-2-3i)}-\frac{1+i}{P-(-2+3i)}\right] \right\}$$ $$= \frac{1}{2} \ell ^{-1} \left\{ \frac{-1+i}{P-(-2-3i)} \right\} -\frac{1}{2} \ell ^{-1} \left\{ \frac{1+i}{P-(-2+3i)}\right\}$$ $$= \frac{-1+i}{2} \ell ^{-1} \left\{ \frac{1}{P-(-2-3i)} \right\} -\frac{1+i}{2} \ell ^{-1} \left\{ \frac{1}{P-(-2+3i)}\right\}$$ $$= \frac{-1+i}{2} e^{(-2-3i)t} -\frac{1+i}{2} e^{(-2+3i)t} = \frac{-1+i}{2} e^{-2t}e^{-3it} -\frac{1+i}{2} e^{-2t}e^{3it}$$ $$= \frac{e^{-2t}}{2}\left[ (-1+i) e^{-3it} -(1+i)e^{3it}\right] = \frac{1}{2}e^{-2t}\left[ -(e^{3it} +e^{-3it}) -i(e^{3it} -e^{-3it}) \right]$$
{ "domain": "physicsforums.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9830850877244272, "lm_q1q2_score": 0.8316333913730006, "lm_q2_score": 0.8459424334245618, "openwebmath_perplexity": 2979.0392609458527, "openwebmath_score": 0.8311225771903992, "tags": null, "url": "https://www.physicsforums.com/threads/the-laplace-transform-inverse.113177/" }
php, beginner, wordpress I've always gotten the hebejeebies when I see string concatenation like this. Please, separate it out into a function, with clear type-hints (if possible), and don't access properties using string constants the way you do. I'd simply write this: function getUrlFromObject(stdClass $obj, $id) { $url = '<a id="' . $id . '" slug="' . $obj->slug . '" class="listing-links-cat" ' . 'href="#" title="' . $obj->name . '" >' . $obj->name . '</a>'; return $url; } //call like so, inside the foreach $url = getUrlFromObject($thisCat, $termCategory); Well, since you've asked us not to go too technical, I've kept the string concatenation business like you're using, but just in case you want to look into something new, I'd actually use sprintf here, I think, or an actual DOM parser/builder (like DOMDocument or SimpleXMLElement). Anyway, here's the sprintf version: function getUrlFromObject(stdClass $obj, $id) { return sprintf( '<a id="%s" slug="%s" class="listing-links-cat" href="#" title="%s">%3$s</a>', $id, $obj->slug, $obj->name ); } To my eye at least, that looks a lot cleaner than what you have now, but that might be a matter of personal preference, just like your adding spaces between a variable and the postfix-increment operator: $i ++;
{ "domain": "codereview.stackexchange", "id": 13280, "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, beginner, wordpress", "url": null }
For now, we'll consider just the circle about $A_0$. Let $M$ be the midpoint of $\overline{BC}$ (and therefore also the foot of the perpendicular from $A_0$). Drop a perpendicular from $A_0$ to $\overline{AB}$ at $X$, and let $P$ be the point where this perpendicular crosses $\bigcirc A_0$. Finally, let $I$ be the incenter of $\triangle ABC$, so that $\overline{IA}$ and $\overline{IC}$ bisect $\angle A$ and $\angle C$. • Since $\angle BAA_0$ and $\angle BCA_0$ subtend the same arc $\stackrel{\frown}{A_0B}$ of the circumcircle, they are congruent. • By the Exterior Angle Theorem applied to $\angle I$ of $\triangle IAC$, we have $$\angle CIA_0 = \color{blue}{\angle IAC} + \color{red}{\angle ICA} = \color{blue}{\angle BCA_0} + \color{red}{\angle ICB} = \angle ICA_0$$ so that $\triangle A_0CI$ is isosceles, with $\color{violet}{\overline{A_0C}}\cong\color{violet}{\overline{A_0I}}$.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9805806518175514, "lm_q1q2_score": 0.8128413507648548, "lm_q2_score": 0.8289388019824946, "openwebmath_perplexity": 200.07026179590707, "openwebmath_score": 0.8989614248275757, "tags": null, "url": "https://math.stackexchange.com/questions/1065981/geometry-problem-about-tangent-lines" }
11 juillet 2020, par Nadir Soualem. The order of selection of items not considered. The following are the common definitions of Binomial Coefficients.. A binomial coefficient C(n, k) can be defined as the coefficient of x^k in the expansion of (1 + x)^n.. A binomial coefficient C(n, k) also gives the number of ways, disregarding order, that k objects can be chosen from among n objects more formally, the number of k-element subsets (or k-combinations) of a n-element set. }}{{k!\left( {n - k} \right)!}} Identifying Binomial Coefficients. Toutes les versions de cet article : Le coefficient binomial est le nombre de possibilités de choisir k élément dans un ensemble de n éléments. Also, the text size of the fraction changes according to the text around it. Binomial coefficient denoted as c(n,k) or n c r is defined as coefficient of x k in the binomial expansion of (1+X) n.. b is the same type as n and k. If n and k are of different types, then b is returned as the nondouble type. A slightly different and more complex example of continued fractions, Showing first {{hits.length}} results of {{hits_total}} for {{searchQueryText}}, {{hits.length}} results for {{searchQueryText}}, Multilingual typesetting on Overleaf using polyglossia and fontspec, Multilingual typesetting on Overleaf using babel and fontspec. n! Ak n = n! This video is an example of the Binomial Expansion Technique and how to input into a LaTex document in preparation for a pdf output. (−)!. The binomial coefficient $\binom{n}{k}$ can be interpreted as the number of ways to choose k elements from an n-element set. Below is a construction of the first 11 rows of Pascal's triangle. (n - k)!} The combination (n r) (n r) is called a binomial coefficient. (n - k)!} formulas, graphs). You can set this manually if you
{ "domain": "org.ua", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9669140177976359, "lm_q1q2_score": 0.8237651030905572, "lm_q2_score": 0.8519527982093666, "openwebmath_perplexity": 1074.9410209736775, "openwebmath_score": 0.9310876131057739, "tags": null, "url": "http://consumerinfo.org.ua/e3vnu03/binomial-coefficient-latex-0861fc" }
Try using $$p(x) = -x^2 + a_1 x + a_0.$$ Taking the first coefficient to be $-1$ (or any other negative number) ensures that the parabola is concave down. Then one just needs to solve the equations $$p(x_1) = y_1 \qquad \text{and} \qquad p(x_2) = y_2$$ for $a_1$ and $a_0$, yielding $$a_0 = \frac{x_1 x_2^2 - x_1^2 x_2 + x_1 y_2 - x_2 y_1}{x_1 - x_2},$$ $$a_1 = \frac{x_1^2 - x_2^2 + y_1 - y_2}{x_1-x_2}.$$ Suppose that $y_2>y_1$ and $x_1\neq x_2$. Note that this is not too burdensome; if $x_1=x_2$ there is no solution; if $y_2<y_1$ you reverse the two points; if $y_2=y_1$ it's not too hard to solve. Then consider $$y=-a(x-x_2)^2+b$$ You now choose $a,b$ to pass through the two points you want. To pass through $(x_2,y_2)$ you need $b=y_2$. To pass through $(x_1,y_1)$ you need $y_1=-a(x_1-x_2)^2+y_2$, which rearranges to $$a=-\frac{y_1-y_2}{(x_1-x_2)^2}$$ Since $y_2>y_1$, we must have $a>0$ so it is indeed a parabola, and points downward.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9830850877244272, "lm_q1q2_score": 0.8082818735052422, "lm_q2_score": 0.8221891305219504, "openwebmath_perplexity": 174.12232100928725, "openwebmath_score": 0.7306217551231384, "tags": null, "url": "https://math.stackexchange.com/questions/804460/fitting-a-quadratic-polynomial-to-two-points-such-that-it-is-always-concave-down" }
localization, imu, navigation, 3d-navigation, position Title: ROS compatibility for accurate UWB positioning sensor [discussion] Hello, my name is Samuel and I am one of the creators of Pozyx, an indoor positioning system that I would like to make ROS compatible. Our system is currently running on kickstarter. We are using ultra-wideband (UWB) radio signals to accurately measure the distances to some anchors for positioning (the signals can pass through walls or objects). This allows us to accurately estimate the position indoor. We have recently achieved our funding goal and as a stretch goal we are going to make sure the system is ROS compatible. By means of this post I would like to know what kind of functionalities should be supported by the Pozyx platform to make it compatible for ROS? Some more information about the platform: The tag is equipped with an UWB transceiver, a gyroscope, accelerometer, magnetometer and pressure sensor. The onboard microcontroller (STM32F4) is in charge of the ranging protocol, messaging protocol, the tracking algorithm, sensor fusion, anchor calibration and all the other stuff to make the board act like a sensor: communication, configuration, etc. Any input would be much appreciated. Thanks Originally posted by Samuel on ROS Answers with karma: 11 on 2015-06-19 Post score: 1 Original comments Comment by NicoNie on 2017-09-18: Hi Samuel, I am very interested in your Pozyx project, can I have your Email for more details, my email is "nozeroxue@gmail.com". Comment by Filippo on 2020-04-09: Hi @Samuel, can you please share your driver? I'm also using an UWB sensor but I don't know how to use the data that I received in localization package Have you thought about how you actually want to integrate with a ROS node graph (ie: communicate with the master and other nodes)? rosserial or any of the other minimal bridging approaches come to mind. Two options you might want to look at are cROS and the work Bosch is doing for the STM32F4. The former is a 'full' ROS client library implementation in C, while the latter is more rosserial inspired.
{ "domain": "robotics.stackexchange", "id": 21966, "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": "localization, imu, navigation, 3d-navigation, position", "url": null }
a shaft length of 5 m as well as the minimum shear stress in the shaft (G = 84 GPa). Express the inner radius to three. • Shear stress (ordinate) vs. torsion of shafts When a cylindrical shaft is subjected to equal and opposite couples at the ends, either it will be in equilibrium or it will rotate at a uniform rate. more or less constant value of shear stress. T = 15 lb-in. Since the secondary shear Forces are equal we have. Mohr’s Circle for Plane Stress. Maximum torque in the shaft is 1,000 in-lb. In general K will be greater than 1. If the maximum shearing stress allowed in the shaft is 80 N/mm 2 and the ratio of inner. In order to calculate maximum surface stress, you must know the bending moment, the distance from the neutral axis to the outer surface where the maximum stress occurs and. 52 inches Applied torque, T = 2238 in-lbs Material = 1026 DOM steel tubing. How much torque can be applied to a shaft of circular cross section. The stiffness of close coiled helical spring is 1. The expression for shear deformation is $\displaystyle\Delta{x}=\frac{1}{S}\frac{F}{A}L_0$, where S is the shear modulus (see Table 1) and F is the force applied perpendicular to L 0 and parallel to the cross-sectional area A. Two circular disks A and B are welded to the ends of both bars. Q23: A hollow shaft of diameter ratio is required to transmit 600 kW at 110 rpm, the maximum torque beam is 20% greater than mean shear stress is not to exceed 63 MN/m 2 and the twist in a length of 3 m not to exceed 1. The shear stress distribution in a hollow shaft is still linear, but it now starts at some non-zero value on the inner radius, and increases (linearly) to the maximum value on the outer radius. twice the inside dia. PROBLEM 08 – 0277: In the I-beam shown, compute the maximum shear stress and the total shear stress at the indicated point. The recommended design procedure for circular shafts is as follows: Define all loads on the shaft. Shaft torsional shear stress: Ss (lbf/in 2) = T*R / J. Basic Stress Equations Dr. Find the size of the
{ "domain": "foresteria-lacura.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9744347868191549, "lm_q1q2_score": 0.8141242283557442, "lm_q2_score": 0.8354835432479663, "openwebmath_perplexity": 1072.6670445682296, "openwebmath_score": 0.7154282927513123, "tags": null, "url": "http://foresteria-lacura.it/rjry/maximum-and-minimum-shear-stress-in-hollow-circular-shaft.html" }
a Coordinate Plane Draw a right triangle with legs of 3 units and 4 units on a piece of 13. 7 Triangles and Coordinate Proof A coordinate proof involves placing geometric figures in a coordinate plane. parallelogram with side length b units 2. a. Auxiliary line: an extra line or segment drawn in a figure to help analyze geometry relationships. Draw a line A square 5. Use a coordinate proof to show that ∆ is an isosceles triangle. 7 Triangles and Coordinate Proof. Use dynamic geometry software to draw AB — with endpoints A(0, 0) and B(6, 0). 5-5 Indirect Proof and Inequalities in One Triangle Isosceles triangle ABC is similar to a isosceles triangle ADE what is the length of DE, which is the base part . 2. Position and label each triangle on the coordinate plane. Distance PQ = [(4+6)^2+(38–14)^2]^0. Chapter Resources: Parents Guide for Student Success (pdf) Audio Summaries isosceles triangle. And that just means that two of the sides are equal to each other. The vertex of an isosceles triangle is on the perpendicular bisector of the base. rectangle 3. B. units long and leg LV b units long $16:(5 triangle. Also reflect on the mathematical practices you used when working on this task. Prove that PAT is an isosceles triangle. isosceles trapezoid with height b units, and height a units bases 2c a units and 2c a units Name the missing coordinates for each quadrilateral. The most common Expected Learning Outcomes The students will be able to: 1) Use the Base Angles Theorem and its converse. In an isosceles And since this is a triangle and two sides of this triangle are congruent, or they have the same length, we can say that this is an isosceles triangle. Base angles theorem The base angles theorem states that if the sides of a triangle are congruent (Isosceles triangle)then the angles opposite these sides are congruent. (How? Remember, the main thing with isosceles triangles is that the base angles are congruent to each other. Place LB at the origin and place the legs along the positive x- and y-axes. Chapter 4 Study guide Numeric Response 1. Use properties of equilateral triangles. Essential Question
{ "domain": "sumcoop.com", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9896718496130619, "lm_q1q2_score": 0.8068126433802972, "lm_q2_score": 0.8152324871074607, "openwebmath_perplexity": 587.6750757794822, "openwebmath_score": 0.685784101486206, "tags": null, "url": "http://sumcoop.com/o2jobnra/coordinate-proof-isosceles-triangle.html" }
ros, pr2 Title: PR2 simulation not working ROS Hydro So I ran: roslaunch gazebo_ros empty_world.launch to start Gazebo in an empty world. The gazebo window pops up but the terminal stops at this: gazebo/set_physics_properties] has not been advertised, waiting... Msg Connected to gazebo master @ http://127.0.0.1:11345 Msg Publicized address: 10.0.0.9 [ INFO] [1456083864.004714895, 0.024000000]: waitForService: Service [/gazebo/set_physics_properties] is now available. [ INFO] [1456083864.126850646, 0.140000000]: Physics dynamic reconfigure ready. Msg Connected to gazebo master @ http://127.0.0.1:11345 Msg Publicized address: 10.0.0.9 Even after waiting for awhile, the terminal seems to be stuck at this point and does not allow me to type any commands. I've tried redoing the command multiple but it keeps stopping at the same point. Originally posted by meep on ROS Answers with karma: 1 on 2016-02-21 Post score: 0 roslaunch does not return control of the terminal until all of the nodes in the roslaunch file exit, and gazebo does not usually accept input from the command line. In short, it sounds like gazebo is working. Are you able to interact with the gazebo window that pops up? What else do you expect it do? Originally posted by ahendrix with karma: 47576 on 2016-02-21 This answer was ACCEPTED on the original site Post score: 1 Original comments Comment by meep on 2016-02-21: Yes thank you I figured it out. New to ros sorry.
{ "domain": "robotics.stackexchange", "id": 23857, "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, pr2", "url": null }
physical-chemistry, quantum-chemistry, electronic-configuration Question Now I know the possible term symbols, but I'm not sure, which microstates belong to them specifically. It's clear, that microstates 13 and 15 will belong to ${}^1D$, but how can I determine it for the other states? ${}^1D$ should contain 3 more microstates with $S=0$ and $m_L$ being equal to -1, 0 and +1, but there are multiple candidates for every configuration. So how could I distinguish between, e.g. microstates 7 and 9 or 8, 11 and 14? I don't understand this point, as even $J=2$ for ${}^1D$, so it can't be used to distinguish among the "similar" microstates and to assign them properly. To add on to what Feodoran has mentioned, you might be interested in looking at the Clebsch–Gordan coefficients, which are essentially the coefficients of the microstates in the term symbols. You can look these up in e.g. the appendices of Atkins Molecular Quantum Mechanics, 5th ed. Note that each term symbol is a collection of states, so a $D$ term (for example) which has $L = 2$ would comprise five states: one each with $M_L = -2, -1, 0, +1, +2$. These five states can in general be denoted as $|L, M_L\rangle$. $L$, which is a total angular momentum, is obtained by a coupling of two individual angular momenta. For two electrons in p-orbitals, these individual angular momenta are $l_1 = 1$ (with $m_{l1} = -1, 0, +1$) and $l_2 = 1$ (with $m_{l2} = -1, 0, +1$). The microstates in the table specify both values of $m_{l1}$ and $m_{l2}$, so they are simultaneous eigenstates of $m_{l1}$ and $m_{l2}$, i.e. they can be denoted by $|m_{l1},m_{l2}\rangle$.
{ "domain": "chemistry.stackexchange", "id": 10991, "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": "physical-chemistry, quantum-chemistry, electronic-configuration", "url": null }
ros, callback, image-transport Title: Notification when tf topic is subscribed to? I'm working on camera based visual odometry node that publishes /tf transforms when fiducial tags are present within a camera image. As the image process is somewhat computationally heavy, I would only like to process images only when there is a subscriber that cares about the transforms from my node. The ImageTransport infrastructure provides a connectCallback mechanism for accomplishing this where client nodes subscribe to an image. However, I don't see there is a similar connect callback mechanism for the TransformBroadcaster which I'm using to send transforms. I presume this is because there is no way to tell when transforms a subscriber to /tf really cares about. Is there a recommended way of accomplishing this? I presume I could create a service that clients can use to manually enable/disable image processing, but I was hoping for something a bit more automatic. Originally posted by mpthompson on ROS Answers with karma: 153 on 2014-07-09 Post score: 0 How about you make the odometry transform a service? This way, it would only run when the service is called. Originally posted by allenh1 with karma: 3055 on 2014-07-09 This answer was ACCEPTED on the original site Post score: 0
{ "domain": "robotics.stackexchange", "id": 18570, "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, callback, image-transport", "url": null }
reaction-control Title: Relationship between Productivity and Yield I am trying to formulate an optimization problem. Can you help me understand the definition of productivity and yield? Why is there a trade-off between them during the reaction? Thanks in advance. Depending on your application and the specifics, to keep it simple. . . Yield: The amount of product obtained in a chemical reaction Productivity: The rate of speed a product can be obtained in a chemical reaction For the compromise, as vague example, perhaps the more of the product you want to yield, the more time it may take thus a longer productivity you'll have.
{ "domain": "chemistry.stackexchange", "id": 4328, "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": "reaction-control", "url": null }
electricity, electrons, voltage, batteries, electrochemistry Title: How batteries create voltage? I am trying to have a more fundamental understanding of electricity and specifically what voltage is. My memory of highschool physics was that a battery has an excess of electron on one terminal, and a shortage on the other. This explanation caused some confusion when I thought about batteries in series; why does two 1,5V batteries add to 3V. If it is excess and shortage of electrons, created from a chemical reaction, that attract the electrons from cathode to anode, wouldn't the volt (J/C) be the same for a circuit with two batteris; every electron in the cathode has one void to fill in the anode? Some reading lead me to see battery voltage as a measurement of how much energy per electron (J/C) the chemical reaction produces, and the number of reactions per second as the current (C/s). I know 1 coulomb is not 1 electron, and one reaction doesn't necessarily = 1 free electron, this is a rough picture in my mind. Does this mean that it is the energy released from the reaction that is accelerating the electron a certain amount depending on the amount of energy, and how is it that two batteries accelerate the electron twice as much? This is my first attempt at articulation my confusion, so I'm sorry that this is not as eloquent as it could be Voltage (up to a factor) is the work one electron can produce when travelling from anode ($-$) to cathode ($+$). Current is the number of electrons flowing. The energy needed to do the work comes from the energy released when electron participates in the reaction happening at cathode. This is chemistry-specific, so one cell of a battery has usually a very specific voltage. Now imagine what happens if you have two cells in series. When, electron travels from A2 to C1 it produces work $W$ and when it reaches $C1$ it releases energy $U$. But at the same time, it allows another electron to travel from $A1$ to $C2$ and release another chunk of energy $U$. So in the end, $W=U+U=2U$ and we say that two cells in series have twice as large voltage, meaning for every electron participating in outer current, there is now twice as many reactions.
{ "domain": "physics.stackexchange", "id": 82577, "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": "electricity, electrons, voltage, batteries, electrochemistry", "url": null }
After seeing Henno’s comment I tracked down the relevant paper by Sierpiński. Wacław Sierpiński, ‘Fonctions additives non complètement additives et fonctions non mesurables’, Fundamenta Mathematicae $\mathbf{30}$, $96$-$99$ ($1938$), essentially proves the result. Specifically, he shows that if there is a finitely additive, $\{0,1\}$-valued function on $\wp(\Bbb Z^+)$ that is not countably additive, then there is a $\{0,1\}$-valued function on $\Bbb R$ that is not Lebesgue measurable. Note that a function $f:\wp(\Bbb Z^+)\to\{0,1\}$ that is finitely additive but not countably additive defines a free ultrafilter $\mathscr{U}_f=\{U\subseteq\Bbb Z^+:f(U)=1\}$ on $\Bbb Z^+$, and conversely, a free ultrafilter $\mathscr{U}$ on $\Bbb Z^+$ defines such a function $f_{\mathscr{U}}$ by $f_{\mathscr{U}}(U)=1$ iff $U\in\mathscr{U}$. Thus, he shows in effect that if there is a free ultrafilter on $\Bbb Z^+$, then there is a non-measurable $\{0,1\}$-valued function on $\Bbb R$, and it follows easily from the construction that $\mathscr{U}$ is not measurable in the Cantor space. His argument, translated into English and modern notation, is as follows.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9830850857421198, "lm_q1q2_score": 0.8149173836080952, "lm_q2_score": 0.8289388125473628, "openwebmath_perplexity": 114.47975874315784, "openwebmath_score": 0.9285312294960022, "tags": null, "url": "https://math.stackexchange.com/questions/1130615/non-measurability-of-ultrafilter-on-omega" }
javascript, jquery, html5 Title: HTML5 Local Storage toggle and save multiple classes I put together a code will allow me to toggle a class and save it in local storage. Now I need to add 2 more classes to be toggled and be saved in the same manner. I don't know how to iterate properly with the code and the DOM to achieve this. This is my "semi-working" example: http://jsbin.com/nimekebura/1/edit?html,css,js,output HTML: <a href="javascript:void(0)" class="bar-toggle">toggle and save state</a> <div class="container"> <div class="box"></div> <div class="box"></div> </div> <hr /> <div class="container"> <div class="box"></div> <div class="box"></div> </div> <hr /> <div class="container"> <div class="box"></div> <div class="box"></div> </div> <hr /> <div class="container"> <div class="box"></div> <div class="box"></div> </div> JS: //retrieve current state $('.container').toggleClass(localStorage.toggled); /* Toggle */ $('.bar-toggle').on('click',function(){ // set 1 localstorage values are always strings (no booleans) if (localStorage.toggled != "with_toggle" ) { $(".container").toggleClass("with_toggle", true ); localStorage.toggled = "with_toggle"; } else { $(".container").toggleClass("with_toggle", false ); localStorage.toggled = ""; } });
{ "domain": "codereview.stackexchange", "id": 22598, "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, jquery, html5", "url": null }
= \frac{n^{\underline{k}}}{k! Corollary 1.4. We present some identities that have combinatorial proofs. share | cite | improve this question | follow | edited May 19 at 15:42. Binomial Expansion. The binomial coefficients satisfy the identities: (5) (6) (7) Sums of powers include (8) (9) (10) (the Binomial Theorem), and (11) where is a Hypergeometric Function (Abramowitz and Stegun 1972, p. 555; Graham et al. In mathematics, the binomial coefficients are the positive integers that occur as coefficients in the binomial theorem.Commonly, a binomial coefficient is indexed by a pair of integers n ≥ k ≥ 0 and is written $\tbinom{n}{k}. Identities involving binomial coefficients. The binomial coefficient is the multinomial coefficient (n; k, n-k).$ It is the coefficient of the x k term in the polynomial expansion of the binomial power (1 + x) n, and it is given by the formula Saslaw, W. C. "Some Properties of a Statistical Distribution Function for Weisstein, Eric W. "Binomial Identity." Astrophys. Every regular multiplicative identity corresponds to an RMI-diagram. enl. Unlimited random practice problems and answers with built-in Step-by-step solutions. In general, a binomial identity is a formula expressing products of factors as a sum over terms, each including a binomial coefficient (n; k). Each of these is an example of a binomial identity: an identity (i.e., equation) involving binomial coefficients. We have, for example, for The combinatorial proof goes as follows: the left side counts the number of ways of selecting a subset of of at least q elements, and marking q elements among those selected. For Nonnegative Integers and with , (12) Taking gives (13) Another identity is (14) (Beeler et al. The first proof will be a purely algebraic one while the second proof will use combinatorial reasoning. The binomial coefficients satisfy the identities: (5) (6) (7) Sums of powers include (8) (9)
{ "domain": "sancakpalas.com", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9481545333502202, "lm_q1q2_score": 0.8441365106529677, "lm_q2_score": 0.890294230488237, "openwebmath_perplexity": 1172.5914922798875, "openwebmath_score": 0.964695394039154, "tags": null, "url": "https://sancakpalas.com/desserts-of-sema/dwf3h.php?538c60=binomial-coefficient-identities" }
type-theory, functional-programming, typed-lambda-calculus, parametricity Then we obtain the following condition: For any $p: (a \to a)\to a$ and $q: (b \to b)\to b$ that are in relation $s$, we will have $f(\phi\,p) = \phi q$. The relation $s$ is defined by: $p: (a \to a)\to a$ and $q: (b \to b)\to b$ are in $s$ if, for any $i: a\to a$ and $j: b\to b$ such that $f . i = j . f$, we will have $f(p (i)) = q(j)$. This condition is somewhat simpler but I am still not able to use it to prove that any function $\phi: T$ is always of the form $\lambda\,p.\,p\,\mathrm{id}$. (That would be to prove that $T \cong\mathbb1$.) I claim that $T \cong \mathbb 1+\mathbb2+\mathbb3\,+\,…$. I will prove the type equivalence and then show what terms of type $T$ correspond to values of type $\mathbb 1+\mathbb2+\mathbb3\,+\,…$ The main idea is to transform $T$ to an equivalent type formulated as a Church encoding of the least fixpoint of some covariant type constructor, and then to simplify that fixpoint. Step 1: use Yoneda The contravariant Yoneda identity looks like this: if $G$ is a contravariant functor then: $$ G \, b \cong \forall r. (r \to b) \to G\, r $$ Use this identity with $G\, r = ((r \to b) \to b) \to b $ (considering $b$ to be a fixed type). We get: $$ G\, b = ((b \to b) \to b) \to b \cong \forall r.\, (r \to b) \to ((r \to b) \to b) \to b $$
{ "domain": "cstheory.stackexchange", "id": 5762, "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": "type-theory, functional-programming, typed-lambda-calculus, parametricity", "url": null }
c#, tic-tac-toe } private void button10_Click(object sender, EventArgs e) { button1.Text = ""; button1.Enabled = true; button2.Text = ""; button2.Enabled = true; button3.Text = ""; button3.Enabled = true; button4.Text = ""; button4.Enabled = true; button5.Text = ""; button5.Enabled = true; button6.Text = ""; button6.Enabled = true; button7.Text = ""; button7.Enabled = true; button8.Text = ""; button8.Enabled = true; button9.Text = ""; button9.Enabled = true; textBox1.Text = ""; counter = 0; } } } //Variable to store player, 0 is X, 1 is O. int counter = 0; Good thing that comment is there! This sets you up for some rather unimpressive player-turn logic though: //Check who's turn it is if(counter == 0) { button1.Text = "X"; counter++; }else if(counter == 1) { button1.Text = "O"; counter--; } So who the current player is is stored in an int variable, that we increment and decrement. How about this instead? public enum Player { X, O } Then you could store who the current player is in a Player variable: //Variable to store player, X is X, O is O. Player currentPlayer = Player.X; Notice how useless that comment becomes with self-descriptive code? Even better: //Check who's turn it is if(currentPlayer == Player.X) { currentPlayer = Player.Y; } else if(currentPlayer == Player.Y) // notice '}' closing brace on its own line { currentPlayer = Player.X; } Or, if you're into ternaries: currentPlayer = currentPlayer == Player.X ? Player.Y : Player.X;
{ "domain": "codereview.stackexchange", "id": 16755, "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#, tic-tac-toe", "url": null }
java, beginner, swing, text-editor keepSearch=0; findField=new JTextField("find"); replaceField=new JTextField("replace"); find=new JButton("Find"); find.addActionListener(new FARListener()); findNext=new JButton("Next"); findNext.addActionListener(new FARListener()); previousFind=new JButton("Previous"); previousFind.addActionListener(new FARListener()); findAll=new JButton("Find all"); findAll.addActionListener(new FARListener()); replace=new JButton("Replace"); replace.addActionListener(new FARListener()); replaceAll=new JButton("Replace all"); replaceAll.addActionListener(new FARListener()); caseSensitive=new JCheckBox("Case sensitive"); caseSensitive.setSelected(true); caseSensitive.addActionListener(new FARListener()); okFind=new JButton("OK"); okFind.addActionListener(new FARListener()); findAndReplacePanel.add(findField); findPanel1.add(find); findPanel1.add(findAll); findPanel2.add(findNext); findPanel2.add(previousFind); findAndReplacePanel.add(findPanel1); findAndReplacePanel.add(findPanel2); findAndReplacePanel.add(replaceField); replacePanel.add(replace); replacePanel.add(replaceAll); findAndReplacePanel.add(replacePanel); findAndReplacePanel.add(caseSensitive); findAndReplacePanel.add(okFind); findAndReplaceWin.add(findAndReplacePanel); findAndReplaceWin.pack();
{ "domain": "codereview.stackexchange", "id": 12706, "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, swing, text-editor", "url": null }
{0, 0} tcs = Table[Limit[fcs, n -> k], {m, -3, 3}, {k, -3, 3}]; % // MatrixForm $$tcs = \left( \begin{array}{ccccccc} 0 & -\frac{6}{5 \pi } & 0 & -\frac{2}{3 \pi } & 0 & -\frac{6}{5 \pi } & 0 \\ \frac{4}{5 \pi } & 0 & -\frac{4}{3 \pi } & 0 & -\frac{4}{3 \pi } & 0 & \frac{4}{5 \pi } \\ 0 & \frac{2}{3 \pi } & 0 & -\frac{2}{\pi } & 0 & \frac{2}{3 \pi } & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & -\frac{2}{3 \pi } & 0 & \frac{2}{\pi } & 0 & -\frac{2}{3 \pi } & 0 \\ -\frac{4}{5 \pi } & 0 & \frac{4}{3 \pi } & 0 & \frac{4}{3 \pi } & 0 & -\frac{4}{5 \pi } \\ 0 & \frac{6}{5 \pi } & 0 & \frac{2}{3 \pi } & 0 & \frac{6}{5 \pi } & 0 \\ \end{array} \right)$$ acs = ArrayRules[SparseArray[tcs]]
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9572778036723354, "lm_q1q2_score": 0.8383714571600891, "lm_q2_score": 0.8757870013740061, "openwebmath_perplexity": 5846.096627024306, "openwebmath_score": 0.6785317063331604, "tags": null, "url": "https://mathematica.stackexchange.com/questions/126272/solution-to-a-specific-problem-caused-by-generic-simplification" }
string-theory, perturbation-theory, interactions, physical-constants Title: Two perturbative expansions in String Theory In my String Theory course we learned about the two perturbative expansions of the theory: the one in $g_s$ and the one in $\alpha'$, but I can't picture the difference between the two of them. I was told that the $g_s$ expansion is an expansion in different topologies (sphere + torus + bitorus + ...) while the $\alpha'$ expansion is an expansion in couplings (quadratic + cubic + quartic + ...) but they both seem like the same loop expansion, because to consider a torus (order 1 in $g_s$) one needs to have at least a cubic interaction term (order 1 in $\alpha'$). First is the expansion in the dimensionless string coupling $g_s=\langle e^\phi\rangle$ while performing string perturbation theory. This is an expansion in the genus of the Riemann surface, i.e. the worldsheet of interacting strings, suppressing worldsheets of higher genus. This sum over topologies has a direct analogue in ordinary Yang-Mills theory: the expansion in terms of the 't Hooft coupling $g_\mathrm{YM}^2 N$. In summary, the $g_s$ series governs interactions and quantum effects.
{ "domain": "physics.stackexchange", "id": 79751, "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": "string-theory, perturbation-theory, interactions, physical-constants", "url": null }
So we can find $x>0$ such that $f(x)>0$. By the intermediate value theorem, there exists $x_0>0$ such that $f(x_0)=0$. I let you do the case $c_0>0$ and $c_n<0$. -
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.977022625406662, "lm_q1q2_score": 0.8471135627553984, "lm_q2_score": 0.8670357683915538, "openwebmath_perplexity": 126.82438289561891, "openwebmath_score": 0.9783045053482056, "tags": null, "url": "http://math.stackexchange.com/questions/293746/is-this-proof-correct-complete" }
$\left\{x|\text{ }|x|\ge 3\right\}=\left(-\infty ,-3\right]\cup \left[3,\infty \right)$ This video describes how to use interval notation to describe a set. This video describes how to use Set-Builder notation to describe a set. A General Note: Set-Builder Notation and Interval Notation Set-builder notation is a method of specifying a set of elements that satisfy a certain condition. It takes the form $\left\{x|\text{statement about }x\right\}$ which is read as, “the set of all $x$ such that the statement about $x$ is true.” For example, $\left\{x|4<x\le 12\right\}$ Interval notation is a way of describing sets that include all real numbers between a lower limit that may or may not be included and an upper limit that may or may not be included. The endpoint values are listed between brackets or parentheses. A square bracket indicates inclusion in the set, and a parenthesis indicates exclusion from the set. For example, $\left(4,12\right]$ How To: Given a line graph, describe the set of values using interval notation. 1. Identify the intervals to be included in the set by determining where the heavy line overlays the real line. 2. At the left end of each interval, use [ with each end value to be included in the set (solid dot) or ( for each excluded end value (open dot). 3. At the right end of each interval, use ] with each end value to be included in the set (filled dot) or ) for each excluded end value (open dot). 4. Use the union symbol $\cup$ to combine all intervals into one set. Example 5: Describing Sets on the Real-Number Line Describe the intervals of values shown in Figure 4 using inequality notation, set-builder notation, and interval notation. Figure 4 Solution To describe the values, $x$, included in the intervals shown, we would say, ” $x$ is a real number greater than or equal to 1 and less than or equal to 3, or a real number greater than 5.”
{ "domain": "lumenlearning.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9901401432417146, "lm_q1q2_score": 0.800099777422856, "lm_q2_score": 0.808067204308405, "openwebmath_perplexity": 458.3682209816544, "openwebmath_score": 0.8808161020278931, "tags": null, "url": "https://courses.lumenlearning.com/ivytech-collegealgebra/chapter/use-notations-to-specify-domain-and-range/" }
ros, lidar, velodyne-pointcloud, velodyne Title: Velodyne point cloud node doesn't work I have a 32 HDl and VLP 16. I built the velodyne package by compiling it from source as I wanted to use VLP-16 driver. When I try to run the velodyne pointcloud node for the HDL 32, I get the following error $ rosrun velodyne_pointcloud cloud_node _calibration:=32db.yaml [ INFO] [1458049427.031892132]: correction angles: 32db.yaml YAML Exception: yaml-cpp: error at line 0, column 0: bad conversion [ERROR] [1458049427.036928149]: Unable to open calibration file: 32db.yaml [ INFO] [1458049427.043593822]: Reconfigure Request Originally posted by b-sriram on ROS Answers with karma: 105 on 2016-03-15 Post score: 0 This is apparently a bug caused by a recent source update affecting the YAML reader. See issue #84. Originally posted by joq with karma: 25443 on 2016-03-19 This answer was ACCEPTED on the original site Post score: 1 Original comments Comment by joq on 2016-03-22: It's fixed now in the mastersource.
{ "domain": "robotics.stackexchange", "id": 24115, "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, lidar, velodyne-pointcloud, velodyne", "url": null }
general-relativity, differential-geometry, field-theory, coordinate-systems, covariance \end{align} This equation is saying that if we take a vector $v\in T_pM$, and we look at the corresponding covector $\theta:= g^{\flat}(v)\in T_p^*M$, then their components are related as $\theta_i=g_{ij}(p)v^j$. The equation $(*)$ looks a little scary, but it's the correct way of writing things. Both sides are functions on $TU$. Therefore, with $(*)$, we know exactly how the two charts for the tangent bundle, $(TU,T\alpha)$ and $(TU, (T^*\alpha)\circ g^{\flat})$ are related to one another.
{ "domain": "physics.stackexchange", "id": 83090, "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, differential-geometry, field-theory, coordinate-systems, covariance", "url": null }
ros, urdf, ros-control, gazebo-ros <material>Gazebo/Black</material> <turnGravityOff>false</turnGravityOff> <dampingFactor>0.01</dampingFactor> </gazebo> <joint name="${fb}_${lr}_wheel_joint" type="continuous"> <parent link="${parent}"/> <child link="${fb}_${lr}_wheel"/> <origin xyz="${translateX} ${translateY} ${base_z_origin_to_wheel_origin}" rpy="0 0 0" /> <axis xyz="0 1 0" rpy="0 0" /> <limit effort="100" velocity="100"/> </joint> <!-- Transmission is important to link the joints and the controller --> <transmission name="${fb}_${lr}_wheel_joint_trans"> <type>transmission_interface/SimpleTransmission</type> <joint name="${fb}_${lr}_wheel_joint"> <hardwareInterface>VelocityJointInterface</hardwareInterface> </joint> <actuator name="${fb}_${lr}_wheel_joint_motor"> <hardwareInterface>VelocityJointInterface</hardwareInterface> <mechanicalReduction>1</mechanicalReduction> <motorTorqueConstant>1</motorTorqueConstant> </actuator> </transmission> </xacro:macro> </robot>
{ "domain": "robotics.stackexchange", "id": 26108, "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, urdf, ros-control, gazebo-ros", "url": null }
navigation, ros2, costmap, amcl Title: AMCL aborts global costmap I have problems with Rviz2 when pose estimating a robot. I get the following error: [amcl-15] [INFO] [1649166945.999995726] [robot1.amcl]: initialPoseReceived [amcl-15] [WARN] [1649166946.000590096] [robot1.amcl]: Failed to transform initial pose in time (Lookup would require extrapolation into the future. Requested time 1649166945.998883 but the latest data is at time 20.984000, when looking up transform from frame [odom] to frame [base_footprint]) [amcl-15] [INFO] [1649166946.000688191] [robot1.amcl]: Setting pose (20.981000): 0.918 0.422 0.007 The global costmap shows up correctly for 1 second (Image 1) before throwing the above error and removes it. Then I am left with only a local costmap (Image 2). The robot can still navigate, but it is not nearly as good without the global costmap. Image 1 Image 2 Any ideas? Originally posted by WarTurtle on ROS Answers with karma: 170 on 2022-04-05 Post score: 1
{ "domain": "robotics.stackexchange", "id": 37560, "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": "navigation, ros2, costmap, amcl", "url": null }
homework-and-exercises, forces, aerodynamics Title: Height formula of a sphere inside a pipe I have a pipe with a ball inside it and a blowing air through it. Look this image:
{ "domain": "physics.stackexchange", "id": 30953, "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, forces, aerodynamics", "url": null }
javascript, jquery, api, html5, ajax If there is any other language than jQquery that I can use to get JSON files from API, please let me know because I find jQuery quite confusing. Variables var icon = "https://openweathermap.org/img/w/" + data.weather[0].icon + ".png"; var weather = data.weather[0].main; var desc = data.weather[0].description; var temp = data.main.temp; var temp1 = temp + "℃" $("#icon").attr("src", icon); document.getElementById('weather').innerHTML = weather; document.getElementById('desc').innerHTML = desc; document.getElementById('temp').innerHTML = temp1; None of these variables are really needed. Each variable is only used once and you aren't doing any incredibly complex calculations on them, so they aren't even needed for the sake of understanding. Eliminating variables would also get rid of this temp1 variable which is frankly a little ugly -- usually you know you've gone too far when you have to start adding numbers to variable names. Try something like this instead: $("#icon").attr("src", "https://openweathermap.org/img/w/" + data.weather[0].icon + ".png";); document.getElementById('weather').innerHTML = data.weather[0].main; document.getElementById('desc').innerHTML = data.weather[0].description; document.getElementById('temp').innerHTML = data.main.temp + "℃";
{ "domain": "codereview.stackexchange", "id": 33644, "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, jquery, api, html5, ajax", "url": null }
quantum-field-theory, klein-gordon-equation, vibrations Title: What is the relationship between vibration of the field and quantum fluctuation? Consider a free field like the KG equation. I see that why $$\tilde \phi(\mathbf{p},t)$$ a momentum-dependent quantity, is an oscillator, vibrating at a frequency because when we apply the Fourier transform to the KG equation we have: $$(\frac{\partial^2}{\partial t^2}+ p^2+m^2)\tilde \phi(\mathbf{p},t)=0$$ which is the equation of an oscillator vibrating at frequency $\sqrt{(p^2+m^2)}$. But is this oscillation or vibration the same notion of quantum fluctuation, or are they related? I'll be very bold and try to be straight to the point. No they are not the same thing in the sense that their nature is very different although related. Think of a usual harmonic oscillator whether it is quantum mechanical or classical, the system will oscillate with some frequency that is independent of the quantum (or classical) nature of the system. Now, because a harmonic oscillator is effectively a confined system, there is kind of a typical confining "length scale" that will affect the quantum behaviour. In particular it imposes a rough bound on the uncertainty in position (or diplacement field or whatever) which in turn makes the uncertainty on the momentum of this field non zero as well (in virtue of the commutation relations they satisfy). The fact that this confinement generates a non zero momentum is called a zero point fluctuation and gives rise to a non zero energy ground state (that is for ever oscillating). Note that the stronger the "spring constant" the more it can fluctuate via this uncertainty mechanism.
{ "domain": "physics.stackexchange", "id": 20140, "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-field-theory, klein-gordon-equation, vibrations", "url": null }
electromagnetism Title: Understanding the Faraday tensor I'm trying to get my head ahead understanding the Faraday 2-tensor. I first started by thinking about how I've understood the electric and magnetic fields in electro/magnetostatics so far. The electric field is just the force that a unit test charge would feel from a purely electric effect assume it didn't affect that field in any way. The magnetic field is just a slightly more complicated version of that, where we have to take the velocity of the particle into account and we define the magnetic field vector at a given point as being in a direction perpendicular to the force felt by the (moving) test charge at that given point. OK, I can understand that, I think. But then I find some trouble in trying to figure out how a 2-tensor can describe a force, so I went off to Wikipedia to see how they define the Faraday tensor. They define it in terms of the 4-potential, which is defined in terms of the electric and magnetic potentials, which are defined in terms of the electric and magnetic fields, which are themselves defined in terms of the electric and magnetic potentials, creating a circular definition. So I ask you, how does one go about measuring the Faraday tensor in some region of space with some arbitrary electromagnetic field there? I don't particularly care if the answer is impractical as I'm perfectly happy to pretend that we can test charges at every region of space to measure it. I just need some way of getting a handle on this new idea that there is one field called the electromagnetic field that somehow explains all of the electric and magnetic effects that we'd otherwise analyze separately. Thanks. You are looking for the Lorentz force law: $$\frac{dp^\mu}{d\tau} = qu^\nu F^{\mu\nu}.$$ Geometrically, that says that feeding $q$ times the four-momentum $u$ into the Faraday tensor $F$ outputs the force $dp / d\tau$. So to measure $F$, you just distribute test charges everywhere, with various four-momenta, then measure the rate of change of their four-momenta.
{ "domain": "physics.stackexchange", "id": 28728, "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", "url": null }
logic, linear-temporal-logic Title: LTL: Show $\neg(aUb) \Leftrightarrow \neg b U (\neg a \land \neg b) \lor G \neg b$ I got as far as \begin{align} w \vDash \neg (a U b) &\Leftrightarrow \neg (w \vDash a U b) \Leftrightarrow \neg (\exists_{i\geq0} : w^i \vDash b \land \forall_{0\leq k < i} : w^k \vDash a) \\ &\Leftrightarrow \forall_{i\geq0} : \neg(w^i \vDash b) \lor \exists_{0\leq k < i} : \neg(w^k \vDash a) \end{align} but got stuck. If you could offer some advice as on where to start I would very much appreciate it. Thanks in advance $aUb$ means that $a$ holds up to (and not necessarily including) the first point where $b$ holds, which must exist. There are two ways in which this can fail: $b$ never holds, or the first time that $a$ fails precedes the first time in which $b$ is true. The first case is handled by $G \lnot b$. The second case is handled by $\lnot b U (\lnot a \land \lnot b)$ (why?).
{ "domain": "cs.stackexchange", "id": 795, "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, linear-temporal-logic", "url": null }
If there is no xy-term, the conic is "horizontal" or "vertical". . . Its axis is parallel to a coordinate axis. Then the equation can be "eyeballed" to identify the conic. The general equation of this conic is: . $Ax^2 + By^2 + Cx + Dy + E \:=\:0$ We are concerned with $A$ and $B$ only, the coefficients of $x^2$ and $y^2.$ If $A = 0$ or $B = 0$ (but not both), we have a parabola If $A = B$, we have a circle. If $A \ne B$ and $A,B$ have the same sign: ellipse. If $A,B$ have opposite signs: hyperbola. Note: the above forms include degenerate and imaginary conics. For example: . $x^2 + y^2 \:=\:0$ is a degenerate circle. And: . $4x^2 + y^2 + 9\:=\:0$ is an imaginary ellipse.
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9805806518175514, "lm_q1q2_score": 0.8106575898950783, "lm_q2_score": 0.8267117940706734, "openwebmath_perplexity": 941.7812733696385, "openwebmath_score": 0.7345899939537048, "tags": null, "url": "http://mathhelpforum.com/algebra/182595-how-can-i-determine-parabola-finding-its-standard-form.html" }
c++, beginner, random, generator Title: Simple randomization program I'm a few months into learning C++ programming and I want to know if I'm moving generally in the right direction or not with the following code. This is the most advanced thing I've created so far, but it doesn't contain any pointers or references so I'm worried I'm not doing things properly on the memory level. I especially want advice regarding moving this type of code to templates and virtual functions. //This program's purpose is a simple battle simulator and a simple lotto simulator //This requires two classes and a bit of procedural main game logic that can repeat //The first class is a Randomizer class that allows the user to generate //random numbers by inputting the desired amount of numbers, and the max //range for those numbers. The default start value is 1. //The second class is a Battler class that contains two Randomizer objects. //It also contains a method to compare the second integer of each of the vector //arrays contained in each of those objects, and returns -1, 0, or 1 depending //on which value is greater, or 0 if they are tied. #include <iostream> //Necessary for cout and endl #include <ctime> //Necessary for time_t variable #include <cstdlib> //Necessary for rand and srand #include <vector> //Necessary for vector<type> /*HEADER OF RANDOMIZER CLASS*/ class Randomizer //The preferred syntax is to start with a capital letter for classes { private: time_t timevalue; //time_t member variable that will be set later void randomTimeInit(); //called by constructor (runs once)
{ "domain": "codereview.stackexchange", "id": 1992, "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++, beginner, random, generator", "url": null }
general-relativity, time-dilation, radio-frequency Title: How gravity time dilation affect radio wave communication? I'm not in any way an expert so sorry if my question is silly. So i was wondering about a hypothetical situation. I'm orbiting a black hole and I'm trying to contact via radio with someone outside the gravitational effect of that black hole. As far I understand the radio wave similarly to light can be bent but cannot be slowed down by gravity. So is the communication possible? How would time dilation due to black hole gravity affect my attempt to communicate? Regards Sebastian First of all let's make the situation more concrete. The effect of gravity extends to infinity, although it drops off as a factor of $(\sim \frac{1}{r^2})$ according to Newtonian mechanics(which suffices in terms of building our intuition here). When you are just outside the event horizon of the black hole, all the signals you send can eventually reach any observer who is not him/herself inside a black hole. A radio wave travels at the speed of light in vacuum so in your example it would be the same as sending a beam of light. Let's think about the signal just outside the event horizon and somewhere far away from there. Because of the gravitational well, the clock of the source of the beam will run slower than the clock at the receiving end of the signal. This creates a shift in the signal as it passes through space. This is what creates a redshift in the signal. For a Schwarzschild black hole, the frequency difference is given by the formula $$ \frac{\lambda_{\infty}}{\lambda_{e}}=\left(1-\frac{r_S}{R}\right)^{-\frac{1}{2}} $$ Where $\lambda_{\infty}$ the wavelength far away from the black hole,$\lambda_e$ the wavelength of the emitted wave, $r_S$ the radius of the black hole and $R$ the distance from the centre of the black hole.
{ "domain": "physics.stackexchange", "id": 63884, "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, time-dilation, radio-frequency", "url": null }
quantum-mechanics Title: Timing of photon emission by electron in bound state A photon is emitted by an electron (which is in a bound state). Is the energy of the electron lost immediately, or is the energy emitted during the complete transition time? I think my second assumption is correct but confirmation would be greatly appreciated. In other words, should I view photon emission as part of the transition process or as merely the cause of it? I am aware that during the transition the election can be viewed as transitioning through a multitude of highly unstable orbitals until it finally settles into the lower level. This post What is the Quantum Transition Time for Photon Emission? is very useful and really brings home the subtleties involved in quantum mechanics, but I don't think it addresses my question directly. A photon is emitted by an electron (which is in a bound state). Is the energy of the electron lost immediately, or is the energy emitted during the complete transition time? I think my second assumption is correct but confirmation would be greatly appreciated One has to let go of the classical framework. Immediately in time has a meaning for a ball falling in the Newtonian gravitational field and mathematics can give you the rate of energy loss per delta(t) because in principle every (x,y,z) point is reached at a specific t. This does not hold in the quantum mechanical framework of an electron bound to an atom. An individual atom with its electron in an excited state may emit the photon at an arbitrary time t. One has to take a large sample of atoms with the electrons at that energy level and measure the time the photon hits the detector . One then will have a curve characterizing the lifetime of that bound state's collective time behavior Now in the post you have quoted the answers are indicating the mathematical formulation within the theory of Quantum Mechanics that reproduce this experimental observation. Quantum mechanical calculations give probability distributions for the variables under consideration, time in this instance, to fit the experimental observations. What is really happening at the individual atom's decay from a higher energy level to a lower one is random to first order ( it is the assumption of calculating the half life curves) . The time will be within the Heisenberg Uncertainty of delta(E)*delta(t) is all that can be safely claimed , and can be presumed "instantaneous" , in the sense that there are no experimental tools to explore further, other than the mathematical ones discussed in the answers of the other question.
{ "domain": "physics.stackexchange", "id": 20392, "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", "url": null }
of the system. The existence of limit cycles can be predicted from closed trajectories in the phase portrait. The advatage of phase plot, is that one does not have to solve the ODE first (so it works for nonlinear hard to solve ODE's). 5 \dot{x}+2 x+x^{2}=0 Method 1: Calculate by hands with phase plane analysis. Il'in}, title = {Journal of Nonlinear Mathematical Physics 2000, V. Can you please help me draw the phase portrait of the non-linear. • A PLL is a control system that generates an output signal whose phase is related to the phase of the input and the feedback signal of the local oscillator. 1 Plane Autonomous Systems A plane autonomous system is a pair of simultaneous first-order differential equations, x˙ = f(x,y), y˙ = g(x,y). The problem that I encountered came from the fact that a huge amount of information on this topic is in books and published in articles. (3 points) Sketch the nullclines and indicate where each derivative is positive/negative. Let A= 3 −4 6 −7. Consider the nonlinear system. Classification of stable and unstable equilibrium points using phase portraits. As an example, I can cite the system of equations from this topic. In this paper, a procedure of energy balance is presented, for the purpose of making a mathematical model of self-excitation oscillations in the system with one degree of freedom and analysis of phase portraits, i. initial-value problems governed by ordinary or partial differential equations, or by difference equations. Using linear algebra, the phase portrait of any linear system of the form (2. (i) For A = 2 And B=0 (which Means There Is No Damping), Make A Phase Portrait Using The Online Plotter. Since Andronov (1932), traditionally three different approaches are used for the study of dynamical systems: qualitative methods, analytical methods, and numerical methods. Phase portrait of the nonlinear system. I Flowing along vector field, phase point traces out a solution. 3 in Third and 3-42 Fourth Quadrant. The field of non-linear dynamics has introduced the powerful phase portrait representation for the global analysis of nonlinear differential equations. What is a Phase Portrait? Above, we have an animated phase portrait, but what is it? A phase portrait, in
{ "domain": "colagrossijeans.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9852713891776498, "lm_q1q2_score": 0.8273658508922132, "lm_q2_score": 0.8397339656668287, "openwebmath_perplexity": 567.4945903919495, "openwebmath_score": 0.6094440817832947, "tags": null, "url": "http://colagrossijeans.it/kzgz/phase-portrait-nonlinear-system.html" }
rviz, mesh Title: Rviz trying to display shape_msgs Mesh Hi There, I've created a ROS node that uses a lidar scanner and a pan tilt unit to create 3d scans. These scans are published by the node as shape_msgs::Mesh messages. I was hoping to be able to visualize these meshes live in Rviz as they are created. But they don't seem to be supported by Rvis V1.11.10 in Ros Indigo. Is there a message type for a mesh that does work in rviz? Ideally I'd like to be able to display texture mapped meshes but I can't find a standard message type that supports that? At some point soon I'll be needing to display a 3D terrain map in Rvis to if that's possible? Thanks, Pete Originally posted by PeteBlackerThe3rd on ROS Answers with karma: 9529 on 2015-12-11 Post score: 2 Original comments Comment by 2ROS0 on 2015-12-11: Could you just use a triangle list type and sort the vertices in your shape_msgs Mesh so they are correctly ordered for the triangle list? Comment by PeteBlackerThe3rd on 2015-12-17: Hi there. Yes I have used the triangle list. Because the data is being generated live so the last thing I want to do is save it to a file. The messages a huge since vertices have to be repeated many times. But colouring the triangles is a bonus. Thanks Comment by simaopp on 2018-01-16: Can you please tell me how can you create the triangle list to display on rviz? I think you want a Mesh Marker: http://wiki.ros.org/rviz/DisplayTypes/Marker#Mesh_Resource_.28MESH_RESOURCE.3D10.29_.5B1.1.2B-.5D Originally posted by William with karma: 17335 on 2015-12-11 This answer was ACCEPTED on the original site Post score: 0
{ "domain": "robotics.stackexchange", "id": 23209, "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": "rviz, mesh", "url": null }
inorganic-chemistry, coordination-compounds, salt Title: Electride salt preparation In preparation for the Birch reduction, I am trying to prepare an electride salt, $\ce{[Na(NH3)6]+, e-}.$ This salt should be brilliant blue, as far as I know, but I am getting a black sludge when adding sodium to the liquid anhydrous ammonia at −60 °C or so. Is this because the salt is missing the electron? How do I remedy this? As long as your experimental setup did not contain any leakages or impurities through which air or moisture could have gotten into the mixture, the reaction should have worked fine under these conditions. The color of the hexaamminsodium electride solution is actually deep blue and intense, so at higher concentrations it can appear black at first sight (see picture below).
{ "domain": "chemistry.stackexchange", "id": 1684, "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": "inorganic-chemistry, coordination-compounds, salt", "url": null }
pandas, dataframe I assumed 5 bins, you can pass in fixed bins if you like. You might have to deal with NaNs . #remove the age column data_age_bins_mean =data.groupby(['age_bins']).mean().drop('age', 1) col_names =variable_names[1:] #creating a dict for each age_bin containing key value pairs for the top 5 values age_bin_top_vars =data_age_bins_mean.apply(lambda x: {col_names[i]: x[i] for i in np.argsort(x)[::-1][:5]}, axis =1) So, np.argsort to sort the variables with the highest values. Output age_bin_top_vars age_bins (0.902, 20.6] {u'var_7': 52.523809523809526, u'var_6': 51.28... (20.6, 40.2] {u'var_7': 65.36842105263158, u'var_6': 57.157... (40.2, 59.8] {u'var_6': 52.0, u'var_3': 54.04347826086956, ... (59.8, 79.4] {u'var_5': 52.2, u'var_14': 56.3, u'var_12': 5... (79.4, 99.0] {u'var_4': 57.11764705882353, u'var_13': 58.35... Convert the series to json age_bin_top_vars.to_json()
{ "domain": "datascience.stackexchange", "id": 9081, "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": "pandas, dataframe", "url": null }
biochemistry Title: Is glutamate always involved in the deamination and amination of the other amino acids? For example, are there pathways for the deamination of phenylalanine that simply produce ammonia or pathways for it to be synthesized from phenylpyruvate with ammonia being utilized to form the amine group? Preferably, I want to know how it is with human metabolism mainly. For most amino acids, the removal of the α-amino group involves α-ketoglutarate and glutamate. The amino group is first transferred to a-ketoglutarate by transaminases, and the resulting glutamate is then deaminated (via glutamate dehydrogenase) to yield ammonia. The same is true for amination. Glutamate and glutamine are the two major amino group-donors. Most ketoacids are converted to their respective amino acids by transamination involving glutamate or glutamine. Glutamine can be synthesized by amination of glutamate with ammonia without transamination (via a synthetase enzyme) and glutamate can be aminated with ammonia too. Exceptions do exist, of course. For example, Not all transaminations involve glutamate/glutamine (as this user has replied), and serine and threonine can be directly deaminated (via dehydratase enzymes, as opposed to the dehydrogenase used for glutamate).
{ "domain": "biology.stackexchange", "id": 10089, "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": "biochemistry", "url": null }
thermodynamics, electromagnetic-radiation, gas, heat-conduction, convection Title: Is there a difference in the 'quality' of a gas if it's heated by electromagnetic radiation as opposed to conduction/convection? According to this link, "The wavelength at which the $O_2$ molecule most strongly absorbs light is approximately $145$ nm." According to this link, that's in the ultraviolet range of the electromagnetic spectrum. Consider two tanks containing oxygen gas, both equivalent. One tank has a steady stream of $145$ nm ultraviolet light being emitted on it, while the other has a flame warming the bottom of the tank. The temperature of the oxygen in both tanks will increase. Say we calibrate the experiment so both tanks reach $10^{\circ}$ C (and that nothing explodes) My question is, is there any difference in the oxygen contained in one tank vs. the other? In other words, is there any experiment that could be done to determine whether some oxygen came from one tank or the other? Or, since they are at the same temperature, are they equivalent? The question arises because from what I understand, a gas molecule heats up by radiative absorption by absorbing a photon, which excites the electrons in it, while the mechanism by which it is heated via conduction/convection is different (molecules bumping into each other ?), and I'm not sure if this results in a different "quality" of heated gas. As noted in @Bob_D's comment, 145 nm radiation is going to convert many oxygen (O$_2$) molecules into ozone (O$_3$). Ozone is unstable and eventually reverts to molecular oxygen, but its half-life is long enough that it could be detected for quite some time. The half-life of ozone in a glass vessel initially filled with 10% O$_3$ and 90% O$_2$at at ambient temperature and pressure is about 20 hours. The lifetime is less is some other types of vessels, e.g. it is only about an hour in brass. Ambient surface ozone levels are $<10^{-7}$, so an oxygen tank initially filled with 10% ozone might be distinguishable for about 20 half-lives, i.e. a couple of weeks.
{ "domain": "physics.stackexchange", "id": 93882, "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, gas, heat-conduction, convection", "url": null }
beginner, c, collatz-sequence Stay with x & 1 or use x % 2llu. Detect overflow cltz() may overflow. Should you want to detect this: #include <limits.h> #include <stdio.h> #include <stdlib.h>
{ "domain": "codereview.stackexchange", "id": 44739, "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": "beginner, c, collatz-sequence", "url": null }
Notice that for $p\in\mathbb{P}$, $f(p)=p$, so the primes map linearly with slope $1$. Then let $k\in\mathbb{Z}^+$ and consider: $$f(kp)=f(k)+f(p)=f(k)+p$$ The slope isn't readily obvious for this one, though, so notice that $$k\cdot(p+m)=kp+km$$ and that $$f(k\cdot(p+m))=f(k)+p+m$$ whenever $p+m\in\mathbb{P}$. So the slope will be $\frac{m}{km}=\frac1k$ between $kp$ and $k\cdot(p+m)$. Since the slope is independent of $p$ or $m$, you have the slope for the line related to $k$. The pattern arises simply because the function sort of "plays nicely" with the primes. • In other words, the second line (of slope $\frac12$) is from numbers of the form $2p$; the third line (of slope $\frac13$) is from numbers of the form $3p$; and so on. – Greg Martin Sep 14 '15 at 5:44 http://timeblimp.com/?page_id=1194 First Line: Primes Second Line: 2 times Primes Third Line : 3 times Primes Fourth line: 2 times 3 times Primes ect
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9688561703644736, "lm_q1q2_score": 0.8365022802499948, "lm_q2_score": 0.8633916011860785, "openwebmath_perplexity": 532.37856637908, "openwebmath_score": 0.9028472900390625, "tags": null, "url": "https://math.stackexchange.com/questions/1434547/why-does-the-sum-of-the-the-prime-factorization-of-n-create-this-strange-pattern" }
Now all you have to do is to choose k so that –17+55k lies between 100 and 200. Originally Posted by barhin Question 2 Let X1 and X2 be two be two smallest positive integer for which the following statement is true 85x-12 is a multiple of 194 then X1+X2= (NB: The 1 and 2 in front of X1 and X2 are all subscripts X1 and X2) For this one, start by finding x and y such that 85x+194y=1 (using Euclid's algorithm, as for Q1). Multiply the result by 12 on both sides, to give you a solution to 85X – 12 = (multiple of 194). Then add suitable multiples of 194 to find the two smallest positive values for X. 3. Hello, barhin! $\text{(1) Of all integer pairs }(x,y)\text{ that satisfy the equation: }\: 42x+55y\:=\:1$ . . $\text{only one such pair has }100 . . $\text{What is this value of }x\,?$ The problem can be solved without Euclid's algorithm. . . But, of course, this solution takes much longer. We have: . $42x + 55y \:=\:1$ $\text{Then: }\:x \:=\:\frac{1-55y}{42} \:=\:\frac{-42y + 1 - 13y}{42} \quad\Rightarrow\quad x \:=\:-y + \frac{1-13y}{42}$ .[1] Since $x$ is an integer, $1-13y$ must be a multiple of 42. . . $1-13y \:=\:42a \quad\Rightarrow\quad y \:=\:\frac{1-42a}{13} \quad\Rightarrow\quad y \:=\:-3a + \frac{1-3a}{13}$ .[2] Since $y$ in an integer, $1-3a$ must be a multiple of 13.
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9859363725435203, "lm_q1q2_score": 0.8792689442983057, "lm_q2_score": 0.8918110425624792, "openwebmath_perplexity": 4064.9297756473325, "openwebmath_score": 0.8764424324035645, "tags": null, "url": "http://mathhelpforum.com/number-theory/181037-integers.html" }
java, performance, time-limit-exceeded, factors public static void main(String[] args) { try { BufferedReader buffer = new BufferedReader(new InputStreamReader(System.in)); long testCases = Long.parseLong(buffer.readLine()); for(long itr = 1; itr <= testCases; itr++) { long number = Long.parseLong(buffer.readLine()); System.out.println(funcD(number)); } } catch(Exception e) { System.out.println("Error"); } } For a coding contest, the answer is almost never to implement the problem the same way as it is given. For example here, functions A and B are actually intentionally misleading. Function A is also known as Euler's Totient, and function B computes the sum of totients of divisors which is the same as the original number. Detailed review of them is therefore a waste, functions A and B don't need to be implemented at all. Function C can be improved by noting that the lowest divisor of a number is necessarily a prime, so calling check_prime is unnecessary. If itr was a * b then a and b would have been found first and divided out of remNum already, making itr not a divisor of remNum. The square root is also unnecessary, and relatively expensive. It can be avoided by testing itr * itr <= numb instead. There is no risk of overflow given that numb <= 1000000. Further refinements are possible. Function D can be improved by caching the partial sums. In isolation that would not help, but there can be multiple test cases during a run of the program, and they can reuse the previously computed sums. For example as an extreme case, after the test case 1000000 has been used, any further test cases could be essentially free, because all possible cases would have been calculated at that point. Also, after funcD(10) has been evaluated, funcD(20) could start with that result instead of starting over from scratch.
{ "domain": "codereview.stackexchange", "id": 38768, "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, performance, time-limit-exceeded, factors", "url": null }
qiskit You can find some tutorials introducing the functionality here: https://qiskit.org/documentation/tutorials/optimization/index.html or here https://github.com/Qiskit/qiskit-tutorials/tree/master/tutorials/optimization
{ "domain": "quantumcomputing.stackexchange", "id": 1575, "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": "qiskit", "url": null }
c#, parsing For either result[] array, I am left with nothing and I would have to read all of the code before I understood what they contained. This is a little backwards - I should know what the variable contains, then be able to read the code - with descriptive variable names giving me a greater understanding of what's going on. bFound: Don't shorten your variable names like this. I'm left wondering: What is a b? What does it mean if it's found? Maybe this would be more recognisable to a German reader, but even so, expanding b to a word to say exactly what's found would do wonders for readability. pos1, pos2: SeparatorPosition and SeparatorEnd would have been more descriptive. Better yet these variables are entirely unnecessary if you just use String.Split(). My approach As I mentioned above, as oppose to editing your methods, I've written from scratch how I'd tackle this problem. ParseHouseNumberRange This is the entry method. You feed this method a string such as "20a bis 21c". It splits it up on the "bis" or the "-" (defined in the separators array) in order to produce smaller chunks of the original string. Each of these chunks is passed to then passes each of the results (in this case, "20a " and " 21c", spaces included) over to the non-public method ParseHouseNumber below. ParseHouseNumber will split these chunks up further and this method combines all the results into a single array which is returned. Given "20a bis 21c" or similar, it returns an array: 20, a, 21, c. public string[] ParseHouseNumberRange(string houseNumberRange) { string[] separators = new string[] {"bis", "-"}; string[] houseNumbers = houseNumberRange.Split(separators, StringSplitOptions.RemoveEmptyEntries); List<string> parsedList = new List<string>(); foreach (string houseNumber in houseNumbers) { parsedList.AddRange(ParseHouseNumber(houseNumber)); } return parsedList.ToArray(); }
{ "domain": "codereview.stackexchange", "id": 39, "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#, parsing", "url": null }
python, beginner, programming-challenge, array Title: (Codewars) Range Extraction Kata: https://www.codewars.com/kata/range-extraction/python A format for expressing an ordered list of integers is to use a comma separated list of either individual integers or a range of integers denoted by the starting integer separated from the end integer in the range by a dash, '-'. The range includes all integers in the interval including both endpoints. It is not considered a range unless it spans at least 3 numbers. For example ("12, 13, 15-17") Complete the solution so that it takes a list of integers in increasing order and returns a correctly formatted string in the range format. Example: solution([-6, -3, -2, -1, 0, 1, 3, 4, 5, 7, 8, 9, 10, 11, 14, 15, 17, 18, 19, 20]) # returns "-6,-3-1,3-5,7-11,14,15,17-20" Courtesy of rosettacode.org
{ "domain": "codereview.stackexchange", "id": 33723, "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, programming-challenge, array", "url": null }
isomers, chirality, stereochemistry (derived from here) If you have a model kit at hand, build the molecules in question. For each conformation of the mesoisomer, the lower part of the Fischer formula is transferred into the upper part of the Fischer formula by a mirror plane. The presence of either a mirror plane (in the drawing indicated by the horizontal dashed line), or a centre of inversion however is incompatible with the molecule's structure being chiral. The principle identifying the mirror plane is illustrated below:
{ "domain": "chemistry.stackexchange", "id": 15809, "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": "isomers, chirality, stereochemistry", "url": null }
When does the limit of a sum become an integral? In many maths and physics texts and courses, I've been told in many cases that the limit of a sum becomes an integral, i.e. (very roughly): $$\lim_{n\to\infty} \sum_{x=0}^n f(x) = \int_0^\infty f(x) dx$$ However I know that this equation can't be true in every case, otherwise series would not exist. So I'd like to ask: what characteristics does $f(x)$ have for the above equation to be true? More details: Yesterday I had to resolve a series like this: $$\lim_{n\to\infty} \sum_{x=0}^n (1 - e^{1/n}) e^{(n-x)/n}$$ This comes from a real-life problem. I decided to find the value of that limit using the following integral: $$\lim_{n\to\infty} \int_0^n (1 - e^{1/n}) e^{(n-x)/n} dx$$ The reasons why I decided to go with the integral are two: habit and because I needed the sum to be continuous (meaning: every value summed must be infinitesimal). Also, I've always been told that sums are for discrete values, integrals are for continuous/infinitesimal ones. The problem is that I do not have a mathematical justification for that. And while testing shows that the result matches reality, I don't know whether it is mathematically correct, or it is just a coincidence. So I asked myself: why should my limit be an integral and not a series? I decided to calculate first the expression of $\sum_{x=0}^n (1-e^{1/n}) e^{(n-x)/n}$ (which is $1 - e^{1/n+1}$) and afterwards the limit for $n$ to infinity ($1 - e$). The result is the same of the integral, and I'm a bit surprised by that.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9728307684643189, "lm_q1q2_score": 0.8288059008625694, "lm_q2_score": 0.8519528038477825, "openwebmath_perplexity": 194.3552773055009, "openwebmath_score": 0.975347101688385, "tags": null, "url": "https://math.stackexchange.com/questions/518609/when-does-the-limit-of-a-sum-become-an-integral" }
Denver Seminary Faculty Portal, Rv Sales Las Vegas, Nv, Princess Celestia And Princess Luna Coloring Pages, Madison Door Style, Cpu Stress Test, Mundo Breakup Version Ukulele Chords, Loudoun General District Court, Mundo Breakup Version Ukulele Chords, Eclecticism And Nursing, Put Your Wood In My Fire Blues Song, Black Jamun Calories,
{ "domain": "webreus.net", "id": null, "lm_label": "1. Yes\n2. Yes\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9697854111860906, "lm_q1q2_score": 0.8299919493444887, "lm_q2_score": 0.8558511396138365, "openwebmath_perplexity": 1311.5734329508234, "openwebmath_score": 0.30894050002098083, "tags": null, "url": "http://43929101674.srv040130.webreus.net/how-many-tludi/modular-system-math-cdb971" }