text
stringlengths
1
1.11k
source
dict
time, conventions, history, si-units, metrology Metrologically speaking, the reference year was chosen as 1900, but that does not by itself mean that that definition of the second is explicitly fixing the length of that year in seconds: it's definitely saying that some given year lasted exactly 31,556,925.9747 seconds, by definition of the latter, and my question is what year was that? Did the definition fix that to the year 1900? Or to the year 1956, when it was chosen? Or, as was claimed in the previous question to some ill-defined year in the early 19th century? I would really like answers to provide suitable references, both to modern reviews and to contemporary documents, that support their claims.
{ "domain": "physics.stackexchange", "id": 48395, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "time, conventions, history, si-units, metrology", "url": null }
tensorflow, gpu, generative-models One or more high-end NVIDIA GPUs, NVIDIA drivers, CUDA 10.0 toolkit and cuDNN 7.5. To reproduce the results reported in the paper, you need an NVIDIA GPU with at least 16 GB of DRAM.
{ "domain": "datascience.stackexchange", "id": 7555, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "tensorflow, gpu, generative-models", "url": null }
c#, design-patterns, search, interface public interface ISearchItemConverter<SourceItemType, FinalItemType> { FinalItemType Convert(SourceItemType sourceItem); } And here is one functional abstract class that brings these 3 together: public abstract class SearchProvider<SourceResponseType, SourceItemType, FinalItemType> { protected abstract ISearchClient<SourceResponseType> CreateClient(); protected abstract ISearchResponseParser<SourceResponseType, SourceItemType> CreateParser(); protected abstract ISearchItemConverter<SourceItemType, FinalItemType> CreateConverter(); public virtual IEnumerable<FinalItemType> Search(string query) { ISearchClient<SourceResponseType> searchClient = CreateClient(); SourceResponseType searchResponse = searchClient.ExecuteRemoteSearch(query); ISearchResponseParser<SourceResponseType, SourceItemType> searchResponseParser = CreateParser(); IEnumerable<SourceItemType> searchSourceItems = searchResponseParser.ParseResponse(searchResponse);
{ "domain": "codereview.stackexchange", "id": 17533, "lm_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#, design-patterns, search, interface", "url": null }
only along a streamline and only if the following conditions are met. MAXWELL EQUATIONS 79 which is the reason why the gauge has its name. Boundary layer flow page 4 • To have an overview of the full equations which are pre-programmed in computational-fluid-dynamic codes (as commercial CFD packages). Continuity equation states that the rate at which mass enters a system is equal to the rate at which mass leaves the system. The particles in the fluid move along the same lines in a steady flow. Thus, we need current. 1 General Considerations Of interest is water flowing in a channel with a free surface, which is usually referred to as open channel flow. The Continuity Equation is a restatement of the principle of Conservation of Mass applied to the atmosphere.
{ "domain": "argomentisas.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9711290897113961, "lm_q1q2_score": 0.8092657637192371, "lm_q2_score": 0.8333246035907933, "openwebmath_perplexity": 507.58152442686884, "openwebmath_score": 0.7993223071098328, "tags": null, "url": "http://vsil.argomentisas.it/continuity-equation-derivation.html" }
c#, system.reactive I was originally fixated on .SelectMany(), but instead .Concat() seems to be what I'm looking for. The code works, in that the subscribe no longer blocks and, as far as I can tell, no unacceptable overhead or confusion is produced, but my experience with Rx is limited. Are there any problems with this I'm not seeing, perhaps when you take it out of the toy box (cancellation, multiple subscriptions, thread overhead, etc.)? The accepted answer also mentions using .Generate(): Observable.Generate( getScheduleTimes().GetEnumerator(), e => e.MoveNext(), e => e, e => e.Current, e => e.Current);
{ "domain": "codereview.stackexchange", "id": 11542, "lm_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#, system.reactive", "url": null }
nuclear-physics, absorption, x-rays, applied-physics, medical-physics Once you have a projection of the attenuation from each direction, then you can use the Radon Transform to calculate the attenuation at each point in the slice. Tissues which "shadow" each other in one projection will not shadow each other in a different projection and can thus be distinguished.
{ "domain": "physics.stackexchange", "id": 93314, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "nuclear-physics, absorption, x-rays, applied-physics, medical-physics", "url": null }
ros It's hard to say why: cannot corellate rviz and sim images on https://www.dropbox.com/s/4bxzlid7e25mwuu/obstacle_remain.png. Can you add laser visualisation in rviz? cells.size() has int type. Try use ROS_INFO("size: [%d]", msg->cells.size()); Not %f.
{ "domain": "robotics.stackexchange", "id": 17572, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros", "url": null }
physical-chemistry, molecular-structure, molecular-dynamics Given all that, your first choice of models may be suitable. However, you need to choose a temperature which is high enough for both the phases to be liquid. You haven't done this! The triple point temperature of 2D Lennard-Jones is $k_BT/\epsilon\approx 0.4$. At your temperature of $0.1$, the Lennard-Jones atoms will be trying to crystallize; in practice they will get "stuck" in irregular semi-crystalline semi-amorphous clumps. Nonetheless, if you raise the temperature above $0.4$, you might see liquid-liquid coexistence for this system. I can't be sure, and you may need to experiment.
{ "domain": "chemistry.stackexchange", "id": 10904, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "physical-chemistry, molecular-structure, molecular-dynamics", "url": null }
quantum-mechanics, condensed-matter, many-body, metals, insulators The enormous amount of theoretical work stimulated by the cuprate discovery has now built up a strong case that the Mott insulator does not exist as a distinct zero-temperature state of matter. Laughlin says similar things in Phys. Rev. Lett. 112, 017004 (2014)
{ "domain": "physics.stackexchange", "id": 90865, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, condensed-matter, many-body, metals, insulators", "url": null }
ros Title: Catkin_make Error: "No rule to make target /usr/lib/libcxsparse.so.2.2.3', needed by /home/zarneel/rgbdslam_catkin_ws/devel /lib/rgbdslam/rgbdslam'." Can any one solve this issue? Base path: /home/zarneel/rgbdslam_catkin_ws Source space: /home/zarneel/rgbdslam_catkin_ws/src Build space: /home/zarneel/rgbdslam_catkin_ws/build Devel space: /home/zarneel/rgbdslam_catkin_ws/devel Install space: /home/zarneel/rgbdslam_catkin_ws/install Running command: "make cmake_check_build_system" in "/home/zarneel/rgbdslam_catkin_ws/build" Running command: "make -j4 -l4" in "/home/zarneel/rgbdslam_catkin_ws/build" [ 0%] [ 0%] [ 0%] [ 0%] Built target _rgbdslam_generate_messages_check_deps_rgbdslam_ros_ui_f Built target _rgbdslam_generate_messages_check_deps_rgbdslam_ros_ui_b Built target _rgbdslam_generate_messages_check_deps_rgbdslam_ros_ui_s Built target _rgbdslam_generate_messages_check_deps_rgbdslam_ros_ui [ 13%] Built target siftgpu_proj
{ "domain": "robotics.stackexchange", "id": 21462, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros", "url": null }
deep-learning, tensorflow Why is my validation accuracy increasing while my validation loss is going up? Should I use a loss metric diferent to cross_entropy? It is possible that accuracy and cross entropy increase at the same. For example, for a positive sample your predicted probability could go from 0.4 to 0.1 (still wrong but worse increasing the entropy loss) and for another positive sample your predicted probability could change from 0.49 to 0.51 (changes from wrong to right improving accuracy). The first case would increase your entropy loss while the second would improve accuracy without significantly changing the entropy loss.
{ "domain": "datascience.stackexchange", "id": 6812, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "deep-learning, tensorflow", "url": null }
java, xml @Override public String toString() { return BoundingBox.class.getSimpleName() + "(" + x1 + ", " + y1 + ", " + x2 + ", " + y2 + ")"; } @Override public int hashCode() { int hash = 7; hash = 89 * hash + this.x1; hash = 89 * hash + this.y1; hash = 89 * hash + this.x2; hash = 89 * hash + this.y2; return hash; } @Override public boolean equals(Object obj) { if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final BoundingBox other = (BoundingBox) obj; if (this.x1 != other.x1) { return false; } if (this.y1 != other.y1) { return false; } if (this.x2 != other.x2) { return false; } if (this.y2 != other.y2) { return false; } return true; } }
{ "domain": "codereview.stackexchange", "id": 7336, "lm_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, xml", "url": null }
r, statistics Coefficients: (1 not defined because of singularities) Estimate Std. Error z value Pr(>|z|) (Intercept) -2.853e+00 5.774e-01 -4.941 7.78e-07 *** originisolate 4.700e-01 7.071e-01 0.665 0.50625 variableRB17 2.877e-01 5.401e-01 0.533 0.59425 variableM56 1.299e+00 4.606e-01 2.821 0.00479 ** variableRB68 -6.269e-14 5.774e-01 0.000 1.00000 variableM39b4 -1.010e-13 5.774e-01 0.000 1.00000 variableRB108 1.542e-01 5.563e-01 0.277 0.78172
{ "domain": "bioinformatics.stackexchange", "id": 1478, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "r, statistics", "url": null }
object-oriented, game, objective-c, simulation #pragma mark - Skill Increases -(void) skillUpMining { _miningSkill++; } -(void) skillUpBuilding { _buildingSkill++; } -(void) skillUpWorkRoom { _workRoomSkill++; } -(void) skillUpFighting { _fightingSkill++; } -(void) skillUpCleaning { _cleaningSkill++; } -(void) skillUpHauling { _haulingSkill++; }
{ "domain": "codereview.stackexchange", "id": 8174, "lm_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, game, objective-c, simulation", "url": null }
operations is proportional to NlogN • Second, it allows us to characterize convolution operations in terms of changes to different frequencies - For example, convolution with a Gaussian will preserve low-frequency components while reducing. Multiplication of two DFTs and Circular Convolution. Fourier Transform and Linear Time-Invariant System Recall in a linear time-invariant () system, the inputLTI - output relationship is characterized by convolution in (3. In practice, the convolution of a signal and an impulse response , in which both and are more than a hundred or so samples long, is typically implemented fastest using FFT convolution (i. Interpolation as Convolution • Any discrete set of samples can be considered as a functional • Any linear interpolant can be considered as a convolution –Nearest neighbor - rect(t) –Linear - tri(t). Signal Processing Toolbox™ provides functions that let you compute correlation, convolution, and transforms of signals. When we perform linear
{ "domain": "coopruah.it", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9838471680195556, "lm_q1q2_score": 0.82822778291892, "lm_q2_score": 0.8418256512199033, "openwebmath_perplexity": 860.205398522123, "openwebmath_score": 0.8229966163635254, "tags": null, "url": "http://coopruah.it/baax/linear-convolution-using-dft-examples.html" }
ornithology, reptile, cladistics Exploring the tree of life by yourself You will find the tree of life on tolweb.org or on onezoom.org (see The best free and most up to date phylogenetic tree on the internet? for more info). Using tolweb.org: here are the roots of the tree of the Amniota. And you will probably want to search for the Dinosauria (there) and see how closely related they are to the birds but not so much to the turtles. Addressing your question directly
{ "domain": "biology.stackexchange", "id": 8826, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ornithology, reptile, cladistics", "url": null }
programming, stabilizer-state, stim where last_entry is the index of the last measurement (respectively of MPP X1Z3 for PsiPlus and MPP !X1Z3 for PsiMinus) should be the required value $\langle O\rangle$. Problems There are problems with the above approach/ideas/implementation. It works if the measurement is deterministic, but it in general it doesn't for non-deterministic measurements (which is the main issue to solve). I think the reason is, since both states refer to the same random generator, the randomness in PsiPlus and PsiMinus are inequivalent, leading to different results (e.g. different internally drawn random numbers). Furthermore, the operations required can be probably reduced. Lastly, I conclude with a remark.
{ "domain": "quantumcomputing.stackexchange", "id": 3188, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "programming, stabilizer-state, stim", "url": null }
4(13C3)3(13C2) since the total number of 5 card hands is 52C5 the probability where the 5 are from 2 suits is [4(13C4)39 + 4(13C3)3(13C2)]/52C5 is this correct? 2. May 15, 2015 ### Orodruin Staff Emeritus At face value, the method looks correct. However, I would do it slightly different and you should end up with the same result. 1. Take the number of combinations where you draw five cards out of 26. 2. Remove two times the number of combinations where you draw five cards out of 13. These are the ones where you only draw from one suite, given that you are drawing from two suites. 3. Multiply this number by the number of ways of selecting two out of four suites. 4. Divide by 52C5. 3. May 15, 2015 ### Zondrina I'll tell you one thing, there's more to poker than just math :P. 4. May 15, 2015 ### Ray Vickson Yes, it matches what I get.
{ "domain": "physicsforums.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9840936059556499, "lm_q1q2_score": 0.8242964461480761, "lm_q2_score": 0.8376199592797929, "openwebmath_perplexity": 471.122053125798, "openwebmath_score": 0.605004608631134, "tags": null, "url": "https://www.physicsforums.com/threads/probability-of-a-poker-hand.813949/" }
## Definition and properties In the following formulas, x and y are real numbers, k, m, and n are integers, and $\mathbb{Z}$ is the set of integers (positive, negative, and zero). Floor and ceiling may be defined by the set equations $\lfloor x \rfloor=\max\, \{m\in\mathbb{Z}\mid m\le x\},$ $\lceil x \rceil=\min\,\{n\in\mathbb{Z}\mid n\ge x\}.$ Since there is exactly one integer in a half-open interval of length one, for any real x there are unique integers m and n satisfying $x-1 Then  $\lfloor x \rfloor = m\;$  and  $\;\lceil x \rceil = n\;$  may also be taken as the definition of floor and ceiling. ### Equivalences These formulas can be used to simplify expressions involving floors and ceilings.[12]
{ "domain": "wikipedia.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9944450741438985, "lm_q1q2_score": 0.8035784554982278, "lm_q2_score": 0.8080672089305841, "openwebmath_perplexity": 4164.757721247511, "openwebmath_score": 0.9321497678756714, "tags": null, "url": "https://en.wikipedia.org/wiki/Floor_and_ceiling_functions" }
homework-and-exercises, newtonian-mechanics, acceleration, friction The car is in a circular motion where the circle is on the paper plane. From the question it seems that the car is moving at a constant speed. This means that the acceleration of this circular motion is in the direction of the radius, that is fully vertical at the hill peak. This means there is no horizontal acceleration at all. Therefore the question makes no sense to me. The solution is given as: $1.8 \;\text{m}\,\text{s}^{-2}$ As the car drives over the hill, the bottom of the tires does not slip. If the car accelerates, the tires push the road backward, and the reaction force pushes the car forward. This is a question about how big can static friction be. For that, you need to know about is the normal force pushing the car onto the road.
{ "domain": "physics.stackexchange", "id": 81088, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "homework-and-exercises, newtonian-mechanics, acceleration, friction", "url": null }
ros, ros-kinetic, python3 Title: roscore on python2.7 'ascii' codec can't decode byte 0xe6 in position 16 Hey, When I set python3.5 as default, I got a error. So, I corrected it to python2.7, However, roscore gave me a Error like this ~$ roscore ... logging to /home/wuxueming/.ros/log/67c4edca-e9fb-11e8-a50a-7c2a314f2b58/roslaunch-wuxueming-n8xejek-28640.log Checking log directory for disk usage. This may take awhile. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB. started roslaunch server http://wuxueming-n8xejek:37377/ ros_comm version 1.12.14 SUMMARY ======== PARAMETERS * /rosdistro: kinetic * /rosversion: 1.12.14 NODES auto-starting new master process[master]: started with pid [28650] ROS_MASTER_URI=http://wuxueming-n8xejek:11311/ setting /run_id to 67c4edca-e9fb-11e8-a50a-7c2a314f2b58 'ascii' codec can't decode byte 0xe6 in position 16: ordinal not in range(128) The traceback for the exception was written to the log file [master] killing on exit
{ "domain": "robotics.stackexchange", "id": 32059, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros, ros-kinetic, python3", "url": null }
quantum-mechanics, quantum-entanglement, density-operator, trace $$\rho_\alpha = Tr_\beta(\rho) = \sum_{j,k}(\sum_{l} \rho_{j,l,k,l}) |\alpha_j\rangle \langle\alpha_k| $$ My main question is how would one write out $\rho_{j,l,k,l}$ and $\rho_{j,l,j,m}$ explcitly as what I get do not seem to agree with a worked example in my book and so I am quite confused. Thanks Well because if I were to do it myself I would write it as follows: $\rho_{jlkl} =\langle \alpha_j|\langle \beta_l| \rho |\alpha_k\rangle |\beta_l\rangle $ However I am unsure because the worked examples I have seen suggest the following $\rho_{jlkl} =\langle \alpha_j|\langle \beta_l| \rho |\beta_l\rangle |\alpha_k\rangle $.
{ "domain": "physics.stackexchange", "id": 73550, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, quantum-entanglement, density-operator, trace", "url": null }
fault-tolerance The state after preparation, before verification is $\frac{1}{\sqrt{2}}\left(\left|000\right>+\left|111\right>\right)\left|0\right>$ After the first CNOT on the extra qubit: $\frac{1}{\sqrt{2}}\left(\left|000\right>\left|0\right>+\left|111\right>\left|1\right>\right)$ After the second CNOT: $\frac{1}{\sqrt{2}}\left(\left|000\right>+\left|111\right>\right)\left|0\right>$ The extra qubit is now measured and returns $0$, showing no bit flip has occurred. There is a possibility, with probability $\mathcal O\left(p^2\right)$ of two bit flips occurring, where the probability of a single error is $p$.
{ "domain": "quantumcomputing.stackexchange", "id": 124, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "fault-tolerance", "url": null }
acoustics, resonance Calculation of mouthpiece cavity connected to the tube does not make the solutions any easier and it must be taken in account If you want a cent-precision then the speed of sound must be considered temperature dependent which gives us an additional parameter. Without perfect knowledge of driving signal you wouldn't be sure that the eigenfrequency is the exact sounding frequency (usually they slightly differ). You need to choose a reference frequency to get an absolute pitch in tones and cents. But there are multiple possible reference frequencies. Nevertheless: you can achieve some sort of estimation by asking the question: How would a change of length affect a change of pitch? That would lead to some simple formulas but you can't expect that to be cent-precise.
{ "domain": "physics.stackexchange", "id": 38607, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "acoustics, resonance", "url": null }
php, mysql /* Helper function - Set the array of active_day, to currently active, active_time */ private function process_whole_day(){ if((isset($this->active_day)) && (!isset($this->active_time))){ $this->active_time = $this->active_day; return true; } else{ return false; } } } I'd consider: breaking it into smaller object (e.g. extract counters) do not hardcode the dblink connection + settings (e.g. pass the object in the constructor) use phpdoc comments correct formatting Try to write unit test for this class, you'll spot all the drawbacks quickly.
{ "domain": "codereview.stackexchange", "id": 529, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "php, mysql", "url": null }
c++, array, iterator, c++20 RowsIterator operator++(int) { auto self = *this; ++* this; return *this; } friend bool operator==(RowsIterator lhs, RowsIterator rhs) { return lhs._it == rhs._it; } friend bool operator!=(RowsIterator lhs, RowsIterator rhs) { return lhs._it != rhs._it; } RowIterator begin() const { return _row_begin; } RowIterator end() const { return _row_end; } }; struct GridRows { RowsIterator _begin, _end; GridRows(int* begin, int* end, int row_length) : _begin{ begin, row_length }, _end{ end, row_length } {} RowsIterator begin() { return _begin; } RowsIterator end() { return _end; } }; struct Grid { Grid(int width, int height) : _width{ width }, _height{ height } { size_t size = width * height; _begin = new int[size]; _end = _begin + size; InitializeValues(); }
{ "domain": "codereview.stackexchange", "id": 42422, "lm_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++, array, iterator, c++20", "url": null }
angles in a linear pair are supplementary. In other words, when put together, the two angles form a right angle. So, In a linear pair, there are two angles who have. Two adjacent supplementary angles form a linear pair. Two angles make a linear pair if their non-common arms are two opposite rays. Non-common side makes a straight line or Sum of angles is 180°. Two angles in the same plane and with a common vertex and a common arm are called adjacent angles. (iv) Adjacent angles which are not in a linear pair (v) Angles which are neither complementary (vi) Angles in a linear pair which are nor adjacent. Since the non-adjacent sides of a linear pair form a line, a linear pair of angles is always supplementary. A polygon showing its interior angles, and a label pointing to two that are adjacent to another use of the term refers to the interior angles of polygons. Adjacent angles must be next to each other, not one on top of the other. Angles A and B are adjacent. Draw a pair of vertically
{ "domain": "cathedralbaptist.com", "id": null, "lm_label": "1. Yes\n2. Yes\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9518632261523028, "lm_q1q2_score": 0.8488821429343587, "lm_q2_score": 0.8918110497511051, "openwebmath_perplexity": 563.3978358630858, "openwebmath_score": 0.5357616543769836, "tags": null, "url": "https://cathedralbaptist.com/7eujzh/qzuio6q.php?157bfb=adjacent-angles-which-are-not-in-a-linear-pair" }
general-relativity, black-holes, resource-recommendations, computational-physics, simulations Pretorius (2005). "Evolution of Binary Black Hole Spacetimes" Campanelli, et al (2006). "Accurate Evolutions of Orbiting Black-Hole Binaries Without Excision" Baker, et al (2006). "Gravitational wave extraction from an inspiraling configuration of merging black holes" The three papers are short. But they are challenging to read unless you are familiar with some technical GR (the ADM formalism in particular) and numerical methods for solving PDEs (like adaptive mesh refinement).
{ "domain": "physics.stackexchange", "id": 99859, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "general-relativity, black-holes, resource-recommendations, computational-physics, simulations", "url": null }
general-relativity, black-holes, differential-geometry, coordinate-systems Title: Schwarzschild metric: Change in coordinates corresponds to change in object? I have been reading about the Schwarzschild metric in the book "General Relativity: An Introduction for Physicists" by Hobson, Efstathiou and Lasenby and it appears to say something counter intuitive. This is how I have interpreted it: Take the Schwarzschild metric (it's exact form is not important for my question) if we write it in terms of 'Schwarzschild coordinates' then we get an object where no light ray can pass the event horizon (do such objects even exist?). If we use 'advanced Eddington-Finkelstein coordinates' then we get a black hole. And if we use 'retarded Eddington-Finkelstein coordinates' then we get a white hole.
{ "domain": "physics.stackexchange", "id": 46545, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "general-relativity, black-holes, differential-geometry, coordinate-systems", "url": null }
java, linked-list // delete node at the beginning of the list public void removeElement(){ removeElementAtIndex(0); }
{ "domain": "codereview.stackexchange", "id": 24091, "lm_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, linked-list", "url": null }
homework-and-exercises, particle-physics, nuclear-physics, quarks, elementary-particles [BP11] H. Burkhardt and B. Pietrzyk. Recent bes measurements and the hadronic contribution to the qed vacuum polarization. Phys. Rev. D, 84:037502, Aug 2011.
{ "domain": "physics.stackexchange", "id": 42954, "lm_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, particle-physics, nuclear-physics, quarks, elementary-particles", "url": null }
programming, qiskit, quantum-state, unitarity Title: How do I get the Unitary matrix of a circuit without using the 'unitary_simulator'? I am using jupyter notebook and qiskit. I have a simple quantum circuit and I want to know how to get the unitary matrix of the circuit without using 'get_unitary' from the Aer unitary_simulator. i.e.:By just using matrix manipulation, how do I get the unitary matrix of the circuit below by just using numpy and normal matrix properties?
{ "domain": "quantumcomputing.stackexchange", "id": 3274, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "programming, qiskit, quantum-state, unitarity", "url": null }
For six by six it is quite easy. Call the colours red and blue. Look at the top row. There will be three points the same colour - say red. Concentrate on those columns. If in any row below there are two out of three points red you have a rectangle. But there are only four possible patterns of three points with at most one red, so two of the five rows must have the same pattern and there will be a blue rectangle. Since one of the possible patterns of three with at most one red is all blue, and if this is present there will be a blue rectangle anyway, this can be adapted to five by five (which must have three the same in the top row). Can you find a four by four arrangement with no rectangle? • Thank you very much for your answer. I have found such a four by four arrangement. – michaelhowes Jun 5 '17 at 12:34
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.986777179414275, "lm_q1q2_score": 0.8723497813958908, "lm_q2_score": 0.8840392741081575, "openwebmath_perplexity": 187.22312882671133, "openwebmath_score": 0.505984365940094, "tags": null, "url": "https://math.stackexchange.com/questions/2310558/two-colouring-of-a-6-by-6-grid-without-a-monochromatic-rectangle" }
continuum-mechanics $$S_{ij} = \lambda (E_{kk}) \delta_{ij} + \nu_1 E_{ij} + \nu_2 E_{ji}$$ $$S_{ij} = \lambda (E_{kk}) \delta_{ij} + 2 \mu E_{ij}$$ Or, in index-free notation, $$S = \lambda\ \text{tr}E\ I + 2 \mu E$$ Instead of making the assertion that $C$ is isotropic after deriving a general expression for $S$, you can simply take the statement that the Saint Venant-Kirchhoff model for the strain energy density is accurate based on empirical modeling and then derive an expression for $S$ from that. If so, consider the strain-energy density function for the Saint Venant-Kirchhoff model in index notation, which you can either take as a postulate or can be derived from the general expression for $W$ above but substituting in the isotropic form of $C$: $$W(E_{ij}) = \frac{\lambda}{2} (E_{kk})^2 + \mu (E_{lm}E_{ml})$$ The second Piola-Kirchhoff stress tensor $S_{ij}$ is equal to the partial derivative of $W$ with respect to $E_{ij}$: $$S_{ij} = \frac{\partial W}{\partial E_{ij}}$$
{ "domain": "physics.stackexchange", "id": 86122, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "continuum-mechanics", "url": null }
geology, mineralogy, minerals, economic-geology Some thoughts about what this means for your app: Generating random questions from SQL queries will not, by itself, produce a fair or useful quiz. Maybe you should add a field like 'knowledge level' with values like 'beginner' and 'expert' to your database. Then you can ask beginners about quartz and gold, and experts about aegerine and spessartine. Use fields like TYPE to form simplified super-groups, like 'silicates'. Then, for instance, you can ask about silicates vs non-silicates early on, and narrow down to different families of silicates later on, or in a harder quiz. Knowing a few formulas, or looking for SiO2 in a silicate, is a reasonable expectation. So you could ask about forumlas, but only when the formula is less than a few characters long (say).
{ "domain": "earthscience.stackexchange", "id": 2364, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "geology, mineralogy, minerals, economic-geology", "url": null }
time, navigation those minutes is local apparent noon. Pick the most likely middle. Continuing, you'll use the observed altitude to find the time of year. You know where you are. Most of the Western Australia airports in 1962 should have been near Perth. If that's so, the Sun will always be in your north sky. You can calculate a pair of days when the Sun would be at the altitudes you observed with the formula D = 365.25 arcsin(a/23.44), where D is the number of days since the vernal equinox, and a is the observed altitude of the Sun at local apparent noon, corrected for latitude, in degrees. Use 16.2 arc minutes for the semidiameter correction. Take readings for several days, long enough to see whether the trend is increasing or decreasing altitude. If it's decreasing the day is in summer or fall - increasing, winter or spring, using Australian naming of the seasons. Considering that the arcsine function is double valued you'll have two values for D. You can pick the right one knowing the season.
{ "domain": "astronomy.stackexchange", "id": 6541, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "time, navigation", "url": null }
Putting it all together, we find that $x^2+x-1$ has a root mod $n$ iff every prime factor of $n$ is $0,1,$ or $4$ mod $5$ and $25$ does not divide $n$. As lab bhattacharjee wrote (working $\bmod n$), If $m(m+1) = 1$ then $4m^2+4m=4$ or $5 =4m^2+4m+1 =(2m+1)^2$. Therefore, if $5$ is a quadratic residue mod $n$, there is (at least) one solution. According to https://en.wikipedia.org/wiki/Quadratic_residue, for a prime $p$, $5$ is a quadratic residue mod $p$ if and only if $p \equiv 1, 4 (\bmod 5)$. For composite $n$, see https://en.wikipedia.org/wiki/Jacobi_symbol. The table there titled "Table of values" shows which $k$ have $5$ as a quadratic residue. Clearly, the condition $x(x+1)\equiv1\pmod{n}$ cannot hold if $n$ is even (because $x(x+1)$ is itself even). Now suppose $n$ is odd. The OP can be reformulated as follows : find the integers $n\ge2$ such that the equation $x^2+x-\bar{1}=\bar{0}$ has at least a solution in the ring $\mathbb{Z}/n\mathbb{Z}$.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9881308807013052, "lm_q1q2_score": 0.8032193053874663, "lm_q2_score": 0.8128673246376009, "openwebmath_perplexity": 105.77405313073334, "openwebmath_score": 0.9496329426765442, "tags": null, "url": "https://math.stackexchange.com/questions/2141949/is-the-product-of-two-consecutive-integers-1-pmod-n" }
quantum-state Title: Can I call $\{|0\rangle, |1\rangle\}$ the "standard computational basis" as it is done in linear algebra? $\newcommand{\ket}[1]{|#1\rangle}$Is there some standard computational basis defined in quantum computing? Can I just call $\{\ket{0}, \ket{1}\}$ the standard computational basis? You can either call it the standard basis (as it can be mapped to the natural orthonormal basis of $\Bbb R^2$) or the computational basis, of the $2$-dimensional complex Hilbert space. The latter is more frequently used in the context of quantum computing, but you'll see mathematicians using the former more. Anyway, calling it the "standard computational" basis is simply redundant when you're dealing with $\Bbb C^2$, although I've seen some authors use it. For instance, check page 5 of From Qubits to Continuous-Variable Quantum Computation (Sanders et al., 2002). Related: What is the Computational Basis?
{ "domain": "quantumcomputing.stackexchange", "id": 591, "lm_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-state", "url": null }
triangles are better looking than all the other triangles. All rights reserved. 45, 45, 90 Special Right Triangle. The measures of the interior angles of a triangle add up to . To find the third angle of an acute triangle, add the other two sides and then subtract the sum from 180°. If a leg and an acute angle of one right triangle are congruent to the corresponding parts of another right triangle, then the two right triangles are congruent. Click Create Assignment to assign this modality to your LMS. In an acute triangle, the line drawn from the base of the triangle to the opposite vertex is always, If two angles of an acute-angled triangle are 85. When the lengths of the sides of a triangle are known, the Pythagorean Theorem can be used to determine whether or not the triangle is an acute triangle. The formula is $a^2+b^2=c^2$. Each formula has calculator All geometry formulas for any triangles - Calculator Online Formulas. Examples Obtuse triangles According to the sides of the
{ "domain": "dongfangoil.cn", "id": null, "lm_label": "1. Yes\n2. Yes", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9793540704659681, "lm_q1q2_score": 0.8400586797966253, "lm_q2_score": 0.8577680995361899, "openwebmath_perplexity": 598.0191804546618, "openwebmath_score": 0.5076112151145935, "tags": null, "url": "http://www.dongfangoil.cn/e5ejzg17/59c66c-acute-triangle-formula" }
You will now practice evaluating a model with tuned hyperparameters on a hold-out set. That's it for now. L1 regularizer minimizes the sum of absolute values of the. Mathematical formula for L1 Regularization. Objectives and metrics. It has a wonderful API that can get your model up an running with just a few lines of code in python. This ratio controls the proportion of L2 in the mix. 7 Summary of Regularization; 9 Training Neural Networks Part 3. Output of above code will be: {'alpha': 1. UGMlearn - Matlab code for structure learning in discrete-state undirected graphical models (Markov Random Fields and Conditional Random Fields) using Group L1-regularization. We will focus here on ridge regression with some notes on the background theory and mathematical derivations that are useful to understand the concepts. The latex sample document shows how to display Python code in a latex document. In the earlier article "MultiClass Logistic Regression in Python" the optimum parameters of the
{ "domain": "danieledivittorio.it", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9732407137099623, "lm_q1q2_score": 0.8172632938308176, "lm_q2_score": 0.8397339756938818, "openwebmath_perplexity": 1414.7315024686475, "openwebmath_score": 0.5768205523490906, "tags": null, "url": "http://mibx.danieledivittorio.it/l1-regularization-python-code.html" }
I personally think this problem is easier to approach from a slightly more brute-force angle. How many of the $$a_i$$ are below $$105$$? How many of them are between $$105$$ and $$210$$? How many are between $$210$$ and $$315$$? How many multiples of $$105$$ do you have to go before you have (close to) $$1000$$ terms? From there it's basically trial and error. Alternate solution, taken from the comments above. The left-hand side of your equation is roughly linear. So you can do a linear regression from basically any two $$n$$-values to find the solution to your equation. For instance, inserting $$n = 1$$ and $$n = 11$$ gives $$1$$ and $$5$$ respectively.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9755769127862449, "lm_q1q2_score": 0.8043260145325773, "lm_q2_score": 0.8244619199068831, "openwebmath_perplexity": 135.5843384160907, "openwebmath_score": 0.8570600748062134, "tags": null, "url": "https://math.stackexchange.com/questions/3375415/find-the-thousandth-number-in-the-sequence-of-numbers-relatively-prime-to-105" }
electrostatics \begin{equation}\tag{22}\label{e22} \iint_S Y_m\frac{\partial}{\partial\theta}\left(\sin\theta\frac{\partial Y_n}{\partial\theta}\right)d\theta d\phi + \iint_S\frac{Y_m}{\sin\theta}\frac{\partial^2 Y_n}{\partial\phi^2}d\theta d\phi = -n(n+1)\iint_S Y_m Y_n \sin\theta d\theta d\phi. \end{equation} The first integral in the above equation can be expressed as $$ \int_0^{2\pi}\left(Y_m \sin\theta\frac{\partial Y_n}{d\theta}\Big|_0^{\pi} - \int_0^\pi \sin\theta \frac{\partial Y_n}{\partial\theta}\frac{\partial Y_m}{\partial\theta}d\theta\right)d\phi = -\iint_S \frac{\partial Y_m}{\partial\theta}\frac{\partial Y_n}{\partial\theta}\sin\theta d\theta d\phi. $$ Similarly, the second integral can be simplified to $$ \int_0^\pi\frac{1}{\sin\theta}\left(Y_m\frac{\partial Y_n}{\partial\phi}\Big|_0^{2\pi} - \int_0^{2\pi}\frac{\partial Y_n}{\partial\phi}\frac{\partial Y_m}{\partial\phi}d\phi\right)d\theta =
{ "domain": "physics.stackexchange", "id": 61036, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "electrostatics", "url": null }
quantum-field-theory, greens-functions =i\int_0^\infty dt e^{itE}\langle \phi(0)e^{-itH}\phi(0)\rangle\\ =\Big\langle\phi(0)\int_0^\infty dt ie^{it(E-H)}\phi(0)\Big\rangle =\langle \phi(0)(E-H)^{-1}\phi(0)\rangle =\psi^*(E-H)^{-1}\psi,$$ where $\psi=\phi(0)|vac\rangle$, since the vacuum absorbs the other exponential factors. The spectral theorem for the self-adjoint operator $H$ guarantees a spectral decomposition $\psi=\int d\mu(E')\psi(E')$ into proper or improper eigenvectors $\psi(E')$ of $H$ with eigenvalus $E'$, where $d\mu$ is the spectral measure of $H$. Orthogonality of the eigenvectors gives $$G(E)=\psi^*(E-H)^{-1}\psi =\int d\mu(E')\psi(E')^*(E-E')^{-1}\psi(E') =\int d\mu(E')\frac{|\psi(E')|^2}{E-E'}.$$ Therefore $$(1)~~~~~~~~~~~~~~~~~~~~~~~~~~G(E)=\int\frac{d\rho(E')}{E-E'},$$
{ "domain": "physics.stackexchange", "id": 36539, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-field-theory, greens-functions", "url": null }
neural-networks, machine-learning, gradient-descent Finally when you are dealing with Deep Neural Nets like CNN if you do not normalise pixels it will result in exponentially large/vanishing gradients. Since generally softmax/sigmoid is used in the last layer, it squashes the outputs. If you have a large output, generally due to un-normalized data, it'll result in wither exact 0 or exact 1 output, which is fed into a log function and BAM! overflow. The error becomes inf or NaN in python. So inf error means exploding gradients and NaN means gradient cannot be calculated. This can probably be remedied by using higher floating point precision but it will result in higher memory and processor consumption ultimately inefficiency.
{ "domain": "ai.stackexchange", "id": 574, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "neural-networks, machine-learning, gradient-descent", "url": null }
In [2]: figure(figsize=(6,5)) yh,bh,p=hist(xr,bins=arange(xmin,1000,.1),log=True,histtype='step') xlabel('x') ylabel('# occurrences in bin of size .1') ylim(.5,300),xlim(1,200) xscale('log'); An obvious way to try to fit a power law to this data is to use the linregress() function, as described in lec19, applied to the log-log data (where we're careful only to use the bins with non-zero counts): In [3]: from scipy.stats import linregress slope, intercept, r_value, p_value, std_err = linregress(log(bh[yh>0]),log(yh[yh>0])) print slope,intercept figure(figsize=(6,5)) yh,bh,p=hist(xr,bins=arange(xmin,1000,.1),log=True,histtype='step') xlabel('x') ylabel('# occurrences in bin of size .1') ylim(.5,300),xlim(1,200) xscale('log') xl=arange(1,200,.1) plot(xl,exp(intercept)*xl**(slope),'k-',linewidth=2,label='$\\alpha={:.2f}$'.format(-slope)) legend(); -1.27505386327 3.51358457684
{ "domain": "ipython.org", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9811668662546613, "lm_q1q2_score": 0.8259714302998238, "lm_q2_score": 0.8418256452674008, "openwebmath_perplexity": 532.9284885184187, "openwebmath_score": 0.9162138104438782, "tags": null, "url": "https://nbviewer.ipython.org/url/courses.cit.cornell.edu/info2950_2016sp/resources/power_law_fit.ipynb" }
quantum-mechanics, quantum-field-theory, wavefunction, wave-particle-duality, wavefunction-collapse So "collapse" which by the way is a misleading term in describing wavefunctions, means a change in the wavefunction as interactions happen. Take this first order in the expansion Feynman diagram, for electron electron scattering
{ "domain": "physics.stackexchange", "id": 63797, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-mechanics, quantum-field-theory, wavefunction, wave-particle-duality, wavefunction-collapse", "url": null }
$$\int_0^1 \left(x-\left(\frac{1}{x+\phi-1}-\phi+1\right)\right)^{2016} dx \approx 0.0003587$$ So unless there were extra conditions to problem, it is inherently flawed and has no answer. • With appropriate precision I get $0.0004957858205$ for your last integral, which is approximately $1/2017$. – Michael Hoppe Nov 5 '19 at 15:31 • @MichaelHoppe I don't see how additional precision could ever change the leading digits of a computation, so unless the three numerical integration methods I tried are all wrong for agreeing with each other, I would suggest you check your computation again, it doesn't seem trustworthy. Perhaps post it so it can be verified? The first integration solver I used was NIntegrate on Mathematica – Ninad Munshi Nov 5 '19 at 23:58 • I think the guess by @MichaelHoppe is correct, so I agree that there is some computational precision issue in your second integral. Check my answer if you like. – dfnu Nov 6 '19 at 1:21 There are two things to note here.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.982013792143467, "lm_q1q2_score": 0.8204563525217078, "lm_q2_score": 0.8354835330070838, "openwebmath_perplexity": 449.8846562669473, "openwebmath_score": 0.8334750533103943, "tags": null, "url": "https://math.stackexchange.com/questions/3422890/on-the-derivative-of-a-function-that-is-its-own-inverse" }
electromagnetism, classical-electrodynamics, maxwell-equations, electromagnetic-induction If we assume there is no charge present, then the divergence of $\vec{E}$ must be zero and therefore $E_r = 0$ and so $$E_{\phi} = -\frac{R}{2} B_0 \cos(t) + {\rm const}$$ OK, so Faraday's law tells us that a time-varying E-field coexists with the time-varying B-field, but Ampere's law tells us that the E-field is time-independent. What could be wrong? Well, you have to make assumptions to arrive at this solution. We assumed that there is no charge present and we assumed there are no currents present. I think what you have shown is that you cannot produce such a B-field without having currents present in the system. If we introduce a current density $\vec{J}$ and take the E-field derived from Faraday's law, then Ampere's law tells us that $$ \mu_0 \epsilon_0 \frac{\partial \vec{E}}{\partial t} = -\vec{J},$$ $$- \mu_0 \epsilon_0 \frac{R}{2}B_0 \sin(t) \hat{\phi} = -\vec{J}$$ $$ \vec{J} = \mu_0 \epsilon_0 \frac{R}{2}B_0 \sin(t) \hat{\phi}$$
{ "domain": "physics.stackexchange", "id": 63689, "lm_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, classical-electrodynamics, maxwell-equations, electromagnetic-induction", "url": null }
computational-chemistry, quantum-chemistry Title: GAMESS crash course? I'm still learning about MO theory – and I thought that I would do some calculations with GAMESS to become more familiar with the concept. Even though I look forward to delving into the realm of quantum math in the not-so-distant future – it's very difficult to get a grip on all of the terminology. I'm using the GAMESS Avogadro extension to write some input files, but I don't know which options to use. Which options should I use if I want to study the orbitals of, say, shikimic acid? RHF, MP2, AM1 / MINI 6-31G(d)? Computer specs: 3.6GHz i5 with 16GB of RAM First off, welcome to Chemistry.SE! For formatting help visit the help center and for more information about this page, take the tour. While I do think you should learn some theory, it's definitely possible to learn some practical computational chemistry through experimentation. And yes, there are a lot of abbreviations to follow.
{ "domain": "chemistry.stackexchange", "id": 1899, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "computational-chemistry, quantum-chemistry", "url": null }
Suppose that $\mathcal{P}$ lies over rational prime $3$. Since the rational prime $3$ is inert in $K'$, the residue field degree must be $3$. By the decomposition $3R=P^2Q$, the residue field degree for $P$ and $Q$ over rational prime $3$ must be both $1$. This gives the residue field degree for $\mathcal{P}$ over both $P$ and $Q$ must be $3$, yielding that the ramification indices for $\mathcal{P}$ over both $P$ and $Q$ are $1$. Now assume that $\mathcal{P}$ is over rational prime $19$. As @franzlemmermeyer answered in the above link, we use Abhyankar's lemma. Since $19$ is totally ramified in both $K$ and $K'$, we have by Abhyankar's lemma that the ramification index for $\mathcal{P}$ over $\mathcal{P}\cap K$ is $1$. Hence, the extension $L$ over $K$ is unramified over $K$, yielding that $L$ is the Hilbert class field of $K$. This answers my question 3. Acknowledgement @JohnM, @Lubin, Thank you very much for the helpful comments with great insights.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.969785409439575, "lm_q1q2_score": 0.8525837032805726, "lm_q2_score": 0.8791467627598857, "openwebmath_perplexity": 135.38083505015564, "openwebmath_score": 0.9061337113380432, "tags": null, "url": "https://math.stackexchange.com/questions/1874504/class-number-of-mathbbq-sqrt319-and-hilbert-class-field" }
javascript, programming-challenge, array, matrix for (let i = iRightLeftStart; i >= iRightLeftEnd; i--) { spiral.push(matrix[rightLeftPosition][i]); } for (let i = iBottomTopStart; i >= iBottomTopEnd; i--) { spiral.push(matrix[i][bottomTopPosition]); } iLeftRightStart++; iLeftRightEnd--; leftRightPosition++; iTopBottomStart++; iTopBottomEnd--; topBottomPosition--; iRightLeftStart--; iRightLeftEnd++; rightLeftPosition--; iBottomTopStart--; iBottomTopEnd++; bottomTopPosition++; } return spiral; }
{ "domain": "codereview.stackexchange", "id": 33798, "lm_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, programming-challenge, array, matrix", "url": null }
javascript, html, sudoku <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> </tr> <tr> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td> <input type="text" size="1" name="sud[]"></input> </td> <td>
{ "domain": "codereview.stackexchange", "id": 19342, "lm_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, html, sudoku", "url": null }
python, performance, algorithm, strings, search Title: Naive implementation of KMP algorithm After reading this answer to the question "High execution time to count overlapping substrings", I decided to implement the suggested Knuth-Morris-Pratt (KMP) algorithm. I used the pseudo-code listed on Wikipedia for the functions kmp_table and kmp_search. However, when running it on some corner-cases, I have observed that it is a lot slower than the standard str.find, which apparently uses a modified Boyer-Moore-Horspool algorithm and should thus have worse worst-case performance. The specific case I looked at is: $ ipython -i kmp.py In [1]: text = "A"*1000000 + "B" In [2]: word = "A"*100 + "B" In [3]: %timeit kmp_search(text, word) 1 loop, best of 3: 410 ms per loop In [4}: %timeit text.find(word) 1000 loops, best of 3: 703 µs per loop
{ "domain": "codereview.stackexchange", "id": 25310, "lm_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, algorithm, strings, search", "url": null }
trees, avl-trees We can also keep sets as hash-tables, with open adressing. Then adding has a standard solution, but deleting is hard, as doing it in the naive way may make other items untraceable (when we have a method other than linear probing).
{ "domain": "cs.stackexchange", "id": 15246, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "trees, avl-trees", "url": null }
c++, tic-tac-toe } turns = turns - 1; player++; } else if(input == 0) turns = 0; else { std::cout<<"Invalid move "; std::cin.ignore(); std::cout << std::endl; //cin.get(); } } while(turns > 1); if(turns == 1) { std::cout << "------------------------------------\n"; std::cout << "====> Player1 and Player2 Tie <=====\n"; std::cout << "------------------------------------\n\n\n\n"; resetBoard(); }
{ "domain": "codereview.stackexchange", "id": 9235, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, tic-tac-toe", "url": null }
One way of defining the real numbers is as equivalence classes of "the collection of all Cauchy sequences (or, equivalently, the collection of all increasing sequences with upper bound) of rational numbers" with "$\{a_n\}$ equivalent to $\{b_n\}$ if and only if $\{a_n- b_n\}$ converges to 0. The essentially says that, for example, $\pi$ is "represented" by the infinite decimal 3.1415926.... From that definition, if a is an irrational number then there exist a sequence of rational numbers $r_1, r_2, r_3, ...$ that converges to a. We then define $x^a$ to be the limit of the sequence $x^{r_1}, x^{r_2}, x^{r_3}, ...$. Using the same example as before, $2^\pi$ is defined as the limit of the sequence $2^3, 2^{3.1}, 2^{3.14}, 2^{3.141}, 2^{3.1415}, 2^{3.14159}, 2^{3.141592}, 2^{31415926}, ...$. • One key point is that the limit of $x^{r_{\large n}}$ does not depend on which sequence $r_n$ converging to $a$ is chosen. – anon Nov 5 '17 at 21:41 My two cents:
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9817357173731319, "lm_q1q2_score": 0.8694560606493561, "lm_q2_score": 0.885631484383387, "openwebmath_perplexity": 287.95063053383217, "openwebmath_score": 0.9064700603485107, "tags": null, "url": "https://math.stackexchange.com/questions/1992464/how-is-irrational-exponent-defined" }
lo.logic, type-theory, formal-modeling, automated-theorem-proving, bioinformatics The theorems in your book will almost certainly be theorems of $\sf NBG$ given that they are written in the language of set theory. The axioms of genetics in that book will almost certainly be represented as definitions on set theoretical predicates, much the way that Peano arithmetic is represented in $\sf NBG$ as definitions of predicates. From there you follow the resolution procedure in any ATP. Pick a statement you want to prove, negate it, convert to Skolem normal form, then to clausal form, and follow the resolution. When you find the empty clause, you have found a contradiction, proving the statement.
{ "domain": "cstheory.stackexchange", "id": 2756, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "lo.logic, type-theory, formal-modeling, automated-theorem-proving, bioinformatics", "url": null }
general-relativity, special-relativity, wormholes I'm not sure what you mean, but not necessarily. There are certainly some effects here, but also note that just because a photon passes close to a horizon, that doesn't mean it ends up with significantly different energy (and thus a change to its wavelength). Just imagine a photon emitted by some distant star, passing close to an ordinary (Schwarzschild) black hole, and escaping to be observed by some distant observer. If the star, the black hole, and the observer are all basically at rest with respect to each other, the observed photon will have basically the same wavelength as when it was emitted — or if it hadn't passed near the black hole at all — because whatever energy it gained on moving towards the black hole it lost on moving away from it. It is possible for the photon to gain net energy if the black hole is spinning very rapidly, or moving very rapidly relative to the emitter or observer.
{ "domain": "physics.stackexchange", "id": 73104, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "general-relativity, special-relativity, wormholes", "url": null }
c++, c, array, iterator, pointers But can this be solved without loops? OR with a single loop? Can this be made more efficient? Why do you have the following line if you are not using temp? int temp = arr->A[0]; You do not need the nested loops. You are currently shifting the elements one position at a time when you can move them n positions. void LeftShift1(struct Array* arr, unsigned int n) { for (unsigned int i = 0; i < arr->length; i++) { if (i + n < arr->length) arr->A[i] = arr->A[i + n]; else arr->A[i] = 0; } } Or use memmove / memset as suggested by @Carlo
{ "domain": "codereview.stackexchange", "id": 42227, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "c++, c, array, iterator, pointers", "url": null }
? • Your first step is not wrong. Just take a closer look at the last term (cf. Brian's answer). – caligula Oct 31 '13 at 15:31 The events $A_1\cap A_2'$ and $A_1'\cap A_2$ are mutually exclusive: $$(A_1\cap A_2')\cap(A_1'\cap A_2)=(A_1\cap A_1')\cap(A_2\cap A_2')=\varnothing\cap\varnothing=\varnothing\;$$ You can certainly subtract $\Bbb P\big((A_1\cap A_2')\cap(A_1'\cap A_2)\big)$, but that’s $\Bbb P(\varnothing)=0$, so there’s no need to do so. Since the events are independent, you then have $$\Bbb P(A_1\cap A_2')=p_1(1-p_2)$$ and $$\Bbb P(A_1'\cap A_2)=(1-p_1)p_2\;,$$ from which the result is a matter of a little algebra. Solution 1
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.98201378740596, "lm_q1q2_score": 0.8225543466288809, "lm_q2_score": 0.8376199572530448, "openwebmath_perplexity": 181.5345110305976, "openwebmath_score": 0.8640900254249573, "tags": null, "url": "https://math.stackexchange.com/questions/547017/find-probability-that-only-one-event-will-occur" }
c#, server Title: C# Chat - Part 1: Server I've been building a simple C# server-client chat-style app as a test of my C#. I've picked up code from a few tutorials, and extended what's there to come up with my own server spec. In this post (the second will be the client), I'd like to get some feedback on the server. To me, the code seems bulky and as if it could be brought down by some judicious use of functions or a utility class (I've spotted a doubled-up function (SendToClient) that I guess I could just make public to save on LOC, but what else is there?) 1 - Program.cs using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace MessengerServer { class Program { static void Main(string[] args) { int port = 1100;
{ "domain": "codereview.stackexchange", "id": 12906, "lm_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#, server", "url": null }
- @GitGud Edited. By the way, if you use \arcsin x, you produce $$\arcsin x.$$ –  Pragabhava Jan 14 '13 at 14:05 I do not follow why $t \in (-1,1)$. –  Lucas Alanis Jan 14 '13 at 15:20 @LanceFerd It's the domain of definition for $\arcsin t$, i.e. the range where $\sin x$ is invertible -in the principal branch, that is-. –  Pragabhava Jan 14 '13 at 17:13 What would be restrictions on $x$ and $t$ if we were to do it by $x=2\arctan t$? –  Lucas Alanis Jan 14 '13 at 20:18 Please, look at my last question to David Mitra above. –  Lucas Alanis Jan 14 '13 at 21:38
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9744347845918813, "lm_q1q2_score": 0.8033843859372494, "lm_q2_score": 0.8244619328462579, "openwebmath_perplexity": 346.875363919611, "openwebmath_score": 0.9782524704933167, "tags": null, "url": "http://math.stackexchange.com/questions/278539/how-to-find-the-following-derivative" }
- Here's another way to look at it. You can also recast the equation as follows, without cancelling anything or multiplying or dividing by anything which might be zero: $$0=\frac {x-4}{x-1}-\left(\frac {1-4}{x-1}\right)=\frac {x-1}{x-1}$$Now do you see what is going on? - Very well. That is one bogus way of proving $1 = 0$ !! :P – valyrian Mar 17 '14 at 11:46 I like this approach; clean simple contradiction – Dan Bryant Mar 17 '14 at 12:25 If you use $x=1$ you get $1-1=0$ on the denominator, which gives you a division by zero. And since that's the only value that gets an equality on both sides of the equation, it shows that there's no solution. - Thank you. That's what I was thinking since the comments came on. – valyrian Mar 17 '14 at 11:31 We may never divide by 0, so we require for the solution that the denominator $(x-1) \not =0$, meaning $x \not= 1$.
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9615338035725358, "lm_q1q2_score": 0.8153496677141868, "lm_q2_score": 0.8479677622198946, "openwebmath_perplexity": 280.9568728151031, "openwebmath_score": 0.9221193194389343, "tags": null, "url": "http://math.stackexchange.com/questions/715358/how-many-solutions-for-this-equation/715369" }
python, pygame player.draw(screen) for star in stars: star.draw(screen) star.fall() pygame.display.update() run = True clock = pygame.time.Clock() while run: star_spawn += clock.tick(60) elapsed_time = time.time() - start_time playerRect = pygame.Rect(player.x, player.y, player.width, player.height) for event in pygame.event.get(): if event.type == pygame.QUIT: run = False break if star_spawn >= max(200, star_spawn_rate): star_spawn_rate -= star_spawn_rate_decrease star_spawn = 0 starSpawner() for star in stars[:]: starRect = pygame.Rect(star.x, star.y, star.width, star.height) if star.y >= SCREEN_HEIGHT: stars.remove(star) elif star.y + star.height >= player.y and starRect.colliderect(playerRect): stars.remove(star) hit = True break
{ "domain": "codereview.stackexchange", "id": 44911, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python, pygame", "url": null }
# Lecture 9: Expectation, Indicator Random Variables, Linearity ## More on Cumulative Distribution Functions A CDF: $F(x) = P(X \le x)$, as a function of real $x$ has to be • non-negative In the following discrete case, it is easy to see how the probability mass function (PMF) relates to the CDF: Therefore, you can compute any probability given a CDF. Ex. Find $P(1 \lt x \le 3)$ using CDF $F$. \begin{align} & &P(x \le 1) + P(1 \lt x \le 3) &= P(x \le 3) \\ & &\Rightarrow P(1 \lt x \le 3) &= F(3) - F(1) \end{align} Note that while we don't need to be so strict in the continuous case, for the discrete case you need to be careful about the $\lt$ and $\le$. ### Properties of CDF A function $F$ is a CDF iff the following three conditions are satisfied. 1. increasing 2. right-continuous (function is continuous as you approach a point from the right) 3. $F(x) \rightarrow 0 \text{ as } x \rightarrow - \infty$, and $F(x) \rightarrow 1 \text{ as } x \rightarrow \infty$.
{ "domain": "notebook.community", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9910145691243959, "lm_q1q2_score": 0.8170537828647313, "lm_q2_score": 0.824461928533133, "openwebmath_perplexity": 1964.1862747413497, "openwebmath_score": 1.0000100135803223, "tags": null, "url": "https://notebook.community/buruzaemon/stats-110/Lecture_09" }
performance, ruby, regex Just doing a very cursory benchmarking, but it's an order of magnitude faster, at least for small strings like your example. Edit: I should point out that this implementation is different from the original in that it doesn't care about multiples of the same character. The original code will return false if given, say, ruby and rr, since there's only one "r" in the string. The implementation above, however, just matches the first letter twice - or N times, if need be. Whether this is correct for your use-case, I don't know. Incidentally, you could consider uniqing the character set to avoid redundant matching, but it'll probably be much slower for all but the most extreme input. Edit 2: Responding to comments. This isn't very pretty, but should get the job done: def find_chars(subject, characters) letters = characters.chars subject.chars.each do |letter| i = letters.index(letter) next if i.nil? letters.delete_at(i) return true if letters.empty? end false end
{ "domain": "codereview.stackexchange", "id": 21457, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "performance, ruby, regex", "url": null }
python, interview-questions, dynamic-programming prices is an N-by-C array containing the price to paint the house n with color c. color_names is a sequence containing the names of the colors. """ num_houses = len(prices) if not num_houses: return [] num_colors = len(prices[0]) totals = [None] * num_houses totals[0] = prices[0][:] # After the first house, dynamic programming does its magic. # At each step, add the price of painting this house # to the minimum of the total painting of the other colors. for house in range(1, num_houses): totals[house] = [ prices[house][color] + min(totals[house - 1][c] for c in range(num_colors) if c != color) for color in range(num_colors) ]
{ "domain": "codereview.stackexchange", "id": 14732, "lm_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, interview-questions, dynamic-programming", "url": null }
ros, pcl, ros-hydro Originally posted by atp on ROS Answers with karma: 529 on 2014-03-25 Post score: 0 Original comments Comment by MichaelKorn on 2014-03-25:\ What compiler (version) do you use? What CPU do you have? Comment by atp on 2014-03-26: Compiler: gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5). CPU model name: Intel(R) Core(TM) i7-4770K. I think Haswell support was added in gcc 4.7. I suppose you are using Ubuntu 12.04. I know 2 solutions: You can update gcc: You can add a PPA (https://launchpad.net/~ubuntu-toolchain-r/+archive/test) and update to 4.7 or 4.8. I'm using this PPA with Ubuntu 12.04, gcc 4.7, i7-4770 and PCL/KinFu. You can use compiler flags to specify the architecture (e.g. "-march=corei7"). This should work, but it maybe not allows to use the full potential of the CPU. Originally posted by MichaelKorn with karma: 1480 on 2014-03-26 This answer was ACCEPTED on the original site Post score: 2
{ "domain": "robotics.stackexchange", "id": 17413, "lm_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, pcl, ros-hydro", "url": null }
ros, message-filters, message /opt/ros/hydro/include/message_filters/synchronizer.h:290:5: instantiated from ‘void message_filters::Synchronizer<Policy>::connectInput(F0&, F1&, F2&, F3&, F4&, F5&, F6&, F7&, F8&) [with F0 = message_filters::Subscriber<coop_est::FeatureBArray_<std::allocator<void> > >, F1 = message_filters::Subscriber<nav_msgs::Odometry_<std::allocator<void> > >, F2 = message_filters::NullFilter<message_filters::NullType>, F3 = message_filters::NullFilter<message_filters::NullType>, F4 = message_filters::NullFilter<message_filters::NullType>, F5 = message_filters::NullFilter<message_filters::NullType>, F6 = message_filters::NullFilter<message_filters::NullType>, F7 = message_filters::NullFilter<message_filters::NullType>, F8 = message_filters::NullFilter<message_filters::NullType>, Policy = message_filters::sync_policies::ExactTime<coop_est::FeatureBArray_<std::allocator<void> >, nav_msgs::Odometry_<std::allocator<void> >, message_filters::NullType, message_filters::NullType,
{ "domain": "robotics.stackexchange", "id": 20098, "lm_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, message-filters, message", "url": null }
Hint Since $$b$$ does not depend on $$u$$, $$\frac{d}{du}[(u A + C)^{-1} {\bf b}] = \frac{d}{du}[(u A + C)^{-1}] {\bf b} ,$$ and so it suffices to know how to compute the derivative $$\frac{d}{du} [P(u)^{-1}]$$ inverse of a matrix function $$P : \Bbb R \to M_n (\Bbb R)$$ (wherever that inverse is defined). We we can find $$\frac{d}{du}(P(u)^{-1})$$ in terms of $$P$$ and $$\frac{d P}{dt}$$ by differentiating both sides of $$P(u) P(u)^{-1} = I$$ and isolating $$\frac{d}{du}[P(u)^{-1}]$$. Suppressing the argument $$u$$, we have $$\frac{dP}{du} P^{-1} + P \frac{d}{du} (P^{-1}) ,$$ so $$\frac{d}{du} (P^{-1}) = - P^{-1} \frac{dP}{du} P^{-1} .$$ $$(uA + C)\mathbf x = \mathbf b; \tag 1$$ since $$(uA + C)$$ is invertible we may directly write $$\mathbf x = (uA + C)^{-1} \mathbf b \tag 2$$ which expresses $$\mathbf x$$ as a function of $$u$$; then $$\mathbf x' = ((uA + C)^{-1})' \mathbf b; \tag 3$$
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9904406023459218, "lm_q1q2_score": 0.8476697255207004, "lm_q2_score": 0.8558511469672594, "openwebmath_perplexity": 299.92193042247777, "openwebmath_score": 0.9975171685218811, "tags": null, "url": "https://math.stackexchange.com/questions/3643615/derivative-of-uac-1-mathbfb-w-r-t-u-in-mathbbr" }
python Write this with a while loop rather then recursion. It'll be easier to read. # hash a file and return the hash string try: local_file = open(filename,'rb') except Exception as e: print 'Error while opening file for hashing: ', e If this error actually happens, the code below will fail because the script will still try to read from the file. If you are going to catch exceptions you need to actually do something sane about it. Printing the error is not something sane. local_file.close() Use the with construct instead return unicode(result) Why? #main def main(): # get list of volumes drives = [d for d in os.listdir('/Volumes')] This is the same as drives = os.listdir('/Volumes') # ask user for origin drive origin = choose_drive(drives, 'Origin') origin_files = os.listdir(origin) # ask user for destination drive destination = choose_drive(drives, 'Destination') destination_files = os.listdir(destination)
{ "domain": "codereview.stackexchange", "id": 1576, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "python", "url": null }
simulation, cirq simulator = cirq.Simulator() result = simulator.run(circuit, repetitions=sample_number) final = result.histogram(key='x')
{ "domain": "quantumcomputing.stackexchange", "id": 4072, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "simulation, cirq", "url": null }
ros [ INFO] [1633642073.757685440, 0.267000000]: Starting Laser Plugin (ns = /tb3_1/) [ INFO] [1633642073.758468818, 0.267000000]: Laser Plugin (ns = /tb3_1/) <tf_prefix_>, set to "" [ INFO] [1633642073.941327861, 0.267000000]: Starting plugin DiffDrive(ns = /tb3_1//) [ INFO] [1633642073.941434480, 0.267000000]: DiffDrive(ns = /tb3_1//): <rosDebugLevel> = na [ INFO] [1633642073.942215834, 0.267000000]: DiffDrive(ns = /tb3_1//): <tf_prefix> = [ INFO] [1633642073.943556971, 0.267000000]: DiffDrive(ns = /tb3_1//): Advertise joint_states [ INFO] [1633642073.944099271, 0.267000000]: DiffDrive(ns = /tb3_1//): Try to subscribe to cmd_vel [ INFO] [1633642073.945743832, 0.267000000]: DiffDrive(ns = /tb3_1//): Subscribe to cmd_vel [ INFO] [1633642073.946119852, 0.267000000]: DiffDrive(ns = /tb3_1//): Advertise odom on odom [tb3_1/spawn_urdf-8] process has finished cleanly log file: /home/roshan/.ros/log/64b78606-27b5-11ec-9406-6f7aa8a39c03/tb3_1-spawn_urdf-8*.log
{ "domain": "robotics.stackexchange", "id": 36992, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros", "url": null }
c#, asp.net, ajax try { convertedValue = (T)Convert.ChangeType(value, type); } catch {} return convertedValue ; } This way of working swallows the exception. In case one occurs the default of T will be returned, otherwise the converted value. Results: ConvertTo<int>("qwerty"); //0 ConvertTo<bool>("qwerty"); //False Update: As stated in the comments below, you can also take the code and throw it in an extension method. Also nice for reusability and your could will also look a bit cleaner. Here goes: public static class Extensions { public static T ConvertTo<T>(this string value) { if (String.IsNullOrEmpty(value)) return default(T); var type = Nullable.GetUnderlyingType(typeof(T)) ?? typeof(T); T convertedValue = default(T); try { convertedValue = (T)Convert.ChangeType(value, type); } catch {} return convertedValue ; } }
{ "domain": "codereview.stackexchange", "id": 10885, "lm_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#, asp.net, ajax", "url": null }
php, twitter, facebook Title: Displaying a user's social media information This is for a page where it displays some social media information for that user. I would like to improve the following code that I posted below. It does the job perfectly, but I just feel like it could definitely be improved. I could easily leave it the way it is but I am trying to learn and that's why I would like to get suggestions from experienced programmers. <?php if($facebook && !$twitter_username || !$facebook && $twitter_username) { $width = "490"; } else { $width = "930"; } ?>
{ "domain": "codereview.stackexchange", "id": 1065, "lm_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, twitter, facebook", "url": null }
thermodynamics Nevertheless, partial molar volume is function of composition and commonly quoted values are for very low concentration (adding substance to large quantity of water). If you want to obtain solution with higher concentration, finding its exact volume requires knowledge about $\widehat{V}_i$ as a function of composition and such function has to be integrated.
{ "domain": "chemistry.stackexchange", "id": 2917, "lm_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", "url": null }
covering the entire MIT curriculum. It is defined as follows: x n rx n (1 x n);0 x n 1,0 r 4 (1) where „r‟ is a variable parameter used to alter the period of the limit cycle oscillations. The other day I found some old basic code I had written about 15 years ago on a Mac Classic II to plot the Feigenbaum diagram for the logistic map. Similar algortihm works well in MATLAB but in OPENCV i am getting original image as it is. The logistic map revisited. The categorical response has only two 2 possible outcomes. Chaos and Time-Series Analysis J. 11 AM-1 PM Lab. With Matlab, code to plot the bifurcation diagram (x vs μ) and discuss stability as a function of μ. A web diagram showing the first hundred or so iterations of this procedure and initial value appears on the cover of Packel (1996; left figure) and is animated in the right figure above. The last m-file (to the right or bottom) of each group runs the simulations. Note that (4) is defined on the open set (0,1) because 0 is a known
{ "domain": "eccellent.it", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9808759610129463, "lm_q1q2_score": 0.8042136637923, "lm_q2_score": 0.819893335913536, "openwebmath_perplexity": 1483.599632833718, "openwebmath_score": 0.6984260678291321, "tags": null, "url": "http://widc.eccellent.it/logistic-map-matlab.html" }
Please use consistent units for any input. . Y_c Moment of inertia of hollow circular section calculator . (check our centroids table here). Circular hollow section is an online tool to determine the section properties like section area, second moment of inertia or the section modulus of a CHS. Therefore, the plastic section modulus formula becomes: Z = {A\over2} Y_c + {A\over2} Y_c \Rightarrow. ), with magnitude given by the formula: \sigma = -{M_x Y\over I} =-\frac{M_x}{S_x}. , the respective distance of the centroid of the tensile area Calculation Tools & Engineering Resources. This tool calculates the properties of a circular tube section (also called circular hollow section or CHS). A variety of surface finishes are available across our range of structural tubulars, but not all finishes are available in all sizes. Read more about us here. Expressed in terms of diamters, the plastic modulus of the circular tube, is given by the formula: where, 21 123 666 679.PO Box 246 Sunnybank,
{ "domain": "base1.cloud", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9766692359451418, "lm_q1q2_score": 0.8242063773609003, "lm_q2_score": 0.8438950947024555, "openwebmath_perplexity": 1837.2402970444944, "openwebmath_score": 0.653057873249054, "tags": null, "url": "http://base1.cloud/identify-the-vnwkciq/6ec876-circular-hollow-section-calculator" }
ros --do some calculations, then write to file self.stdout_log.write('stuff') return resp1.outgoing except rospy.ServiceException, e: print "Service call failed: %s"%e self.stdout_log.write('[call_serve ' + str(self.call) + '] ' + 'Service call failed: %s'%e) def callback(self, data): rospy.loginfo(rospy.get_caller_id() + 'I am: %d, I heard %d', self.about_me_wm.ID, data.id) self.callback_bc = self.callback_bc + 1 self.stdout_log_callback.write('[callback ' + str(self.callback_bc) + '][ROSPY] I am: %d, I heard %d\n' % (self.about_me_wm.ID, data.id)) guy_id_srv = [data.id, -1] guy_id_srv.append([int(x) for x in filter(None, data.content.split('|'))]) exp = [] for x in range(0, len(guy_id_srv[2])): exp.append(-1) guy_id_srv.append(exp) self.about_me_wm.known_people.append(guy_id_srv)
{ "domain": "robotics.stackexchange", "id": 25321, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ros", "url": null }
quantum-field-theory, gauge-theory, quantum-electrodynamics, quantization Formally, you can eliminate the unwanted term $\frac{1}{2\xi}(\partial\cdot A)^2$ by taking the so-called unitary limit, $\xi\to\infty$. As $S$ is $\xi$ independent, you may want to argue that you have taken the unitary limit, thus getting rid of the unwanted term, while at the same time taking $\xi=1$, thus simplifying the evaluation of $S$. The 't Hooft-Feynman gauge is more convenient from the practical point of view, and the unitary one is more convincing from the Lagrangian point of view. Gauge invariance is essential if these different POVs are to coexist.
{ "domain": "physics.stackexchange", "id": 44967, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-field-theory, gauge-theory, quantum-electrodynamics, quantization", "url": null }
quantum-field-theory, particle-physics, string-theory, supersymmetry, magnetic-monopoles The triplet, the SU(5) partner of the Higgs, assuming the Higgs is in a 5 of SU(5), or the analogous thing for higher GUTs. Presumably, this is GUT scale, but the experimental bound on this is going to be weak, order 1TeV, since it comes from loop corrections to the standard model. the triplet will be a scalar charged like a quark doublet. Any SU(5) Higgs boson, whatever it might be, or the analogous thing in higher GUTs the theoretical range is GUT scale. I don't think that compiling a list is so useful--- you will eventually hit manifold moduli fields, and string resonances, and then the black hole spectrum, which is continuously lined to the particle spectrum. There is no limit to what unstable particles you start detecting at the GUT scale. The monopoles are interesting because they are stable. The rest are not.
{ "domain": "physics.stackexchange", "id": 4188, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "quantum-field-theory, particle-physics, string-theory, supersymmetry, magnetic-monopoles", "url": null }
• Let $p$ be the probability that in $7$ rolls you see all faces at least once. We find $p$. Then the answer to the original problem is $1-p$. It should not be too hard to find $p$, by counting the "favourables" and dividing by $6^7$. – André Nicolas Aug 6 '15 at 13:34 • As a further hint to counting the "favorables" for $p$, note that if you roll 7 times you will see at least one number repeated. But if this happens more than once you will not get to see all 6 numbers. – David K Aug 6 '15 at 13:50 • The title and text of the question don't match. Please clarify whether "at least" is intended, as in the text, or "exactly", as the title appears to imply. – joriki Aug 6 '15 at 14:17 • To clarify are you asking what is the probability of needing exactly 8 rolls to see all numbers or 8 or more rolls? – Warren Hill Aug 7 '15 at 8:20 Rephrase the question: What is the probability of not seeing all $6$ values when rolling a die $7$ times? Find the probability of the complementary event:
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9572778024535095, "lm_q1q2_score": 0.8647034919164124, "lm_q2_score": 0.9032942054022056, "openwebmath_perplexity": 234.50984034329736, "openwebmath_score": 0.8104450702667236, "tags": null, "url": "https://math.stackexchange.com/questions/1386606/probability-of-rolling-a-dice-8-times-before-all-numbers-are-shown/1387649" }
divide and conquer recurrences, Dynamic Programming vs Divide-and-Conquer, Generate a random permutation of elements from range [L, R] (Divide and Conquer), Merge K sorted arrays of different sizes | ( Divide and Conquer Approach ), Sum of maximum of all subarrays | Divide and Conquer, Frequency of an integer in the given array using Divide and Conquer, Maximum and minimum of an array using minimum number of comparisons, Program to find largest element in an array, Find the number of islands | Set 1 (Using DFS), Write Interview Strassen algorithm is a recursive method for matrix multiplication where we divide the matrix into 4 sub-matrices of dimensions n/2 x n/2 in each recursive step. edit Time Complexity of above method is O(N3). & .
{ "domain": "heaveyduty.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9626731105140615, "lm_q1q2_score": 0.808389308732794, "lm_q2_score": 0.8397339656668287, "openwebmath_perplexity": 781.7602093644065, "openwebmath_score": 0.6605963706970215, "tags": null, "url": "https://heaveyduty.com/docs/7p3l3.php?a930b0=strassen%27s-matrix-multiplication-4x4-example-code" }
quantum-mechanics, hilbert-space, operators, quantum-information, density-operator $$\hat{\rho} = |\psi\rangle \langle\psi|$$ Since you are given the probabilities of the state, which are just real numbers, you can assume your system to be in a mixed state. Also, probabilites are usually not denoted as kets. For a mixed state you write: $$\hat{\rho} = \sum_i p_i|\psi_i\rangle \langle \psi_i|$$ Also for the probabilites must hold: $$1 = \sum_i p_i$$ For your second question, the states are not required to be orthogonal nor form a complete orthonormal system, but they are required to be normalized. I hope that helps you. Edit: For question 1 you should probably also consider writing out the trace using a complete orthonormal system of states e.g. the eigenstates of the density matrix.
{ "domain": "physics.stackexchange", "id": 62325, "lm_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, hilbert-space, operators, quantum-information, density-operator", "url": null }
qiskit, simulation, noise, qiskit-runtime print(job.result().values) I know that Qiskit Runtime primitives can run on real IBM quantum devices but what I'm wondering whether is possible run them by using fake backends (or, more in general, custom noise models). For example, how can I run the code above on the FakeManila backend or passing a NoiseModel instance? Is there any other way to do that? Using primitives with fake backends You can use BackendEstimator to work with fake backends. As primitives implementation, BackendEstimator and BackendSampler are designed to be generic that can work with almost any backend. from qiskit.primitives import BackendEstimator estimator = BackendEstimator(backend = FakeNairobi()) job = estimator.run(qc, O) result = job.result() print(result.values) Note that, if you are dealing with a provider that has native primitive implementations, like Qiskit Runtime or Qiskit Aer, you should use that native implementation. Most probably, it will be much more efficient.
{ "domain": "quantumcomputing.stackexchange", "id": 4458, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "qiskit, simulation, noise, qiskit-runtime", "url": null }
based energy storage? Thanks for contributing an answer to Mathematics Stack Exchange! Then, you have to check if there is any non marked point on the line inside the initial square [0,k]X[0,k]. By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy. then you will never process a cell (that has already been processed that you can get to quicker so you never process any already processed cells. And the manhatten distance is the largest of abs(u1-u2), abs(v1-v2). To begin with, a lot of this material in this section has been referred from the now offline page of divingintodatascience, the site had been of great help. Manhattan Distance is the sum of absolute differences between points across all the dimensions. So, again, overall solution will be binary search for r. Inside of it you will have to check if there is any point at least r units away from all given points. The social distance requirement in Manhattan is 2 metres. Voronoi diagram
{ "domain": "eandltoledolandscaping.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9658995723244552, "lm_q1q2_score": 0.8357195813963271, "lm_q2_score": 0.8652240930029117, "openwebmath_perplexity": 1112.1657793499576, "openwebmath_score": 0.47308290004730225, "tags": null, "url": "http://www.eandltoledolandscaping.com/pri2s/fe22b6-maximum-manhattan-distance" }
sequence-alignment, prosite Example from Prosite documentation: <A-x-[ST](2)-x(0,1)-V This pattern, which must be in the N-terminal of the sequence ('<'), is translated as: Ala-any-[Ser or Thr]-[Ser or Thr]-(any or none)-Val
{ "domain": "bioinformatics.stackexchange", "id": 1465, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "sequence-alignment, prosite", "url": null }
java, multithreading It is true that sleep() can be interrupted (which will raise an InterruptedException), which is what the interrupt() will do. However, afterwards the Thread can continue doing whatever it wants after being “interrupted”, so you must also check for a stop-condition of some kind. Above, we check runner != null. But as you can see above, you don’t need a sleep() in the worker thread. If you don’t want to run the Thread in a loop, or you have many different loops where the task may spin, you will have to make the stop check in each of those places.
{ "domain": "codereview.stackexchange", "id": 45214, "lm_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", "url": null }
$$\begin{eqnarray} \vec{FB}\cdot \vec{FE} &=& (E-F)(B-F)\\ &=& {1\over 4}(-B+2C)(2B-A)\\ &=& -{1\over 2}(B^2+CA)\\ &=&0 \end{eqnarray}$$ A solution with a help of the coordinate system. Let $$B = (0,0)$$, $$C= (2c,0)$$ and $$A= (0,2a)$$. Then $$D(2c,2a)$$ and $$E(2c,a)$$. A perpendicular to $$AC:\;\;{x\over 2c}+{y\over 2a}=1$$ through $$B$$ is $$y={c\over a}x$$ which cuts $$AC$$ at $$G= \big({2a^2c\over a^2+c^2},{2c^2a\over a^2+c^2} \big)$$ so $$F = \big({a^2c\over a^2+c^2},{2c^2a+a^3\over a^2+c^2} \big)$$ Now it is not difficult to see that $$\vec{FE}\cdot \vec{FB} =0$$. Another solution: Say $$M$$ is midpoint of $$AB$$, then $$FM$$ is a middle line in triangle $$ABG$$ so $$FM||BG$$ so $$\angle MFC = 90^{\circ}$$ and thus $$F$$ is on a circle through $$B,C$$ and $$M$$. But on this circle is also $$E$$ since $$\angle MEC = 90^{\circ}$$. So $$\angle BFE = \angle BME = 90^{\circ}$$
{ "domain": "stackexchange.com", "id": null, "lm_label": "1. YES\n2. YES", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.988130881050834, "lm_q1q2_score": 0.8653921620593246, "lm_q2_score": 0.8757869819218865, "openwebmath_perplexity": 128.04523796137414, "openwebmath_score": 0.9508201479911804, "tags": null, "url": "https://math.stackexchange.com/questions/2948977/proving-right-angle-using-vectors" }
python, performance, python-3.x, array, numpy # initialize accumulators X, y = np.zeros([0, 1, chunk_size, 4]), np.zeros([0,]) # loop over each group (df[df.id==1] and df[df.id==2]) for _, group in grouped: inputs = group.loc[:, 'A':'D'].values label = group.loc[:, 'class'].values[0] # calculate number of splits N = (len(inputs)-1) // chunk_size if N > 0: inputs = np.array_split( inputs, [chunk_size + (chunk_size*i) for i in range(N)]) else: inputs = [inputs] # loop over splits for inpt in inputs: inpt = np.pad( inpt, [(0, chunk_size-len(inpt)),(0, 0)], mode='constant') # add each inputs split to accumulators X = np.concatenate([X, inpt[np.newaxis, np.newaxis]], axis=0) y = np.concatenate([y, label[np.newaxis]], axis=0) return X, y
{ "domain": "codereview.stackexchange", "id": 41393, "lm_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, python-3.x, array, numpy", "url": null }
elements, ozone The periodic table describes the atoms that make up elements as this is the most fundamental property. Many other elements, though, exist in multiple allotropes. Carbon, for example, has several: graphite, diamond, buckminsterfullerene and quite a few others. All allotropes consist of only one type of atom but the bulk physical properties depend on how the atoms are joined up (flat plates of carbon hexagons with multiple bonding in graphite, a three-dimensional network of singly-bonded tetrahedral carbons in diamond). We don't normally add too much about allotropes in a periodic table as it would make the table a little big, although some include limited information about how many there are. And, usually, only one is thermodynamically stable under normal conditions (so the physical properties will be about that one).
{ "domain": "chemistry.stackexchange", "id": 11678, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "elements, ozone", "url": null }
ions, bond Why does $\ce{FeCl3}$ bond the way it does? First, it is a good idea to look at the wikipedia page for iron(III) chloride, which shows that the molecule actually binds in an octahedral fashion, where two additional chlorides from neighboring molecules bind in a bridging fashion. This is a type of bonding that is typically not discussed until one's third year of chemistry education. Valence shell electron counting works really well for identifying "stable" electron configurations of ions and covalent molecules made out of lighter elements (C, N, O, for example). The presence of d-orbitals, plus the ionic nature of the interaction between Fe(III) and chloride ions, plus the Lewis acid/base concepts that do a better job at describing and rationalizing bonding in transition metal complexes, makes the concept of valence electrons not the best model to explain bonding in $\ce{FeCl3}$.
{ "domain": "chemistry.stackexchange", "id": 561, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "ions, bond", "url": null }
electromagnetism, electrostatics, classical-electrodynamics, boundary-conditions Title: boundary condition of perpendicular component of electric field of a thin sheet This question is in reference to Introduction to Electrodynamics by David Griffith
{ "domain": "physics.stackexchange", "id": 49318, "lm_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, electrostatics, classical-electrodynamics, boundary-conditions", "url": null }
openni, rosdep, openni-launch, osx Title: openni_launch rosdep on OS X rosdep seems to know about openni_launch, but the formula ros/hydro/rgbd_launch is not there. Is the formula supposed to be there, or is rosdep wrong? I'm on OS X 10.9 Mavericks with a desktop-full install of ROS hydro. $ rosdep install --from-paths src/openni_launch --ignore-src Error: No available formula for rgbd_launch Please tap it and then try again: brew tap ros/hydro executing command [brew install ros/hydro/rgbd_launch] Error: No available formula for rgbd_launch Please tap it and then try again: brew tap ros/hydro Searching taps... ERROR: the following rosdeps failed to install homebrew: command [brew install ros/hydro/rgbd_launch] failed Originally posted by demmeln on ROS Answers with karma: 4306 on 2013-12-10 Post score: 0 The problem is likely that rgbd_launch is missing from your workspace. To understand why it failed like this, you have to understand the process through with rosdep goes when resolving dependencies:
{ "domain": "robotics.stackexchange", "id": 16407, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "openni, rosdep, openni-launch, osx", "url": null }
c#, singleton, reflection, rubberduck } } That gets you down to 6 constructor arguments in one step :)
{ "domain": "codereview.stackexchange", "id": 13268, "lm_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#, singleton, reflection, rubberduck", "url": null }
ros, gazebo, simulation, ros-melodic <pose frame=''>0 0 0 0 -0 0</pose> <geometry> <box> <size>0.1 0.1 0.1</size> </box> </geometry> <surface> <friction> <ode> <mu>1</mu> <mu2>1</mu2> <fdir1>0 0 0</fdir1> <slip1>0</slip1> <slip2>0</slip2> </ode> <torsional> <coefficient>1</coefficient> <patch_radius>0</patch_radius> <surface_radius>0</surface_radius> <use_patch_radius>1</use_patch_radius> <ode> <slip>0</slip> </ode> </torsional> </friction> <bounce> <restitution_coefficient>0</restitution_coefficient> <threshold>1e+06</threshold> </bounce> <contact>
{ "domain": "robotics.stackexchange", "id": 35761, "lm_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, gazebo, simulation, ros-melodic", "url": null }
# Factor theorem ## Recommended Posts I want to use the factor theorem to find the factors $2x^3+x^2-13x+6$ How do I do that? ##### Share on other sites What does the factor theorem say? From there the usual thing to do is try to make an educated guess at one of the possible roots. Think about this carefully. Whatever the factorisation of this is, the parts that have nothing to do with x must multiply up to 6. This will give you some ideas of what to try. ##### Share on other sites It says that $x-r$ is a factor of a polynomial $f( x)$ if $f( r)=0$ Edited by Chikis ##### Share on other sites Right, so you need to find an 'r' such that f[r] =0 and then you know you can write you polynomial as (x-r)(ax^2 + bx +c). So try a couple of values for 'r' and see if you can find one root. From there you maybe able to factor the quadratic or apply the factor theorem again... or it may not factor (over the reals). ##### Share on other sites What is 'r' and what is $f( r)$
{ "domain": "scienceforums.net", "id": null, "lm_label": "1. YES\n2. YES\n\n", "lm_name": "Qwen/Qwen-72B", "lm_q1_score": 0.9859363746096915, "lm_q1q2_score": 0.8299865208358794, "lm_q2_score": 0.8418256412990657, "openwebmath_perplexity": 652.2290077455093, "openwebmath_score": 0.46370846033096313, "tags": null, "url": "https://www.scienceforums.net/topic/94650-factor-theorem/#comment-917452" }
ros, video, webcam Title: streaming video from a ros topic to a client browser I want to stream live data from my robot to the internet. Right now I have a ROS node communicating with a webcam and publishing Image/CompressedImage data. The robot needs this data to follow lines/recognize obstacles. I'm trying to figure out how to have the data be sent to show up in a browser in realtime video. I'm not sure on the best way to go about this. I could have the computer running ROS also be running a server, copying jpeg/png CompressedImage data to a file, then have a client connect to that server to periodically poll for the image and update its page to simulate video.. Is there a more common/better approach? Originally posted by robzz on ROS Answers with karma: 328 on 2012-10-19 Post score: 1 You are possibly interested in the mjpeg_server. Originally posted by SL Remy with karma: 2022 on 2012-10-20 This answer was ACCEPTED on the original site Post score: 2
{ "domain": "robotics.stackexchange", "id": 11443, "lm_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, video, webcam", "url": null }
vba, excel Public Sub GetIngredients(ByVal targetSheet As Worksheet, ByVal mealList As Variant, ByRef IngredientList As Variant) Dim mealIngredients As Variant Dim quantity As Long Dim ingredient As String Dim listIndex As Long Dim listPosition As Long Dim mealName As String Dim mealIndex As Long
{ "domain": "codereview.stackexchange", "id": 30316, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "vba, excel", "url": null }
actuator, manufacturing, air-muscle Title: What are the materials and methods used to build ROMAC artificial air-muscles? So, I was reading about pneumatic artificial muscles, and to my surprise I found that there is a lot of types of air-muscles. One that called my attention was ROMAC artificial muscle: In this article it is said: "The flexible walls of the ROMAC are not designed to work as elastometers. Rather, the geometry of the individual pyramid elements allows for greater contraction. Additionally, the wire restraining cables and pyramid elements are combined into a "single surface" actuator designed to eliminate sliding friction during contraction, reducing wear on the soft parts and extending service life." In this other article (page 7) is said:
{ "domain": "robotics.stackexchange", "id": 2541, "lm_label": null, "lm_name": null, "lm_q1_score": null, "lm_q1q2_score": null, "lm_q2_score": null, "openwebmath_perplexity": null, "openwebmath_score": null, "tags": "actuator, manufacturing, air-muscle", "url": null }