What is the fastest Area 51 proposal to reach the Beta stage?

Question: The site proposal Proof Assistants has gone from Definition to completing Commitment in just over three days. Has any proposal (whether it managed through Beta or not) achieved this in a shorter duration?
Comment: [This Tweet mentioning the proposal](https://twitter.com/andrejbauer/status/1461809941778419716) got quite a bit of attention.
Comment: What is the story behind this? This must have been organised outside Stack Exchange (especially when it is so narrow and specialised as this). Who, how, where, when, and what?
Comment: @P.Mort.-forgotClayShirky_q my guess is group of people using social platform to communicate, e.g. Facebook group, WhatsApp, etc, and acting together to achieve their goal. That's the only way to have a proposed site reach Beta in these days.
Comment: It'll take some time to reach beta. Typically, beta launches are approved on Thursdays with the actual launch taking place on the following Monday or Tuesday, but this Thursday is a holiday here in the U.S. (Thanksgiving day).  As such, it likely won't be launched until at least December 6.
Answer: How about a programmatic solution?
<code>function sleep(ms) {
  return new Promise(resolve => setTimeout(resolve, ms || DEF_DELAY));
}
async function getMinimumTime() {
  var proposal = 1;
  var done = false;
  var minimumTime = Infinity;
  var minimumPost = null;
  while(!done) {
    await $.ajax({
      type: "POST",
      url: `https://area51.stackexchange.com/proposals/${proposal}?phase=commitment`,
      success: function(proposalRawBody) {
        var proposalBody = $("<html>").html(proposalRawBody);
        if(proposalBody.find(".phase-name").text() != "Definition") {
          var proposedDate = new Date(proposalBody.find('.label-key:contains("proposed by")').parent().find(".label-value:first > span").attr("title"));
          var committmentStartDate = new Date(proposalBody.find('.label-key:contains("first commit")').nextAll().filter(".label-value:first").find("span").attr("title"));
          var timeBeforeCommitment = committmentStartDate - proposedDate;
          if(!Object.is(timeBeforeCommitment, NaN) && timeBeforeCommitment < minimumTime) {
            minimumTime = timeBeforeCommitment;
            minimumPost = proposal;
          }
        }
      },
      error: function() {
        done = true;
      },
      ajax: false
    });
    ++proposal;
    await sleep(500);
  }
  return minimumPost;
}
</code>
Go to any area 51 page, paste this in the developer console and wait about 10 hours while it searches every proposal for the smallest time between the proposal and the first commit.  I'll edit in the results when it finishes running.
Comment: You seem to be measuring the fastest a proposal went through the definition phase. The commitment phase is a second step _before_ the private beta begins. The question is asking for the quickest proposal to reach Beta, not to reach Commitment. And while a "private beta start" date is available on the beta tab, this can be trickier to gauge given that there can sometimes between 1-3 weeks between commitment reaching 100% and a proposal actually going into beta due to various factors in company planning. E.g. this particular proposal is _not_ private beta yet, as they are still waiting.
Comment: Is there something wrong with this post?
Comment: @animuson Should this measure the end of the commitment phase, then?


Export OpenCms' article to Wordpress

Question: I have a website uses OpenCms (http://www.opencms.org).
Now, I want to replace it by Wordpress (http://wordpress.org).
How to export article from old site (OpenCms) to new one (Wordpress)?
Sorry for my bad Endlish!
Thanks!
Answer: OpenCms has a static export feature which exports all the pages to the filesystem, this could come in handy. You can find it under "Administration View  >  Database Management  >  Start Static Export".

Export OpenCms' article to Wordpress


Mongod not working but data exists

Question: I am running a Homestead virtual box. I installed mongodb recently and was able to type mongod and it would load as it should. Now though I get an error saying dbpath /data/db does not exist. The typical solution for that is to create /data/db and set the proper permissions. The problem is that I already have data, just not in that location. My site is able to connect to mongodb and access information...
I noticed my .0 and .ns file, which I assume are my data files, are actually saved in /var/lib/mongodb as well as a mongod.lock file
I tried setting my dbpath using "mongod --dbpath /var/lib/mongodb" to which I get an error:
exception in initAndListen: 10308 Unable to create/open lock file: /var/lib/mongodb/mongod.lock errno:13 Permission denied Is a mongod instance already running?, terminating

I've tried stopping mongod and then running the --dbpath command which produced the same error. I've also tried running in sudo
Answer: I decided to keep this up in case someone else runs into the same problem. The problem was that I was using:
mongod

when I should have been using:
mongo

Mongod not working but data exists


Will a ball attached to a string keep revolving without external forces acting on it?

Question: Will a ball which is connected to a pivot through a massless string keep revolving after it is made to perform uniform circular motion? What will be the role of tension in it? Will it (tension) draw the ball towards the centre, or will it provide the centeipetal force? If tension indeed acts then is there a force that balances it?
Comment: In the absence of friction it will keep revolving for all of eternity.In reality that doesn't happen, of course.
Comment: What role does the tension will play in it?
Comment: The horizontal component of the tension provides the centripetal force, needed to keep the ball on its circular trajectory.
Answer: The tension keeps the ball from flying off in a straight line in some direction. You could think of tension like the effect the sun's gravity has on the earth- it keeps it in orbit.
Comment: the 'stupid' refers to me, not you...
Answer: An easy way to think of tension is that it would be the sum of forces required to keep the rope at the same distance from the pivot as it was. In this case the tension should be equal to the centripetal force. Here are some cases to consider,
if, $$ T - mw^2 r \geq 0$$
then, the object would accelerate inwards and
if, $$ T-mw^2 r \leq 0 $$
the object would accelerate outwards


Lower MSE results in less profit when using Machine Learning

Question: When using Machine Learning for predicting stocks, can a lower Mean Squared Error result in less profit after Backtesting or is there a mistake in the experiment?
Comment: It can. Good forecast doesn't mean neither big profits or frequent ones.
Comment: @LisaAnn So the loss function doesn't mean more accuracy? What's the solution?
Comment: The problem is that your trading model could not be able to properly exploit your forecast model accuracy. The solution is making your trading model performances more dependent on your forecast model accuracy.
Answer: My answer to a similar question on the Cross Validated forum link here might be useful. In a nutshell you need to optimise for profit and not MSE - the two are not necessarily one and the same.
Comment: So your suggestion is a custom loss function?
Comment: custom loss is generally very diffucult to implement as it should be smooth/convex function  so usual gradient descent methods to work well. PNL is very noisy , therefore training model on PNL would be very diffucult. But it can be used as out of sample benchmark to prefer one model over another.
Comment: @Adb100 A custom loss function is one solution; others are weighting your training example training losses in proportion to size of move and/or eliminating training examples with moves below a threshold value.
Answer: It can , it depends on your trading strategy.
Let's say model1 predicts relative return as 0.1 for next day
and model2 predicts relative return as 0.3, while actual return is 0.15.
Model1 has lower RMSE error.
If your trading strategy is to buy when model predicts positive next day return,and do so in volume proportional to model prediction, then you would buy more asset in model2 case, even if accuracy is lower.  but you will make more money in this case. i.e. PNL of model1 would be less than PNL of model2.


Ender V3 SE middle of print bed sticking but fine elsewhere

Question: Recently got an Ender V3 SE and new to 3D printing. I am having issues where the prints are sticking hard to the middle of the print bed and are difficult to remove, often with damage to the bottom. If offset anywhere else on the bed, the prints are fine. Wondering if the build plate has an issue
Answer: Consider to measure the nozzle distance from the bed at the "normal" points, those at which you have no release problems and compare that distance to the points at which the release is difficult. It's not out of the realm of possibility that your bed has a substantial enough distortion to cause the nozzle to too-heavily bond the filament to the bed.
If you're willing to put a bit more effort into the solution, you can install Octoprint on just about anything and run the Bed Level Visualizer which will present a color graph representing the flatness of the bed. Image below from linked site:

It's important when running this program to note the scale for the axes. The linked image shows rather large scale which presents a fairly distorted bed, but I've seen similar images in which the scale was one-tenth or one one-hundredth of this image. As a result the distortion is relatively severe, but absolutely measured, quite insignificant.


Why are players required to record the moves in World Championship Classical games?

Question: I understand that in some lower-level games, if the players do not record the moves, nobody else will do it for them. But what is the point of requiring the players at World Championship classical games to record the moves? After all, they can easily hire somebody else to do the job and let the players just focus on making the moves.
Comment: You're assuming that recording the moves is somehow distracting to the players.  In fact, they have been recording the moves in thousands of games for their whole life, and it would probably be more distracting for them to NOT be recording the moves.
Comment: Not just additional hiring, but there are already a lot of cameras recording the game.
Comment: They don't even need to hire someone. The boards are electronic, and the moves are relayed automatically.
Answer: To my understanding there are a few reasons to require the players to record the moves. However, I believe that most of them could also be solved with a sufficient technological investment.

Tradition: Chess has a rich history, and recording moves has been a part of the game for centuries. This tradition is preserved at the highest level to honor the game's roots and maintain continuity.
Move Number Recording: A technical reason is that the players can easily keep track of the move number themselves that way, so that they know when they get the additional time at moves 40 and 60. The same argument could be made for three-fold repetition, which needs to be claimed instead of automatically taking effect, but I would suggest that it is not that easy to see from the record sheet.
Legal Record Keeping: The fact that the physical record is signed by each party at the end gives it the semblance of a legal contract, which gives the players a sense of responsibility and fair play, although that argument is clearly weaker at the championship level, where this would be taken for granted anyway.
Tier System Avoidance: At some level of professional play, the record keeping rule would need to be relaxed, introducing a tiered system, where one tier has to keep physical records and the other one does not. In general, many professional tournaments could then also relax the record keeping requirement, but at which level exactly would you then drop the requirement. Should the Candidates tournament, which is also very prestigious, drop the requirement? I think that ambiguity goes a long way in explaining the requirement.

I do not think that there are any technical reasons for maintaining the record keeping requirement. However, the sociological and convenience reasons lined out above probably pushed the arguments in favor of not dropping the record keeping requirement even for the world championship.
Answer: In addition to the answer already given, I would add:
To provide a paper-trail in case confusion or disputes arise.
There have been many cases of illegal moves or disputed moves during top-level play, especially involving the touch-move rule or during time pressure. For instance, the Kasparov touch-move incident against Polgar during the 1994 Linares tournament was a famous top-level incident.
In such cases, it can be helpful to have documentation of the game so far, according to the players themselves. Consider a situation where a piece is placed on the border between two squares, and a dispute arises between the players as to which square the piece was moved to. Having the players themselves document which square the piece was moved to provides a canonical record of the moves, which wouldn't otherwise exist.
This documentation is of peak importance in the highest-stakes games, where accurate arbitration of disputes is essential.
Comment: @Abigail Suppose someone played Qa1, and both players recorded that, but they placed the Queen weirdly. Then based on the opponent's next move, it's revealed that Qa1 was a blunder, and Qb1 would have been much better. Now, the player claims they played Qb1 all along.
Comment: If there is a dispute on which square a piece is placed when placed on the border, both sheets will have recorded a different square. It's hard to imagine how the different recordings are going to solve the dispute. Same for the touch move incident. I doubt any player is going to record "I touched my Queen, but played Ra1 instead". Note also that if there are just a few minutes left on the clock, the requirement to record moves is lifted until time has been added to the clock.
Comment: The question ha very difficult answer nowadays.. players cannot defy the techmology


Custom Latest News Module?

Question: i'm new to Joomla! but I really like it, i'm working on 'migrating' a website template to Joomla. This is how the template looks like NerdyFuture. It's not finished yet but i planned on finishing it in Joomla, so i want to have the latest news exactly how it is in the template. How can I achieve this?
Answer: The default Joomla module mod_article__latest can be used as the Latest News module. So once you have your articles setup, you will then need to start the styling.
Step 1 is to create a template override for this module. This will allow you to use your own styling for a module without editing any core Joomla files. Here are the steps in simply terms:

In your template folder, create a folder called html and then inside that, create a folder called mod_articles_latest.
Copy this file: modules/mod_articles_latest/tmpl/default.php to your newly created folder.

Now that you have your file copied, you can start editing it accordingly and merging your styling with it.
Comment: @NerdZilla - If this answered your question fully, please mark it as accepted to other know it has been solved

Custom Latest News Module?


Delay + 'Click' in Garage Light Switch Since Getting Cold

Question: When I turn on my (non-insulated) garage lights (LED), there is a 2-4 second delay. After 2-4 seconds, I hear a solid "click" from the light switch, and then the lights come up. The click sounds almost like the tension in a piece of metal being released. The delay only started recently, since it's started to get very cold (<0F), but I'm not sure if that is a coincidence. Do I have a serious problem with the switch/wiring, or is this just a symptom of an old switch and the cold?
Comment: Does it do this on every actuation of the switch? If you stand there and actuate it several times in a row then does it keep producing delays?
Comment: Tell us more about your light switch.  It doesn't sound like a *plain* 50 cent light switch, since those are not capable of that.
Answer: Buy a new light switch and leave it in the garage overnight.
In the morning try turning it on.
If the existing switch still delays but the new one does not then I would just replace it. This of course assumes you have the tools/confidence to do so.
Answer: It's probably just a bit of drag in the sprung toggle switch, which could be exacerbated by the cold.
Quick fix…
with the power off , spray into the mechanism with some contact cleaner [if the pull-switch has a threaded or simple to remove cover, take it off first]; pull the switch a dozen times or so. You should be able to hear a slight difference between the on click & the off click, each of which can be separate to the 'pull' click - some switches operate by spring on the return rather than on the pull itself, but all will have a toggle mechanism so one action produces two results. Keep going until both clicks are immediate. Give it another 15 mins to be sure the cleaner has evaporated, then power back on.


Samsung netbook NP300E5A dimming on battery

Question: My Samsung netbook NP300E5A screen is continually dimming.  The screen is forty percent dim on battery, but if I plug in the charger, the screen will be normal. I have tried all I know and I could not fix it. What should I do? what am trying to explain  is that the system is dimming like flooricent light  the screen resolution systems are all ok. When I pluging my charge the dimming we stop but when is on battery it look like flashing someone  light when driving
Answer: You most likely have your power or display settings located in Control Panel set to have your screen dimmer when it is not connected to the charger.
That would make sense because the screen being less bright = more power conserved. When the computer is plugged in, it doesn't matter because it is actively charging thus, it can use as much power as it would like.
So, to resolve this navigate to Control Panel > Power Options > Change Plan Settings > Click Change Advanced Power Settings > Expand the Display section, then expand the Enable Adaptive Brightness option. You can turn this off or on, and as I stated earlier, it is for conserving power.
Comment: Thanks for d reply, what am trying to explain  is that the system is dimming like flooricent light  the screen resolution systems are all ok. When I pluging my charge the dimming we stop but when is on battery it look like flashing someone  light when driving


What were Plato's view on slavery, in particular with respect to his proposed Utopia?

Question: In the Dialogues(specifically The Republic), when he is discussing his Utopia, At one point, he does say that children should not be treated differently based on their parent's status in life. However, I did not see any mention of slavery in this discussion, so I want to know what did he propose about the practice of slavery in his Utopia? Also, what were his views of Slavery in general?
Comment: His Utopia is the earliest recorded example of the type of horrid Dystopian totalitarian states as further explored in books like "[We](http://en.wikipedia.org/wiki/We_%28novel%29)", "[Brave New World](http://en.wikipedia.org/wiki/Brave_New_World)", "[Kallocain](http://en.wikipedia.org/wiki/Kallocain)" and movies like "[THX 1138](http://en.wikipedia.org/wiki/THX_1138)". As such, he treats pretty much everyone except the rulers as slaves to the state. How you want to interpret that in terms on what his "views" were is up to you I guess. I assume he wanted the world to be his slaves, simply put.
Comment: @Joseph Weissman. Hi, Joseph. I hope to answer tomorrow. In the meanwhile  have you noticed the reference to slavery in Republic, VIII. 569a-c where Plato says that in the most degenerate stage of political decay, that under the tyrant, all citizens are reduced to a state of slavery (douleia) ? Ref : Sir Desmond Lee, 'Plato : The Republic', Penguin, 2nd. ed. rev., 1987, 391.
Comment: I expanded the comment into an answer.
Comment: You might want to consider published scholarship on this question (which is controversial among scholars): http://www.jstor.org/stable/267583 and http://www.jstor.org/stable/638835, for example.
Comment: @Joseph Weissman. I realise that you are interested in Plato's views on slavery particularly in the perfect state. So I might face the reply : what has slavery in the worst form of  state to tell us about slavery in the best? Something, I think. Tyranny, the worst form of state, is the exact antithesis of the perfect state. If all citizens are slaves in the worst form, it's not an unreasonable inference that none are in the best. However, I think Lennart Regebro is right that in a sense all citizens except the guardians are slaves in the perfect state. References to follow in Answer.
Comment: I understand slavery was a deeply entrenched institution in classical antiquity, a norm and never questioned (abolished). Brief extract on the subject: https://www.cambridge.org/core/journals/classical-quarterly/article/abs/slavery-in-platos-republic/93248BB9FD28F79BE46E3B676653B6B3
Comment: I think that the Platonic Utopia entails a hard but steady progression from compulsory master-slave relations to voluntary teacher-student relations, the highest teacher being not a human but the idea of Good.
Answer: There is no special cast called "slaves" in Platos Utopia. Instead all children are given to the state to be brought up and given work as the state sees fit once adult. Hence, almost everybody are slaves. ref Although all people are "citizens" these "citizens" have no rights, only obligations, and no freedom at all except for the absolute upper part that rules the city.
Plato wishes to abolish freedom, and hence in our terminology make everybody slaves. He tries to cover this by claiming that rulers are enslaved (by responsibility and fear of those who rules over) and in pure NewSpeak claim that freedom leads to slavery. (ref: The Republic)
In Platos later 'Laws', he describes another city which he thinks is more realistic, and it does have a separate slave cast. ref
Platos view of slavery was therefore quite clearly very positive. But he knew that the word was negative, and therefore tried both to associate things he did not like, primarily freedom, with the word slavery, and also tried to excuse tyrannic rulers by claiming they actually were slaves to the people. But people that we today would call slaves, are people he wanted many of in his ideal states.
Comment: -1 This answer is unnecessarily emotional and hyperbolic. It relies on a simplistic understanding of Plato's Republic and interprets it in the worst light.
Comment: There is neither emotion nor hyperbole in my answer. It's purely factual. A "simplistic" understanding, is likely to be anything that actually understands and takes Plato at his words, instead of trying to smooth his totalitarian ideas over. I can understand the desire to try to make Plato palatable for today, he was very influential in history, and it can be hard to accept that throughout most of the history of philosophy philosophers revered a man with such terrible ideas. But such is life.
Answer: A knife is good, he said, when it cuts efficiently, that is, when it fulfills its function.
The assignment of all people to their respective classes would come only after extensive training and only those capable of doing so would progress to the higher levels. Although theoretically all people would have the opportunity to reach the highest level, they would stop in fact the level of their natural aptitudes.
This implied that by nature some would be rulers and others craftspeople, and would provide the basis for a perfectly stratified society. Whereas later societies in Europe assumed that children born into such a stratified society would stay at the level at which they were born, Plato recognized that children would not always have the same quality as their parents. He said, therefore, that among the injunctions laid by heaven upon the rulers there is none that needs to be so carefully watched as the mixture of metals in the souls of children.
If a child of their own is born with an alloy of iron or brass, they must, without the smallest pity, assign him the station proper to his nature and thrust him out among the farmers and craftspeople. Similarly, if a child with gold or silver is born to craftspeople "they will promote him according to his value."
Most importantly, Plato thought that everyone should agree on who is to be the ruler and agree also on why the ruler should be obeyed.
Comment: Though true, this does not answer my question. Yes, these facts he states may mean that he did not support slavery but neither is it stated explicitly. And since Athens was dependent on slaves, and a common attitude then was that slaves are inferior to freemen, it's not obvious what he wanted their role in Utopia to be.
Answer: First of all Plato's Republic which you mention as Utopia has many parts taken from existing cities and legislations specifically Sparta and Crete.
Concerning your comment on slavery. Broadly speaking Plato belonged to the Athenian Aristocracy. He believed, and is evident in the Republic that not all men are created equal. In the Republic, there is no explicit mention of slaves per se but, men are separated in 3 distinct divisions depending on their personal merits.
One thing to note here, since the concept of slavery in Greece has been misinterpreted by a lot, is this:

The king in Plato's Republic is the absolute best. The best in all aspects. The best warrior, the best philosopher the most capable person by any standard.
There are no hereditary rights to powers. I.e. the children of the division of the warriors do not necessarily stay in that division. If they are not fit to be warriors, they might fall into the division of farmers.

So to answer your question, division 3 is the division that is somehow the slaves of Republic since all they do in life is work to feed themselves (and families) of course but to feed the other 2 divisions (the republic's elite) as well.
This is not far from what slaves did in Ancient Greece since their treatment was not as you imagine or happened in Egypt or elsewhere.
Also note on this that slave in Greece is δοῦλος which is the root of today's word for work in Greek.
Comment: "This is not far from what slaves did in Ancient Greece since their treatment was not as you imagine or happened in Egypt or elsewhere." I'm not exactly sure what you mean here, but if you mean to say that Greek slaves did not suffer, then the slaves who worked the silver mines at Athens beg to differ. Many Greek slaves suffered horrific conditions of work and treatment.
Answer: As an advocate of meritocracy, I think it is obvious that Plato was not pro slavery, since slavery is antithetical to meritocracy.
Also the third class in his Republic is clearly free compared to a chattel slave who is property and their children will be property too.
Despite ridiculous answers here such as: everyone is slave to the state according to Plato, by people who obviously don't even know the title of the book they're referencing so they call the 'Republic', 'Utopia' instead...it is quite clear, even on a superficial reading, that the third class in the 'Republic' is an equivalent of workers or the proletariat, but with greater opportunity for their children to be something more.
Comment: Rather than simply asserting what you think it obvious, this answer could be improved with some citations.
Comment: But Plato didn't advocate for meritocracy. He was anti-democracy. And The Republic explicitly advocates a hereditary aristocracy - one he admits is based on a lie. See: 'Slavery in Plato's Thought' https://www.jstor.org/stable/2180538 And: 'Slavery in Plato's Republic' https://www.jstor.org/stable/2180538 And consider Popper's critique of him as 'an enemy of the open society'. He was a proto-fascist, fundamentally, who saw most humans as means to the ends determined by philosopher-kings - that's entirely compatible with slavery.
Comment: Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-ask).


Is the time code a way to reduce paper work when it comes to logs?

Question: So a clock can listen to a station WWVB to update time.
My question is:
Could you use the time code to mark your logs in conjunction with a recorder thus doing away with paper logs all together.
Comment: No duplicate, but of interest, maybe: [alternatives to shut down WWV* services](https://ham.stackexchange.com/questions/11816/wwv-wwvh-and-wwvl-may-be-shut-down-are-there-any-alternatives)
Comment: @MarcusMüller actually its still going i called number listed in the book from 75. i need to get a more modern handbook preferably from the 80s.
Answer: The FCC no longer requires amateur stations to keep a log. So if you wish to reduce paperwork, a trash can is probably the best piece of equipment to employ.
People that keep logs for other reasons (often contesting, or just personal interest) these days often use some software to do it which will automatically populate the time based on the computer's clock. The computer's clock is often set by NTP: network time protocol.
GPS receivers provide another possible source of time, especially useful when the station won't have internet access. GPS receivers are more ubiquitous, cheaper, and more accurate than WWVB receivers. Many people carry one in their pocket in the form of a smartphone, which conveniently can also run logging software.
Answer: The times in your log needs to be approximate. having a few minutes of error is not usually issue. Many software logging programs will automatically use the time from your PC.
When logs are used to confirm contacts a few minutes difference is accepted. The exact difference allowed will vary depending on the service being used. I believe Logbook Of the World will accept up to a 10 minute difference and still confirm the contact.
Having said that, some digital modes like FT8 and FT4 require time to be accurate to within a couple of seconds. as these are digital modes that require a PC, it usually more convenient to use software to synchronize to network time servers instead of sources like WWVB.
For portable digital mode some operators use GPS timing signals.
Comment: GPS has the additional benefit that you can use a GPS receiver to get a *very* good clock signal


A tool that migrates data from database A to B has been developed

Question: A tool that migrates data from database A to B has been developed. The tool will be used to migrate all production data from version 1.0 of our app (operating on A) to version 2.0, currently being developed (operating on B). The schema may differ between each other. How are you going to make sure the application is working after migration? Provide your test strategy and sample test cases.
Comment: Welcome to SQA, nakul garg.  If this is a homework/interview question, you should provide some evidence that you tried to work out the question on your own.  If it is not a homework question, please provide specific details such as the database vendor and the framework that the tool is built on top of.
Comment: -1 because you copied it directly from my answer, without even citing me: http://sqa.stackexchange.com/a/7463/1933
Comment: A complete answer? I attach my bank account number as well, ok? ;)
Comment: StackExchange is not for demanding homework / interview answers.
Answer: I would suggest that the most risk would be in the areas that change schema.
As a first step ask for a data migration plan.  That is, a mapping from the current schema to the new schema.  You can then verify that the database was migrated as expected from a data point of view.
In order to test this aspect properly you will need business domain knowledge of how the application works and which functions access this particular data.  You should focus your testing around the application functions that access this data.
For the data that has not changed schema, I would suggest that a comparison/diff of the data from the original to the migrated database be done to verify that no data has been inadvertently changed.  This should include both the data and the data model/schema.
You labeled this manual-testing.  However, for such a change it would be nice to have an automated set of regression test cases for added confidence that the application can still read/write to/from the new database.
This is of course a simplified answer of a simplified question without much detail.  In the real world, you would be worried about stored procedures, triggers, etc. and again the functionality that hinges from it.


Are there any Easter eggs or hidden areas in Bad Piggies?

Question: I see the levels in Bad Piggies are littered with what could be hidden areas or treasures. They look nearly impossible or very difficult to reach. Anyone had any luck reaching any of these areas?
Answer: I've retrieved all the skulls and nothing happened. There's only "secret" level when you find 10 skulls. I also have all stars in all levels (even the 5 sandbox) and nothing happened
Answer: In a lot of levels, there are hidden skulls that can be retrieved.  These skulls usually have to be retrieved by making a different contraption than that that would complete the level.  Make sure to zoom out and look around at the beginning of each level.
Besides the unlockable levels with the star requirements though, that's it.  I've tried (and succeeded) in hitting the message bottles and other random objects in the sand, but nothing has happened.
Once you retrieve all the skulls, a hidden level will be unlocked.


Change Base Shapekey without changing the other shapekeys

Question: I started adding shapekeys and then noticed I want to edit my basemesh. Unfortunately the changes in the base shapekey affect the other shapekeys. Is it possible to change the base shapekey and not have it affect the other shape keys?
Comment: Have you tried using hooks instead?  In Edit mode, select the vertice(s) concerned, press CTL-H and select "Hook to New Object".  An empty will appear at the vertice which is in effect an object and can be keyframed.  Changes made later won't (or shouldn't) affect it's other keyframes.  The drawback is that you have to make another central empty and parent the model to that if you're to move the model about.  Also parent the hook to this empty.
Answer: Try this:
Two objects with the same vertices will be required. So make a copy before you change basis of one of the object.

Make modification to the basis.

Create a new shape key on the object with modified basis.

Select the newly created shape key for the object with modified basis.

Select the shape key you want to keep the old position from the object with original basis.

Object Mode: select object (original basis) then shift select object( modified basis)

On the shape key drop down menu select "Join as shapes"

A new shape key will be created with the old position.
Answer: If you edit the basis then it will change all the following shapekeys but to change the other ones without it editing the basis you have to so it in edit mode
Answer: Maybe this could help :
https://www.youtube.com/watch?v=sTY7xTWB6-o
He shows how to update your current shapekeys, including your basis
Answer: Possibly not the best way to do it, but what I did was:

Make a new intermediate parent shapekey off the basis blendshape, parented to itself
Parented all of my existing shapekeys to this intermediate parent
Modified my basis blendshape accordingly (in this case, doing "blend from shape" from the blendshape I wanted to swap to the basis shape)
Parented the intermediate back to basis

This seems to have worked correctly, and allowed me to preserve the original blendshape as well.
Answer: I just figured it out... Before making changes to the Basis, change the "Relative To" option to the shape key itself. Then select the icon to edit and tab into edit mode modify the Basis, tab back out of edit mode, then change back the "Relative to" on the shape key back to Basis. I am using Blender 3.3.0


How do SSL certificates become compromised after expiring

Question: I'm reading into security issues surrounding SSL, and one of that has come up is certificate expiration. The general idea is that once a certificate expires, the site is insecure. What is the difference between an expired certificate and valid certificate, seeing as they both still encrypt the data? What allows an attacker to compromise an expired certificate that he couldn't do a valid one?
Answer: There is not much difference between a valid and expired certificate in the SSL/TLS communication. Both case will allow the communication in a safer way and also the same level of data transmission. Even the certificate is expired , the keys are valid until its compromised. Here the point is that the level of trust to the client. But as a Standard SSL protocol part of verification, the client or server need to do.


Why is inode size fixed?

Question: I'm reading about file systems and storage medium and I can't understand why if I create a one block size file I can't have a smaller inode than a one of a bigger file.  Can't the OS dynamically choose the inode size according to the file size?
Answer: One reason for inodes to be fixed-size is that in the traditional Unix filesystem format (which e.g. ext4 still follows pretty closely), the inodes are stored in what is essentially a single table. With fixed-size items, locating an item based on its index number is trivial. With any other data structure it would require more work, and perhaps more importantly, more random-access reads across the data structure.
The size of the file itself doesn't influence the inode itself, which traditionally stores the location of the first couple of data blocks. For longer files, the system allocates extra blocks (indirect blocks) to hold the locations the rest. (See the wikipedia page for a pretty picture.)
I said "traditionally", since e.g. ext4 actually does things differently, it can save the contents of symlinks in the inode itself (they're often short, so it's useful to not allocate a full block), and the traditional tree of single blocks is replaced by a tree of extents, i.e. spans of several blocks.
As far as I can tell, on ext4 the reason for supporting inodes larger than the minimum size, is to allow for new fields to be stored, and to use the extra space for extended attributes. Looking at the table in the first link, the extra fields above the original 128 bytes on an ext4 inode mostly store higher precision time stamps. In SELinux systems, the security labels are implemented as extended attributes, so being able to store them directly in the inode can be very useful.
Newer filesystems like btrfs, XFS and ZFS with less orthodox formats are likely to do things differently, and I don't know much about the file systems used on, say BSD systems.
Answer: The inode itself holds file metadata and not any data. As such, it doesn't matter if the size is small or large. Also, inodes exist for things other than plain files. E.g. for named pipes, which have no data at all.
Having said that, the exact format and size of an inode is filesystem specific and can have any kind of behavior the designer of the filesystem wants. For Linux/Unix systems, the filesystem has to be able to provide a minimum set of information in the inode but filesystems can store more than that internally, both on the disk an in memory.
Comment: It may or may not have. E.g. ext2 and XFS have both direct and indirect references. The benefits however of a fixed-size inode outperform any potential space savings. Picture for example trying to read an inode from the disk that you don't know the size of. It will require at least 2 reads (one to get the size and one to read the data), or speculative read ahead, which will both be bad. With fixed size inodes the FS can also accurately compute the inode location within a larger block of data, which is the case for both ext2 and XFS.
Comment: I thought that inodes had a pointers to the data blocks where the file is stored.  So my question was about the number of pointers in an inode related to the number of data blocks within a file is split

Why is inode size fixed?


Why do I always get strength but not muscular gain?

Question: I am going in the gym for some time and I notice that while I improved my strenght and resistance a lot (I can lift heavier weights and for more repetitions) but I don't notice them growing. What am I doing wrong?
Comment: Impossible to say with the information provided. Diet? Length of time training? Specific exercise(s) w/ sets/reps?
Comment: What does your calorie and protein intake look like? How many calories do you eat in a day and how many grams of protein are in those calories?
Comment: It might be worth to try lighter weights with slow controlled eccentric and pause (to take away the stretch reflex) and more reps (10-12).
Answer: Strength is faster and easier to measure than muscle growth. Especially starting out, you can notice changes day-to-day or week-to-week. To measure muscle composition, you need to take a measuring tape and measure different points of your body and record over time. This can be tedious and most people don't do it. You can also take progress photos which is less tedious, but gives you less data.
Muscle growth is done slowly over time so you get used to your look. Similar to how you don't notice a child growing taller if you see them every day. You see yourself every day when you look in the mirror or look down, so you don't notice changes.  If you took pictures of yourself six months ago and compared to now, you'd probably notice some changes.
Muscle growth is obscured by body fat. Lean people can typically see changes in muscle composition. People with moderate body fat levels (greater than 13% in men) will need to lose the body fat to see the muscle definition.
Comment: Deev is spot on here, I highly recommend progress pictures. I started taking weekly progress pictures and measurements a little over 2 years ago. Week to week and even month to month I rarely notice any difference, but if you look at a long enough time frame where you have been consistently working out, I think you will be surprised at how much different you look. If you still don't notice a change, I would suggest looking at your food, and sleep habits.
Answer: Adding on to what DeeV said in the prior answer, remember to focus on the eccentric phase of the lift if you want to maximize size growth.
For example, doing a deadlift and dropping the bar from a locked out position is the wrong way to go about getting growth gains. You lose more than half of the potential growth by doing this.


How to assign a different layout to sub-case or related case

Question: I have a parent case and then related cases. I want to assign a different layout to related cases than the parent case. Is there a way to do that? Can't find any option.
Answer: Layouts are controlled by the Record Type. If your child cases are of a different Record Type, they can have their own page layout assigned.
If you are using Lightning Experience, you do have one additional option. When you build a Lightning Record Page, you may conditionally render specific components based upon field values of the viewed object. While this does not allow you to change page layouts (the Record Detail component), it does allow you to surface different supporting information or component-based functionality based on record values, even if the Cases have the same Record Type.


Can you submit a paper to a journal that contains a paper already accepted?

Question: I have just got a short paper (about 3,500 words) accepted by a top journal and it is currently being copy-edited. Meanwhile I have completed a paper (about 12,000 words) with deeper research that contains the short paper as a whole. The new paper reorganizes and expands on the short paper in a way that improves on the accuracy, although it takes much of the short paper contents verbatim. Then it adds an entirely new section. Is it inappropriate to submit this to a journal?
Comment: I am no sure what "reorganizes and expands..in a way that improves the accuracy" means in this case. However, nothing from an accepted paper should be used verbatim in a new paper. You must rewrite all these sections and cite the short paper.
Answer: It is quite common, to publish a short letter-like paper to a high-impact journal first and then follow it up with a more detailed longer paper expanding on the first one.
However, containing the first paper as a subset is (self-)plagiarism, not original, and not acceptable. You must write the second paper independently, though some similarity of the text is okay, in particular if you state explicitly which passage has already been presented in that earlier paper and are only included for completeness.
Comment: Thank you very much for your replies. By "write the second paper independently" do you mean not to use the same expressions verbatim but rephrase all of them? About citing, I cannot cite the shorter paper in the submission because that would reveal my identity as the author and break the anonymity requirement.
Comment: Are you sure regarding the anonymity requirement? Whose requirement is that? Not citing the short paper is unacceptable, as it would pretend the new submission is entirely original, i.e. this is plagiarism. You should clarify with whoever you think forbids quoting that paper how to proceed.


"Tit for tat"—Where does this come from?

Question: I always ask myself where this saying originates. I only know the individual words, tit and tat, but why is this a saying?
Comment: Tit for tat...you kill my dog....I kill you cat!
Answer: Tit and tat are used here to mean striking a light blow, so the phrase has exactly the same meaning as blow for blow. They were used as both nouns and verbs, as a sixteenth-century rhyme shows:

Come tit me, come tat me,
  come throw a kiss at me.

(Source; An earlier variation has halter instead of kiss.)
I always thought it was a cute mispronunciation of this for that, but apparently it's actually a corruption of tip for tap (Etymonline; concise etymological dictionary), with the same—and, I should think, slightly more obvious—meaning.
Comment: Interesting!  Do you have a citation for that?
Comment: Thanks!  Now I'm at home I can check my (terribly old-fashioned) paper copy of _Chambers_, and it agrees with you entirely.
Answer: An exhaustive derivation from http://www.businessballs.com/clichesorigins.htm:

tit for tat - retribution or retaliation, an exchange insults or attacks - 'tit for tat' evolved from 'tip for tap', a middle English expression for blow for blow, which also meant a trade of verbal insults. Tit is an old English word for tug or jerk. Tat evolved from tap partly because of the alliteration with tit, but also from the verbal argument aspect, which drew on the influence of the Middle English 'tatelen' meaning prattle, (Dutch tatelen meant stammer) which also gave rise to tittle-tattle. Tip and tap are both very old words for hit. (eg 'tip and run' still describes a bat and ball game when the player hits the ball and runs, as in cricket). Tit for tat was certainly in use in the mid-late 16th century. Tip for Tap was before this. As with lots of these old expressions, their use has been strengthened by similar sounding foreign equivalents, especially from N.Europe, in this case 'dit vor dat' in Dutch, and 'tant pour tant' in French. Skeat's 1882 dictionary of etymology references 'tit for tat' in 'Bullinger's Works' . Brewer in 1870 suggests for 'tit for tat' the reference 'Heywood', which must be John Heywood, English playwright 1497-1580 (not to be confused with another English playwright Thomas Heywood 1574-1641). According to James Rogers dictionary of quotes and cliches, John Heywood used the 'tit for tat' expression in 'The Spider and the Flie' 1556.
Comment: Robert Hendrickson, _The Facts on File Dictionary of Word Origins_ (1997) has this additional note on _tant pour tant_ ("so much for so much"): The French phrase _tant pour tant_, with its sense of paying back, also gives us our word _taunt_, "a sharp or clever rejoinder."
Answer: Though etymonline guesses in the way of Robusto's post I would assume that it is related to plattdütsch or Low German where this/dies is dit and that/das is dat. So Low German dit för dat simply means this for that.
I am always astonished that English etymological dictionaries prefer parallels to Old Norse or PIE consonant constructs but seldom mention near similar words in Low German, Frisian, Dutch, High German or Latin, words that are better known than PIE roots.


how to peg an ERC20 token to a stipulated price in other to make it a stablecoin

Question: I'm new into blockchain development and currently challenging myself to create a stablecoin. I have created an ERC20 token but I don't know how to peg the price to the desired price. Please can anyone put me through on how to go about it?
Comment: Can you specify further if this is a fiat-backed stablecoin or an algorithmic stablecoin? Pegging of price usually is out of the control of fiat-backed stablecoin, but for an algorithmic stablecoin, if you have a mechanism to maintain the pegging that could work. However, as far as now, algorithmic stablecoin hasn't worked very well to maintain its peg.
Comment: can you provide further details?
Answer: In most cases this is done with the power of algorithmic bots that can buy or sell tokens and fill the market with more liquidity, pushing the price back to the desired peg.
You can search for repositories through GitHub. Probably you will be able to find good solutions for studying and build your own stablecoin.


How do I teach my kitten to clean feces from itself?

Question: I adopted a kitten, when he was only 1.5 months old (he is now almost 4 months), from his breeder so he didn't know a lot things. So I've had to teach him how to use the litter box and even how to eat from a bowl. However the one thing I haven't been able to teach him is how to clean himself.
He tends to lick himself all over his body but from time to time he gets some poop on his fur which not only makes him dirty, but also my carpets and quilts. Is there a way to make him understand how to clean himself instead of me needing to cut away some of his fur so that the feces falls off?
Answer: You didn't say, but I'm guessing your kitty has medium to long hair.  If this is the case, you will need to take him to the groomers regularly so they can shave his "back end."  Otherwise, it is difficult for your cat to get that area completely clean.
Also, I'm guessing that you're probably still giving your kitten a lot of wet food.  He is old enough to be eating dry kitten food.  Try dry food during the day and a half a can of wet food at night.  This will help solidify his stool so it won't get in his fur.  If you have never given the kitten dry food, you will need to mix the wet and dry together until he gets the hang of it.
Also, remember, kittens usually rush the litter box process because they want to get back to all the fun things they're missing.  I know it's frustrating, but it sounds like you are being very patient with him.  I hope this helps!
Comment: Not all longhairs need their butts groomed on a regular basis, but that is especially true of kittens who are still learning and the elderly who are less flexible. Good points about diet and kittenish distractability. Arguably these should have been part of the basic briefing a breeder gave for care and feeding if someone hasn't adopted a longhaired kitten before...
Comment: @keshlam Very true about the breeder comment.  But not so sure about this breeder, since he/she let the kitten be adopted at 6 weeks.  8 weeks is usually the minimum, and 10 weeks is even better so the kitten has learned what I call "cat law."
Comment: @kittyconsultant:  That was my instinctive reaction, though I've never had one younger than a year. That's another "breeder should have" violated, and suggests one may want to keep an eye on this cat's health over the years since it suggests the breeder is... inexpert.
Comment: Downvoting for the suggestion to solve the issue through dehydration, which may solve this problem but will introduce others. There may be a protein sensitivity; switching to a different wet food can also solidify stools. (Source: a long-haired kitten with a sensitivity to seafood proteins who has been fed almost exclusively wet food most of her life.)
Answer: In my experience a healthy cat or kitten will produce rather dry poop that doesn't stick to the fur. That suggests that your kitten is having stomach issues and may need a vet visit.
Kittens usually have more sensitive stomachs than adult cats anyway, and from what I've seen a kitten with stomach problems is much more likely to have sloppy, messy poop than to throw up - and sloppy, messy poop will stick to fur. Kittens will also be more likely to step in it afterwards (cleaning up after that is not fun!) while they're trying to cover it up.
What I did with the last longhaired kitten I had when she had issues was to start with a box of tissues and use the tissue to "wash" her butt. You might get everything out this way, or you might need to brush/comb the rest out. I recommend doing this when the kitten is sleepy or you'll be trying to clean a squirming ball of energy that wants to play with you. Don't forget to thoroughly wash your hands and the brush/comb after you've thrown the used tissues in the trash.
If there's a lot of poop to clean, you might need several sessions, and if the kitten is having serious stomach issues, you might want to trim the fur there until you can get the stomach problems settled.
A few other thoughts:

there's a difference between a healthy, more or less dry poop hanging from the kitten's butt and poopy mess sticking to the fur. The dry dangler is probably either the kitten rushing the job to get back to the more interesting things or a partial hairball that hasn't been fully passed. If it's a hairball, there'll be kitten fur holding the poop and you'll want to give the kitten hairball treatment.
As others have said, the breeder really shouldn't have given you the kitten so young. You'll want to watch for other health issues.
If your kitten has ongoing diarrhea, you need to see a vet.
Answer: You can try playing momma-cat and "licking" him clean with a damp corner of a sponge or washcloth... but remember that you're still dealing with an infant who's not yet entirely sure that tail is his...
Answer: I also have a five month male I adopted and one and a half mos.  He's busy and can have a stinky bum.  He loves to play with water with his paws and mouth, so I wet his bottom while he does this.  Then he licks his bum, isn't scared acting, just goes on with all his playing.


Branes on a tip of a conifold; how to understand it?

Question: I am not sure if this question makes sense "intuitively" but here it is. In Klebanov-Witten theory one puts branes on the tip of a cone over a Calabi-Yau manifold. My question is what does it mean to put a "D-brane on a tip" which is a singularity? I cannot understand where this tip is spatially located. Nor can I understand if the cone breaks or not Lorentz symmetry in the 10d space.
Answer: It might help to think of obtaining Klebanov-Witten theory in a limiting proceedure. Imagine a dynamical setting where the branes don't start out at the singularity, but instead at some smooth point near the singularity. Then move them to the conifold point. And the conifold point can be located because it's a singular point. If we choose coordinates so that the conifold is at $r=0$, then the metric is
$ds^2 = dr^2 + r^2 ds^2(T^{1,1}),$
which is a cone. Because the second factor isn't a round sphere with unit radius, this has a curvature singularity at $r=0$. The conifold is also often described as the quartic in $\mathbb{C}^4$: $\sum_{i=1}^4 (z^i)^2 = 0$.
The cone doesn't affect the Lorentz symmetry of the Minkowski space. The metric for the full 10D solution looks like
$ds^2 = H^{-1/2} dx_{\mu}dx^{\mu} +  H^{1/2} ds_6^2$,
where in the usual case $ds_6^2 = ds^2(\mathbb{R}^6)$. In Klebanov-Witten (or Klebanov-Tseytlin) it is the space written above with the $\mathbb{T}^{1,1}$ factor.
By the way, the singularity of the conifold in the Klebanov-Tseytlin solution get's ``fixed'' by replacing the conifold with the deformed conifold in Klebanov-Strassler.
Comment: Thanks. This is interesting but I still fail to see the essence of my question. The branes are not supposed to be finite, right? I will try to interpret your answer but I am still confused.
Comment: What do you mean, finite? They extend infinitely in the $x^{\mu}$ directions, and sit at a point in the transverse ones. Ordinarily this point is just a smooth point, and this for example leads to $AdS_5 \times S^5$ as a near horizon limit, but in the case of the conifold they sit at a singular point.
Comment: So I should be thinking of this singularity as a 0 dimensional one over the cone but as a 4-dimensional one (say for D3-branes) on the $x^{\mu}$. This makes some sense now. Do you have some good reference? It would be great, thanks!
Comment: For the purpose of understanding this, I would actually just forget about the brane directions $x^{\mu}$ and think about the D3 brane as a point in the 6-dimensional transverse space. I would think about the fact that D3-branes can be added in superposition to help understand this--if you're not familiar with this fact, it can be found in the review article http://arxiv.org/abs/hep-th/9905111.
Comment: Indeed, the approach you propose indeed looks as a better way to look at it. I know this review not sure if I remember anything about cones though, I ll look at it.


Primary menu items are dissapearing

Question: on my website, www.trutrade.org the primary menu items are disappearing after I click the first time any of the menu items. when I goto the second page, the menu items are not seen, I need to hover on the links and only then I can see the menu's. Can anyon suggest how to make them stay permanent? Thanks.
Answer: It seems that the background color of menu and text color of the menu items is same at https://trutrade.org/abouttrutrade/. That's why, you feel that primary menu items are disappearing. When I add this code, the menu items appear in red color:
<code>a.mega-menu-link {
   color: #f00
}
</code>
So, try changing the background color. It should fix your issue.

Primary menu items are dissapearing


No 120 in my dryer receptacle

Question: I am not getting 120 @ my hot to neutral
 in my dryer receptacle
For my dryer outlet h1-h2 =240,  h1 -n <40  ,  h2-n <20
does this mean that i have no ground at the box?
Comment: No ground?  Wouldn't that just mean that the neutral isn't connected?  You didn't show that you tested the ground.
Comment: Do you have 3-hole receptacle and plug for this dryer or a 4-hole?
Comment: You have an open neutral. The hot lines are reading 240V (phase to phase) . So perhaps the box is defective and you are not able to get a probe on the neutral or there is some other issue with the neutral.
Comment: Measure between your dryer chassis and each phase - be careful not to touch anything .. if you measure 240V .. unplug the dryer .. fix receptacle - if you have 4 wires to receptacle (but only a 3 prong receptacle change it to a 4 wire style and your dryer cord the same. Much safer..
Answer: With no 120 v reading the grounded and or grounding lugs going to a main panel are open. This happens at the outlet quite frequently. I mentioned both because it was not stated if it was a 3 or 4 wire.
Comment: I did say outlet that is more common than the panel because of the stress on the wires when stuffing back in the box, rare to have neutral or ground come out in a panel bus. I worded it that way because some are getting hung up on "proper terms".
Comment: Usually the drum motor is 120 v and the heating elements are 240 so the drum would not turn
Comment: Ed, are you suggesting that the open connection is at the receptacle or is it inside the panel? Should the original poster pull out the receptacle and check that first?
Comment: Agreed it sounds like the neutral came loose in the receptacle. Might be a good idea to check all wires on both ends though.
Comment: Will a dryer work with no functioning neutral?
Answer: Do Not Plug The Dryer In!
This is a dangerous condition if you have the obsolete 3-prong dryer plug (called NEMA 10-30). It will electrify the chassis of the dryer near 120V, while the chassis of the nearby washing machine is grounded, as well as slop sink valves, light switch plates, etc.
This is because when NFPA (authors of the electrical code) started requiring grounds (thus NEMA 14 on dryers), they allowed grandfathering of the old NEMA 10 receptacles, and officially sanctioned getting ground by bootlegging it from neutral.  This is not safe, because now instead of the chassis floating, now the chassis is tied to neutral.  A neutral break means the 120V parts of the dryer are trying to return 120V to source, via neutral, there's no path, so the appliance side of the neutral break is "pulled up" to 120V.
NEMA 10 was outlawed in the, when, 80s?  But what happens in the real world is this:

Susan has an older house with a NEMA 10 receptacle
Susan buys a new dryer with a NEMA 14 plug, and installers change the plug to NEMA 10
later, Susan sells this dryer on Craigslist
Jim has a newer house with proper NEMA 14 receptacle
Jim buys Susan's dryer, finds NEMA 10 cord, changes socket to NEMA 10
Karen buys Jim's house, changes her modern dryer plug to NEMA 10
Jim's new house has NEMA 14, he changes to NEMA 10 again

Thus, NEMA 10 spreads like a virus.
Seize the moment. Don't even bother trying to troubleshoot your problem, just pull some 10/3 cable and upgrade to NEMA 14 and bedone with it!
Comment: @Ken Yes, that's why Home Depot still sells NEMA 10 sockets.  Barely legal, but a bad idea.    The measurement to phase you discuss will only occur if the dryer is turned on (or has a 24-7 vampire load).
Comment: I guess replacing the 3 wire outlet with a new 3 wire outlet is still with in code. Now the issue is because op has an open neutral - op has 120v flowing through his chassis , if op were to measure dryer chassis to phase the measurement might be 240v.
Comment: @Ken the maximum voltage to ground in a 240 v system is 120 v. If it is a 3 wire system that the grounded or grounding conductor has opened the only possible voltage would be 120 as Harper points out the vampire load is a 120 v circuit in the dryer used for the control circuit if the dryer uses 120 v control.
Comment: @EdBeal read my comment again - you will see I mention chassis to phase if your neutral / ground is OPEN as the case with the op. You have a phase flowing through a motor winding to the chassis - like a direct wire Chassis is now one phase - and as Harper pointed out - the dryer must be on. Measuring from the chassis at this point to other phase will yield the full 240V. Remember the op has an open neutral. Now if you were measuring simply ground to phase or neutral to phase then yes 120V is the reading as long as it is not a hi leg (aka stinger)  - which in a home in the USA is very rare.
Comment: Ken is right, in a NEMA 10 installation, a broken neutral means the chassis floats up to the 120V potential of one leg, and therefore 240V from the other leg.  That's one way to test insulation!

No 120 in my dryer receptacle


Is it necessary to write test cases for different test levels?

Question: When creating test cases after unit testing(done by developers) QA team starts working on component testing. For component testing level there will be test cases written by the QA's
When it comes to component integration, should the QA team write test cases for component integration and so on system level, system integration etc?
If the answer is yes, please provide a little example on how to do it.
Currently I'm working on a test automation project and started creating test cases. With that I got this issue.  Im planning on doing API testing and End to End testing. Happy to consider new ideas too.
Answer: I've written a blog post talking about the different levels of checking in an Ember.js application. Link to it here
An Ember.js application looks like this:

If we have a function as:
fullName: computed('fullName', function() {
    const firstName = this.get('firstName');
    const lastName = this.get('lastName');
    if(lastName) {
        return `${lastName}, ${firstName}`;
    } else {
        return firstName;
    }
}

And the single computed attribute can be checked using at the unit level:
test("should display last name and first name in order", function(assert) {
  // get the controller instance
  const controller = this.owner.lookup("controller:names");

  controller.set("firstName", "Michael");
  controller.set("lastName", "Jordan");

  assert.equal(someThing.get("fullName"), "Jordan, Michael");
});

test("should display only the first name if no last name exist", function(assert) {
  // get the controller instance
  const controller = this.owner.lookup("controller:names");

  controller.set("firstName", "Michael");
  controller.set("lastName", null);

  assert.equal(someThing.get("fullName"), "Michael");
});

Now, if you want to investigate how this attribute is rendered (controller + template), you would go with a Component check:
test('displays full name with first and last name', async function(assert) {
    this.set('firstName', 'Mary');
    this.set('lastName', 'Johnson');

    await render(hbs`
      { {fullNameDisplayer} }
    `);
    assert.equal(this.element.querySelector('.full_name').textContent, 'Johnson, Mary');
}

In this case, we are isolating completely the rendering of the component from the application as a whole.
To ensure that this component is well integrated with the routing, you can create an (Ember) Application level check:
test("should say welcome at landing page", async function(assert) {
  await visit("/");
  assert.equal(
    this.element.querySelector(".welcome_message").textContent,
    "Welcome!",
    "should say 'Welcome'"
  );
});

This check can run a whole Ember application, isolating the services using Mirage.
These services should be tested in isolation, surely. But how to confirm that services provide the same structure of response as that ones you've mocked using Mirage?
That's where the concept of Contract Testing enters, using a tool such as Pact, which replays the requests issued by a consumer and checks if the responses match the consumers mocked data.

Now that we've checked that everything works as expected and can be connected, the last piece of the puzzle is checking if that are actually connected. Let's say your frontend app is configured to search for a service where it doesn't exist. Everything will pass, include Contract Testing, but your app will not work. This an example where end-to-end (Selenium, e.g.) comes handy, because it uses the app as a user would do, considering the tool's limitation, of course.
I talk about this and other examples of the blog post.
Each of these checks provide one type of information and are essential to have a good response time to a problem. If you have a problem that could be detected by an unit test, but you just have end-to-end checks, your response time (debugging + fix) will be longer; however, as shown, not everything can be detected by lower levels of checking.
If you use each tool with its best goal in mind, the check you write would be clearer and more objective.


What is the purpose of mvnw and mvnw.cmd files?

Question: When I created a Spring Boot application I could see mvnw and mvnw.cmd files in the root of the project. What is the purpose of these two files?
Answer: These files are from Maven wrapper. It works similarly to the Gradle wrapper.
This allows you to run the Maven project without having Maven installed and present on the path. It downloads the correct Maven version if it's not found (as far as I know by default in your user home directory).
The mvnw file is for Linux (bash) and the mvnw.cmd is for the Windows environment.

To create or update all necessary Maven Wrapper files execute the following command:
mvn -N io.takari:maven:wrapper

To use a different version of maven you can specify the version as follows:
mvn -N io.takari:maven:wrapper -Dmaven=3.3.3

Both commands require maven on PATH (add the path to maven bin to Path on System Variables) if you already have mvnw in your project you can use ./mvnw instead of mvn in the commands.
Comment: Thanks for the answer. Can you explain when this gets generated, like is it when you initially create a project? Will it gets updated along the line when you do changes to your pom like add remove dependencies/plugins ?
Comment: and, should you add/commit the  mvnw.cmd files?
Comment: yes, of course. it allows you to quickly run your maven build without the need to extra install maven or having it on PATH.
Comment: So many thanks for the answer, it's very helpful ¿Could you tell us something about the portability of the maven settings files when we working in that way?
Saludos and thanks again.
Comment: @DanielHernández the maven wrapper uses the default settings.xml on the users system. and according to this [issue](https://github.com/takari/maven-wrapper/issues/4) there are some tricks how you could add a custom settings.xml to the repo but it seems then it ignores the user settings on system.
Comment: Your answer is very helpful. I check the maven wrapper documentation. I was using `mvn` command for maven operation though I could use `./mvnw` for the same purpose.
Answer: Command mvnw uses Maven that is by default downloaded to ~/.m2/wrapper on the first use.
URL with Maven is specified in each project at .mvn/wrapper/maven-wrapper.properties:
distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.3.9/apache-maven-3.3.9-bin.zip

To update or change Maven version invoke the following (remember about --non-recursive for multi-module projects):
./mvnw io.takari:maven:wrapper -Dmaven=3.3.9

or just modify .mvn/wrapper/maven-wrapper.properties manually.
To generate wrapper from scratch using Maven (you need to have it already in PATH run:
mvn io.takari:maven:wrapper -Dmaven=3.3.9

Answer: The Maven Wrapper is an excellent choice for projects that need a specific version of Maven (or for users that don't want to install Maven at all). Instead of installing many versions of it in the operating system, we can just use the project-specific wrapper script.
mvnw: it's an executable Unix shell script used in place of a fully installed Maven
mvnw.cmd: it's for Windows environment

Use Cases
The wrapper should work with different operating systems such as:

Linux
OSX
Windows
Solaris

After that, we can run our goals like this for the Unix system:
./mvnw clean install

And the following command for Batch:
./mvnw.cmd clean install

If we don't have the specified Maven in the wrapper properties, it'll be downloaded and installed in the folder $USER_HOME/.m2/wrapper/dists of the system.

Maven Wrapper plugin
Maven Wrapper plugin to make auto installation in a simple Spring Boot project.
First, we need to go in the main folder of the project and run this command:
mvn -N io.takari:maven:wrapper

We can also specify the version of Maven:
mvn -N io.takari:maven:wrapper -Dmaven=3.5.2

The option -N means –non-recursive so that the wrapper will only be applied to the main project of the current directory, not in any submodules.

Source 1 (further reading): https://www.baeldung.com/maven-wrapper
Comment: Maybe you should mention that part of the text is extracted from https://www.baeldung.com/maven-wrapper
Answer: short answer: to run Maven and Gradle in the terminal without following manual installation processes.
Gradle example:
./gradlew clean build
./gradlew bootRun

Maven example:
./mvnw clean install
./mvnw spring-boot:run

"The recommended way to execute any Gradle build is with the help of the Gradle Wrapper (in short just "Wrapper"). The Wrapper is a script that invokes a declared version of Gradle, downloading it beforehand if necessary. As a result, developers can get up and running with a Gradle project quickly without having to follow manual installation processes saving your company time and money."
Gradle would also add some specific files corresponding to the Maven files Gradlew and Gradle.bat
Answer: In the windows OS, mvnw clean install is used for the maven clean and install activity, and mvnw spring-boot:run is used to run the Spring boot application from Command Prompt.
For Eaxmple:
C:\SamplesSpringBoot\demo>mvnw clean install
C:\SamplesSpringBoot\demo>mvnw spring-boot:run

Answer: By far the best option nowadays would be using a maven container as a builder tool. A mvn.sh script like this would be enough:
#!/bin/bash
docker run --rm -ti \
 -v $(pwd):/opt/app \
 -w /opt/app \
 -e TERM=xterm \
 -v $HOME/.m2:/root/.m2 \
 maven mvn "$@"

Comment: This does not answer the OP question, it just suggests an alternative
Comment: The very basic idea of maven wrapper is to declare the correct version of maven for this project. And a bonus is avoiding the need to manually install maven. Your approach not only misses to solve the version problem but requires one more locally installed tool.
Comment: Also note that this mounts the users own local Maven repository into the docker instance.  Typically this runs as root, so anything written by the dockerized maven instance is owned by root under Linux.  This is not necessarily desirable.  I found a properly setup nexus instance accessible to the docker build instance was less painful, especially if you desire reproducible builds.
Comment: I'm not down-voting because the answer could be helpful as an alternative, but it completely misses the point of the OP question and you can't just introduce a complex tool like Docker without even explaining what it is.
Comment: (continuing) Old-school Jenkins setup and mindset lead to this kind of thing. Modern CI/CD tools do the opposite: you just choose a build container. But that's just my opinion.
Comment: That was a long ago, but I still prefer this way. About maven version, image tags provide it (just look at the maven page in Docker Hub). As for the root ownership, it just doesn't happen on docker desktop - but indeed happens in linux boxes (and build nodes, of course). A small trick can "force" the current UID in this case (-u argument), so the problem is handled. But all means I find this approach orders of magnitude better. Docker is omnipresent anyway, specially on build nodes.
Comment: (continuing) this approach also has the advantage of reproducing the whole build environment is a very simple way. Old-school Jenkins setups are a nightmare.


Zend framework multiple routes for same controller

Question: I'm trying to set up Zend pagination on my site so that I can use Paul Irish's jquery infinite scroll plugin, but I'm having trouble with my routes. I currently have these routes set up for my organizer page:
//Organizer searches
    $route = new Zend_Controller_Router_Route('organizer/index/:filter/:page',
                                                array('controller'=> 'organizer',
                                                'action'=> 'index'));
    $router->addRoute('organizer', $route);
    $route = new Zend_Controller_Router_Route('organizer/index/:filter',
                                                array('controller'=> 'organizer',
                                                'action'=> 'index'));
    $router->addRoute('organizer', $route);

It matches organizer/index/popular correctly in this order, but if I put a page number on it the filter suddenly comes up null. If I switch the order, organizer/index/popular/2 works perfectly fine but organizer/index/popular no longer works. I could just only use the more specific route since that's the one I'll need for pagination, but I would like to include both to accommodate users trying to type the url or in case I forget to change the links somewhere in my code. Can I incorporate multiple routes to the same controller with Zend? If so, what am I doing wrong?
Answer: You need to give the routes different names. You've called them both 'organizer', so the second one replaces the first each time.
You could also easily do this with one route simply by setting a default value for the page variable:
$route = new Zend_Controller_Router_Route(
    'organizer/index/:filter/:page',
    array(
        'controller'=> 'organizer',
        'action'=> 'index',
        'page' => 1
    )
);
$router->addRoute('organizer', $route);

Comment: I didn't know I could set defaults like that. Thanks for the extra information!
Answer: Every route you add to the router must a have a unique name, so the second route you want to add must have a different name, because with your current code you overwrite the route organizer. Change the second call of $router->addRoute() to something like this:
$router->addRoute('organizer2', $route );


Is there a camera comparison site similar to GsmArena for phones?

Question: GsmArena has a fantastical tool for searching and comparing mobile phones. Is there a similar online tool for cameras?
Comment: This isn't a bad question per se, but it's a bad fit for Stack Exchange. All of our old list-of-sites questions quickly turned into a mess of outdated links, half-useful advice, and spam.
Comment: Would DPReview.com qualify?
Comment: @MikeDixon sure
Answer: I don't know and I doubt it is even possible and reliable.
There is big difference between DSLR world and smartphone world.
Smartphones are sold and used as is; there is no way of customizing it or upgrading. Except for fancy covers.
On the other hand, DSLR consist of a body and a lens(es) and the lens is the thing that rules the result and lenses are the expensive part of the "garage".
Usually, photographers pick a brand and stick to it, because it is cheaper to upgrade body and lenses separately. High-end lenses last much longer than High-end bodies.
Another reason why DslrArena is not there is because the market is not large enough to pay the service from ads.
There are also very limitted differences between brands in terms of resolution, noise, processing power etc. The things that actually matters cannot be measured and tabulated - handling philosophy and ergonomy. I own Canon 700D; when I am asked to use Nikon I know what I want to do, but it takes me a while to find out how to do it. I bet you, that skilled Nikoneer will have same troubles with Canon.


The mean waiting time of the pattern from coin tossing

Question: Toss a coin at time-points t = 1, 2, . . .. Denote the outcome of each toss
head-facing-up and tail-facing-up by a 0 and a 1, respectively. Let $\Lambda=(0\ 0\ 1)$ and $N$ be the waiting time for $\Lambda$. Find the mean waiting time $E[N]$ with the probability of each toss of the head-facing-up is $\frac{1}{3}$.
The following is my thinking:
Conditioning on the outcome of the first coin toss and second coin toss, let $N=
    \begin{cases}
      2+N^\prime& if X_{t=1}=0 \ \&\ X_{t=2}=1\\
      2+N^* & if X_{t=1}=1 \ \&\ X_{t=2}=0\\
      2+N^{**} & if X_{t=1}=1 \ \&\ X_{t=2}=1\\
      2+N^{***} & if X_{t=1}=0 \ \&\ X_{t=2}=0\\
    \end{cases}     $
Here, $N^{**}$ and $N^\prime$ have the same distribution as $N$.
$N^*$ and $N^{***}$ have the same distribution.
$E[E[N \mid X_1,X_2]]=E[N]=(2+E[N^\prime]) \times \frac{2}{9}+(2+E[N^*])\times \frac{2}{9}+(2+E[N^{**}])\times \frac{4}{9}+(2+E[N^{***}])\times \frac{1}{9}$
However, I don't know how to describe the distribution of $N^*$ and $N^{***}$.  If I know their distribution, I can obtain the answer.
Answer: To change the notation for clearer understanding, we want the waiting time for getting the first sequence of HHT
I shall use an approach proceeding step by step
Let $s$ be the starting state, $h_1$ the state where we have just tossed a head and $h_2$ the state where we have  tossed two consecutive heads, then
With one toss from start, we either toss a head with $Pr = \frac13,\;$ or remain where we are with $Pr =\frac23\;$ as shown in equation $[I]$
Framing equations step by step, we get
$\displaylines{s = \frac13(1+h_1) +\frac23(1+s)\;\;[I] \\h_1 = \frac13(1+h_2) +\frac23(1+s)\;\;[II]\\h_2 = \frac23\times 1 + \frac13(1+h_2)\;\;[III] }$
The last equation tells that from $HH,$ with $Pr=\frac23,\,$ we toss a tail and are done, or with $Pr=\frac13$, we remain poised at $HH$
Solve to get $s = 13.5$

Additional Material
Maybe the equations will be clearer if written in a  different form
$\displaylines {s = 1+ \frac13h_2 +\frac23h_1\;\;[I]\\h_1= 1+\frac13h_2 +\frac23 s\;\;[II]\\h_2= 1+\frac13h_2\;\;[III]}$
The first equation now  tells very clearly that from start, one step (or time unit) either leads to  the first H in the desired chain  with $Pr= \frac13$, or back to square one with $Pr = \frac23$
Similarly, the last equation means that with one step, either you go back to a HH situation with $Pr=\frac23$, or are done.
The technique is called first step analysis, which you can look up if you want further explanation or examples, also look at this answer here which addresses a somewhat more complex problem, and contrasts it with a stochastic matrix approach.
Comment: I still can't realize the meaning of $s$. What does the starting state mean?
Comment: The starting state is when you haven't yet tossed the coin, or when , say, you haven't achieved HHT and the chain has been broken, eg if you toss T, or HT, you are back to a state where you still require the first H of the HHT chain you want. Square $1$, so to say.
Comment: How do you generate the  equation above? Do you use markov chain? But the form doesn't seem like the markov chain I have seen before.
Comment: Yes, it is a Markov chain, I will add the equations in a different form, maybe that will help


Ice box room upstairs

Question: 1 room in the house upstairs remains 11 degrees cooler than the remaining rooms.  I don't even know where to start with this issue.  The thermostat is on the opposite side of the house.  But there is a room even further away than the problem room that doesn't get quite this cold.  The problem is the worst at night.  How can I even out the temperatures?
Answer: Ductwork usually has a vent damper below where it rises up from the basement. If it is a manual damper, it probably looks like a wing nut see this picture
It's possible most of the dampers are closed or partially closed, and the really cold room is fully open.
If you have dampers like this, you can loosen the wing nut and adjust the damper with a flat screwdriver. Usually the blade orientation matches the orientation of the damper. So if the blade is parallel to the duct, it is fully open.
Answer: The reason can be one of a few. Keep in mind that the position of the thermostat plays no part whatsoever. Its like having a light switch that is 1 ft away or 100 ft away from the actual light. It is only used to turn on and off the light.
With that, here is what should be considered.
1) Location of the duct distribution box ( This is where the air enters and then sent to other rooms.
2) A possible leak from not being sealed properly with duct tape.
Is this a new problem or has always been this way?
You can try simple trouble shooting such as close off other vents to see if indeed air does reach the room. If it does, then adjust other registers/vents until well balanced.
If indeed no air is circulated to the room after closing off other vents, then that means something is wrong in the attic. If you are able I would check in there first and look for openings or even the possibility of an animal chewing through the ducts..
Do not ask me how but I have even seen animals get in the ducts with no entrance holes and ultimately pass in the duct and reek up the house.
Should be able to easily find the problem based on the 2 aforementioned inspections and trials. Also look to see if they are all insulated as well.
duct distribution box photo below:

Ice box room upstairs


ubuntu 18.03 says no wifi adapter found on dell inspiron 3543

Question: I have installed ubuntu 18.04 on my laptop alongside window 8.1. Everything seems fine but it doesn't show wifi. It says wifi adapter not found. I have tried almost all the tricks and solution available till but it didn't help. My laptop have broadcom adapter and laptop is of dell inspiron 3543.
Please some one guide me.
Comment: You didn't specify which Ubuntu media you used (18.04, 18.04.1, 18.04.2, 18.04.3, 18.04.4, which shows age of stack, nor if using desktop, server etc), however your best starting point is the doco - https://help.ubuntu.com/community/WifiDocs/WirelessTroubleShootingGuide  (you'll find the Device Recognition & Operating in step 3 most hepful, it tells you the chipset used by your box allowing you to search online, or us to know what is on your motherboard, as brands regularly change components in models unless a short-term failed model that didn't see & was dropped quickly).
Answer: You can try using other operating system on a "Live CD" to check if exists a damage on your WiFi physically, if your WiFi works correctly on the "Live CD", try verify if exists an official driver for your operative system. Regards.


How do I remove a dishwasher that is screwed to a granite countertop?

Question: The company that installed the granite countertops attached the dishwasher to the granite. I need to know how to remove the screws, without damaging the granite, in order to replace the dishwasher.
Comment: Be aware that dishwasher width may vary. When I replaced mine, the new one required that I widen the opening about an inch. The cabinets _did_ have scribe fitting overhangs that I could trim back to achieve this, but it could have been ugly if they didn't. If at all possible I suggest getting the old one out, checking the opening size and how much room there is for adaptation, and getting the actual (rather than nominal) dimensions of the proposed replacement before paying for it -- or buy it with installation service included so this is Someone Else's Problem.
Answer: Unscrew the screws, using a screwdriver. There's no reason to think doing that will damage the granite. Almost certainly, the screws have been driven into plastic or lead inserts that are placed into holes drilled in the granite. Your new dishwasher may not have the mounting holes in exactly the same position, and will require similar inserts installed accordingly.
Comment: Also, there is sometimes simply a stamped metal bar that is placed across the adjoining cabinets, with many little holes to accommodate various models of dishwasher.


Wifi connected but can't access any Website

Question: When trying to connect to Wi-Fi it connects without a problem and it is showing that Wi-Fi has full signal strength. However when trying to access any website it shows that it is trying to load it and just hangs at that point. What is causing this?
What can be done to resolve this? The router in question is a Aruba Networks Router with WPA2 enterprise.
Answer: Hold alt and click the Wi-Fi symbol in the menu bar; in the extended menu does it list the Internet as reachable?
If not, it can be a external problem or perhaps there is a secondary login required on a splash website or something.


On the use of $\mathrm{\delta^{18}O}$ as temperature proxy

Question: $\mathrm{\delta^{18}O}$ (i. e. the ratio of $\mathrm{^{18}O/^{16}O}$ compared to a standard) is massively used today in paleoclimatology as a global temperature proxy.
But how did it become a proxy for temperature? When and by whom was the correlation observed for the first time?
Was the model explaining why it followed global temperature found straight away or was this proxy purely empirical for a long time?
Answer: You're not going to believe this, but it turns out that the guy behind this was none other than Harold Urey (Yes, the Harold Urey of the Miller-Urey experiment!).
He made the discovery of the correlation sometime in the 1950s, and with his nuclear background, he was well aware of the properties of isotopes. He studied small ancient fossilized creatures called foraminifera, and used the ratio of $^{18}O/^{16}O$ in their shells to figure out ancient temperature patterns. Here's a quote of a passage from this site:

In the 1950s, the nuclear chemist Harold Urey devised another way to use the shells to measure ancient temperatures. He found he could take the temperature of an ancient ocean by measuring the oxygen that forams built into their shells. The rare isotope oxygen-18 is a bit heavier than normal oxygen-16, and biologists had shown that the amount of each isotope that a foram takes up varies with the temperature of the water. The isotopes were fossilized with the shells, and the ratio of isotopes (O18 to O16) could be determined with the new and exacting techniques of mass spectrometry. Urey and his team at the University of Chicago refined these tools, developed for nuclear studies, and applied them to calcite in fossils. They found plausible temperatures clear back to the Cretaceous era, more than 100 million years ago.

However, the page also says (a bit above this passage) that the person who realized that the foraminifera could give clues as to the temperature of the world at the time of their lives was Wolfgang Schott, working in the 1920s.
The page also cites two papers of Urey's, the first from 1947 and the second from 1950, making it seem as if his research was actually in the later 1940s.
Fun fact: The Wikipedia page on Urey hints that this work led him and one of his students to carry out the Miller-Urey experiment. I haven't been able to confirm this, though, so for now it's just a fun fact.
Comment: This is very interesting! Do you think he had worked out a model explaining the link with temperature? I found the 1950 reference (which was unfortunately just a short abstract) but don't have access to the 1947, so i couldn't check if he at least hypothesized one.
Comment: I haven't been able to find anything on that; it's quite possible that he did, but I don't have any evidence for or against it.


MySQL: get a rows position within a sorted table within a view

Question: Ok, I am having trouble think how to describe this problem, but basically I have a view that looks like this:
CREATE VIEW `dbname`.`v_viewname` AS
select
idTable,
round(val1*(probability*.01),2) as probest,
from table

And what I want to do is create another field (let's call it "rank") that is the position of the row when it is sorted by probest in descending order. First I created a stored procedure which will generate a table which does this and turns it into a derived table, which look like this:
set @rownum := 0;

select * from (

select @rownum := @rownum+1 AS rank, idTable

from table order by (val1*probability) desc )

as derived_table;

so the question is, how would I join this derived table with my the table I read from in my view? Were the table in a routine or something I would use:
table join inner derived_table on table.idTable = derived_table.idTable;

but because this has to be done through a view, I don't even know how I would get the derived table for joining. Also: If this way won't work or is inefficiency in any way, what would be an alternative method?
Answer: select tbl.*, @rownum := @rownum+1 AS rank
from (select
      idTable,
      round(val1*(probability*.01),2) as probest,
      from table
      order by probest desc) tbl
      ,(select @rownum := 0) init_vars


Michigan Results- Provisional Ballots

Question: As of writing this, Trump won Michigan by just about 13,000 votes. Is it known how many provisional ballots there are in Michigan that might tip the state to Hillary?
Answer: This answer is no longer timely, but the Michigan Secretary of State's office released a report on provisional ballots.
According to that report a total of 22,504 provisional ballots were cast. The vast majority were provisional because the voter did not provide an adequate ID at the time they voted.

Michigan Results- Provisional Ballots


SoftPhone and linux

Question: We are thinking about writing a softphone app. It would basically be a component of a system that has calls queued up from a database. It would interface with a LINUX server which has Asterisk installed.
My first question is

Whether we should write the softphone at all or just buy one?

Secondly, if we do,

what base libraries should be use?

I see SIP Sorcery on CodePlex. More than anything, I am looking for a sense of direction here. Any comments or recommendations would be appreciated.
Answer: To directly answer your question, one of the many open source softphones are likely to fit your needs, and allow slight modifications as needed. Under most open source licenses there is no obligation to distribute your code as long as you only use it internally (do not distribute the binary.)
Trying to guess what you are trying to do, it sounds like a call center like scenario, so one of the many call queue implementations out there might fit your needs.
Answer: The answer would depend on the capabilities you have in your team and the place you see your core value and the essence of the service you provide.
In most cases, I'd guess that you don't really care about SIP or doing anything fancy with it that require access to its low level. In such a case, I'd recommend getting a ready-made softphone - either a commercial one or an open source one. I'd go for a commercial one, as it will give you the peace of mind as to its stability and assistance with bug fixing and stuff.
Answer: I had to write an own softphone and I found a great guide how to achieve it. In the guide there are 10 steps provided for having an own softphone (voip-sip-sdk.com on page 272)
I found it useful and maybe you will find it as well.

SoftPhone and linux


Custom Content Type Missing from Search API results

Question: I am trying to return all items with my custom content type applied but all the ContentType property is set to Item. Not sure what I am missing here. I have added my content type to my list and populated the columns. These columns have data if I search via the title but I cannot search on ContentType. Any ideas?
Answer: I believe though you have added content type to a list but you haven't set it to default. And all the items have been created with default CT i.e. Item.
Modify the view and check the CT for all the items. Confirm for list settings if custom CT is selected as default CT.
Comment: It does not need to be the default, but it does need to be assigned. Make sure you have assigned the correct Content Type to the item and then recrawl the list.
Comment: @MatthewMcDermott, how do you assign the Content Type?
Comment: @MatthewMcDermott, I changed the order of the content types and set the custom type as default and the content type is still set to Item in the search results
Comment: Did you assign the Content Type to the Items? You do this in the Metadata of the item.


series representation of bivariate functions

Question: Given a bivariate function $f(x, y)$ with $x \in [-a,a]$ and $y \in [-b, b]$, what is the necessary and sufficient condition under which we can write $f(x, y) = \sum g_k(x)h_k(y)$ for all $(x,y)$ in the domain of $f$ (the series could be infinite, in that case the convergence is just pointwise convergence)? Are there any established results or good references related to this kind of problems?
Comment: You should specify where are your functions defined, and in what sense does the series converge. Otherwise, one cannot give "necessary and sufficient conditions".
Comment: Thank you for the reminder. Already updated the question.
Answer: For example, $C^\infty([-a,a])\hat \otimes C^\infty([-b,b]) = C^\infty([-a,a]\times [-b,b])$
for the completed tensor product, and all tensor product topologies between the projective and the inductive one coincide, because the spaces are nuclear.
See for example,

MR2296978  Trèves, François: Topological vector spaces, distributions and kernels. Unabridged republication of the 1967 original. Dover Publications, Inc., Mineola, NY, 2006. xvi+565 pp.

Also, $C^0([-a,a]) \hat{\hat \otimes} C^0([-b,b]) = C^0([-a,a]\times [-b,b])$, but now only for the inductive tensor product norm. For $\mathbb R$ instead of a compact interval, this only holds for functions which vanish at  infinity.
Similarly for $L^2$, with the $\ell^2$-tensor norm.
Edit:
Elements in the algebraic tensor product are exactly the functions $\sum g_k(x)f_k(y)$ (finite sum), so in the completed tensor product they are convergent series (at least for the Frechet case).
Comment: ... and can something in the completed tensor product be written as a sum of a series of "elementary tensors" $g_k(x)h_k(x)$ ?
Comment: ... yes: For the (completed) projective tensor product this is a result of Grothendieck and for the injective tensor product this is also true (and motivated [this question](http://mathoverflow.net/questions/134382/series-representation-in-injective-tensor-products)).
Answer: Since you explicitly ask formseries, perhaps it is more relevant to phrase your questions in terms of Schauder bases.  Most of the function spaces of interest in analysis have such bases (the original Schauder bases for spaces of continuous functions, Haar type systems for $L^p$ -spaces, classsical families of special functions for spaces of test functions and distributions).  As indicated above, the bivariate versions usually have representations as tensor products. The circle is closed by a series of results showing how to tensor use such bases to get ones on  tensor products. This was originally done by Gelbaum and de Lamadrid (Pac. J. Math. 11 (1961), 1281-1186) for the case of Banach spaces and the result can easily be extended to locally covex spaces (e.g, in "Bases and complete systems for analytic functions", Studia Math. 33(1969), 157-164).
So the answer to your question is yes in most concrete cases (with the usually proviso about pointwise convergence in the case of $L^p$-spaces).