text stringlengths 1 1.11k | source dict |
|---|---|
electromagnetism, energy, waves
Title: Energy in an EM wave should depend on frequency I just finished reading Feynman's Lectures on Physics vol.I, §34-9: "The momentum of light". The author explains that there is a relation between the wave 4-vector $k^{\mu}$ and the energy-momentum 4-vector $p^{\mu}$ of an EM wave, namely
$$p^{\mu}=\hbar k^{\mu}, $$
or equivalently
$$\tag{deB}W=\hbar \omega, \mathbf{p}=\hbar \mathbf{k},$$
and those equations are called de Broglie relations.
However, as I learned in my classical electromagnetism course, flux of energy in such a wave is quantified by Poynting's vector, yielding formulas such as the following:
$$\tag{1} I=\frac{1}{2 \mu_0 c} E_0^2, $$
where $I$ stands for "average intensity" of the wave and $E_0$ for "maximum amplitude of electric field".
Question Where is $\omega$? It does not appear in formula (1) nor in any other formula based on Poynting's vector. But as of equations
(deB) it should do so. Am I wrong? | {
"domain": "physics.stackexchange",
"id": 2328,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "electromagnetism, energy, waves",
"url": null
} |
c#, strings, extension-methods
Because you are trying to track state (i.e. the secret index), an OOP solution will help you encapsulate your state and use it while at the same time hiding it from the consumer.
A second way you could've come to the realization that OOP is useful here is that you can't alter a string by reference by doing myString.MyMethod(), but if you wrap that string in an object, you can alter that object by reference by doing myObjectContainingMyString.MyMethod().
To the consumer, this alternate approach will handle exactly the same. It's as if the handled characters no longer exist. But internally, you simply skip over the characters. They're still there, they're just not used anymore.
I'm going to call this a StringQueue, because it basically makes your data behave like a queue of substrings.
First, the initial state. We create a queue, with a given data string. The secret index is 0 since we have not processed any characters yet.
public class StringQueue
{
private readonly string original; | {
"domain": "codereview.stackexchange",
"id": 42246,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "c#, strings, extension-methods",
"url": null
} |
python, python-3.x
],
"statusCodes": [ | {
"domain": "codereview.stackexchange",
"id": 42530,
"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",
"url": null
} |
(initial and boundary) conditions also called side conditions. - user6655984 Mar 25 '18 at 17:38. Learn more about convective boundary condition, heat equation. The equation is $\frac{\partial u}{\partial t} = k\frac{\partial^2 u}{\partial x^2}$ Take the Fourier transform of both sides. This paper is concerned with numerical approximations of a nonlocal heat equation define on an infinite domain. This heat and mass transfer simulation is carried out through the usage of CUDA platform on nVidia Quadro FX 4800 graphics card. We can solve this problem using Fourier transforms. Consider the heat equation ∂u ∂t = k ∂2u ∂x2 (11) with the boundary conditions u(0,t) = 0 (12) ∂u ∂x (L,t) = −hu(L,t) (13) We apply the method of separation of variables and seek a solution of the product form. Index Terms—Adomian decomposition, method, derivative. Now the boundary conditions are homogeneous and we can solve for U ( x, t) using the method in the Dirichlet boundary conditions. 5} term by term once | {
"domain": "umood.it",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138138113965,
"lm_q1q2_score": 0.8210195020805188,
"lm_q2_score": 0.83973396967765,
"openwebmath_perplexity": 512.9019421213272,
"openwebmath_score": 0.8403221964836121,
"tags": null,
"url": "http://pziq.umood.it/heat-equation-boundary-conditions.html"
} |
-
@Bill You use $\mathtt{x}$ for two different purposes. And you might wish to correct the repeated squaring. – Did Mar 25 '11 at 14:11
@Didier: Your comment makes no sense to me. – Bill Dubuque Mar 25 '11 at 14:15
@Bill The symbols $\mathtt{x}$ did not appear as factors of $2\mathrm{i}$ when I first looked at your comment. Now they do, so the second part of my comment is moot. Re the first part, you use $\mathtt{x}$, first as the running argument of the transformation $\mathtt{x}\to(\mathrm{i}+\sqrt{2})\mathtt{x}$, then as $\mathtt{x}=\mathrm{i}+\sqrt{2}$. – Did Mar 25 '11 at 14:27
@Didier: I still see no problems. – Bill Dubuque Mar 25 '11 at 14:34 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9852713857177955,
"lm_q1q2_score": 0.8628878692431304,
"lm_q2_score": 0.8757869981319862,
"openwebmath_perplexity": 149.55856519170442,
"openwebmath_score": 0.9899265170097351,
"tags": null,
"url": "http://math.stackexchange.com/questions/29005/minimal-polynomial-of-i-sqrt2-in-mathbbq"
} |
ros-melodic
As you suggest, if you are able to collect more data from the environment (longer range, more sensors, etc.), the SLAM algorithm will be better able to determine how far the robot has moved. In general, the more data, the better. You do have to make sure it's quality data, though. If your odometry is way off for example, it could hurt more than help.
Another option is to make the scans look different by adding objects to the environment, so the SLAM algorithm has more discernible features to use.
Comment by sisko on 2021-04-03:
I'm going to try finding and adding some kind of unique patterns to the kerbs. I'm thinking qr codes to be read by camera on my model. BUT, how can I integrate such camera data, or lidar etc, into the SLAM algorithm ? This is the part I can't figure out yet. Gmapping needs a minimum of laser data. How can I introduce extra data from other sensors ?
Comment by tryan on 2021-04-04: | {
"domain": "robotics.stackexchange",
"id": 36267,
"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-melodic",
"url": null
} |
networks
About conserved patterns of protein interaction in multiple species
About comparing genomic expression patterns across species
This one is slightly out of topic but can give you
some other ideas about comparing networks. | {
"domain": "bioinformatics.stackexchange",
"id": 779,
"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": "networks",
"url": null
} |
java, performance, beginner, formatting, complexity
}
components.add(equivalent);
equivalent.getNode1().connect(equivalent);
equivalent.getNode2().connect(equivalent);
temp.clear();
}
}
}
}
}
/* remove resistors to be replaced by single equivalent resistor */
/* if there are items to be removed */
if(toRemove.size()>0) {
/* for each component to be removed */
for (Component remove:toRemove) {
/* for each component */
for(int i = 0; i <components.size();i++) {
/* if the component is a resistor and it is in the list of resistors to be removed */
if(components.get(i).getId()==remove.getId()&&components.get(i) instanceof Resistor) {
/* remove it from components */
remove.getNode1().disconnect(remove); | {
"domain": "codereview.stackexchange",
"id": 33411,
"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, beginner, formatting, complexity",
"url": null
} |
c#
Title: Adding many items generated from Taglib# is incredibly slow and expensive, how can I increase the performance? I'm trying to make an audio file tag editor, but I ran into some serious performance issues. Here's my method for loading files:
private void LoadFiles(params string[] fileNames) {
foreach (string fileName in fileNames) {
string path = fileName;
if (loadedSongs.ContainsKey(path))
continue;
new Thread(new ThreadStart(() => {
using (TagFile file = TagFile.Create(path)) {
Song song = new Song() {
Album = file.Tag.Album,
AlbumArtists = file.Tag.AlbumArtists,
Artists = file.Tag.Performers,
BeatsPerMinute = (file.Tag.BeatsPerMinute != 0 ?
(uint?)file.Tag.BeatsPerMinute : null), | {
"domain": "codereview.stackexchange",
"id": 1454,
"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
} |
thermodynamics, carnot-cycle
Title: Carnot Cycle Question I have two questions surrounding the Carnot cycle. The typical diagram for a Carnot cycle is shown here:
I have several textbooks that discuss this cycle, but what none of them do is explain how points B and D, where the process is switched from an isothermal one to an adiabatic one, is determined.
So my first question is: How does one know that at the volume represented by the point $V_D$, one ends the isothermal compression and begins the adiabatic compression? (I guess one answer might be that it's an engine, it doesn't choose - it just does its thing?) | {
"domain": "physics.stackexchange",
"id": 91349,
"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, carnot-cycle",
"url": null
} |
thermodynamics, statistical-mechanics, molecules, degrees-of-freedom
In the case of a non-linear molecule made by $3$ atoms, we have to subtract $3$ independent scala constraints of fixed distances from the $9$ degrees of freedom of a three-atom system. Here again, addition of more atoms with rigid distances from the first three, corresponds to add $3$ new coordinates but the same time $3$ more scalar constraints. As a result, a rigid non-linear molecule would require ony six numbers to uniquely identify its space configuration.
Of course, we could have more than 5 or 6 degrees of freedom, in the case of poly-atomic molecules, if only part of the distances are fixed.
So far, it's just matter of counting atoms and constraints. The real physical question is under which conditions we could consider an intramoleclar distance as fixed? The answer requires Quantum Mechanics. It turns out that every motion requiring excitation $\Delta E \gg k_BT$ is dynamically frozen and the system behaves as if there would be a rigid constraint. | {
"domain": "physics.stackexchange",
"id": 69542,
"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, statistical-mechanics, molecules, degrees-of-freedom",
"url": null
} |
materials, glass
If you make a glass with potassium, you have potassium ions occupying potassium sites, thus no strengthening occurs. Thus the only way to chemically harden the glass is to substitute larger ions into the glass. | {
"domain": "chemistry.stackexchange",
"id": 12007,
"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": "materials, glass",
"url": null
} |
quantum-mechanics, energy, molecules, dipole
This is, of course, a weak effect: it is very hard to induce a dipole in the partner system if you don't have a permanent dipole of your own! This is why the London force scales so unfavourably (as $1/r^6$) when the systems stop being close to each other.
(Note, of course, that this heuristic explanation in terms of induced dipoles is only partially true. The full, correct explanation can only be done within quantum mechanics, and its core principles of operation are only partially reflected in the heuristic explanation. But it's close enough.) | {
"domain": "physics.stackexchange",
"id": 78553,
"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, energy, molecules, dipole",
"url": null
} |
universe, redshift
See accelerated expansion at https://en.m.wikipedia.org/wiki/Accelerating_expansion_of_the_universe
The real issue is we still don't know what exactly is the dark energy. We think it is the vacuum energy of spacetime, but can't understand why it is the value it is. Still a lot of research in that area, and also dark matter. | {
"domain": "physics.stackexchange",
"id": 38537,
"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": "universe, redshift",
"url": null
} |
neuroscience, brain, intelligence
Title: What is the creature with the lowest neuron count that demonstrates cognition beyond reflexes? I'm under the impression that nematode worms just perform the same scripted actions over and over again in response to specific stimuli. They have 302 neurons. Chimpanzees display problem solving capabilities, as do other mammals with smaller brains (cats, for instance with ~ 1 billion neurons). You might say that bees demonstrate something more than reflexes when they communicate the location of nectar sources to the hive (~ 960,000 neurons). | {
"domain": "biology.stackexchange",
"id": 1869,
"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": "neuroscience, brain, intelligence",
"url": null
} |
ros, arduino, serial, topic
Originally posted by Jon Stephan with karma: 837 on 2013-04-16
This answer was ACCEPTED on the original site
Post score: 2 | {
"domain": "robotics.stackexchange",
"id": 13843,
"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, arduino, serial, topic",
"url": null
} |
grovers-algorithm
Question
After this elaborate writing, I was wondering why this seems to work and whether this has been analyzed before? It seems too real to be true, and although I don't know how this applies to constructing an actual circuit, mathematically, it seems to be valid. You can't just choose any operator that you want. Generally, you want to choose something that's unitary. Your new operator isn't. Instead, it's a measurement. This is still technically allowed, but is unlikely to lend itself well to repeated iteration. It may be that you suggestion works well enough on small cases, but if it works, you should be able to prove it works for arbitrary $N$, and for arbitrary search states. | {
"domain": "quantumcomputing.stackexchange",
"id": 3953,
"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": "grovers-algorithm",
"url": null
} |
#### wyngarth
##### New Member
Thanks for the advice. Once I realized there are 36 cards in the deck that are neither Jacks nor Spades, the numbers looked a lot better. Enclosed is what I came up with, if anyone's interested.
But here's another rub. Using these figures, the Correlation Coefficient between J and S is basically. 0. Either I made another dumb arithmetic mistake, or this is one of those situations where the values are dependent, but uncorrelated. Is this a reasonable conclusion? Seems counter-intuitive to me.
#### BGM
##### TS Contributor
I have come up with the same table and get the covariance
$$2.05998 \times 10^{-17}$$
When you try to multiply the two marginal pmfs, you will find that it is very close to the joint pmf. Therefore although they are dependent, they are almost independent and the covariance/correlation is so close to zero. | {
"domain": "talkstats.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595527,
"lm_q1q2_score": 0.8053711350697326,
"lm_q2_score": 0.8198933315126791,
"openwebmath_perplexity": 954.1263124642571,
"openwebmath_score": 0.7728987336158752,
"tags": null,
"url": "http://www.talkstats.com/threads/joint-probability-distribution-from-drawing-5-cards.59049/"
} |
moveit, roslaunch
Originally posted by MikeArmstrong on ROS Answers with karma: 11 on 2017-01-02
Post score: 0
It seems like there's a non-ascii character (probably š) in one of the file names of one of the files on your system, and the python library for dealing with paths and filenames (os.path.isdir) doesn't like that.
I realize that's not very specific, but without modifying roslaunch to add additional debug information, there's not much more I can say.
You can search for files with that character in the file name in /opt/ros with find /opt/ros -name '*š*'. If that doesn't find anything, you can try searching the whole file system: find / -name '*š*' (give this an hour or two to run if you have a large file system, a slow hard drive, or both)
Originally posted by ahendrix with karma: 47576 on 2017-01-03
This answer was ACCEPTED on the original site
Post score: 0 | {
"domain": "robotics.stackexchange",
"id": 26626,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "moveit, roslaunch",
"url": null
} |
JK is tangent to circle … b) state all the secants. The circle’s center is (9, 2) and its radius is 2. Since tangent AB is perpendicular to the radius OA, ΔOAB is a right-angled triangle and OB is the hypotenuse of ΔOAB. In this geometry lesson, we’re investigating tangent of a circle. Tangent, written as tan(θ), is one of the six fundamental trigonometric functions.. Tangent definitions. On solving the equations, we get x1 = 0 and y1 = 5. Because JK is tangent to circle L, m ∠LJK = 90 ° and triangle LJK is a right triangle. Proof of the Two Tangent Theorem. Therefore, the point of contact will be (0, 5). The required perpendicular line will be (y – 2) = (4/3)(x – 9) or 4x – 3y = 30. The equation of the tangent in the point for will be xx1 + yy1 – 3(x + x1) – (y + y1) – 15 = 0, or x(x1 – 3) + y(y1 – 1) = 3x1 + y1 + 15. On comparing the coefficients, we get (x1 – 3)/(-3) = (y1 – 1)/4 = (3x1 + y1 + 15)/20. var vidDefer = document.getElementsByTagName('iframe'); By using Pythagoras | {
"domain": "exaton.hu",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9861513881564148,
"lm_q1q2_score": 0.8838395350696157,
"lm_q2_score": 0.8962513724408292,
"openwebmath_perplexity": 358.98978621027345,
"openwebmath_score": 0.4151161313056946,
"tags": null,
"url": "https://www.exaton.hu/qn573/c5fe24-tangent-of-a-circle-example"
} |
wavefunction, quantum-entanglement, quantum-measurements, locality
Or should it become:
$$\frac{1}{\sqrt{3}}|up, down, \text{Bob measured up}\rangle +\frac{\sqrt{2}}{\sqrt{3}} |down,up, \text{Bob measured down}\rangle$$
If the first option is correct, how does it not violate locality? I am thinking that the first option involves the information, that Bob has made a measurement, to instantaneously travel to Alice's end. If Bob observes "down", due to the wavefunction collapse the full system will be described by :
$$
\left|down,up\right\rangle
$$
There is indeed some sort of "spooky action at a distance", but this action cannot be used to transfer information.
When Bob observes "down", he will instantaneously know the state of the particle in Alice's possession, and yes, that state will instantaneously change for Alice. However, this cannot be used to transfer information. This is mainly because Bob cannot choose what he observes. He will observe $1/3$ of the time "down", and $2/3$ of the times "up". | {
"domain": "physics.stackexchange",
"id": 91177,
"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": "wavefunction, quantum-entanglement, quantum-measurements, locality",
"url": null
} |
c++, beginner, console, c++14, adventure-game
while (NameSelectDone == true && IsGameOver == false && LChoice != 'Q' && LChoice != 'q')
{
cout << "Before we begin at anytime if you type 'S' you can save the game, also at anytime if you type 'Q' you can quit the game.\n";
cout << "Also your choices will afect the outcome of the story so pick wisely\n";
cout << "If you use the Letter 'C' you can display all the controls.\n";
cout << "Type any letter to continue....\n";
cin >> LChoice;
system("cls"); | {
"domain": "codereview.stackexchange",
"id": 21401,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "c++, beginner, console, c++14, adventure-game",
"url": null
} |
h[{a_, r___}, p_: {}] := h[{r} + #, Append[p, #]] & @ Max[-a, 0]
h[{}, p_] := p
Test:
h[balance]
{0, 80, 0, 0, 20}
• Thanks for the answer. I really like both your solutions (didn't know about Symbol assignment). I think I danced around your first idea, but I had it in my head to use a Reap and Sow, and so couldn't really get it to work "cleanly". – Steve D Feb 28 '15 at 20:40
• @Steve You're welcome. Let me know if you have any problems with these. – Mr.Wizard Feb 28 '15 at 20:42
• @Steve Please see the update to my second method. FoldList was a poor choice for that mixed method. – Mr.Wizard Feb 28 '15 at 22:07
You mentioned Sow and Reap in a comment, so here's a recursive function using those. Performance-wise it's a total disaster but perhaps it's of interest anyway:
f[{first_, rest___}] := f[{rest} + Sow @ Max[-first, 0]]
Reap[f @ balance][[2, 1]]
(* {0, 80, 0, 0, 20} *) | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.956634196290671,
"lm_q1q2_score": 0.8111949495029914,
"lm_q2_score": 0.8479677526147223,
"openwebmath_perplexity": 3064.785040663899,
"openwebmath_score": 0.2227804958820343,
"tags": null,
"url": "https://mathematica.stackexchange.com/questions/76107/iterating-over-a-list-in-a-functional-way"
} |
java, beginner, object-oriented, design-patterns
One last note on the design: It seems odd to me that the Storage also keeps track of the currently logged in user. Make a copy or a branch if you use git and try moving that functionality into the UI or somewhere else, so that the Storage's only purpose is to load and save your database.
EDIT: The Hash map
In loadUserNamesAndPasswords (as example, same in loadUserToDoLists) you do this:
public void loadUserNamesAndPasswords(File file) {
if (file.length() == 0) {
map = new HashMap<>();
this.saveUserNamesAndPasswords(map);
}
try {
FileInputStream fis = new FileInputStream(UsernamesAndPasswords);
// ...
} catch (Exception e) {
// ...
}
} | {
"domain": "codereview.stackexchange",
"id": 41961,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "java, beginner, object-oriented, design-patterns",
"url": null
} |
javascript, twitter-bootstrap
Title: Parking Lot Management System in JavaScript Hypothesis
There is a paid parking lot, with the following rates: $1 for the first hour and $0.5 for every subsequent hour. The parking capacity is of 10 spaces.
Required
Make an activity management system for the Parking with the following characteristics:
Any parking interval is rounded up, to the nearest hour.
When a new car enters the parking lot, the parking system takes in the registration number of the
car.
When a car leaves the parking, the system issues a summary, depending on the duration of the stay. What information do you consider essential as part of the summary?
Any customer can see the list of cars parked in the parking lot at a given time.
Technical requirements
The implementation will be done using JavaScript, all data being stored in memory, with no need for permanent storage.
Write clean code.
Create a simple GUI that allows entering and reading data from the computer; display the data on the same page. | {
"domain": "codereview.stackexchange",
"id": 39654,
"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, twitter-bootstrap",
"url": null
} |
newtonian-mechanics, classical-mechanics
Title: How does the masless pulley gets the force from rope? I have seen whenever we solve for forces on pulley by rope we take the force on pulley exactly as the tensions in the rope around it. But , why do we do this ? Exactly how does the rope exerts forces on pulley ? | {
"domain": "physics.stackexchange",
"id": 22792,
"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": "newtonian-mechanics, classical-mechanics",
"url": null
} |
ros, qtcreator
MESSAGE(STATUS "step3.")
SET( HWQ_LIB
${QT_LIBRARIES}
)
ADD_EXECUTABLE(turtle_teleop_joy1 ${HWQ_SRC} )
TARGET_LINK_LIBRARIES(turtle_teleop_joy1 ${HWQ_LIB} )
INSTALL_TARGETS( /bin turtle_teleop_joy1)
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
rosbuild_init()
MESSAGE(STATUS "step4.")
#set the default path for built executables to the "bin" directory
set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
#set the default path for built libraries to the "lib" directory
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib)
#uncomment if you have defined messages
rosbuild_genmsg()
#uncomment if you have defined services
#rosbuild_gensrv()
MESSAGE(STATUS "step5.") | {
"domain": "robotics.stackexchange",
"id": 8021,
"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, qtcreator",
"url": null
} |
It follows (in my mind, anyway) that we have:
$e = F^{-1}(1)$.
This, to me, is the reason why $e$ is "natural", I find the definition:
$$\displaystyle e = \lim_{n \to \infty} (1 + n)^{1/n}$$
nearly impossible to motivate, whereas the derivative of a differentiable function $f$ where:
$f(a+b) = f(a)f(b)$ clearly has derivative:
$f'(x) = f'(0)\cdot f(x)$.
At this point, we are in a bit of a fix, which is why considering $f^{-1}$ proves to be more amenable to attack:
$(f^{-1})'(x) = \dfrac{1}{f'(f^{-1}(x))} = \dfrac{1}{f'(0)\cdot f(f^{-1}(x))}$
$= \dfrac{1}{f'(0)x}$
This is a function of the form $g(x) = \dfrac{1}{\alpha x}$, and we can use the Fundamental Theorem of Calculus to find values for $f^{-1}(x)$.
Taking $\alpha = 1$ leads, of course, to the above definition of $e$.
Last edited:
#### ThePerfectHacker | {
"domain": "mathhelpboards.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9825575147530351,
"lm_q1q2_score": 0.8654337848652092,
"lm_q2_score": 0.8807970748488297,
"openwebmath_perplexity": 484.89271278881665,
"openwebmath_score": 0.8424057364463806,
"tags": null,
"url": "https://mathhelpboards.com/threads/why-e-is-natural-and-why-we-use-radians.9286/"
} |
average standard error on excel
Average Standard Error On Excel table id toc tbody tr td div id toctitle Contents div ul li a href Average Standard Error Of The Mean a li li a href Standard Error Of Average Partial Effect a li li a href Standard Error Of Average Formula a li li a href Standard Error Of The Average Of Multiple Measurements a li ul td tr tbody table p the toolbar at the top A menu will appear that relatedl says Paste Function Select Stastical from the left hand side p h id Average Standard Error Of The Mean p of
average standard error arcgis | {
"domain": "winbytes.org",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9840936068886641,
"lm_q1q2_score": 0.899143230082056,
"lm_q2_score": 0.9136765281148513,
"openwebmath_perplexity": 10404.382160598483,
"openwebmath_score": 0.3121330142021179,
"tags": null,
"url": "http://winbytes.org/help/standard-error/proportion-standard-error.html"
} |
stresses, friction, bicycles, carbon-fiber
Even steel ball bearings, which we imagine are a rigid object, do not generate stresses that shoot towards infinity.
When loaded, they behave just like a rubber ball. They can be squished.
Here also, the two pairs of bolts will generate the dominant stresses on the two narrow vertical bands—regardless of whether the center section is present in the stem. If it's present, it will take relatively little load, and it can hence be discarded. The presence of the mid-section may simply be cosmetic.
Can you confirm/refute and/or elaborate?
Future Questions | {
"domain": "engineering.stackexchange",
"id": 4927,
"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": "stresses, friction, bicycles, carbon-fiber",
"url": null
} |
To review properties of exponents, I ask students to work with assigned partners on Property of Exponents Match Up.docx. You have seen that when you combine like terms by adding and subtracting, you need to have the same base with the same exponent. All the exponent properties hold true for any real numbers, but right now we will only use whole number exponents. Zero Exponent Property a0 = 1, a ≠ 0 Negative Exponent Property a − b = 1 ab, a ≠ 0 Product of Powers Property ab ⋅ ac = ab + c, a ≠ 0 $$\frac{x^{a}}{x^{b}}=x^{a-b},\: \: x\neq 0$$. Since exponents indicate multiplication, and since order doesn't matter in multiplication, there will often be more than one sequence of steps that will lead to a valid simplification of a given exercise of this type. This exercise practices several of the exponent rules, including product rules, power rules, and rules for negative exponents. x n ⋅ x m = x n + m. x^n\cdot x^m=x^ {n+m} xn ⋅ xm = xn+m. Properties of Exponents p. 323 Slideshare uses | {
"domain": "trinitariasmallorca.org",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9621075701109192,
"lm_q1q2_score": 0.811917868435894,
"lm_q2_score": 0.8438951045175643,
"openwebmath_perplexity": 1270.9053218679683,
"openwebmath_score": 0.6059345602989197,
"tags": null,
"url": "http://trinitariasmallorca.org/bedspreads-and-xetifo/8aec1f-properties-of-exponents"
} |
gravity, space-time
Title: What defines stationary vs spinning in space? To produce artificial gravity on a space station, we simply spin it around some central point, and the acceleration makes objects "fall" outwards. If our space station is so far in deep space that it cannot detect any light from stars whatsoever, we can still tell if we are spinning or not based on the artificial gravity produced.
Why? What are we spinning relative to? If I were to take a stationary space station and spin everything else in the universe around it, would it produce the same effect?
Or to put it another way, suppose I took all of the matter in the Universe and made it into a gigantic disk. Would it be possible to spin the disk? What would it be spinning relative to? Issac Newton described an experiment in which a bucket containing water is spun. As the water in the bucket starts to rotate, it becomes concave. The reason for this can be understood in terms of rotating frames of reference. | {
"domain": "astronomy.stackexchange",
"id": 2599,
"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": "gravity, space-time",
"url": null
} |
equipment, filtering
The next time I get cheap sieves I think I might wash them in the solvent first just to get the initial dust load out, recharge them, and then use them for their intended purpose. Although I suspect that if I balance the time, cost, and energy of doing this with the extra cost of better sieves, it's probably a good idea just to pay for the better sieves.
Pretty obvious in retrospect but maybe a fellow non-chemist will find it useful some day. | {
"domain": "chemistry.stackexchange",
"id": 15177,
"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": "equipment, filtering",
"url": null
} |
special-relativity
$$
Now proper velocity in terms of rapidity is $u(\phi) = \mathrm{sinh}(\phi)$, so $du/d\phi = \mathrm{cosh}(\phi)$.
The Lorentz factor is $\gamma = dt / d \tau = \mathrm{cosh}(\phi)$.
After substitition the product of $\frac{du}{d\phi}$ and $\frac{d \tau}{dt}$ cancel, so you the proper acceleration is indeed the rate of change of rapidity with respect to the proper time. | {
"domain": "physics.stackexchange",
"id": 21482,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "special-relativity",
"url": null
} |
optics, visible-light, reflection, refraction
of the angle from which it entered? It is impossible to do this perfectly with a static optical system. Think about the backwards-going rays: If they all originate from the same spot and are generally indistinguishable, they will always emit in the same distribution of directions. There is nothing time-dependent about the optical system, so a static input will result in a static output. The ideal solution for your general problem would use mirrors which track the location of the sun to focus the maximum power on the target at all times. | {
"domain": "physics.stackexchange",
"id": 84218,
"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, reflection, refraction",
"url": null
} |
condensed-matter
Title: How long is unit cell in metre? I have been reading papers on amorphous and crystalline heterostructure (topic related to condensed matter and solid state physics). Frequently, they used unit cell (uc) to describe the thickness of their material. Since I have little background, I am not sure what is the actual length of unit cell.
So, as the title suggest, how long is one unit cell in metre? A unit cell is simply the smallest sub component of crystalline structure, from which the entire lattice can be created. For instance, in a cubic lattice, the unit cell is a cube. Since the lattice spacing of a material depends highly on its constituents, the length of a unit cell is not a standard unit of measurement, but simply a way to demonstrate how large a crystal is, in reference to its lattice spacing.
I hope this helps! | {
"domain": "physics.stackexchange",
"id": 49647,
"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": "condensed-matter",
"url": null
} |
javascript, mysql, node.js, express.js
The code is VERY hard to read. It is not indented well (particularly around SQL queries), has no comments, and has inconsistent use of vertical whitespace to separate logical sections.
You have many more nested if-else conditions than are needed. You should always that about inverting conditions to de-nest things, and should use return appropriately to de-nest. Code with this many branches is going to be very fragile to maintain and extremely difficult to test all those code paths.
You have some case where you are doing this well like
db.query(queryChecking,(error,result)=>{
if(error) return res.status(400).json(error);
if(result[0].length > 0 && result[1].length > 0 && result[2].length === 0 && result[3].length < 15){ | {
"domain": "codereview.stackexchange",
"id": 33376,
"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, mysql, node.js, express.js",
"url": null
} |
newtonian-mechanics, classical-mechanics
The equation of motion for the rotation is:
$F_fr=I\dot{\omega}$.
With $v=2\pi fr=\omega r$, differentiate to $t$ and get $a=\dot{\omega}r$ or $\dot{\omega}=\frac{a}{r}$.
So that $F_fr^2=Ia$.
So we have two linear equations in $a$ and $F_f$ and we get:
$F_f=\frac{Ig\sin\alpha}{R^2+\frac{I}{m}}$.
But this is an ideal case: smooth ball on a smooth surface with just the right amount of friction to avoid slippage. In 'real world' cases there will be extra friction and this will do work that is irreversibly lost: for example a golf ball rolling down a grassy slope. Resistance by the grassy surface will cause some potential energy to be lost to friction work. | {
"domain": "physics.stackexchange",
"id": 24692,
"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": "newtonian-mechanics, classical-mechanics",
"url": null
} |
beginner, c, fibonacci-sequence
Title: Iterative Fibonacci sequence I implemented a function that prints all the numbers from the Fibonacci sequence until max_num. The minimum value allowed is 0 (so, fib(0) prints 1). It works until 92, and I want to know how to improve the code, in general.
void fib(unsigned int max_num)
{
unsigned long fib_num = 1;
unsigned long fib_temp = 0;
size_t count = 0;
if (max_num < 0)
{
fprintf(stderr, "Please, enter a non-negative number\n");
return;
} | {
"domain": "codereview.stackexchange",
"id": 21614,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "beginner, c, fibonacci-sequence",
"url": null
} |
cosmology, spacetime, curvature
$^\dagger$$\Omega_k$ is the fraction of the Universe's total energy content "contained" in curvature, defined through it's present-day's value $\Omega_{k,0} = kc^2/H_0^2$, and $\Omega_k(a) = \Omega_k/a^2$, where $a$ is the scale factor describing the relative size of the Universe, defined to be $1$ today. | {
"domain": "physics.stackexchange",
"id": 27987,
"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, spacetime, curvature",
"url": null
} |
java, multithreading, android, xml, adventure-game
//System.out.println("1 drawing the place:"+name);
//g.drawImage(image, 0, 20, this);
int xx = 200;
int yy = 0;
if (persons != null) {
synchronized (persons) {
Iterator<Person> iterate = persons.iterator();
while (iterate.hasNext()) {
Person p = iterate.next();
System.out.println("Fullscreen drawing:" + p.getName());
// Drawable appearance = getResources().getDrawable(p.image);
if (p.getImage() != 0) {
hero = BitmapFactory.decodeResource(getResources(), p.getImage()); //load a hero image
//hero = Bitmap.createScaledBitmap(hero, 10 * 2, 10 * 2, true); | {
"domain": "codereview.stackexchange",
"id": 28342,
"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, multithreading, android, xml, adventure-game",
"url": null
} |
frequency, infinite-impulse-response, reverb
1F801DE6h rev13 mRDIFF src/dst Reverb Different Side Reflect Address 1 Right
1F801DE8h rev14 mLCOMB3 src Reverb Comb Address 3 Left
1F801DEAh rev15 mRCOMB3 src Reverb Comb Address 3 Right
1F801DECh rev16 mLCOMB4 src Reverb Comb Address 4 Left
1F801DEEh rev17 mRCOMB4 src Reverb Comb Address 4 Right
1F801DF0h rev18 dLDIFF src Reverb Different Side Reflect Address 2 Left
1F801DF2h rev19 dRDIFF src Reverb Different Side Reflect Address 2 Right
1F801DF4h rev1A mLAPF1 src/dst Reverb APF Address 1 Left
1F801DF6h rev1B mRAPF1 src/dst Reverb APF Address 1 Right
1F801DF8h rev1C mLAPF2 src/dst Reverb APF Address 2 Left
1F801DFAh rev1D mRAPF2 src/dst Reverb APF Address 2 Right | {
"domain": "dsp.stackexchange",
"id": 12018,
"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": "frequency, infinite-impulse-response, reverb",
"url": null
} |
evolution, senescence
Title: Evolution of Aging according to Weismann Several authors agree to the fact that August Weismann was the first to propose an explanation to biological aging (Kirkwood and Cremer, 1982; Gems and Partridge, 2013).
A lot of hallmarks (and some contradictory) are pointed out about Weismann along his life, which I am reflecting only in these
When he suggested that group selection was the answer of aging;
August Weismann and Alfred Russel Wallace proposed that aging has evolved to remove worn-out older individuals, thereby reducing competition for scarce resources and resulting in benefits for the species. However, such an evolutionary mechanism would require group selection of a sort that makes this an untenable scenario. (Gems and Partridge, 2013) | {
"domain": "biology.stackexchange",
"id": 11579,
"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": "evolution, senescence",
"url": null
} |
biochemistry, virology
Why does just having an envelope make it susceptible to soap and alcohol? Soap molecules are amphiphilic. This means those molecules have parts which are hydrophilic (water-loving, or "polar") and parts which are hydrophobic (water-avoiding, or "non-polar").
Fat molecules are non-polar. They avoid water. This is why a mixture of oil and water will separate into layers. In this mix, oil molecules prefer to hang around other oil molecules, and water molecules prefer to hang around other water molecules. Soap "likes" both oil and water, so it can be used for cleaning, by helping dissolve this mixture. (For a similar reason, this is why vinegar is used to dissolve or emulsify oil in salad dressings. Vinegar — acetic acid — is amphiphilic and likes both water and oil.) | {
"domain": "biology.stackexchange",
"id": 10834,
"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, virology",
"url": null
} |
discrete-signals, wavelet, time-frequency, cwt
and analogue scale-to-frequency mappings:
Energy, $\tilde\omega_s \equiv \tilde \omega_\psi / s$: correctly gives mean of energy scales of the transform
Peak, $\omega_s \equiv \omega_\psi / s$: correctly gives frequency of scale at which CWT of a sinusoid obtains maximum
Instantaneous central, $\breve\omega_s \equiv \breve\omega_\psi(0) / s$: correctly gives frequency to be same as rate of phase progression of CWT at the location of an infinitesimally narrow pulse. | {
"domain": "dsp.stackexchange",
"id": 10372,
"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": "discrete-signals, wavelet, time-frequency, cwt",
"url": null
} |
php, beginner, object-oriented, classes
public function __construct($username, $password, $email, $conn)
{
$this->username = $username;
$this->password = $password;
$this->email = $email;
$salt = time();
$pwd = sha1($this->password . $salt);
$sql = 'INSERT into users (username, password, salt, email) VALUES (?, ?, ?, ?)';
$stmt = $conn->stmt_init();
$stmt = $conn->prepare($sql);
$stmt->bind_param('ssis', $this->username, $pwd, $salt, $this->email);
$stmt->execute();
if ($stmt->affected_rows == 1) {
$this->success = "$this->username has registered. You can now log in.";
} elseif ($stmt->errno == 1062) {
$this->errors[] = "$this->username or $this->email is already in use. Please redo.";
} else {
$this->errors[] = 'Sorry, there was an issue with the database.';
} | {
"domain": "codereview.stackexchange",
"id": 11024,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "php, beginner, object-oriented, classes",
"url": null
} |
It's not about the nomenclature (though in your setting such an open set is said to be "relatively compact"), but the idea of the proof of what you want.
You can choose for each $$x \in C$$ an open set $$O_x$$ such that $$x \in O_x \subseteq \overline{O_x} \text{ (which is compact) } \subseteq U$$
because in a locally compact Hausdorff space the compact neighbourhoods (or open sets with compact closure, aka relatively compact open sets) of $$x$$ form a local base.
$$C$$ being compact allows us to find a finite subcover of $$O_x$$'s and the union of these can be your $$D$$, and its closure (which you could call $$A$$) is compact (as the finite union of the corresponding $$\overline{O_x}$$) and of course sits inside $$U$$ still.
Confusing symbol choices: I'd say:
for a compact $$C$$ with an open set $$C \subseteq U$$ we can find an open set $$V$$ such that $$\overline{V}$$ is compact and such that $$C \subseteq V \subseteq \overline{V} \subseteq U$$. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9683812331876135,
"lm_q1q2_score": 0.8048633255900111,
"lm_q2_score": 0.8311430436757312,
"openwebmath_perplexity": 68.34222412465698,
"openwebmath_score": 0.9107244610786438,
"tags": null,
"url": "https://math.stackexchange.com/questions/3662775/what-is-the-name-for-the-open-set-that-is-contained-in-some-compact-set"
} |
entanglement, linear-algebra, emulation
If you want to do a two-qubit gate $V$ between qubits $i$ and $j$, say, then you have to combine the states at both sites. So, you replace two registers each of dimension 2 with one register of dimension 4, containing state $V|\psi_i\rangle|\psi_j\rangle$. The problem is that you now can't split this state up again, so you have to keep those two qubits in a register forever after. Of course, if you ever have a 1-qubit gate $U$ to apply on qubit $i$, you'll now have to apply $|\psi_{i,j}\rangle\mapsto U\otimes\mathbb{I}|\psi_{i,j}\rangle$. Then, the next time you want a 2-qubit gate between, say, $j$ and $k$, you'll have to combine the spaces for $(i,j)$ and $k$. Those spaces will keep growing, but if a gate is localised on just one space, you only have to apply it there (using $\mathbb{I}$ operators to pad it on the rest of the qubits), and you don't have to do anything to the other spaces. | {
"domain": "quantumcomputing.stackexchange",
"id": 141,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "entanglement, linear-algebra, emulation",
"url": null
} |
microbiology, bacteriology, plasmids
Title: Why are plasmid genes not already incorporated into bacterial chromosomes if necessary for stressful situations? If plasmids are important for bacteria to express specific genes under stressful conditions, why are these genes not already incorporated into their chromosome to begin with? What is the evolutionary significance for this? Plasmids do have the advantage that they replicate independently of the cells chromosome and that they can be transferred between different bacteria. This spreads the gene encoded by the plasmid to other bacteria, which then can also survive.
Think about antibiotic resistance. Bacteria which have a plasmid which allows protection against the antibiotic will survive. They can transfer this protection to other bacteria which then also become resistant. This can either happen through pili which develop between bacteria or also via the uptake of plasmid DNA from the environment in a process called horizontal gene transfer. | {
"domain": "biology.stackexchange",
"id": 3514,
"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": "microbiology, bacteriology, plasmids",
"url": null
} |
Then, in the numerator, $$2 \cdot 3 = 6$$, and in the denominator, $$2 \cdot 3^2 = 18$$.
$$\frac{12\sqrt{2 \cdot 3}}{2 \cdot 3^{2}} = \frac{12\sqrt{6}}{18}$$
Finally, reduce to lowest terms by dividing both numerator and denominator by 6.
$$\frac{12\sqrt{6}}{18} = \frac{2\sqrt{6}}{3}$$
In Figure 9, the approximation for the original expression $$\frac{12}{\sqrt{54}}$$ matches that of its simple radical form $$\frac{2\sqrt{6}}{3}$$
## Variable Expressions
If x is any real number, recall again that
$\sqrt{x^2} = |x| \nonumber$
If we combine the law of exponents for squaring a quotient with our property for taking the square root of a quotient, we can write
$\sqrt{(\frac{a}{b})^2} = \sqrt{\frac{a^2}{b^2}} = \frac{\sqrt{a^2}}{\sqrt{b^2}} \nonumber$
However, $$\sqrt{(\frac{a}{b})^2} = |\frac{a}{b}|$$, while $$\frac{\sqrt{a^2}}{\sqrt{b^2}} = \frac{|a|}{|b|}$$. This discussion leads to the following key result.
Quotient Rule for Absolute Value
If a and b are any real numbers, then | {
"domain": "libretexts.org",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9911526459624252,
"lm_q1q2_score": 0.8302092449775559,
"lm_q2_score": 0.8376199653600372,
"openwebmath_perplexity": 356.65065799553645,
"openwebmath_score": 0.9020271897315979,
"tags": null,
"url": "https://math.libretexts.org/Bookshelves/Algebra/Intermediate_Algebra_(Arnold)/09%3A_Radical_Functions/9.03%3A_Division_Properties_of_Radicals"
} |
graphs, np
Pick an 'uncoloured' vertex $v \in V(G)$.
For every vertex $u \in N(v)$, if $u$ has been coloured, then there is one $k_{i}$ such that $uk_{i} \notin E(G)$. Add the edge $vk_{i}$ to $E$.
For the remaining vertices $k_{j}$ such that $vk_{j}$ is not yet in $E$, we add all other edges between $v$ and the $K_{k}$ and ask the oracle if the new graph is $k$-colourable. If it is, we keep this graph and move on to the next vertex, if the answer is No, we undo step 3 and try with the next $k_{j}$. | {
"domain": "cs.stackexchange",
"id": 736,
"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": "graphs, np",
"url": null
} |
thermodynamics, visible-light, thermal-radiation, biophysics
As curly hair tends to trap more of the poorly conducting air, curly hair provides somewhat better insulating properties, compared to straight hair. All other things being equal that is a reasonable assumption.
This table shows the heat conductivity values of a number of common materials, notice how porous materials mostly have lower heat conductivities. | {
"domain": "physics.stackexchange",
"id": 75901,
"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, visible-light, thermal-radiation, biophysics",
"url": null
} |
homework-and-exercises, electromagnetism, magnetic-fields, maxwell-equations, poynting-vector
So far, I have used Ampere's Law to determine the magnetic field, which for $r \le R$ (and ignoring Maxwell's correction) is:
$$ \vec B=\mu_0 \kappa(t) \hat z$$
and nule for the remaining space. Faraday's Law in integral form:
${\displaystyle \oint _{\partial \Sigma }\mathbf {E} \cdot \mathrm {d} \mathbf {l} =-{\int _\Sigma }\mathbf {\frac {\mathrm {d} {B} }{\mathrm {d} t}} \cdot \mathrm {d} \mathbf {A} }$
leads to (for $r\le R$): $$\vec E(t)=-\frac{\mu_0}{2} \frac{d \kappa(t)}{d \kappa}r \hat\phi$$
So the Poynting vector $\vec S =\frac{\vec E \times \vec B}{\mu_0}$ is nule for $R \le r$ and, for $r \le R$:
$$\vec S=-\frac{\mu_0}{2}\kappa(t)\frac{d \kappa(t)}{d \kappa}r \hat r$$
I understand all the steps of the problem, but what I can't understand is why the vector $\vec S$ is discountinuous on the surface of the cylinder. | {
"domain": "physics.stackexchange",
"id": 67756,
"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, electromagnetism, magnetic-fields, maxwell-equations, poynting-vector",
"url": null
} |
Square Roots of Quotients 4:49 Rationalizing Denominators in Radical Expressions 7:01 To simplify this radical number, try factoring it out such that one of the factors is a perfect square. 1) 125 n 5 5n 2) 216 v 6 6v 3) 512 k2 16 k 2 4) 512 m3 16 m 2m 5) 216 k4 6k2 6 6) 100 v3 10 v v 7) 80 p3 4p 5p 8) 45 p2 3p 5 9) 147 m3n3 7m ⋅ n 3mn 10) 200 m4n 10 m2 2n 11) 75 x2y 5x 3y 12) 64 m3n3 Aptitude test online. Print; Share; Edit; Delete; Report an issue; Host a game. Dividing Radical Expressions. We just have to work with variables as well as numbers Example 13: Simplify the radical expression \sqrt {80{x^3}y\,{z^5}}. Let’s simplify this expression by first rewriting the odd exponents as powers of an even number plus 1. \int_{\msquare}^{\msquare} \lim. Example 8: Simplify the radical expression \sqrt {54{a^{10}}{b^{16}}{c^7}}. Play this game to review Algebra II. The simplify/radical command is used to simplify expressions which contain radicals. Simplifying radical expressions calculator. | {
"domain": "mid.gr",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.96741025335478,
"lm_q1q2_score": 0.8627471521934389,
"lm_q2_score": 0.89181104831338,
"openwebmath_perplexity": 666.4039805951548,
"openwebmath_score": 0.7712398767471313,
"tags": null,
"url": "https://mid.gr/bk40qmd/simplify-radical-expressions-46f37a"
} |
thermodynamics, entropy, heat-engine
What I do not understand is the engine does work, which is a form of energy transfer where energy leaves the engine, so why can we not have an engine where the work done by it restores its entropy, leaving us with zero energy having to be dumped to reduce entropy? | {
"domain": "physics.stackexchange",
"id": 43698,
"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, entropy, heat-engine",
"url": null
} |
biochemistry, enzymes
My question is, what exactly is happening here that helps to neutralize a free radical, and what is the part after the transition state doing?
If I had to guess, based on that cofactors generally can be affected during a reaction, perhaps Iron somehow binds with the free radical and share its electrons, effectively neutralizing the unpaired electron as well as using up the Iron atom? I imagine the "pulling" in the book could fit a description of a weak chemical bond/attraction, but I'm still unsure. Catalase (hydrogen peroxide oxidoreductase) does not actually quench free radicals. It catalyzes the conversion of hydrogen peroxide to water; the former is a source of a free radical, not a free radical in itself. | {
"domain": "biology.stackexchange",
"id": 3260,
"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, enzymes",
"url": null
} |
vba
If you are concatenating just two cells maybe using an array and JOINing is a bit overblown: strCell = Join(Array(wsSource(i, 1), wsSource(i, 3)), "|"). But the best is to run a benchmark and test performance using different approaches. Don't be afraid to experiment. Good code is code that is efficient while remaining intelligible.
I don't understand why you declare your variable like this: Dim wsSource As Worksheet and then use it like this: wsSource = .Range("C17:U" & LRow).value. Did you mean Range ?
The choice of data type for your variables is not always optimal: several variables are of type Double. From the doc: "Double (double-precision floating-point) variables are stored as IEEE 64-bit (8-byte) floating-point numbers ranging in value from: -1.79769313486231E308 to -4.94065645841247E-324 for negative values and 4.94065645841247E-324 to 1.79769313486232E308 for positive values". Performance matters when you are doing arithmetic operations in loops. | {
"domain": "codereview.stackexchange",
"id": 37930,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "vba",
"url": null
} |
condensed-matter, quantum-entanglement, superconductivity
Title: Cooper pairs and superconductivity This might be a dumb series of questions, because I'm not a theoretical or condensed matter physicist.
If there was a method of pairing all electrons before entering a semiconductor, would you essentially have a cheat code to turn any semiconductor into a superconductor, or does the lattice of semiconductors vibrate too much that pairs would still bump into it, disengaging the pairs, and losing energy to heat?
If the latter is true, is this because the energy required to maintain and disengage entanglement is low?
If the former may be true, would energy in the transmission of electrons still be lost due to the effort required to establish electron pairs? Essentially, there is nothing special about the lattice of a semiconductor that would prevent it to "host" Cooper pairs. | {
"domain": "physics.stackexchange",
"id": 77675,
"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": "condensed-matter, quantum-entanglement, superconductivity",
"url": null
} |
modulus of complex number properties 2021 | {
"domain": "com.pl",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138105645059,
"lm_q1q2_score": 0.8016210420152463,
"lm_q2_score": 0.8198933403143929,
"openwebmath_perplexity": 944.2665439370911,
"openwebmath_score": 0.7277530431747437,
"tags": null,
"url": "http://szadkowski.com.pl/structural-unemployment-fhdhxyj/modulus-of-complex-number-properties-449d09"
} |
thermodynamics, entropy, carnot-cycle
I am also unsure about $ (3) $. If the heat is being added to the reservoirs infinitely slowly, then wouldn't the same be true of the system? This would make $ ∆S_{sys} = -∆S_{res} ≠ 0 $ and is obviously not correct. Exactly as you said: "(5) seems to say that the entropy change for an irreversible process is 0 for the case of the system itself, but is > 0 for the case of the surroundings." After the cycle is finished, by definition of the "cycle", the system returns to its original state irrespective of all the irreversibilities that may have taken place within it during some portions of the cycle.
Entropy being a state variable it also assumes its initial value after the cycle. The only place therefore where the entropy will have increased after the cycle is in the reservoirs that do not perform any "cycle", they are sinks and sources of heat and their state can and will change per Clausius., i.e., $$\Delta S_{res} =\frac{q_{res}}{T_{res}}$$ | {
"domain": "physics.stackexchange",
"id": 12230,
"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, entropy, carnot-cycle",
"url": null
} |
quantum-mechanics, quantum-information, quantum-entanglement, faster-than-light, locality
Title: How do we know quantum entanglement works no matter the distance? It is said quantum entanglement works regardless of distance. 2 particles can be entangled and information is shared instantaneously, even if they are lightyears away from each other.
But how do we know this still works with such a vast distance between both particles?
I can image experiments in a lab, or even on opposites sides of the planet, but not with light years between them.
So how do we know? Distance is not a relativistic invariant. Let A be the event marked by my beginning to write this answer, and B the event where I finish writing it. In the frame of reference of my desk, the distance between A and B is zero, but in the frame of reference of an observer moving at $0.9999999c$ relative to the earth, the distance between A and B is millions of kilometers. | {
"domain": "physics.stackexchange",
"id": 53185,
"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-information, quantum-entanglement, faster-than-light, locality",
"url": null
} |
python, beginner, datetime, tkinter
def replace_forward(event):
l1.configure(text=replace(l1["text"], "+"))
if l1["text"] == "Febuary":
change_month(Febuary)
load()
elif l1["text"] == "March":
change_month(March)
load()
elif l1["text"] == "April":
change_month(April)
load()
elif l1["text"] == "May":
change_month(May)
load()
elif l1["text"] == "June":
change_month(June)
load()
elif l1["text"] == "July":
change_month(July)
load()
elif l1["text"] == "August":
change_month(August)
load()
elif l1["text"] == "September":
change_month(September)
load()
elif l1["text"] == "October":
change_month(October)
load()
elif l1["text"] == "November":
change_month(November)
load()
elif l1["text"] == "December":
change_month(December)
load()
else:
change_month(January)
load() | {
"domain": "codereview.stackexchange",
"id": 19075,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "python, beginner, datetime, tkinter",
"url": null
} |
and the second HK theorem? benedikta siboro on 8 May 2018 We could also say that circumcenter is the point in the plane of a triangle equidistant from all three vertices of the triangle. Line 1: 3x -2y = 4 Line 2: x + 4y = 1 Solution Put 3x - 2y = 4 into slope-intercept form so you can clearly identify the slope. Ex 11.2, 10 Find the angle between the following pairs of lines: (i) ⃗ = 2 ̂− 5 ̂ + ̂ + (3 ̂ + 2 ̂ + 6 ̂) and ⃗ = 7 ̂ – 6 ̂ + ( ̂ + 2 ̂ + 2 ̂) Ex 11.2, 10 Find the angle between the following pairs of lines: (i) ⃗ = 2 ̂− 5 ̂ + ̂ + (3 ̂ + 2 ̂ + 6 ̂) and ⃗ = Select two lines, or enter p to specify points. But between two intersecting lines, there are a total four angles formed at the point of intersection. Should I hold back some ideas for after my PhD? tanθ=±(m 2-m 1) / (1+m 1 m 2) Angle Between Two Straight Lines Derivation. The task is to find the angle between these two planes in 3D. Use MathJax to format equations. Asking for help, clarification, or responding to other | {
"domain": "ludatou.com",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9653811611608242,
"lm_q1q2_score": 0.8262225793642178,
"lm_q2_score": 0.8558511524823263,
"openwebmath_perplexity": 387.12714507923596,
"openwebmath_score": 0.5351652503013611,
"tags": null,
"url": "http://ludatou.com/4mhiqzo/95d5a1-angle-between-two-lines-in-3d"
} |
From hereon we could continue similiar like Jack D'Aurizio or Sangchul Lee already did. We will exploit a different attempt starting with a very similiar substitution $$x\mapsto \tan x$$ we conclude via several trigonometric identities that
\begin{align*} -2\int_0^1\frac{\log(1-x)}{1+x^2}\mathrm dx&=-2\int_0^{\pi/4}\log(1-\tan x)\mathrm dx\\ &=-2\int_0^{\pi/4}\log\left(\frac{\sqrt 2\sin\left(\frac\pi4-x\right)}{\cos x}\right)\mathrm dx\\ &=-\frac\pi4\log(2)-2\int_0^{\pi/4}\log\left(\sin\left(\frac\pi4-x\right)\right)\mathrm dx+2\int_0^{\pi/4}\log(\cos x)\mathrm dx\\ &=-\frac\pi4\log(2)-2\int_0^{\pi/4}\log(\tan x)\mathrm dx \end{align*}
The aformentioned Clausen Function is capable of expressing the latter integral in a closed-form expression. To be precise we further get | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9919380089483864,
"lm_q1q2_score": 0.8015525874929135,
"lm_q2_score": 0.8080672181749422,
"openwebmath_perplexity": 463.1162729460503,
"openwebmath_score": 0.9999796152114868,
"tags": null,
"url": "https://math.stackexchange.com/questions/2837145/what-about-of-this-integral-involving-the-gudermannian-function-int-0-infty"
} |
ros-control
Originally posted by BigBuddha on ROS Answers with karma: 66 on 2015-06-15
Post score: 3 | {
"domain": "robotics.stackexchange",
"id": 21931,
"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-control",
"url": null
} |
object-oriented, csv, xml, vb.net
Q3: As long as i know definition of interfaces e.g "Need to provide common functionality to unrelated classes" what in my example code is real benefit as all of my specific parsers uses the same interfaces at the end? All can open, read, transform and save...
Q4: As you see i have 3 specific parser classes: CsvParser, XmlParser, TxtParser inheriting from their base EtlParser class. Wouldn't it be better to make one parser class and instead make interface IXml, ITxt, ICsv which will be implemented? At this moment i think what i have is proper.
Q5: Why in the Main method i cannot do: parser.SaySomething() However when i look at parser item it shows exactly correct type.
Q6: Any ideas, advices to my current code besides?
Q1: It takes nanoseconds to create an object and milliseconds to access a file; i.e. roughly one million times longer! Don't try to optimize things that will have absolutely no noticeable effect at the expense of clarity! | {
"domain": "codereview.stackexchange",
"id": 27456,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "object-oriented, csv, xml, vb.net",
"url": null
} |
orbit, fundamental-astronomy, binary-star
Title: How to plot orbit of binary star and calculate its orbital elements? I have a set of dates, position angles ($\theta$) and angular separations ($\rho$) for visual binary star. For example:
1994.3132 57.0 0.097
1996.1783 73.4 0.051
2006.1938 182.0 0.126
2009.2597 192.9 0.152
etc.
What are algorithms to calculate orbital elements and to plot the orbit of the binary star?
Are there available codes (or programs) for this calculations? The good software for orbit calculation is "Binary" (Binary Star Combined Solution Package) by CHARA team:
http://www.astro.gsu.edu/~gudehus/binary.html | {
"domain": "astronomy.stackexchange",
"id": 210,
"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": "orbit, fundamental-astronomy, binary-star",
"url": null
} |
spacetime, vectors, event-horizon, spacetime-dimensions
Title: How many null directions are there?
The metric signature of spacetime is usually given as ($3,1$), but spaces can also be ($3,n,1$). Null surfaces include photons and event horizons, which exist, so is $n$ actually $ > 1$ in the signature?
In theory, could an experiment establish the number of null dimensions/directions?
In another answer, someone said there are an infinite number of null directions. If that's true, is there ever any reason to specify $n$ in the signature? | {
"domain": "physics.stackexchange",
"id": 100110,
"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": "spacetime, vectors, event-horizon, spacetime-dimensions",
"url": null
} |
slam, localization, navigation, gmapping
Originally posted by RND on ROS Answers with karma: 133 on 2015-04-18
Post score: 1
Original comments
Comment by N.N.Huy on 2021-03-26:
Hello, did you find the answer, i have the same concern as you have :))
GMapping does not publish geometry_msgs/PoseWithCovarianceStamped message as robot_pose_ekf and other packages do. Instead it provide transformation from map frame to odom frame. In combination with transformation from odom frame to robot base frame (provided by your odometry) you have estimation of your robot pose.
About the rotation problem you have other informations are needed (about hardware, configuration etc).
Bye
Ale
Originally posted by afranceson with karma: 497 on 2015-04-20
This answer was ACCEPTED on the original site
Post score: 4 | {
"domain": "robotics.stackexchange",
"id": 21461,
"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": "slam, localization, navigation, gmapping",
"url": null
} |
# Factor Large Factorial
• Mar 14th 2010, 10:50 PM
jzellt
Factor Large Factorial
How could I factor 30! into prime factors?
Can you show the steps please...
• Mar 14th 2010, 10:56 PM
Drexel28
Quote:
Originally Posted by jzellt
How could I factor 30! into prime factors?
Can you show the steps please...
Prime factorize $1,\cdots,30$
• Mar 15th 2010, 07:50 AM
Soroban
Hello, jzellt!
I'll use the "greatest integer function": . $[x]$
Quote:
Factor 30! into prime factors.
30! contains $2^{26}$
. . How do we know this?
Every 2nd term is even, contains a factor of two.
. . There are: . $\left[\frac{30}{2}\right] \:=\:15$ factors of two.
But every 4th term has a factor of 4 $(2^2)$, which contributes an additional two.
. . There are: . $\left[\frac{30}{4}\right] \,=\,7$ more factors of two.
And every 8th term has a factor of 8 $(2^3)$, which contributes yet another two.
. . There are: . $\left[\frac{30}{8}\right] \,=\,3$ more factors of two. | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9830850837598123,
"lm_q1q2_score": 0.81272803122057,
"lm_q2_score": 0.826711791935942,
"openwebmath_perplexity": 1766.6739920987059,
"openwebmath_score": 0.8094603419303894,
"tags": null,
"url": "http://mathhelpforum.com/number-theory/133846-factor-large-factorial-print.html"
} |
python, numpy, iterator, pandas, fibonacci-sequence
df = pd.DataFrame(data=datas[1:,1:],index=datas[1:,0],columns=datas[0,1:])
print(df)
If you want to provide an example that does the same and produces a Pandas dataframe like this it would be very useful for me to study your code. You’re using the wrong tool for the job. Basically, you do all the computation in Python, use numpy for intermediate storage and pandas for display.
Instead, you should compute the list of tribonacci numbers and from there on use pandas for anything else as it would be much more efficient / readable. I’d keep building the tribonacci numbers in Python as I don't know enough pandas to be able to come up with an efficient way that wouldn't involve Dataframe.append and also because it can be expressed very nicely as a generator:
def tribonacci_sequence():
a, b, c = 0, 1, 1
yield a
yield b
while True:
yield c
a, b, c = b, c, a + b + c | {
"domain": "codereview.stackexchange",
"id": 29216,
"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, numpy, iterator, pandas, fibonacci-sequence",
"url": null
} |
least one member of S. Graph Theory What is a Eulerian cycle? Graph Theory What is a complete graph? Graph Theory How many edges are there in a complete graph with n vertices (Kn)? Graph Theory For a complete graph of n vertices (Kn), how many Hamiltonian cycles are there (assuming tours in reverse order are of the same length? Graph Theory For a complete graph of n. By convention, the singleton graph is considered to be Hamiltonian even though it does not posses a. This chapter presents the theorem of Hamiltonian cycles in regular graphs. Hamiltonian Graphs in general Determining if a graph is Hamiltonian is NP-complete, so there is no easy necessary and sufficient condition. Complete Bipartite graph fulfills Dirac's Theorem and thus is guaranteed to have a Hamiltonian Cycle. In the broad eld of Computer Science the problem of determining if a graph is Hamiltonian is known to. De Bruijn also realized that Minimal Superstrings were ***Eulerian cycles*** in (k−1)-dimensional "De Bruijn | {
"domain": "giardinilegnone.it",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9888419703960398,
"lm_q1q2_score": 0.8037973224824343,
"lm_q2_score": 0.8128673201042493,
"openwebmath_perplexity": 421.31380160784477,
"openwebmath_score": 0.6590907573699951,
"tags": null,
"url": "http://nhri.giardinilegnone.it/number-of-hamiltonian-cycles-in-a-complete-graph.html"
} |
algorithms, algorithm-analysis, runtime-analysis, sorting
As you can see I have a problem - O(log m). How to eleminate it ? What exactly does $n \gg m$ mean for your professor?
If it means $m \in o(n)$, then you are allowed $O(\log m)$ time for step 2.2. Note that $\log(n/m) = \log n - \log m$. If $m \in o(n)$, the target runtime bound simplifies to $O(m \log n)$; a summand $m \log m$ is dominated by this.
If $m \in \Theta(n)$ is allowed -- arguably, $m = n \cdot 10^{-10}$ would fulfill "a lot smaller" -- you can have that $\log n/m \in O(1)$ and the runtime bound is $O(m)$. It's quite clearly impossible to perform this task in time $O(m)$, so I think we can safely ignore this case for the purpose of this exercise.
But here is something more for you to think about. | {
"domain": "cs.stackexchange",
"id": 4966,
"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, algorithm-analysis, runtime-analysis, sorting",
"url": null
} |
history, language-design, c++
In retrospect, I think these notions have been very important for C++'s success as a practical tool. Over the years, just about everybody has had some kind of expensive idea that could be implemented "for classes only," leaving low overhead and low features to structs. I think the idea of keeping struct and class the same concept saved us from classes supporting an expensive, diverse, and rather different set of features than we have now. In other words, the "a struct is a class" notion is what has stopped C++ from drifting into becoming a much higher-level language with
a disconnected low-level subset. Some would have preferred that to happen. | {
"domain": "cs.stackexchange",
"id": 14558,
"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": "history, language-design, c++",
"url": null
} |
ros-kinetic, gazebo-7
Title: How to create an ellipsoid
I would like to create an ellipsoid in Gazebo (and use it as static, and only visual, no collision). Reason for that is that I want to show an object and the minimum-volume ellipsoid enclosing the object. I have the algorithm to calculate the ellipsoid, but I don't know how to spawn it in Gazebo (no problem for a sphere, but I can't find any ellipsoid model). Is there any way to do so ?
I'm using Gazebo7 and ROS Kinetic. | {
"domain": "robotics.stackexchange",
"id": 4061,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "ros-kinetic, gazebo-7",
"url": null
} |
thermodynamics, pressure
Title: Why do we use the external pressure to calculate the work done by gas I read in a textbook that in the case when we have a gas in a cylinder fitted with a massless frictionless piston being held with an external pressure $p_1$, and when the pressure is reduced to become the value $p_2$, the gas pushes up against the piston and then the work done by the gas for a small change in volume is calculated by:
$$\mathrm dW=p_2\,\mathrm dV$$ | {
"domain": "chemistry.stackexchange",
"id": 14843,
"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, pressure",
"url": null
} |
death, anthropology, forensics, decomposition
Title: Can rigor mortis change the anatomical position in which a person died? I've been told as an undergrad in anthropology that the flexed position of the body in which some Neanderthal skeletons were found indicates that they were deliberately buried. Apart from the good preservation of the remains, one of the arguments for deliberate burial was that if the individual had died in this very flexed position during sleep, rigor mortis or post-mortem bloating would have caused the body, if not already buried, to extend (see e.g. Villa's [1989:325] comments to Gargett 1989). Barring sudden death by rockfall and ceiling collapse, this suggests that the body was completely buried before rigor mortis set in, or was deliberately placed in this sleeping position after rigor mortis faded by those that buried it. | {
"domain": "biology.stackexchange",
"id": 6759,
"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": "death, anthropology, forensics, decomposition",
"url": null
} |
# Simple expressions for $\sum_{k=0}^n\cos(k\theta)$ and $\sum_{k=1}^n\sin(k\theta)$? [duplicate]
Possible Duplicate:
How can we sum up $\sin$ and $\cos$ series when the angles are in A.P?
I'm curious if there is a simple expression for $$1+\cos\theta+\cos 2\theta+\cdots+\cos n\theta$$ and $$\sin\theta+\sin 2\theta+\cdots+\sin n\theta.$$ Using Euler's formula, I write $z=e^{i\theta}$, hence $z^k=e^{ik\theta}=\cos(k\theta)+i\sin(k\theta)$. So it should be that \begin{align*} 1+\cos\theta+\cos 2\theta+\cdots+\cos n\theta &= \Re(1+z+\cdots+z^n)\\ &= \Re\left(\frac{1-z^{n+1}}{1-z}\right). \end{align*} Similarly, \begin{align*} \sin\theta+\sin 2\theta+\cdots+\sin n\theta &= \Im(z+\cdots+z^n)\\ &= \Im\left(\frac{z-z^{n+1}}{1-z}\right). \end{align*} Can you pull out a simple expression from these, and if not, is there a better approach? Thanks!
-
## marked as duplicate by Aryabhata, J. M., Rahul, Asaf Karagila, Zev ChonolesJan 26 '12 at 16:51 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822876992225169,
"lm_q1q2_score": 0.8053711407038353,
"lm_q2_score": 0.8198933381139645,
"openwebmath_perplexity": 428.1477306415883,
"openwebmath_score": 0.9961974024772644,
"tags": null,
"url": "http://math.stackexchange.com/questions/102477/simple-expressions-for-sum-k-0n-cosk-theta-and-sum-k-1n-sink-theta?answertab=active"
} |
python, performance, numpy, cython
cdef np.ndarray center2 = basisobject2.center
cdef np.ndarray exponents2 = basisobject2.exponents
cdef np.ndarray coefficients2 = basisobject2.coefficients
cdef np.ndarray shell2 = basisobject2.shell
cdef np.ndarray normcoeffs2 = basisobject2.normcoeffs
for index1, exponent1 in enumerate(exponents1):
for index2, exponent2 in enumerate(exponents2):
t_nuclearintegral = 0.0
gamma = exponent1+exponent2
gaussiancenter, gaussianintegral = gaussiantheorem(center1, exponent1, center2, exponent2)
for atom in atomobjects:
for expansionindex1A in range(0, shell1[0]+shell2[0]+1):
for expansionindex1B in range(0, int(expansionindex1A//2)+1):
for expansionindex1C in range(0, int((expansionindex1A-(2*expansionindex1B))//2)+1): | {
"domain": "codereview.stackexchange",
"id": 44778,
"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, performance, numpy, cython",
"url": null
} |
# Order of MATLAB FFT frequencies
This wikibook states that the output of MATLAB's FFT corresponds with the wavenumbers ordered as:
$$k=\left\{0,1,...,\frac{n}{2},-\frac{n}{2}+1,-\frac{n}{2}+2,...,-1\right\}$$
However, in the example codes on the same page, the wavenumbers are coded as
k = [0:n/2-1 0 -n/2+1:-1];
which is the same as the first, but with the $n/2$-wavenumber (the "maximum wavemnumber") replaced with $0$. It seems strange that they would include $0$ twice.
It seems the correct order is necessary for taking derivatives via Fourier transforms, as described in the wikibook. Which of these is correct, and does MATLAB document this anywhere?
-
look into the function fftshift. It will take the output of fft, and reorder it from [-n/2+1 : n/2-1], which should help with your confusion. – Godric Seer Feb 18 '13 at 18:05 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9353465098415279,
"lm_q1q2_score": 0.8175650927774668,
"lm_q2_score": 0.8740772368049822,
"openwebmath_perplexity": 1145.7735812887574,
"openwebmath_score": 0.5898700952529907,
"tags": null,
"url": "http://scicomp.stackexchange.com/questions/5314/order-of-matlab-fft-frequencies"
} |
reproduction, epigenetics, stem-cells
There may be an effect on genetics because the natural selection process. Spermatogenesis and oogenesis is a highly selective process; only a small fraction of the ova generated by the ovaries ever mature and a large percentage of sperm generated are not motile or have other irregularities. During fertilization, sperm competition obviously throws out all but one in 250 million. It also appears that there are processes in the fallopian tubes that can store the sperm for several (up to 5) days before fertilization.
So while its not strongly established one can see how various IVF processes vary from in vivo fertilization. This could have an impact on epigenetic factors, although different sperm vary genetically due to Meiosis and this would be a big source of genetic variation in the outcome. | {
"domain": "biology.stackexchange",
"id": 1002,
"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": "reproduction, epigenetics, stem-cells",
"url": null
} |
quadcopter, pid, raspberry-pi
static double gyroX = 0;
static double gyroY = 0;
static double gyroZ = 0;
static double accelX;
static double accelY;
static double accelZ;
static double angleX;
static double angleY;
static double angleZ;
public Sensor() {
//System.out.println("Hello, Raspberry Pi!");
try {
bus = I2CFactory.getInstance(I2CBus.BUS_1);
sensor = bus.getDevice(0x68);
sensor.write(0x6B, (byte) 0x0);
sensor.write(0x6C, (byte) 0x0);
System.out.println("Calibrating...");
calibrate(); | {
"domain": "robotics.stackexchange",
"id": 635,
"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": "quadcopter, pid, raspberry-pi",
"url": null
} |
navigation, turtlebot, namespaces, amcl, move-base
amcl.launch:
<launch>
<arg name="use_map_topic" default="false"/>
<arg name="scan_topic" default="scan"/>
<arg name="initial_pose_x" default="0.0"/>
<arg name="initial_pose_y" default="0.0"/>
<arg name="initial_pose_a" default="0.0"/>
<arg name="odom_frame_id" default="odom"/>
<arg name="base_frame_id" default="base_footprint"/>
<arg name="global_frame_id" default="map"/>
<arg name="tf_prefix" default="tf_p"/> | {
"domain": "robotics.stackexchange",
"id": 25011,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "navigation, turtlebot, namespaces, amcl, move-base",
"url": null
} |
somy question is: if i toss a coin and get four heads in a row, does the fifth toss has a 50/50 chance of landing heads/tails. If we throw the coin three times, the possible results are: Three heads: 1 way Two heads and one tail: 3 ways Two tails and one head: 3 ways Three tails: 1 way Total: 8 ways So the chances of getting three heads are 1/8 (and the method for calculating this quickly is (1/2)^3). So, if I flip a coin 100 times, is the likeliness of it landing exactly 50 times on either side any greater than it landing all 100 times on the same side? Short, non-numerical answer: yes it is, because there's only two ways for it landing all 100 times on the same side: either it lands heads every single time, or it lands tails every single time. A coin is tossed three times. Probability can be considered as the measurement of the chances of an event to occur. What is the probability of getting two heads and four tails?. Of these, 3 contain two tails: HTT, TTH, and THT and the | {
"domain": "laron-online.de",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9811668706602659,
"lm_q1q2_score": 0.8471312510100645,
"lm_q2_score": 0.863391617003942,
"openwebmath_perplexity": 218.89877272879593,
"openwebmath_score": 0.7882991433143616,
"tags": null,
"url": "http://xkoj.laron-online.de/a-coin-is-tossed-3-times-what-is-the-probability-of-getting-all-tails.html"
} |
ubuntu-trusty, ubuntu, ros-indigo
Originally posted by Stefan Kohlbrecher on ROS Answers with karma: 24361 on 2015-08-12
Post score: 4
As of mid-October Travis supports Ubuntu 14.04 trusty! I've been running travis with ROS indigo without any problems.
To get running in a trusty build environment, you simply have to add the following to your .travis.yml file:
sudo: required
dist: trusty
Originally posted by Felix Duvallet with karma: 539 on 2015-11-02
This answer was ACCEPTED on the original site
Post score: 2 | {
"domain": "robotics.stackexchange",
"id": 22431,
"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
} |
electromagnetism
Title: Is aluminium magnetic? From high school, I remember that Aluminium has 13 electrons and thus has an unpaired electron in the 3p shell. This should make Aluminium magnetic. However, the wiki page of Aluminium says its non-magnetic at one place(with a citation needed tag though) and at another place says it's paramagnetic. Doing a google search shows up some contradictory results. So what is the truth?
Note:The context of the question is this answer on scifi.SE about magneto. It really depends on what you mean by "magnetic," because there are different kinds of magnetic properties. | {
"domain": "physics.stackexchange",
"id": 15169,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "electromagnetism",
"url": null
} |
ros, python, ros-melodic
def Computecubics(param):
pub_coeffs = cubic_traj_coeffs()
pub_param = cubic_traj_param()
m_list1 =pub_coeffs
x = np.array(m_list1)
m_list2 = [[1,(pub_param.t0),(pub_param.t0**2),(pub_param.t0**3)],
[0, 1, (2*pub_param.t0), (3*pub_param.t0**2)],
[1, (pub_param.tf), (pub_param.tf**2), (pub_param.tf**3)],
[0, 1, (2*pub_param.tf), (3*pub_param.tf**2)]]
a = np.array(m_list2)
print(a)
m_list3 = [[pub_param.p0],
[pub_param.v0],
[pub_param.pf],
[pub_param.vf]]
b = np.array(m_list3)
inv_a = np.linalg.inv(a)
x = np.linalg.inv(A).dot(b)
coeffs.publish(x)
rate.sleep()
if __name__ == '__main__':
try: | {
"domain": "robotics.stackexchange",
"id": 36123,
"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, python, ros-melodic",
"url": null
} |
In addition the algorithm stores a variable $L$ representing the length of the longest increasing subsequence found so far.
This algorithm runs in worst-case time $\Theta(n\log n)$. Your problem is a special case that allows you to return when $L=3$ which pushes runtime down to $O(n)$ because the binary search runs only on arrays of length at most two, which is therefore in time $O(1)$ as opposed to $\Theta(\log n)$ in the general case.
Consider the modified pseudo code:
L = 0
for i = 1, 2, ... n:
binary search for the largest positive j ≤ L
such that X[M[j]] < X[i] (or set j = 0 if no such value exists)
P[i] = M[j]
if j == L or X[i] < X[M[j+1]]:
M[j+1] = i
L = max(L, j+1)
if L==3 : return true; // you can break here, and return true.
return false; // because L is smaller than 3. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9715639636617014,
"lm_q1q2_score": 0.8053670804044288,
"lm_q2_score": 0.8289388146603364,
"openwebmath_perplexity": 547.4284099544884,
"openwebmath_score": 0.6154834628105164,
"tags": null,
"url": "https://cs.stackexchange.com/questions/1071/is-there-an-algorithm-which-finds-sorted-subsequences-of-size-three-in-on-ti/1073"
} |
filters, filter-design, poles-zeros, butterworth, bilinear-transform
$$s=2f_s\frac{z-1}{z+1}\tag{2}$$
where $f_s$ is the sampling frequency. Expressing $z$ in terms of $s$ gives
$$z=\frac{2f_s+s}{2f_s-s}\tag{3}$$
Equation $(3)$ can be used to determine the pole locations in the complex $z$-plane. If the cut-off frequency of the analog filter is $\omega_c$, its poles are located at $\omega_cp_k$, with $p_k$ given by $(1)$. So the poles in the complex $z$-plane are given by
$$z_{\infty,k}=\frac{2f_s+\omega_cp_k}{2f_s-\omega_cp_k}\tag{4}$$
You can use $(4)$ to check the pole locations you obtained from Matlab (and I don't doubt that they are identical up to numerical inaccuracies). | {
"domain": "dsp.stackexchange",
"id": 3621,
"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": "filters, filter-design, poles-zeros, butterworth, bilinear-transform",
"url": null
} |
# eigenvalues of certain block matrices | {
"domain": "bootmath.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9854964220125032,
"lm_q1q2_score": 0.8169162275857353,
"lm_q2_score": 0.828938806208442,
"openwebmath_perplexity": 117.98125824214972,
"openwebmath_score": 0.9274455308914185,
"tags": null,
"url": "http://bootmath.com/eigenvalues-of-certain-block-matrices.html"
} |
asteroids
Title: How can we be certain that Ryugu is a remnant of the material that did not form planets? As mentioned here, that Ryugu is a part of the Solar System material that did not get swept into forming a planet.
But how can we be sure that it was not created later for example by an asteroid striking Mars or some other planet? Why do we think its "primordial"? Most of my information is from this link. So here's a watered-down version. | {
"domain": "astronomy.stackexchange",
"id": 3717,
"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": "asteroids",
"url": null
} |
ros, python, moveit, move-group
Originally posted by v4hn with karma: 2950 on 2017-06-08
This answer was ACCEPTED on the original site
Post score: 2
Original comments
Comment by David_111 on 2017-06-08:
if it would only get the orientation right, what does the robot_commander.set_position_target(xyz) do?
Comment by v4hn on 2017-06-08:
It only gets the position right.
The MoveGroupInterface class that is used by the commander has different target modes:
JOINT, POSITION, ORIENTATION, and POSE. When you call a set_*_target method, the active target mode becomes the one you called and the previous mode is overwritten.
Comment by David_111 on 2017-06-11:
Thanks! That should be mentioned in the tutorial...
Comment by v4hn on 2017-06-12:
Could you point out a specific tutorial (we have a lot of them) and in the best case even provide a patch against the github repository? :)
Comment by David_111 on 2017-06-15:
i was referring to this tutorial... What tutorials are you talking about? :) | {
"domain": "robotics.stackexchange",
"id": 28081,
"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, python, moveit, move-group",
"url": null
} |
image-processing, convolution, deconvolution, 3d
Title: How Can Convolution and Deconvolution be Defined for 3D Images? I am trying to understand how convolution and deconvolution can be represented for 3D images/ stacks of data. I would prefer it, if you built the these concepts from 1D vectors to 3D matrices in terms of their equations. I am currently writing a report and am trying to represent 3D deconvolution as an equation.
Please do not hesitate to ask me any questions to clarify this question. For one variable, we have
$$
y(i) = \sum_m x(i-m) \cdot h(m).
$$
For two variables it's
$$
y(i,j) = \sum_m \sum_n x(m,n) \cdot h(i-m,j-n).
$$
For three:
$$
y(i,j,k) = \sum_m \sum_n \sum_p x(m,n,p) \cdot h(i-m,j-n,k-p).
$$ | {
"domain": "dsp.stackexchange",
"id": 3550,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "image-processing, convolution, deconvolution, 3d",
"url": null
} |
ros, rosservice, msg, array, custom-message
Title: Array as response in service
I'm trying to create a service that returns an array of a custom msg. However, when I call this using roservice call /myservice [input params...] I get the following error:
ERROR: service [/myservice] responded with an error: service cannot process request: handler returned wrong number of values: Invalid number of arguments, args should be ['parsed'] args are(operation: travel_to
target: a1
time_step: 0, operation:open ... )
Based on this I assumed that the type I was returning was wrong, so outputted the type just before the return statement in Python, however they seem to be what I expect them to be based on the documentation here
type: type 'list'
element type: class 'asp_model.msg._SubGoal.SubGoal'
.srv file
string goal
string entityA
string entityB
---
Subgoal[] parsed.msg file
string operation
string target
int16 time_step | {
"domain": "robotics.stackexchange",
"id": 20821,
"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, rosservice, msg, array, custom-message",
"url": null
} |
describing a Turing machine,. For example, no person could ever write out every decimal place of pi because it's infinite. This will prove that a two-track Turing machine is equivalent to a standard Turing machine. Turing Machine-based algorithm for basic string operations implementation. 2 Turing Machines. A Turing machine is an abstract device to model computation as rote symbol manipulation. Simple machine with N states. Turing Machine Applet The following Java™ applet animates a Turing Machine that can add or multiply numbers. "Start the Turing Machine operation. Every other "reasonable" model of a computer can be encoded as a TM. State sis the starting state, in state r 0 and r 1 it is moving right and preparing to write a 0 or 1, respec-. The behavior of the mind shows at least two functions - aboutness and qualitative experience - that cannot in principle be reduced to the operations of a Turing machine. Examples of Turing complete languages. The Turing machine's state is | {
"domain": "lotoblu.it",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9643214552744682,
"lm_q1q2_score": 0.8014890674019536,
"lm_q2_score": 0.8311430415844385,
"openwebmath_perplexity": 786.5102890888312,
"openwebmath_score": 0.5172455310821533,
"tags": null,
"url": "http://lotoblu.it/ndgz/turing-machine-example.html"
} |
fluid-dynamics, convection
Now we may model the problem as follows: if a hot fluid of thermal diffusivity $\alpha_{fluid}$ and temperature $T_0$ at its source, is flowing with mean speed $U$ inside a thermally conducting tube, immersed in a static infinite fluid of thermal conductivity $\alpha_{ocean}$ and whose temperature far away from the tube is $T_{ocean}<T_0$, what distance does the fluid inside the tube has to travel, beginning from its source, before its mean temperature becomes equal to that of the ocean, $T_{ocean}?$ | {
"domain": "physics.stackexchange",
"id": 38467,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "fluid-dynamics, convection",
"url": null
} |
quantum-algorithms
Title: Is there an intuition built on ansatz in VQE algorithm or is it more a trial and error approach? Variational Quantum Eigensolver is a popular algorithm in Quantum Computing. But the ansatz part is very tricky. I do not really understand if they are built on some intuition, according to hardware or something else; or if it was just a trial and error approach. | {
"domain": "quantumcomputing.stackexchange",
"id": 344,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "quantum-algorithms",
"url": null
} |
molecular-dynamics
where I think that offsets contains the integers $(n_x,n_y,n_z)$ and I think that cell contains the cell lengths $(L_x,L_y,L_z)$ in the form of a $3\times3$ matrix (just the diagonal elements would be nonzero in this case).
If you are not using such a function to locate neighbours "within range" and pre-calculate the necessary minimum image corrections to the interatomic vectors, you will need to put it into your calculation of pair and three-body energies and forces, somewhere, yourself. As I mentioned, this is not the same as putting the atoms back into the supercell, when they move out.
Caveat! I am not an expert in ase, and if you want specific advice on that package, you should look at the package documentation, and at simple examples of calculators provided within it. Generally speaking, I believe that advice on debugging programs, and on specific packages, is considered off-topic for this site, so I think that's as far as I should go in any case. | {
"domain": "chemistry.stackexchange",
"id": 11116,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "molecular-dynamics",
"url": null
} |
ros-kinetic
Commit Version: 1.5.1-0-g916b5db Build Version: 1.5.7152.31018
For more information, please see http://wiki.ros.org/sw_urdf_exporter -->
<robot
name="base_2links">
<link
name="base_link">
<inertial>
<origin
xyz="-0.016 0.0034506 0.074794"
rpy="0 0 0" />
<mass
value="0.027215" />
<inertia
ixx="2.0815E-06"
ixy="3.1439E-22"
ixz="-2.2393E-22"
iyy="1.2394E-05"
iyz="-1.2756E-22"
izz="1.2544E-05" />
</inertial>
<visual>
<origin
xyz="0 0 0"
rpy="0 0 0" />
<geometry>
<mesh
filename="package://base_2links/meshes/base_link.STL" />
</geometry>
<material
name="">
<color
rgba="0.79216 0.81961 0.93333 1" />
</material>
</visual>
<collision>
<origin
xyz="0 0 0"
rpy="0 0 0" />
<geometry>
<mesh | {
"domain": "robotics.stackexchange",
"id": 35257,
"lm_label": null,
"lm_name": null,
"lm_q1_score": null,
"lm_q1q2_score": null,
"lm_q2_score": null,
"openwebmath_perplexity": null,
"openwebmath_score": null,
"tags": "ros-kinetic",
"url": null
} |
ros, publisher
My subscriber node :
#include "ros/ros.h"
#include "std_msgs/Int16.h"
void sub_call(const std_msgs::Int16::ConstPtr& msg)
{
ROS_INFO("I heard: [%s]", msg->data);
}
int main(int argc, char **argv)
{
ros::init(argc, argv, "my_sub");
ros::NodeHandle n;
ros::Subscriber sub = n.subscribe("my_topic", 1000, sub_call);
ros::spin();
return 0;
}
I am able to build these both. I can run the publisher node and I can see the data being published through
$ rostopic echo /my_topic
The problem is that as soon as I run the subscriber node, it shows
Segmentation fault (core dumped)
and the subscriber node is stopped.
What does this mean?
Originally posted by R.Mehra on ROS Answers with karma: 49 on 2016-09-05
Post score: 0
I think your issue is in the ROS_INFO call inside of your callback. You are trying to print a string value with %s, but your data is an integer value. Try changing the %s to a %d.
This mistake likely throws a compiler warning when you compile your code. Something like | {
"domain": "robotics.stackexchange",
"id": 25677,
"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, publisher",
"url": null
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.