Was the word 'gravity' an invention of Newton?

Question: Before Newton many phycisists try to understand nature and the rotations of planets. But Newton founded his laws of gravity. But was he the first who used the word gravity or when was it first used? And comes the word gravity from the word 'grievous'? Or was Aristotle or Galilei before him using that word? Of course they spoke another language but perhaps the already used βαρύτητα or gravità?
Comment: So maybe we should improve the question.  "Gravity" formerly meant: the tendency of objects to fall toward the center of the earth.  Was Newton the first to change that to: the tendency of two objects to attract each other?
Comment: No it was not. It existed in English language since the times immemorial. It is of Latin origin.
Comment: Hi, welcome to hsm. This question is answered on English SE http://english.stackexchange.com/questions/48469/which-usage-of-the-word-gravity-came-first
Answer: Gravitas is the latin word used by Medieval natural philosophers to translate the Aristotelian heaviness, i.e. the quality of a body "having weight" (pondus):

Let us then apply the term 'heavy' (βάρος) to that which naturally moves towards the centre, and 'light' to that which moves naturally away from the centre. (De Caelo, 269b)

Isaac Newton uses gravity in his Philosophiae Naturalis Principia Mathematica (1687, 3rd Latin ed, 1726):

DEFINITION V
A centripetal force is that by which bodies are drawn or impelled, or any way tend, towards a point as to a centre.
Of this sort is gravity [gravitas], by which bodies tend to the centre of the earth.

Thus, Newton did not invent the word, but was the author of a crucial "shift of meaning": previously "gravity" denoted a quality, then a force.
For sure, Newton "invented" the force of gravity [vi gravitatis].

Note. Galileo Galilei in his Dialogue (in Italian) uses: gravità and leggerezza for heaviness and lightness, respectively.
Answer: Gravity meant weight or heaviness before Newton. Thus Newton writes: "That force by which the moon is held back in its orbit is that very force which we usually call 'gravity'." (Principia, Book III, Prop. IV.)
Comment: @Marijn He means that "gravity" is a common word in general usage by speakers of the English language. The Oxford English Dictionary lists many examples of pre-Newtonian uses of "gravity" in the sense of weight, such as for example: "1646 Sir T. Browne Pseudodoxia Epidemica ii. iii. 72   To overcome the resistance of its gravity and to lift it up from the earth."
Comment: @fdb yes yes, but the point is the same in either language.
Comment: what does he mean by saying: 'we usually call gravity'? Who is 'we' and why said he 'usually'?
Comment: Do you think Aristotels also used βαρύτητα for his explanatioin why earthy heavy things falls to earth?
Comment: @ViktorBlasjo. Except that the Principia are in Latin, not English.
Comment: @Marijn, He does not (I think) ever use βαρύτης to mean "heaviness", though he does use it for "low pitch" and for "arrogance".
Answer: This is a supplement to the two (good) answers by @Mauro Allegranza and @Viktor Blasjo. Although these answers and the question now have some age to them, it seems worth clarifying them by adding some historical perspective to the questioner's (largely mistaken) opening statement that "Before Newton many phycisists try to understand nature and the rotations of planets."
Before Kepler, astronomy was not thought to be a matter of physics, certainly not in the modern universal sense. For a long time, the idea held sway that the world consisted of two parts, quite different from each other (see Lindberg & Shanks (eds.)(2013) 'Cambridge History of Science', vol.2). The lower part was a "terrestrial region extend[ing] downward from the concave surface of the lunar orb to the center of the Earth", a "realm of incessant change", made from the four primary qualities "hot, cold, dry, and moist" or the elements representing them, fire, earth, air, water. In radical contrast, the upper part, the heavens above the sphere of the moon had attributes of perfection and incorruptibility. The heavens were not made of the four terrestrial elements, they were composed of a fifth and aetherial element, or "quintessence", and their motions showed the perfections of pure geometry in uniform circular motions. Within this framework of incorruptible celestial quintessence and perfect geometry it made no sense to think of physics learned from terrestrial effects as having any role.
The title of Kepler's book of 1609 is sometimes abbreviated just to 'Astronomia nova' or 'New astronomy'. More fully, his title in translation runs "A new astronomy, studied by causes, or, Celestial Physics". Kepler's idea that the celestial motions were subject to physical causes was itself revolutionary. He ran into conservative objections, made stiffer by the fact that he not only departed (especially with his postulated elliptical orbits) from the geometrical perfections of circular motion; he also demanded calculations that could not be perfectly executed by traditional demonstrative methods of geometry: they could only be approximated ('Kepler's problem' in Kepler (1609) chap.60, forerunner of the later 'Kepler's equation').
Kepler's ideas were rather slow to find limited acceptance. His elliptical orbits gained credibility by the success of his Rudolphine Tables (1627), especially in predicting a 1630 transit of Mercury across the sun's disk (see e.g. Gingerich (2013)).  But the particular physics that he proposed, to implement his overarching idea of physical causes in astronomy, was not a success: it involved a power of the sun, by virtue of its rotation (and by the help of something like outwardly extending magnetic fibers) to drive the planets around their orbits. The special inequalities of the moon's motion, Kepler supposed, were effects of the sun's illumination.  Kepler also thought that if not for the sun's rotatory drive, the orbital motions would cease and come to rest. (See Bruce Stephenson (1985) 'Kepler's Physical Astronomy'.) The particular physics that Kepler conceived was rather speedily forgotten, even though his overarching general idea of the existence and relevance of celestial physical causes did succeed much later in the hands of others.
There are other indications that a number of respected geometrical astronomers of even the mid-17th century did not regard astronomy as governed by physics, quite apart from the question of Kepler's elliptical ideas.
Thus G B Riccioli's 'Almagestum Novum' (1651) disparaged the efforts of those such as Cavalieri who had tried to give quantitative account of the core of Kepler's elliptical astronomy, calling these efforts an unsuccessful attempt to "apply medicine" to the "a-geometrical" relationships of Kepler's orbital ellipses -- as if Kepler's 'departure' from geometry was a kind of sickness in itself.
Even 60 years after the publication of Kepler's 'Astronomia nova...', Nicolas Mercator (1669-70) could still report complaints about Kepler's hypotheses (Philosophical Transactions 1670, vol.5, pp.1168-1175). At p.1174 (translated from the Latin):
"No-one has been found up to now who would deny that Kepler's areas can satisfy the appearances; but since neither he himself nor anyone after him could determine them by direct calculation, some have criticized Kepler for having parted ways with geometry while indulging too much in [speculation about] physical causes."
Mercator's remarks bear witness to contemporary opinions that still regarded it as a mistake on Kepler's part even to propose introducing  physics into astronomy. The conservatives included I Boulliau, who accepted ellipses, but sought to relace Kepler's ideas about the associated celestial motions by something purely geometrical, and GB Riccioli whose scepticism was already cited above.
To be sure, the older ideas were breaking down during the 1670s. A number of thinkers (including those acknowledged in Newton's 'Principia' book 1 prop.4 and elsewhere, Wren, Hook, Halley) were starting to apply physical ideas to orbital motions, and Hooke in particular made the insightful inference from his observation of apparent impact craters on the moon that the moon, too, had an attractive power to make heavy objects fall towards it. But nearly all physics was terrestrial, and Newton's proposal, quoted by @Viktor Blasjo, that the force retaining the moon in its orbit was of the same kind as the familiar heaviness seen in terrestrial objects, was revolutionary in itself.
So this background tends to explain and support Mauro Allegranza's answer that Newton did not invent the word gravity, but he was the author of a crucial "shift of meaning" in it.


What is the difference between apt, apt-get and git?

Question: I use Xubuntu and found that I can update packages by using apt and apt-get. But I have heard that programmers use usually git in their project to manage different version. So why Xubuntu do not use git to handle different versions of software?
Comment: It's an interesting question, however it seems that you first need to understand the difference between software package manager and version control systems. They are fundamentally very different things.
Comment: A package is a group of pre-configured files such as pre-compiled binaries, libraries, and/or supporting configuration files, etc. These are created by a package maintainer who may acquire original sources from git (or any other vcs or even a distribution method that isn't a vcs). This saves all of us the work of compiling all of our own applications and libraries and leverages skills of the maintainer.
Comment: Everything. What is the difference between format and mkdir? :-)
Comment: They can, they just don't. Using git to manage versions of packages would be too much overhead and the main functionality of git -- storing all the versions of your files -- is not actually needed by users of package manager, software packages management system can have that kind of functionality, but would just be considered as bonus.
Answer: apt and apt-get are related and very different from git.
apt is the package management tool for Debian-derived Linux distributions (including Ubuntu/Xubuntu). This is used to manage (i.e. download, install, remove, update) the binary software packages that makeup the Linux distribution you are using. This is about updating your local system software, as well as adding and removing programs.
'apt' is the command-line tool that is used to interact with the Synaptic graphical tool. Essentially, they do the same things; however, one is graphical and runs in the X-Window System and the other is run from the Linux command line.
apt-get is the command that is most-commonly used to install or update packages on your computer. apt is less-commonly used and differs from apt-get mostly in terms of output formatting. You can use man apt or man apt-get to pull up the manual pages, which will give you more details about the differences between the commands. There are also many pages online that will give you more information about how Synaptic and apt can be used.
git, on the other hand, is a versioning control system for source code for software development. Again, you can use man git for more information (if git is installed on your system). However, I wouldn't think you would need to worry much about git if you have Xubuntu and are not involved in developing software yourself.
Answer: So apt and apt-get are both package management tools available to most Debian and Debian based Linux distributions. APT stands for Advanced Package Tool and is a package management tool designed to manage .deb packages. Here is an article you can check out to see the differences. I also recommend you read the Debian Wiki on package management.
Essentially apt-get is "older" and apt is "newer" but both have largely the same functionality, that being they download, install, update, upgrade, and manage all your packages on your Debian install. They are interchangeable outside of a few edge cases.
Git on the other hand is a software version control system. Here is a good site to get started on learning about git. Developers and end users can use git to control versions of a project they are working on. You can use git to track changes in Word documents, videos, pictures, source code, etc.
It is just another tool to be able to manage and control software on your system. Some applications are not available in your operating system's repositories and the developers may choose to distribute a version in a git repository compared to the standard repository that your operating system's package manager would reference. In that case you would use git to download the software and follow any instructions the developers provide to complete the installation.
Using git is a more manual process. By using apt or apt-get you can automatically download and install any updates for all packages (software, firmware, kernel updates, security patches, etc.) with 1 or 2 commands. With git you would have to check to see if there is a new version of the software yourself, download it and complete all the installation steps needed. Unlike with an APT tool, you would have to do this for each individual piece of software you installed via git.
Answer: apt calculates dependencies.  When you request software package X, apt installs both package X and all the packages it depends on.  (Or in other cases, removes other packages).  It unpacks the package files, and runs install scripts in sequence.
git allows pulling or pushing a set of (source code) files.  It does not track dependencies.  As well as the current version of the source files, git tracks the history of changes to the set of files.
Both of these are fairly sophisticated.  They are also specialized to their respective purposes - with various tradeoffs and limitations.  There is not much overlap in how the two work, or what they are used for.

For example they even tend to use different network and security protocols from each other.
Many (but not all) git downloads are now performed over HTTPS (HTTP over TLS).  This defends against connection hijacking, by relying on the same global Web Certificate Authorities (CAs) that have been created to secure online shoppping, etc.
Connection hijacking on the internet is distressingly easy and widespread; we must always defend against it.  Connection hijacking can be performed by a malicious Wi-Fi router you are connected to, the internet access provider, someone who gained access to a line between internet backbone routers, etc.
Most (but not all) apt downloads are performed over plain HTTP.  apt authenticates the downloaded files using a different method.  It uses one GPG signature file for the overall apt repository, which in turn authenticates a list of checksums of the available files.  See SecureApt.
For example SecureApt is historically cheaper than TLS, because it does not require the server to encrypt each file transfer individually.  Another example feature is the ability to download from your best local "mirror" server of the apt repository.  All the mirror has to do is copy the same files.  Mirror servers have been provided by many different organizations as a public service.  And yet if the mirror server is hijacked, they cannot feed you a false update.  The authenticated files can only be generated by the organization that holds the secret half of the GPG keypair.
There might be some room to improve SecureApt using more modern techniques.  For example SecureApt has no equivalent of "Update Transparency" (analogous to Certificate Transparency), to deter state powers from secretly coercing backdoors into distributed software.  Nevertheless, the features of SecureApt have been quite well suited to their purpose.
Whereas e.g. the Debian apt repo is generated by one large organization, many people will want to use Git to inspect source code and history from many stand-alone projects.  Re-using HTTPS (i.e. authenticating using the Web Certificate Authorities) has been a very convenient way to add protection to git transfers.


Newer drugs useful for acute heart failure

Question: Diuretics (drugs which increase urine output), morphine and oxygen are often used to treat patients who have to come to emergency ward with acute heart failure. But what are newer drugs useful for management of patients with acute heart failure? I am looking for names of such agents, each with a one line summary of their current status for this indication. Thanks for your responses.
Comment: There's a host of them...do you want to narrow it down a bit?
Comment: I just want their names and a one line summary of current status for each of them.
Answer: I checked myself and found following agents are useful:

diuretics (for example frusemide, torsemide): to reduce fluid accumulation in lungs and other parts of body. Other agents such as thiazide and metolazone may be added if response is not adequate.
morphine: reduces anxiety, distress and diverts blood away from lungs by dilating peripheral blood vessels, especially veins.
oxygen: should be given only if hypoxia is there; otherwise it can cause vasoconstriction and may be deleterious.
vasodiators: e.g. nitroglycerin (or isosorbide dinitrate), nitroprusside, nesiritide. Used if blood pressure is not low.
inotropes: e.g. dobutamine, milrinone, levosimendan. Used if blood pressure is low.
vasopressors: e.g. dopamine, norepinephrine: only if blood pressure is low and not responding to inotropes.
low molecular weight heparin e.g. enoxaparin: to reduce risk of deep vein thrombosis

As patient stabilizes, agents known to be useful in long term treatment of chronic heart failure are added:

ACE (angiotensin converting enzyme) inhibitors (e.g. enalapril, ramipril) or ARBs (angiotensin receptor blockers) (e.g. losartan, telmisartan)
Aldosterone antagonist: e.g. spironolactone, eplerenone
Beta-blockers
Digoxin: especially useful if patients with atrial fibrillation
Ivabradine: useful in a subset of patients with chronic heart failure.
Valsartan/sacubitril combination: recently approved; shown to have better response than ACE-inhibitors in a large study.

These agents have been shown to provide survival benefit in long term to patients with heart failure.
References:
ACCF/AHA practice guidelines: http://circ.ahajournals.org/content/128/16/e240.extract
ESC guidelines: http://www.escardio.org/Guidelines-&-Education/Clinical-Practice-Guidelines/Acute-and-Chronic-Heart-Failure
NICE guidelines: https://www.nice.org.uk/guidance/cg108
Answer: Acetazolamide , a carbonic anhydrase inhibitor diuretic that reduces proximal tubular sodium reabsorption , is not a new drug , but has never been used for decompensated heart failure , however , new studies , the main : advor trial , have shown that it can improve the efficiency of diuretics . loop, potentially leading to faster and greater decongestion in patients with volume overload decompensated acute heart failure.
Reference
Mullens W, Dauw J, Martens P, et al., on behalf of the ADVOR Study Group. Acetazolamide in Acute Decompensated Heart Failure With Volume Overload. N Engl J Med 2022;Aug 2


WebViewClient shouldInterceptRequest handling gzipped data

Question: I want to intercept all HTTP requests in a WebViewClient and make my own requests.  The problem I'm having is dealing with gzipped responses.
There are a couple different posts suggesting methods that will work (such as AndroidHttpClient.getUngzippedContent(entity) or GZIPInputStream(entity.getResponse()) for instance) but when I return WebResourceResponses for these, the page loads blank.  I assume this is because the html is gzipped, and then that isn't handled properly so the rest of the page doesn't even get requested.
Does anyone have a 100% working method for simply intercepting every HTTP request and returning a WebResourceResponse?  I'm currently able to do this for anything that is not gzipped, but for gzipped responses I'm returning null (which means the request is not intercepted and thus gets made twice) so that the page loads properly.
Any help or a step in the right direction would be greatly appreciated.  I figure this is probably not that difficult but I am totally stumped.
Answer: Try avoiding Accept Headers while requesting for resources. Server will send you full fledge data if you don't accept gzip data while requesting.


How to treat $ObjectType.{sobject}.name as a string in a merge field?

Question: I have a VF Page that can be used with multiple SObject types (e.g., Account, Case, Contact).  It uses a custom controller that determines the SObject type and exposes it as a property named recordType.  This allows VF code in the page (or in components on the page) to dynamically show or hide content, for example:
<apex:outputText rendered="{!recordType == 'Account'}" value="..." />

This all works fine.  However, instead of inline string values (e.g., 'Account'), we tried to change the code to this:
<apex:outputText rendered="{!recordType == $ObjectType.Account.name}" value="..." />

This doesn't work, and I could not find documentation of $ObjectType. properties, return types, etc., only example usage.  Building some tests into the VF Page proved this:
//sample output
$ObjectType.Account.Name: Account
$ObjectType.Account.Name == 'Account': false

So $ObjectType.Account.Name can't even be compared with a literal string, but outputting it on the page ( {!ObjectType.Account.Name} ) produces a stringified result.  This attempt:
<apex:outputText rendered="!recordType == TEXT($ObjectType.Account.name)" value="..." />

produced an error while saving the page that TEXT() expects a number, percent, etc, not an Object.  So $ObjectType.Account.name returns an object, but attempts to add .toString() and .toString don't work (as expected on a merge property).
So, is there any way to test against $ObjectType.Account.Name?  We came up with one - stashing the value in an apex variable like so:
<apex:variable var="AcctRecType" value="{!$ObjectType.Account.Name}" />

puts the string value 'Account' into the variable, allowing it to be tested.  However, we use this pattern in a number of custom components, so we will need to add this variable to each one, perhaps several (the page supports multiple record types), e.g.,
<apex:variable var="AccountRecType" value="{!$ObjectType.Account.Name}" />
<apex:variable var="CaseRecType" value="{!$ObjectType.Case.Name}" />
<apex:variable var="ContactRecType" value="{!$ObjectType.Contact.Name}" />

We could also expose these names as properties on the custom controller, but that starts to feel cumbersome.  Which leads me back to my original question:  Is there any way to treat $ObjectType.{sobject}.name as a string for comparison within a VF mergefield?
Answer: Do you have to compare a field of the object? If not you could compare the object type itself.
<apex:outputText rendered="{!recordType == $ObjectType.Account}" value="..." />

where recordType would need to be the Id key prefix, e.g for account the value is '001', case the value is '500'
I think this approach is safer than using label, because the label could change at any time and break the code.
Comment: Id agree. It would be safer to get the key prefix using describe rather than compare with string literals. Account.sObjectType.getDescribe().getKeyPrefix() = '001'
Comment: This surprised me - I did not think you could directly compare the string '001' to the object $ObjectType.Account.  More VF deep magic :)  Also worth noting here, @techtrekker's apex code for getting the prefix can be translated to VF merge syntax, as $ObjectType.Account.keyPrefix.
Answer: As long as your Name and Label are the same, you should be able to use the Label attribute, which returns a String
{!$ObjectType.Account.Label == 'Account'}

evaluates to true
Comment: I'd be careful of this one. Labels translate with the user locale. You might be setting yourself up for difficulties solving it this way. EN: Account, FR: Compte, ES: Cuenta, etc.
Comment: I've added an answer that addresses this shortcoming
Comment: I believe these are valid concerns only if the translation workbench is enabled. But yes safer to compare sObject key prefixes.
Answer: Have you considered going with dynamic visualforce (VF generated from Apex)?
The level of flexibility that you seem to need could perhaps be well served by moving the logic of what to build on the page into code, as opposed to the Visualforce markup?
As far as reusability goes, you could also write this into a library of apex code that could then be easily plugged into many different pages/components.
You will also have a lot more fine grained control over logic.
Downside is that it is clunkier than just writing visualforce. But in your case you might find it worth the extra effort.
Answer: I think this is a Salesforce defect.
According to the $ObjectType documentation, $ObjectType.Lead.name should return a string, but as you can see if you try something like
{!$ObjectType.Lead.name + ''}

you get an error
Incorrect parameter type for operator '+'. Expected Text, received Object

showing that it is returning an object.
The same issue exists for field schema details, e.g.
{!$ObjectType.Lead.Fields.Phone.name + ''}

but works ok for
{!$ObjectType.Lead.Fields.Phone.localName + ''}

despite both Data Types being defined as strings.
Answer: I think that best solution is to utilize map syntax of VisualForce
rendered="{!$ObjectType[recordType].Name == ($ObjectType.CampaignMember.Name)}"


All my Kentico live sites 404 and the previews do as well

Question: I created a site in Kentico 12 and using the live viewer was working fine.  Now its started 404ing every time I try to go to the site either by the URL: localhost:8080/Kentico12_[sitename] or by viewing the site through the live site feature.  I a new site and it does the same thing.  Additionally, page preview 404s as well.  I have tried changing domain alias' and URL patterns but it doesn't seem to work.  If anyone has a solution or some useful documentation to point mee toward that would be appreciated.
I can get into the back end of the site no problem by going to http:localhost8080:/Kentico12_Admin
I can reinstall Kentico 12 if needed but would rather avoid that.
Answer: Reinstalling is not the answer.  Make sure you have the site properly setup in IIS first.  A simple setup is to set the root of the site in IIS to the root of your MVC site.  Then under that main site, create a virtual application and set that to the root of the CMS directory and call that virtual application "cms".
Then navigate to localhost/cms and you should be directed to the Kentico login page.  Once you've logged into the Admin interface, update your site's domains.  The Site domain name should be localhost/cms.  The Presentation URL should be http://localhost.
If after you've made those changes and you're still getting 404's we'll have to look into other possible issues maybe in your web.config.
Comment: I can get into the back end of the site no problem by going to http:localhost8080:/Kentico12_Admin
Comment: Then do you have a license key for localhost:8080?  Or is there a specific need to add the port number after the domain?  Kentico sees a domain with a port as a separate license key. Lastly, have you double-checked the site domain fields aI mentioned?


Merging duplicated protected questions

Question: I found two duplicated questions which are protected:
'Operation is not valid due to the current state of the object' error during postback
ASP.NET MS11-100: how can I change the limit on the maximum number of posted form values?
Is it possible to merge them together?
Since both of them are protected I cannot close any of them as a duplicate.
Answer:
Since both of them are protected I cannot close any of them as a duplicate.

I just missed the action links on the page - I can close as duplicate.

Merging duplicated protected questions


一 [份/个/项] 工作??? What is the difference?

Question: Not sure if there is actually a difference, but I see the word 工作 used with different measure words and I've never got to the bottom of what the difference is. I recently saw 换一份工作, so I guess that is to change jobs, i.e. to change to work for a different company?
But how does that compare to 一项工作? Is that the same? Or is that more like a piece of work within the same job? I.e. I've got two projects at work and I work on project A in the morning and project B in the afternoon, so at lunchtime I 换一项工作?!! Or am I just making that up?!
And what of 个? Are there are other measure words you can use with 工作?
All input happily welcomed :-)
Hashamyim
Answer: Ok, so simple way to put this:
一份工作:it means a job (occupation)
一项工作:it means a task
工作 has many meanings, so depending on the context, it means different things.
Hope that helps.
Answer: [份/个/项] is not important, in other word the three 字s are similar-meaning words. You can say "一份工作" or "一个工作" and all Chineses
will acknowledge what you say.
Extra: 项 with 工作 is not common in Spoken Chinese, maybe the 工作 followed 项 refers to project.

I recently saw 换一份工作, so I guess that is to change jobs, i.e. to change to work for a different company?

There is also another correct situation that You become Apple's boss from Apple's Manager.

一 [份/个/项] 工作??? What is the difference?


Is there anyway to test AAVE and Uniswap protocol locally

Question: I am trying to write a smart contract interacting with AAVE and Uniswap.
Is there anyway to test my smart contract locally using Ganache or Hardhat node?
Answer: You can do it two ways

Using mainnet forks: Super slow to, but needs less testing code to write. Prone to test failures becausing using live data.
Deploying Uniswap and Aave locally using your test code and setting up tokens with fake balances: tests run 100x faster.

Some examples of deploying Uniswap for testing.
Comment: Thanks for your answer but How can I get fake AAVE token locally?
Comment: You deploy any ERC-20 token and call it Aave.
Answer: Another possible solution could be mocking the functionality that you will be interacting with.
The functions you will be using from Uniswap or Aave will have an input and provide you with an expected output. You can essentially mock these functions to behave in an expected way, to further test your code's behavior and interaction with Uniswap or Aave.
I would recommend this approach if there aren't many complicated interactions with the external code base. Good luck!


DEC RLV12 Disk Controller Register Access

Question: The RLV12 Technical Description (EK-RLV12-TD-001) describes the RLV12 registers as "word-addressable". I presume that means these registers can only be accessed as words and byte access would fail. If that is correct what would the reaction of the controller be to a byte access on one of its registers (be it on an even or odd address)?
Comment: Having written a few PDP-11 and VAX drivers, I concur with your interpretation of the practical meaning of "word-addressable", especially your last 3 words.
Comment: @another-dave Alternatively, for a "word-addressable" register, DATOB could be simply ignored (that saves a few logic gates), and byte operations would succeed, corrupting the register. In principle, the choice would depend on the HW designer and/or the management, and I would not be surprised if it could vary even between revisions. In other words, "word-addressable" means "using byte operations on the register is undefined behavior, do not attempt".
Comment: I would guess that a DATOB (data out, byte) transaction wouldn't be recognized, maybe leading to a bus timeout.  Section 3.5.1 talks about word operations DATI and DATO, only.  But this is only guesswork.
Answer: TL;DR:
Those registers are assigned at word boundaries and to be accessed with word operations. Any byte access is simply not defined.
Once Upon a Time ...
Today we take it granted that memory addresses point to bytes and access is done in bytes or more. But that is only a convenience that came to be with the IBM /360, which not only settled that a byte is 8 bits, but also byte addressing independent of word size. Before that data access was (almost) always word wise and these words were addressed consecutive. Any smaller access had to be done by building words from bits before writing or taking them apart into whatever was needed after reading. An art lost in history today - but not back when the PDP-11 series was conceived. Back then people still know the meaning.
And That Means?
The PDP-11 series is a 16 bit machine with word organized, byte addressable memory. Or in simple words:

Word size is 16 bit i.e. two byte
Memory is 16 bit wide
IO-bus is 16 bit wide
Addressing is byte wise
Each byte of a word can be addressed on its own
Thus

memory words are accessed on even addresses (x0/x2/x4/x6/...)
bytes (within a word) are accessed via even and odd adresses (x0/x1/...)

In this context 'word-addressable registers' means that these registers are assigned to word addresses, not byte addresses. Nicely shown in any list of them, like table 1-1 (p.1-4) or 3-2 (3-16) of that document:

For registers like that words access is usually as well implied. That is, any read or write has to be done for the whole word as one, not as single bytes.
Why?
Well, it simplifies hardware:

No need to care for byte access
No need to synchronize upper/lower half access
No need to byte-swap for uneven assignment

and most important:

Any change of a register is atomic
No chance for a programmer to screw up sequence (within a word)
All values written are always valid

What If I Still Do Byte Access?
It may not work at all, for example due byte access not being handled at all, or screw data, like clearing CSR/CRDY before setting the drive, thus possibly writing to the wrong drive.
It is simply not defined what happens if a programmer does not follow the rules set by the manual. This is operating at the lowest level, there is no mighty megabyte sized OS pampering everything twice. We're talking about hardware made at a time when a single gate, or even transistor was an investment to be avoided. Why on earth should hardware be thrown at bad software?
As always: Do as told by the manual, don't try to outsmart the designers :))
In fact, even defining such behaviour might be quite harmful, as it's implementation dependant and may change between versions and models.
Comment: The question is surely not "should I obey the manual?" but rather "what happens with this specific device if I don't?".  Our consensus seems to be "we don't know but it's probably not going to be  good".
Comment: @another-dave point is that for such no real answer exists, as it's simply not defined and implementation depending. A conclusion independent of what controller or CPU we're talking. Don't do Stuff that's not documented as it may and will change. Without giving any prior notification - like field service replacing the controller for whatever reason.
Comment: I agree that the reaction to a register byte access is undefined and shouldn't be tried. A RLV12 controller will however have some sort of reaction implemented to a register byte access (even if that is no reaction or data corruption). I'm interested in the exact behaviour as I'm writing a RLV12 simulator and have to code some sort of reaction and would like to keep the behaviour of the simulator as realistic as possible.
Comment: @JosF If my task (and I would even go there), I'd simply add an emulation error exit for anything but a word access. This will already during early test reveal if there is non word access at all. At least under the assumption that the emulator will be tested prior to publication :))


How can I update an array value and put it into a mysql database using php?

Question: Okay so a while ago I asked this question
How can I grab and store multiple $_POST Variables in a for each loop?
And the response was perfect, and it worked for inserting the values into the database just fine.  However, I now am revisiting this project and I want to UPDATE only one field in the database, specifically the post test field for that particular user, using the same or similar method.  How would this be possible?
Currently I have something along the lines of this.
<code>$SGUID = the Unique User ID
$SGpost = the field i want to update
$SGQID = question ID
</code>
Obviously, this does not work.. and my code is extremely sloppy as I tried to replace and edit this along the way.  Any ideas?
<code>foreach ($_POST as $p => $v)
{

 if (preg_match("/^Q\d+$/",$p)) {   //$_POST variables with Q1, Q2, Q3, etc etc

$query_3 = mysql_query("UPDATE SGresults SET SGpost = '$p', SGpostCheck = 1 WHERE SGUID = '$SGUID' AND SGQID = '$p'") or die('Error: '.mysql_error ());
    $SGQID++;

}
}
}
</code>
When I echo out $p I get the following
    Q11
Q21
Q31
Q44
Q54
Q63
Q73
Q83
Q93
Q103
Q111
Q122
Q131
Q142
Q153
Q163
Q17
Which is what I want, except without the Q, and just the second value.  So for example if it was 'Q163'  I just want to insert the '3' part into SGpost WHERE the database is 'Q16'.
Thanks again again!  Any help would be greatly appreciated!
EDIT::
Looked over my code again and changed some values around...The following DOES work, so I think I will stick with it.  Unless bad code?  Thanks again for your suggestions.
<code>$SGQID= 1;

foreach ($_POST as $i => $v)
  {
    if (preg_match("/^Q\d+$/",$i)) {    //$_POST variables with Q1, Q2, Q3, etc etc
// Here we insert value $v to database
    if ($SGtestType == "Post-test") {

    $query_post = mysql_query("UPDATE SGresults SET SGpost = '$v', SGpostcheck ='1' WHERE SGQID = '$SGQID' AND SGUID = '$SGUID'  ") or die('Error 109: '.mysql_error ());
    $SGQID++;
    // ^^ increments the question value everytime an insert is made
    //last 2 fields is check for existing value.. or if not exists.. 1 if it does.
    }
</code>
}
}
}
Answer: Assuming you trust the post data to not be an xss attack:
<code>    foreach ($_POST as $p => $v)
    {

     if (preg_match("/^Q(\d+)$/",$p, $matches)) {   //$_POST variables with Q1, Q2, Q3, etc etc

$id = (int)$matches[1];

    $query_3 = mysql_query("UPDATE SGresults SET SGpost = '$id', SGpostCheck = 1 WHERE SGUID = '$SGUID' AND SGQID = '$id'") or die('Error: '.mysql_error ());
        $SGQID++;

    }
    }
    }
</code>


What does the derivative of the unit radius vector with respect to time represent?

Question: I was reading 1.11.2 in Introduction to Mechanics by Kleppner and Kolenkow when they started discussing the derivative of the r unit vector with respect to time. I understand that a change in r would be a new vector $r(\theta + \delta\theta) - r(\theta)$. But how would we incorporate time into it? What would the rate of change of the unit radius vector look like?
Comment: I do not understand why this question has been asked as in section 1.11.2 on page 29 the equation $\frac{d \bf\hat r}{dt}=\dot \theta \bf\hat \theta$ is derived.
Answer: If you have a unit vector that stays a unit vector while it changes in time, then it is changing direction. This is a rotation.
In that case the derivative would be the angular velocity. How fast it's changing direction, and what direction it's changing. By convention that gets written as a vector perpendicular to both the unit vector and to the direction of change, according to the right-hand rule.
Answer: It represents the instantaneous velocity vector directed along the tangent to the moving path. It is the sum of resolved radial ( same direction as position vector) and ( the perpendicular) circumferential  components of velocity.
The changes occur whether or not the initial position vector is of unit length or not.
Answer: Often in physics problems, how each variable depends on all the other variables is left to be implicit. Although this makes it more convenient to write things it can obscure certain details, making the problem more difficult.
A general (time-dependent) position vector in polar coordinates is written as follows
$$\vec r(r(t),\theta(t)),$$
i.e. it depends on the radius and angle which can both be functions of time. We restrict ourselves to motion on the unit circle so we can set $r(t)=1$. Now our function only depends on $\theta$:
$$\vec r(\theta(t))$$
The derivative of this function with respect to time can be calculated by applying the vector version of the chain rule.
\begin{align}
\frac d{dt}\vec r(\theta(t))&=\theta'(t)\frac d{d\theta}\vec r(\theta(t))\\
&=\theta'(t)\begin{pmatrix}\frac{d{x}}{d{\theta}}\\\frac{d{y}}{d{\theta}}\end{pmatrix}
\end{align}
After knowing this explicit definition you might be still confused how you can take the derivative of a vector which is constrained to lie on the unit circle. The answer is that it is still possible as long as this derivative (read: the velocity) is perpendicular to $\vec r$ itself. This can be shown using the following proof. Assume $\vec r$ can depend on $r$ and $\theta$ and then impose $\frac d {dt}(\vec r\cdot \vec r)=0$, which is equivalent to saying the radius is constant. Working out this expression gives $\vec r\cdot \vec v=0$, which means $\vec v$ has to be perpendicular to $\vec r$ in order to have a constant radius.
Answer: The unit vector $V(t)$ has coordinates $(\cos(u(t)),\sin(u(t))$. We have thus
$$
V' =dV/dt = (-\sin(u(t))u', \cos(u(t)) u')= u'(-\sin(u(t)), \cos(u(t)))
$$
the modulus of $V'$ is thus $u'$ and $V'$ is orthogonal to $V$.


How to speed up Visual Studio Webserver (Cassini)?

Question: for my webapp the integrated Visual Studio Server (Cassini) ist much slower than IIS. How can I speed up Cassini so that i dont have to wait for 3s for every small page?
Answer: Are you seeing this on a Web Application Project or a Website Project?
If it's a Website, then the issue just may be that the Development Server needs to compile each page the first time it's executed. Are subsequent requests of the same page faster?
If it's a Web Application Project then Visual Studio compiles it all before the Development Server runs it. In this case, are you sure it's the Development Server? Is there the same delay for EVERY page in the application?
Also, Are you sure it isn't disk or database latency?
Answer:
Determine why you think the web server is the culprit.
How did you determine that it was the web server? How did you measure this 3 seconds? Is it on every page, or just certain pages? Is it continuous, or does it get better after a while?
Determine what aspect of the slow web server is the problem.
Is there a lot of CPU in use? Memory? Are there other things happening when this happens? When you're using IIS, are you running on the same computer that had the slow Cassini? Is everything else the same? Same database server? Same hard disks in use?

You've got to narrow things down, as in any performance analysis.


Duality in category theory

Question: The well-known duality principle asserts that if a statement is true (resp. false) for a category $\mathfrak{C}$, then the dual statement must be also true (resp. false) for the dual category $\mathfrak{C}^{\mathrm{op}}$. Now, in some cases it is useful to work with the dual category because it might simplify the analysis. However, in this case, by the duality principle, we translate the found properties with respect to $\mathfrak{C}$. Hence, my quedtion is: except for what I remarked before, why it is so important to study dual categories? Honestly, I considered such a notion useful only to simplify the work needed when using $\mathfrak{C}$.
Comment: It simplifies statements and people who don't like to work contravariant can work covariant.
Comment: The difference is intuition. Frames are like algebras/lattices and locales are like spaces.
Comment: So, at an interpretative level, they do not give new informations than the starting category. I think for instance to frames and locales. Why even changing names, if opposite only gives a formal way to simplify computations ?
Comment: In a certain sense, this follows because taking locales is a generalization of taking open subsets with inclusions, while taking frames underline only the lattice-structure of open sets, right? Therefore, there exists in general an interpretative reason to introduce opposite category (they give a different point of view for seeing mathematical structures). Hence, in particular, opposites must not be seen only as a "formal convenience" to find further properties of $\mathfrak{C}$. Is it right?
Answer: What is important is that dual categories appear naturally, most notably because there are (what people call) "contravariant" functors - what I prefer to call functors on dual categories (it is very convenient to declare all functors as "covariant"). A basic example is the functor $\mathbf{Top}^{\mathrm{op}} \to \mathbf{CRing}$, $X \mapsto C(X)$, $f \mapsto f^*$, a more complicated example is singular cohomology $H^* : \mathbf{Top}^{\mathrm{op}} \to \mathbf{grAb}$. Also, every (pre)sheaf on a space $(X,\mathcal{O})$ is actually a functor on $\mathcal{O}^{\mathrm{op}}$.
One important observation is also that dual categories of concrete categories in practice behave quite differently than these concrete categories. For example, although the dual of every abelian category is also abelian, the dual of a Grothendieck category is almost never a Grothendieck category, which applies in particular to $(\mathbf{Mod}_R)^{\mathrm{op}}$, the dual of the category of right $R$-modules, where $R$ is a nontrivial ring.
Also, concrete representations of these dual categories often involve some kind of topology. In fact, Pontryagin duality tells us (in a special case) that there is an equivalence of categories between $\mathbf{Ab}^{\mathrm{op}}$ and the category $\mathbf{CompAb}$ of compact topological abelian groups. It follows formally that $(\mathbf{Mod}_R)^{\mathrm{op}}$ is equivalent to the category ${}_R \mathbf{CompMod}$ of compact topological left $R$-modules.
Comment: PS: I just babbled a bit about why I find dual categories important. I have no idea if this answers the given question.
Comment: Very good answer! Following your examples, I have another question, which is related to the first I posed: the consequences of the equivalence between ${\bf Ab^{op}}$ and ${\bf CompAb}$ may be translatable as properties of the category ${\bf Ab}$? Indeed, if each property of dual category may be translated as a property of ${\bf Ab}$, then the introduction of dual category, beyond giving a formal tool in order to see in a simpler way further properties of the starting category, has no very importance. Namely, I can study a category directly, using contravariance instead of passing to dual.
Comment: I don't understand what you *specifically* want to know.
Comment: Does the previous equivalence provide properties of the opposite ${\bf Ab}$ which cannot be translated using duality into properties of ${\bf Ab}$?

Duality in category theory


Continuity at rational and irrational

Question: Let $f:\mathbb{R}\rightarrow\mathbb{R}$ defined by $$f(x)=\begin{cases} x^6-1 & x\in\mathbb{Q} \\ 1-x^6 & x\notin\mathbb{Q} \end{cases}$$
How to find the number of points at which $f$ is continuous?
I think as there are infinite irrational numbers between any two numbers rational no. This point should be discontinuous everywhere except at $x=1$ as we approach 1 from both side although the rational or irrational both will give values close to zero but this is totally based on intuition, how to find the actual number of point of continuity.
Comment: You should use  `\begin{cases} \end{cases}` for what you wanted to do.
Answer: You could use continuity by sequences, and the fact that both $\mathbb Q$ and $\mathbb R\setminus\mathbb Q$ are dense in $\mathbb R$.
For instance, choose $x\in\mathbb R\setminus\mathbb Q$; then you can find a sequence $\{x_n\}_n\subset\mathbb Q$ such that it converges to $x$.
The limit of the image of the sequence will be, by continuity of polynomials, $x^6-1$, but the image of $x$ is $1-x^6$. Therefore the function is continuous $\forall x$ such that $1 - x^6=-(1-x^6)$, that is, $x=\pm 1$.
Comment: Thanks for the reply, I get the concept thank you

Continuity at rational and irrational


Evaluate integrals trapezoid rule using lists

Question: I'm trying to write a formula for trapezoid rule from scratch. I'm not that familiar with python yet so I'm strugguling a bit. I have an expression I wish to integrate, which I wrote as a list called square.
I'm in the part of writing the integrals already:
square = []                        #Create empty list
for i in range(0, len(dos)):
     square.append(dos[i]*dist[i]) #Multiplication from inside the integral

s1 = 0
s2 = 0
for i in square[i] != square[1] and square[-1]:
    s1 += s1 + 0.01 * square[i]
else:
    s2 += s2 + 0.01 * 0.5 * square[i]

print(s1,s2)

And I am getting the following error:
for i in square[i] != square[1] and square[-1]:

TypeError: 'float' object is not iterable

Anyone knows what can be wrong with the code?
Thanks in advance!
Comment: Could you explain what you want to do in `for i in square[i] != square[1] and square[-1]:` you want to iterate AND set a condition it seems
Comment: Yes, I am trying to say that if the element i on the list square is different to both the first and last element, then it calculates the sum as s1
Answer: You need the for loop and the if statement then, also you used += so you don't need to add s1 in th right operand because that will add it twice
# equivalent
s1 += square[i]
s1 = s1 + square[i]

s1 = 0
s2 = 0
for i in range(len(square)):
    if square[i] != square[0] and square[i] != square[-1]:
        s1 += 0.01 * square[i]
    else:
        s2 += 0.01 * 0.5 * square[i]

With tome tips to get cleaner code

zip to create square list, to iterate both on dos and dist lists
iterate on square by elements on not its indices
use in instead of the double condition

square = [do * di for do, di in zip(dos, dist)]

s1 = 0
s2 = 0
for elt in square:
    if elt not in (square[0], square[-1]):
        s1 += 0.01 * elt
    else:
        s2 += 0.01 * 0.5 * elt


My 11 yr old Rottweiler has bladder control issues

Question: How do I make sure that he's not developing more problems by cleaning up his urine?
Comment: Welcome to Pets! Please take the [tour] and have a look at the [help]. Currently, it's not clear what exactly your question is or what problem you're trying to avoid. Please [edit] your question to clarify it and add more details so we can understand you and offer help.
Answer: There are several strategies for dealing with urinary incontinence in dogs, and the right strategy requires a veterinarian to understand the causes and resultant effective treatment paths.
Generally, especially at your dog's age, the more important thing is to make sure the dog is healthy; there is not a high risk that you are reinforcing behavior by cleaning up the urine, especially if this is a recent issue (i.e. if the dog previously had no bladder control issues).
Here are some questions a vet will probably ask you to determine the right treatment:

Are you letting him out enough?
Does he consume more water than usual?
Is he on any medications right now? Some medications can cause either increased water consumption or incontinence itself
Has he recently had any injuries?

There are medications that your veterinarian can prescribe to strengthen urinary sphincter control, but there might be other issues (genetic conditions, spinal deformities, urinary tract infections) that have other treatment paths. So it really depends, and you should really reach out to your veterinarian.
Also:
 - Make sure his bedding is dry; he may be wetting his bedding and he can get sick easily if he sleeps on wet bedding.
 - Check for skin irritation and excessive licking of the penile area; if urine drips, it can cause irritation there


How can I find out what is teleporting in?

Question: Let us say I can pinpoint the exact endpoint of a teleportation, e.g. with Trace Teleport. Is there any way to find out what is coming? In 3.5 there is the spell Anticipate Teleportation that at least gives the creature's size and how many creatures are coming, but I cannot find an equivalent in Pathfinder. Is there any way to know?
Comment: @SevenSidedDie Is the site now okay with a *D&D Tools* link?
Comment: @HeyICanChan Missed that while I was editing. I think [my practical objection to them still applies](http://meta.rpg.stackexchange.com/a/2773/321). (Ironically in this case though, the link going down doesn't risk robbing the post of any information because the spell name is already sufficient reference, so relative to that practical objection it's kinda six of one, half a dozen of the other whether it's left in or taken out.)
Answer: Trace Teleport covers that already:

Whenever you detect the origin point or termination point of any teleportation effect with this spell, you can study that origin point or termination point for 1 round. If you do, you can attempt a caster level check (DC = 11 + the teleportation effect's caster level), taking a –5 penalty if the effect occurred more than 1 minute ago. If you succeed, you gain a glimpse of the teleportation effect's termination point (if you detected an origin point) or origin point (if you detected a termination point).

This means that you can see the origin point of this teleportation effect.
You do need a round for that, so most teleportation spells will be finished before you have time for that, since they are instantaneous, but that also means that you will immediately see what is coming out of the teleport.
For teleportation effects that take longer to finish their effects, like a Gate, Getaway, or Teleportation Circle, you can look at what is on the other side (the origin) of the spell effect.
The spell anticipate teleportation only worked on willing creatures, so it wasn't really great to know what and how many enemies are coming out of a teleportation effect, and it could anticipate because you had the option to delay the effect for a round.
As for instantaneous teleportation, your only option would be to use a Divination (or similar) spell and anticipate that someone is going to teleport to your location.
Or to ask your GM to convert the greater anticipate teleportation spell from D&D 3.5e to Pathfinder.
Comment: I believe that will depend on the GM, as this glimpse is defined as: "This glimpse lasts long enough for you to get a brief look at the area, but not long enough to scrutinize it in detail." To me, this means that you cannot use this glimpse as to get familiar with the location for a teleport, but you could remember it if you see it again. And since it says you take a brief look, anyone or anything on the location could be seen aswell.
Comment: I don't think *trace teleport* works the way the answer makes it sound. First, the caster "can detect the lingering traces of any teleportation effect that occurred up to 1 hour previously, in the same fashion" as detecting a teleportation effect that's happens while the caster's in the area. Second, the *trace teleport* spell only reveals the teleportation effect's origin point, termination point, or both, not the creature that created the effect or the creatures that were subject to the effect, which is what the asker wants.
Comment: O, okay! So the spell *trace teleport* is no help *as the creature's arriving or departing* even though it could still be used after the creatures have arrived or departed. Got it. I'm still unsure if *trace teleport* lets the caster see at the origin or termination points things *other than* the point itself, though. That sounds like an expansion of the spell's mandate.
Comment: The target of the spell *anticipate teleportation* is a willing creature; then the spell's effect affects all teleportation effects within its area, and *greater  anticipate teleportation* does exactly what the asker wants.
Comment: @HeyICanChan it works for spells that arent instantaneous, and i explained that it can see the other "side" of the effect. Nowhere i said it can see creatures, but it will see whoever is on the other side.


iPhone App Store how to display a long app name with line breaks?

Question: I noticed that some Apps in the App store have very long names. When the app's sales page is displayed, their long titles are displayed in smaller font with line breaks, so the entire name fits on the page.
Let's say I have an app with a long name: App name: keyword1, keyword2 and keyword3"
However, my app name is displayed as "App name: keywo..." in both the search results and the sales page.
Is there some kind of an Xcode project setting that I can use to tell the app store that my app name is long? I've seen this done for other apps, but am not sure how to do this.
Thank you!
Answer: You have to use short and succinct name.


How would a human body behave if the atmosphere pressure were 2Atm at the sea level?

Question: I am wondering if on an otherwise Earth-like planet the atmosphere pressure were constantly 2Atm at the sea level, how would a human body behave if we landed there? Suppose the air composition would be quite similar to our (like 25% oxygen, 73% nitrogen, water vapur etc.). Would our blood pressure raise or remain stable? Would our lungs function with more ease or with greater difficulty? The ability to move, work, act etc. - would they change? Would it influence our senses (hearing, seeing, etc.)? Would we be tired more easily or on the contrary less easily (having more oxygen)? Could we sleep better or worse? In general, how would we adapt? Would it influence our ability to survive - make our life longer or shorter? Thanks for any answer!
Comment: 2 atmospheres in analogous to scuba diving in 30 feet of water. Not deep enough for nitrogen saturation to be a problem.
Comment: Thank you for a quick answer. Unfortunately I have no idea about scuba diving, have never done it. 30 feet that's approximately only 9 meters deep. Not much. Yet, I guesss, if you are in a scuba in the water however, all the other factors of your environment change, not only the pressure. You are in the water, not air, so your skin is constantly wet, your vision and audition are impared, your temperature (homeostatis) functions differently etc.  I have read https://en.wikipedia.org/wiki/Human_physiology_of_underwater_diving, that's not what I mean.
Comment: And of course you cannot be diving for 365days 24h a day.
Comment: Divers don't need to be diving to be in pressure environments. There are underwater habitats that are maintained at the water pressure to facilitate 'moon pools'. People live perfectly ordinarily inside these. In most cases these use various heliox mixtures due to depth, but regular atmospheric air is good enough for about 2 atmospheres (10 meters), at 3 atm (20m) the nitrogen becomes narcotic. So for regular air the limit is somewhere between 2 and 3 atmospheres. Unfortunately I don't have suitable references at hand to make this proper answer.
Comment: The underwater habitats, that's a great idea to research. Thanks for the idea, even if without precise referewnces.
Answer: My answer here: https://worldbuilding.stackexchange.com/questions/194650/what-would-be-the-effects-of-changing-the-composition-of-air-in-order-to-increas/194689#194689[1]
quotes research on the atmosphereic requirements of humans, specifically Habitable Planets for Man Stephen H. Dole, 1964, 2007, which has an online edition.
https://www.rand.org/content/dam/rand/pubs/commercial_books/2007/RAND_CB179-1.pdf%5B1%5D[2]
On page 15 Dole states that the normal atmospheric pressure of oxygen at sea level on Earth is about 149 millimeters of Mercury. The overall sea level atmospheric pressure is 29.92 inches of Mercury, or 759.968 millimeters of Mercury.  Twice the sea level atmospheric pressure on Earth should be about 1,519.936 millimeters of mercury.
On page 19 Dole says:

To summarize, then, the atmosphere of a habitable planet must contain oxygen with an inspired partial pressure of between 60 and 400 millimeters of mercury and carbon dioxide with a partial pressure roughly between 0.05 and 7 millimeters of mercury. In addiiton, the partial pressures of the inert gases must be below certain specified limits and other toxic gases must not be present in more than trace amounts. Some nitrogen must be present so that nitrogen in combined form can find its way into plants.

Twice the sea level atmospheric pressure of oxygen would be about 298 milititers of oxygen, which Dole considered within the safe limits.
If a planet has an atmopsheric pressure of 1,519.936 millimeters of mercury which is entirely a substance which is not oxygen, humans would suffocate without oxygen.
But pressure of 1,519.936 millimeters of mercury is within the non toxic limits of such inert gases as argon, nitrogen, neon, and helium.  A human would not suffer toxicity in atmospheres containing 1,519.936 milimeters pressure if it was composed of any of those gases, though humans would suffocate unless sufficient oxygen was also in the atmosphere.  So if any of those elements was in an atmsophere of 1,519.936 millimeters of pressure and with the same percentage as Earth's atmosphere, it would not be toxic.
In Earth's atmosphere nitrogren and oxygen are the main components totalling almost 99 percent. And argon, neon, helium and krypton are in such low concentrations that doubling their concentration in an atmosphere twice as dense should still be far below their toxic levels.
The main concern with doubling the density of Earth's atmosphere would be doubling the pressure of carbon dioxide, methane, and water vapor.
The scale height of Earth's atmopshere is the height at which its density decreases by 2.718, and is 8.5 kilometers.  So a mine extending 8.5 kilometers below sea level would have an atmosphereic denisty 2.718 times that at sea level, consdierably more than twice sea level.
The deepest mine in the world, the Mponeng Gold Mine in South Africa, extends 4.0 kilometers or 2.5 miles deep, though mine depth is measured from the surrounding elevation,not from sea level.
Reverse altitude sickness can happen when mumans move from a haigh altitude to a low altitude.  Thus you might want to research reverse altitude sickness and find out whether it wo uld bother humans born in a region with twice the atmospheric pressure of Earth.
Comment: Inches and millimeters, must have been an international team.
Comment: The surface elevation of Mponeng is 1565 m above sea level, so at it's deepest it's only 2435 m below sea level.
Comment: I am not sure if I have understood everything, partos of your explanation seem to me a bit cryptic, and the link to Dole gives the 404 ERROR, yet you have given me sothing to think about. E.g. it would be nice to know and consider the toxic limits of other gases. I have never heard about "reverse altitude sickkness", high mountain dwellers like Tibetans, Bolivians and Peruvians, seem to adapt more easily to life in the lowlands, than reverse, e.g. the Chinese who were resettled to Tibet, or Westerners trying to live in Machu Picchu, yet I will search for it. Thank you
Comment: Researching the conditions in open mines, would also be great. Thanks
Comment: A new link for Dole is https://www.rand.org/pubs/commercial_books/CB179-1.html and for another booklet by him and Asimov https://www.rand.org/pubs/commercial_books/CB183-1.html, both donloadable for free. Thank you for the reference.
Answer: With question of atmospheric composition and pressure percentages are less important than the partial pressures of the various gases in the system. If I recall correctly the research I did for another question about atmospheric composition indicated that half an atmosphere partial pressure of oxygen would be a 1 on the "martini's per hour" scale used to measure gas intoxication, not immediately harmful but cumulatively quite damaging. I think the Carbon Dioxide and Nitrogen of an atmosphere twice as dense but with the same gas percentages would be bad news too but you'd have to check that.
Comment: Having reread after some time I can find that the link to Dole needs to be only slightly corrected, removing the [1][2] after the .pdf and one can download the report. I will read it now.


Change a single icon in the Unity launcher panel?

Question: I have a third-party application, (in this case, Oracle SQLDeveloper which is a java application), that I installed manually (i.e. not through apt).  When I ran it, I selected to "Lock to Launcher" so I can easily launch it again.  The icon works to launch the application, but the icon is a generic grey question mark icon.  I can download various other icons that would be more appropriate, but I don't see any way to customize just a single icon in the launcher.
Comment: please look inside your `~/.local/share/applications` folder to see if there is a representing `.desktop` file of the application. (If not, look in `/usr/share/applications`) If so, could you open it with gedit (drag it over a gedit window) and post the line starting with `Icon=` (or better: the whole file). There can be various reasons why an icon does not appear properly in the launcher.
Comment: [Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Oracle SQL Developer
Icon=.png
Path=/opt/sqldeveloper/sqldeveloper/bin
Exec=/usr/lib/jvm/java-7-openjdk-amd64/bin/java .....
Comment: Should I be able to directly edit the "Icon=.png" line?  If so, how do I update it and/or make it stick?
Answer: From your comment, it turns out that there is no icon defined in the .desktop file. You can use an icon "of your choice", and edit the line:
Icon=.png

to:
Icon=/path/to/your/icon.png

You will possibly have to log out and back in to make the change appear.
Note1
If you found your .desktop file in /usr/share/applications, it is good practice to first copy it to ~/.local/share/applications and edit the local copy. After log out / in, the local version will "overrule" the one in /usr/share/applications.
Both Dash and the Unity Launcher will then use the local one.
Note2
You might want to look inside the application's directory (which seems to be /opt/sqldeveloper) if there is not already an appropriate icon to use. /opt is a typical directory where self-contained "all in one" applications can be located.
Comment: It turned out that I had it in .local and when I updated the Icon=/opt/sqldeveloper/icon.png, it showed up instantly without logging out.
Answer: I use a program called "Main Menu" or "Alacarte"
To Install:
sudo apt-get install alacarte
Then open Main Menu through the dash.


Change/reset password WITHOUT monitor/keyboard

Question: I forgot the password to my Pi, but don't have access to a compatible monitor/keyboard. I've seen methods like these but they all involve editing cmdline.txt and then booting with a monitor and keyboard attached to run passwd pi from the main console. Is there a way I could do a similar thing (or something completely different to the same effect) but where I can interact via SSH/console cable?
Answer: The password isn't actually stored anywhere on the system, a one way hash of it is.  This means even if you have the hash, you won't be able to deduce the password.
The hash itself is stored in /etc/shadow.  Take the SD card out and stick it in another linux system; any common distro (ubuntu, fedora, arch, etc.) should do.  On that system, create a new temporary user -- do all this via sudo or as root:
> useradd tmpuser
> grep tmpuser /etc/shadow
tmpuser:!:16406:0:99999:7:::

The last line of output is just an example but that's more or less what you should see.  There might be two exclamation marks.  Now open /etc/shadow, find that line (the one starting with tmpuser, or whatever name you used) and remove the ! (or two) from between the first two colons, so it is tmuser::16406....  This makes this a passwordless account.  Now:
> su tmpuser
> passwd
Enter new UNIX password:

Go ahead and enter a password.  This creates a hash in /etc/shadow; if you run grep tmpuser /etc/shadow you'll now see a long string between the first two colons; it probably begins with $6$,, eg.
tmpuser:$6$jlBY96dq$V7tFs2xEv.a3kXArkyTEcEbGDX43d6UpzMcy/aplV8khxUFJKPMg0ugGBfWVZMpJRpaMXAATEAb5inu7/G.Iz1:16406:0:99999:7:::

If that's not there try sudo pwconv and check again (man pwconv explains this).
Now open the /etc/shadow file on the second partition of the SD card, i.e., the one used on the pi.  In there you'll find a line beginning with pi or whatever user it is you are interested in.  It will have a long string between the first two colons as above.  Erase that (only the stuff between the first two colons!) and replace it with the string from tmpuser on the current system.
You could just remove it and leave the account passwordless, but I think you may then have problems with ssh.  Whereas this method is pretty foolproof.
Unmount the partition, take the card out, boot it in the pi, and the password will be whatever you created above.  You can then change that with passwd if you want.
To remove the temporary user you created for this purpose on the other system (n.b., you could always skip that and just use the hash from an account you know the password for):
> userdel tmpuser

Comment: @PrashanthBenny the default flags for `/etc/shadow` seems to be `640`, i.e. readable by root group and not visible by others.
Comment: You sir are awesome. Thats a neat hack :)
Comment: Upvote - great instructional answer.
Comment: i had tried days with everything else since i dint have a display for my pi! This is a perfect hack for those who dont have a display! @goldilocks is the best
Comment: if there are any permission issues to **etc/shadow**, in console change permissions to the file by executing this line `sudo chmod 777 /etc/shadow` in the terminal. Also dont forget to revert the permissions by executing `sudo chmod 755 /etc/shadow`
Comment: I'm not a n00b in Linux, but for some reason this solution didn't work. I took a Debian image from osboxes.org, booted it in Virtualbox, mounted the SD card inside the VM, took the hash from its  `/etc/shadow` and pasted it into the `/etc/shadow` on the SD card. Then placed the SD card back into the pi and booted it, but the password doesn't work :(
Answer: You don't have to create a temporary user on a different system to generate a password hash. You can do it without root access by running:
openssl passwd -salt "salt" "password"

That gives you the hash string (using CRYPT) which you'll need to somehow put in /etc/shadow file on the SD card. If you want to use a different hash function (CRYPT is very old and insecure by now), passing -1 as an extra argument will generate an MD5 password (also insecure), -5 a SHA256 and -6 SHA512.
Another solution is to simply take the complete /etc/shadow from a working Raspbian image. This is only viable if you didn't create new users though.
Answer: A "similar thing" that comes to my mind:

Unplug SD card (data loss may occur...)
Put SD card into another machine running Linux
Access the SD card and open /etc/shadow
Replace the password hash for root
???
profit
Answer: Another easy thing you can do is leave the password empty on /etc/passwd mounted on your laptop e.g. by modifying a pre-existing pi user line to be:
pi::1000:1000:,,,:/home/pi:/bin/bash

This then allows you to login without a password, it just logs in automatically after typing the username pi. You can then add a password if you want after logging into the pi with passwd.
Tested on Raspberry Pi 3, Raspbian 9.4.
Comment: Note that this will write the new password to `/etc/passwd` (to where the x was before) instead of `/etc/shadow`. Solution: Before setting the password switch to root `sudo su` add back the "x" to `/etc/passwd` and then do a `passwd pi` from the root shell.


Sensible defaults for configuration

Question: I've recently started to play with Ruby on Rails which favours convention over configuration and relies on sensible defaults to tie various aspects of the application together.
I was thinking that it might be useful if this concept of sensible default configuration was used in general configation for various frameworks then it might save some development headache.
For example, in a .net app I usually want to log an exception in the windows event log using enterprise library exception handling block but if I don't explicity state the behaviour I want in a config file then EL will complain. I think that instead, if it can't find custom configuration then it should revert to a sensible default configuration, like logging my exception in the event log.
Would this be a good or bad concept for frameworks to adopt for their configuration?
Answer: I work a lot with a framework that does this exact thing. My trouble with this way of working is that:

the framework grew to having an excessive amount of configuration keys that are actually never used/set in a configuration file.
behavior of the software becomes implicit sometimes, I want to explicitly set the system to behave a certain way instead of having it fallback on some other code path due to a 'default'.
a missed typo in configuration key may result in a very long diagnostic session before figuring out what is going on.

When forgetting to set a configuration value I rather have the software tell me, instead of assuming some form of behavior that I might not at all be after.
I'd prefer a 'template' configuration file in which I change what I want and have the unchanged settings serve as the default.
Figuring which out which convention the software picked when debugging can be a lot of time wasted also.

Sensible defaults for configuration


PAR 38 LED in a PAR 30 recessed can

Question: Can you use PAR 38 LED floods in a kitchen where the receptacle says only use 30 PAR maximum?
Answer: First the good news: Electrically it would be fine as long as the PAR38 bulb's wattage does not exceed the receptacle's maximum wattage.  In the case of an LED bulb replacing an incandescent household bulb, you'll most likely be replacing a higher-wattage bulb with a lower-wattage bulb, but you should check the specs to be sure.
Now the bad news: PAR38 and PAR30 refer to the physical characteristics of the bulbs.  PAR = Parabolic Aluminized Reflector, 38 = thirty-eight eighths of an inch, or 38*1/8"=4.75".  30 = thirty eighths of an inch, or 30*1/8"=3.75".  As you can see, PAR38 has a larger diameter than a PAR30 bulb or can.  Depending on your fixture, the PAR38 bulb's connector may not even reach the receptacle, and if it does, the bulb will protrude past the fixture rather than being recessed.  Some people use extensions to bridge the gap and use the PAR38 bulbs anyway, but personally I think it looks horrible.
Also, keep in mind that a PAR-type bulb may produce more of a spotlight effect, whereas a BR-type bulb typically produces broader illumination, so you may want to look at BR30 bulbs unless you have high ceilings or prefer a more focused beam.
Comment: Thanks for the info. Even though our receptacles say 30 PAR max, the PAR 38 fit fine, so there must be some leeway. Thanks again. I was afraid there might be an over heat problem
Comment: I suspect it would be fine given that my outdoor PAR38 fixtures aren't vented and don't leave much of an air gap, but if you end up having several LED bulbs fail prematurely I wouldn't rule out a heat problem.  Some LED bulb housings are basically large metal heat sinks with fins that allow for venting and heat dissipation.

PAR 38 LED in a PAR 30 recessed can


Does migrating code from vb.net to a C++ dll offer significant performance boosts?

Question: I know simular questions have been asked before but I believe my specifics vary enough that this cam be it's own question. If I've missed another question that's very simular please link it for me.
I'm proficient in vb.net but a total novice at c++. I've got a subroutine in vb.net that just does a lot of maths. There's some trigonometry and squareroots etc. nothing too demanding but it's around 100 equations and they have to be run thousands of times.
Here's some pseudo code of what I do:
<code>Sub mathsub()
For i = 0 to arraylength
A = somenum(i) * othernum(i)
...
Next
End sub
</code>
So I do all the math inside the for loop many thousands of times. Each time uses a different element of a bunch of arrays (somenum, othernum, etc.), all of these arrays are the same length.
No single line of code takes any significant length of time (when profiled each line takes a negligible length of time), but all in all the program takes longer than I'd like. Can I expect a significant speed increase by rewriting this routeen in c++ and referencing it from vb.net?
Edit #1 - answers to questions in comments
The code takes a negligible amount of time per array element but there's about 20,000 elements and I need to do this about 10,000 times (so 200 million times - no joke). All in I've estimated it taking around 18 hours based on how long it takes for a fraction of the work. The entire program will need to be run multiple times as well, although each new run is 100% separate an unrelated. I have tried threading the code, I have a Ryzen 1800x 8 core (16 thread) processor - I've tried splitting the task into exactly 15 thread (leaving 1 thread for overhead and other activities) and using a parallel.for loop and both don't offer enough of an increase yet. I don't know what AVX is, but I'll start looking into it, I've never written a line of C++, but the maths itself is all just simple equations and I'm happy to spend a few days/weeks/months learning implementing if it's seriously going to make a difference!
Comment: Threading might be more relevant, ad that's available from vb.net as well. For serious speedups, you'd have to also use AVX, but that's not a realistic goal if you're a C++ novice.
Comment: How long does the VB code take to execute?  Even if you were to get a significant improvement, if the VB code executes quickly enough then it really isn't worth the effort.  For instance, a 50% increase in performance would be important if something takes an hour, could be important if something takes a minute but is likely not worth the effort if something takes a second.
Comment: The trig and math isn't going to be any faster, they are intrinsics in vb.net.  Might actually [be slower](https://stackoverflow.com/a/687741/17034).  But you might well be ahead with the array manipulations, a C++ compiler doesn't generate bounds checks by default and might be able to auto-vectorize and auto-parallelize the code.
Comment: "I'm proficient in vb.net but a total novice at c++" probably means that you will write better vb than you would c++ ... it might be fun as a learning project though
Comment: I've answered the questions from comments in my edit to the question. Thank you all for your input, I hope my answers help explain my problem a little more!
Answer: Benchmark it. There's no way to know that without benchmarking, but the answer is likely to be "yes" because of C++'s performance profile versus a managed language like VB.NET, but JIT optimizations, managed-to-native transitions, array access order / data locality, and general coding technique can all have an impact here.


What would you call a positive addiction?

Question: You can be addicted to exercise or healthy food or helping others in the sense that you feel good when you do it and bad when you don't. You can even have the dopamine responses that are conventionally associated with addiction. What word would you use to describe a person that is addicted to a beneficial activity without the connotation that there is something wrong with the person?
Comment: An _addiction_ is an adaptation that is physically necessary but socially condemned (it may be physically damaging as well). _Adaptation_ is the general term; humans are adapted to breathe oxygen in gaseous form, so we would be addicted to it if oxygen were socially condemned for any reason. Religions that banned it wouldn't last long, though.
Comment: Why not just refer to these as 'healthy habits.' If someone is actually addicted to exercise, i.e. experiences withdrawal symptoms when not allowed to exercise, that person is not well. If they have a habit of exercising and feel better when they do, that's not necessarily an addiction.
Comment: Perhaps [*dedication*](http://www.oxforddictionaries.com/definition/english/dedication).
Comment: Do you mean like eating?
Answer: Probably less negative than addiction.
What about-
fanatic

A person marked or motivated by an extreme, unreasoning enthusiasm.

or an enthusiast.

a baseball enthusiast.
(TFD)
Answer: You can say that they're very passionate about exercising, helping others, etc.

Passionate:
having, showing, or expressing strong emotions or beliefs
Merriam-Webster
Answer: We all have 'addictions' to water, oxygen, and a host of other stuff. No comparable dopamine responses, of course, but we get some pretty severe withdrawal symptoms if we don't get the amounts we need.
It's hard to come up with a non-negative correspondent to addiction, since the crux of that entire concept is its negative aspect.
Less negative and more neutral (though still tending towards the negative side of the spectrum) would be words like dependence (also dependency):

The state of relying on or being controlled by someone or something else

It is also defined as a synonym of addiction, but to me at least, it sounds a bit less negative, since you can depend on something without actually having all the symptoms of an addiction.
Another option, slightly vaguer, would be reliance:

Dependence on or trust in someone or something

I'm not sure if it really makes much sense to say that someone relies on exercise or on helping others as a general statement, though: you'd more expect to hear it in a more specific context like the following:

Her diet is surprisingly bad—she relies (or is reliant) on exercise alone to keep her figure.
Answer: Devotion may suggest a strong positive attachment:

earnest attachment to a cause, person, etc;

"their devotion to each other was beautiful"

commitment to some purpose;

"the devotion of his time and wealth to science"

(TFD)
Answer: Altruism - the belief in or practice of disinterested and selfless concern for the well-being of others.
Another choice:

benevolence - disposition to do good
Comment: These terms lack the connotation of *being addicted*. Some people are behaviourally predisposed to altruism and benevolence, but for most of them this tendency is not a *compulsion*.


The STM32L431 EXTCLK MCU pin 14 and 15 need to be conected or not

Question: Is there a way to make the internal MSI (RC) clock recalibrate itself (automatically in hardware) onto the LSE 32.786kHz clock input, effectively reaching the same precision as a sealed-external oscillator? the slow speed clock (LSE) cannot be fed into the PLL circuitry which provides e.g the 80Mhz core clock.
Answer: The Reference Manual for your part states in section 6.2.3

Hardware auto calibration with LSE (PLL-mode)
  When a 32.768 kHz external oscillator is present in the application, it is possible to configure
  the MSI in a PLL-mode by setting the MSIPLLEN bit in the Clock control register (RCC_CR).
  When configured in PLL-mode, the MSI automatically calibrates itself thanks to the LSE.
  This mode is available for all MSI frequency ranges. At 48 MHz, the MSI in PLL-mode can
  be used for the USB FS device, saving the need of an external high-speed crystal.

So yes, it does look possible.
Answer: According to ref. manual, chapter "6.2.3 - MSI clock", if you use MSI + PLL, it automatically autocalibrate by hardware when an LSE is present.
I've not tested it, but according to ref. manual you have to do nothing to achieve what you want.
However, this is obvious just reading the ref. manual. If you hadn't search this in the manual before asking, you should do it in the future, you are expected to search for the solution by yourself before asking. If what happens is that this is not what you need, maybe you should clarify your question.


I can't boot my Compaq Presario desktop from an Ubuntu 12.04 usb

Question: I have a Compaq Presario sr2017cl desktop running Windows7. The computer locked up and when I did a hardboot and now I get a "disk read error occurred, press control alt delete to restart."
Upon pressing control alt delete, I'm taken to the same screen.
I have a parted magic disc that I've used recently on a Dell laptop that worked beautifully. I can't get the Compaq to boot from the dvd even when I change the boot order in the bios, nor can I get it to start from the Windows 7 recovery cd.
I have Ubuntu 12.04 LTS on a usb drive that I used to install ubuntu on a HP laptop which I'm using right now. When I try to boot the desktop from that same usb, it won't boot from it and I get the same disk read error over and over.
I've researched this extensively online and the only answers I come up with are to change the boot order, or use f10 to choose what to boot from. I've tried that repeatedly to no avail. I've also tried unplugging the power, holding the power button for a full minute and powering back up. so far, nothing has worked. I'm at my wits end. I know both the parted magic dvd and usb work correctly but I can't get them to work on this bleeping computer.
Any help would be greatly appreciated.
Comment: The error message indicates a hard drive problem.  Check your BIOS to see how the drive controller is set.
Answer: It sounds like you might have a corrupt hard drive. Try purchasing an external hard drive adapter and see if the hard drive will pop up for available use. If your hard drive does not become available when using the external hard drive adapter on the other computer you are using to make this process happen, you will know if you do or do not have a damaged hard drive.
If it does work, then you will know at least that your hard drive is working properly.


FreeFontPath: FPE "unix/:7100" refcount is 2, should be 1; fixing

Question: I tried to run Xvfb in my Centos 5.7 machine to get thumbnails of websites.
I follow this Xvfb + Firefox site and install Xvfb, firefox on my Gnome Centos 5.7.
No problem at all for installation, yet when I try to run
DISPLAY=:1 firefox-remote http://www.google.com/

I kept getting this error message
FreeFontPath: FPE "unix/:7100" refcount is 2, should be 1; fixing.

and I can not proceed with anything else now. Hours of hours spent and still have no clue, please help me out here.
Answer: This fixed it for me:
http://corpocrat.com/2008/08/18/fix-freefontpath-fpe-unix7100-refcount-is-2-should-be-1-fixing/


How to publish a web service?

Question: I have a android application which wants to connect to C# server application via a web service. I have develop the web service. But I don't know how to publish it to connect to my android application in the phone. Can any one tell me how to publish a.NET web service to internet?  Thank you
Answer: You need to publish the web application project or web site project containing the web service.

How to publish a web service?


Htaccess file to protect files on the server

Question: I created a php script that allows you to download and upload files. Files are saved to a directory XXX. Can I add an htaccess file to protect files in this folder? I would want that people must login to my web site to download files. I would want that people who know the position of XXX can not download file without to login to control panel of my web site. What should I write in this htaccess file? The site is hosted. Files can have any extension.
Answer: You can do something like this in your htaccess:
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^files/([^/]+)/([^/]+).zip /download.php?folder=$1&file=$2 [NC]

All requests to files/XXX/YYY.zip will be rewritten to files/download.php?folder=XXX&file=YYY and your php can handle the authentication.


Rotation Keybinds

Question: I would like to know if there is a keybind for grabbing the Y-Axis on the rotation tool. I have a "bug" (idk if it is) where I can only grab the Z-Axis and nothing else. If somebody can help me thank you!
Answer: it should just be R > Z in object mode or in edit mode
if you get stuck on rotating and axis then press the right mouse button to cancel.
also you can go to user prefs > input and search for any key combos you want. and even change them.

Rotation Keybinds


machine learning mode are suitable for using word features as x, and y as click rate of text

Question: Hi I want to extract words of english texts using click rate with machine learning model. Now I know the click rate of text, and I know How to extract words(unigram) of each text, for example, there are about 10000 texts,and the click rate of each text is provided. How to extract words features for click rate. How to extract key words and compute the importance of each word for computing click rate.
Comment: Understand that there is a click rate for the text as a whole, and words within the text. I also understand that you want to compute / correlate both. Could you elaborate what that correlation would mean, and what the purpose of it would be?
Comment: hi @Frankstr, thanks for your comment. I know that using the linear regression model for computing the correlation of words for click rate. My purpose is to compute the correlation of words for text to extract key words or high importance words for improve click rate that influence click rate for new text.
Comment: Thanks. I hope I got the point now,  extract the important words for each text to learn which topics are well received. My misunderstanding was that I wrongly assumed "compute the importance of each word" means to discriminate words within a single text in a more sophisticated way than picking the topic.
Answer: You can build a dictionary of character sequences (words) and for each instance of text you will count the occurrence of these words. You can either use groupings of characters n-grams or words them selves using bag-of-words.
n-grams
n-grams is a feature extraction technique for language based data. It segments the Strings such that roots of words can be found, ignoring verb endings, pluralities etc...
The segmentation works as follows:
The String: Hello World
2-gram: "He", "el", "ll", "lo", "o ", " W", "Wo", "or", "rl", "ld"
3-gram: "Hel", "ell", "llo", "lo ", "o W", " Wo", "Wor", "orl", "rld"
4-gram: "Hell", "ello", "llo ", "lo W", "o Wo", " Wor", "Worl", "orld"
Thus in your example, if we use 4-grams, truncations of the word Hello would appear to be the same. And this similarity would be captured by your features.
Bag-of-words
Bag-of-Words builds a dictionary of the words it has seen during the training phase. Then using the word the frequency of each word in the example a vector is created. This can then be used with any standard machine learning technique.
Comment: Sounds like a start. To extract topics some more processing will be needed, removal of high frequency words aka stopwords, also perhaps POS tagging, part of speech tagging.
Comment: thanks for your answer, how to compute the importance of each words in the model?
Comment: a large field... perhaps you can start with https://en.wikipedia.org/wiki/Topic_model for a list of algorithms
Comment: @tktktk0711, the model is precisely what will decide the importance of each word in discriminating between different output distributions for classification.


Can you find Yenna's mother?

Question: Besides Yenna's plot involvement in the camp, is there supposed to be a questline for finding her mother? I never really agreed to help her so maybe that's why I don't have anything related to that (and if that's the case how could I initiate such quest afterwards?)
Answer: No, you cannot find Yenna's mother. Nor is there a quest to attempt to do so.
The presumed "why" is actually pretty interesting, and it's entirely because of the particular role Yenna plays in the overall plot -- she's there as a schrödinger's trojan horse.
Act 3 Spoilers

 During Act 3, Orin, a Changeling, steals one of your party members and
 holds them captive. There are three criteria:

 - The captured party member can't be a member of the active party;

 - The captured party member must be Lae'zel, Halsin|Minthara, or Gale;

 - The captured party member can't be romanced by the player

 These requirements are actually pretty strict - it's easy to deny Orin
 a victim. In such scenarios, Yenna is the fallback, with Orin
 capturing her instead (and murdering poor Grub the cat).

 This does lead to some strangeness though -- Yenna disappears from
 your camp once Orin's machinations are revealed, even if a valid
 companion was found. There's no follow-up in that case; Yenna is
 simply gone.

 In short, Yenna is the backup resolution to ensure the game plot progresses normally. The fact that her mother is missing simply gives her the plausible deniability to insert herself innocuously into your camp.
Comment: This reads like an answer to "Where is Yenna" rather than "Where is Yennas MOTHER". You don't answer the question if there is a quest related to the mother.
Comment: Couldn't figure out how to get better formatting what with the spoilers and all -- if there's a better way, I'd appreciate a gussying up!
Comment: Yeah, I appreciate the details but the focus was on her mother since that was the whole reason she even joined. On an unrelated note, I never seemed to lose Yenna despite triggering all these events - in fact she's still making soup in all my camps towards the ending.
Comment: Should have named her Biff.
Comment: My first playthrough I took on Yenna but Orin never interacted with her, just snatched Halsin. 2nd playthrough I actively refused Yenna to come along but she showed up anyway. Then Orin killed Yenna _and_ snatched Lae'zel. Also in a latter combat encounter someone raised dead Yenna as a skeleton, so there's now a pile of splatter where she used to stand. Her cat is fine though! Err, yeah this whole thing is pretty glitchy.

Can you find Yenna's mother?


Linux distribution for a netbook with 7-inch display with 800×480 screen resolution

Question: What distros work well on an eeePC with an 800x480 7-inch non-touch display and a 2GB SSD flash drive? I tried a couple, but they're definitely not optimized for 800x480. I need something for rich text editing, for video, and for web browsing.
Answer: I use Archlinux on mine.  It's worked well for me for nearly four years now.
Answer: Ångström is probably your best bet; it's made for embedded devices, which frequently have smaller screens.


Can't boot windows 8 after installing ubuntu 12.10!

Question: I installed ubuntu 12.10 using something else. I made 2 new partitions in which I installed the swap and the file system. After I installed it, I found I couldn't boot windows 8. It booted straight into ubuntu 12.10! What do I do? If I can't fix this I'm going to be in some serious trouble with my dad... I didn't use any windows partitions... What happened? I need to find out how to boot windows 8 again. Please, somebody help me...
Comment: You can try [Boot-Repair](https://help.ubuntu.com/community/Boot-Repair)
Comment: Possible duplicate of http://askubuntu.com/questions/87409/i-cant-get-grub-menu-to-show-up-during-boot/101693#101693.  To answer your question, though, have you tried holding shift during boot?
Comment: Error in sitecustomize; set PYTHONVERBOSE for traceback:
EOFError: EOF read where not expected
Comment: No, the grub menu shows up. It's just that windows 8 isn't in it.
Comment: I get the above error when trying to install boot-repair. Can somebody help me?
Answer: Boot into your Ubuntu system, or if you cant boot with a LiveCD or LiveUSB.
You should install boot-repair in order to restore your GRUB settings easily.
Open a terminal and type:
sudo add-apt-repository ppa:yannubuntu/boot-repair && sudo apt-get update

Then press enter.
After that type:
sudo apt-get install -y boot-repair && (sudo boot-repair &)

Then type
boot-repair

in the terminal to launch boot-repair.
Then click recommended repair and do what it ask from you.
Source: https://help.ubuntu.com/community/Boot-Repair
Answer: I wish you didn't delete your windows partition, but you can add windows 8 entry to grub in this way:
to get your windows 8 UUID:
1) sudo blkid
add windows 8 to grub
2) sudo gedit /etc/grub.d/40_custom
3) copy and paste these lines into the file [REPLACE UUID_FROM_WIN8 with what you got from number 1]
menuentry "Windows 8 UEFI" {
     search --fs-uuid --no-floppy --set=root UUID_FROM_WIN8
     chainloader (${root})/efi/Microsoft/Boot/bootmgfw.efi
   }

again i wish you didn't delete your windows partition. confirm if solved.
Comment: I have a couple of partitions that might be it. OS,PBR IMAGE, WINRETOOLS, ESP, DIAGS, and a random key of numbers. I think it would be OS, right?
Comment: By the way, I can't access the grub menu anymore.
Comment: Can somebody help me install boot-repair?
Comment: press ESC while the computer start, by the way i think it is OS
Answer: I'd try Rescatux instead of Boot Repair.  I believe Boot Repair is now only available as part of a specialized Ubuntu live DVD, a 900+ MB download, whereas Rescatux you just download the program .iso image, burn to CD, run on boot.  Much faster and easier to use.  It's never failed me.
Then to set Windows as the default, boot into Ubuntu, then go to this page
https://launchpad.net/~danielrichter2007/+archive/grub-customizer
and follow the instructions to download and install grub-customizer.  Once installed, you can access it via the Settings Manager and set the computer to boot by default into Windows.
You might also try using testdisk (you can install it from the software center) to locate and restore the windows partition if you've deleted it.
If all else fails and your dad has to reinstall Windows, he can access the Windows partition by booting into the Ubuntu live DVD.  When the window asking if you want to try or install Ubuntu pops up, click Try, then you'll see the Windows partition near the bottom of the Unity bar showing up as a separate drive or volume - it'll have some strange gobbledygook name, more likely than not.  That way your dad can copy the files he needs (documents, photos, email, etc.) to a separate HD before doing the Windows reinstall.
Comment: ok for Grub-Customizer and TestDisk, but the start of your answer is incorrect. Unlike Boot-Repair, Rescatux is not compatible with UEFI, nor SecureBoot, nor LVM, nor RAID, and there are many GRUB bugs that it cannot fix. So it's useless for new computers (all Windows8 PCs, and many Windows7). Boot-Repair is a 1MB software that you can install on any Ubuntu/Mint/Debian disk. And there are plenty of disks with Boot-Repair preinstalled, including Boot-Repair-Disk (350MB) and Linux-Secure (= Ubuntu iso with Boot-Repair preinstalled).
Answer: I found out how to make it work! I went to boot options just before ubuntu booted and selected UEFI OS. Now all I need to do is show the grub menu. I edited the grub file but I still can't see it.