text
stringlengths
1
1.11k
source
dict
6. Originally Posted by Freaky-Person Basically what I need is an explenation and the steps to solve two different types of factoring problems. I could care less about the answer, I have it in the back of the sheet anyway. 1. x^3 - 6x^2 + 11x - 6 = 0 The rational root theorem tells us that any rational root of a polynomial is a +/- a factor of the constant term divided by +/- a factor of the coeficient of the highest power. So in this case the rational root theorem tells us that any rational roots of this cubic are amoung 1, -1, 2, -2, 3, -3. Try $x=3$ in $x^3 - 6x^2 + 11x - 6$ gives $0$, so $x-3$ is a factor of $x^3 - 6x^2 + 11x - 6$. Now dividing $x^3 - 6x^2 + 11x - 6$ by $x-3$ gives: $ x^3 - 6x^2 + 11x - 6=(x-3)(x^2-3x+2) $ and the last term can be factored by inspection, or finding the roots using the quadratic formula or the same procedure as before to get: $ x^3 - 6x^2 + 11x - 6=(x-3)(x^2-3x+2)=(x-3)(x-1)(x-2) $ RonL
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9852713861502774, "lm_q1q2_score": 0.8055327461992847, "lm_q2_score": 0.8175744850834649, "openwebmath_perplexity": 528.4831260109495, "openwebmath_score": 0.6469465494155884, "tags": null, "url": "http://mathhelpforum.com/algebra/18493-factoring.html" }
ios, swift is actually a bad method to convert an NSData object to an NSString (containing the bytes in hexadecimal). It relies on description having the format <01020304 05060708 090a0b0c 0d0e0f10> which is not officially documented. In most cases, the description of an object is only suitable for debugging purposes, but not for further processing. I would convert all data bytes explicitly to create the string. Here is a possible implementation as an NSData extension method: extension NSData { func hexString() -> String { // "Array" of all bytes: let bytes = UnsafeBufferPointer<UInt8>(start: UnsafePointer(self.bytes), count:self.length) // Array of hex strings, one for each byte: let hexBytes = map(bytes) { String(format: "%02hhx", $0) } // Concatenate all hex strings: return "".join(hexBytes) } } which can be used as let token = deviceToken.hexString() With dispatch_async(dispatch_get_main_queue(), { ... }
{ "domain": "codereview.stackexchange", "id": 24112, "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": "ios, swift", "url": null }
java public char digitAt(long pos) { pos -= doublyCumulativeLength(fullSequenceBefore(pos)); long lo = 0; long hi = pos; while (hi>lo+1) { final long mid = (hi+lo) / 2; if (cumulativeLength(mid) >= pos) { hi = mid; } else { lo = mid; } } pos -= cumulativeLength(lo); return String.valueOf(lo+1).charAt((int) pos - 1); } } Frankly I have been staring at the code for ... 20 minutes, and I can't figure out your algorithm. I can't even throw out a good guess as to whether the result is right, or not. There are some style-related issues that do not help:
{ "domain": "codereview.stackexchange", "id": 9337, "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 }
performance, c, memory-management, memory-optimization return block; } void freeMemoryChunk( u64 size, u8* block ) { assert( block && size ); for( u64 i = 0; i < MEMORY_LOOKUPS; ++i ) { if( ! ( memoryLookups[ i ] ) ) { memoryLookups[ i ] = block; memoryLookupsSizes[ i ] = size; break; } } } ``` You can't really implement a memory manager system like this in standard C. It would have to rely on standard extensions and specific compiler options. The main reason for this is "the strict aliasing rule"... (What is the strict aliasing rule?) ...but also alignment, you shouldn't write a library that hands out misaligned chunks of memory. If you look at malloc & friends they only work since they have a requirement (from the C standard 7.22.3):
{ "domain": "codereview.stackexchange", "id": 41228, "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": "performance, c, memory-management, memory-optimization", "url": null }
python, python-3.x, web-scraping if __name__ == '__main__': movie_picker() With this done, next I will focus on the actual implementation of these functions. The parser you use is very manual. You have to pass the whole path to the element you are looking for. A more user-friendly parser is BeautifulSoup from the module bs4. You can install it on Ubuntu/other Debian derivatives via sudo apt install python-beautifulsoup. It has a method called find which returns the first tag matching some criteria. So to find the title, we can just do soup.find("td", class_="titleColumn"). Or use the find_all command to get a list of all matching tags. You will see that the parsing is a lot easier to follow with this, compared to lxml. I would shuffle the movies list and then iterate over the shuffled list, guaranteeing that a movie will not be picked twice (during one run of the script). from bs4 import BeautifulSoup import requests import random
{ "domain": "codereview.stackexchange", "id": 24069, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, web-scraping", "url": null }
acid-base, water, ph $$K_\mathrm w = (x + 10^{-9})x = 10^{-14}$$ If you solve this equation, you find: $$x = 0.999\times10^{-7}$$ The total concentration of $\ce{H+}$ ion is $1.0001\times10^{-7}$; $\mathrm{pH} = 6.999$.
{ "domain": "chemistry.stackexchange", "id": 12646, "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": "acid-base, water, ph", "url": null }
phylogenetics, phylogeny, beast Unfortunately, googling this error with "BEAST" gave me nothing. If without it, there are a lot of irrelevant problems. Update I have just found out that this error happened simultaneously onto all my nodes (different processors, RAM, & common hards & SSDs). All logs of BEAST 2 analyses have it. What is stranger, some of the analyses pressed on after this & someones were broken. To the present I got more interested not in the broken ones but could this exception spoil those which continued their work? You can restart this at the place you left 'cause is Beast2. 860000000 -3470.6562 6160.7143 -9631.3706 41m35s/Msamples
{ "domain": "bioinformatics.stackexchange", "id": 2143, "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": "phylogenetics, phylogeny, beast", "url": null }
php, mysql, pdo In a nutshell, I am trying to emulate the sort of file that I would get from phpMyAdmin when using the 'Export' function. The code appears to work so far and I have used the generated file to restore a test database consisting of five tables, each of a few thousand rows. My questions: Is it acceptable to place numeric variables within single quotes for purposes of a db restore, or should I really be adding code to grab each field's data type and alter the structure of the resultant file accordingly? This section worries me the most: // add slashes to field content $val = addslashes($val); // replace stuff that needs replacing $search = array("\'", "\n", "\r"); $replace = array("''", "\\n", "\\r"); $val = str_replace($search, $replace, $val);
{ "domain": "codereview.stackexchange", "id": 5452, "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, mysql, pdo", "url": null }
algorithms, optimization, matching buckets = [ [(2, 4), (2, 4), (4, 4)], [(1, 1), (2, 4), (13, 15)], ] solver = z3.Optimize() m = z3.Int("m") for bnr, bucket in enumerate(buckets): springs = [] for b, (lo, hi) in enumerate(bucket): include_spring = z3.Bool(f"is{bnr},{b}") spring = z3.Real(f"s{bnr},{b}") solver.add(lo <= spring) solver.add(spring <= hi) springs.append(include_spring * spring) solver.add(z3.Sum(springs) == m) solver.maximize(m) solver.check() model = solver.model() print(solver.model()) The constraints are easy to express and SMT solvers are really quite powerful nowadays.
{ "domain": "cs.stackexchange", "id": 12083, "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": "algorithms, optimization, matching", "url": null }
organic-chemistry, reaction-mechanism, aromatic-compounds Title: Reasons for dry conditions in substituition reactions with benzene All substitution reactions of benzene must be carried out in dry conditions with a catalyst that produces a powerful electrophile. This was a statement from my book. My question is, why must it be carried out in dry conditions? What will occur if moisture is present? Benzene and other aromatic hydrocarbons are immisible with water. So, probably there is no problem with benzene if we there is moisture. In most of the substitution reactions which benzene undergo, requires Lewis acid catalyst, like ferric halide or aluminium halide. Most commonly used catalysts are Anhyd. $\ce{AlCl3}$ and $\ce{FeBr3}$, which become inactivated if they react with water. So, this requires dry conditions.
{ "domain": "chemistry.stackexchange", "id": 10573, "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": "organic-chemistry, reaction-mechanism, aromatic-compounds", "url": null }
space-telescope Secondly, you'd need some kind of compact design. A reflector for sure, but not newtonian. Some kind of Cassegrain variant, you can make those pretty short and stubby. Unless you make it so that it "unfolds" in space, but that's going to be tricky. Also, the whole optical stack has to be very rigid and must hold its shape through launch and while in space. The optical system must remain collimated at all times. Finally, you probably have some weight limits. That will make it harder to create a rigid system.
{ "domain": "astronomy.stackexchange", "id": 1048, "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": "space-telescope", "url": null }
imu, navigation, odometry, robot-localization, amcl #Frames config odom_frame: odom base_link_frame: base_link world_frame: odom Configuration of the "global" EKF node: frequency: 10 two_d_mode: true # X, Y, Z # roll, pitch, yaw # X vel, Y vel, Z vel # roll vel, pitch vel, yaw vel # X accel, Y accel, Z accel #Odometry input config odom0: /odom odom0_config: [false, false, false, false, false, false, true, true, false, false, false, true, false, false, false] odom0_differential: false odom0_relative: true #IMU input config imu0: /imu_data imu0_config: [false, false, false, false, false, false, false, false, false, true, true, true, false, false, false] imu0_differential: false imu0_relative: true imu0_remove_gravitational_acceleration: false
{ "domain": "robotics.stackexchange", "id": 26180, "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": "imu, navigation, odometry, robot-localization, amcl", "url": null }
java, performance, graphics if(Core.builderMode){ if(Core.builderModePathMode && SpriteManager.eventSpritesGet(currTile.getEventWalkPath()).pixels[tilePix] != 0xffff00ff) Game.pixels[screenPix] = SpriteManager.eventSpritesGet(currTile.getEventWalkPath()).pixels[tilePix]; if(Core.builderModeEventMode && SpriteManager.eventSpritesGet(currTile.getEventID()).pixels[tilePix] != 0xffff00ff) Game.pixels[screenPix] = SpriteManager.eventSpritesGet(currTile.getEventID()).pixels[tilePix]; }else{ if(SpriteManager.eventSpritesGet(currTile.getEventAlias()).pixels[tilePix] != 0xffff00ff) Game.pixels[screenPix] = SpriteManager.eventSpritesGet(currTile.getEventAlias()).pixels[tilePix]; } if(x >= Game.WIDTH / 2 - 16 && x <= Game.WIDTH / 2 + 16 && y >= Game.HEIGHT / 2 - 16 && y <= Game.HEIGHT / 2 + 16){//wrong
{ "domain": "codereview.stackexchange", "id": 15602, "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, graphics", "url": null }
quantum-mechanics, condensed-matter, superconductivity Title: Is the Bogoliubov quasiparticle boson or fermion? The Bogoliubov quasiparticle combines the properties of a negatively charged electron and a positively charged hole, so here we have two fermion and the quasiparticle have an integer spin. By this reason we have to consider this quasiparticle as boson, but in literature I came across with definition this one as fermion.Please, can anybody explain me what's wrong? It depends. Bogoliubov transformation has a fermion version $+$ and a boson verion $-$. $$[c,c^\dagger]_{\pm}=1 $$ The transformation is parameterized by $u$ and $v$ $$a=uc+vc^\dagger$$ $$a^\dagger=v^*c+u^*c^\dagger$$ The goal is to restore similar commute relation as $c,c^\dagger$ $$[a,a^\dagger]_{\pm}=[uc+vc^\dagger,v^*c+u^*c^\dagger]_{\pm}=(|u|^2\pm|v|^2)[c,c^\dagger]=1$$
{ "domain": "physics.stackexchange", "id": 51216, "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, condensed-matter, superconductivity", "url": null }
# Python Portfolio Optimization Cvxopt
{ "domain": "freccezena.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9632305381464927, "lm_q1q2_score": 0.8047632511380802, "lm_q2_score": 0.8354835309589074, "openwebmath_perplexity": 1894.8592761976015, "openwebmath_score": 0.26045969128608704, "tags": null, "url": "http://nrvt.freccezena.it/python-portfolio-optimization-cvxopt.html" }
```F(1:2:n) = simplify(F(1:2:n) + 2*x(1:2:n).*F(2:2:n)); F(1:2:n) = -F(1:2:n)/2; F(2:2:n) = F(2:2:n)/20;``` Now the systems of equations are identical: `F(1:10)` ```ans =  $\left(\begin{array}{c}1-{x}_{1}\\ 10 {x}_{2}-10 {{x}_{1}}^{2}\\ 1-{x}_{3}\\ 10 {x}_{4}-10 {{x}_{3}}^{2}\\ 1-{x}_{5}\\ 10 {x}_{6}-10 {{x}_{5}}^{2}\\ 1-{x}_{7}\\ 10 {x}_{8}-10 {{x}_{7}}^{2}\\ 1-{x}_{9}\\ 10 {x}_{10}-10 {{x}_{9}}^{2}\end{array}\right)$``` ### Calculate Jacobian of Matrix Representing the System of Equations Use `jacobian` to calculate the Jacobian of `F` . This function calculates the Jacobian symbolically, thus avoiding errors associated with numerical approximations of derivatives. `JF = jacobian(F,x);` Show the first 10 rows and columns of the Jacobian matrix.
{ "domain": "mathworks.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9770226314280634, "lm_q1q2_score": 0.8224827110199365, "lm_q2_score": 0.8418256492357358, "openwebmath_perplexity": 742.536380019125, "openwebmath_score": 0.7024767994880676, "tags": null, "url": "https://jp.mathworks.com/help/symbolic/examples/improving-accuracy-and-performance-in-optimization.html?lang=en" }
cosmology, black-holes, universe, event-horizon Title: Is the observable region of the universe within the event horizon of a super-massive black hole? Observations: I have read that for a free-falling observer within the event horizon of a black hole that all lines of sight will end at the singularity which is black. I also look up and see that the sky is mostly black. I also know that by measuring the red-shifts of the galaxies that they are all accelelerating towards that blackness. (rather than accelerating away from a big-bang event, which makes less intuitive sense) The red-shifts are greatest for those galaxies closest to the singularity (i.e. furthest away from us).
{ "domain": "physics.stackexchange", "id": 71053, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "cosmology, black-holes, universe, event-horizon", "url": null }
"for $n = 1$, clearly, $9\equiv 1 \pmod 8$". Then I suggest you make your inductive hypothesis explicit: "Assume that it is true that $9^n \equiv 1 \pmod 8$," and then finish with, "for the inductive step....[what you wrote]" If your task was to prove the congruence holds using proof by induction on $n$, then you've done a fine job of sketching such a proof. If you can use other strategies, then bonsoon's suggestion is worth considering: "Or note that since $9 \equiv 1 \pmod 8$, we have $9^n\equiv 1^n = 1 \pmod 8.$" - Yes, that is correct. Alternatively, prove by induction the $\,\rm n$-ary congruence product rule $$\rm\qquad\ \ a_k\equiv b_k\ \Rightarrow\ a_1\cdots\, a_n \equiv b_1\cdots\, b_n$$ by iterating the binary product rule $\rm\ a_k\equiv b_k\ \Rightarrow\ a_1 a_2 \equiv b_1 b_2,\:$ then specialize $\rm\:a_i \equiv 9,\ b_i\equiv 1$
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9859363729567545, "lm_q1q2_score": 0.834045424114149, "lm_q2_score": 0.8459424431344437, "openwebmath_perplexity": 172.18788998839227, "openwebmath_score": 0.9509916305541992, "tags": null, "url": "http://math.stackexchange.com/questions/290287/9n-equiv-1-mod-8" }
special-relativity, vectors, galilean-relativity Yes correct. This photon is a clock hand that moves inside a clock. The clock hand moves in "that direction", which we call the y-direction, at speed: $$ v_y = \sqrt {c^2-v_x^2 } $$ Or, if the photon is shot at angle $ \alpha $ then $$v_y = c * sin \alpha$$ $$v_x = c * cos \alpha$$ ,where y-direction is "that direction" and x-direction is the other direction. Shoot a photon straight up. Now you have a clock that moves at speed zero, and a clock hand that moves inside the clock at speed c. Shoot a photon at 45 degree angle. Now you have a clock that moves at speed 0.70 c, and a clock hand that moves at speed 0.70 c inside the clock.
{ "domain": "physics.stackexchange", "id": 75771, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "special-relativity, vectors, galilean-relativity", "url": null }
c, memory-management, pointers, gcc err_exit("Failed to destroy mutex for shared_ptr"); } return; } } if(pthread_mutex_unlock(&p->cntrl->mutex)){ err_exit("Failed to unlock mutex for shared_ptr"); } } }
{ "domain": "codereview.stackexchange", "id": 40652, "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, memory-management, pointers, gcc", "url": null }
c++, performance, comparative-review, gmp This makes a couple of assumptions that are important. First, it assumes that num > 0 and it dives deep into the internal structure of __mpz_struct so it will not be very durable to changes in GMP, should they decide to change the underlying representation of numbers. However, with this code, I find that it's a bit faster on my machine than the string method, both with and without -O3 optimizations. Also, note that within your range of integers, the sum of digits will always fit within a long int which will save time, but could equally be applied to the string method.
{ "domain": "codereview.stackexchange", "id": 7799, "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++, performance, comparative-review, gmp", "url": null }
cc.complexity-theory, communication-complexity, interactive-proofs, query-complexity It isn't always possible to make the prover do all the work (or even any work at all). The reason is that an MA-prover is trying to convince you that the answer is YES. But the problem can be chosen so that in the YES case, there's nothing interesting that the prover can tell you. There are hard problems for which having a YES-prover is completely useless (i.e., it will not reduce the verifier's work at all). For example, consider the AND problem, where you have to compute the AND of all the bits in the black box. This requires $\Omega(n)$ queries for a bounded-error algorithm. Now if you have access to a YES-prover, there's nothing interesting he can tell you. The most he could do is give you the entire contents of the black box. But since it is the AND function, and he is trying to convince you that the function evaluates to 1, he will always give you the all ones string. So you could have simulated this yourself.
{ "domain": "cstheory.stackexchange", "id": 1705, "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": "cc.complexity-theory, communication-complexity, interactive-proofs, query-complexity", "url": null }
python, python-3.x, programming-challenge, strings You could combine slices and compressed_str into one comprehension. If you do you don't need to use len as indexes[i+1] - indexes[i] is the length of the string. return "".join( f"{b - a}{s[a]}" for a, b in pairwise(indexes) ) def pairwise(iterable): return ( (iterable[i], iterable[i+1]) for i in range(len(iterable) - 1) ) def compress_string(s: str) -> str: if s == "": return "" indexes = [ i+1 for i in range(len(s) - 1) if s[i+1] != s[i] ] indexes = [0] + indexes + [len(s)] return "".join( f"{b - a}{s[a]}" for a, b in pairwise(indexes) ) Itertools The pairwise function could be better described using the pairwise recipe. If you utilize itertools.groupby the challenge is super easy, as it makes slices for you.
{ "domain": "codereview.stackexchange", "id": 37198, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, programming-challenge, strings", "url": null }
optics, visible-light, vision Title: Why are green screens green? How/why do green screens work? What's so special about the color green that lets us seamlessly replace the background with another image and keep the human intact? Are there other colors that work similarly? It's partly about how human colour vision works, partly about avoiding colours you want to keep, such as those of the actors. Colour cameras record concentrations of red, green and blue light to mimic human colour vision. Before digital techniques, blue screens were preferred because, of the three primary colours, that's the one rarest in human skintones. When digital cameras were invented, they were given greater sensitivity to green light to mimic a bias in human vision. Green screen doesn't require as much illumination of the screen as blue screen does, which prevents the risk of chroma spill onto the foreground subject's edge, which can cause a special effects failure called a chroma halo.
{ "domain": "physics.stackexchange", "id": 53809, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "optics, visible-light, vision", "url": null }
Ellsberg, who had leaked the Pentagon Papers para!., terms, and more with flashcards, games, and mathematics in..., f and g, are given in the first column in finding Ellsberg 's file and so. = y + x ⇒ commutative property of addition para todos to discredit Ellsberg, who leaked... To use a calculator to optimize the time of calculations el par galvánico persigue casi. Momento en el que las unidades son impo, ¿Alguien sabe qué es eso the burglary of the form +... Process is necessary because the imaginary part finding Ellsberg 's Los Angeles psychiatrist, Lewis J, Quadratic... Chapter Exam Take this practice test to check your existing knowledge of expression... Can ’ t in the first column number with both a real and an imaginary part, we! The FOIL process ( first, Outer, Inner, Last ) & ProportionsPercentModuloMean, Median & ModeScientific Notation.... Binomials '' of a sort, and other study tools browse other questions tagged complex-numbers or ask own. Imagino có el par galvánico
{ "domain": "badinansoft.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9648551525886193, "lm_q1q2_score": 0.8433579241092369, "lm_q2_score": 0.8740772351648677, "openwebmath_perplexity": 1050.656113516827, "openwebmath_score": 0.9053365588188171, "tags": null, "url": "https://ak.badinansoft.com/we-are-mexv/9a2502-operations-with-complex-numbers-quizlet" }
quantum-mechanics, soft-question If you think carefully, there is nothing surprising about it. Similar phenomena is also found in Classical Physics under the name of Poincaré recurrence time. Stable systems tend to be periodic or quasi-periodic. This has helped their study and the birth of Physics since the early days. However, as the complexity of the system increases, or in other words, as the number of eigenstates that participate in the dynamics is larger, so it will be the recurrence time, which eventually may be larger than the time related to the inverse of the precision of the Hamiltonian eigenstates, or in other words, larger than the time disposed to follow or measured the system. In fact for most physical systems the recurrence time is clearly unphysical. This is also reflected in the fact that for increasingly complex systems it becomes harder to guarantee that they are discrete and time-invariant, or closed, or isolated.
{ "domain": "physics.stackexchange", "id": 12472, "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, soft-question", "url": null }
sleep Title: Why is Sleep apnea only risk to males? I was reading this article. In Risk Factors, it clearly mention "Being a male". Why is Sleep apnea only risk to males? Wikipedia actually means that being male is a risk factor for sleep apnea, which is a jargony way of saying that males have been observed to develop sleep apnea more often than females. The article pointed out by com.prehensible suggests that this difference in the prevalence of sleep apnea between genders is due (in part) to a difference pharyngeal airway length (illustrated below), which is longer in men than in women even when corrected for (body) height. Since the pharyngeal airway lacks any bones or cartilages for structural support, the theory goes that a longer pharyngeal airway is more likely to collapse during sleep, when breathing is reduced via mild to moderate hypoventilation (in everyone). Here's an illustration (3rd one in the set below) what that collapse looks like (source):
{ "domain": "biology.stackexchange", "id": 8155, "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": "sleep", "url": null }
python, python-3.x, programming-challenge, tetris def completed_line(self): for i, line in enumerate(self): if line.count('.') == 0: yield i def clear_line(self, index): del self[index] self.data.insert(0, ['.'] * self.width) def drop(self, piece, offset): last_level = self.height - piece.height + 1 for level in range(last_level): for i in range(piece.height): for j in range(piece.width): if self.board[level+i][offset+j] == "#" == piece.piece[i][j]: return level - 1 return last_level - 1 def place_piece(self, piece, pos): level, offset = pos for i in range(piece.height): for j in range(piece.width): if piece.piece[i][j] == "#": self[level+i][offset+j] = piece.piece[i][j]
{ "domain": "codereview.stackexchange", "id": 28534, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, programming-challenge, tetris", "url": null }
python, python-3.x, unit-conversion To remedy this, I'd take everything in __init__, and move it into a regular function. To store the data, I'd use a NamedTuple returned from the function.
{ "domain": "codereview.stackexchange", "id": 35937, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, unit-conversion", "url": null }
An arbitrary subset can be viewed as a sequence heads-tails of length $n$. For example, consider the set $\{1, 2,3,4\}$ and its subset $\{2,4\}$. This subset can be viewed as the sequence tails-heads-tails-heads. Because the fair coin is flipped independently, each position has a probability of $2^{-1}$ to be heads or tails. Since length of the sequence is $n$, the sequence will be formed with probability $2^{-n}$. (b) Calculate $Pr(X \subseteq Y)$: Using the principle of deferred decision, suppose that we already chose a subset $X$ with $a$ elements($a = 0, \ldots ,n$). For every subset $X$ which has $a$ elements, $Pr(X \subseteq Y) = 2^{-a}$. Now consider the process of choosing $X$. There are $\binom{n}{a}$ different subsets of $\{1,\ldots ,n\}$ which has $a$ elements ($a= 0, \ldots, n$), each subset is  equally likely to be chosen with probability $2^{-n}$. Therefore:
{ "domain": "wordpress.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9822877044076955, "lm_q1q2_score": 0.807626275749243, "lm_q2_score": 0.8221891327004132, "openwebmath_perplexity": 152.40979752113662, "openwebmath_score": 0.9559769630432129, "tags": null, "url": "https://thethong.wordpress.com/2009/09/26/probability-and-computing-chapter-1-exercises-cont-4/" }
telescope, space, space-telescope Although there are a few differences that one ought to be aware of. NASA has an entire program of telescopes to observe the universe, and many of them are designed for different wavelengths of light. The James Webb is primarily designed for the infrared part of the spectrum. While many people view the Webb as the successor to the Hubble, it would be more fair to say that it's really a successor to the Spitzer Telescope. Hubble and Spitzer were both part of the "Great Observatories" program. The Webb telescope is barely hanging on to funding, but so far the US hasn't managed to entirely abandon the program, science, or reality.
{ "domain": "astronomy.stackexchange", "id": 117, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "telescope, space, space-telescope", "url": null }
javascript, jquery, event-handling, dom How can I remove redundancy in the following code? jQuery(document).ready( function($) { $(document.body).on( 'DOMNodeInserted click', '.media-modal', function( event ) { var test = $('label.setting[data-setting=alt] input:visible').val(); var test2 = $('input[data-setting=alt]:visible').val(); if (!test && !test2) { $('.media-modal .media-button-insert').prop("disabled",true); $('.media-modal .media-button-select').prop("disabled",true); } else { $('.media-modal .media-button-insert').prop("disabled",false); $('.media-modal .media-button-select').prop("disabled",false); } $(document.body).on( 'input propertychange paste', 'label.setting[data-setting=alt] input, input[data-setting=alt]', function( event ) { var test = $('label.setting[data-setting=alt] input:visible').val(); var test2 = $('input[data-setting=alt]:visible').val();
{ "domain": "codereview.stackexchange", "id": 26101, "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, event-handling, dom", "url": null }
Edit: I also find this "steel trap" analogy very depressing. While it might seem that way in some textbooks, a properly presented proof should feel more like a poem. Edit #2: I'd also like to mention that the general outline of Polya's advice is on Wikipedia. - It seems you are asking two questions. The first is how to get better at doing proofs, and the previous answers are better than I can do. The second is why to do them, which has not been addressed. From your questions on this site, you seem more an engineer than a mathematician. This is not a negative-I am educated as a physicist and practicing as an engineer(ing manager), but I enjoy proof-type math. It just is a different view.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9399133481428691, "lm_q1q2_score": 0.8199309510353371, "lm_q2_score": 0.8723473846343394, "openwebmath_perplexity": 406.96050821812446, "openwebmath_score": 0.716921329498291, "tags": null, "url": "http://math.stackexchange.com/questions/7743/getting-better-at-proofs" }
https://leetcode.com/problems/climbing-stairs/ """ class Solution: def climbStairs(self, n): return self.helper(n) # in case we reach remaining=0, then we have found way (a correct set of steps) def helper(self, remaining, store={0: 1}): # store={0:1} is a base case if remaining < 0: return 0 if remaining in store: return store[remaining] total = self.helper(remaining-1, store) + \ self.helper(remaining-2, store) store[remaining] = total return store[remaining] """ Staircase Traversal: You're given two positive integers representing the height of a staircase and the maximum number of steps that you can advance up the staircase at a time. Write a function that returns the number of ways in which you can climb the staircase. For example, if you were given a staircase of height = 3 and maxSteps = 2 you could climb the staircase in 3 ways. You could take 1 step, 1 step, then 1 step, you could also take 1 step, then 2 steps, and you could take 2 steps, then 1 step.
{ "domain": "paulonteri.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9559813501370535, "lm_q1q2_score": 0.8218225111577803, "lm_q2_score": 0.8596637487122111, "openwebmath_perplexity": 6090.381773024074, "openwebmath_score": 0.30743175745010376, "tags": null, "url": "https://dsa.paulonteri.com/Data%20Structures%20and%20Algorithms%2016913c6fbd244de481b6b1705cbfa6be/Recursion%2C%20DP%20%26%20Backtracking%20525dddcdd0874ed98372518724fc8753.html" }
To see what it means that the statistic is scale invariant, consider a table that summarizes an experiment that was $$1/10$$th of the size, but otherwise had the same relative counts. O2 <- O/10 r2 <- rowSums(O2) c2 <- colSums(O2) N2 <- sum(r2) tab2 <- rbind(O2, c2) tab2 <- cbind(tab2, c(r2, N2)) colnames(tab2)[ncol(tab)] <- rownames(tab2)[nrow(tab)] <- "tot" tab2 ## R D I tot ## M 20 15 5 40 ## F 25 30 5 60 ## tot 45 45 10 100 E2 <- outer(r2, c2/N2) t2 <- sum((O2-E2)^2/E2) Ccc2 <- sqrt(t2/(N2*(min(length(r2),length(c2))-1))) Ccc2 ## [1] 0.1272938 • Same result! The same would be true of a larger experiment. # Pearson’s contingency coefficients There are two coefficients attributed to Karl Pearson, which as you can see are simplifications of Cramér’s contingency coefficient. \begin{aligned} R_2 &= \sqrt{\frac{T}{N+T}} && \mbox{and} & R_3 = \frac{T}{N}. \end{aligned}
{ "domain": "gramacy.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9857180669140007, "lm_q1q2_score": 0.8104466739337495, "lm_q2_score": 0.822189123986562, "openwebmath_perplexity": 3656.1814098739756, "openwebmath_score": 0.8500341176986694, "tags": null, "url": "http://bobby.gramacy.com/teaching/np/depend.html" }
python Title: PyPi Keyboard - Seeing "Shortcut" characters printed on break from their loop? import keyboard import os import sys from colorama import Fore, Back, Style, init init() clear = lambda: os.system('cls') cwd = os.getcwd() header = """ ____ _ ____ _ _ _ ___ _ / ___|___ (_)_ __ / ___|__ _| |_ _| | __ _| |_ ___ _ __ / _ \\ / | | | / _ \\| | '_ \\ | | / _` | | | | | |/ _` | __/ _ \\| '__| | | | || | | |__| (_) | | | | | | |__| (_| | | |_| | | (_| | || (_) | | | |_| || | \\____\\___/|_|_| |_| \\____\\__,_|_|\\__,_|_|\\__,_|\\__\\___/|_| \\___(_)_| Omar "Michael Abdo" 2019 'Q' to Quit """ def end(): print(Style.BRIGHT + Fore.RED + "\n\n\t\tCLOSING.") os._exit(0)
{ "domain": "codereview.stackexchange", "id": 33615, "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 }
ubuntu-trusty, ubuntu, ros-indigo Title: Indigo on Trusty Hey, So I wanted to go ahead of time and install indigo on ubuntu trusty (14.04), but found out the binaries are incomplete? ros-indigo-desktop* doesn't exist at least. Many binaries do seem to exist, I thought maybe I could install all of them and have a working ROS, but alas, no catkin_make even. Is this a matter of waiting? Or can I do something? (preferably without going towards installing from source) Best regards, Hans edit: Just tried to build from source as well, the rosinstall_generator fails with : The following not released packages/stacks will be ignored: desktop-full No packages/stacks left after ignoring not released Originally posted by Hansg91 on ROS Answers with karma: 1909 on 2014-04-18 Post score: 1
{ "domain": "robotics.stackexchange", "id": 17696, "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": "ubuntu-trusty, ubuntu, ros-indigo", "url": null }
c, converting return *n; } static inline int ensurebase(int b) { if (b < 2 || b > 36) _throwerror(1, "Unsupported base: %d", b); return b; } You have created a header file, but it's not clear why. Your code is not constructed as a library that others can call, but is a standalone program. A lot of the things you have put in the header file are specific to the implementation of your program. For just one example, BUF_SIZE is not relevant to any other code that might call your functions. Another example, iseven() and isodd() are internal functions that don't need to be in a header file. Your implementations of iseven() and isodd() macros do not properly parenthesise their arguments. Instead use: #define iseven(n) ((n) % 2 == 0) #define isodd(n) ((n) % 2 != 0)
{ "domain": "codereview.stackexchange", "id": 15488, "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, converting", "url": null }
planets, magnetic-fields The solar dynamo is the physical process that generates the Sun's magnetic field. The Sun is permeated by an overall dipole magnetic field, as are many other celestial bodies such as the Earth. The dipole field is produced by a circular electric current flowing deep within the star, following Ampère's law. The current is produced by shear (stretching of material) between different parts of the Sun that rotate at different rates, and the fact that the Sun itself is a very good electrical conductor (and therefore governed by the laws of magnetohydrodynamics). The earth's magnetic field is modeled Walter M. Elsasser, considered a "father" of the presently accepted dynamo theory as an explanation of the Earth's magnetism, proposed that this magnetic field resulted from electric currents induced in the fluid outer core of the Earth. He revealed the history of the Earth's magnetic field through pioneering the study of the magnetic orientation of minerals in rocks. In particular
{ "domain": "physics.stackexchange", "id": 7647, "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": "planets, magnetic-fields", "url": null }
ros, turtlebot, 2d-mapping, nav2d-tutorials, nav2d Original comments Comment by zzzZuo on 2016-05-09: Has your problem solved? I also have a similar problems that I couldn't receive a map after it roslaunch. Comment by Gonzalo Hernández R on 2016-05-27: Yes, the problem was with the hokuyo description in the urdf. The hokuyo in gazebo was upside down but the base_laser_link frame was not, so the mapper didn't know how to manage that measures. Are you running a real robot or simulation? Your scans seem to come from gazebo, but "cmd_vel" doesn't seem to go into gazebo. Your global map looks somewhat distorted like from some error in the transformation tree. You should check the tf-tree with "rosrun tf view_frames". Update: An inverted scan-frame would explain the weird behavior when the robot is turning. In your video 2 it also looks like the scan is under the map, can you verify this? Can you check which coordinate frame the laser-scan is defined in (likely it is base_laser_link) and visualize this in RVIZ?
{ "domain": "robotics.stackexchange", "id": 23463, "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, turtlebot, 2d-mapping, nav2d-tutorials, nav2d", "url": null }
c#, pdf, sharepoint word.Visible = false; word.ScreenUpdating = false; // I think this can actually be done away with and all oMissing parameters removed, as C# can handle optional parameters ... object oMissing = System.Reflection.Missing.Value; // for adding the file name to the temporary pdf files int counter = 1; foreach (FileInfo wordFile in wordFiles) { // Cast as object for word open method Object fileName = (Object)wordFile.FullName;
{ "domain": "codereview.stackexchange", "id": 18005, "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#, pdf, sharepoint", "url": null }
algorithms, artificial-intelligence, genetic-algorithms All freshly laid eggs in (A) are collected in record time. Our algorithm has learned some tricks about navigating gardens; like driving a car for the first time. But there is more. If I now put the same robot in a different garden (B), it may or may not do OK. It depends, I suppose, on how similar (B) is to (A) in certain key factors, i.e., will any of the tricks learned in (A) apply here? The likelihood is it will need new tricks, so I'm going to have evolve it further in (B) if I want anything like an optimal solution. Yet if I don't, at every iteration, continue to test it in (A) too, then I may be losing fitness for (A) in every new generation, yes?
{ "domain": "cs.stackexchange", "id": 7171, "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": "algorithms, artificial-intelligence, genetic-algorithms", "url": null }
# Math Help - Newton's method 1. ## Newton's method I need help on a Newton's Method problem. I have to "Use Newton's method to approximate the given number correct to eight decimal places". The number is the hundredth root of 100 (100^(1/100)). When done on calculator, the result is 1.04712855. I've tried the approximation but am not able to get close. The method is Xn+1=Xn-(f(n)/f'(n)) Thanks 2. So what are you using for f(x) and f'(x)? Can you show me at least one iteration of what you've been trying so I can see where you went wrong? 3. From the examples I've seen on the book, f(x) = x^(100)-100 and f'(x) = 100x^99 I've tried using n=1, n=2, n=3, also tried big numbers and cannot seem to come up with the true approximation. 4. Originally Posted by djo201 From the examples I've seen on the book, f(x) = x^(100)-100 and f'(x) = 100x^99
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9763105273220727, "lm_q1q2_score": 0.8027119078320741, "lm_q2_score": 0.822189134878876, "openwebmath_perplexity": 402.0275258364898, "openwebmath_score": 0.8057224154472351, "tags": null, "url": "http://mathhelpforum.com/calculus/59404-newton-s-method.html" }
c++, c, callback I do have some constraints in my case, for example I can't use STL, since the code is supposed to run on an embedded system. So, how bad is my code? Encapsulate stuff that shouldn't be public I'd rather make the callback functions private static functions of the c++ class This helps to encapsulate the nasty void*casts: #ifdef __cplusplus class Foo { public: Foo(); int getValue() const; void setValue(int value); void register_callbacks(); private: int value_; static int cb_getValue(void *arg1); static void cb_wrapper_setValue(int value, void *arg1); }; #endif Implementation: void Foo::register_callbacks() { register_handler(Foo::cb_getValue, Foo::cb_setValue, static_cast<void *>(this)); } void Foo::cb_setValue(int value, void *arg1) { Foo* foo_instance = static_cast<Foo*>(arg1); foo_instance->setValue(value); } int Foo::cb_getValue(void *arg1) { Foo* foo_instance = static_cast<Foo*>(arg1); return foo_instance->getValue(); }
{ "domain": "codereview.stackexchange", "id": 38562, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, c, callback", "url": null }
thermodynamics, work, reversibility However, it is still possible to get the work if you are able to apply the laws of fluid mechanics and a differential version of the first law locally within the cylinder. This involves solving a complicated set of partial differential equations to determine the temperature, pressure, stresses, and deformations as functions of time and position. Usually, such calculations would be accomplished using Computational Fluid Dynamics (CFD). The deformations inside the cylinder could be turbulent, and this would require CFD capabilities to approximate turbulent flow and heat transfer. So, for irreversible processes, predicting the behavior in advance can be much more complicated (but possible).
{ "domain": "physics.stackexchange", "id": 38197, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "thermodynamics, work, reversibility", "url": null }
signal-analysis, wave, source-separation I take in a 1D signal containing a sentence, split this sentence up into different parts which contain this data: vect[0], vect[1], .... vect[4] Let's say in matlab I did the following command wavwrite(vect[0], ....) then it would output the word "My" and putting all the blocks together would give me the full sentence back. Here is my "real-world problem" instead of Phonemes, I have bat calls, the length of each bat call is unknown at this stage. But here is a typical sample of a bat call: Here and for each of these bat calls, these need to be separated from the inputted signal and stored inside a vector (Just like the example above), this, then allows me to identify each of the bats and perform analysis on them. This, like, the sample would give me a 2D vector containing each of the bat calls: "Bat1", "Bat2" ..... "Bat[n]" it is unknown the amount of time the bats have been recorded for, or, what the length of each of the bat call therefore is. What I have done so far:
{ "domain": "dsp.stackexchange", "id": 1181, "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-analysis, wave, source-separation", "url": null }
In [80]: #collapse-hide show_image(Image.open(threes_train[1])) Out[80]: <AxesSubplot:> The first thing we want to do is to load the training images into tensors. In [81]: three_train_tensors = [tensor(Image.open(o)) for o in threes_train] seven_train_tensors = [tensor(Image.open(o)) for o in sevens_train] # lets see how many tensors we have len(three_train_tensors), len(seven_train_tensors) Out[81]: (6131, 6265) Each tensor contains a pixel matrix, the values in the matrix describe the color of each pixel on a grey scale. A 0 indicates a white pixel and a 255 indicates a black pixel. For example, row and column 4 to 10 from the pixel matrix of the three above looks like so. In [82]: three_train_tensors[1][4:10,4:10] Out[82]: tensor([[ 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 29], [ 0, 0, 0, 48, 166, 224], [ 0, 93, 244, 249, 253, 187], [ 0, 107, 253, 253, 230, 48], [ 0, 3, 20, 20, 15, 0]], dtype=torch.uint8)
{ "domain": "nbviewer.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9683812336438725, "lm_q1q2_score": 0.8005721849428639, "lm_q2_score": 0.8267117919359419, "openwebmath_perplexity": 1002.0799698953714, "openwebmath_score": 0.6479559540748596, "tags": null, "url": "https://nbviewer.org/github/MoeweX/jupyter-blog/blob/master/_notebooks/2021-09-12-broadcasting.ipynb" }
javascript // Now the bit that I really can't wrap my head around enable : function() { var self = this; if ( ! self.callbacks ) { self.callbacks = {}; } self.fireCallback = function(event, args) { Extension.fireCallback.call(self, event, args); }; self.addCallback = function(event, fn) { Extension.addCallback.call(self, event, fn); }; } } There is some form of JS voodoo going on here that I can't programatically work out, can anyone help me shed light on how JS is interpreting this and why when I call: Extension.enable.call(this); within a class scope, the Extension object seems to extend the calling objects prototypes allowing me to bind a callback within the class scope. And then attach a handler after I have instantiated the class. function Bar() { Extension.enable.call(this); // Do stuff this.fnCallback = function() { this.fireEvent('complete'); } }
{ "domain": "codereview.stackexchange", "id": 2646, "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", "url": null }
Mark Wadsworth: Economic Myths: Governments don't issue currency. he same thing and there are the same two sides to each of them - the issuer/borrower has a financial LIABILITY and the holder of the mortgage, bank notes, bank deposit, IOU etc. has a financial ASSET. It always nets off to precisely zero. So <span>the government can pay people with coins and notes, bank deposits, new bonds, or simply pay a supplier over an extended credit period. It is all shades of the same thing. It does not need to borrow a penny beforehand. It is the expenditure which creates the liability and asset, collectively referred to as "money". ------------------------------------------------------------- As a quite separate matter, having printed or issued currency, the government also claws back or unprints money by collectin #### Annotation 150891240 #economics #money government SPENDING creates money, in the same way as government TAXATION destroys money.
{ "domain": "buboflash.eu", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9914225143328518, "lm_q1q2_score": 0.8304352860845532, "lm_q2_score": 0.8376199592797929, "openwebmath_perplexity": 5089.82326652057, "openwebmath_score": 0.7020999789237976, "tags": null, "url": "https://buboflash.eu/bubo5/whats-new-on-day?day-number=42137" }
fourier-transform, continuous-signals, power-spectral-density, signal-power, signal-energy $R_{xx}(t)$ (for stationary $x(t)$) is defined as ensemble average: \begin{align} R_{xx}(t) = \langle x(t)x(0) \rangle = \int yz f_{x(t),x(0)}(y,z) dy dz \end{align} $f_{x(t),x(0)}(y,z)$ is the joint probability density function for the random variables $x(t)$ and $x(0)$ so it has dimensions of $[\text{signal}^{-2}]$. time average: \begin{align} R_{xx}(t) = \langle x(t)x(0) \rangle = \lim_{\Delta t \rightarrow \infty} \frac{1}{\Delta t} \int_{t'=-\frac{\Delta t}{2}}^{\frac{\Delta t}{2}} x(t'+t)x(t') dt' \end{align}
{ "domain": "dsp.stackexchange", "id": 8543, "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": "fourier-transform, continuous-signals, power-spectral-density, signal-power, signal-energy", "url": null }
$\displaystyle \dfrac{a^4-b^4}{a-b} \;=\; a^3 + a^2b + ab^2 + b^3$ $\displaystyle \dfrac{a^5 - b^5}{a-b} \;=\;a^4 + a^4b + a^2b^2 + ab^3 + b^4$ Get it? Hence: .$\displaystyle \dfrac{a^n-b^n}{a-b} \;=\;a^{n-1} + a^{n-2}b + a^{n-3}b^2 + \hdots + a^2b^{n-3} + ab^{n-2} + b^{n-1}$ Thanks for your reply. I'm having trouble trying to figure out how to solve this problem using the long division. I'm feeling like an idiot , can you please show me how to do it. If there's only one variable I can do it in seconds without the calculator but add a second variable and I'm lost. 7. Originally Posted by levan55604 Thanks for your reply. I'm having trouble trying to figure out how to solve this problem using the long division. I'm feeling like an idiot , can you please show me how to do it. If there's only one variable I can do it in seconds without the calculator but add a second variable and I'm lost. I figured it out. Here's how to do it: for example if we have (27a^3-8b^3)/(3a-2b)
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9838471651778591, "lm_q1q2_score": 0.8240900264218388, "lm_q2_score": 0.8376199633332891, "openwebmath_perplexity": 1412.4295019079975, "openwebmath_score": 0.7936175465583801, "tags": null, "url": "http://mathhelpforum.com/pre-calculus/164103-binomial-division.html" }
Here is a working solution: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 int main() { int n; cin >> n; int k; cin >> k; vector data; for (size_t i = 0; i < n; i++) { int val; cin >> val; data.push_back(val); } sort(data.begin(), data.end()); size_t count = 0; for (size_t i = 0; i < data.size(); ++i) { if (binary_search(data.begin() + i + 1, data.end(), data[i] + k)) count++; } cout << count; } An even more fine-tuned version has been proposed by Davide Malvezzi: the search range can be made smaller by setting the end at most k steps far from the beginning (the smaller k than n, the more convenient), and the beginning is either i + 1 or one element after the result of the last successful search. For example, suppose we have: 1 1 4 7 9 And we look for pairs whose difference is k=6. When we start, the search spans from 1 to 1+k: 1 2 1 3 4 5 6 7 8 9 ^ ^ And we find 7: 1 2 1 3 4 5 6 7 8 9 ^ * ^
{ "domain": "coding-gym.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9865717480217661, "lm_q1q2_score": 0.8462497859116404, "lm_q2_score": 0.8577681122619883, "openwebmath_perplexity": 1051.1212590924183, "openwebmath_score": 0.3807850480079651, "tags": null, "url": "https://coding-gym.org/challenges/pairs/" }
r, rna-seq, differential-expression, deseq2, rna Title: Selection of differential expressed genes I'm working with RNA-seq data. I have 40 tumor samples and 5 Normal samples. Differential analysis with Deseq2 based on Fold change > 1.2 and alpha < 0.05 gave very low number of differentially expressed genes. Only 2 upregulated genes. res <- results(dds, lfcThreshold = log2(1.2), alpha = 0.05) To get more number of differential expressed genes I have few questions now Instead of FDR < 0.05 can I use FDR < 0.1 (or) FDR < 0.5. Will there be any low confidence with this? Can I select differential expressed genes only based on FDR < 0.05 without any fold change cutoff? As I get very low number of DEGs with FDR < 0.05 & Foldchange > 1.2, Can I select DEGs based on Foldchange > 1.2 and p.value < 0.01 or 0.05 ?
{ "domain": "bioinformatics.stackexchange", "id": 636, "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": "r, rna-seq, differential-expression, deseq2, rna", "url": null }
If preferred, the exercises can be attacked head on. The exercises are also intended to be a guided tour. Hints are also provided below. Two sets of hints are given – Hints (blue dividers) and Further Hints (maroon dividers). The proofs of certain key facts are also given (orange dividers). Concluding remarks are given at the end of the post. $\text{ }$ $\text{ }$ $\text{ }$ $\text{ }$ $\text{ }$ $\text{ }$ Hints for Exercise 2.A Prove that the Lindelof property is hereditary with respect to closed subspaces. That is, if $X$ is a Lindelof space, then every closed subspace of $X$ is also Lindelof. Prove that if $X$ is a Lindelof space, then every closed and discrete subset of $X$ is countable (every space that has this property is said to have countable extent). Show that the product of uncountably many copies of the real line does not have countable extent. Specifically, focus on either one of the following two examples.
{ "domain": "wordpress.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9850429107723176, "lm_q1q2_score": 0.8372580846858609, "lm_q2_score": 0.8499711794579723, "openwebmath_perplexity": 128.38624810648136, "openwebmath_score": 0.9707801342010498, "tags": null, "url": "https://dantopology.wordpress.com/category/lindelof-space/" }
reference-request, optimization, set-cover Now you can apply an off-the-shelf ILP solver to this ILP instance.
{ "domain": "cs.stackexchange", "id": 3377, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "reference-request, optimization, set-cover", "url": null }
planet, orbit, astrophysics, asteroids, comets Does that mean that they have very strong mathematical evidence for Planet Nine? I did a little digging and I found this article. It's worth noting that the initial publication wasn't about resonances but the fact that all 6 objects came from the same side of the sky, from somewhat similar directions, which, given that they were the 6 most distant at the time, is statistically unusual and it was both similar direction and similar inclination to the plane, so the statistical improbability was high enough to investigate. Orbital resonance wasn't the primary argument, it was tacked on later as a secondary. From the article:
{ "domain": "astronomy.stackexchange", "id": 1942, "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": "planet, orbit, astrophysics, asteroids, comets", "url": null }
neural-networks, homework $$ \begin{aligned} \frac{\delta L}{\delta w_6} &= \frac{\delta L}{\delta \hat{y}} \cdot \frac{\delta \hat{y}}{\delta w_6} \\ &= \left(\hat{y}-y\right)O_2\left(O_3 \left(1-O_3\right)\right)\\ &= \left(O_3-y\right)O_2\left(O_3 \left(1-O_3\right)\right) \end{aligned} $$ The answer key says it should be $\left(O_3-y\right)O_2$. Where did I go wrong? For the first problem your $O_2$ is mistaken and should be corrected as below $$ \begin{aligned} O_2 &= \text{Sig} \left( -0.6 - 0.1 \cdot 2 + 0.2 \cdot 6 \right) \\ &= \text{Sig} \left( 0.4 \right) \\ &\approx 0.5987 \\ \end{aligned} $$ $$ \begin{aligned} O_3 &= \text{Sig} \left( 0.6 - 0.3 \cdot 0.5987 + 1.6 \cdot 0.5 \right) \\ &\approx 0.7721 \\ \end{aligned} $$ $$ \begin{aligned} p\left(C=1 | x; w,b\right) = O_3 \approx 0.7721 \end{aligned} $$ For the second problem thus corrected to: $$ \begin{aligned} p\left(C=0 | x; w,b\right) = 1 - \left(C=1 | x; w,b\right) = 0.2279 \end{aligned} $$
{ "domain": "ai.stackexchange", "id": 3603, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "neural-networks, homework", "url": null }
context parametric and polar equations. Ron Larson + 1 other. Trigonometry (10th Edition) answers to Chapter 8 - Complex Numbers, Polar Equations, and Parametric Equations - Section 8. We will discuss the polar (trigonometric) form of complex numbers and operations on complex numbers. Area under one arc or loop of a parametric curve. I don't know what to do from here or if I'm going in the right direction or not. Thanks for contributing an answer to Mathematics Stack Exchange! Finding cartesian equation for trigonometric parametric forms. Simplify (x −7)2 ( x - 7) 2. Example 1: 3, 4 1, for -4 t 2xt y t dd 2 2 Example 2: 2, , ( , )xt y t fortin ff t x y 5/7/19 9. Fill in the table and sketch the parametric equation for t [-2,6] x = t2 + 1 y = 2 – t 5 6 Problems 2 – 10: Eliminate the parameter to write the parametric equations as a rectangular equation. Example 1 - Graphing Parametric Equations; Example 2 - Parametric to Rectangular Form; Day 2 - 7. T= Ncos𝜃 U= N O𝑖𝜃 N P 𝜃= U T −.
{ "domain": "outdoortown.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9780517456453798, "lm_q1q2_score": 0.8646361687069855, "lm_q2_score": 0.8840392878563336, "openwebmath_perplexity": 665.260664865313, "openwebmath_score": 0.822030246257782, "tags": null, "url": "http://aipc.outdoortown.it/parametric-to-rectangular-with-trig.html" }
theta. And inductor in parallel form '' widget for your website, blog, Wordpress, Blogger, or.... Order to work with formulas developed by French mathematician Abraham de Moivre ( 1667-1754 ) we will learn how enter... Are real numbers, while i is the combination of real and numbers! Tutorial, Description Features Update information Download, Basics calculation results Desktop form presented... 9 on my Sharp rectangular and polar forms impedance of a complex to! Vector \ ( |z|\ ) of the number is a different way to represent complex... A fast and simple method to convert complex numbers to polar form - calculator of... Set the complex number to polar form of the complex number to polar and exponential:! Are clockwise, multiply and divide complex numbers in rectangular form of a complex number trigonometric... Expression, with steps shown, using the cis operator F. 8 and 9 my..., Description Features Update information Download, Basics calculation results Desktop setting the mode (
{ "domain": "com.br", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9559813463747181, "lm_q1q2_score": 0.8305821848206507, "lm_q2_score": 0.8688267694452331, "openwebmath_perplexity": 776.9305106613202, "openwebmath_score": 0.8601990342140198, "tags": null, "url": "http://diagramma.com.br/amish-oak-vlnacm/ec2dee-complex-number-to-polar-form-calculator" }
kinematics, definition Title: Polar radius and position vector: two-dimensional kinematics for high school students We consider for example this image, which is a polar graph of a naval unit's on-board instrumentation with vector radius (or polar radius) $\rho$ and anomaly $\theta$ or polar angle. We know that a point $P=(x,y)$ in an orthogonal Cartesian coordinate system may be identified in a polar diagram with coordinates $P\equiv(\rho,\theta)$ or viceversa.
{ "domain": "physics.stackexchange", "id": 71321, "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": "kinematics, definition", "url": null }
python, python-3.x, beautifulsoup I have loops and list comprehensions to get the tags, associate data with tags for each row, and to generate the line protocol lines. I have two additional comprehensions in those and a loop to see if I need to strip out an included unit of measure. Can I eliminate some of these to be more efficient? I am running all of this code on Python 3.6.7. Example Table to show field values (this is NOT the HTML table) Channel Lock Status Modulation Channel ID Frequency Power SNR Correctables UnCorrectables 1 Locked QAM 256 121 585000000 Hz 4.9 dBmV 37.0 dB 20513 11263 2 Locked QAM 256 6 591000000 Hz 5.0 dBmV 37.0 dB 20571 9512 3 Locked QAM 256 7 597000000 Hz 4.9 dBmV 36.8 dB 18347 9736 4 Locked QAM 256 8 603000000 Hz 5.1 dBmV 37.0 dB 13391 11156
{ "domain": "codereview.stackexchange", "id": 34085, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-3.x, beautifulsoup", "url": null }
python, pygame def set_position(self, x_or_x_and_y, y=None): if y != None: self.rect.x = x_or_x_and_y self.rect.y = y else: self.rect.x = x_or_x_and_y[0] self.rect.y = x_or_x_and_y[1] So, if a text is supposed to increase to the left, all that I have to do is initialize a Text object with the left_orientation parameter set to True and, whatever the rect is, it will update itself to remain at it's original position. Is this a good solution? If not, what would be a better one? This is copied from my answer to your question "What about my Pong game?".
{ "domain": "codereview.stackexchange", "id": 4585, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, pygame", "url": null }
homework-and-exercises, newtonian-mechanics Title: Need help with knowing when I should use $KE = \frac12mv^2$ or $V_f^2 = V_0^2 + 2ad$, in order to find final velocity I'm looking at this pdf for question 15.b) and I figure out $V_f$ by using $V_f^2 = V_0^2 + 2ad$, but the answer says $W = \Delta PE = \frac12mV_f^2$, and our answers ending up totally different, can someone please explain to me whats going on? The $v_f^2 = v_0^2+2ad$ equation only works under constant acceleration. Based on the graph, you can see that the force $F$ keeps changing, so the kinematic equation above does not apply, since the acceleration $a$ will not be constant. The work-kinetic energy theorem (or conservation of energy) $W_\text{net}=\Delta \rm KE$ is true for any acceleration. And since you found out the net work (work by spring force), you can find the change in kinetic energy, and subsequently, the speed.
{ "domain": "physics.stackexchange", "id": 81240, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "homework-and-exercises, newtonian-mechanics", "url": null }
quantum-fourier-transform Title: How does the QFT represent the frequency domain? QFT is often explained through the classical analogue which converts a certain function from the time domain to the frequency domain. When looking at the discrete Fourier transform, it makes sense to see a sin wave become a spike at a certain frequency. However, I don't see how this "frequency domain" notion applies to the quantum fourier transform. How does the Fourier basis represent this frequency domain? If we apply a QFT on a quantum "sin wave" will it output a certain frequency? The Fourier transform is more general than moving from the time domain to the frequency domain. For example, physicists regularly Fourier transform from position space to momentum space.
{ "domain": "quantumcomputing.stackexchange", "id": 2268, "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-fourier-transform", "url": null }
Yet another approach was suggested in a comment to the question: exploit a geometric distribution. This refers to analyzing the process according to how many rolls you will have before dying. To deal hit points, imagine rolling the die, with its "death" face removed parallel with flipping a (biased) coin, whose function is to determine whether you die. (Thus, in the situation of the question, each of the 19 remaining sides of the die--including the $$0,$$ which must be left in--has a $$1/19$$ chance; more generally, the side with value $$\omega$$ has a chance $$p(\omega)/(1-p_{*}).$$) The two sides of the coin are "death" (with probability $$p_{*}$$) and "continue" (with probability $$1-p_{*}$$). At each turn you separately roll the truncated die and flip the coin, accumulating hit points until you reach the threshold $$T$$ or the coin turns up "death."
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9783846662919581, "lm_q1q2_score": 0.8296386598248712, "lm_q2_score": 0.8479677660619633, "openwebmath_perplexity": 604.873426220533, "openwebmath_score": 0.7726212739944458, "tags": null, "url": "https://stats.stackexchange.com/questions/549334/probability-of-defeating-a-dragon-in-one-turn-rolling-a-20-sided-die/549387" }
circular cylinder. The Attempt at a Solution I know this. OX and OY axes are in the. 5⋅m)2+(7⋅kg)(4. The moment of inertia of an area with respect to any axis not through its centroid is equal to the moment of inertia of that area with respect to its own parallel centroidal axis plus the product of the area and the square of the distance between the two axes. ) I know I = (1/12)(M)(L^2) and then I need to use the parallel-axis theorem so I need to add Mh^2 but that is not working. Just as with mass in the linear case, it requires a force to change. pdf), Text File (. The moments of inertia found in textbooks are usually calculated with respect to an axis passing through the object's center of In many cases, the moment of inertia can be calculated rather easily using the parallel-axis theorem. Apply theorem of the parallel axis and the total moment of inertia will be the sum of the moment of inertia of each rod. Since we have a compound object in both cases, we can use the parallel-axis
{ "domain": "opera11bbparma.it", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9867771786365549, "lm_q1q2_score": 0.8157803295921193, "lm_q2_score": 0.8267117919359419, "openwebmath_perplexity": 208.34489284734323, "openwebmath_score": 0.6377691030502319, "tags": null, "url": "http://lcou.opera11bbparma.it/use-the-parallel-axis-theorem-to-show-that-the-moment-of-inertia-of-a-thin-rod.html" }
computer-vision, linear-algebra, projective-transformations Suppose I have points $p_1, p_2, p_3, p_4$ in the first image and $p'_1, p'_2, p'_3, p'_4$ in the second. How am I going to generate the homography matix given these points. To understand homographies and how to find them, you will need a good dose of projective geometry. I will briefly describe some preliminary concepts that you need to know before trying to find the homography, but don't expect to understand all these concepts with one reading iteration and only by reading this answer, if you are not familiar with them, especially, if you don't even know what homogenous coordinates are. For more details, I suggest you read the book Multiple view geometry in computer vision (2004) by Richard Hartley and Andrew Zisserman, in particular, chapter 4. The projective space $\mathbb{P}^2$
{ "domain": "ai.stackexchange", "id": 1961, "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": "computer-vision, linear-algebra, projective-transformations", "url": null }
c# Are there supposed to be "clearer" names althought it's impossible to manually set these values and it should be clear that these methods are meant to retrieve the values? Placement of methods: While the CalculateReserves() and CalculateCashflows() methods actually make sense on the square since they only need the values stored inside a square, they make no sense at all when the claims/losses strored in the sqaure have not been developed from a triangle by a reserviong method. Again on the other hand, putting that inside a reserving method, even inside an abstract base class, would lead to code duplications when I added simulation based methods. Is it better to place the method on the object "it's working on" or on the class that provides the logic that makes the meaningful execution of the method possible? Memoization: Inside the reserving methods, basically everything is memoized, e.g.: public Square Projection() { if (projection == null) {
{ "domain": "codereview.stackexchange", "id": 36927, "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#", "url": null }
from which it is easy to get $$F_{2n} = F_n L_n,$$ (where $L_n$ is the $n$-th Lucas number) and we have only to prove $$L_n= F_n+2F_{n-1},$$ that is true since $\{L_n\}_{n\in\mathbb{N}}$ and $\{F_n+2F_{n-1}\}_{n\in\mathbb{N}}$ are sequences with the same characteristic polynomial ($x^2-x-1$) and the same starting values $L_1=F_1+2F_0=1$, $L_2=F_2+2F_1=3$. -
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9820137863531804, "lm_q1q2_score": 0.9096430339985054, "lm_q2_score": 0.9263037308025664, "openwebmath_perplexity": 681.1956827471885, "openwebmath_score": 0.8712043166160583, "tags": null, "url": "http://math.stackexchange.com/questions/213655/fibonacci-equality-proving-it-someway/213675" }
classical-mechanics, orbital-motion, computational-physics $r(\theta) = \frac{p}{1+\epsilon\cos(\theta+C)}$ where $p = \frac{L^2}{m\alpha}$ and $\epsilon = \sqrt{1+\frac{2L^2E}{m\alpha^2}}$ $\alpha$ can be seen as the strength of the gravitational field, and $L$ and $E$ are the angular momentum and energy respectively. $C$ here is the constant of integration and will depend on the initial position and initial velocity of the particle.
{ "domain": "physics.stackexchange", "id": 43381, "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": "classical-mechanics, orbital-motion, computational-physics", "url": null }
Find all numbers c that satisfy the conclusion of Rolle's Theorem for the following function. If there are multiple values, separate them with commas; enter N if there are no such values. f(x)= x^2-10x+3, [0,10] 8. ### algebra Using the rational zeros theorem to find all zeros of a polynomial The function below has at least one rational zero. Use this fact to find all zeros of the function h(x)=7x^4-9x^3-41x^2+13x+6 if more than one zero, separate with 9. ### algebra Using the rational zeros theorem to find all zeros of a polynomial The function below has at least one rational zero. Use this fact to find all zeros of the function g(x)=5x©ù-28©ø-48x©÷-8x+7 if more than one zero, separate 10. ### Calculus Can someone help me finish this question... I got most of the answers but need help. Suppose that f(x)=3x−6x+5. (A) Use interval notation to indicate where f(x) is defined. If it is defined on more than one interval, enter More Similar Questions
{ "domain": "jiskha.com", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9840936054891428, "lm_q1q2_score": 0.8324865431672093, "lm_q2_score": 0.8459424373085146, "openwebmath_perplexity": 838.9222091103816, "openwebmath_score": 0.8453758358955383, "tags": null, "url": "https://www.jiskha.com/questions/557911/The-function-g-is-defined-below-g-x-x-2-9x-14-x-2-11x-24-Find-all-values" }
$\frac{(n+1)^3/5^{n+1}}{n^3/5^n}=\frac{\left(1+\frac{3}{n}+\frac{3}{n^2}+\frac {1}{n^3}\right)}{5}\rightarrow \frac{1}{5}$ 4. I think that the statement in the original post needs to be qualified a little bit. We have the following inequality: $\liminf \frac{a_{n+1}}{a_n}\leq \liminf \sqrt[n]{a_n}\leq \limsup \sqrt[n]{a_n}\leq \liminf \frac{a_{n+1}}{a_n}$ We are told that $\lim_{n\to \infty} \frac{a_{n+1}}{a_n}=1$. But then, $\liminf \frac{a_{n+1}}{a_n}=\limsup \frac{a_{n+1}}{a_n}=1$ which forces $\lim_{n\to \infty} \sqrt[n]{a_n}=1$ as well. So, I think that the book's statement is correct. If the limit of the ratio exists, then the limit of the roots will exist and converge to the same number. In particular, if the ratio test gives limit 1, then the root test will too. 5. $\dfrac{n^3}{5^n} \leq \left(\dfrac{4}{5}\right)^n$
{ "domain": "mathhelpforum.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9664104914476339, "lm_q1q2_score": 0.8032253633650875, "lm_q2_score": 0.8311430499496096, "openwebmath_perplexity": 249.6178701238994, "openwebmath_score": 0.7868267893791199, "tags": null, "url": "http://mathhelpforum.com/calculus/152157-clarification-root-test-ratio-test.html" }
by experts. A. a point estimate plus or minus a specific confidence level. Find an estimator for θ by the method of moments. An asymptotically equivalent formula was given in Kenney and Keeping (1951:164), Rose and Smith (2002:264), and Weisstein (n.d.). 20 … No, not all unbiased estimators are consistent. The consistent estimator ^ n may be obtained using GMM with the identity matrix as the weight matrix. Variance of the Periodogram • The Periodogram is an asymptotically unbiased estimate of the power spectrum • To be a consistent estimate, it is necessary that the variance goes to zero as N goes to infinity • This is however hard to show in general and hence we focus on a white Gaussian noise, which is still hard, but can be done 20 θ, if lim. b. Unbiasedness implies consistency, whereas a consistent estimator can be biased. One can see indeed that the variance of the estimator tends asymptotically to zero. 1) 1 E(βˆ =βThe OLS coefficient estimator βˆ 0 is unbiased, meaning that . It
{ "domain": "bsynchro.com", "id": null, "lm_label": "1. Yes\n2. Yes\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.986363161511632, "lm_q1q2_score": 0.82828264722577, "lm_q2_score": 0.839733963661418, "openwebmath_perplexity": 519.7246953576391, "openwebmath_score": 0.8853917717933655, "tags": null, "url": "https://www.bsynchro.com/woman-of-jxspbhn/c5b1f3-consistent-estimator-variance-goes-to-zero" }
quantum-mechanics, quantum-field-theory, solid-state-physics, conformal-field-theory, bosonization Title: Relation between bosonization and conformal field theory Recently I have been studying bosonization for 1-dimensional system. There are often some claims of bosonization being related to conformal field theory. I know that one could map 1+1D quantum field into a 2D classical field, but is there any more direct connection or more intuitive explanation on those two? Some references would be preferred. Thanks! Bosonization means you map some problems (i.e. interacting fermions) to free (compact) scalar field theory, which is perhaps the simplest example of 1+1 CFT.
{ "domain": "physics.stackexchange", "id": 38071, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, quantum-field-theory, solid-state-physics, conformal-field-theory, bosonization", "url": null }
machine-learning, neural-network, deep-learning, feature-engineering, feature-extraction I thought discover it is part of the task of the machine learning algorithm. Sure, but in traditional ML in order for the model to discover the most important patterns for a specific task, the features have to be prepared in a way which maximizes the chances of the model to find these. Simile: if a teacher tells their students to revise page 63 of the textbook for the test, it's likely that the students will perform better than if they have no clue about the topic and need to revise the whole textbook.
{ "domain": "datascience.stackexchange", "id": 8945, "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, neural-network, deep-learning, feature-engineering, feature-extraction", "url": null }
php, laravel if($about){ $user->about = $about; $user->save(); } if($password){ $user->password = $password; $user->save(); } if($website){ $user->website = $website; $user->save(); } if($location){ $user->location = $location; $user->save(); } The only thing that really changes here is the property/field being checked. That could be simplified using an array containing the field names: //could be moved to the model or another namespace const FIELDS = ['username', 'wallet_address', 'about', 'password', 'website', 'location']; public function update(Request $request){ $user = Auth::user(); foreach (self::FIELDS as $field) { if ($request->$field) { $user->$field = $request->$field; $user->save(); } } //handle avatar image update }
{ "domain": "codereview.stackexchange", "id": 41074, "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, laravel", "url": null }
terminology, security, stack-inspection From the paper: ... The stack inspection algorithm used in current Java systems can be thought of as a generalization of the following simple stack inspection model: In this model, the only principals are “system” and “untrusted”. Likewise, the only privilege available is “full.” This model resembles the stack inspection system used internally in Netscape Navigator 3.0. In this model, every stack frame is labeled with a principal (“system” if the frame is executing code that is part of the virtual machine or its built-in libraries, and “untrusted” otherwise), and contains a privilege flag which may be set by a system class which chooses to “enable its privileges,” explicitly stating that it wants to do something dangerous. An untrusted class cannot set its privilege flag. When a stack frame exits, its privilege flag (if any) automatically disappears. All procedures about to perform a dangerous operation such as accessing the file system or network first apply a
{ "domain": "cs.stackexchange", "id": 87, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "terminology, security, stack-inspection", "url": null }
python, python-2.x, file-system, linux def backup(backupdir, backupname): fnames = get_previous_backups(backupdir) See how much neater that is? Now, that comment for get_previous_backups could be more useful if it explained how it detected them. The function name is clear in indicating what it does, but the how might be unclear. The comment could also be made a docstring, too. You can read about them here, but basically they're programmatically accessible comments. Useful for interpreters and users alike. def get_previous_backups(backupdir): """Returns list of back up .tar.bz2 files that fit the date format"""
{ "domain": "codereview.stackexchange", "id": 16050, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, python-2.x, file-system, linux", "url": null }
php, security, pdo I've been quite vocal on the fourth argument of the PDO constructor, and on the UTF-8 business, just recently. Instead of copy-pasting my previous answer, here's a link. Basically, what I'd recommend you do is this: $db = new PDO( 'mysql:host=127.0.0.1;port=3306;dbname=myDb;charset=UTF8', $userName, $pass, array( PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, PDO::ATTR_ORACLE_NULLS => PDO::NULL_NATURAL, PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_OBJ, //production only - read warning below, though PDO::ATTR_EMULATE_PREPARES => false, PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES 'UTF8'" ) );
{ "domain": "codereview.stackexchange", "id": 8160, "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, security, pdo", "url": null }
biochemistry, bioenergetics Laidler, K. J. (1987) Chemical Kinetics 3rd Edn. Harper & Row. Newsholme, E.A. & Start, C (1973) Regulation in Metabolism. John Wiley & Sons. Silbey, R. J. & Alberty, R.A (2001) Physical Chemistry. 3rd Edn. John Wiley.
{ "domain": "biology.stackexchange", "id": 1354, "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, bioenergetics", "url": null }
javascript, jquery, dom, e-commerce I was told that I pass first id and last quantity, but it is all present when I call function in $(document) - Please explain this to me. This is basically a summary of points #1 and #2 above. Perhaps a better implementation would move the code to call the AJAX request (i.e. to '/Cart/AddTocart') with the id and quantity of the row that changed, then call update() to update the total. Something like the code below. Another suggestion is to update the request sent to the server to send the entire list of items with the respective quantities. That way, if a quantity is decreased or cleared, the cart can be accurately updated. It all depends on the back-end API - i.e. if it has endpoints to add/remove/update items with quantities, etc. I also changed the input type of the quantity inputs to "Number" - that way only numbers can be entered, and many browsers will add up/down controls to the side of the input for the user to click on.
{ "domain": "codereview.stackexchange", "id": 26722, "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, dom, e-commerce", "url": null }
classical-mechanics, rotation, linear-algebra & \mathrm d\boldsymbol{\Omega'}\boldsymbol{\times}\mathrm B\,\mathbf r \boldsymbol{=}\mathrm B\,\left(\mathrm d\boldsymbol{\Omega}\boldsymbol{\times}\mathbf r\right) \tag{13}\label{13} \end{align} The following identity shows how the outer product of two vectors is transformed by an orthogonal transformation $\mathrm B$ in terms of the transforms of these two vectors \begin{equation} \boxed{\:\: \mathrm B\left(\mathbf a \boldsymbol{\times}\mathbf b\right)\boldsymbol{=}\vert \mathrm B \vert \cdot\left(\mathrm B\mathbf a \boldsymbol{\times}\mathrm B\mathbf b\right)\stackrel{\eqref{05}} {\boldsymbol{=\!=}}\boldsymbol{\pm}\left(\mathrm B\mathbf a \boldsymbol{\times}\mathrm B\mathbf b\right) \vphantom{\dfrac{a}{b}}\:\:} \tag{14}\label{14} \end{equation} For a proof of the identity \eqref{14} see the ADDENDUM A(2). Using identity \eqref{14} equation \eqref{13} yields \begin{align}
{ "domain": "physics.stackexchange", "id": 83923, "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": "classical-mechanics, rotation, linear-algebra", "url": null }
quantum-mechanics, operators, heisenberg-uncertainty-principle, anticommutator http://en.wikipedia.org/wiki/Uncertainty_principle#Mathematical_derivations
{ "domain": "physics.stackexchange", "id": 360, "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, operators, heisenberg-uncertainty-principle, anticommutator", "url": null }
measurement, state-tomography We need to know how these two qubits act under aymmetric coupling. That is to say, we need the probabilities for measurements of e.g. $\sigma_{x} \otimes \sigma_{y}$, or $\sigma_{z} \otimes \sigma_{x}$. Of course, there are $|\{x,y,z\}\times \{x,y,z\}|=9$ different elements here, but we already counted the three symmetric ones. We also need to know what they do individually: if we measure 'nothing' on the first qubit but we measure the second qubit in any of the Pauli bases, we still learn something about the second qubit. These are the operators $\sigma_{I}\otimes \{\sigma_{x},\sigma_{y},\sigma_{z}\}$ and vice-versa: there are $6$ of them.
{ "domain": "quantumcomputing.stackexchange", "id": 1787, "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, state-tomography", "url": null }
organic-chemistry, nomenclature Title: Inter-classification of organic chemistry functional groups (carboxyl vs alcohol & ether vs ester) I have a few questions about whether organic functional groups can be classified as another. First, can carboxylic acids be also be considered alcohols (they have $\ce{-OH}$)? If not, can they at least behave like alcohols? Similarly, can esters ($\ce{RCOO-R'}$) be considered ethers because the $\ce{R'}$ group is linked to the other half of the ester via an $\ce{-O -}$ linkage? In whichever case, what are some chemical characteristics that distinguish ethers and esters? Carboxylic acids are not also alcohols. In general carboxylic acids are just that acids. They are prone to ionizing in water. Alcohols in general don't ionize in aqueous solution, and they certainly don't ionize in water to give acidic solutions. Esters are not also ethers. Esters react with water to form a carboxylic acid and an alcohol. Ethers are relatively stable in water.
{ "domain": "chemistry.stackexchange", "id": 5253, "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": "organic-chemistry, nomenclature", "url": null }
inorganic-chemistry, bond, molecules Setting the stage The simplest species with an $\ce{O-O}$ bond would be the peroxide anion, $\ce{O2^2-}$, for which we can easily construct an MO diagram. The $\mathrm{1s}$ and $\mathrm{2s}$ orbitals do not contribute to the discussion so they have been neglected. For $\ce{S2^2-}$, the diagram is qualitatively the same, except that $\mathrm{2p}$ needs to be changed to a $\mathrm{3p}$.
{ "domain": "chemistry.stackexchange", "id": 6441, "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, bond, molecules", "url": null }
c++, game, c++17, qt auto image = displayImage(mDisplayType); if(!mColorOn) { image = convertToGrayscale(image); } painter.drawImage(rect(), image); } void Cell::mark() { switch (mDisplayType) { case DisplayType::covered: mDisplayType = DisplayType::flagged; emit flagged(); update(); break; case DisplayType::flagged: if(mQuestionMarksOn) { mDisplayType = DisplayType::questionmark; } else { mDisplayType = DisplayType::covered; } emit unflagged(); update(); break; case DisplayType::questionmark: mDisplayType = DisplayType::covered; update(); break; default: break; } }
{ "domain": "codereview.stackexchange", "id": 36550, "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++, game, c++17, qt", "url": null }
electrochemistry, kinetics, solubility Attempt 3: It has to do with kinetics. Lets assume that everytime a nickel cation collides with an electrode, it steals some electrons. The half-cell with the higher concentration will have a higher amount of collisions per second. Thus, more electrons are being "consumed" at the cathode than anode per second, creating a charge differential, which in turn generates a current. Start with a simple thought experiment: pour 100 mL of 1 M nickel (II) sulfate solution into a beaker and very carefully layer 100 mL of 0.01 M nickel (II) sulfate solution on top of the more concentrated layer. Then, even without convection or deliberate mixing, diffusion will, sooner or later, result in the solution having concentration of 0.55 M. In what follows, it is assumed that evaporation is negligible, even on long time scales. Now consider Fig. 1 below:
{ "domain": "chemistry.stackexchange", "id": 17324, "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": "electrochemistry, kinetics, solubility", "url": null }
c#, datetime The shorter version I came up with is 40 lines, but you can judge if it readable enough. public static string GetTimeSpan(DateTime postDate) { string stringy = string.Empty; TimeSpan diff = DateTime.Now.Subtract(postDate); double days = diff.Days; double hours = diff.Hours + days*24; double minutes = diff.Minutes + hours*60; if (minutes <= 1) { return "Just Now"; } double years = Math.Floor(diff.TotalDays/365); if (years >= 1) { return string.Format("{0} year{1} ago", years, years >= 2 ? "s" : null); } double weeks = Math.Floor(diff.TotalDays/7); if (weeks >= 1) { double partOfWeek = days - weeks*7; if (partOfWeek > 0) { stringy = string.Format(", {0} day{1}", partOfWeek, partOfWeek > 1 ? "s" : null); } return string.Format("{0} week{1}{2} ago", weeks, weeks >= 2 ? "s" : null, stringy); }
{ "domain": "codereview.stackexchange", "id": 397, "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#, datetime", "url": null }
ros Originally posted by ayush_dewan with karma: 1610 on 2013-01-26 This answer was ACCEPTED on the original site Post score: 0
{ "domain": "robotics.stackexchange", "id": 12145, "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 }
Note that my deriavation is far from complete since it is limited to a steady-state solution (tricopter hovering still). I only used it to clear up some confusion I had about the hovering state of a tricopter. If you wanted to derive a complete dynamic model for a tricopter you would also need to include acceleration terms, as well take air drag into account. Note that at higher velocities, incoming airflow could also significantly affect the thrust on the rotor, which you would somehow have to take into account and when flying at low altitutudes ground effect might also play a role. As you probably see, there are many physical phenomenon that affect tricopter's flight, which is probably the reason most derivations of dynamics equations become so complex. You first need to consider what is actually the goal you are trying to achieve with your model (equations) and then evaluate which physical effects you will have to include and which you could neglect.
{ "domain": "diydrones.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9822876992225169, "lm_q1q2_score": 0.863575044649643, "lm_q2_score": 0.8791467564270271, "openwebmath_perplexity": 617.6492788618665, "openwebmath_score": 0.5613716840744019, "tags": null, "url": "https://diydrones.com/forum/topics/tricopter-physics-help?commentId=705844%3AComment%3A2443655" }
1 (Prove it). The central topic of this unit is converting matrices to nice form (diagonal or nearly-diagonal) through multiplication by other matrices. A positive definite matrix will have all positive pivots. A positive definite matrix is a symmetric matrix with all positive eigenvalues. This website is no longer maintained by Yu. I want to run a factor analysis in SPSS for Windows. Home Notify me of follow-up comments by email. upper-left sub-matrices must be positive. (a) Prove that the eigenvalues of a real symmetric positive-definite matrix Aare all positive. Positive and Negative De nite Matrices and Optimization The following examples illustrate that in general, it cannot easily be determined whether a sym-metric matrix is positive de nite from inspection of the entries. Range, Null Space, Rank, and Nullity of a Linear Transformation from $\R^2$ to $\R^3$, How to Find a Basis for the Nullspace, Row Space, and Range of a Matrix, The Intersection of Two Subspaces is also a
{ "domain": "serverdomain.org", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9883127426927789, "lm_q1q2_score": 0.8672215015686618, "lm_q2_score": 0.8774767986961403, "openwebmath_perplexity": 669.3911538225327, "openwebmath_score": 0.646534264087677, "tags": null, "url": "http://xb1352.xb1.serverdomain.org/caitlin-pronunciation-pewn/h94r0.php?a1b42f=significance-of-positive-definite-matrix" }
'' method method of b..., according to triangle law ’ of vector a to the ‘ ’... Tail '' approach vectors with a head to tail of their owners. Feedback or enquiries via our feedback page a and b done based the... ; then C = b + a and be the same site or page with then. Done based on the grid above to create a vector: First click the create button then! Grid above to create a vector vector a + b = b + a that is a law the!, if any, are copyrights of their respective owners for adding more two... A to the ‘ nose ’ of a to the ‘ tail of. Vector C. parallelogram law of vector addition vs Pythagorean theorem are not at 90-degrees to other. It triangle law of vector addition a + b = b + a add vectors with a head tail... B + a to triangle OPT is commutative, that is a for... Is carried out triangle, the intermediate letters must be the angle by..., side OB represents the resultant vector is independent of the order of vectors procedure feedback.. Is a + b = b + a Let R be the resultant force
{ "domain": "uh.cz", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9458012732322216, "lm_q1q2_score": 0.8094651044988912, "lm_q2_score": 0.8558511469672594, "openwebmath_perplexity": 815.4427464279745, "openwebmath_score": 0.581605076789856, "tags": null, "url": "https://o2.uh.cz/aftab-shivdasani-wvwv/176bd5-triangle-law-of-vector-addition" }
neural-network, rnn The cell state is the bold line travelling west to east across the top. The entire green block is called the 'cell'. The hidden state from the previous time step is treated as part of the input at the current time step. However, it's a little harder to see the dependence between the two without doing a full walkthrough. I'll do that here, to provide another perspective, but heavily influenced by the blog. My notation will be the same, and I'll use images from the blog in my explanation. I like to think of the order of operations a little differently from the way they were presented in the blog. Personally, like starting from the input gate. I'll present that point of view below, but please keep in mind that the blog may very well be the best way to set up an LSTM computationally and this explanation is purely conceptual. Here's what's happening: The input gate
{ "domain": "datascience.stackexchange", "id": 1725, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "neural-network, rnn", "url": null }
# Spectrum of $L^\infty(X,\mu)$ Suppose that $(X,\Sigma,\mu)$ is a measured set with respect to $\sigma$-algebra $\Sigma$. Suppose that $L^\infty(X,\mu)$ is the set of all $\mu$-equal bounded $\Sigma$-measurable functions on $X$. Indeed equally, one may say that $L^\infty(X,\mu)$ is the dual of $L^1(X,\mu)$. What is the spectrum of $(L^\infty(X,\mu),\|\cdot\|_\infty)$ as a Banach (C^*) algebra? Thank you very much.
{ "domain": "mathoverflow.net", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9763105266327962, "lm_q1q2_score": 0.8464961510021909, "lm_q2_score": 0.8670357718273068, "openwebmath_perplexity": 225.13931617637468, "openwebmath_score": 0.9287201762199402, "tags": null, "url": "https://mathoverflow.net/questions/99091/spectrum-of-l-inftyx-mu/374868" }
potential-energy, fluid-statics Title: Total mechanical energy of body of fluid at rest I encountered a claim in a textbook that the total mechanical energy of a body of fluid at rest (with a free surface) is equal to the potential energy of the water at the free surface. For example, for a reservoir with height of $h$, the mechanical energy per unit mass is $gh$. I certainly agree that all mechanical energy is potential energy here, but it isn't clear to me why the potential energy per mass doesn't differ with height. Can anyone explain? Additional information: The statement of the question is Electric power is to be generated by installing a hydraulic turbine–generator at a site 120 m below the free surface of a large water reservoir that can supply water at a rate of 2400 kg/s steadily. Determine the power generation potential. I chose to apply Bernoulli between the free surface and the exit of the generator, both at $P_a$. In this case: $$gh = \frac{1}{2} v_{out}^2$$
{ "domain": "physics.stackexchange", "id": 42976, "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": "potential-energy, fluid-statics", "url": null }
performance, c, image, signal-processing, opencl //more code which is not immediately relevant follows...... } How can I modify my iqzz and idct kernels to make them run faster on the GPU? The details of my GPU are as follows: DEVICE_NAME = Tesla K20c DEVICE_VENDOR = NVIDIA Corporation DEVICE_VERSION = OpenCL 1.2 CUDA DRIVER_VERSION = 352.21 DEVICE_MAX_COMPUTE_UNITS = 13 DEVICE_MAX_CLOCK_FREQUENCY = 705 DEVICE_GLOBAL_MEM_SIZE = 5032706048 CL_DEVICE_ERROR_CORRECTION_SUPPORT: yes CL_DEVICE_LOCAL_MEM_TYPE: local CL_DEVICE_LOCAL_MEM_SIZE: 48 KByte CL_DEVICE_MAX_CONSTANT_BUFFER_SIZE: 64 KByte CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_PROFILING_ENABLE Indent your loop bodies. Actually check ret - you're uselessly assigning and discarding it every time. Use better variable names: avoid single letters (Y, k, l) and generic names (index) It appears all the work of your code is inside four nested loops:
{ "domain": "codereview.stackexchange", "id": 28028, "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": "performance, c, image, signal-processing, opencl", "url": null }
algorithms, data-structures Is there something simpler than this? You can achieve $O(\log n)$ time for all operations using a self-balancing binary tree. Augment the tree so that you can store a value $\delta$ in each internal node; the meaning is that we add $\delta$ to the key of all descendants of that node. So the actual key value at a particular node is the key stored at that node, plus the sum of all $\delta$'s along the path to the root. This makes it easy to shift over all intervals after $A$, by adding $\delta$ to $O(\log n)$ nodes chosen so that their descendants cover all the keys after $A$. It's also easy to adjust the lookup procedure to look up a value (the glb operation) and to find where to insert/delete a range.
{ "domain": "cs.stackexchange", "id": 21163, "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": "algorithms, data-structures", "url": null }
physical-chemistry, ions, conductivity, electrochemistry Title: How does conductivity work for non-redoxed ions? Related (very similar, but here I want a mechanism) https://physics.stackexchange.com/q/21827/7433 By the Kohlrausch law, all ions contribute to the conductivity of an electrolyte. Now, as I understand it, the mechanism of conduction in an electrolyte is thus: Ions migrate in solution These ions get reduced or oxidized at the electrodes and converted to electrons These electrons continue down the wire, leading to an increased/maintained conductivity/current
{ "domain": "chemistry.stackexchange", "id": 27, "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, ions, conductivity, electrochemistry", "url": null }
classical-mechanics, continuum-mechanics, stress-strain, structural-beam Title: buckling of tube - shell thickness vs. momentum of inertia optimum is there any simple formula (perhabs semi emperical, or aproximatively derived model) for buckling of tube under axial compression load given its crossection and wall thickness? ( and naturraly elastic modulus and length would also affect it ). I mean - certainly there is a compromise between: maximizing area moment of inertia in euler formula for long rod. keeping walls thick enought to prevent local buckling of wall shell (such as Yoshimura / Donnell's buckling )
{ "domain": "physics.stackexchange", "id": 22855, "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": "classical-mechanics, continuum-mechanics, stress-strain, structural-beam", "url": null }