does the equivalence of Poisson and conditional logit models hold for fixed effect panel data and negative binomial models?

Question: Guimaraes et al. (Rev Econ Stat, 2003, 85/1) describe the conditions under which the results from poisson regression models and conditional logit models are equivalent. I am trying to find out whether this result also holds i) for fixed effects panel data; ii) for negative binomial models; and iii) (for completeness' sake) fixed effect negative binomial models. It would be extremely helpful if you could point me to some relevant literature, if it exists.
Comment: Can you give a full citation? Off-the-cuff I doubt iii holds, as the estimate of the dispersion parameter makes the negative binomial panel model not really "fixed effects" - see *Fixed–Effects Negative Binomial Regression Models* ([Allison & Waterman, 2002](http://dx.doi.org/10.1111/1467-9531.00117)), PDF [here](http://www.statisticalhorizons.com/wp-content/uploads/Allison.Waterman.pdf), for discussion.
Comment: @AndyW The full citation is: Guimaraes, P., O. Figueirdo, and D. Woodward, 'A tractable approach to the firm location decision problem', the Review of Economics and Statistics, 2003, 85(1): 201-204. doi:10.1162/003465303762687811
Comment: @AndyW And if I understand Allison&Waterman correctly, I could estimate unconditional fixed effects models by including dummy variables in the specification of the mean. The incidental parameter problem might exist, but seems to be small in this case.
Comment: Well that is the recommendation by Allison in that particular paper, supported by a simulation study with a fairly large cross section (100) and a small number of repeated observations (2). It is unclear to me if the same advice would hold in different circumstances, and/or with more interesting unobserved fixed effects.
Answer: Check out:

Guimaraes, P., and Lindrooth, R.C. (2007), Controlling for Overdispersion in Grouped Conditional Logit Models: A Computationally Simple Application of Dirichlet-Multinomial Regression, The Econometrics Journal. 10: 439–452. doi: 10.1111/j.1368-423X.2007.00215.x

I think it shows the connection to the negative binomial.
Comment: Welcome to the site, @user61841. Would you mind expanding on the connection shown there a little? The citation is helpful, but a little more information would be nice. At present, this is more of a comment than an answer.


The relationship between each harmonic numbers

Question: In Knuth's "Concrete Mathematics" in chapter about numbers below equality is given
$$H_n = \ln n + \gamma + \frac{1}{2n} - \frac{1}{12n^2} + \frac{\epsilon_n}{120n^4} $$ where $0 < \epsilon_n < 1$.
For every $i$ holds $H_{i-1} < H_i$. Is this also true that for every $i$ holds:
$$\frac{\epsilon_i}{120i^4} < \frac{\epsilon_{i-1}}{120(i-1)^4}$$. I was trying to prove that but I can't prove the dependency between $\epsilon_i$ and $\epsilon_{i-1}$. Where can I found a prove or a contrexample?
Answer: If you persue the approximation of $H_n$ a bit further you may find
$$ H_n=\ln n+\gamma+\frac1{2n}-\frac1{12n^2}+\frac1{120n^4}-\frac1{252n^6}+\frac1{240n^8}-\frac1{132n^{10}}+\mathcal O(\frac1{n^{12}}).$$
Hence for some constant $c$ (not explicitly specified in that Wikipedia page), we have
$$ \epsilon_n=1-\frac1{252n^2}+\frac1{240n^4}-\frac1{132n^6}+\frac{\delta_n}{cn^8}$$
with $|\delta_n|<1$. Depending on the ecaxt value of $c$ this gives us that the sequence of the $\epsilon_n$ is strictly increasing either for all sufficiently large $n$ or possibly even for all $n$. Indeed, $e_{n+1}-\epsilon_n\approx\frac1{126n^3}$ already by the first term and the contribution of the last is at most $\approx \frac2{cn^8}$.
Comment: @WillJagy Now it seems to look like what I've get. But your not right. If I asked a question because I couldn't show something and the answer which is given has mistakes, then it doesn't make me any closer to the answer which I am looking for or even didn't give any knowledge, even if I will try to do something on my own, because it is just misleading.
Comment: Thanks for your answer! But can you please specify what values $c$ and $\delta_n$ means?
Comment: The $\delta_n$ are like the $\epsilon_n$ in Knuth, the $c$ is like the $252$ in Knuth, but is here unspecified. But an explcit value *can* be found using the same techniques. In fact, to show only that $\epsilon_n$ is monotonic, it should suffice to make only the constant hidden in $\mathcal O(\frac1{n^6})$ explicit.
Comment: Are you sure you didn't make any mistake in your post, because every time I try to evaluate that, I have a different result than yours. Maybe you can show more steps?
Comment: @rop, you need to learn to do some of the work yourself. All I can see is that the factor of 120 in $120 n^4$ was not carried along, it should go to the numerators that come after, so i get $$ \epsilon = 1 - \frac{10}{21 n^2} +  \frac{1}{2 n^4}  - \frac{10}{11 n^6} +  \frac{\delta}{ n^8}. $$ If that is not quite right, you fix it.


Gravity Simulation

Question: I was looking to see if I could simulate orbits or gravity at least in Blender. Is it possible to set an object as a gravitational source, and have other objects be affected by it realistically? I know there is a gravity variable that effects things in physics sims obviously but can gravity be emitted by an object?
Comment: [Somewhat related](https://blender.stackexchange.com/a/91511/15543)
Answer: You could use a force object as the source of gravity, there is a "Gravitation" check box you can use to make the force proportional to distance.  Turn off global gravity (in the Scene tab).  Giving rigid body objects an initial velocity is tricky but you can use the hack described in this answer:
How can I add motion to a rigid body?
A quick implementation of this concept:

However, this falls short of an "actual simulation" because both objects should be attracted to one another.  Perhaps it is possible to create a gravity force object for each mesh in your sim, and parent the force objects to the meshes?
Comment: Thanks. Maybe Blender will someday implement a real way to simulate gravity, but this is nice. :)
Answer: Are you trying to make GFX? I believe the best way to do that would be to animate it if you're making an animation, I don't really think there is a way to make gravity generate from an object, the only way objects "move" is when you move it or you make an animation and the object moves in it. Such as, depending on what planet the animation is on, animate them jumping to certain heights then falling or something else of the sort. Hope this helped!
Comment: Yeah. Unfortunately, I am looking to do actual simulations. Guess that sort of thing needs to be programmed yourself.

Gravity Simulation


Why am I getting this linker failure building my Unity project in Xcode?

Question:
This image is of my code when I am trying to compile my game in xcode. I have been
working on it for weeks and this is stopping me I have been trying to figure it out for days. Any help would be greatly appreciate!
Comment: Could you try copy-pasting the error code into a readable format? Note that providing an *image* of a *text-based* error code is often not received well. I would do it myself, if not for the immense length.
Comment: it would also help to provide background on what research you have done into this. For example, the error code clearly states that you are missing library files.
Answer: I figured it out. Delete any x code instances of this project, and then re-export with unity(making sure your package name/and icon images are in there) after that open in x code and should work right away. I'm not sure why this is, probably happened from multiple instances of the same object with a few different library files with the same name not linking in the right order or something. Thanks for the responses though!


Can I use MCU's internal oscillator when communicating with GPS and cellular modules?

Question: Can I use MCU's internal oscillator when communicating with GPS and cellular modules? I want to avoid connecting external crystals for the MCU since they generate noise, extra components, extra costs, and on top of that require PCB design constrains and cautions. My MCU is stm32L4
Comment: What do you mean, "communicating" with GPS? You can recieve GPS signals, but you need a dedicated GPS module for that. If you have that, the precision of the MCU clock is not relevant any more.
Comment: Communicating over the UART should be fine off internal oscillator. Unless you're trying to do something like very precise GPS time sync.
Comment: gps uarts are generally slow, and can often be kept slow so that your internal oscillator should work fine.
Comment: if you wanted to say use 115200 if you can find a device that even does that and if your chips uart is 16x oversampled that is 1.8mhz if you are running at 2mhz your accuracy may be pretty bad and not work, but if you run at 16 or 32 or whatever mhz you could even do 115200 well enough.  a gps module at 4800 or 9600 times 16x should be clean enough.  and some peripherals have an 8x oversample mode giving you more relief.  But all of this is covered in the st documentation, just read it please.
Answer: Asynchronous serial communications places demands on the accuracy of the clock. Some internal calibrated RC oscillators are acceptable, some are not, and some are okay  over a limited temperature/Vcc range and/or if you don't have additional errors due to divider resolution (typically at higher speeds).
The receiving party starts timing the data based on when it detects a starting edge. That detection will be degraded a bit if the cables are long and by the number of times it samples within a given bit. Since the framing typically takes place on a per-byte basis, the error accumulates within the byte plus start bit, stop bit partity etc. which is typically about 10 bits per byte. So a 5% error means the receiver is looking at the data 1/2 bit off, which is right at the edge if everything else, including the receiver clock frequency is perfect.
If the other party is using a crystal controlled clock, a worst-case error of ~4% is probably (barely) acceptable. Usually 2% is used as a limit, if you don't have control of the other side.
An MCU with a 1% worst-case initial error (large print number) may have unacceptable or barely acceptable accuracy when all factors such as voltage coefficient and temperature coefficient are considered. For example, a typical spec from a "midrange" Microchip part

If your only need for serial communication is in an office/shop environment for configuration or diagnostics, the above is more than good enough for communications with a PC that is guaranteed to have a proper crystal controlled clock. If you expect it to work in a car, under all conditions, it's not guaranteed to be good enough.
If that is your only requirement for an accurate clock, I would suggest considering a ceramic resonator. It's not necessarily cheaper, but results in a lower parts count and is more rugged compared to a crystal oscillator and is typically more than good enough (0.5% is a typical spec) in accuracy for asynchronous serial communications.
Answer: Yes you can run with the internal oscilator, but you may not want to do all the work to make it happen. Depending on the exact STM32L4 part, you read the datasheet and take a look at the internal oscillator frequency tolerance, taking into account things like initial tolerance at given supply voltage and temperature and then the tolerance at the range of your supply voltages and temperatures. If it is out of tolerance for UART communications requirements (found in reference manual) then you need automatic calibration to stay within the tolerance. If you want to avoid all this, just put the crystal or oscillator there. Also note that the baud rate has no effect on this, only the tolerance.


Yorkshire puddings in a fan assisted oven

Question: Which shelf in a fan assisted oven is the best to use for making Yorkshire puddings?
Answer: I've always done them on the top shelf - leaving enough room for them to rise, if you use small tins.
I started before we had fan ovens & never changed the method when they were introduced.
The 'golden rule' has always been "as hot as you can get it", though you have to open the door at some point to pour the batter, so that also becomes, "as fast as you can do it [without burning yourself]".
I'm pretty sure this is going to be similar to many many other 'old but simple' recipes - there are no two people do it quite the same.
Answer: With Yorkshire puddings you need an extremely hot oven to get the best results.
In a fan oven you put them on the middle rack so that the hot air can blast over the batter, although the top rack seems to work just as well as long as you leave enough clearance for rising, and there will be a lot of that. However, many convection ovens do not go as high a temperature in convection mode as they do non-convection. Mine goes up to 200°C on fan, but up to 275°C non-fan, so I preheat the oil at 275, then I pour in the mix and turn down to 240 non-fan. As I use non fan I put it on the second to highest rack as the top would not leave clearance.
Answer: According to this recipe, you put your pudding on the middle rack.
"Adjust oven rack to center position and preheat oven to 450°F (230°C)."


Android: How to reset and download A-GPS data?

Question: How can I programmatically reset and download new A-GPS data in an Android application? In other words, how do the "Manage A-GPS state" tools work in the GPS Status & Toolbox app?
Answer: You should be able to use LocationManager.sendExtraCommand(String provider, String command, Bundle extras). This will allow you to delete all or part of the GPS data, so it will redownload it. The docs are here, but a quick rundown of the arguments, referenced from this code(for a GPS Provider):
For provider, use LocationManager.GPS_PROVIDER.
For command, use "delete_aiding_data"
For extras, if you pass null, it will delete all data. If you want to delete specific data only(such as just the almanac or position), you can use the flags found in this function as extras in the bundle.
Don't forget to add android.permission.ACCESS_LOCATION_EXTRA_COMMANDS to your permission list in the manifest!
Comment: Thank you very much - this is extremely helpful. Is there any other command that can speed up the process of re-downloading the data after it is deleted? Also, do you have experience with whether it is better to delete only specific data or all of it when the GPS seems to be stuck?
Comment: I haven't used the GPS features of Android much, so I can't say for sure. I can say that on aircraft GPS systems, the entire data is dumped when we do a reset. Traditionally, it can take up to several minutes to reacquire it, depending on what algorithm is used to do initial satellite-finding.
Comment: How do you decide when to do a reset on an aircraft? Is it something that is done just on a routine basis when the plane is on the ground, or is it possible to detect when a reset will be useful based on the GPS performance?
Comment: Basically? When it's not working. It's part of a troubleshooting process. In most circumstances, it's not needed. Of course, "not working" depends on the pilot's whims, and can include degraded performance. That part's a pretty gray area, to be honest.
Comment: that permission doesn't seem to work all the time?  Something about being a "system" app.  Any ideas?
Comment: @daveatflow It shouldn't have to be a system app to work. I'd suggest posting a separate, concise question, with code/manifest examples. The question you posted a few days ago wasn't very clear on the exact problem you are having. Make sure you include any error messages you receive.
Answer: So far, the best answer to my question seems to be a combination of @Geobits' response and the XTRA injection code discussed in Problems with sendExtraCommand and force_xtra_injection. Based on this, I am currently using the following:
locationManager = (LocationManager) getSystemService(LOCATION_SERVICE);
locationManager.sendExtraCommand(LocationManager.GPS_PROVIDER,"delete_aiding_data", null);
Bundle bundle = new Bundle();
locationManager.sendExtraCommand("gps", "force_xtra_injection", bundle);
locationManager.sendExtraCommand("gps", "force_time_injection", bundle);

If anyone has additional ideas on how to improve this, or how to determine the best times to clear and download new GPS data, I would be very interested to hear.
Comment: I think this permission is needed:
Comment: did this make use of a network (data) connection?  Do we need to add permissions to our manifest to allow for that?


what is the reason for probability in half life decay of radioactive elements from a physical prespective?

Question:
If we leave out the math equations how would explain the reason why the decay of a radioactive element is based on probability ?
If say the decay was truly a random event for each atom then would that not mean that its creation of new information (the order in which individual atoms decay) that didn't already exist in the universe ?
Answer: (0) It is a truly random event. Period.
(1) A radioactive atom (nucleus, really) follow Fermi's Golden Rule. It says "that the transition rate is proportional to the strength of the coupling between the initial and final states factored by the density of final states available to the system".
Let's say the coupling between the initial and final states is constant. Let's also say that the density of final states is constant. (Note: this is not always the case, as their are stable atoms that are unstable ions--the Coulomb energy blocks the final states for the neutral atom. There is also research into environmental effects--temperature and density--affecting decay rate. Of course, the inverse beta decay in neutron star formation is an extreme example).
Anyway, with the constant assumption, the the transition rate is fixed. This means that in any short period of time, there is some probability of decaying, which remains constant until the decay. That's how is how the system become probabilistic. Moreover, if you do the math you'll see that you can define a half-life, which is the time period over which an decay has a 50% chance of occurring. It is important to note that this is constant and stays constant. If you make a uranium-238 atom in a reactor today, it has the same probability of decaying by tomorrow as a U238 atom you dig out of the ground--even though the latter was made in a supernova billions of years ago.
(2) I am going to defer on the question of what is the entropy of a random sequence, esp. w/o math. However, I will posit that all possible orderings have equal likelihood, so there is no information in the ordering. Moreover, following the example in (1), since all U238 are indistinguishable--can you even define an order?
Comment: @wavscientist Yes, I think it was done a GSI (Darmstadt), but I can't find a reference. As I recall, it was some midsize stable nucleus that they ionize and store in the ring and the nucleus is now unstable.
Comment: Did I read it correctly that some atoms are stable while being neutral but are unstable when they become ions?
Comment: @JEB for (2) what if we use pauli's exculsion principle for distinguishing the atoms ?
Comment: That is shocking piece of knowledge! I have never heard or read about such effect.If you find any kind of article or study about this phenomenom,post link in comment.


Doubt about installing Ubuntu on my internal HDD

Question: I have 256gb SSD on my laptop with windows installed on it and 1tb HDD internally. I want to install Ubuntu only on a partition of my HDD. Is this possible? If so how? as when I tried it, it only allowed me install Ubuntu on entire HDD and not on only one partition. If I selected only one partition then it would give me "no root file system defined".
Answer: Regarding your question "No root system  defined"
you need to define your partition on the Installation type page...click
on "+" .
This is to create/edit a partition.
Then, you will have to select "/" which is defined as the root.
This should solve the problem.


Sync MySQL database and Quickbooks Database

Question: I use Quickbooks as an accounting software. I also have a MySQL database where I record data on orders, customers, inventory, employees and etc. Is there a way for me to sync the two databases? For example, I would like to enter order details on Quickbooks and would like that order details to be in my MySQL database as well. Can someone please advice?
Answer: quickbooks have completely different database, its not SQL based
For quick books Enterprise you should have SQL data optimizer and you should be able integrate with MySQL. QuickBooks pro and premium don't have that feature but there are third party applications that might do database optimization.


interaction between mathematical structures

Question: From a physicist's perspective there are several situations in which somehow arbitrary choices of mathematical structures can be made. One can describe a system from different perspectives, etc. without changing anything in the physical properties. (see gauge invariance, picture changing etc.) In the situation when these choices impose a mathematical structure one has limitations in the subsequent choices (are these limitations physical???). However, there are situations when this prescription does not hold. The best example is in this case the Black-Hole complementarity principle (if it is well defined in the first place). So, the question about how mathematical structures "interact" in a logical way is not a bad one. Again: what is the interaction between, say, locality and Hausdorff-ity in the case of a black hole? Or what is the true relation between metrizability and hausdorff-ity of a space in the context of a black hole? The question about how mathematical structures assigned (innocently) at some point interact in different situations is in my opinion a quite relevant one...
Answer: I guess you mean the sort of 'interaction' between structures (though I would call it 'interlocking' or something similar) that Gowers describes in this blog post. It is of course crucial, when one postulates two different structures on an object, to have some interplay between the two, or you will not get any result that cannot be derived from one of the structures alone. A topological group, for example, is not simply a group that has a topology on it: the group operations must play well with it (i.e. be continuous) for the theory to be more rich than just the results of group theory and topology.
However, it is ridiculous to assert that such interlocking of structures would have "unexpected physical effects". On what? Mathematics isn't physically real by itself. You can't "add" mathematical structure to an object, it either has it or not. A physical theory either has one or more mathematical structures, along with their 'interplay' properties, or not. Those structures determine what comes out. If you impose additional structure on the mathematical problem, of course it will predict 'different results'. But then you're talking about a different situation.
Comment: You may know (or not) that in some cases imposing a structure may be arbitrary at some point. However, as you go on, other freedoms in the problem may allow you to introduce other structures etc. Is it clear that in all these cases the interplay between the choices is physically irrelevant? See in terms of quantization prescriptions, but also in the case of Black Hole complementarity.


Is it okay to say "you are asked to do something" instead of "Please do something"?

Question: For example, "For the beginning, you are asked to download the file" instead of "Please download the file".
I know "Please download the file" is more casual, but I want to make sure that "you are asked to" sounds natural in this context.
Comment: 'You are requested not to smoke' on a notice is indeed a very hedged (here polite) variant on 'Please do not smoke'. A general prohibition in that area.  However, your friend might tell you 'In the driving test, you are asked to do an emergency stop'. This means it is one of the test components.
Comment: @EdwinAshworth - You're right, but what about this particular context? Can, for example, a teacher tell his students, "For the beginning, you are asked to download the file and..." to mean "For the beginning, please download the file and..."?
Comment: 'You are asked to ...' is an impersonal (though still polite) framing of a request. Nobody addresses someone that way when they mean "Please ...". (Note I've changed to double inverted commas to signal switch to direct verbal address.)
Answer: 'Being asked to' is a more impersonal, non-specific way of conveying this, and could fit better in other contexts like, for example:
"If you are asked to provide and explanation, you'll have to make yourself clear."
"When you were asked that before, did you know the answer?"
It is used when you choose not to specify who is asking, often because it turns out as unimportant. If your sentence "For the beginning, you are asked to download a file" is said in the context of a class in which you'll be asked to carry out a series of things it would be overall okay, though it is rather an odd expression that of "For the beginning" if there is not an 'of' immediately after as in "Everything is set for the beginning of the operation." which is not the case.
In the same context, if you say, on the contrary, "I want you to/ I ask you to download a file" this would be deliberately unnatural, as it would imply directly that the person who is asking you to download the file has a personal or a particular interest in you doing so. If this person is your professor or your teacher, this would not be remotely the case.
Other ways to convey the same thing could be:
"At the beginning, you'll be asked to download the file", which to me, sounds way more natural without further context given.
"At the beginning, they will ask you to..."
"To start off, you will be told to download the file".
"First, they will gauge your technical knowledge by asking you to download a file".
Hope it's useful.
Comment: Hi, Alanis. This is a good answer, but it would be better if your sentences started with capital letters and ended with punctuation. Please [take the tour](https://english.stackexchange.com/tour) and read about [good answers](https://english.stackexchange.com/help/how-to-answer).
Answer: No. Never ever write instructions in the passive or using any other language contortion that makes the meaning less obvious. As far as I am concerned, this includes politenesses. For example, if you had discovered a fire would you shout

Occupants are kindly requested to evacuate the building.

or

Fire! Get the hell out of here!

The key principles against which you should judge any instruction you write are clarity and brevity. Do they communicate your idea effectively in as few words as possible?
In the example given

Download the file.

Is all that is required. More would be less.
Comment: But my sentence is not intended as an instruction. It's just a request.
Comment: Why is it a request? Do you gain from the person downloading the file or do they? If they gain, why use please?


How to use .key and .crt file in java that generated by openssl?


Test if an element is focused using Selenium Webdriver

Question: I'm really surprised I can't find  references on the internet to testing for element focus using Selenium Webdriver.
I'm wanting to check when when a form submission is attempted with a mandatory field missed, focus is moved to the empty field. But I cannot see any way to do this using the WebDriver API.
I will be able to find the focused element using a JavascriptExecutor. But reading the FAQ makes me think there must be some way to perform the check using the driver itself.
Thanks for any help.
Answer: driver.switchTo().activeElement() will return the currently focused WebElement.  Equality is well defined for WebElement, so you can call element.equals(driver.switchTo().activeElement()).
Calling the slightly misleading named driver.switchTo().activeElement() does not in fact switch focus, neither does driver.findElement(), so you do not need to switchTo().defaultContent() after; in fact, doing so would probably blur the current element.
Comment: I have a text field which id="widget_113_signup_username" . I want to verify whether the focus is on that field or not. I wrote the
following code to do this. If cursor is not present on it bb = false, otherwise bb= true. Am I right? Is my code OK?
boolean bb = driver.switchTo().activeElement().equals(driver.findElement(By.id("widget_113_signup_username")));
Answer: driver.switchTo().activeElement();

returns the currently focused element.
Makes sure you switch back after using
driver.switchTo().defaultContent();

Also if nothing is focused the body of the document is returned.
Take a look at this question as well.
In Selenium how do I find the "Current" object
Comment: The answer from Daniel says `switchTo().defaultContent()` is incorrect.
Answer: You can find the active element using selector 'dom=document.activeElement'. Then you can assert whether it's the element you want it to be focused or not.
Answer: The WebDriver is supposed to change focus when you use Driver.FindElement calls.  So you're last element in the Driver context is active.
NOTE: This breaks for any elements injected dynamic (e.g. jQuery), so you'd need to go the script route then.
Answer: @danielwagner-hall The boolean bb = driver.switchTo().activeElement().equals(driver.findElement(By.id("widget_113_signup_username"))); will always pass but it doesn't prove that the element is brought into focus if the element is out of view.
NB: Unable to comment as not enough reputation points.
One way of approaching this could be to use webElement.getLocation().getX(); getY() methods and reference the coordinates on the page and verify its focus.


What's a Professor of Practice do?

Question: Are they tenured / on tenure track?
Are they more like clinical teaching professors?
Do they perform research?
I recently saw this job with lots of teaching duties but no research listed.
Comment: Caution: These positions are very rare. I've worked in U.S. academia for a generation and I've never heard of this title until today.
Comment: Just saw that Michael McConaughey is now Professor of Practice at a Texan uni - https://www.southernthing.com/matthew-mcconaughey-is-a-film-professor-at-the-university-of-texas-now-2640088348.html
Answer: This answer will be a little different from that of JoshuaZ.
Yes, such a position is intended for people wanting to build a career as teachers/educators, rather than theoretical researchers. But there are caveats.
First, the job may not come with a tenure track leading to eventual traditional tenure. Instead, as at Duke, after a probationary period the holders get long term (say ten year) contracts that are renewable. The ones I am familiar with also come with various ranks. You don't get a lifetime employment commitment, but you do get security. I know people who have held these positions over a long period. (I actually don't know of a situation in which traditional tenure is offered.)
But it isn't quite correct to say that there are no research expectations. The professors of the practice are expected to contribute to the profession and, normally, to publish and have a presence at conferences and such. But the research is more likely to be in pedagogy than theory. This is the situation in computer science at several very good universities. The people are very active professionally and may be text book authors.
These positions exist when a good university has both a commitment to research in a field, but also to high quality undergraduate education. Holders of these positions relieve the top theoreticians of teaching lower level courses, especially to large classes, but still provide high quality instructors for the undergraduates. Of course, such people are also able to interact with the more traditional research focused faculty.
Answer: This may vary from university to university and department to department, but in general at many locations a Professor of Practice is essentially tenured with a 100% teaching load. This sort of title has become more common, partially with schools taking people who were previously labeled as lecturers or senior lecturers and relabeling them as such. Iowa State University is one example where this happened recently https://www.inside.iastate.edu/article/2018/05/03/fs .

What's a Professor of Practice do?


How can I run Drush as user 1 in version 5?

Question: Drush v3 had a --user flag (--user=1), however, this seems to be removed since v4, according to the website.  How can I run Drush 5 as logged in as user 1?
Answer: See drush topic core-global-options; you will see that the --user flag is still supported.
Of course, you do not really 'log in' to your Drupal site with Drush.  The usual convention is that Drush commands should call API-level functions, which are expected to operate independently of the current user.  (Drupal does access checks before calling the API functions.)  There are only a few instances, mostly in contrib, where setting the user is necessary.
Comment: I am having a problem now a few views API functions. For example, views_save_view() or $view->save() both return false when using Drush to execute scripts with those functions. However, running these in Drupal these run fine and everything works as expected. Are Views API functions different? The closest related issue I could find is here: http://drupal.org/node/1515616 comment #6. Some of my functions are embedded in cron as well.
Comment: note, too, that running 'drush --user=1' results in the list of flag options; running 'drush --user=1 cron' or 'drush --user=1 script.php' still results in permission issues and immediately after 'drush status' still reports Anonymous. What am I doing wrong?
Comment: Sorry, I can't answer your views api question off the top of my head. Perhaps if you posted a follow-up question specifically about calling views_save_view from Drush, someone who knows the answer will notice it.


Corona iPhone Deployment Warning

Question: I have developed a game using corona. Now I get this warning while trying to build for iPhone using new provisioning profile.
<code>warning: Application failed codesign verification.  The signature was invalid, contains            disallowed entitlements, or it was not signed with an iPhone Distribution Certificate. (-19011)
failed to extract requirements data: 1

/Users/codemenmini2012-4/Desktop/ArcheryClassiciOS.app: invalid signature (code or signature have been modified)
failed to extract entitlements: 1

AssertMacros: entitlements_requested, At least need an application-identifier entitlements file: codesign_wrapper.c, line: 879
 - (null)

warning: Unable to extract codesigning entitlements from your application.  Please make sure ArcheryClassiciOS is a valid Mach executable that's properly codesigned. (-19050)
/Users/codemenmini2012-4/Desktop/ArcheryClassiciOS.app/ArcheryClassiciOS: invalid signature (code or signature have been modified)- (null)
</code>
Answer: Have you tried revoking the Profile and requesting it again with a key from your machine? Apples profiles are annoying me quite often, too....

Corona iPhone Deployment Warning


K-fold Stratified cross validation on a dataset with examples of variable length

Question: I have a dataset of audio recording of variable length with large std which are heavily imbalanced in terms of total duration per class. So in stratified k-fold cross validation I would like to main the relative total duration statistics for each class but the common stratified sampling methods work using number of examples per class. So how can I achieve duration statistic preserving stratified sampling?
Answer: Easiest is to transform the dataset into a set of fixed-length samples - as then the number of instances will again be a good measure of the amount of data.
This is often called analysis window in audio machine learning. This has other benefits as well, like making it possible to implement time-shift data augmentation (by letting the windows overlap) and merging predictions over multiple windows. As well as supporting the use of models which expect a fixed-size input.
The other alternative would be to write your own cross-validator splitter, using the logic that you want wrt duration.


Drupal 7 single language views

Question: I have a website which is developed in three languages. I created a taxonomy vocabulary (product category), which is output from the views. Inside the term gallery thumbnail image products. So, how do single language for the gallery to not have to add three times the same image for multiple languages.
Answer: you could set it to language neutral and allow both content in the selected language and language neutral to be shown
Comment: Probably a good answer, but please take some care about editing. Capitals and dots exists for better readability, so please use them, for example :)
Comment: I added content with neutral language. In the settings views I chose filter `No language`, but the content is only visible to the default language. How to fix it?
Comment: Dear Pearson, What do you mean with the default language?
If it is set to language neutral, there is no default language? :)

Drupal 7 single language views


Barney DeVine Circus Performer from Ireland 1800-1860

Question: I'm looking for any information someone might have regarding Barney DeVine who was a circus performer in Ireland and came to the US around 1834.
Comment: Welcome to G&FH SE!  As a new user be sure to take the [Tour] to learn about our focussed Q&A format which is quite different from bulletin boards, discussion forums and other Q&A sites you may be used to.  Please try to ask a single focussed question rather than "for any information".  How do you know that Barney "came to the US around 1834"?  Is it an immigration record that you seek first?
Answer: There is a Barney DeVine who arrived in New York aboard the Howard in 1834. The passenger list, on FamilySearch, states his age to be 21 and place of birth as Ireland.
His occupation, slightly obscured by what appears to be an ink blot, is given as "labourer".

Just to make life interesting, there is also a B DeVine, aged 22 and born in Ireland, who arrived in New York on board the Eagle in 1934. His occupation was also given as "labourer".


How do I keep track of references in a distributed object graph?

Question: I'm developing a distributed system, which must maintain a distributed object graph, where objects can point to other objects, some of which may be on remote computers.  It must also be possible to move objects from one computer to another.
This raises two related problems:

How do we know when it is safe to garbage-collect objects?
If we move an object, how do we robustly ensure that all references to it are updated?

An initial thought is to maintain an exhaustive list of all inbound references.
Of course, this alone isn't sufficient for garbage-collection, as it won't catch cyclic references (same problem as with reference-counting garbage collections).
However this list can be used to ensure that any remote computer with references to the object can be notified if the object is moved.
Another thought is that if an object is moved, it leaves behind a "breadcrumb" on its original computer.  If a computer receives a message intended for an object that is no-longer present, it can be forwarded to its new location.
However it is not scalable to keep such references around indefinitely, how do we know when its safe to delete them?
Can anyone provide pointers to existing solutions to this problem, particularly those that deal with replication and concurrency issues too?
Answer: The most known solution in Java is implemented as part of the RMI spec.
See Garbage Collection of Remote Objects & Distributed Garbage Collection


Performance impact of using functions in WordPress?

Question: I have a website that generates lots of dynamic contents. I'm facing performance issues even on my localhost, on a Corei7 processor.
I've tried to disable every unnecessary plugin, and ran p3 performance profiler to see the results. The resulting charts show that most of the loading time is spent on WordPress's core (not plugins).
I'm using simple functions like if() and bloginfo('name') and call metadatas like get_post_meta() and the_permalink() a lot of times on my pages, one could say maybe up to 50 functions in each page.
These functions seem very simple, however i'm not sure how much impact do they have on loading time.
Is there a way to find out which parts of the page consume the most time? or is there a general guide to understand how much impact does these functions have on WordPress?
Thanks are in orders.
Comment: Have you first tried some simple analysis, like using the online Google page insights, or the firefox plugin 'yslow'?  Might give you some more clues.
Comment: Unfortunately Y!slow no longer works on firefox. However i used the website and it tells me that my server's bandwidth is low. I have performance issues even on localhost tho. This wordpress performance issue is so common, and it has dozens of questions asked already.
Answer: The overhead of PHP function as a mechanism is minimal. After all nearly everything going on is function calls. On a reasonable hardware you will have to ramp up function calls into thousands and tens of thousands to generate significant overhead (as opposed to doing same things with less function calls involved).
Worth noting that PHP profilers tend to overestimate the impact of function calls. Xdebug is especially eager to do that. More so just having Xdebug enabled can slow things down in environment heavy on function calls.
P3 profiler uses PHP ticks mechanism to profile, which is highly unreliable.
For any realistic outlook into performance you need to use a profiler that works on PHP engine level, such as Xdebug or Blackfire. In lack of such your performance troubleshooting options are very limited and basically amount to stuffing code with timers and ripping it apart until you figure out the slow part.
Answer:
p3 performance profiler

This plugin worked well, but now I found it is not a good quality anymore. Have you noted the same?
You should relax and let the web server do stuff. Pick smart plugins from trusted authors.
When you write themes or plugins do as much as possible ob_start() magic to buffer your output.
I wish PHP will become ahead of time, and thus faster.
Comment: BTW, I really thought [ahead of time PHP](http://stackoverflow.com/questions/41194577/php-to-become-ahead-of-time-complied-language) would be good idea.


What is the meaning of 'Tishbi' in 'Eliyahu haTishbi'?

Question: I've heard the theory that it's a place, but have never heard of a place with a similar name...
Comment: There is a Tishbi junction in northern Israel.  But that is likely named after him. http://maps.google.com/maps?f=q&source=s_q&hl=en&geocode=&q=tishbi+junction+Israel&aq=&sll=35.101934,-95.712891&sspn=45.087229,92.460937&ie=UTF8&hq=&hnear=HaTishbi+Junction≪=32.672164,35.107648&spn=0.011488,0.022573&t=h&z=16&iwloc=A&ved=0CA0QpQY&sa=X&ei=jJMMTrSdOo6G8AOE-OiIAg
Answer: Adding to what jutky cited:
There is a parenthetical note in Rashi to Judg. 20:45* that after the civil war described there, in which most of the tribe of Benjamin was wiped out, some one hundred members of the tribe fled the Land of Israel and ended up "in the lands of Rome and Germany." Those who remained behind - including Eliyahu (or his ancestors) - came to be called "toshavim," residents (of the Land).
* The source given, מ"ע, is Megaleh Amukos by R' Nosson Nota Shapiro (17th century). This and many other such parenthetical notes first appeared in a 1699 edition of Tanach.
Answer: To add a little information to that which has already been presented, the ancient translations all interpret Tishbi as denoting his residence in a particular place. The precise name of that place, however, varies from version to version:
• Targum Yonatan: אליהו דמתושב מתותבי גלעד ("Elijah from Toshav, of the residents of Gilead"). So too Rashi, Rabbi David Qimchi (Radak) and R' David Altschuler (Metzudot Tziyon) on 1 Kings 17:1;
• Syriac Peshitta: ܐܠܝܐ ܕܡܢ ܬܫܒܝ ܡܢ ܬܘܬܒܐ ܕܓܠܥܕ (= Aram. אליא דמן תשבי מן תותבא דגלעד; ie: "Elijah from Tishbi, of the residents of Gilead");
• Greek "Septuagint" (3 Kings 17:1): Ηλιου ό προφητης Θεσβιτης ό εκ Θεσβων της Γαλααδ ("Eliu the prophet, the Thesbite of Thesbae of Galaad"). Aside from the addition of προφητης ("the prophet"), the Greek translator has understood "residents" (תושבי) to be the name of the place from which Elijah came;
• The Latin Vulgate (also 3 Kings 17:1) is painfully literal, but differs from the Greek: Helias Thesbites de habitatoribus Galaad ("Helias the Thesbite, of the residents of Galaad"). Presumably, they are also interpreting Thesbite as a geographical marker, but it is unclear whether they understand the town to be named Toshav or Tishbi.
In accordance with the Syriac, the HALOT lexicon interprets "Tishbi" as being the name of the place. In favour of that suggestion, note that Tishbi is also the name of a town in Naphtali, in which Tobias lived in the apocryphal Tobit 1:2.
Comment: @DoubleAA - that is an *extremely* paraphrastic translation, and it looks like they've taken lots of liberties with the Greek text. [Here](http://etext.virginia.edu/etcbin/toccer-new2?id=KjvTobi.sgm&images=images/modeng&data=/texts/english/modeng/parsed&tag=public∂=1&division=div1) is a more literal one, from the KJV. The one I'm looking at is in print, by R.H. Charles. He notes in the apparatus an Aramaic fragment that reads: והוה יתיב בתשבי קרתא.
Comment: I don't see such a name http://daat.ac.il/DAAT/hasfarim/tuvya-2.htm#1
Answer: Here is some info about Tishbi.
There is written that it is either a name of city (which has not been identified) or another form of the word "תושב" (resident)
Comment: The link is in Hebrew. Can you summarize it or give a rough translation?
Comment: @ninamag I did summarized it in my answer.
Answer: The wonderful sefer Ramot Gilad by Rav Eliezer Weisfish (unfortunately not on Hebrewbooks.org) which is an encyclopedic work on Eliyahu Hanovi brings that Josefus in Kadmoniyos Hayehudim (book 8, 319) writes that Eliyahu came from the place Teshev in Gilad. This might be the same town as the Toshav brought by an earlier correspondent from the Targum Yonasan. The sefer Seder Hayom (https://hebrewbooks.org/pdfpager.aspx?sits=1&req=41230&st=%u05EA%u05E9%u05D1%u05D9&_rnd=0.7797483451474362) suggests that he was called that because as someone who lives forever can truly be called a Toshav, rather than Ger which applies to everyone else who only live for a certain amount of years!
The sefer "Yichusei Tanaim Ve'amaraim" (page 328 -Hebrewbooks.org only seem to have the introduction of this sefer) writes that Eliyahu caused people to dwell in a town in Gile'ad and as such was considered as if he built it.
Based on Pirke DeRebbi Eliezer ch 47 (https://hebrewbooks.org/pdfpager.aspx?req=22744&st=&pgnum=180) he suggests that he was possibly called like that because he caused, and will cause, people to do tshuva.
From Rabeinu Rokeach the words Hishbiso ((Ruth 3-14) and Taashiv (Eicho 3-63) which refer to the coming of Moshiach, in which of course Eliyahu is involved, have the letters (Ha)Tishbi referring to him.
He quotes one more pshat from the Sefer shaar Hagilgulim (hakdama 32) but as I don't understand it properly I can't quote it.
Answer: The word "תשבי" Tishbite, begins with the root word "שב" and means "to return".  Adding a yod to the end makes it plural and becomes the word "שבי" meaning "to dwell". With the preposition tav the word becomes "He shall return to dwell".  This definition makes more sense in the context.  The word Elijah is a compound of the words "El & Ya" meaning "My G-d is YHVH".  The passage then reads "Elijah the Tishbite" or "G-d is YHVH, He shall return to dwell".
Comment: Welcome to Mi Yodeya and thanks for your information. Any source or evidence for your claims would be most useful, [edit]ed into your answer. Otherwise we have only your word to take for this. Note that normally, AFAIK: a _yod_ at the end of a root doesn't make it a plural; the plural of "return" isn't "dwell"; and a prepended _tav_ doesn't mean "he will".


Is the TC ("terminal count") output of a 4-bit sync counter (74163) reasonably assumed to be glitch-free?

Question: My gut tells me so, but the proof eludes me.  Effectively this output is the AND of all four bits.  These four bits go from 0 to 1 at very distinct times, assuming the counter is running at a reasonable clock rate.  From this, I assume that the TC output's transition from 0 to 1 is safe.  But what about the other way?  When the counter rolls over and all bits go from 1 to 0, may I assume that TC makes a glitch-free transition from 1 to 0 as well?  I sense that I'm missing some elementary rule of thumb here.
Comment: Speaking cynically, I don't think you can trust it to not glitch.  However, if you follow the data sheet recommendations for clock rates you can trust it to have settled out when the next clock pulse comes along.  So I wouldn't try to clock something from the RCO, but I'd certainly trust it to be used as it was intended.
Comment: there will be propagation delays of Clock to Qout. Respect those numbers.
Answer: I'm assuming that you are referring to RCO, the ripple-carry output, rather than TCO.
No, you can not assume that it is glitch-free. In fact, the Texas Instruments datasheet says

counting spikes may occur on the (RCO) ripple carry output
Comment: Nope, not the RCO.  The '163 is a sync counter.
Comment: @Aaron Synchronous counters can still have a ripple carry output.
Comment: Thanks, Heath.  Let me scope the question further to the '163 in that case, as it's the part I'm working with.  I don't see mention of spikes/glitches in the docs for this part, and the output for the '163 parts seems to be universally referred to as TC or TCO.
Comment: The naming seems to vary, http://www.ti.com/lit/ds/symlink/sn54ls161a-sp.pdf uses RCO, https://assets.nexperia.com/documents/data-sheet/74HC_HCT163.pdf uses TC for the same signal.
Answer: No, I don't think you can assume it will be glitch free.
The problem is not that the expected low to high and high to low transitions will be glitchy, in fact those transitions are likely to be glitch-free.
The problem rather is that the output may briefly glitch high during counting. For example during the transition from 1101 to 1110 if the units flip-flop is slightly slower than the twos flip-flop then the data outputs may briefly be 1111 and thus the TC/RCO output may briefly go high.
Comment: Thanks Peter - Ugh.  Yes, of course.  Ought to have thought of that!


There is any simple way to forming handmade paper pulp?

Question: I want to know how can I make a form for forming handmade paper pulp for something like paper egg container. There is possible to make small hand press from for example wood/steel and pressing that pulp only by hand without special machines. Im thinking about something like that but the other shape not flat, maybe something like diamond shape. There is possible making something like paper egg container from only handmade paper pulp?
Comment: Do you want to make the pulp or just make an egg container? I would first shred the source material so it breaks down quicker.
Comment: I knowe some about making paper pulp from the paper garbage but I want to know simple way to shape that to make small egg container, something like that but using diy method https://youtu.be/CA9xBSb9NZI
Comment: Well, papier-maché ie laying small strips of paper is a simple method. Had lots of fun making dinosaurs with kids as they grew up.
Comment: the handmade paper from old newspapers will save shape if the press squeezes it with the right strength and time and then it dries?
Comment: What press? Not mentioned in your original question... And "handmade"...
Comment: There is also an [Arts and Crafts SE](https://crafts.stackexchange.com/).
Answer: My recommendation would be to make a mold. Materials:

Egg container

Plaster of Paris

Vaseline

Small box that allows a couple of inches of space on all sides
Take a egg container, Vaseline the outside lightly of the egg container, use mixed cement or plaster of Paris (my preferred material), pour half of the plaster in the box, press the egg carton into the plaster and let dry (you might need to weight the egg container so it doesn't float out of the plaster). Now, you have the bottom half of your mold, Vaseline the inside of the egg carton lightly and the top of the plaster, pour the plaster into the box making sure to have a couple of inches of thickness, and let dry.

You now have your molds. Make your paper pulp (drier is better) pour in the mold and clamp the other mold into it gently and let it dry (probably a day or two until you can separate them.
Comment: Wow, perfect answer! I'm gonna try this


How to create trial account for Salesforce Marketng cloud

Question: How to create trial account to access Salesforce Marketing cloud
Answer: A free Marketing Cloud Developer Edition was released at Connections in September 2014 but was only available for a couple of months. If you didn't sign up during that period, then unfortunately you missed out.
I enquired about the availability of the Developer Edition at Connections last year and Salesforce explained that while the public program had been discontinued, free Developer Edition accounts are still available, by request.
I would suggest you contact your Salesforce Account Representative to enquire if you can get access to an account (I'd suggest that you also explain what you intend to use the account for).
Answer: http://www.salesforce.com/ap/marketing-cloud/overview/
In the above link, you can click on any of these to create trial accounts.


Does Windows 7 Updates really improve your system performance?

Question: Till now I can not say I have ever seen a performance improvement or infact, any significant changes after installing Windows Updates. So my question is, how necessary is the updates for a Home user? I know Service Packs have relevant updates for certain applications propriety to Microsoft, but that is not pointed out. I would just like to know if it is really necessary and what the chances are for your system to be slowed down by the updates.
Answer: The main focus of Windows updates tends to be security patches, as opposed to speed enhancements. The reason you have not seen any "significant changes" is because the updates are patching very specific circumstances, which may lead to system vulnerability. A full explanation of the reason and workings of each update is given in the Windows Update window.
In my opinion, you should download and install all updates, since there will be good reason for Microsoft to be distributing them.
Comment: Unless it is that recent update that causes chkdsk to run on every boot (http://support.microsoft.com/kb/2839011).
Answer:
Does Windows 7 Updates really improve your system performance?

No, definitely not, but nevertheless you should install ALL of them :)
Take a look at this answer please: Which of the Windows updates are really necessary?
Answer: Most updates fix security issues, but there are some Performance updates. MS bundled 90 updates in an Enterprise Hotfix Rollup which also helps home users because they include fixes for faster booting:
KB2510636 - An update that improves the startup performance of Windows 7 and of Windows Server 2008 R2 is available
KB2555428 - The Windows 7 startup process is slow when you create many restore points
KB2505454 - The startup process is delayed on a computer that has a large hard disk installed and is running Windows 7 or Windows Server 2008 R2
Answer: I however don't recommand install all updates. Installing updates increases the size of C:\Windows\winsxs. The size easily goes to 10G. You will use up your disk soon.
The disk usage of installing Windows without Service Pack and then installing Service Pack is larger than installing Windows with SP, because Windows will backup files changed by the sp. There is a tool that can make sp permanent by removing the backup files and you cannot uninstall the sp, after which the disk usage should be same as installing Windows with sp.
If you installed AntiVirus software, you face lower security vulnerability. If you don't have AntiVirus software, like me, and rely on UAC to protect your system, don't let malware bypass UAC by exploiting security vulnerability.
I don't install antivirus software, nor install windows updates for four years and I am not infected by virus. You may become a computer expert to take the risk and win benefit.
Comment: That's like not vaccinating yourself against measles because there's a chance you still might get measles. The sensible course of action is to get vaccinated (install patches), then see a doctor regularly (scan with anti-virus). Sitting in blissful ignorance and exclaiming its just as good as taking precautions is at best stupid and at worst dangerous, what if someone not in the know came here, saw your unwise opinions and took them as gospel, only to find that 3 months later all their personal details now belonged to Boris in Czechoslovakia.
Comment: this is foolish advice, you have no idea if you're infected with a virus or not, most specifically make themselves impossible to manually detect whilst stealing your personal details, mainly through java and flash which are notoriously insecure.
Comment: Even if you installed all updates, you have no idea if you're infected with a virus or not neither.


How do I reload my vimrc without leaving Vim?

Question: When I do a change in my .vimrc, I usually exit Vim and open it again. Is there an easier way to reload the new .vimrc changes?
Answer: Run:
:source $MYVIMRC

inside Vim to reload the vimrc file. Or, a shorter version:
:so $MYVIMRC

as mentioned in a comment by kenorb.
You may also find it useful to map either of these forms to a key. For example:
nnoremap <Leader>r :source $MYVIMRC<CR>

Comment: Save two more keystrokes with `:so %`. `%` is set to the current file name of the buffer you edit, in this case `$MYVIMRC`
Comment: Shortcut: `:so $MYVIMRC`.
Comment: By far the easiest way to do this is to automatically reload the vimrc upon save - check the other answers.
Comment: @kenorb: I've added this possibility; thanks for mentioning it!
Comment: `:so $m`  ← extra-short-cut
Answer: If you just want to reload the file once in a while
:source $MYVIMRC

as Paul wrote is correct. If you end up changing your vimrc often, you could add something like this to your vimrc file:
autocmd BufWritePost .vimrc,_vimrc source $MYVIMRC

This will reload the file when you write it (from within that vim session)
Comment: note a vimrc file can also be called other things: for example vimrc (if it's in ~/.vim).
Comment: johannes: Do we need to edit the .vimrc through vim for this command to automatically source the file?
Comment: @SaiManojKumarYadlapati Yes, AS said this has to be the same vom session. Bufwritepost is triggered when vom does the write
Comment: Problems with this: (1) doesn't work with `.vim/vimrc`, (2) will create duplicate `autocmd`s so each subsequent save will be slower as file will be reloaded multiple times, (3) doesn't behave with vim-tiny which doesn't have autocmd and is still the default on some linux distributions. See my answer to address these issues.
Answer: " Quickly edit/reload this configuration file
nnoremap gev :e $MYVIMRC<CR>
nnoremap gsv :so $MYVIMRC<CR>

To automatically reload upon save, add the following to your $MYVIMRC:
if has ('autocmd') " Remain compatible with earlier versions
 augroup vimrc     " Source vim configuration upon save
    autocmd! BufWritePost $MYVIMRC source % | echom "Reloaded " . $MYVIMRC | redraw
    autocmd! BufWritePost $MYGVIMRC if has('gui_running') | so % | echom "Reloaded " . $MYGVIMRC | endif | redraw
  augroup END
endif " has autocmd

and then for the last time, type:
:so %

The next time you save your vimrc, it will be automatically reloaded.
Features:

Tells the user what has happened (also logging to :messages)
Handles various names for the configuration files
Ensures that it wil only match the actual configuration file (ignores copies in other directories, or a fugitive:// diff)
Won't generate an error if using vim-tiny

Of course, the automatic reload will only happen if you edit your vimrc in vim.


How to force upgrade of PulseAudio at Raspbian 8?

Question: Is it possible to upgrade PulseAudio to version higher than 5.0? If yes, then how?
Thanks!
Answer: Version 5 is in the Raspbian / Debian Jessie repositories.
Upgrade to Raspbian Stretch and you will get v10.0
Since Jessie has been 'end of life' for quite a while now (with even the successor of Stretch not too far away) I would say this is the best option.
Answer: Version 5 of PulseAudio is 2014 vintage (I think), which is fairly old. You didn't indicate which version of Raspbian you are using, but @Dirk has suggested you may be using Stretch. If that's the case, there are at least two options:
One is as @Dirk suggested: Upgrade your OS to Stretch, and when you install pulseaudio you'll have ver 10.0-1+deb9u1. You may be able to upgrade to ver 12 on Stretch, but you'll have to install the source, and build it. This may or may not be difficult... you can use Google to do a bit of research, or go to the PulseAudio GitHub page & submit a query.
Another option is to upgrade ver 5 on your current system. As before, you'll probably need to do this by downloading the source code, and building it. Unfortunately, I don't know enough about PulseAudio to tell you whether or not that will break something in your current system, but I will hazard a guess that the package management system will at least warn you before doing something that will make your system unstable.
Let us know if you run into any issues, and we'll try to help further.


circular saw bevel screw

Question:
hi - Please guide what this thin screw is for and how it used. I searched a lot but no luck. Not even in product mannual.
Comment: Stanley SC16? If I understand what you're pointing at, it is a travel stop as detailed below.
Comment: Please [edit] the question and put the model details in the body of the text.
Comment: Hi, welcome to StackExchange. We're going to need a *much* larger (and in-focus) photo of the screw to give us any idea of what type of screw it is, since "bevel screw" is not a recognised term. But since this screw wasn't included in the product manual it is possible it ended up in the packaging by accident, such things do occur occasionally on production lines.
Comment: Does it bump up against anything solid when you have the blade at 90 degrees to the table? If so, it's an adjustment screw that should reliably get you squared up.
Comment: Yes Stanley SC16
Answer: It's very hard to tell exactly what screw you're talking about from that distant and blurry picture. However there are a couple of possibilities.

You're talking about the large screw with a large knob. This is used to tighten/loosen the screw that holds the sole plate. Loosening this allows the sole plate to pivot, allowing the saw to cut at an angle other than 90°. There is a scale on the curved piece that will, when adjusted properly, show you what angle you're cutting at.

There are small screws, 3-5mm in diameter, with a small hex inset near the sole plate tilt mechanism. These are travel stops that are designed to be used once and forgotten about.
Use a known 90° to get the sole adjusted to exactly 90° from the blade and set the 90° stop.
Using a known 45° angle to get the sole adjusted to exactly 45° from the blade and set the 45° stop.
Theoretically, these should never have to be adjusted again, but theory rarely matches up with reality. It's good to check blade angle every now and then, especially before making a critical cut.

Funny, five days later and I've just realized that saw says "Stanley" on the label, not DeWalt so the comments below about DeWalt (and the link to their repair site) don't really apply, the 3rd party part suppliers should both carry parts for them, and the recommendation for finding the official Stanley parts supply is the same as that for finding the DeWalt parts site.

If you're talking about the screw in your fingers (which I just saw). I'm not sure what that one's for, but you're right, it's probably not in the manual because DeWalt tools rarely come with a loose screw that needs to be installed. (I know, I've got a lot of 'em!). I'd suggest using DeWalt's own service/parts website (which shouldn't take much searching for - go to DeWalt.com, then click on "service" - it'll take you right there), or a third party site like https://www.ereplacementparts.com/ or https://www.partswarehouse.com/ (both places I've shopped at and gotten good prices & service from - no other affiliation).
Once you've picked a site, enter your tool's model number (generally 3 letters, 3 digits, possibly 1 more letter, though other possibilities exist). It will then ask for a "Type". Both the model & type will be listed on the tool's label. You'll get a parts diagram and parts list - you can search for "bevel screw" (not a term I've heard of, despite having just made repairs to my cordless circular saw) in the parts list, and the numbered drawing will show you exactly where the part goes.
Comment: Well bravo, it's hard to provide a good Answer to a poor Q but you've sure managed it!
Comment: Thank you for the kind words! I usually refrain from answering until we get better details, but, unfortunately, further details are often not forthcoming, as evidenced by this question.

circular saw bevel screw


Vaadin SQLContainer Commit Only Single Row

Question: I have a problem with the SQLContainer in Vaadin. commit() will committ all changes to the database. I only want to commit a single row to the database.
The situation is that I have a TableQuery and a Table where the user can add and remove new Rows. Each row has properties that can not be null. The problem is, if a user adds 2 new rows to the table and deletes one. The SQLContainer tries to commit everything and will throw an exception because 1 item has null values.
Is it possible that I can tell him only to commit the rows I want him to ?
rollback() would revert all changes. The problem is that the user can remove item that are already in the database or the ones that are only temporary in the memory.
Would it help to create a RowItem because that one has a commit method ?
Answer: You can commit after added evry of new created item by user. It is not optimal solution but it may solve your problem.


Do launch vehicle companies like SpaceX and RocketLab use magnetometers in their IMU units? If not, why?

Question: I am aware that most launch vehicle companies use strapdown IMU systems, consisting of gyros and accelerometers. I was thinking if one could use a magnetometer and accelerometer to get data (like they do in mobile phones), since calibrating a gyroscope seems like a difficult task.
Comment: Calibrating a magnetometer isn't a simple task. For example, in mobile phones, you often need to wave the phone in a figure eight pattern. Magnetic fields are also prone to interference, especially in the high tech, high metal content body of a rocket. Additionally, earth's magnetic field is not constant. Magnetic field strength and direction changes depending on your location on Earth and your altitude.
Comment: Calibrating a gyro isn't a particularly difficult task, at least when compared to other steps in building a rocket. It just requires knowing exactly how fast it's rotating, which is fairly easy if it's on a test bench before being integrated into the avionics, or indeed bolted firmly to a launch pad before ignition.
Comment: @Dragongeek I was thinking about that as well. Maybe it can be used for model rockets(big maybe), but that's for a different thread to discuss in.
Answer: As a disclaimer: I do not have specific information nor any connection to those companies, I would expect such details not to be public and trust no one to be a reliable source for industry intellectual property except the specific person who developed and deployed the technology.
There are plenty references and methods for calibrating an magnetometer as well as calibrating IMUs, I do remember doing both these tasks.
The big bottomline I've got from my limited practical experience was:

The magnetic field in any place is subject to a lot of disturbances. This gets worse around electronic equipment and metal artifacts. So even if you had a perfect mangnetometer which required absolutely no calibration, for any purpose that would require having a comparison reference (such as attitude determination), the achievable accuracy would be very limited. Meanwhile, good inertial systems achieve fairly good performance
As magnetometers do require calibration, that should preferably be performed when installed on the target platform, the platform itself is also required to move. And as you can't play much with a rocket's position, (same as you can't do so with an airplane) then maybe you shouldn't trust magnetometers.
Given the earlier points, I am aware of some aircraft which carried magnetic based attitude determination systems as independent backup for the IMU, the reasoning being that someone someday required an independent fallback method of attitude determination (though allowing for poor attitude estimation) for safety reasons. But notice that for a small aircraft the pilot is also available, but for a rocket that needs to guide itself its instruments should be even more reliable.
I am aware of some rocket designs which performed stationary alignement (I've worked with in-flight alignment but that was more pure research). This procedure is well known and does allow calibrating a gyro. It's complex and delicate indeed. But as far as I was informed, this is both a necessary and there are well-mastered methods for this application.
Hence, even if calibrating gyros is difficult, it is also mandatory. While calibrating magnetometers is not only difficult but it's ineffective and unnecessary.


Gimp make new image from selection or layer

Question: What is the fastest way to make a new image out of the selection or selected layer?
I thought I remembered it was as easy as dragging it to the top where the tabs for different images is but can't remember.
Answer:
Make a selection with a selection tool, or use Ctrl+A to select the entire image on the selected layer

Copy it using Ctrl+C

Do File > Create > From clipboard, or use the short cut Shift+Ctrl+V

It is also possible to create a new image from a layer by clicking and dragging a layer from the layers panel, and drop it onto the toolbar.
Comment: That's the one. Dropping it onto the toolbar. It's a bit un-intuitive but it's fast.
Answer: The instructions work perfectly, and the creation of the new file from layer is near-instantaneous, but I just encountered enough trouble regarding precise communication as to cause me to create this account, log in, and advise that, where above, per Billy Kerr and Scrampus, you see "toolBAR" you might do well to instead read "toolBOX".
I spent far too long futzing around looking for a "toolBAR", even going so far as to futilly Google for it, and of course it's all my fault, for being thick-headed, but... I have my toolBOX as a separated "window" and it's long and tall, with the variety of tools up at its top end, the color choice overlapping squares down beneath that, and below that, the particulars of whatever tool has been invoked by clicking on it up in the top end.
From the Layers Panel, the layer you want to create a new image from must be dragged into the top end of the toolBOX, at or above the level of the color choice overlapping squares, and when I do it correctly, I get a bit of thin hard-white highlighting around the color-choice area. Done wrong, done too low, down where the particulars of the invoked tool are found, at or below the "Tool Options" divider bar, I get a thin hard-white highlight around that lower portion of the toolbox, but when I drop my chosen layer into it, it bounces back over to the Layers Panel and nothing happens. So you have to watch out for all of that, lest you burn far too much time trying to figure it out. GIMP 2.10.30 running in Linux Mint Mate.


Shellwords.shellescape implementation for Ruby 1.8

Question: While the build of 1.8.7 I have seems to have a backported version of Shellwords::shellescape, I know that method is a 1.9 feature and definitely isn't supported in earlier versions of 1.8.  Does anyone know where I can find, either in Gem form or just as a snippet, a robust standalone implementation of Bourne-shell command escaping for Ruby?
Answer: You might as well just copy what you want from shellwords.rb in the trunk of Ruby's subversion repository (which is GPLv2'd):
  def shellescape(str)
    # An empty argument will be skipped, so return empty quotes.
    return "''" if str.empty?

    str = str.dup

    # Process as a single byte sequence because not all shell
    # implementations are multibyte aware.
    str.gsub!(/([^A-Za-z0-9_\-.,:\/@\n])/n, "\\\\\\1")

    # A LF cannot be escaped with a backslash because a backslash + LF
    # combo is regarded as line continuation and simply ignored.
    str.gsub!(/\n/, "'\n'")

    return str
  end

Comment: Thanks!  I wound up going with the Escape gem (see my answer); but this is definitely a viable option.  BTW, Ruby is dual licensed according to the file you linked.
Comment: With regards to licensing, a snippet this small is fair use (http://en.wikipedia.org/wiki/Fair_use) anyway. As the FSF states (http://www.gnu.org/prep/maintain/maintain.html#Legally-Significant): "just a few lines (less than 15 or so) is not legally significant for copyright."
Answer: I wound up going with the Escape gem, which has the additional feature of using quotes by default, and only backslash-escaping when necessary.


What sustainability certifications are found on coffee bags related to ethical practices?

Question: When looking to buy coffee beans from producers that sustain the local forests, waterways, natural wildlife and reclaiming deforested land, as well as farmer friendly practices, which certifications can help me making an informed choice?
Answer: There is a report by the International Institute for Sustainable Development which highlights 5 different "voluntary sustainability standards" that are being used. The leading 4 in the report's Production Volumes by VSS section are 4Cs, UTZ (now a part of the Rainforest Alliance), Fairtrade International, and the Rainforest Alliance.
Answer: The five standards mentioned in another answer are a good start, but some of them hold little real value. The one that's probably best of the five is Rainforest Alliance, but even that is not immune to issues (see https://abcnews.go.com/US/caffeine-jungle-child-labor-struggling-farmers-found-ethically/story?id=91735230 for recent bad news).
We face this same problem in cacao sourcing for craft chocolate makers. The best solution is harder to scale, but it is DIRECT TRADE, where the roaster buys directly from the farmer in a transparent fashion. The issue with direct trade is the onus is on you to insist the coffee roaster be completely transparent on the trade. Which farm? When? Which harvest? How? Have they visited the farm? Do they continue to visit periodically? How much of that farm's harvest are they buying? If it's less than 100%, ask more questions to see if it's truly direct or through a broker. In cacao, there are some exceptional brokers that are completely transparent, and that can be a good way to go for those buying smaller quantities.
It's a tricky thing that basically boils down to honest, transparency, and trust around the roaster you are buying from.


In what ways is it the best to use a computer in correspondence chess?

Question: I have only recently started correspondence chess and I have
read that engines are allowed in correspondence chess. I definitely do know that the world champions of correspondence chess have said that using engines to a 100% degree is a bad idea.  My question is this: What is the most efficient way to use engines in this format of chess? Any experiences would be helpful!
Comment: Word of caution: engines are allowed in the ICCF (International Correspondence Chess Federation). Engines are by default **not** allowed in "correspondence chess" on sites like lichess.org and chess.com. Read the rules of the organisation you are playing with before starting.
Comment: I found ICCF rules here https://iccfwebfiles.blob.core.windows.net/rules/2020/ICCF%20Rules%20-%20final%20copy%20for%201-1-2020.pdf    "In ICCF event games, players must decide their own moves. Players are allowed to consult prior to those decisions with any publicly available source of information including chess engines (computer programs), books, DVDs, game archive databases, endgame tablebases, etc."  that etc on the end make the rule a bit unclear, but it clearly includes engines.
Comment: @Remellion Excellent comment.
Comment: What is an example of an organization that allows engines?  I skimmed the linked article but didn't find it.
Comment: @Remellion  quote and source for that ICCF rule.   There is no way to tell or police computer use and they have been used ever since Hans Berliner won the world championship using some at IBM.
Comment: @edwinaoliver I said engines are **allowed** in ICCF.
Comment: Someone else here has said that ICCF does not mention it in their rules.   The reason because they cannot police it.  My question is then is it in the rules explicitly or is it not.
Answer: Obviously, as long as they are permitted within the rules of the organization, here is how I would use a computer.
First, realize that different programs are better at different things, and I will divide them into two categories. I heard GMs Peter Svidler and Jan Gustafsson discuss this during the Firouzja-Carlsen game just yesterday.
The first program is for opening play, and that is where Leela shines. I have not had much experience with this program, but Jan mentioned that it can, apparently, blunder at times. They both agreed that Stockfish is still the king of analyzing in the middlegame. I watch a lot of relays of top tournaments, and I follow along with Stockfish, and it is currently the best program out there for the middlegame, and the best part is that it is free.
The next thing is that in most circumstances, I only look at the top two lines (in ChessBase, you can click the little plus/minus sign in the engine box to add/remove the number of lines). I would probably increase this to the top 5 lines for correspondence since there may be a line that fits in better with what you are trying to do, so you can, at least, know to explore it.
Next, in the opening, it helps if you have a good understanding of the opening pawn structure, and the typical plans that are played. As you get into the opening, look at a bunch of GM games from a database to see what they have done before you decide on your moves. Have Stockfish going while looking at them...you never know what you might find if it pops up an unusual eval.
Lastly, and the stronger you are, the easier this is, and the better you will be at it, but you want to play "advanced chess". "Advanced chess" is term for using both the computer and your knowledge to pick the best move. In its infancy, Anand was considered the best at this, and there were a few tournaments where these top players were allowed to use a computer. Here is an article. As part of this cyborg play, and this is the key, you want to force in certain series of the computer's best moves or even some of your own human moves, so, in essence, the program only starts analyzing from that point.
For example, if you and I are playing and we are on move 28, and you just let your computer analyze from there, it may analyze out to move 38. Not bad, but if I am able to force in 7 likely moves based on my 40 years' of experience and the computer's evaluation along the way, and only then let it think uninterrupted, I start at move 35, and might get to move 45.
If you are evaluating a position based on the end result at move 38, but I am evaluating it based on move 45, 7 moves later; I am much more likely to be successful, and win the game.
That is how I would use one if I played correspondence chess. Frankly, I am too impatient so I was never into correspondence in the old days of postcards, but the advent of computers really turned it into more machine versus machine, so that really killed any chance I would get into this in the future; but to each his own.
Comment: I haven't played this way, but it seems like these days whoever knows how to tune their engine and has the most / correct kind of compute power would win.  I can't find the exact quote right now but I recall that Magnus said about computer play that they play like they don't understand anything and then they win.  If computers win by playing weird moves then how am I to judge these moves?
Comment: I would be interested in a match between a grandmaster with a computer vs just the computer with the same specs. I'm not convinced the grandmaster actually adds any strength in the long run.
Comment: I've talked to a few correspondence players on the leela discord who say it's pretty obvious when someone is just letting an engine play for them. Turns out the engines are fallible in ways that are sometimes easier to see than to fix.
Answer: This is by no means complete, but here's a few things.

Use at least 2 engines. More different is generally better. Lc0 and SF would be an obvious pair.
Especially with leela, look at the point of view of the engine. Dig into disagreements.
Realize most of your games will be draws
Make sure you have tuned your engines for long time control. For leela, that typically means using a bigger net since you will have plenty of time to get nodes.
Comment: I contribute with this idea: Look for positions in which several good moves looks almost the same to an engine. Its like a flat landscape. Or on the contrary, look for very complex positions that the horizon is far deep that your opponent will burnt his machine, before finishing on time his analisis.
Answer: I feel a bit like I'm giving away my secrets, but  here we go

Learn how to get the most performance out of your computer setup. For example, you can run analysis 1) in the browser on chess.com or lichess, 2) using a downloaded version of stockfish connected to your GUI, or 3) compile an optimized build of stockfish from source code for your specific hardware. Those are in order of increasing complexity and you gain effective ELO with each step, with diminishing returns as you increase complexity. At the least I'd recommend staying up-to-date with the latest releases.
Don't use engine parameter defaults. For example, things like the number of threads and the hashtable size need to be increased for longer analysis and for maximal search speed. On my primary analysis machine, I have 3 threads for lc0 (one per GPU + one extra) and 21 threads for stockfish, with a 16GB hashtable for stockfish. The total number of threads you use should be the number of cores your system reports. In my example above, I have 12 cores with hyperthreading and the OS reports 24 cores.
Use syzygy tablebases. All the 6-man positions are a few hundred GB IIRC. I'd also suggest a handful of the most popular 7-man positions and store those locally too. Store these on a fast SSD. Learn how to configure your engine to use these, and how to verify that they're working. Having these available will sometimes drastically change the evaluation of late middlegame positions because the engine will have an absolutely true evaluation of some endgame positions as opposed to using its heuristics to evaluate. This will prevent going into lines that look good from the engine's perspective but are tablebase draws, and could lead you toward positions that are favorable but which the engine has a hard time seeing the benefit of.
Track the current engine evaluation of every game you're playing, and spend more time on games where the evaluation is in your favor. The eval tells you how hard to work analyzing variations. For example, if I see +1.3 for me on move 22, I'm going to try to look at dozens of lines into the late middlegame or early endgame if I can to see if I can find lines where the eval holds, or better yet, increases, as I go deeper. The hard truth is that often you'll see the +1.3 advantage just evaporate as you play on, so it's critical to explore and decide if you think you can find lines where your perceived advantage does not vanish.
The corollary to the above is basically don't spend any time on positions that are 0.00 eval. I'd say don't offer or accept a draw in these positions, but choose your move from the 0.00 options and make it after double and triple checking that the position on the board and your move match what you analyzed. If your opponent wants a draw, they have to not mess up and get to a tablebase position, 50 move rule position, or find a threefold repetition and can then automatically claim a draw. I've gotten one or two wins in drawn 0.00 positions where my opponent made a mistake. And frankly, all wins in chess are a mistake on your opponents part because its all probably a theoretical draw from move one. So you might as well play in any 0.00 position because the starting position is probably theoretically 0.00 and no one has qualms about starting a game. If you play move one because you think you have a chance at a win, then you should think you have a chance at a win in any 0.00 position.
Dive into the details of disagreements between engines. If lc0 and stockfish see a position drastically differently, play out the lines and see which engine changes its mind first as you go deeper and deeper. You'll sometimes find that one engine or the other misses a critical move and only sees it when you get closer or in some cases after you've played the move. Use this to your advantage: once you've resolved the discrepancies by going deeper, you have a better true evaluation of the position, while your opponent may not have as good of a picture, and as they play on thinking they are okay according to their engine, you will surprise them with a line their engine missed.
Use MultiPV. This is one no one talks about. Engines will give you their top N lines and sort them by evaluation. So in a position where there are several good moves, I'll start with many lines and let the engine crank for a while. I'll mentally cluster the top moves and reduce the PV to just consider them. For example, if I do a PV=5 analysis to depth 30 and see evals of {0.47, 0.45, 0.42, 0.22, 0.16}, I'll notice that the top three cluster together, then the next moves down come after a larger gap in eval. So then I'll reduce the PV to three, and let the computer crank to more depth on just those three to see if it will clearly separate those three and if one is clearly better than the others. If not, I'll explore all three in depth and decide which line I like.
Using the computer just for record keeping of your analysis is huge benefit to your game. I write extensive comments in my games using my GUI, including my impressions of the evaluation, how many alternate lines I think I should consider, and if/when I think my opponent missed something or played an inaccuracy.
Analyze past games for opening ideas. All the ICCF PGN files are available and can be made into one big database, which can then be viewed in "Show Statistics" mode in the Scid software (for example, there's lots of ways to do this). This shows me immediately what's been played, how relatively popular different opening moves are, and lets me dig into opening lines in depth. If a line is popular but statistically bad for one side, I'll often delve deeper to see if there is an unpopular sideline that is more favorable. For example, there are lines in the Najdorf Poisoned Pawn that are statistically overall bad for black, but if black plays the second most popular move at the right moments, he is fine and will maintain equality. I also keep a separate file of just my completed games (and my current ongoing games). I'll look to my completed games for guidance, e.g., if a move looks statistically bad in the opening database but I've drawn with it many times, I'm more confident that its okay to play (but I'll always check variations to make sure I won't be unhappily surprised).
Use your opening database and engine to find the perfect moment to uncork a novelty. If you see a move has not been played in a previous position and its top or close to the top of engine recommendations, you can consider going for it and bringing your opponent into previously uncharted territory. In my opinion, the earlier you deviate from the database the better, because less about the structure of the position is cemented.
Comment: Very nice writeup! Some small things I would add: in 0.00 positions I think the character of the position matters. In a complicated confusing position you still need to be cautious. However, in a clearly defined settled position indeed you do not need to spend as much time. And, for 10., you can also use the database of your opponents past games to figure out if their repertoire has any weaknesses that you want to probe.
Comment: Those are very good points, thank you! Looking at my opponents openings using the database and planning around their typical play is something I do and I agree wholeheartedly that that is a great way to use a computer when playing on ICCF, and it is one I neglected to include in my answer.


Gifts and Party Members

Question: I am finding a slew of gifts throughout my journeys. Which ones are most appropriate for which party members?
Answer: Some items (like Alistair's Mother's Amulet) you know by the plot whom you should give them.
For the others:

Alistair: statuettes
Dog: bones
Leliana: church (Andraste) stuff
Morrigan: jewelry
Oghren: booze
Shale: gems
Sten: paintings
Zevran: silver/gold bars

A complete list can be found here.
Answer: The Dragon Age Wiki has an excellent write up on the gift system as well as which gifts goto which party member.
Answer: Somewhat tangentially, the Golden Mirror is especially significant if you want a complex relationship arc with Morrigan:

If you have previously broken up with Morrigan, giving her the mirror can restart the romance . . .
If you are planning to get the 'ring' epilogue for Morrigan at the end of Origins, and import the same file to Awakening and get the elusive 'Dark-haired sorceress Morrigan' epilogue, it is advised (although not required) to save this item and not to give it until the epilogue auto-save.
. . . The tricky part is how to import the same character to Awakening and get the 'basic' Morrigan slide at the end of that campaign. The problem with the final Morrigan dialogue at Denerim's city gate is that Morrigan will invariably end the relationship, which alters their status to 'Friendly' at most. . .
Answer: I found out that Wynne has a passion for wine and books, in case you were wondering.
Alistair likes runestones too. The dog loves you already so there is no need to give him bones, unless you want a codex update.

Gifts and Party Members


Can I flash a ROM of another Android version?

Question: I'm currently having Android Lollipop and wanting to flash a Android 6.0 ROM. Would that brick my phone?
Answer: Regarding your first question.
In order to flash a rom with higher Android version you need to

make sure the rom is for your device
flash new bootloader
flash new radio

Note: i recommend upgrading Android version with the OTA update from your OEM (Samsung, HTC, ... etc) because you cannot mess up. And then flashing the rom.
Then follow the usual steps for flashing any rom which are

make sure rom can be flashed on your device
wipe (optionally not including internal storage)
flash rom
flash gapps if not included in rom
reboot

And if you want Root

find a SuperSU version that your ROM supports
reboot to recovery
flash SuperSU zip
reboot

IMPORTANT : after flashing twrp may ask you to root your device Select NO
Note: you know that a rom can be flashed on your device only if your device's codename is in the name of the zip file. For example : paranoidandroid6.0.1_hammerhead.zip
 Here hammerhead is the device codename , specifically nexus 5.
Make sure to research before doing anything.
Comment: What is a bootloader, radio. Why should I flash it, and how? Thanks :)
Comment: @Yayy bootloader explained : http://www.androidcentral.com/what-is-android-bootloader , radio explained  : http://android.stackexchange.com/questions/70/what-is-radio-firmware, you flash them like a regular zip , every device comes with one installed , when upgrading software ,bootloader and radio may need to upgrade too. That's why i recommend to upgrade with the OTA from you OEM, it is much easier
Comment: What if there is no OTA for my device yet? :o
Comment: @Yayy than you either get the radio and bootloader from the team that make the rom or you don't get it at all
Comment: @Yayy Sometimes you don't need to flash them at all. For example: i have a Nexus 5 with Android 6.0 , in order to flash 7.0 rom i don't need to flash bootloader and radio. Now i don't really know if this is device specific or if they are included in the rom. Once again research beforehand and ask on xda forums


Access Google App Engine Hosted Site without using DNS

Question: I have a site hosted at Google App Engine. Its current address is in the format like xxx.appspot.com. Now I want someone to have access to it by typing some IP along with sub-directory, like xxx.xxx.xxx.xxx/dir1/dir2/dir3. How can I do that?
Comment: Could you modify your question to include _why_ you want that kind of setup?
Comment: I would like to tell but the reason is very complicated.
Answer: This would be near-impossible to accomplish. It is easy to set up a GAE app on a custom domain, but it seems the OP has some more specific requirements.
The xxx.appspot.com domain can certainly be translated to an IP address, but GAE's servers will not be able to respond to requests by IP address. It has to know which app you are trying to access, and cannot do so without seeing the hostname. Also, Google might change the IP address associated with your hostname at any time, so you cannot depend on it.
Additionally, making it respond to a sub-path is not easy. If it is at all possible, it would involve altering your app, so that it basically ignores requests to anything but the desired sub-path.
However, I suspect you want to do this because you want to run other (non-GAE?) services on the same IP (that you own), while having your GAE app "installed" on the specified path. This is generally not possible.
You might be able to work around it by setting up a web proxy on the desired path, which forwards all requests to the GAE app.
Comment: Ok, I have nothing much techy like you said in my fourth para. I was also hoping of it being nearly-impossible. Only I want is no DNS. I want site to available at any IP including google along with any how complicated directory structure.
Comment: Ok, I think should mention for that. I have seen many free proxy internet tricks like http://www.tipsplanet.in/2013/01/free-idea-3g-gprs-trick-2013.html that really works. These tricks requires only a host that is accessible by some IP. So, I was planning of installing a proxy script at GAE and try this trick on GAE.
Comment: Yes, proxying could work, but be prepared to do some configuration tweaking to get the sub-path part working.
Comment: GAE is definitelly best free proxy as it is fast, reliable and there is no risk of data mining.


Snappy Loop partition on encrypted disk concern

Question: I was curious about something. I have LUKS FDE on my Ubuntu installation and discovered that using snappy packages creates a snap loop partition. I'm not really sure why this was added or what it exactly is. Will this partition encrypt and decrypt with the rest of the HDD? Will snappy mess with my HDD encryption?
Answer: It is a loopback mount. This type of mount  is a "virtual" thing on your disk, and how some image types are read. It will not affect your encryption. Snap packages are squashfs images, and are loopback mounted, so they may be used.


What is the job of Prakriti?

Question: If its saguna sakara brahman Narayana (Purusha) who creates and preserves everything in this universe, and Shiva (Purusha) who destroys everything, then what is the job of prakriti or shakti?
Comment: you need to understand taratamya of madhva acharya before creation naryana and lakshmi existed. BG 15 : 16 Narayana and Lakshmi are both Akshara but naryana is God..the who is Akshara other than naraya is lakshmi that is prakruthi.. that is material cosmos which stays as atom before creation..its abhimani devatha is lakshmi
Comment: By prakriti do you mean the goddess or insentient matter?
Comment: @Ikshvaku, Both.
Comment: Simple.  Ensure that we stay in maya.
Answer: The question is:

what is the job of prakriti or shakti?

Sri Krishna says in BG as follows:

पिताऽहमस्य जगतो माता धाता पितामहः।
वेद्यं पवित्रमोंकार ऋक् साम यजुरेव च।।9.17।।
Of this world I am the father, mother, ordainer, (and the),
  grand-father; I am the knowable, the sancitifier, the syllable Om as
  also Rk, Sama and Yajus.
सर्वयोनिषु कौन्तेय मूर्तयः सम्भवन्ति याः।
तासां ब्रह्म महद्योनिरहं बीजप्रदः पिता।।14.4।।
O son of Kunti, whatever forms are born from all the wombs, of them
  the great-sustainer is the womb; I am the father who deposits the
  seed.
सत्त्वं रजस्तम इति गुणाः प्रकृतिसंभवाः।
निबध्नन्ति महाबाहो देहे देहिनमव्ययम्।।14.5।।
O mighty-armed one, the alities, viz sattva, rajas and tamas, born of
  Nature, being the immutable embodies being to the body.

The Almighty has 2 forms,ie., sAkAra and nirAkAra -   with form and formless.
The  sAkAra form of the Almighty is called prakriti or NATURE.  Like a Mother it gives sustenance to all creatures.
Answer: I think I read something about it in later chapters on Gita, or in Mahabharat (Don't remember exactly).
It is something like, Krishna says that he created the universe and Prakriti, then gave the responsibility of running this world to Prakriti, then Prakriti created some rules to run the world, Now even Krishna follows those rules, he can choose to break them at his will, but does not.
If you give me some time, I will try to find the exact source of where I read it.

What is the job of Prakriti?