Why is it a considered a passing touchdown in cases when the receiver gains most of the yards?

Question: I don't understand why it is considered a passing touchdown that accrues to the QB's stats, in cases when the receiver gains most of the yards.  Consider a 5 yard pass where the receiver then runs 90 more yards.  My understanding is that this is a passing touchdown, and that the QB threw a TD.
Shouldn't this be a variety of rushing TD instead of a passing TD, or at least its own thing "pass with YAC TD"?
Answer: The short answer is that it is considered a passing touchdown because it is, by definition, a touchdown that occurred on a forward pass. The receiver would still be credited with a "Receiving Touchdown" as well as the sum of the yards credited to his net total. This is simply the definition of how the respective statistics "Receiving Yards", "Passing Yards", "Receiving Touchdowns", and "Passing Touchdowns" are determined.
There are, however, different advanced statistics that reflect what you appear to be seeking, a seemingly more proper distribution of credit on such a play. A stat like "Air Yards" for example, reflects how far downfield the Quarterback's throw traveled before caught by the receiver. This, along with Yards After the Catch or YAC, can be used to more precisely illustrate how a pass play gained its yardage.
I would caution however, against giving the receiver all of the credit for yards after the catch, as often an accurately thrown ball by the QB is a big part of the reason for a long gain after the completion is made. It can be interesting to look at air yards however, for often a QB can inflate his stats simply by throwing passes that are essentially elongated handoffs to skilled receivers who turn them into big plays. If it works, it is certainly a benefit to the offense, but speaks more highly of the receivers and the scheme than it does of the QB.
Answer: First: "touchdowns scored" is a mostly meaningless statistic.  A receiver who picks up 80 yards on a pass but is tackled at the one yard line has done quite a lot for his team, and while that last yard would be nice, who scores that last yard isn't all that important - the hard work was getting there.
Look at this article on predictability of statistics for QBs for example; passing TDs/game has only a weak year to year correlation (0.42), and passing TD rate (which accounts for teams that tend to pass a lot) was even lower at 0.23.  Nearly every other passing statistic is better correlated; Yards/Attempt is 0.43 (double that of TD rate), and Passing Yards/Game is 0.66 (1.5 times that of TDs/game).
Touchdown is simply an ends based statistic - like Wins in baseball (or football), it measures how the player got the positive final result.  As such, it's not an advanced statistic that's carefully crafted to show exactly how much someone contributed.
Measuring the QB's contribution to passing plays is a complicated work, and several groups have attempted to do so.  ESPN has a helpful explainer on its QB rating statistic, QBR, which shows their approach.  For passes, it looks at the expected YAC for a player after a pass of a particular type (YAC on a screen is expected to be more than YAC on a deep bomb, for example), among other things, to figure out how much credit to give the receiver for the completion.


controlling a machine with usb boot or target mode

Question: I need to change some preferences on a mac of which statup disk I can't control due to video issue (I don't see the desktop and so on ), I can use an usb disk to boot or launch it as target disk.... but can I operate on hits preferences?
thanks for now
Answer: If you boot your Mac into Target Disk Mode, you can access all of its files (provided you have the pertinent credentials) using another Mac. To start, reboot while holding down the T key on the Mac of which you would like to access the disk.
Once booted into Target Disk Mode, connect it to another Mac. This can be done using a FireWire or Thunderbolt cable, or using a USB Type C > USB Type A cable if you have the MacBook (Retina 12") (note that Apple does not sell this cable, but Belkin will soon. You can use your standard USB Type C cable if you're connecting it to another MacBook).
Then, to get to your displays preferences, open the property list located at ~/Library/Preferences/ByHost/com.apple.windowserver.<uuid>.plist. It's binary plist, meaning that you must either open it using a tool like Xcode, or convert it to XML by running plutil -convert xml1 com.apple.windowserver.<your_uuid>.plist on the command line in the appropriate directory to make it suit for opening by text editor. (Note that after this you will need to convert back to binary using plutil -convert binary1 com.apple.windowserver.<your_uuid>.plist).
When it's all said and done, you should be able to change your display settings back to ones appropriate for your display.


Whole-house surge protection: "intramural" surges

Question: Is there such a thing as a whole-house surge protector installed at or near the panel that can shield devices inside the home from surges originating on the mains, as well as shield devices inside the home from surges caused by other devices inside the home? I've tried reading about this but find conflicting info, and have spoken with a couple of electricians who say it's not possible to centrally protect all devices in the house from "intramural" surges; each device would need to be protected individually with its own surge-suppressor.
Comment: do not understand your dilemma. There are devices available "whole house surge protection"
Comment: As one of the answers states Type 2 surge protectors provide some protection for surges whether they are externally or internally generated. All the hots come together in the panel. The Type 2 protector evidently prevents the voltage there from spiking.  There of course may be and probably is a benefit to further protecting some delicate appliances at the receptacle or between the receptacle and the applicance.
Comment: HVAC company is trying to sell me two local device surge protectors for A/C, one for the motor up in the attic, and another for the fan outdoors, about $750 for the pair, but they said they would protect only those devices from surges, so I believe they would be type 3.  So I am looking to see what can be done at the panel.
Answer: You are asking several questions, but the electricians are correct: no single central surge protector can protect all devices from surges originating both inside and outside of your house.
A whole house surge protector is also referred to as a Type 1 surge protector, mounted on the line side of a panel, and is intended to prevent surges from the supply grid from affecting your house. It cannot protect against "intramural" surges, such as one of your appliances experiencing some sort of spectacular capacitor disaster, or a lightning surge that comes in via unprotected data cables, or that one cousin eager to show off his DIY generator by plugging it into your living room.
Type 2 surge protectors are also generally placed at or near the panel, but on the load side. These aren't as common in residential applications as types 1 or 3, but may be used to isolate circuits that may generate large spikes (like HVAC systems), or for circuits that will have heavy appliances that have draw higher than the rating on most Type 3 protectors.
Individual surge suppressor such as power strips and other devices functioning at the outlet end of things are referred to as Type 3 surge protectors. They are intended to protect whatever is plugged into them from surges in the rest of the house, as well as protecting the rest of the house from surges originating from things plugged into them (as the "intramural" examples given above).
Any surge protector is a potential interruption in the web of circuits, that protects everything on one side of the interruption from everything on the other side. If you want to protect things that are on the same side of the interruption from each other, you need more interruptions. It comes down to your own evaluation of the cost of layering these levels of protection vs the probability of something going wrong and the expense if it does.
Comment: Surge protectors have parts, e.g., MOV's, that can short while stopping a surge. For that reason, there should be a fuse in the protector. This means that after saving devices from a fault, the protector is effectively "burnt out",  no longer functioning. Even with Type 1 or 2 protection, having surge protection at outlets is worthwhile -- they've saved a computer in my house, when an unprotected lamp and a clock went up in smoke (no flames, though).
Comment: @DrMoishePippik about 15 years ago now, I experienced a nice weekend when the UPS at work decided to short and take out half our companies backoffice IT infrastructure.  Servers were literally pumping out smoke.  That was a relaxing weekend, for sure.
Comment: Whole house surge protectors can indeed protect virtually everything in the house, within the limits of their ability to protect anything at all.  See my explanation below, which exceeds the permitted length of comments.
Answer: **Whole house surge protectors do offer equal protection against surges originating within the house, except for devices on the branch where the surge originates and even there the risk is quite small (zero?).
A whole-house surge protector drops the voltage to a safe value (the clamping voltage) at the point it is connected, at the main panel the service line comes in and all the branch circuits come together.  The voltage drops when the surge current passes through the wires to your house.  (Whenever current passes through a finite impedance, the voltage drops, per Ohm's Law.)  Every branch circuit has the same, safe voltage, so everything is protected.
For surges originating inside the house, the process is almost identical:  the voltage surge sends current through conductors whose impedance causes the voltage to drop when the protector clamps it. That sets the maximum voltage for all the branches, preventing the surge from spreading to other branches.
The only branch where devices could conceivably be harmed is the one where the surge originated.  But what device could cause such a surge?  It would almost certainly have to come from a high-current inductive load.  In most homes, only the HVAC compressor would qualify.  But since code requires it to have a dedicated branch, there would be no other devices to damage, either on it or anywhere in the house.
The whole house surge protector a pretty wise choice to prevent damage from surges originating from either inside or outside.  I have had one for my home for many years with zero surge damage and many thunderstorms.  But two caveats:

Surge protectors have finite limitations in how much energy they can absorb before they fail, and limited lifetimes.
A lightning strike to your home may send catastrophic currents through several (or even all) the branches and damage the devices connected to them. The whole house protector mitigates but does not eliminate that risk.
Comment: @mr blint, the metal of a wire is the conductor. If you define a wire as the metallic core plus any insulation, then the metal core is the conductor. Any wire can conduct a spike.
Comment: I am sort of in the dark about the precise meaning of certain terms, like "conductor". If I have a ground, a neutral, and a hot going to a device in the house, can a surge at that device travel back to the panel on the neutral and then proceed out to other circuits on their neutrals?
Comment: Are any of the wires able to be a conductor?
Comment: It is my understanding that a Type 2 surge protector installed in the panel can mitigate a spike or surge originating in that branch circuit *and* in all other circuits. I think some people misunderstand the nature of a "spike" by imagining the wavelength of the spike being short compared to the distance along the wire whereas in actuality the wavelength is long compared to the distance from applicance to the panel. The result is that the developing surge appears at the panel simultaneously with its origin in the appliance. Hence the Type 2 protector interrupts the development of the surge.


Automate change background to white on all images?

Question: I am working with model images that our standard images have to be the item with white background. Ive had vendors sending me images with their item only with off white background and I have to do 600 images a day and it gets annoying. Is there a way to automate a white background without taking out the main image and do it all at once to save me time?
Comment: Can you upload an example image you would normally manually clean up, so we can get a better idea of how much contrast there is in the images?
Comment: If they're vendors...then you're paying them...why not simply stipulate that they must shoot their images with blown out backgrounds?
Comment: An example or two is really needed then. "off white" is a very large range...
Comment: They do give us a white background but its like "off white" just want to make it clean and bright and make the item stand out.
Answer: It really depends on the consistency of the photos and maybe more importantly, the colour of the subject. PS has the ability to do selections on colour range, so you record your actions on processing a single image to create a PS Action that you can then apply to other images.
If this works, then you can apply the action in a batch process against all your images and let it run.
If your images don't allow for the easy color range selection though, you won't be able to automate it like this. Manually doing the selection will be very time consuming.


More Scientific Discoveries Outside Academia Past 50 Years?

Question: I heard someone claim there have been more scientific discoveries outside of academia, in industry, the past 50 years than in academia. Is this true? Has anyone tried to quantify this?
Comment: This question appears to be off-topic because it is about the history of science.
Comment: I'd be highly skeptical of what that person says, especially if he's not providing you with some kind of supporting evidence. That said, there are specific fields like biomedical research a large portion of work is being done by industry. On the other hand, discoveries in fields such as fundamental physics are made almost entirely within academia.
Comment: diito for mathematics. Whens the last time a serious result in Algebraic Geometry came from outside the academy?
Answer: This is not a philosophical question, but it has some philosophical offshoots, whatever answer is given. Most importantly -- how are discoveries made and what conditions are conducive? If you know that, the main question is whether academia provides such conditions. This is a controversial topic, and I liked an article last year about this in the context of Vinay Deolalikar's P≠NP proof.
Anyway, I don't even think it would be possible to quantify this in a strict way. After all, you would need to select some criteria for what a discovery is (was the lightbulb or search engine a scientific discovery?) and whether it was made in industry or academia (the line is usually quite blurry and becoming more so).
Comment: Academia's dismissal of industrial discoveries is not something new: [penicillin discovery](http://en.wikipedia.org/wiki/Ernest_Duchesne) that could have saved millions of lives was ignored for decades because the thesis was written by a non-specialist outside academia.
Answer: This is definitely true in regard to applied sciences: there have been significantly more discoveries of things that make money in the institutions designed to make money than in the institutions designed to teach. The amount of industrial research in electronics and computer science and other branches of engineering is very impressive.
I don't think though that the magnitude of the industry-driven research can be accurately quantitatively measured because many discoveries remain unpublished proprietary information for years. Very often a trade secret would make one more money than a patent. For example, RSA cryptography was known to British Intelligence 20 year before it was published by RSA, and that fact was not publicly disclosed until 30 years after RSA publication. In academia it's "publish or perish"; in industry it's often "don't publish or perish".
That said, I think the situation is different in regard to fundamental discoveries. Things that would open humanity's eyes but won't pay the discoverers' bills are still researched primarily in academia.
Answer: The phrase "more scientific discoveries" has three words in it that are vague and that can be made precise in many many different ways. Depending on how one defines these terms, the truth of this statement will vary.
The National Science Foundation regularly publishes statistics for various comparisons between academia and industry. Here are excerpts from two articles. The emphasis is from the original articles.
Business R&D Performance in the United States Increased in 2011, by Raymond M. Wolfe

During 2011, companies in manufacturing industries performed $201 billion (68%) of domestic R&D, defined as R&D performed in the 50 states and the District of Columbia (table 2). Most of the funding was from companies' own funds (81%). Companies in nonmanufacturing industries performed $93 billion of domestic R&D (32% of total domestic R&D performance), 81% of which was paid for from companies' own funds.

Science and Engineering Indicators 2012, National Science Board

The business sector continues to account for most of both U.S. R&D performance and R&D funding.

The business sector performed an estimated $282 billion of R&D in 2009, or 71% of the U.S. total, drawing on business, federal sources, and other sources of R&D support. The business sector itself provided an estimated $247 billion of funding for R&D in 2009, or 62% of the U.S. total; almost all of which supported R&D performed by business.
The levels of business R&D performance and funding were both higher in 2008 than in 2009 ($291 billion and $259 billion, respectively). Even with the decline in 2009, expanded business spending has accounted for most of the nation's R&D growth over the last 5 years.
The academic sector is the second-largest performer of U.S. R&D, accounting for an estimated $54 billion in 2009, or about 14% of the national total.
The federal government is the second-largest funder of U.S. R&D, providing an estimated $124 billion, or 31% of the U.S. total in 2009.

U.S. R&D is dominated by development activities, largely performed by the business sector. The business sector also performs the majority of applied research, but most basic research is conducted at universities and colleges and funded by the federal government.

In 2009, basic research was about 19% ($76 billion) of total U.S. R&D performance, applied research was about 18% ($71 billion), and development was about 63% ($253 billion).
Universities and colleges historically have been the main performers of U.S. basic research—and accounted for about 53% of all U.S. basic research in 2009. The federal government remains the primary source of basic research funding, accounting for about 53% of all such funding in 2009.
The business sector is the predominant performer of applied research, accounting for 58% of all U.S. applied research in 2009. Business is also the largest source of funding for applied research, providing 48% in 2009.
Development is by far the largest component of U.S. R&D. Funding for development comes primarily from the business sector, 78% in 2009; nearly all of the rest comes from the federal government.
Answer: A few years ago I was invited to participate in a workshop hosted by the EC on fundamental research in software engineering. I remember Wolfgang Emmerich from University College London talking about their Impact project, which had found evidence that most innovations in industry are traceable to academic research, but only after some time has passed. The report from the workshop with the details can be found here.


Classification performance and the feature set selection

Question: I am now working on a classification problem. The generated feature set can be separated into two group. I did a comparison study: use all of the features; use the features of group 1 only; and use the features of group 2 only. It turns out that the performance of using all of the features are the worst. How to understand this kind of observation?
Answer: The symptoms you are describing sound like a classic case of overfitting.  As described in the link, over time, researchers have managed to come up with various strategies such as pruning or early stopping to try to avoid or reduce the effects of overfitting.  Depending on which specific learning algorithm you are using, and the details of how it was implemented, it may be more or less sensitive to this problem.  If you are using a machine learning package such as scikit-learn or Weka, I'd suggest swapping out whatever learning algorithm you were previously using, and try running the same experiment with a different algorithm; both packages make that extremely easy (almost trivial, in fact) to do.
Answer: I think this is highly dependent on the classification approach that you chose.  Many classifiers can get stuck in local optima that represent non-ideal parameter spaces.  Another possibility is the scale of your normalization may be different between the feature sets thus causing issues with the classification.
Answer: I would suggest you do a cross validation to observe the influence of feature numbers. You need to quantify both in-sample error (in training data) and out-of-sample error (cross validation error). If both are large, it is possible due to the underfitting (high bias), and you need to add more features; if the in sample error converges to a small value, but the cross validation error is unacceptably high, you need to remove some features to reduce the possible overfitting (high variance).


Are there areas that have a higher chance of spawning dragons?

Question: It might be that I'm questing too much, but I don't see much dragons so I'm unable to learn the new words I learn. Are there areas I could go and take a visit to perform some efficient dragon hunting?
Answer: From what I gather they appear generally every 36 or so hours. I tend to find them in towns when I'm waiting for shops to open.
I read somewhere that you can sleep for 36 hours in a town and when you go out a dragon spawns every time.
Also you need to do a quest in Whiterun as part of the story to allow attacks by "wild" dragons.
Comment: I've done the quest; the time between my two last dragons might have indeed been 36 hours but I'm not entirely sure. Someone needs to confirm whether force spawning by sleeping enough would work. I haven't seen a dragon attack Whiterun itself yet, is that possible?
Comment: @TomWijsman Yes, I've killed one right in Whiterun (and a single guard was the only NPC to die!)
Answer: I've found that they're very likely to appear around the burial grounds, even after you've killed the first one guarding them.
Answer: In my experience Morthal, Winterhold, Falkreath, and Dawnstar spawn dragons nearly every time. Markarth had only one spawn and I have a house where I dump my gear after every quest or two. Karthwasten about every other time. Shor's Stone I don't visit very often so idk. Riften I've never had a spawn. Ivarstead about one in three. Been attacked between Ivarstead and Riften quite often.Windhelm I've never had attacked but I've been attacked at the farms near the stables. Rorikstead I've never had attacked but been attacked before and after. Solitude have had attacked twice, but get plenty of attacks a little ways away from the city. Same for Dragon Bridge. Whiterun never had a "wild" dragon attack, but a lot in the countryside and Riverwood. Think attacks have to do with how close dragon burials are, and where the dragons fly to. *Note this is just my current character at level 37.


How fix Windows10 doesn't remember windows position on desktop

Question: It's the first time(in all Windows versions) that I notice this BIG problem.
Windows on desktop(except Chrome) continue to open in a different position without remember the last one.
A fix?
Comment: I've only noticed it with VLC, which I have auto-launch at startup. It was putting the window where it wanted, not where I put it. Fix was… launch, move window, quit, launch. Test by reboot… Fixed.
Comment: Nope my friend :( this isn't a fix. It's very annoying mostly with Windows Explorer, it continues to open according to a precise pattern
Comment: Tried the 'set all folders like this one' trick? Same as in Win7, just a bit harder to find, In View menu/options, I think - not on a Win machine right now
Comment: Nada! I think a registry hack can be the solution but I don't know what to do precisely...
Comment: Sorry, I'm out of ideas - wish you luck :)
Answer: Not exactly a proper fix, but this workaround may help. In short:

Get DisplayFusion.
Go to DisplayFusion's settings.
Open the 'Triggers' tab.
Add a trigger with:

Event: Window Created
Process Filename: <whichever program you want in a fixed positions>
Add an action: Move Window to Specific Size and Location

Press OK.
Press Apply.

Also works for issues like this one where Windows 10 will move windows close to the monitor edges 10 pixels inward after reopening it.


How to get this visual effect on typeface?

Question:
This is some work by Alexis Jamet. I was wondering how he executed the blurred, print effect on the type? I feel like blurring would work but I think there's a little bit more effort on this that I can't quite put a finger on. Would love to study these analog-esque effects!
Comment: So, did you *try* a basic or more advanced blur?
Answer: You are correct-
Editable text- Effect>Blur>Gaussian blur- then play with the setting-
Answer: Gaussian blur makes the effect partially. But it doesn't make the foggy bridges between the parts as you seemingly have noticed. Here's a slightly more developed attempt:

In the bottom there's the background layer
In the middle there's a text. It's rasterized for free adjustments and effects. It has got a slight gaussian blur and another filtering Noise > Median. Median filtering finds what's around a pixel and takes the most common color. It tightens blur at the edges and generates those foggy bridges.
Median spoils the definition of the letters if it has large enough radius to make bridges. The definition is partially restored by inserting a copy of non-blurred text to the top layer. It has reduced opacity to keep the appearance still blurry.
The opacity reduction explains the transparency of word "To" in your example.


How do I fix an Avid BB7 Outboard Pad that Doesn't Retract?

Question: A friend came by with a Bike Friday with a rear BB7 disc brake that no longer worked at all. The adjustment was way off, a result of the undiagnosed fact that the outboard pad wasn't retracting anymore. How could I fix it?
Answer: This is apparently not an uncommon problem, but the fix isn't necessarily simple to do -- especially the first time around. It took me an hour and a half to figure this out, so hopefully this saves some time for people.
The problem is discussed at length here, and the solution as well, but how to get it done isn't clear. You do not have to disassemble the brake to fix it. However, it helps to understand how the mechanism works:

The lever pulls the arm that twists the drive cam, that pushes the foot screw, which pushes the pressure foot. The pad (not shown) sits flush on the pressure foot into the disc rotor (and the rotor into the inboard side pad).
If someone twists the outboard foot screw too far clockwise, this can actually disengage the pressure foot. It won't pull back anymore, and only the little retaining spring in there (normally meant to just keep the pads on the pressure feet) will push out, so there will be a constant brake drag.
The pressure foot needs to be shoved back on/in, and this can take a decent amount of force. That linked thread says that shimming the pads and/or using the rotor and just pulling hard on the brake lever can re-seat it, but it didn't do the job for me. This is a friction fit, apparently.
I needed to:

Remove the caliper from the bike
Remove the pads and retaining spring.
Clean things with alcohol on a q-tip.
Find a suitable shim to fit between inboard and outboard pressure feet.
Loosen outboard foot screw entirely (counterclockwise)
Use inboard adjuster to push shim into outboard foot until it pushes back into place.
Reinstall pads and brake on bike, adjust, good to go.

Finding a suitable shim isn't easy. First, the shim needs to be rectangular, so you get a parallel/orthogonal push. Next problem, the pressure feet on both sides aren't totally flat. They have a protruding button in the middle (which retains the brake pads by fitting into a hollow), so you need a shim with a hole in it, or two identical flat pieces that will work on either side of the buttons.
I was going to drill some aluminum stock I have, but then I used a pair of 8mm hex wrenches, followed by 10mm hex wrenches. Two of these could be place inside the caliper body, one on each side of the button, then the inboard adjuster used (with a t-25 torx driver) to shove things together. After I reached the limit of what the 8s could do, I unscrewed the adjuster, put in the 10s, and repeated.
This did the job easily, after I spent and hour trying to shove that foot back home by other means.
Oh, after you clean would be a good time to put some dry lube on the cam and pressure foot (and inboard adjuster threads). I used dry because it won't migrate or attract and hold dirt. This probably made the reseating a lot easier too, as I had much less friction on the inboard adjuster screw threads.


Giving the same keyframe to multiple meshes

Question: A beginner here. I want to give the same key frame to multiple meshes. Are there any other way than selecting every single one and giving key frames one by one?
Comment: Please include a Blender screen capture to illustrate your question.  The choice is yours.  Currently I have a 50% understanding of what you wrote.   Maybe others have a 100% understanding.
Comment: Are you trying to change any of location, rotation, scale? Blender has modifiers and constraints that copy and coordinate properties such as location, scale, rotation.  You may copy and paste graphs of keyframes. There are drivers which are Python.  You may also want to write in your question how many objects are involved .  Do you believe you can coordinate all the keyframes once and for all correctly ?  Do you want to have more flexibility in how you coordinate.  Blender can also coordinate some properties directly .. by copying attributes .. such as materials.
Comment: There is also the concept of Parent Child in Blender.  I assume you have many keyframes per object you would like to coordinate.  Is that true?
Answer: I can think of two ways: select all the objects you want to apply the animation to, then select the object whose keyframes you are copying last (to make sure that it is the active selected object) then press Ctrl-L to bring up the Link Menu. From there select "Animation Data", and all the objects you have selected should now have the same animation applied to them. Please note that if you have keyframed the active object's Location property that all of the selected objects will be moved to the same location as the active object.
If you don't want the other objects to match the location of the active object, but you do want them to "fly in formation" as it were, then select all your objects, again making sure the object whose animation you are copying is last, then press Ctrl-P for Parent, and select "Object (Keep Transform)" from the dropdown menu.
Answer: Select to destination objects first, then the object with the animation.  Then menu to Object -> Make Links -> Animation.
However, this will "overwrite" any other animation you may have put on the destination objects.
Then if you don't want the object to continue to share animation, use the Object -> Relations -> Single User -> Object Animation.   This will make individual copies of the animation on each object, so you can further animate objects individually.


How to implement GSW13 using Helib or SEAL?

Question: I want to implement the homomorphic encryption scheme proposed in GSW13, and make some changes to it, but seems that there is no library that has already been implemented it. Since this is a homomorphic encryption scheme based on LWE, both Helib and SEAL have implemented some other LWE-based homomorphic encryption algorithms. I want to ask if I can use one of these two libraries to generate the public and private keys in the form required in the GSW13? And would tell me based on these two libraries, how to implement the of GSW13?
Answer: A good resource for FHE implementations is found on Micciancio's website. Searching GSW on it points to FHEW/TFHE, although they are quite different than "standard FHE" schemes (they bootstrap after each gate in the circuit). They are implemented though.
Besides those, there are various libraries for lattice crypto (Palisade, Lol, NFLlib, all on the linked webpage) which may be useful to use in any given implementation as a starting point.


Calculating area of newly added polygons on same layer?

Question: I have a layer where I had 6 polygons. I then used the field calculator so I could get a column with the area of each of these polygons and I thought this would be applied to any other polygons I made after that, which was not the case since every new polygon appears as "NULL" in the area column.
How do I make so the area is calculated automatically for all the rows?
Answer: You can use the AutoFields plugin, which solves exactly that issue.
Go to the plugin's docked window, select your polygon layer, choose the 'Area' field from the list of existing fields, choose the expression 'Area' and click on Save AutoFields.

Now QGIS will maintain your Area field up-to-date when you create new polygons or edit existing ones (you can also calculate the expression on already existing features if you like).

The AutoFields plugin saves the Area data into your data source file, so you can see it even if you change the QGIS project or load the data into another GIS software.
Watch this demonstration video showing how to keep other geometric properties up-to-date.
Comment: The best option to me! It avoids re-updating fields constantly after adding new features...
Comment: It's a great plugin. But don't we have to save the edits to see the change appearing? That is at least my experience with it.
Comment: Right Victor, when creating features you need to save edits and then the plugin does calculations. When modifying existing features the plugin does calculations right away.
Comment: I used the plugin and it is really useful, however It seemed to slow down the software performance quite a lot when saving edits (strange since I didn't even had many features to save).
I think It might be something else that happened simultaneously (mac update, something like that) because I have never had slow down issues with QGIS, so I'm going to try it later again. Thank you!
Comment: You're welcome. Please test it again later and if you find issues please let me know by reporting them [here](https://github.com/gacarrillor/AutoFields/issues). So far, I haven't experienced QGIS performance drawback with the plugin nor have I got any report about it.
Answer: There are 2 approaches:
1/ select all area's which has no value ("Area" is null) and do the calculation just on the selected ones. Check 'only update XXX selected features' and 'update existing field'

2/ You can make a virtual field with the expression $area.  Every time you add a feature the area will be calculated.  Warning: a virtual field is project only.  If you want to distribute the shapefile to another, you have to save it as a new one.


Running two LP heaters

Question: recently ripped out the old oil furnace that was proving to be more trouble than its worth to fix ; and went and got a 30K BTU heater, BUT its only warming up one side of the house, I plan on getting another to put on the other side but my question is will both of those be able to run alright off of my 100LB tank? and If so any rough estimate of how long?
Comment: I do hope that they have Oxygen deficiency minoring devices on them. Can in some instances cause dangerously low levels of life sustaining oxygen.
Comment: they shut off if the oxygen is low
Comment: Current, indoor-rated ones do have [O2 deficiency systems](http://thermablaster.com/why-thermablaster/vent-free-heaters/how-vent-free-heating-work/). I have one that has no such feature, and I'm careful how I use it in enclosed spaces. (I believe the problem is not actually that people might not get enough oxygen, but that in low-oxygen conditions the burners can start making deadly CO.)
Answer: A 100lb propane tank holds approximately 24 gallons of fuel, each of which will provide about 90k BTUs. So, one of your 30k BTU/hour heaters will use 1/3 gallon of fuel an hour (if run at full tilt), using up the full 100lb tank in about three days.
reference: https://theadminzone.com/threads/propane-usage-calculations.118427/

Running two LP heaters


Fetch list item if specific column is modified using caml query

Question: I need to fetch item from SharePoint list using CAML query, if specific column is modified. How to achieve this?
Comment: try to write in more details, possibly with example
Comment: If 'specific column' is modified **how?** Please provide more details as this question is far too vague.
Comment: I need to fetch list item from list only when specific column like "Name" is modified.If any other column is modified,no need to fetch other item.Is it possible to query the list using CAML query,to check whther the item is modified.If modified,whther the specific column is modified,if so..then i need to fetch the data.
Answer: CAML query will not be able to handle this for you as far as I know.  Updates to columns are logged in the audit system of SharePoint and the history tables.  You can't scan a list looking for a change to a specific column using CAML query.  It won't have that level of refinement.
Your only option is to use code to view the version history of the item and determine if the value has changed within each version of the history.  This can only be done if you are tracking history in your list.
However, since you are SharePoint Online managed code is also not going to work for you and CSOM doesn't have any hooks into History either that I am aware of.  You will have to utilize SPServices to get the history data for you from SharePoint online (information: http://spservices.codeplex.com/wikipage?title=Versions).  Using the following code will get you a list of each version of the item.  You can then loop through them to find out if your field has been modified.
<code>$().SPServices({
  operation: "GetVersionCollection",
  async: false,
  strlistID: "<LIST NAME>",
  strlistItemID: <LIST ITEM ID>,
  strFieldName: "<Column You are Checking",
  completefunc: function (xData, Status) {
    $(xData.responseText).find("Version").each(function(i) {
      console.log("Name: " + $(this).attr("Information") + " Modified:     "     +     $(this).attr("Modified"));
    });
  }
});
</code>
Comment: is possible to get multiple columns (strFieldName) data


How to stimulate basal growth in a tree?

Question: On my street lots of trees have a big burl at the base.
Is there a technique to "encourage" trees to develop it?
Answer: There's no real consistent way to encourage burls to grow on trees. Burls are a reaction to various kinds of infections and possibly damage. They can weaken a tree and raise it's susceptibility to more deadly infections. There's no way to purposefully try and create or encourage their growth and there's at least some debate about the exact circumstances that lead to burls being created.
Answer: Basal burls on Redwoods are a little different from other burls - they used to be called lignotubers, and are a natural reproductive structure for these trees. It's thought that this type of basal burl is genetically controlled, whereas other swellings which may occur on other parts, or at the base, of trees are an environmental response, maybe to fungal or bacterial infection. This type of burl may also be known as a gall or, sometimes, a tumour - an example would be crown gall, which affects many species of tree.
Unless your tree is a redwood, then any other gall or burl either happens or it doesn't.
Answer: The traditional method that probably caused what you are seeing is to run into the tree with a lawnmower a lot - once every week or two throughout the growing season.
Note that this is not a good idea (tree health-wise), but it is a common cause of damage near ground level in trees in domesticated areas.


Addition of Watermelon extract to secondary

Question: I would like to add a 4oz bottle of watermelon extract to my secondary, do I have to boil it or can I just add the extract?
Comment: How concentrated is the extract and how much volume is in your secondary? I've seen overuse (measured in *drops*) of extracts make a mead almost undrinkable (I think it mellowed a bit over time and was OK for sipping/mixing).
Answer: If it is packaged in a shelf-stable way (i.e., not refrigerated) and has been handled properly, you won't need to boil it.
Comment: With handled properly do you mean pasteurized or UHT? Both methods should kill most of the micro organisms existing on the extract, but not all. Still, for a secondary addition it should be safe enough. UHT should be the most effective between the two.
Answer: Boiling is only to sanitize whatever you are putting in the beer, if the product is completely sealed the solution inside will be fine. if you are worried about contamination you can soak the bottle in some sanitizer before you dump.
Make sure the extract contains no potassium sorbate as a preservative as that will stop all fermentation.
Good luck!
Comment: Ah I see, that does just come down to what the additive is and if fermentation needs to continue (for natural carbing or similar). I have had some secondary additives (specifically flavoring syrups) get destroyed by the yeast, so it can be a tricky situation.
Comment: @thanby Right, if he's force carbing and wants the sweetness, go ahead and stop fermentation. Otherwise there are other things to consider.


Uninstall gcc-5.4.0 to run gcc-4.8 as default

Question: I am using Ubuntu 14.04. Recently I decided to install gcc-5.4.0 (from source, i.e. i downloaded a tar ball and followed instructions to install) since it was needed to run CAMB and CosmoMC.
However, I am in need of using a new program: CosmoSIS (https://bitbucket.org/joezuntz/cosmosis/wiki/Manual%20Install), this code requires gcc-4.8 to run.
Whenever i try to install CosmoSIS, the code crashes because when it is searching for gcc-4.8 in /usr/local/bin it conflicts with gcc-5.4 which is installed in the same directory (i am new to this, i'm guessing i made a mistake by installing 5.4 in the same directory in which 4.8 is installed)
I'm looking for help on uninstalling gcc-5.4 since my priority is running CosmoSIS and gcc-4.8 is needed. I know there is no "uninstall" command for source-installed programs, but i need help on this: How can i uninstall a source-installed program?
Thank you in advance
Answer: Indeed, there is no "uninstall" command when installing from source, unless the developer has decided to put one in.  (i.e., it's not impossible for a developer to create a script that undoes everything)
Your only option is to go into /usr/local/bin/ and remove each file yourself.  But which ones to remove?
One solution is to reinstall 5.4, but specify a new directory that isn't /usr/local/bin/.  This will give you a list of files that 5.4 installed.  Then, using the list of files, go into /usr/local/bin/ and remove them manually.  Note that it probably installed libraries and documentation into other directories, so to remove it completely, you will have to do more than just /usr/local/bin/.
An alternative is to not do an uninstallation and just install gcc 4-8 on top of 5.4.  It's the same program, but just a different version.  So gcc version 4.8 will overwrite 5.4.  The "downside" is that you might have 5.4 files lying around, but they will just occupy (relatively little) space.  It'll solve your problem and you can move ahead with what you want to do.
Of the two options, I'd pick the second one.  The 5.4 files that remain won't affect your system.  Relative to images, video, or almost any type of data, the space they occupy is fairly little (i.e., compiler, libraries, documentation is probably small).  In the future, you should install it in another directory and add symbolic links manually.  update-alternatives would do that for you if it's a package installed compiler; but for a compiler installed from source, that isn't an option.
(Aside:  Ubuntu 14.04 has reached end of life, I think.  You might consider upgrading some day...  If so, then what /usr/local/bin/ looks like won't matter anymore!)
Comment: Security paches for ubuntu 14.04 are available through 2022 through the (maybe free) Canonical ESM support.  See https://ubuntu.com/blog/ua-services-deployed-from-the-command-line-with-ua-client
Comment: @ubfan1 Hmmmm, I'm not sure if it's free.  But thanks for pointing that out.  At the time that I wrote the above, I was referring to [this](https://www.omgubuntu.co.uk/2019/04/ubuntu-14-04-end-of-life) news.
Answer: Just create a symbolic link to gcc-4.8
cd /usr/bin
sudo rm gcc
sudo ln -s gcc-4.8 gcc

now try
gcc --version

And see if you got the desired result
Comment: while `/usr/bin/gcc` is very likely to be a symlink, it would be advisable to check first. Also, OP wants to uninstall gcc-5.4 so it would be nice if your answer addressed that...
Answer: I advise to use update-alternatives command as described in the answer How to choose the default gcc and g++ version?


Is Torta de Santiago supposed to be very moist?

Question: Is a Torta de Santiago supposed to be moist?  I cook it on convection for full time but the cake is still moist, so much so that  my 95 year old mother-in-law cooks pieces I give her again! A couple of days later even!  I did get an internal temp of 190 F.  Any suggestions?  Cake tester seemed clean!
Answer: Torta de Santiago should be moist, but I wouldn't describe it as very moist. Bear in mind that the standard presentation is to dust it heavily with icing sugar and then drench it in liquor when serving. If it's so moist that the icing sugar turns to icing, that's a problem. Otherwise, it would be moist from the liquor anyway.


Do the right-handed people tend to use the right side teeth of their jaw to chew food more often than the left-handed people?

Question: And vice versa, do the left-handed people tend to use the left side teeth of their jaw to chew food more often than the right-handed people?Or the frequency of food chewing distribute fairly to both sides of the jaw?
Comment: Related: https://biology.stackexchange.com/questions/57361/do-animals-exhibit-handedness-paw-ness-preference
Answer: Individuals have not only hand dominance but also a dominant foot, eye and ear. There has also been a belief that this sidedness applies to chewing as well. However, the short answer is that no one is sure, but that it may be related to handedness. I only looked at studies done after 2000.
One large study[1] found a questionable to weak correlation, not consistently maintained through different dentition (baby teeth, mixed, and permanent). A slightly smaller study showed a correlation; in 78% chewing side preference correlated with other tested lateralities (footedness, handedness, eyedness and earedness).[2] Another similar sized study found none.[3]
A small 2012 study found that there was a preference for right sidedness when chewing hard food (73.68%) and for soft food (57.89%) but failed to correlate this with hand/other-sidedness.[4] Another small study tested for sidedness, finding that 55% of subjects did not have any side preference, 30% preferred to chew on right and 15% preferred the left side, and this was reproducible in 90% of subjects only with almonds (a medium hardness food) as opposed to jerky or asparagus. Unfortunately they did not measure sidedness. Their findings were that chewing-side preference is not a fixed characteristic, and texture seemed to affect sidedness.[5] A review article determined that a person's dental condition to a large extent dictates how they chew.[6]
The studies were mostly designed very differently, making good comparisons difficult. I think it's safe to say it's possible but not known with certainty.
[1] Absence or weak correlation between chewing side preference and lateralities in primary, mixed and permanent dentition
[2] Chewing side preference as a type of hemispheric laterality
[3] Relationship between chewing side preference and handedness and lateral asymmetry of peripheral factors
[4] Chewing side preference in first and all mastication cycles for hard and soft morsels
[5] Chewing-side determination of three food textures
[6] Adaptation of mastication in response to the characteristics of the individual or the food


How to do blade element momentum theory analysis for different geometries of airfoil, e.g. NACA airfoils?

Question: I want to analyse NACA airfoils using BEMT. I have only yet done it for basic symmetric airfoils. I would like to know what all assumptions remain same in NACA airfoil analysis and to what degree it is accurate. Like for starters, will accounting for Cl-alpha change and geometrical changes in angle of attack be enough to analyse NACA airfoils?
Comment: To clarify: I usually hear of BEMT to analyze rotors or propellers, given particular airfoil sections.  Are you trying to analyze a variety of NACA airfoils so that you have an expanded set of airfoil tables to reference in a BEMT analysis?
Comment: It is for analysing rotors. I cant think of any difference to BEMT analysis except for the airfoil table changes when NACA airfoils are considered. I feel like the accuracy is going to be way off if that's just it
Comment: Technically, symmetrical airfoils are just NACA00xx airfoils, and I think that frames the problem better. If you do not use the right airfoil data -- particularly when moving from symmetrical to asymmetrical airfoils -- you are going to see significant errors in the results for sections that are pre-stall. But that's it if you are doing a traditional BEMT analysis...the described change in airfoils won't effect compressibility effects since neither are supercritical airfoils, and that's the only other change that comes to mind outside of the airfoil tables.
Answer: The only difference would be the lift and drag coefficients used.  You'd need those to be specific to the airfoil(s) you choose.  Momentum theory is otherwise not sensitive to the airfoil shape.
Given the same lift and drag, momentum theory will give you the same induced velocity.


Validating Email and Password Input Against a Dataset

Question: I am trying to validate user input from a form against the results of a dataset from my database. I do not know if I am implementing the logic or the attempt at the foreach loop (I kinda just made it up based on logic). I am trying to assign the indices of the datatable(created off the dataset) to variables, and then check if they match user input. Is this a decent way to do this? Is it possible? How can I make this work?
I get an error from code I thought I was correctly implementing that you can find in the comments of the code.
protected void btnSubmit_Click(object sender, EventArgs e)
    {
        //creates a connection for a data set to fill emails and passwords for validation
        string ConnectionString = ConfigurationManager.ConnectionStrings["ContourCoffeeRoastersConnectionString"].ConnectionString; ;
        SqlConnection Conn = new SqlConnection(ConnectionString);
        Conn.Open();
<code>    //creats a data set with database information and puts the dataset in a datatable
    SqlDataAdapter daCustomer = new SqlDataAdapter("Select (CustEmail, CustPW) From Customer", Conn);
    DataSet dsEmailsandPW = new DataSet("Emails");
    daCustomer.Fill(dsEmailsandPW, "Customers");//I get and error here in my stack trace
    DataTable tblCustomers;
    tblCustomers = dsEmailsandPW.Tables["Customers"];

    //sets the variable to user inputed data from the login form so it can be compared and validated to the dataset
    string custEmail = exampleInputEmail1.Text;
    string custPW = exampleInputPassword1.Text;

    //looks through each row on the data set to see if a matching email can be found
    foreach (DataRow drCurrent in tblCustomers.Rows)
    {
        string txtEmail = drCurrent[0].ToString();//sets a variable to the first index of the current row of the dataset
        if (txtEmail == custEmail)//if a match is found with the user input and a record in the database through the data set the password is then checked for validation
        {
            string txtPW = drCurrent[1].ToString();//assigns a vaiable to the second index of the row that should contain customer password
            if (txtPW == custPW)//if the password is a match
            {
                lblLogin.Text = "You are logged in!";
                //TODO: query for cartID and set it to the cookie!!!!!
            }
            else
            {
                lblLogin.Text = "Email/username combination is not correct";
            }
        }
        else
        {
            lblLogin.Text = "Email/username combination is not correct";
        }
    }
</code>
Answer: I would recommend sending a query
<code>"SELECT CustEmail FROM Customer where CustPW =" + custPw;
</code>
And evaluate it as a boolean value.
If it comes back true, you have a valid login.
If it comes back false, you have an invalid login.
You can also do something like
<code>"SELECT CustEmail FROM Customer where CustPW =" + sha1(custPw);
</code>
If the passwords are encrypted, you can encrypt their attempted login password and check it
against the DB's encrypted password.
EDIT: I'd also recommend storing your queries as stored procedures and just providing the variable data.


How do i 'share cookies' in opera extensions?

Question: I'm trying to write my first extension for Opera. Its speeddial extension.
I want it to show me some data from website, but to acces these data I need to be logged in.
I'm logged in, and opera knows it ;-) (When I type website's adress in Opera's adress bar, then everything works just fine.) And i want Opera to tell JS, that i`m logged in ;-)
But when I try to get that website in js, i get text, that says, that i need to be logged in:
<code>    r_xmlhttp.open("GET",url,true);
    //r_xmlhttp.withCredentials = 'true'; //even with that on, nothing changes.
    r_xmlhttp.onreadystatechange = user_func;
    r_xmlhttp.send();
</code>
My config.xml(that`s one from tutorial;-), added acces origin, and feature opera:share-cookies:
<code>    <?xml version="1.0" encoding="utf-8"?>
    <widget xmlns="http://www.w3.org/ns/widgets" id="http://example.com/SimpleClockSD" defaultlocale="en" viewmodes="minimized">
    <name short="Simple Clock">Clock Speed Dial Extension</name>
    <description>This is an example Speed Dial extension showing a simple clock.</description>
    <author href="http://people.opera.com/danield/">Daniel Davis</author>
    <icon src="images/icon_64.png"/> <!-- Icon source: http://www.openclipart.org/detail/17552 -->
    <feature name="opera:share-cookies" required="false"/>
    <access origin="http://wykop.pl" subdomains="true"/>
    <feature name="opera:speeddial" required="false">
    <param name="url" value="http://wykop.pl"/>
    </feature>
    </widget>
</code>
I looked up what is going on with wireshark, and i can tell that Opera sends other cookies than JS, and that's why JS says i'm not logged in. But i want JS to send the same cookies that opera sends, and theoretically it should do it, becouse i added feature called "opera:share-cookies", right?
What do I do wrong?
Answer: It should work, however, for initial development, try setting access-origin as * and then try. Also, try to be carefull with regards to access origin (www, and a domain without www). For now, try setting access origin as *, and see if it works or not. (In production, access origin * will probably not be allowed by the moderators though).
Answer: Had same problem, your extension is most likely working but not in the developer mode for some reason. When you zip it, rename to .oex and install as normal extension, it will probably work.


iPhone 5 tethering, device hard to discover, normal or a problem?

Question: I often use tethering now that it's enabled on Softbank network in Japan.
I normally use WIFI connection. The thing is, my iPhone 5 is usually hard to discover from my computer (Macbook Air). Normally when I turn on the tethering and wait around 10 seconds, it shows up in the available networks in the computer. But after closing the computer, doing something else, than later (minutes, hours or days), without having switched tethering off on the iPhone 5, I don't think I was ever able to discover the iPhone 5 from the computer, without switching tethering on/off on the iPhone 5.
Sometimes even after discovery, the connection itself fails because of "timing out". It seems the tethering discovery with iPhone 5 is weak. Is this normal or an issue? Is the iPhone 5 faulty? (I know most/many iPhone 5 have really bad WIFI hardware and/or software. Maybe it's related.)
iPhone 5 is at iOS 6.1 I believe.
Comment: Not sure if it matters, but I have the same problems with my iPhone 4S. In fact, it's so bad that I often just resort to Bluetooth or USB which seem to be more reliable.
Comment: Ok when finally discovered and connected I don't experience any problems. I didn't feel any lost connections so far. It takes some patience with the connection. Then again I cannot tell how good/bad the transfer speeds are, but then again there's not much else of a choice. I cancelled a Pocket wifi subscription and now use tethering only when in the field. The discovery is my only concern at this point.
Comment: FWIW I also end up using a Bluetooth connection most of the time due to how often I'm unable to get a wifi connection to work for tethering.
Answer: You should verify which software level you're on. 6.1 isn't available to the public yet. iOS 6.0.2 specifically fixes a Wi-Fi bug (Apple doesn't say what the particular bug is, but it affects Wi-Fi). Check to make sure you're not on 6.0.1. If you are, upgrade to 6.0.2 and see if the problem is resolved.
Comment: Rechecked. I'm on 6.0.2. The 6.0.2 did not help my WIFI troubles.


Difference between 'lie' and 'lie down'

Question: What is difference between lie and lie down? Please explain with some examples.
Comment: The question should have been: what is the difference between lie and lay.
Comment: @BlessedGeek Why, do you think?
Answer: The verb to lie describes the state of being in a horizontal position.

I often lie in bed for hours before falling asleep.
Why are you lying on the floor?

The verb to lie down describes the action of going from an upright position to a horizontal position.

You should lie down if you're feeling dizzy.
She lay down on the grass and went to sleep.

For the verb form differences between to lie (be horizontal), to lie (tell an untruth) and to lay (to put flat), see this article from Professor Pullum on Language Log.
Comment: @Kris, you are right to point out that in its continuous form (She's lying down; he's been lying down, etc.) the verb can also describe a state.
Comment: -1 Please see the definition for *lie down* --  "to place oneself or **be**" -- I wonder how this answer has been up voted!
Comment: https://www.google.com/#q=%22been+lying+down%22&tbm=bks
Comment: Which makes this 'not an answer', right?
Comment: https://www.google.com/#q=%22lie+down+any+longer%22&tbm=bks
Answer: lie down is a phrasal verb, an expression and an idiom.
phrasal verb/ expression:

1 to place oneself or be in a prostrate position in order to rest or sleep

idiom:

2 to accept without protest or opposition (esp in the phrases lie down under, take something lying down)

lie 2, on the other hand, is just an ordinary verb like any other.

to be situated, esp on a horizontal surface   ⇒ "the pencil is lying on the desk", "India lies to the south of Russia"
Answer: Lie, is to tell a none truth i.e. saying something that is false. 'I didn't eat your cookie.' (In this example you would have actually eaten the cookie)
Lie down, is to lay i.e. when someone says 'Lie down on the bed' they are giving you a command to lay down on the bed.
Comment: This answer does, in fact, describe a difference between the two terms. This answer could use a little fleshing out, though.
Comment: And keeping with the theme of unrelatedness, "lie down" also means "give up": _I will not lie down -- I will stand and fight!_
Comment: OED records first use of *to lie = be in a prostrate or recumbent position* in C11. It's misleading to suggest that sense only applies with the form *to lie **down***.

Difference between 'lie' and 'lie down'


Is molarity an intensive property?

Question: $$\mathrm{molarity} = \frac{\text{amount of solute}}{\text{volume of solution}} $$ and amount of substance is based on quantity (larger mass means larger amount), so how come it is an intensive property. Shouldn't it be an extensive property?
Comment: Very firstly, no. of moles doesn't depend on weight, it depends on mass. If you will take 12g of Carbon to the moon, it will have same no. of moles on moon as on earth.
Answer: Concentration is an intensive property. The value of the property does not change with scale. Let me give you an example:

Let us say you had a homogenous mixture (solution) of sodium carbonate in water prepared from 112 g of sodium carbonate dissolved in 1031 g of water.

The concentration (in mass percent, or mass of solute per mass of solution) is:
$$c=\frac{112\text{ g solute}}{(112+1031)\text{g solution}}=0.09799 =9.799\%\text{ sodium carbonate by mass}$$
The concentration is the ratio of sodium carbonate to the total mass of the solution, which does not change if you are dealing with the entire 1143 g of the solution or if you dispense some of that solution into another vessel.

If you dispense 11.7 g of that solution into a flask for a reaction, what is the concentration of sodium carbonate in that flask?

It is still 9.799% by mass. The ratio of the mass of sodium carbonate present to the total mass present has not changed. The actual mass of sodium carbonate has changed:
$$0.09799\dfrac{\text{g solute}}{\text{g solution}}\times11.7\text{ g solution}=1.15\text{ g solute}$$
The concentration is a property dependent only on the concentration of the solution, not the amount of solution you have. The concentration of a solution with defined composition is independent of the size of the system.
In general, any property that is a ratio of two extensive properties becomes an intensive property, since both extensive properties will scale similarly with increasing or decreasing size of the system.
Some examples include:

Concentration (including molarity) - ratio of amount of solute (mass, volume, or moles) to amount of solution (mass or volume usually)
Density - ratio of mass of a sample to the volume of the sample
Specific heat - ratio of heat transferred to a sample to the amount of the sample (mass or moles usually, but volume also)

Each of these intensive properties is a ratio of an extensive property we care about (amount of solute, mass of sample, heat transferred) divided by the scale of the system (amount of stuff usually). This is like finding the slope of a graph showing the relationship between two extensive properties. The graph is linear and the value of slope does not change based on how much stuff you have - thus the slope (the ratio) is an intensive property.
Answer: Consider the following picture:

Break the ice block shown in the picture into two equal halves.Now I hope you would be able to answer the following questions:
1.What are the physical properties of ice block which got halved?
Absolutely mass,volume,etc.(These are all extensive properties.)
2.What are the physical properties of ice block which remained same?
Density,etc.(These are all intensive property.)
If you have the doubt so as to why the density remained same,here is the explanation:
I hope you know basically even if block got halved,mass per unit volume remains the same in either of the pieces.All the way it mean that density remained the same(mass per unit volume).Thus it is an intensive property.
Similarly if you imagine solution instead of ice block,you will find that molarity remains the same even if you divide solution into two equal halves.Thus molarity is a intensive property.

Is molarity an intensive property?


is there any way to determine the date a domain DNS record like MX record was published?

Question: We need a way to determine when exactly a DNS record such as MX was published for a domain. Does anyone have a clue?
Comment: It'd have to be something like http://www.domaintools.com/research/whois-history/ but I've never heard of one that monitored MX records.
Comment: Your domain or someone elses?
Comment: Not our domain. Third party domains. We need to determine the MX publish date for some reasons.
Comment: Without admin access to the DNS server(s) to look at the actual records, I don't know of a tool that would find creation timestamps for DNS records.  Even a DIG with +all doesn't return that info.
Answer: Short of a kind of crawler that keep historical snapshots like the Wayback Machine but for DNS, no, this is not possible.
If you suspect that the MX record update may have been the most recent change to the DNS zone, then you can always check the zone serial number in the SOA record. One very frequently used convention for the format of the serial number is YYYYmmddnn where nn is a serial number for multiple modifications made on the same day. This might give you a clue as to when the zone was most recently updated. But this convention is not necessarily in use, and it can lie even if it is, and it doesn't tell you what was modified. The only thing I would infer from it is that probably nothing at all has changed in the zone since the date that appears in the SOA. Probably.


Determine Access rights for a role

Question: I'm having trouble finding a good way to determine the Access Rights for a given role. Is there a easy way to get a list of items, that a given role have been granted access to, without iterating the entire content tree?
Comment: Do you want to do that programmatically? Or see those items in a UI?
Comment: @DmytroShevchenko  programmatically.
Answer: Sitecore Powershell Extensions comes with a script which will return you all the items with security information on them. You can filter the data to specific path and select one account you are interested in.

You will get the information in form of a report.  You can also have a sneak peak into the script which should be in /sitecore/system/Modules/PowerShell/Script Library/Content Reports/Reports/Content Audit/Items with security for an account
More information about the cmdlets

UPDATE
In case you would like to do this programmatically you can execute SQL query on the database:
SELECT * FROM [Sitecore_master].[dbo].[SharedFields] where fieldid = '{DEC8D2D5-E3CF-48B6-A653-8E69E2716641}'

Comment: I was looking for a way to do this from code. But I will try to see if the functionality used by the powershell plugin, could point me in the right way.
Comment: @MikkelNielsen you can always see how this is done in the script. I assume it iterates over all items but it's worth checking.
Comment: That would also be my idea. Im not a fan of this, but I guess there is no other way. Thanks.

Determine Access rights for a role


The cabinet hinge is becoming less secure, and there are cracks in the cabinet door frame

Question: Over time, the cabinet hinge has progressively become looser, and there are noticeable cracks developing in the wooden component. I'm interested in finding out if there's a permanent solution for stabilizing the hinge with the cabinet door or if there's an alternative approach to resolve this problem.
Comment: 3 answers, all downvoted. Wow, thanks for your feedback.
Answer: I'd go for a 2-in-1 fix.
Part 1…
You need to strengthen the cabinet frame, fill all the existing holes & glue the split section. Then I'd go with Solar Mike's idea of adding a batten on the inside, firmly screwed & glued. This will not only add strength to the existing structure, but provide a basis for part 2…
Part 2…
Replace the hinges. The door insert is a fairly standard construction, so that part will be easy to match, but for the cupboard carcass itself, you now have more thickness to play with, so you can use more standard fittings.
Something like this, which is not only soft-close, for less door-slamming, but also can open to 165° so they won't hit a hard-stop when someone opens the door.

Image from https://www.screwfix.com/p/hafele-steel-165-sprung-door-hinges-67mm-2-pack/559ft
Get these fastened into your new batten [they're a longer throw than your existing ones so that should be fairly easy] & you'll have increased the strength considerably.
Rather than trying to choose exactly the right hinge online, take one hinge & your pictures to a local merchant & get their advice.
Answer: That hinge fixed into the end "grain" or edge of the panel is never going to be strong.
I would be considering screwing and glueing a batten down the inside of the cupboard edge then insetting the hinge into that so it does not just rely on those screws.
Answer: I'd remove everything, inject a thin glue into the crack and screw hole (ie, "chair doctor") and clamp until it dries.
Then, find a screw that's a little longer than the original (if the original was an inch, go with 1-5/8"), predrill (drill bit should be a tiny bit smaller than the root diameter of the screw), and reinstall.
If you have kids in the house, ask them nicely not to push the doors past their normal opening range. These cracks happened for a reason.


A question regarding forcing extensions

Question: Can one, for an infinite set A in ZFC, use forcing to add so many generic subsets of A as to make the collection of all subsets of A a proper class?  Consider now a model $M$ of ZFC and use $Add(  ,  )$ to make the collection of all subsets of any given infinite set in the forcing extension $M$[$G$] a proper class. This forcing extension $M$[$G$] would certainly not be a model of ZFC (the Powerset axiom would fail) but what axioms of ZFC would remain?  Also, if replacement would remain and one 'replaces' Replacement with Collection in $M$[$G$], how would that effect $M$[$G$]?
Comment: What does "replace Replacement with Collection in $M[G]$" mean?
Comment: @NoahS, I believe that Thomas is likely referring to the fact that without power set, the axioms of replacement and collection are not equivalent (see http://jdh.hamkins.org/what-is-the-theory-zfc-without-power-set/). But the issue is moot here, since with this forcing, we get both axioms.
Comment: I guess I was confused by "how would that effect $M[G]$," since that implies some sort of change in $M[G]$ itself - I was expecting to see "does collection remain?" instead.
Answer: $\newcommand\Ord{\text{Ord}}
\newcommand\Add{\text{Add}}$Yes, one may undertake such kind of class forcing constructions.
For example, we can force with $\Add(\omega,\Ord)$ to add $\Ord$
many Cohen reals. As you point out, we won't have ZFC in the
resulting forcing extension, but we will get a sensible model of
some theory. The resulting forcing extension will be a model of set theory without power set, $\text{ZFC}^-$, in which the power set of $\omega$ is a proper class.
Let's be a little more specific. To make things easy to understand
at first, lets start with a countable transitive model
$M\models\text{ZFC}$, and consider forcing with
$\Add(\omega,\Ord)$ from the point of view of $M$. Since this
model is countable, we may find a filter $G$ in this partial order
such that $G$ meets any dense subclass $D\subset\Add(\omega,\Ord)$
that is definable in $M$ using parameters. (There are only
countably many such $D$ and so we can meet them one by one in
order to construct $G$.) Now, we build $M[G]$ by using names in
$M$ and interpreting them by $G$.
Note that the forcing satisfies the countable chain condition by
the usual $\Delta$-system argument. This in effect gives us access
to the Boolean completion of this partial order, from the
perspective of $M$, and we can recursively define the Boolean
value $[\![\varphi(\tau)]\!]$ of any assertion in the forcing
language. We'll have the usual fullness and mixing lemmas for
these Boolean values, and using genericity we'll get that
$M[G]\models\varphi(\tau_G)$ just in case
$[\![\varphi(\tau)]\!]\in G$. (But in fact, we can use the Boolean algebra to form the Boolean ultrapower of this forcing inside any model of ZFC, not just the countable transitive models.)
Thus, the forcing relation will be definable in $M$ just as for
set forcing. Once you have the definability of the forcing
relation, together with fullness and mixing, then you'll get all
the usual ZFC axioms holding in $M[G]$ for this forcing, including
collection, replacement, separation, choice and so on, except for
the power set axiom. As you mention, we obviously cannot expect
get the power set axiom, since we'll have too many reals in
$M[G]$.
So $M[G]$ will be a model of $\text{ZFC}^-$.
One can similarly add subsets to $\omega_1$ instead of $\omega$ or
to any other fixed cardinal, with a similar effect.
There are also interesting situations to arise if one should collapse all cardinals to become countable. This forcing is not c.c.c., but still one gets $\text{ZFC}^-$ in the forcing extension, a model where every set is countable and the reals do not form a set.
Comment: The answer's rather long, but the short version is: I *do* think of every set as "potentially countable," so insofar as I imagine a "real" universe of sets (which I usually don't), it's one with that property. It's also a very useful (for me) picture to have in order to think up counterexamples for things. Also, I'm interested in how ideas around countable objects (ex: computable structure theory) can be "lifted up" to uncountable settings, and I find that such a picture of the universe helps me get the right intuition for things.
Comment: @Prof Hamkins:  Regarding the model where one collapses all cardinals to become countable--can the model 'know' that every set is, in fact, countable?
Comment: Yes, to be countable is a first-order property that is expressible inside the model.
Comment: @Prof. Hamkins:  Thanks.  Might this then be a possible 'home universe' for the so-called "anti-Cantor cranks'?
Comment: Not really, since "the reals are uncountable" would still be true in it - it's just that the reals would form a proper class instead of a set. (That's not to say that this kind of model wouldn't appeal to a certain philosophical stance - personally, I find it very attractive.)
Comment: @NoahS:  Interesting.  What do you find attractive about it?
Comment: @NoahS:  Interesting.  Are you familiar with the Moschovakis papers "Abstract First Order Computability I & II"?

A question regarding forcing extensions


NAND gate LVS problems in Cadence Virtuoso

Question: I don't know why my layout won't pass LVS. I am constructing a NAND gate, and it looks like I have all connections in the schematic and layout fine, but I can't get it to say success. What could be wrong?
1
Comment: are you using the correct layers for your node labels?
Answer: The NMOS FETs out of order.  In the schematic gate "b" is closer to ground but in the layout gate "a" is closer to ground.
The mismatched number of terminals indicates there may be some additional substrate (bulk) and nwell terminals assumed in the schematic devices.  If you query the FETs in the schematic, is there an entry for the well or bulk node?  There probably is, and it's probably for some default node names other than gnd! and vdd!. (I never use the three-terminal device symbols for this reason.)  You'll want to use a dedicated pin for supply and one for ground, as well, eventually, e.g. vdd and vss, rather than the global vdd! and vss!.  Global nets cause all sorts of headaches later (at least in big chips).
Good luck with it.


Expanding a FreeNAS RAIDZ Pool

Question: I am building a ZFS data server using FreeNAS.  I have enough hard disk space (4x2TB) for a few years, but if down the road I want to expand this out can i build another 4xHD pool?  Would i need separate datasets for this second volume or can i just expand the existing ones?
Answer: You have various options. I'm assuming here that you have the 4 disks arranged as a raidz1 (like raid5) layout. Not ideal, but I won't go into discussions about the best disk layout.

You can go and buy big 4/5/8/XTB disks in a few years and just replace the disks one by one. When they have all been replaced the size of the pool should increase.
You can add a second group of 4 disks to the original pool. (Adding a new vdev in ZFS terms). The new vdev should ideally be the same type as the first, so if you first 4 disks are set as raidz1, the next four should be as well.
You can make a new, independent pool out of the new disks.
Comment: A new vdev will just expand the available space to the pool. Datasets are not constrained to one vdev, their data is stored wherever ZFS can find in the pool to put it. This is the main concept of 'pooled' storage. The zpool merges X number of disks into a pool, which just becomes one big storage area for ZFS file systems to put data records.
Comment: but the new vdev, will the datasets overlap between them?  Or do separate vdevs have separate datasets?
Comment: @Dave you can go either way. File system data is contained within a zpool, which is comprised of vdevs (a raidz set is a type of vdev). A system can have multiple zpools, zpools can have multiple vdevs. So it's a whole lot of "how you want to configure it depends on what you want out of it now and later". I tend to keep zpools to a single vdev, so separate zpools for each set of disks, as it's easy to expand things, but you can't shrink (at least not easily).
Answer: Yes. You can swap out the disks in a RAIDZ. You can't change the number of disks. You can also add another RAIDZ to a pool, but you can't remove a RAIDZ from a pool. You might want to take a look at the ZFS Administration Guide before deploying it.

Expanding a FreeNAS RAIDZ Pool


When was the environment variable PS1 created?

Question: I've always seen reference to pwd as being very essential 'back in the day'. These days we have customized command prompts like PS1 that display the current directory and pwd is pretty outmoded. But when did the idea for ps1 get introduced into *nix systems? Watching this from the AT&T archives I can see that PS1 definitely did not exist in the seventies.
Answer: This variable is part of the shell, $PS1 is used in bash, the Bourne shell (sh) and the ksh, it is not used in the csh.
The first UNIX shell was the Thompson Shell (which was also called sh like the later bourne shell, the Thompson Shell was often called osh on systems with both the Thompson and Bourne shell installed.) The Thompson shell used the variable $P for the prompt.
Then the Bourne Shell was introduced which used $PS1 to set the prompt. ksh was based on the Bourne Shell, and also uses $PS1. The csh/tcsh used set prompt = <something>.
So I think the first shell to use $PS1 was the Bourne Shell.
Thompson Shell man page: https://etsh.io/man/osh.1.pdf
Bourne Shell man page: http://heirloom.sourceforge.net/sh/sh.1.html
Comment: So let me add the final answer to **when** did `PS1` first appear. It was 1976 in the Bourne Shell.
Comment: You could do if you wanted to, I expect it just wasn't the convention back then. Remember they would have been using 80 character wide terminals where space was a bit more of a luxury.
Comment: If the Thompson Shell had a variable for the prompt, $P, why did they never customize a prompt to display the working directory?


Use my 27" Thunderbolt monitor with a Macbook that has only DisplayPort output

Question: Somehow this doesn't work out of the box – is there an adapter I can buy that will allow me to connect the Displayport output of my Macbook to the Thunderbolt input of my 27" Thunderbolt monitor?
Comment: No - time to sell something and replace it so as to have matching protocols.
Comment: To elaborate, a Thunderbolt output is backwards-compatible with a DisplayPort *input*, but not the other way around. As @bmike said, I'm afraid you're out of luck.
Comment: Apple's [Tech Specs for the Thunderbolt Display](http://www.apple.com/displays/specs.html) clearly state it requires a *Thunderbolt-enabled Mac computer, including MacBook Air, MacBook Pro, Mac mini, and iMac*
Comment: If Thunderbolt can output (into a DP display) the correct ("old") DisplayPort protocols, why can't it receive the "old" DisplayPort protocols.
Answer: As @bmike, @djacobson, and @jaberg have stated in comments, that will not work. There is currently (as of March 2012) no adapter, nor do I expect there to be one to adapt mini-DisplayPort to Thunderbolt. (The standards were defined to be backward-compatible, not forward-compatible.)
Comment: BOOOO! This sucks ;)
Comment: The good news is that you can return it,  and if not that you can sell it, its still worth a lot. Additionally apple is still selling the 27" LED Cinema Display on the Apple Store, which will work on your Mac. Also note that DELL and HP are making a really nice professional IPS panel series of 27" LCD that offer the same 2560 by 1440 resolution, and those will work with you mac as well.
Comment: I thought Thunderbolt was DisplayPort with PCIe added in? http://www.intel.com/content/dam/staging/image/Kim/lightpeak-process-diagram_610x305.gif. So surely the DisplayPort protocols are the same?
Comment: @Jonathan Yes, Thunderbolt is DisplayPort multiplexed with PCIe such that a DisplayPort device will only read the DP signals. However, a Thunderbolt device would be expecting both signals and the absence of the PCIe part might cause it to think there is no signal at all.
Comment: @CajunLuke, it sounds like they could have quite easily made just DisplayPort work both ways. Someone could create an adapter which produces the PCIe and trick the display.
Answer: No this will not work. Check the system requirements for the Apple Thunderbolt display.

System Requirements
Thunderbolt-enabled Mac computer, including MacBook Air, MacBook Pro, Mac mini, and iMac
OS X v10.6.8 or later

As of yet there is no way to add a Thunderbolt port to a Mac that did not ship with Thunderbolt.


Should I brown meat for a stew before freezing it?

Question: I bought some meat to make a stew sometime in the future. Is it best to brown the meat before I freeze it, or should I freeze it raw?
Comment: If you brown it first, you've eliminated some options.  What if you change your mind and decide to do kebabs instead of a stew?
Answer: It might save you a few minutes when you decide to use it. Meat that has been frozen takes a bit longer to brown, since it will exude a bit more moisture.
But it's probably not worth it. Browning meat, then cooling it to freeze, is a huge hassle. Plus, you'll lose the fond on the bottom of your pan (unless you de-glaze and save that too.) That's a huge amount of flavor loss. You might as well just make the stew and freeze that (which is also good).
If you're going to freeze the meat, freeze it in the form that you got it. Defrost carefully (in the fridge, not the counter) and dry it thoroughly (e.g. paper towels) before browning.
Comment: Cooling to freeze is not *huge* hassle.
Comment: I guess compared to the hassle of browning meat at all, it's not. But it's yet another thing you have to do: take the meat, put it on a plate, let it sit out for at least 15 minutes, then put it in a container.

I suppose you don't even have to do that: as long as it's not an enormous amount it'll get cool-enough-fast-enough in the freezer. But that does strike me as a way to get more freezer burn, as well as potential harm to the other things in the freezer.
Answer: A single portion is not really worth it but a few possible advantages

You don't want to take the time to brown when it comes time to make
the stew
Browned you would not need to wait for it to fully thaw before adding to the stew.
You are prepping multiple stews.  Put each batch in a freezer bag and reuse the pan.  You only have to clean the pan once.


How to make a test process for unit testing?

Question: I recently joined a team of developers that has been working on a software project for several years. I have been asked to create a unit testing test process to improve their output and suggest new test cases and test strategies.
I have been working before as a black box tester with a programming backgrounds; I am not sure how to start and from where as the software they are working on is quite complex.
If you could guide me from where to start.
Comment: Unit testing is programmer's responsibility. If they, as programmers, cannot figure it out, then they are not doing their job properly.
Comment: Sorry, but in the current form your question is way too broad to be a good fit for the QA format of this site. See https://softwareengineering.meta.stackexchange.com/questions/6366/where-to-start
Comment: But FWIW, start with this older SO question: http://stackoverflow.com/questions/1365943/how-to-start-unit-testing-or-tdd
Comment: see [Where to start?](https://softwareengineering.meta.stackexchange.com/a/6367/31260)
Comment: _"I have been asked to **(a)** create a unit testing test process to improve their output and **(b)** suggest new test cases and test strategies"_ A implies that there is no testing being done now, and B implies that you're being asked to append/improve an existing test suite. Both can't be true, so which is it?
Answer: In the first place you have to find out what the team means by "UnitTests".
I found that most teams do not distinguish between

UnitTests

and

automated tests done with a UnitTesting Framework

UnitTest
"real" UnitTests verify a single expectation about the behavior of a unit in isolation.
In this definition a unit is

a small part of the production code with the same reason to change
  (Roy Osherove, "The Art of UnitTesting")

UnitTests are a responsibility of the developer and best done following the Test Driven Developement approach.
automated tests done with a UnitTesting Framework
You can use any UnitTesting Framework to create other kinds of test as well, especially module test, acceptance tests, performance tests and alike.
The difference is that you test a part of the application at its "natural borders". In particular you don't use mocks created with a mocking framework as test doubles for parts not being in the tests scope.
This kind of test are the responsibility of a dedicated tester.
Answer: A simple thing is test coverage. There are even tools which will generate the reports automatically, and then you can see which lines of code are well or not at all covered.
More important are the the "contents" of the tests. Do tests include the "happy path scenario" (where everything works as expected) only, or do they care for exceptions, for edge cases etc.? I do not know tools for that (but I won't exclude that they exist).
I'd also check if they are really interested in Unit Tests only, or also in Integration Tests, Load Tests, etc. Such tests can provide additional valuable information to the system under test.
Answer:
a unit testing test process to improve thier output

Unit tests should be required

But judgement must be used when deciding how much is enough and how good the tests are
Beginning unit testers must learn how to write code, and refactor as needed, that facilitates testing that code. Note I did not say beginning programmers; I mean new to unit testing.

The programmer

writes unit tests for code (s)he writes
writes unit tests as the code itself is written - TDD - test driven development
I promise you that it is harder to write unit tests after the fact.

If y'all do code reviews also review the unit tests
Unit tests should always be run when your code is compiled
Unit tests must be kept current. As your code changes, tests will have to necessarily change too. Do not allow broken tests to simply be turned off or deleted.
One or more persons needs to be the evangelist to teach, encourage, guide, etc.

That is very basic process. There is also the technical implementation. You'll just have to research for your particular development languages and environment.

suggest new test cases and test strategies.

This does not make sense in the context of unit testing. The developer decides on test cases for the code (s)he is writing. I don't know what you mean by strategies.
Answer:
Unit Testing has to be driven by the programmers, period. Any attempt to change that is futile exercise. So rest of the points is more focused on test driven development.
The product should provide a way to test api's (testability aspect of software quality metrics) to test functionality.
As a tester, your test strategy should be driven from the requirement perspective than what is written in code (In code there can be omissions which can never be caught from unit testing).
Once the apis(assuming apis are provided, can be selenium) are published, then test suite should be created in parallel to development.
If there is a continuous integration pipeline, then add the test suite execution as a job to it so that the developers can see the progress of the project.

Effectiveness can be measured in terms of code coverage/number of tests successful/failed
Answer: Your first priority is to get the tools working. Pick a testing framework that works for your combination of language, platform and IDE. Preferably a testing framework that support coverage reports and continuous integration (or find a way to integrate it).
While it is possible to have tests done by custom tools, creating such tool is not your current project. So, do not do that, get something that already exists.

Whoever is responsible for the code should write and review test, or delegate these tasks. It is not a good idea to have others write tests for the developers, have other review the tests may or may not work.

What tests to write?
Considering that we are talking about introducing testing to an existing project, you will not start with real unit tests. The reason being that we are not sure if the code is in good shape to do so. We do not know yet how easy it will be to isolate or mock components. The code may not have interfaces or dependency injection in place to ease testing.
Start by writing tests for your requirements or documentation. That is, if the documentation or requirements say that when you do X then Y happens, make a test of that. Do the same with contracts. If possible, convert these contracts into tests (not always possible).
Any defect found should translate into new tests. If you have the means to use tests to replicate a bug, do so. These will be your regression tests, which purpose is to make sure that when making changes they do not break what is already fixed.
Once you are done with the documentation / requirements, move to increase test coverage. The idea is to make sure that each odd situation is tested, and not use the code path of regular or intended usage.
Once you have added tests to increase coverage of a component to a point where you consider that the easier way to increase coverage is to refactor the code... then do so. The existing tests should give you additional confidence when refactoring. This is when you start molding your code to ease actual unit testing.

All the above is for legacy code. For new code, write tests before and during writing the code itself. Testing should be a consideration in the design of the code.
Comment: Thank you for your answer. The thing is Unit tests do exist but the coverage is pretty low. and the software is very complex and no documentation. I am trying to increase the coverage by adding tests but i believe this is not the right way to go as i am not sure if these tests are really important.
Comment: @M.Elbarbary increasing coverage should aid documentation, and should prevent regressions. So, yeah, they don't contribute directly to software quality, and their usefulness is limitled. Now, going beyond tests, perhaps the project would improve faster if they set a small team to review the code and write documentation. Then you could write tests for any bugs they find on code review and for any new documentation added.


How to upgrade a server from 12.04 to 16.04?

Question: The machine has no desktop, only a command shell. It is running 12.04. I have been doing apt-get update & upgrade weekly for four years. How do I convert it to 16.04 from the command line? I have a 16.04 server install CD, do I boot from that?
Comment: What have you followed that didn't work? Did you tried http://askubuntu.com/q/110477/169736?
Answer: General
You can always upgrade from LTS to LTS, in your case that would mean:

upgrade from 12.04 to 14.04 and then
upgrade from 14.04 to 16.04

As far as i know there is no supported upgrade from 12.04 to 16.04 directly.
Following this approach there is no need for your 16.04 medium
As always, consider creating a backup of your critical files before you start.
Limit to LTS
The way to limit upgrades to LTS without a GUI is to change the value of  Prompt in /etc/update-manager/release-upgrades.
Set it to
[DEFAULT] Prompt=lts

The possible values are

never: Never check for a new release.
normal: Check to see if a new release is available. If more than one new release is found, the release upgrader will attempt to upgrade to the release that immediately succeeds the currently-running release.
lts: Check to see if a new LTS release is available. The upgrader will attempt to upgrade to the first LTS release available after the currently-running one. Note that this option should not be used if the currently-running release is not itself an LTS release, since in that case the upgrader won't be able to determine if a newer release is available

How to upgrade
For both upgrade processes you should always update the current system via
sudo apt-get update
sudo apt-get upgrade

Then start the upgrade via
sudo do-release-upgrade

or - SPECIAL CASE - for development versions (which is valid for upgrades from 14.04 to 16.04 until 16.04.1 was released):
sudo do-release-upgrade -d

If do-release-upgrade command is not found, install it:
sudo apt-get install update-manager-core

Comment: It should be mentioned that the LTS to LTS for 14.04 to 16.04 won't be enabled until 16.04.1, several months from now.
Comment: @ThomasW.: true, while it still works already if you are using -d
Comment: True, but it's hard to determine that from your post, hence the comment.
Comment: Good point , i updated the post slightly
Answer: As far as I can tell, I must edit
/etc/update-manager/release-upgrades
to change Prompt to
[DEFAULT] Prompt=lts
Then reboot and give these commands:
sudo bash
apt-get update
apt-get upgrade

{Reboot again}
sudo bash
do-release-upgrade -c

{check target version}
do-release-upgrade

{I can upgrade from 12.04 to 14.04 now;
upgrading from 14.04 to 16.04 may have to wait until August}
=========
I asked a question about how to upgrade a server from 12.04 to 16.04. I got many leads, links to other sites, etc. Finally, I posted my own answer - the specific commands I must give to do it. My posted answer was gleaned from reading all the other answers.
Every answer has a rating. I assume higher numbers are better. I see that my summary answer has a rating of minus one. I assume this is worse than zero. How did I earn a minus one rating?

Note: all three of my computers already read  "Prompt=lts"


What is the best Drupal module that allows me to embedd videos from Youtube or upload videos locally?

Question: What is the best available Drupal module that allows the user the ability to either upload the video locally or embed a video from a thirty-party video sharing website (ex: Youtube) 2- Is this video integrated with players such as flow-player? 3- Can the video be transcoded to flv or mp4?
Comment: Hey, as Alexandru said, Media and MediaYoutube are great. Here is a tutorial i did on setting the up: http://cleverlogic.net/tutorials/drupal-7-video-setup-using-media-and-media-youtube-module
Comment: I had put a comment on cleverlogic. My Problems now lies in the fact that I don't know how I can display both the embedded videos and uploaded videos in the same view. I would appreciate if you can make a video tutorial which shows how this can be done.
Comment: Hey, that should be quite simple, just add both fields to the view (the one with embedded and the one with uploaded videos), if the node has embedded vids, it would show up, and if its a node with uploaded vids, the uploaded vids would show up too.
Comment: Thanks. After getting it to work, I have written a tutorial about it on my website http://linux-hosting.net/article/uploading-embedding-and-playing-videos-drupal .
Comment: You might want to addd a link to the tutorial as a comment on cleverlogic
Answer: That would be Media module plus the extension module MediaYoutube
To transcode the video to flv or mp4 you will need ffmpeg.

ffmpeg is a very powerful tool to record, convert and stream audio and video. Its a very rich tool almost supporting every format out there in the world.

Or, if you think you're up-to, you can try Kaltura witch is an open source video platform that can be integrated with almost all CMSs (Joomla!, Drupal, Alfresco, Moodle etc). It will take care of uploaded videos for you.