Confusion about differentiating a variable with respect to a function of that variable (and others).

Question: I was considering this function $F(g(x_1,x_2,...,x_n),x_1,x_2,...,x_n, y,z)$ (I guess you could really forget about listing $g$ as an argument of $F$ but I just wanted to stress that the $x_j$ appear in a combination which equals $g$. I wanted to find the mixed derivative $\frac{\partial }{\partial x_i }  \frac{\partial F(g(x_1,x_2,...,x_n),x_1,x_2,...,x_n, y,z)}{\partial g }$ (I'm not sure the use of partials here is technically correct). I was wondering (A) is this a valid thing to do and (B) if it is how would you differentiate the "loose" $x_j$ terms with respect ot $g$? Something like $\frac{\partial }{\partial g}  = \sum \limits_{i}^{} \frac{\partial x_i}{\partial g} \frac{\partial }{\partial x_i}$ doesn't seem to give a reasonable result?
Does this only work if $g$ is a function of a single variable, say $x_1$?
Comment: please don't ever write things like $\frac{\partial}{\partial g}$. I suggest you take a look at the following answer of mine: [partial derivative of functions of functions](https://math.stackexchange.com/a/3270436/568204) to see how to properly interpret the partial derivative notation and how to write things correctly
Comment: Hi, thanks a lot for pointing me to that post. I find your notation very helpful in clearing things up. There were just a couple of things that I was still unsure about after reading. If we have have
$f:\mathbb{R}\times \mathbb{R} \to \mathbb{R}: f(x(t),t) = x(t)+t^2$ with $x(t)=t^2$ say, what if we were to consider $(\partial_1 f)(x(t),t)$? Would this be equal to 2 or to 1 (I would have thought the former as surely we just note $t^2=x(t)$?
Comment: Secondly, how exactly do we consider $(\partial_1 f)(x(t),t)$ because, as you say, it's not possible to vary $x(t)$ without varying $t$? Are we literally thinking about varying the definition of the function $x:\mathbb{R} \to \mathbb{R}$?
Answer: Addressing your comments as an answer, because too long for a comment.
First of all, saying the definition of $f$ is "$f(x(t),t)=x(t)+t^2$ with $x(t)=t^2$" is a nonsense definition for the function $f$. One should say "define $f:\Bbb{R}^2\to\Bbb{R}$ as $f(\xi,\eta)=\xi+\eta^2$" for example. Or even saying "$f:\Bbb{R}^2\to\Bbb{R}$ as $f(@,\sharp)=@+\sharp^2$" is fine, because as I mentioned, the choice of symbols do not matter. What is important however is that you have to prescribe for me the value of $f$ at any arbitrary point of the domain. In this case, the function $f$ takes as input a tuple of real numbers,and as an output it gives you the first entry of the tuple added to the square of the second entry. So, $f(7,4)=7+4^2=23$ and so on.
Next, I think you should reread the entire second half of my answer there because it seems you're still not clear on the difference between the distinction between a function and its values at certain points.
Now you're saying you want to introduce a new function $x:\Bbb{R}\to\Bbb{R}$ defined as $x(t)=t^2$ for all $t$. Ok. At this stage, I could define a billion other functions. It still will not affect what $\partial_1f$ and $\partial_2f$ are. Just to make this abundantly clear: for all $(\xi,\eta)\in\Bbb{R}^2$, we have
\begin{align}
(\partial_1f)(\xi,\eta)&=1\\
(\partial_2f)(\xi,\eta)&=2\eta
\end{align}
So, $\partial_1f$ is the function which regardless of what it takes as input, always gives the number $1$ as output, i.e it is the constant function $1$. Next, $\partial_2f$ is the function which eats a tuple of numbers and spits out twice the second entry of the tuple. That's it.
So, for each $t\in\Bbb{R}$, the quantity $(x(t),t)$ is a tuple of numbers, hence we can plug this into $\partial_1f$ and $\partial_2f$. So, as per above, we get
\begin{align}
(\partial_1f)(x(t),t)&=1\\
(\partial_2f)(x(t),t)&=2t
\end{align}
For your question about how can we consider $(\partial_1f)(x(t),t)$, I suggest you reread my linked answer. By definition, the symbol $(\partial_1f)(@,\sharp)$ means
\begin{align}
(\partial_1f)(@,\sharp)&:=\lim_{h\to 0}\frac{f(@+h,\sharp)-f(@,\sharp)}{h}
\end{align}
As you can see, the only thing needed to compute this limit is knowledge of the function $f$ and the point of consideration $(@,\sharp)$. So, similarly, if you fix a value of $t\in\Bbb{R}$, then $(x(t),t)$ is a particular tuple of real numbers, and we have
\begin{align}
(\partial_1f)(x(t),t)&:=\lim_{h\to 0}\frac{f(x(t)+h,t)-f(x(t),t)}{h}
\end{align}
What you're probably getting confused with is what happens when we consider the single variable function $g:\Bbb{R}\to\Bbb{R}$ defined as $g(t)=f(x(t),t)$. Suppose I want to calculate the derivative of $g$ at $\pi$. Well, the chain rule tells us
\begin{align}
g'(\pi)&=(\partial_1f)(x(\pi),\pi)\cdot x'(\pi)+(\partial_2f)(x(\pi),\pi)\cdot 1\\
&=1\cdot x'(\pi)+2\pi\cdot 1\\
&=2\pi+2\pi\\
&=4\pi
\end{align}
Just so we're absolutely sure, lets verify this another way. We have
\begin{align}
g(t)=f(x(t),t)=x(t)+t^2=t^2+t^2=2t^2
\end{align}
So, of course, $g'(\pi)=4\pi$, just as we calculated. Of course, this entire calculation holds not only for the specific number $\pi$, but for any real number $t$. So,
\begin{align}
g'(t)=(\partial_1f)(x(t),t)\cdot x'(t)+(\partial_2f)(x(t),t)\cdot 1 = 4t.
\end{align}
In my linked answrr, I explicitly wrote down the limit definitions of $(\partial_2f)(x(t),t)$ and of $g'(t)$. Compare the differences.
Comment: Thank you very much for your detailed answer. This is a very helpful way of thinking about multivariate functions and partial derivatives which I shall certainly keep in mind moving forward. I believe my confusion was rooted in the fact that it is not possible to think about taking the partial derivative with respect to some function of the arguments of a multivariate function. In my head this seemed plausible because it is possible for single-variable functions.


Dell XPS 13 (9350) on Ubuntu 16.04 - touchpad stops working or works erratically

Question: I have pretty much the same problem as in Dell XPS 13 9350 with Ubuntu 15.10 - Touchpad freezing, jumping - but on Ubuntu 16.04.
My touchpad stops working randomly, or can work somewhat only if I click and drag with it. Sometimes it starts working if I do a two-finger scroll, but this doesn't always work.
I have installed a mainline kernel (version 4.4.13-040413-generic) to fix an issue related to resuming after suspend. However, the present touchpad issue was present on a vanilla 16.04 install too.
Any help is appreciated. How would I even begin debugging this? (I am not shy to use the terminal or modify my system, as long as I know how to bring it back to a working version, in case the experiment fails).
Comment: what did you learn, DenverCoder9?
Answer: I had the same problem when I put Ubuntu 16.04 on my Dell XPS13 (9350). For me the problem was largely resolved by installing libinput:
<code>sudo apt-get install xserver-xorg-input-libinput
</code>
The only issue I have now is that the mouse pointer freezes once in a while. But this is very rare and I can always unfreeze it with a left click. Overall I'm very pleased with the improvement libinput has made to the performance of the touchpad.
You can read more about this solution at https://askubuntu.com/a/678122
J-Linux
Comment: I tried this out for a week, but it doesnt seem to be helping. My touchpad still freezes but it's able to start working with a few clicks or by attaching a usb mouse. But there are instances where it doesnt fix itself.
Answer: I have experienced the same issue on my XPS 13 9350. I had the same issue about a year ago on my XPS 14 L421X. Dell updated the BIOS and then it was solved.
Answer: I had a more extreme version of this issue on my XPS13-9333. After the update from the pre-installed 14.04 to 16.04, I had no touchpad anymore. Nothing would bring it back.
Updating the BIOS as per these instructions magically brought it back to life


Do some languages have articles besides the definite and indefinite articles?

Question: Most languages have either no articles, or one or both of the definite (akin to English "the") and indefinite (akin to English "a" / "an").
But are there other kinds of articles, and which languages have them?
Answer: Yes there are!
Another common one is the partitive.  If you've ever learned a language like French then it's an article you use with mass nouns like "water" or "cake".  In English the closest would be something like "some" as in "Would you like some cake?".  Occasionally you'll see it written by linguists as "sm", as it is phonologically reduced in speech.
Here are some examples from French:

Je ne bois pas de café.
Je n'ai pas de temps à perdre.
Donne-moi de la glace.

I'm sure there are probably others!
Comment: Your first two examples do not really list partitive articles, do they? The partitive articles are "du" in masculine and "des" or "de l'" in plural. I guess you can argue that the partitive article has a negative counterpart, "de" (even though I would say this is just a special use of the preposition "de" :D)
Comment: Please add some of the actual such articles from French or any other language from which you know them (-:
Comment: Yes, it's partitive, not partative.
Comment: I think what she had in mind is, for example: Je ne bois pas *de* café. / Je n'ai pas *de* temps à perdre. / Donne-moi *de la* glace.
Comment: isn't it called the *partitive*?
Answer: It is worth noting, I think, that "article" is not a theoretical primitive in (most if not all) contemporary generative theories of syntax.  A generative syntactician would say that languages have larger or smaller inventories of determiners (e.g. this, that; this is the category from which the developed) and quantifiers (e.g. one, many, no; this is the category from which a(n) developed).  However, articles are a notion of classical grammar and are definitionally restricted to the definite and indefinite.
(Some grammarians might include more kinds of articles, as the Wikipedia article on articles does.  But this reflects more a taxonomic whim of the analyst than a fact about language.)
Comment: Yes that's true, determiners do seem to be a more satisfactory category. Nonetheless I'm still interested in the analyses or traditional treatments of many languages which talk about articles, whether any do include other types.
Comment: I actually asked a followup question based on this answer. A few years ago already: [Does Japanese have determiners?](http://linguistics.stackexchange.com/questions/85)
Answer: By some accounts, "no" is considered an article, distinct from definite and indefinite.  To me it affects the reference in a very different way than the other two ("a couch," "the couch," "no couch"), but I know none of the proper linguistic theory on the matter.
Comment: Yes "kein" is often listed in paradigms in German I've noticed.
Comment: @JamesTauber Probably.  As some others discussed, 'article' isn't really a common term in academic linguistics, and as such it overlaps with several other more rigorous terms, like quantifier and determiner.
Comment: wouldn't it best be considered a quantifier?
Answer: Don't forget the demonstratives.  Old Church Slavic had a definite article (i), a proximal or 'this here' demonstrative (sej), a distal or 'that over there' demonstrative (on), and a simple 'this/that' demonstrative (tъ).
Comment: I know definite articles generally if not always evolve from demonstratives, but are demonstratives considered to be articles?
Comment: Ah this makes sense since another name for for Old Church Slavonic is Old Bulgarian and modern Bulgarian does have something very similar.
Answer: As Bill Sullivan noted - The demonstratives in Slavic languages can evolve to articles. One example is Macedonian (and perhaps western Bulgarian dialects):

One feature that has no parallel in any other standard Balkan language is the existence of three definite articles pertaining to position of the object: unspecified, proximate (or close) and distal (or distant).

Romanian has something called Genitival article (which is nothing extraordinary - just an article in genitive)
The wikipedia article about "article" lists: definite, indefinite, partitive, negative.
Comment: Yes indeed I am travelling now and having arrived in Macedonia I read about this in Wikipedia and thought it would make a good test question to ask in a wide open way. I thought if Macedonian has some extra one what other languages might?
Answer: Some languages also have a zero article (i.e., they have overt articles, but can omit them). In English, for example, you can say "I saw turtles on the beach", whereas in French you would have to add the indefinite plural article: "J'ai vu des tortues sur la plage".
Comment: Ah yes you found a nice technical loophole I knew about but wasn't thinking about when I posed my question (-:
Answer: Catalan has personal articles used with person names, e.g., en Pere "Peter" as opposed to el/un noi "the/a boy".
Answer: I just came across some info trying to learn a bit about Albanian in Albania.
Albanian has a kind of article called an "adjectival article".
I haven't been able to find out much about them though so I've asked a question about them.
Answer: Creoles tends to have three ways of marking noun phrases for definiteness:

definite, for already known, specific information ({the} in English)
indefinite, for new, unknown but still specific information ({a/an} in English)
not specific, usually unmarked (also {a/an} in English, or unmarked)

The first time you mention something you mark it indefinite, later you use the definite marker and if it is not specific or important you use the third option. Naturally I can't remember the reference for it (book used in grammaticalization-class I think) but apparently there can be two types of nonspecificness too, for new and old nonspecific information: In such a system "dogs bark but foxes bark too" the nouns would be marked differently. IIRC no more than three of the four possibilities are marked in any one language though.
Then there are the languages with only one article of course... or none, but opinions differ on whether all languages always mark definiteness (needn't be with an article!) or not.
For those interested in definiteness there's the book "Definiteness" by Christopher Lyons. I haven't read it myself as I'm not very interested in the subject. The other books I have read in the series it is part of though, Cambridge Textbooks in Linguistics, have never disappointed even though of course some linguists just can't write and needs to be read in small doses lest your eyeballs bleed ;)
Comment: Yes one point of asking my question was whether definiteness is the only concept that articles can address. I would love if you can find and include some examples in your answer.
Comment: Can you provide an example from a Creole with three different articles like the ones you describe?
Answer: Basque has a definite article that could be taken as special in some ways:
-It is an affix
-There are no nude Basque NPs, and the affix definte article is added to the NP is no other determiner or quantifier appears
-The so-called definite article also appears in predicates, i.e. in phrases with no referential value.
Comment: I don't understand, what is the article you're talking about?


Can server 2008 session broker be used in a 2008 R2 terminal server farm

Question: i'm building a terminal server farm using two 2008 R2 terminal (remote desktop) servers but i do not have a third R2 server in my network for the session broker so i was wondering if i can use a 2008 server for the session broker.  i would imagine that this would work but i wanted to ask if anyone knows for sure.
Answer: I don't have a link to a document that mentions this, but my experience when I added our first 2008R2 server tells me that the answer to this is yes a 2008R2 terminal servers will work with a 2008 session broker.  I am not certain if it is 100% functional though.


Wireless issue in lenovo g40-30

Question: i see in the forum differents steps to repair the issue i got in my computer, i got computer Lenovo g40-30, the issue is; the wireless or wifi connect for a few minutes and after some time, the connection is drop, and i need to reboot the ocmputer and have internet again or just connect connect by wire in LAN, when i restar the computer i see this:
~$ sudo rfkill list
0: ideapad_wlan: Wireless LAN
    Soft blocked: no
    Hard blocked: yes
1: ideapad_bluetooth: Bluetooth
    Soft blocked: yes
    Hard blocked: yes
2: hci0: Bluetooth
    Soft blocked: yes
    Hard blocked: no
3: phy0: Wireless LAN
    Soft blocked: no
    Hard blocked: no
To be honest, i dont have much time using Ubuntu but i got some idea, can you help me to know what should i do in the issue? And still the change to dont restar my computer.
64bit
~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.3 LTS
Release:    14.04
Codename:   trusty
thank you for your time, have a great day.
Comment: if i put command:

sudo modprobe -r ideapad_laptop
sudo rfkill unblock all

Works during few minutes, but not back again, i check in Bios if the wireless is disable, but is enable.
What should i do?

Thank you for your help.
Answer: To specify i got this Lenovo G40-30 with XUbuntu 64bits.
i got good news!! i resolve this with more help, for example, first i have the help for other guy who work with laptops and he told me verify first what kind os PCI wireless the unit have installed in this computer, and i see i have INTEL not REALTEK the model is
WirelessLan_Non_Intel, Cbt RTL8723BE
1x1BN+BT4.0 PCIE M.2 WLAN
So i found some information with put in the terminal "uname -r" i have "3.13.0-74-generic" and i didi the steps in the webpage http://ubuntuforums.org/showthread.php?t=2261702
sudo modpobe -r rtl8723be
echo "options rtl8723be fwlps=0 swlps=0" sudo tee -a /etc/moprobe.d/rtl8723be.conf
sudo modprobe rtl823be

sudo apt-get install linux-headers-generic build-essential git
git clone https://github.com/lwfinger/rtlwifi_new.git
cd rtlwifi_new
make
sudo make install

After i reboot the unit and put:
sudo modprobe -r ideapad_laptop
sudo rfkill unblock all

And last thing! to keep changes put:
sudo add-apt-repository ppa:hanipouspilot/ideapad-laptop
sudo apt-get update
sudo apt-get install ideapad-laptop-dkms
sudo apt-get update
sudo apt-get upgrade

Restart your computer
And for now is working, i dont have cut signal and still online more than the time i was working.
Im not expertice with Linux, but this help a lot, and i would like continue working with Linux.
Comment: You did too many things. The first part from github is not needed, or the last part with ppa. I am afraid that now the driver is blacklisted and it will not be built by dkms.

Wireless issue in lenovo g40-30


Sun or the Sun?

Question: I'm coming up with a tagline for a solar company logo that says 'All you need is the Sun'. I am however confused with the use of 'the' and the capitalisation of 'sun' here. Are they necessary or 'All you need is sun' sufficient enough?
Answer: The capitalization or otherwise of 'sun' is a useful (but optional) device for distinguishing between our sun (i.e. the one at the centre of our own solar system) and suns somewhere else.
'The Sun' thus refers specifically to our sun, whereas 'sun' can mean both a sun (e.g. "That solar system has two suns"), our sun (e.g. "Remember not to look directly at the sun!") and sunlight (e.g. "It's time you came in out of the sun"), and is therefore ambiguous.
So how you decide to answer the question you have asked will depend on what you are trying to convey.
If you mean "All you need is (our) sun", then the most appropriate wording is "All you need is the Sun" or "All you need is the sun".
If you mean "All you need is sunlight", then I'd suggest you use that form of words if you want to avoid the ambiguity of "All you need is sun".
Comment: It seems to be a general slogan for companies of such kind, however, the capitalization probably  is for formatting purpose. Find two more instances of such expression in the following links. http://www.maccoenergy.com/solar-energy/   and
http://homeofsolarenergy.com/
Comment: Although technically speaking, solar power comes from "sunlight", it would sound warmer if you said "sunshine". Of course, there is "sunlight" even on a cloudy day, but "sunshine" only on a sunny day (or portion ), so pick whichever seems apt.
Answer: To me it sounds better the Sun because it somehow implies that is referring to sunlight, almost everything that is "all you need" can be changed to "you only need".
Comment: Actually, it is _sun_ that would imply "sunlight", whereas _the Sun_ implies the star. As for changing _all you need_ to anything, it is a very, _very_ commonly used phrase (see for instance [this song](https://www.youtube.com/watch?v=EKiqthx0GKw) ) and probably more idiomatic than "you only need".
Comment: @oerkelens well I was answering the question with the idea that it was for a company logo, a regular consumers always welcomes a character which in this case is "the Sun". I said "almost" anything, answering with a consumerism approach,  "all you need" implies everything and most of the cases everything implies plural objects, as of "you only" implies a single thing. what do you need? all or everything, vs only or just one. I used the consumerism approach. I agree with you.
Comment: @Meed or Got sunlight? or Got sun?  lol
Comment: "You only" implies a single thing? How so? I only want an explanation and a reference ... ^^

Sun or the Sun?


MLA: citing indirect sources w/o quoting

Question: I am working on a paper.  In this paper, I'm talking about how poverty affects African-Americans.  I found this great article in which the author talks about poverty and how it is related to mental illness.  She cites another article in which the author said that African-Americans in poverty are more adversely affected by said illness.  I want to include this research in my essay, but my college library doesn't carry the journal that said article is in.
Answer: According to the MLA guidelines, it is advisable to refer to primary sources. However, there are situations when one is not able to access direct sources and have to refer to indirect sources.

Sometimes you may have to use an indirect source. An indirect source is a source cited in another source. For such indirect quotations, use "qtd. in" to indicate the source you actually consulted. For example:
Ravitch argues that high schools are pressured to act as "social
service centers, and they don't do that well" (qtd. in Weisman 259).

(quoted from here)
Some of the other sources where you could find examples are here and here.
If your college library does not have access to the primary source, you could try looking online to see if you can find a copy. Alternatively, consider writing to the authors to see if they are willing to e-mail a copy to you. Your librarian might also be able to help you secure a copy. If nothing works, you can always cite indirectly like above.
Hope this answers your question.
Comment: What if Weisman never actually quoted Ravitch, just cited his document as a source?


For incoming requests to AWS Accounts, should we use Application load balancer or Classic load balancer?

Question: For incoming requests to AWS Account, when should we use Application load balancer or Classic Load Balancer? I understand that, if we use application load balancing, we would be able to do path based routing to specific port of EC2 instance or to respective container. Is that the only criteria?
Answer: You probably shouldn't use a Classic load balancer for a new application. The newer Application (L7) and Network (L4) load balancers are better on many aspects. Here's the feature comparison from AWS:
https://aws.amazon.com/elasticloadbalancing/features/#Product_comparisons
Comment: For every incoming requests, is it mandatory to be routed to the IP of the load balancer or it can be routed to an API gateway and make it highly available? Any specific patterns AWS offers?
Comment: AWS's elastic load balancers are already highly available. See: https://aws.amazon.com/elasticloadbalancing/


Are there any survey tools that are optimized to render correctly on mobile devices?

Question: My company would like to run a NPS survey off of our Mobile experience (app and website), are there any tools that will work well with mobile screens? We use Vovici, cvent and surveymonkey in house already and nothing is exactly what we are looking for. It would be nice to use a link to launch a mobile ready survey formatted to the right screen size that doesn't use tiny radio buttons that can be hard to select.
Answer: Our product, CustomerSure may fit the bill. Strictly speaking, we're a tool to gather and act upon customer feedback, rather than a general-purpose surveying solution like SurveyMonkey but we feel this offers a couple of advantages:

Our NPS-compatible surveys are deliberately very short and easy to complete (we've spent a lot of time on the experience), meaning better response rates.
Feedback and scores land in a tool which has been designed to encourage staff collaboration and actionable responses, rather than sitting neglected in a spreadsheet somewhere.

Our standard survey is clean, attractive and is easy to interact with on a touchscreen.
Apologies if this sounds in any way sales-y or spammy, it's not my intent, it just happens that our company produces product which seems to answer your question! A free trial is available if you'd like, or get in touch if you'd like more help. (I'll probably edit this answer to improve it if there's anything important I've missed).
Answer: I am updating with the answer we went with...
The upgraded version of Vovici allow surveys to be rendered in Mobile HTML. This has solved our problem. However, OpinionMeter also has a decent product that would allow us to do the same.


Encrypted file system in a hosted linux system

Question: I'm considering to use an encrypted file system (dm-crypt or gocryptfs) in a linux system hosted by Linode. Can the administrators of Linode access the mounted (i.e., decrypted) contents? I'm not sure which technology they use to provide a virtual system. But anyway I've installed Arch linux and have a full control on the system. I think they cannot modify the kernel and system softwares provided by Arch. So I think that as long as they don't know my root password, it's very hard to read the mounted contents. Is that true?
Answer: If it is a virtual machine provided by Linode, they can access the decrypted contents.
Linode controls the host OS of the VM, and the host can access all memory of the VMs. Therefore the host can extract the encryption key from VM memory, and use that to access the disk contents.
What is hard is a relative judgement, but Linode would have to go through some effort if they want to read your disk data.


Draw on map and and search by or get coordinates from graphic

Question: I have an app that uses mapkit and I have the annotations and everything going.
I would like some functionality that allows the users to draw, either freehand or draw out a box, on the map.  After the user creates this graphic (for lack of a better term) i would like to query my annotations for those that intersect with this graphic.  If this is inherent or easy to do great, otherwise if i can get the geometry of the graphic and can do searching with the min/max x/y through coordinates i have stored in a db.
I have looked into openGL/GLPaint but cannot quite connect the dots (so to speak).
Thanks.
Answer: The first thing that comes to mind would be to "display" a transparant view on top of your map to intercept the touch events.  This view could then add overlays and annotations to the map as it receives touch events.  You can then do your logic once all of your geometry is in the same coordinate space.
You would need a way to switch between "browse" and "draw" modes so that:

when you are in "browse" mode, the
map operates as usual.. swiping moves
the map, etc.
when you are in "draw" mode, the same gestures will draw on the map

This way you can enable the transparant view when in "draw" mode and hide/remove it in "browse" mode.  You'll need to convert your view points to coordinates or MapPoints which could be tricky but you should find all the methods to help you acheive this here:
http://developer.apple.com/library/ios/#documentation/MapKit/Reference/MapKitFunctionsReference/Reference/reference.html
I haven't tried this, but it might be worth trying.  Let us know how you end up doing it.


Mouse hover with CartoDB?

Question: Some of the CartoDB maps online, like Illustreets react constantly to mouse hover instead of requiring a click. Is there a way that I can do that with my CartoDB maps?
Answer: One of the CartoDB developers just put a great example of this, see http://bl.ocks.org/javisantana/8313604
Right now it does take some javascript coding, leveraging cartodb.js. In the future the team hopes to add hover functionality directly to the GUI.
Answer: Also, there are some CartoDB templates developed by Michael Keller that will give you some more hints on how to do the hover with JS.
Answer: Its now been added to the GUI check this and this

Mouse hover with CartoDB?


Call touchUp() programattically for sprite in LibGDX

Question: I'm trying to call touchUp() for a sprite i've created in my app.
i'm getting success but the co-ordinates do not match while i call it manually.
<code>final int x = (int)mySprite.getX() + 10;
final int y = (int)(Gdx.graphics.getHeight() - (mySprite.getY() - 5));

touchDown(x, y, 0, 0);
</code>
this code calls method perfectly but positions do not match. x and y values that i get in touchUp() method is different. it call touch up event of another sprite.
Answer: you have to unproject your coordinates
<code>  getCamera().unproject(new Vector3(actorX,actorY,0))
</code>
this method gives you a Vector3 with the coordinates you want.
If you want to do the opposite call project() method


how add custom field in "Order Summary" checkout?

Question: How I can add custom field with custom value in Order Summary? ty for answer
Comment: is it static field or dynamic ?
Comment: @BornCoder custom field static, value = dynamic
Comment: Create field in admin system.xml and use that field here, so that you will get dynamic value. If you  have any requirement depend on checkout page then you need create attribute for checkout page.
Answer: This is hard to explain. It's not just add field in checkout, you also need to add this field to admin order, invoice, shipment, creditmemo.
There are so many files and coding involve in adding just one field in order summery.
I would suggest use SilkSoftwar Module Creator: https://www.silksoftware.com/magento-module-creator/magento2-module-creator.php
Use the option "Need to Add New Extra Fee for Order" and generate your module, you will get whole coding of what you want.
Hope it will help you.


Modifying Windows ctrl-alt-del behavior through Gina

Question: Hello I am trying to change the behavior of the windows xp ctrl alt del key in certain scenarios throught Gina. Specifically I want to unhook the custom dialog that appears on ctrl alt del that was implemented in legacy code, and have my task manager back. Would someone point me at the right direction please?
Answer: Try this page: http://webhostingtalk.com/showthread.php?t=614457
It seems to describe the procedure for restoring the default behavior for Ctrl-Alt-Del.


Examples of function sequences in C[0,1] that are Cauchy but not convergent

Question: To better train my intuition, what are some illustrative examples of function sequences in C[0,1] that are Cauchy but do not converge under the integral norm?
Comment: A now-deleted answer suggested "example 7.13 of the following book: http://www.fysik.su.se/~walck/suf9601.pdf". If anyone can find that example, I urge them to post it as an answer, because it might be an interesting example, and I cannot find it.
Answer: You can get examples by considering elements of $L^1[0,1]$ that are not equal almost everywhere to any continuous function, and considering sequences of continuous functions converging in the $L^1$ norm to these discontinuous functions.  Because convergent sequences are Cauchy and $L^1$ limits are unique up to equality almost everywhere, such sequences will be Cauchy and nonconvergent in $C[0,1]$.
E.g., let $f$ be $1$ on $[0,\frac{1}{2}]$ and $0$ elsewhere.  Let $f_n$ be the continuous function that is $1$ on $[0,\frac{1}{2}]$, $0$ on $[\frac{1}{2}+\frac{1}{n},1]$, and linear on $[\frac{1}{2},\frac{1}{2}+\frac{1}{n}]$.  Then because $f_n\to f$ in $L^1$, $(f_n)$ is Cauchy.  (The Cauchy-ness is also easy to verify directly.)  If there were a limit function $g\in C[0,1]$, you would have $g=f$ a.e..  But this is impossible, because the left-hand and right-hand limits at $\frac{1}{2}$ would not agree.
More generally, a Cauchy sequence in a metric space $X$ with completion $\overline{X}$ that does not converge in $X$ is basically the same as a sequence in $X$ that converges to an element of $\overline{X}\setminus X$.  In a case like this where $X=C[0,1]$ with $L^1$ norm and $\overline{X}=L^1[0,1]$ have explicit descriptions, you can find examples by starting with an element of $\overline{X}\setminus X$, and find a sequence in $X$ converging to that element.  The same idea applies to demonstrating nonconvergent Cauchy sequences in $\mathbb{Q}$, where you can take any irrational number and consider the sequence of truncated decimal expansions.
Answer: By measure theory you can always pass to a subsequence that converges pointwise a.e. so it's usually quite easy to determine the only possible limit. Then you should try to build the examples in such a way that the pointwise (a.e.) limit has no chance of being continuous.
Here's an example of what I have in mind:
$f_{n}(x) = \begin{cases} 0 & 0 \leq x \leq \frac{1}{2} \\\ nx - \frac{n}{2} & \frac{1}{2} \leq x \leq \frac{1}{2} + \frac{1}{n} \\\ 1 & \frac{1}{2} + \frac{1}{n} \leq x \leq 1 \end{cases}$ defined for $n \geq 2$. It's easy to see that it converges in the $L^{1}$-norm to the characteristic function of $[\frac{1}{2},1]$.

Added: Since an $L^{1}$-Cauchy sequence will always converge ($L^{1}$ is complete by the theorem of Riesz-Fischer (or Fréchet-Riesz)), the only thing you have to do is to pick a function in $L^{1}$ that doesn't have a continuous representative. The easiest example is a step function (that's probably the reason why all three answerers came up with essentially the same example). This suffices, because every function in $L^{1}$ is the $L^1$-limit of a sequence of continuous (even smooth) functions, as can be seen by convolving with mollifiers, for example. In other words, $C[0,1]$ (or even $C^{\infty}[0,1]$) are dense in $L^{1}$.
Answer: How about the sequence of functions given by $f_n(x)=x^n$? This sequence is Cauchy in $(C([0,1]),\|\cdot\|_{L^1(0,1)})$ but does not converge in $C([0,1])$.
EDIT: This example doesn't work. Thanks for pointing that out. An example that does work is given by the sequence of continuous functions $f_n$ with
$f_n(x)=\frac{2}{n}(x-\frac{1}{2}+\frac{1}{n})$ for $|x-\frac{1}{2}|\leq \frac{1}{n}$, $f_n(x)=0$ for $x<\frac{1}{2}-\frac{1}{n}$ and $f_n(x)=1$ for $x>\frac{1}{2}+\frac{1}{n}$. That's basically a continuous approximation of the characteristic function of the interval $[\frac{1}{2},1]$, which is not continuous.
Comment: That's not what's asked. It converges in the $L^1$-norm (= integral norm) to zero.
Comment: Great. Now I supplied _your_ example...
Comment: +1 anyway. @Jonas: Well, three people coming up with essentially the same example doesn't make us seem  particularly inventive...
Comment: You're right, sorry. I'll supply a _valid_ example...
Comment: To obtain a somewhat more fancy example one can also take the sequence of partial sums of a Fourier series of a discontinuous but square-integrable function $f$, provided $f$ does not coincide with some continuous function almost everywhere.


Are animals killed in the production of rexine?

Question: Rexine is a material used widely as a substitute of leather. However, there is not much clarity on the materials used in its production. Sometimes, it is even referred to as "Artificial Leather". Does the production of raxine involve killing animals?
Answer: Rexine and other artificial leathers are cloth-backed plastics
In general, the whole point of artificial leathers is to not be animal skins, for either ethical or cost reasons. The cloth component is generally plant-derived (again for cost reasons), and modern plastics are purely synthetic.
If that's all you're worried about — that rexine might actually be animal skin — then you needn't worry about that. It's definitely not animal skin.
The Devil's in the details
However, every artificial leather uses its own production formula, and it's theoretically possible that minor chemical additives have an animal source.
Unfortunately, if all you know is that the material you're thinking of is called "rexine", there's no way to know for certain, since that's not enough information to know what the material actually is and track down its production formula. Brand-name Rexine is a specific type of artificial leather produced by Rexine LTD of the United Kingdom, but much like "kleenex" in the United States, the brand name "Rexine" has suffered from brand genericisation, and now many different materials are popularly called "rexine".
Brand-name Rexine: probably vegan
Based on Wikipedia's record of the formula, actual brand-name Rexine is probably produced without animal products: it's made from nitrocellulose (which is itself made from cellulose and laboratory-produced, mineral-sourced nitric acid), camphor oil, pigment and alcohol.
The "probably" is because of the non-specific use of "pigment": the vast majority of industrial processes use synthetic pigments rather than naturally-derived ones, due to greater colour-fastness and lower cost, but since animal-sourced pigments do exist, it's possible — however unlikely — that some colours of Rexine are coloured with an animal-derived pigment.
Buyer beware, and do more research
For all other artificial leathers, the specific manufacturer must be identified, and this can't be done just by finding out what trade name the material goes under. To find out exactly what a specific artificial leather is made out of, you'll have to contact the manufacturer directly and inquire about their formula's sources.
Conclusion
Artificial leathers are definitely not animal skin, and at that "large scale", they're not animal products.
It's highly likely that any given artificial leather brand does not contain any animal-derived ingredients.  For many artificial leather brands, this is the entire purpose. However, it's possible that a given artificial leather brand might use some innocuous chemical as part of its plastic production, which might have some animal source somewhere in its own production history. This is unlikely, but a possibility. If 100% vegan artificial leather is the goal, then the only way to be sure is to talk to the manufacturer of the specific artificial leather and get their response on how they source all ingredients for their formula.
Answer: Rexine sounds like a great alternative to leather, not only avoiding animal skin altogether but also being natural, avoiding oil based (basically plastic style) fabric.
A lot of the make-up is cellulose, which is plant fibre. This though might bring us to a situation similar to viscose which is made from plant and wood fibres, but where some have been concerned about chemicals used in in the manufacturing process. The raw material itself is natural and of course causes no animal deaths. However chemicals used might harm the environment (including wildlife) and might further introduce some element of toxicity in usage.
However there's a further negative point to the historical rexine which has me drop the possibility of it being useful altogether. The finish of cellulose nitrate is extremely flammable and therefore quite a dangerous fabric to use, having the potential to enable a small flame or burn to spread very rapidly.
This refers to the original, trademarked rexine, which I doubt is actually made anymore, though might still be made on demand by some producers.
I think that most modern leathercloth fabrics today which are called rexine are not the cellulose based, trademarked original and are likely to be more typical faux leather. (In other words, back to the world of plastics).
The only other natural, faux leather which I have come across is cracked cotton (or chapped cotton), which looks great and works very well. I'm not sure what the issues there about chemicals may be, but in any event it's a very hard to find cloth which unfortunately doesn't seem to be used much.


IOException on Deserializeling XML

Question: I am writing a small navigation app for Windows Mobile 6.1 (.NET CF 3.5), and I am getting IOException when I try to deserialize my data from file stream, and I cant understand why.
here is some of my code:
//That's the class I am trying to serialize / deserialize
 public class MapData
    {
        [XmlIgnore]
        public Bitmap EntireMapBitmap { get; set; }
        public string Date { get; set; }
        public string FileName { get; set; }
        public Route NavigationRoute { get; set; }
       //and some other unrelavant fields...
    }

here is the code to serialize:
string fileNameWithExtension = /*some calculation to get the full path*/
XmlSerializer serializer = new XmlSerializer(typeof(MapData));
TextWriter textWriter = new StreamWriter(fileNameWithExtension);
serializer.Serialize(textWriter, mapData);
textWriter.Close();

here is the code for deserialization:
 string fullPath = /*Retreive file's full path logic - working OK */;
 XmlSerializer deserializer = new XmlSerializer(typeof(MapData));
 FileStream fs = new FileStream(fullPath, FileMode.Open);
 mapData = null;
 mapData = (MapData)deserializer.Deserialize(fs);
 fs.Close();

I know thats a lot of details, but from my interrogation, the Exception only occurs when I am making a use with the NavigationRoute poroperty, so I will add those related classes also...
 public class Route
{
    public List<GeographicCoordinate> Coordinates { get; set; }

    public Route()
    {
        Coordinates = new List<GeographicCoordinate>();
    }
}

public class GeographicCoordinate
{
    public int LocationOnMap_X { get; private set; }
    public int LocationOnMap_Y { get; private set; }

    public GeographicCoordinate(Point onMap)
    {
        LocationOnMap_X = onMap.X;
        LocationOnMap_Y = onMap.Y;
    }
}

As I mentioned before, its only after I add one or more objects to the Coordinates list of the Route - I get the exception (which makes it even more awkward to me...). Another thing I tried to do it to remove the private setters from GeographicCoordinate class - but it was no good.
Thanks everyone :)
Comment: If you're getting an exception you don't understand, *always* specify what's in the content of the exception.
Comment: @ET, when you say remove the private setters, do you mean you removed the private keyword or you removed the setter entirely? XmaSerializer requires that both get/set are available and public.
Answer: You did not specify the actual exception, but I suspect that the problem is that your GeographicCoordinate.LocationOnMap_X and GeographicCoordinate.LocationOnMap_Y have private setters, you will need this to be public for XmlSerialization.

IOException on Deserializeling XML


Markov Decision Process model

Question: What does a deterministic Markov Decision Process (MDP) mean? Does it mean that the probability when going from one state to another is 1?
Answer: A Markov Decision Process is essentially a Markov Chain, where at every point in time, you make a decision that affects the next step in the process, i.e. the process uses a transition matrix that depends on your action for its next step.
A deterministic MDP is one where the decisions you make, given the current state, are deterministic, e.g. if you are in state $1$, you take action $A$, and action $B$ if you are in state $2$.
Compare this with stochastic MDP: if you are in state $1$, take action $A$ with probability $p$ and action $B$ with probability $1-p$, and if in state $2$, do $A$ w.p. $q$ and $B$ w.p. $1-q$ etc.
Answer: To add to the above answer of Ken Wei, you can visualize your deterministic MDP as follows:
From a practical computational perspective, when dealing with finite state MDPs, one has an array of same dimension transition matrices. Each of these matrices correspond to and action. Simulation-Based Optimization by Gosavi call this your TPM's.
So if actions are given as A = [a0,a1,a2,...an] then TPMs = [P0,P0,P2,...Pn].
So if you perform action a0 at state 0 (s0) in order to move to state 1 (s1) then you can access your probability as TPMs[0][0][1] = p. In a deterministic setting p = 1 and the entire rest of the row would be zero e.g. TPMs[0][0] = [0,1,0,...0]. This row is a probability distribution. So in a stochastic setting TPMs[0][0] = [0.1,0.7,0.1,....0] as an example.
What is the purpose of a deterministic MDP when you could just solve the Bellman equations recursively as is? Well, despite it being deterministic, you might still have some graph created by your Transition matrices and MDP setting can expose this. Plus, you can just plug the problem into some MDP solver if you would wish. You can even approach you problem as a shortest path problem. However, despite all this being said, MDP algorithms such as Policy Iteration do make assumptions which are critical such as boundedness of the value function and assumptions on transience and recurrence in the chain. So some deterministic chains might pose a problem if the chain is not irreducible. For deterministic problems I rather recommend solving the Bellman equations recursively.

Markov Decision Process model


How do I split up a list of data points into invervals and assign values to those intervals?

Question: So I have a data set for chess and our goal is to plot the difference between the rating difference versus white's win rate. I want to subdivide the x-axis into intervals like  (-10, 0) (10,20) (20,30) and read the data in the intervals and get the percent of white's win rate over that inverval. Our goal is to plot sort of like a step function for each of the intervals and eventually create a linear regression with the values of each interval.
Comment: Can you give some example data that people could work with? This would be helpful in terms of getting an answer. Also useful is to show what code you have already tried
Comment: Welcome to Mathematica.SE! I suggest the following:
1) As you receive help, try to give it too, by **answering questions** in your area of expertise.
2) Take the [tour] and check the [faqs](http://goo.gl/kQNRaS)!
3) When you see good questions and answers, vote them up by [clicking the gray triangles](http://tinyurl.com/ch98nrh), because the credibility of the system is based on the reputation gained by users sharing their knowledge.
Also, please remember to accept the answer, if any, that solves your problem, [by clicking the checkmark sign](http://tinyurl.com/4srwe2t)!
Answer: You can use WeightedData and Histogram as follows:
First some fake win/loss and rating difference data:
SeedRandom[1]
whiteWinLoss = RandomInteger[1, 200];
ratingdiff = Subtract @@ RandomInteger[100, {2, 200}];

(1) Construct a WeightedData object using whiteWinLoss as weights
wd = WeightedData[ratingdiff, whiteWinLoss];

(2) Use Histogram with bin width 10 and height spec "Probability":
Histogram[wd, {10}, "Probability"]


ARMA-GARCH, invertibility, stationarity and insignificance

Question:
I am trying to forecast volatility out-of-sample using ARCH, GARCH, GJR and EGARCH. I used AIC to identify the ARMA and ARCH order and decided to stick with (1,1) for GARCH-type models. However, I have situation where my mean equation is either insignificant and/or non-invertible and non-stationary. The insignificance does not worry me too much, but I think the non-invertibility/non-stationarity will affect my forecast results out-of-sample. Should I remove the mean equation in the models where this happens? If no then how would this affect my forecast results out-of-sample?
Comment: +1 because I find the idea of removing the mean equation to be thought provoking.
Answer: I agree that nonstationarity and noninvertibility are the two more serious concerns when it comes to forecasting. If you have a nonstationary process where nonstationarity is due to the level of the series (the unconditional expectation is undefined or changing over time), you will have trouble forecasting the level of the series.
Is that important when you are actually interested in forecasting volatility? Yes, it is. You either define volatility as the magnitude of deviations from the conditional mean (the level) or from zero. In both cases nonstationarity in mean will cause you trouble.

Should I remove the mean equation in the models where this happens?

Removing the mean equation will not solve the problem. In fact, you cannot remove the mean equation. A GARCH model specifies the conditional distribution of the time series, and that by definition specifies the conditional mean (unless it does not exist). In a GARCH(r,s) model for a time series $y_t$,
\begin{aligned}
y_t &= \mu_t + u_t, \\
u_t &= \sigma_t \varepsilon_t, \\
\sigma_t^2 &= \omega + \alpha_1 u_{t-1}^2 + \dotsc + \alpha_s u_{t-s}^2 + \beta_1 \sigma_{t-1}^2 + \dotsc + \beta_r \sigma_{t-r}^2. \\
\varepsilon_t &\sim i.i.d(0,1), \\
\end{aligned}
you have the element $\mu_t$. It can be zero, it can be something more complicated, but it is there, it cannot just be removed. And it specifies the conditional mean of the distribution of $y_t$, the latter being $y_t \sim D(\mu_t,\sigma_t^2)$. (It has to do with the properties of a random variable. Ignoring some property of a distribution, such as the mean, does not make it disappear.)
What I suggest is trying to see why the series appears to be nonstationary and address that (by adjusting for a deterministic or a stochastic trend, a structural change or the like). Then you will have a solid ground for your volatility forecasting.

If no then how would this affect my forecast results out-of-sample?

If the conditional mean model is well specified and estimated well (e.g. the true process is explosive like $y_t = 1.1 y_{t-1} + u_t$ and it is estimated as such), your forecasts of the conditional mean should be fine. On the other hand, if there is, say, a neglected structural change, then the model will be misspecified and the forecasts will likely be poor.
Comment: Thank you very much for your answer! I think I haven't expressed myself right. When I talk about the mean equation I talk about the ARIMA(3,3) which I estimated first. Basically I estimated an ARIMA(3,3) checked for ARCH effects and then estimated and ARIMA(3,3)+GARCH(1,1). Obviouslt I can drop the arima and estimate: $$ r_t = \mu +\varepsilon_t $$ and the GARCH. If I drop the ARIMA however I need to drop it from all models, right?
Comment: @Alex, You are welcome! Technically it does not matter whether you estimate the mean and variance equations simultaneously or stagewise -- the mean equation is implicitly there, even if it is just a constant. Now if you want to compare ARCH to GARCH, GJR-GARCH and EGARCH, it would make sense to have the same mean equation, thus also to "drop" it from all models rather than just one or two of them.


How to upgrade to specific release on Mac OS X (e.g. 10.7.3)?

Question: I have an old iPhone application which was created using Xcode 4.3.2. I want to get it running on Xcode. However, I am using OS X 10.9.5. So I get the error "This installation of Xcode 4.3.2 requires Mac OS X Lion". So I searched online and found an article about running Xcode 4.3.2 on VirtualBox. Now when I try to install Xcode 4.3.2 on Lion on VirtualBox, I get the error message "You have Mac OS X 10.7. The application requires Mac OS X 10.7.3 or later. How can I upgrade to 10.7.3 to get Xcode working?
Answer: If you start from a base install - 10.n.0 then you can always directly update to a given 'point release' by using the Combo Updater for that release.
These appear to always remain available from Apple.
The Combo updater for 10.7.3 is at https://support.apple.com/kb/DL1484
Answer: Simply use a so-called Combo Updater:
Download at least OS X Lion Update 10.7.3 (Client Combo). This will update your 10.7.0 installation to 10.7.3 and contains all other point releases in between (10.7.1.& 10.7.2).
Other Lion Combo Updates are available here: OS X Lion Combo Update search


Convert ProRes RAW to CinemaDNG or Blackmagic RAW

Question: I want to convert ProRes RAW files (.mov extension) to an open source format such as CinemaDNG or Blackmagic RAW.  Is it possible?  If so, how?
Answer: A Czech film maker, Nikolaj Pognerebko, has created a paid app (macOS version, Windows version) that will convert ProRes RAW to CinemaDNG for use in software such as Davinci Resolve.
Answer: I want to advice against converting to any RAW format, I don't even know if that's possible at all. A RAW format is usually driven by the needs of the camera hardware and fits the purpose of efficiently storing the video data while providing very high flexibility, often much more than non-RAW codecs do. That's why you usually cannot convert to such a format, you can only convert from a RAW format to something else.
Regarding CinemaDNG, there is this unofficial information on Adobe community forums (Source):

The CinemaDNG format was dropped due to licensing issues and disputes. And only a few cameras were built to use it to begin with, so sadly support for that format was never great and is now nearly non-existent.

That said, it is best to avoid CinemaDNG.
But what should you do now? If I understand you correctly you need a codec for video editing, but ProRes doesn't work for you. There are a number of other options that are suitable as an high-quality intermediate codec (which means a codec that is suitable for doing video editing). Examples are Cineform, DNxHR or DPX. As far as I know, only Cineform is fully open source. Here's a table with codecs and their supported frame sizes, bit-depths and a few other key information: link
In order to transcode the ProRes file to your target codec, you need a tool that supports reading the first and writing the second one. It may be a little difficult to find something that can read ProRes RAW if you're on Windows, but you can install Apple's ProRes RAW. Beware, due to Apple's restrictive licensing politics, only the Adobe products listed there are officially supported on Windows. Other tools may be able to read the format too, but there is no guarantee that they correctly interpret the files. Which means, you should use Media Encoder or Premiere Pro to transcode the format to something else. In Premiere you can go to project settings-> ingest settings and choose another format. If you're unhappy with the choices add your own ingest preset. I have not yet worked with ProRes RAW in Premiere or Media Encoder on Windows, so I can't tell you if everything works well. But you can use a trial version of Premiere Pro or Media Encoder and test if this works for you. Also, Premiere Rush is supported too, but I've got no experience with that whatsoever.
On a Mac you can use Final Cut Pro, Motion, or Compressor to export ProResRAW to something else (see bottom of this article).
Comment: The quote about CinemaDNG licensing disputes makes no sense. First, the author is not Adobe staff. Second, CinemaDNG is an open format not encumbered by licensing. Third, Adobe themselves created CinemaDNG. Finally, Adobe themselves say it was removed because of performance ([src](https://web.archive.org/web/20121002233930/https://blogs.adobe.com/toddkopriva/2012/09/cinemadng-in-after-effects-cs6-and-elsewhere.html)).
Comment: Thank you that is very helpful. I do not have a Apple computer but i have tried   Premiere Pro; after installing ProRes RAW I  can read in a ProRes RAW file  and export to Cineform, but it does not seem to be the CFA Bayer format.  If you know any way I couild get that, please let me know.
Comment: I'm sorry, I don't know how to help you with the bayer filter.
Comment: @AndrewMarshall thanks for pointing that out. The person had a different title back then, because Adobe only introduced the "Community Expert" program in 2022, and  it looked like he was staff back then. Maybe he even was for some time. I don't know.
Answer: Note: Blackmagic RAW is not open source, there is no public source code available. They have a binary library/API which allows for decoding Blackmagic RAW in a host application.
Blackmagic RAW and ProRes RAW are both closed source codecs which provide video frames to the host application in a demosaic'd format - therefore neither of them can output something that can be re-encoded as RAW.
Very few RAW formats provide the ability to decode the data in such a way (mosaic's in camera raw space) that can then be used as in the input to another RAW format. CinemaDNG is the only format which can do this due to being open source. There was once a tool that could read CinemaDNG and convert it to CineForm RAW (Both are open source so this could still exist)
Regarding CinemaDNG, it is a mature and well supported format (Adobe Premiere, Apple Compressor, DaVinci Resolve) and the only fully implemented true open source RAW format. It is also the only RAW video format which can be lossless.


Why did Cameron try to Kill John?

Question: In Terminator: The Sarah Connor Chronicles, 1st season last episode, when Cameron is starting the jeep, it blasts. Then she tries to kill John Connor. So my question is, why is this? Is it because her software or hardware malfunctioned?
Answer: From what I remember, it was her original programming to kill him and the explosion must have reset her to factory settings (F*#k you Apple).
From my knowledge of real-world electronics, I suppose it's possible that the explosion could have corrupted a hard drive or part of a hard drive and that forced the CPU to boot in safe mode which would would boot with default settings, AKA kill John Connor.
Going back to normal may have been because her CPU found a backup of the hard drive that was corrupted. (Always backup your stuff!) However, computers in the real world are able to find and load backups in seconds not hours. Although it depends how much data she is storing.
So to answer your question, it's kinda both a software and hardware problem.
Comment: "However, computers in the real world are able to find and load backups in seconds not hours." If it was doing something like filesystem repair / error correction, it would've taken a while; in the meantime, if there was an available copy of the original programming, it would make sense to use that rather than sit around idle.

Why did Cameron try to Kill John?


What is the origin of alpha in the mediopassive indicative?

Question: In greek, the indicative mediopassive in the 3rd person singular and plural are -εται and -ονται, however in PIE, the alpha was originally an o. Additionally, in the imperfect, the endings also have o in them. Why did this shift to alpha, since it seems like an omicron and iota seems phonologically legal in greek, such as in the masculine plural article οἱ.
Comment: I'll consult Willi's *Origins of the Greek Verb* later when I get a chance. If you can get your hands on it it's an excellent read on the PIE verbal system through the lens of Greek
Comment: Greek takes a capital g, We should make an effort...
Comment: Thanks for the suggestion, I'll try to look at it.
Answer: Willi's Origins of the Greek Verb argues that it's by analogy from the 1sg, 2sg (from PIE *(m)h₂ei̯ & *soi̯/-sai̯), noting Arcado-Cypriot and Myceanaen forms in -τοι:

In Greek *-toi̯ > -τοι is attested in Arcado-Cyprian and Mycenaean; -ται is analogical after the 1sg./2sg.

Note that Willi does not assume the 1sg & 2sg directly continue the PIE middles, but instead consist of the h₂e-conjugation (stative) endings appended to the active athematic ones (-mi conjugation), and then followed by the primary -i in the present tense.

These are badsed on a combination of endings from both series/conjugations. ... the ending *-o acquired a mediopassive value and could be added to the 3sg. ending *-t of the m-conjugation form new 'oppositional' middles...
... Since Vedic 'primary' 2sg. med. -se can continue either *-sai or *-soi, a late-PIE 'primary' *-s-t(h₂)a-i̯ may have been 'regularised' after active *-si into *-sai̯ (> Ved. -se), while the vocalism of only 'secondary' *-s-th2e > *-s-t(h₂)a > 'regularised' *-sa was aligned with that of 3sg. *-to. This would imply that Proto-Grreek possessed a 'primary' middle series 1sg. *-mai̯ (cf below), 2sg. *-sai̯, 3sg. *-toi̯ vs 'secondary' *-mā(m) (cf.below), *-so, *-to, and it would thus account for the general a-vocalism of the 'primary', but not 'secondary', middle endings of most historical dialects (Att. -μαι, -σαι, -ται vs. -μην, -σο, -το).
[footnotes ommitted]

This does require two analogies (one for 2sg. *-st- > *-s-, and another for 3sg. *-oi̯ > *-ai̯).
The ablaut of the PIE middle is not consistently reconstructed (Sihler & Beekes reconstruct o-grade, whilst Fortson & Ringe reconstruct e-grade). An o-grade explains the lack of a-vocalism in the secondary middle (i.e. imperfect & aorist middles) but makes the a-grade in the primary middle (i.e. present middle) problematic, whilst the e-grade is exactly reversed (explaining the a-vocalism of the primary, but not the lack of it in the secondary middle). Willi's explanation using concatenation of the stative and active (athematic) endings explains both.


Add "C" wire to NEST

Question: I have a NEST thermostat. My heating and cooling system is in the attic.I need to add a "C" wire to the control board, but I can't find out where I need to open the unit in the attic to see where the existing thermostat wires run from my hallway thermostat to the attic?
Answer: Sometimes air handlers/furnaces have lift off covers that allow you to access the wires, but often you will have to remove some screws or cut some duct tape (if the install was messy) to remove the proper panel.  Pictures help here, but you want to look for any covers or panels that will slide or lift out of place.
If you find one, open it and see whats inside.  If it only provides access to the blower or the heater portion of the unit and not the control board, you will most likely have to remove a few screws to remove another panel (panel can be large, like the whole half of the unit).
Again, this is general advice, but I think that many people might not think they need to start pulling out sheet metal screws and expect a pop-open panel.  If you're not sure, post some pictures.  I wouldn't want you taking apart the wrong thing!
Comment: Thanks so much for replying. I will take some pictures tonight when I get home. There are 2 (large) panels on the side of the unit with screws I removed all of the screws on both panels. The one panel I was able to remove only shows the copper coils and no circuit board. The other panel has some black press-on adhesive that is very strong and holding the panel in place. When I tried to pry it apart the panel actually started to bend or crimp, so I stopped. I thought the black adhesive was a sign that the panel was not intended to be removed.That's why I decided to write and ask for some advice
Comment: That adhesive _could_ have been an overzealous sealing attempt by the installer, but pictures would help.  Don't force anything open - there's a chance it's not a panel that should be removed.
Comment: Additionally, if you can find a make and model number, do a google search for that + "Owner's manual." You'll probably get a searchable document, and you may be able to find the OEM's documentation on where the control board is.

Add "C" wire to NEST


Recommendation to learn css

Question: How would you recommend to proceed to learn css?
Is there a great book, or online tutorial?
Answer: this is the best repository i know
css 101
and some thing that bother most of us is floating
as far as books are concern i love "Eric Meyer" way of doing stuff, but some other worth mentioning books i read

CSS Cookbook by Christopher Schmitt
Core CSS by Keith Schengili-Roberts

hope that will help you getting startted
cheers
Answer: These are some online tutorials that might help you a lot:

W3Schools
CSS Tricks

More web-based tutorials that aid you in learning CSS.

456 Berea Street CSS Category.
W3C CSS Tutorials and e-Books
A List Apart CSS Category
Answer: I like Stylin' with CSS, and SAMS's Teach Yourself HTML & CSS in 24 Hours is also good.
I did take a CSS course, but they taught out of the Lynda books.
Answer: I am a big fan of CSS: The Missing Manual. It allows you to either start from the beginning and read through to the end, or open the index and answer specific questions on what you're doing.
The best way to learn anything is to do it. Make some web pages with bad CSS ("Why is my text always falling off the side?!?") and then look up the solutions (I like the W3Schools pages a lot, too). There's nothing like working through some bad CSS to give you confidence in working with CSS.
I also agree with the sketchbook - I keep one at home and one at the office. If you know what you want your page to "look like" it will become much easier to write CSS that matches your layout.
Answer: also, try CSS3: Visual QuickStart Guide (5th Edition)

Recommendation to learn css


What tools do you use to monitor a web service?

Question: From basic things likes page views per second to more advanced stuff like cpu or memory usage. Any ideas?
Answer: I think someone has asked the same type of question before here?  Though I'm not too sure how helpful it is.
For CPU usage, etc, I would try RRDTool, or maybe something like Cacti.
Answer: Web service or web site?  Since you mention page views: I believe you mean web site.
Google Analytics will probably give you everything you need to track usage statistics and best of all is free under most circumstances.
You might also want to monitor site up-time and have something to send email alerts if the site is down for some reason. We've used Nagios in the past and it works just fine.
Answer: I've been using monit (http://www.tildeslash.com/monit/) for years. It monitors CPU and memory usage as well as downtime for apache/mysql/etc... you can also configure it to notify you of outages and automatically restart services in real time.
I also use munin for reporting: http://munin.projects.linpro.no/
If you want reports on pageviews and whatnot, AWStats is the best I've used.
Answer: I use Nagios for general machine monitoring on Linux and I pretty much rely on Google Analytics for website reporting - I know that's not for everyone since some folks have privacy concerns about giving all their site data to Google.
Both are free and easy to install (Nagios is generally available through apt-get and Analytics is a pretty easy install on a site).
Nagios, however, can be a bear to configure.
Answer: I cast my vote for monit as well.   The nice thing about is that it understands apache-status info and can notify/take actions when say 80% of max num of apache workers are in "busy" state.
but you need something else for hardware and general monitoring, something SNMP-aware, like zennos or zabbix
Answer: Munin and Cacti provide very nice interfaces and pre-built scripts for rrdtool. They can also monitor multiple servers and send out warnings and alerts through naigos.


https://login.salesforce.com/id/keys is returning random results

Question: I build a third-party application that integrates with Salesforce using the REST API (connected app). We hit /services/oauth2/token to get a token for the user, then we verify the token using the associated RSA key from https://login.salesforce.com/id/keys. Here's the problem. In the past two months, we've started to get intermittent failures. You'll notice if you go to https://login.salesforce.com/id/keys and then refresh the page a couple times, you get random responses. You can tell by looking at the "kid" fields in the JSON. Often "kid": "222" is not present, for instance.
Is this expected from this endpoint? I would assume not seeing as we only started getting errors from this in the past two months when we've had this integration for a couple years.
I've also noticed that hitting the /id/keys endpoint from an org-specific domain like https://na49.lightning.force.com/id/keys always returns a consistent result, but never includes "kid": "228" like https://login.salesforce.com/id/keys sometimes does.
So is it safe to use the org-specific domain since it's consistent? Or does my server need to handle the inconsistency in order to support "kid": "228"?
Answer: There's a chain of custody you have to follow when retrieving the public key: the iss (Issuer) of the id_token you're trying to verify determines the location of the keys. By default, the issuer will be login.salesforce.com for a production org but (for example) a community hosted in the same org will have a different issuer.
If the id_token issued by SF does not have a corresponding public key in the JSON Web Key Set (JWKS), then you can't validate the signature on the token and therefore cannot rely on this token. (Correspondence is established via kid). As far as your client acting in the capacity of OpenID Connect Relying Party is concerned, when token validation fails not using this token is your only app-level, programmatic recourse.
You could complain to Salesforce that you can't validate id_token due to a missing key. We haven't seen such a scenario but if you have evidence of this, please let Salesforce know by opening a support case.


What is the best way to validate the following data?

Question: Lets say I receive an xml request that is sent to my web service and this request contains some data in it such as Hotel Room/Rate pairs (Room = Double Queen, Rate = 10%).  The database has all of these Room/Rate pairs stored, so when the xml request comes in, I have to validate them to see if the request contains both the room and the rate in the database.  If I receive one room/rate pair and it is not in the database, I fail the message and send back an error response, but if I receive 3 room/rate pairs for example, and 2 are found in the database, but one is not, I would process the succussfull ones and send back warnings for the ones that were not found.  The other scenario is if I receive 3 room/rate pair and they all are not found in the database, then I want to send back an error message.  What is the best way to approach these scenarios?
Answer: My opinion is that you should be consistent and always follow the same path regardless of the number of data you have in the request. That way the client of your application knows what to expect. As such, being consistent leaves you only with two choices:

strict: you are very strict and nothing goes through if you have one error (like, this is a transaction). You stop at the first error and return the response explaining where you find the first error.
permissive: The valid rooms are successfully updated. For each room you don't have in your database, you generate a warning and continue. The response will contain a warning for each problematic data.

From what I understand it does not seem you require your request to be transactional (everything passes, or nothing) so my guess is that you may be "permissive". The client should check the warnings and do whatever it can to do better next time.
There is also a third choice, but I don't know if you can implement that into your business domain: why not "create" the missing rooms in the database if you don't have them ?
Comment: The rooms are created already, but if the client happens to send room="abc" when it should have been room="abc1", then we have to either send back an error basically saying the whole message failed if that was the only one or if there is more than one room and some passed and some failed, for the failed ones, they are warning and for the ones that didn't fail, they are processed successfully.  Some clients want to fail everything if one room fails and some clients want to only send warning for failed rooms, but process the successful ones.  In this case, the client wants to do the latter.
Comment: As you pointed out, permissive is the way I am going with this client.  The client does try to ensure that valid data is passed through, but as you know it can't be perfect.  I can't create a room in a database if it doesn't exist because then I might be creating a hotel room for a hotel that they don't even have at their hotel.
Comment: OK, the client can decide on that matter. Well then you could be consistent *with the choice of the client* :-) For example, in addition to the room data he sends a status indicating whether he wants a "transaction mode" or an "atomic mode". Depending on that status you follow either the strict or permissive path. What do you think ?
Comment: I agree with what you are saying, but I don't have any say in this.  The way the client sends the data has already been decided.  By "way", I mean the format of the messages and how they are sent have been established by the client already and they are not going to change.  I just have to know how to process them in code.
Comment: Alright, then yes you are very limited in your choices, and it seems that your only job when you detect an invalid room is to provide a meaningful error message.
Answer: What you probably want to do is to incorporate success/failure in for each request in your response. So, in your example, the user would receive a response saying that the first 2 are successful and the final one failed. Bonus points for including why it failed.
Comment: +1: XML request is a "document".  The document is either valid or not valid.  One invalid thing makes the document -- as a whole -- invalid.  A good error message provides details.  A bad error message summarizes.
Comment: @S.Lott, the xml document itself is not invalid, the data is invalid.   is completely valid xml, but the the Room Id could be "abd" instead of "abc" which would make the data invalid.
Comment: @Xaisoft.  The request -- represented in a document -- is invalid.  The request -- as a whole -- represented in a whole document -- is invalid as a whole.  The point is the "wholeness" of it.  The point is that XML requests can't be subdivided because it is one document.  All or nothing.
Comment: @S.Lott, we have some clients who take the approach of All or Nothing, meaning that if one room/rate pair is invalid, do not process anything, but we have some clients who say, if 1 room/rate is invalid, but 3 are valid, process the valid ones, but send back warning message indicating which ones were invalid along with a success message for the ones that were valid.
Comment: (1) If you have two conflicting requirements, then don't ask which is "best".  (2) This answer says which is best.  If some of your clients don't like that, then they don't like what's best.  (3) If you want a magical answer that resolves your conflicting requirements, please fix the question to say that you have conflicting requirements and want a magical answer.  This answer says which approach is best.  It's a good answer, even if you have clients that have bad requirements.


Paper with multiple authors

Question: If I have a question about a paper which has multiple authors, who should I email? The professor whose lab the paper came out of maybe? The first author named on the paper?
Comment: The one whose e-mail adress is given in the paper.
Comment: If one of the authors has a footnote marking them as "corresponding author" -- then that one. Otherwise, any of them.
Answer: If I understand it correctly, you're a reader of the paper and want to contact the author(s)?

In most journals, one author is marked the corresponding author (and their email address is provided more prominently. It's a good first port of call, and the right thing to do on recent papers.
Otherwise, depending on the field, the first author is likely to be the principal author and most able to speak to the entire article.
If the paper is very old of course, you might have to do some research of your own to find out who is still active and which email address is still valid. In this case, if you can't find the first author's (who may have been a junior researcher and moved on) it might be ok to inquire with the lab director.
If you have all email addresses, you might want to send it to all three. Three is not that many addressees. Five or more would be different - you don't want to send a mass mail.

Also, the content of your letter would be slightly different based on which option you choose. You didn't tell us why you want to email them. (If it is to get a copy, first author is probably the one who is maintaining a personal file.)
Comment: If the paper has two or three authors, I'd send one single email to all three. If it's more than that I'd be more selective - and also, it is likely that some authors were just very peripherally involved. So I'd make ONE email, but go through the list and look them up: "First author = corresponding author - include; second author is now a researcher/faculty at OTHER INSTITUTION - include with new address; third author - can't find any more in the original institution - leave out; fourth author - now a mid-career academic: include; last author - lab director: include, but don't expect much"
Comment: Don't overthink it! People are happy to talk about their work. And if they aren't they'll just ignore your message.
Comment: In your 4th option - should one send separate individual e-mails, or is sending an e-mail addressing e.g. both authors also legitimate or even better (so they know you approached both of them)?
Answer: It probably doesn't make a huge difference, but your two suggestions are fine. The one you correspond with may pass on your query to one of the others if that is appropriate. The first author may mean something or not, depending on the field. The one whose lab it came out of may know a lot about the specific paper or not, again depending on the field and how the lab works.

Paper with multiple authors


Create OpenOffice ODT document RUBY

Question: I am looking for a Ruby Gem that will allow me to create openoffice odt documents from scratch. There is also a requirement to include images in said documents. Has anyone come across a gem offering this functionality. I have not been able to find any that will facilitate the creation of new documents (replacing text in a template doc is pretty straight forward).
Regards and many thanks in advance
Answer: There is serenity-odt listed on Rubygems or this post that describes some work similar to what you describe.

Create OpenOffice ODT document RUBY


"He gets angry when (he is) trying to explain the issue." Why is it okay to remove the "he is" part?

Question: I saw this structure in a few texts, and it made me wonder what is the grammar role of when in this sentence and why the subject and verb (he is) are absent. It doesn't fit any grammar structure that I know in English. I guess the part after when is an adjective clause but I'm in doubt since the clause lacks the subject and verb.
Answer: Because it is common in English to omit certain words from certain subordinate clauses when they can easily be inferred. This is called ellipsis.
It can sometimes lead to ambiguity, but here the omitted subject can only refer to the subject of the main clause, "he," as there is no noun or other pronoun to refer to. If a different subject were intended, ellipsis would not be permissible.

He gets angry when I am trying to explain this.
Answer: He is can be omitted because it isn't necessary. Reading the sentence, you know who is trying to explain the issue: he is!
When... functions as an adverb clause, because it modifies the verb phrase gets angry -- it is saying when he gets angry.
When: https://www.ahdictionary.com/word/search.html?q=when


Are you allowed to get married the night going into Shiva Asar B'Tamuz?

Question: Are you allowed to get married the night going into Shiva Asar B'Tamuz? If you have the Chupa prior to Shekiya can the wedding continue past sunset? (Sources please)
Comment: Shut Harav Harashi #55
Answer: Rabbi Moshe Feinstein says yes, "if needed". (I.e. there's a legitimate reason why you couldn't do the wedding a day or two earlier.)
His cousin-once-removed, Rabbi Joseph Dov Soloveichik, said no.
Rabbi Soloveichik's argument: "if the Talmud debated whether the fast starts at night, and some later rabbis thought you start saying the fast-day prayers at night, that means that elements of the fast really start at night."
Rabbi Feinstein's argument (OC I:168): "the Talmud concludes that the fast doesn't start at night; yes it was later debated about saying the prayers at night, but we conclude that the fast-day prayers don't start until day; that opinion has stronger Talmudic support; and the whole no-three-weeks-wedding thing is a custom, so we should be lenient in cases of doubt."
Hat tip Joseph Kaplan and others.
Comment: Some more information from yesterday's "Halacha Yomis," by the OU: https://web.archive.org/web/20170711190242/https://oukosher.org/halacha-yomis/
Answer: On the surface level, yes, but more importantly is whether one should.  The three weeks are a rather auspicious time and over the centuries Jews have tried to prevent taking on major activities during that time.  My recommendation would be to hold off until after 9th of Av, the 15th is especially an auspicious day to get married.  There are also questions of sheva brachos during the three weeks, one can have them, but again, the mood is not ideal and has certain overtones.  Its probably ideal to delay if possible, otherwise, its not asur.
Comment: "On the surface level, yes": Do you have a source for this?
Comment: @msh210, why do you necessarily assume that something must be forbidden?
Comment: @Adam, I don't assume things are forbidden with no basis. In this case, though, there's a widespread practice that we don't marry in the three weeks, and night generally counts as part of the next day in Judaism.
Comment: @AdamMosheh He doesn't necessarily assume that. He just wants to know if the OP has a source in Judaism for his claims or is just sharing his personal whims and feelings.
Answer: From Halachically Speaking (Vol 6, Issue 8), "The Three Weeks":

There is a discussion among the poskim if one has to refrain from the actions which are
  not done during the three weeks from the morning of Shiva Asar B'tamuz or even the night
  before? Most poskim say that one should refrain from doing these activities even from
  the night before, from tzeis. In a pressing situation one can be lenient (i.e. wedding on
  Motzei Shabbos).11
From Footnote 11: "...This is even with music etc (See Igros Moshe E.H. 1:97)

And:

The custom of Ashkenazim is to refrain from making weddings from the night of
  Shiva Asar B'tamuz until after Tisha B'av. This is even if one has not fulfilled the mitzvah of having children.
Answer: There was a big fight over this in Israel, I believe during the 70's / 80's.  The chief rabbinate was dominated by Ashkenazim and they forbade weddings during the three weeks.  One of the many things Rav. Ovadia Yosef is known for was his fight for Sephardi traditions, one of which is that weddings are allowed during the three weeks:
Rabbi Ovadia Yosef ZT"L Rabbinical Authority

As a leading Sephardic Torah scholar and arbiter of halakha, Rabbi
  Yosef was often described by his followers as the greatest of the
  generation and the outstanding Sephardic rabbinical authority of the
  century. His most outstanding quality was his courage to proudly renew
  the Sephardic system of legislation. Time and again he disagreed,
  openly and proudly, with the official position of the rabbanut, while
  sticking to his religious Sephardic position. Thus, for example, when
  he was the Chief Rabbi of Tel Aviv, he cancelled the religious
  council's decision not to permit marriage in the Ben Hametzarim (three
  weeks) days—as the Ashkenazim do—and instructed all the marriage
  registrars in his jurisdiction to allow marriage of Sephardic Jews for
  the whole month of Tamuz.


Which method to use for granting sudo

Question: What is the difference between adding a user to /etc/sudoers and usermod -a -G sudo?
Which method should be used for granting sudo?
Comment: For Ubuntu you should very strongly avoid editing the `/etc/sudoers` under any conditions.  Instead add config fragments into the `/etc/sudoers.d` directory.  Using the fragments folder makes upgrading easier since you modified a conffile.
Comment: @EEAA, I grant you permission to use the above, and anyother comments I post to merge into actual answers.  I add comments because I am too lazy/busy to add a full answer, but I don't mind at if people take my comments and integrate them into a complete good answer.
Comment: @Zoredache - excellent point. Do you care if I add that to my answer? I don't want to take credit for it, but this tip should live in an answer somewhere in case the comment gods nuke this for some reason.
Answer: If you can avoid it, never grant sudo privileges to individual users. Always grant privilegs to a group and then add users to that group.
For ubuntu-based servers, instead of adding lines to /etc/sudoers, add config file fragments into /etc/sudoers.d. This is more flexible, easier to understand, more resilient in the face of upgrades, and works better with systems managed by configuration management systems.
NOTE: never edit /etc/sudoers directly. Instead, use visudo, which will perform syntax checking on your edits, preventing you from breaking your sudo config with invalid syntax.
Comment: @FlakDiNenno - right, that is exactly what I suggested.
Comment: why not add the group to `/etc/sudoers`?
Comment: ahhh... I thought you were referring to the `usermod -a -G sudo`
Comment: +1 for the warning about using visudo instead of direct edit
Comment: Good point about ``visudo``. Some people don't realize there's a reason that ``/etc/sudoers`` is marked as read-only.
Answer: I just found this little tidbit out there... seems you need to be particularly careful with using the -G option in Ubuntu, in particular in combination -g option.  So:

Use usermod -aG to add the user(s) to a group.
Then as @EEAA suggested, add the group to the /etc/sudoers file using the $ sudovisudo command (automatically invokes a privileged editor with syntax checking).

Here's the info about the -aG option on Ubuntu, taken from here http://ubuntuforums.org/showthread.php?t=1240477:

'I'm reading the Wiley "Linux Command Line and Scripting Bible" - and they said that usermod -G "appends" a group to whatever user account you are modifying. I found this to be false in Ubuntu, don't know if it's just different in other distro's, or a typo in the book. It removes you from EVERY other group you belong to, except your default user group (modified by the -g option). I managed to remove myself from the admin group and could no longer sudo anything. Thank goodness for recovery mode...'
The correct option is usermod -aG. Lesson learned...
Comment: can the downvoter have the courtesy to provide some constructive criticism here.  tia.
Comment: I didn't downvote you, but your 'answer', doesn't really answer the question asked.  This is a pretty strict Q&A site, we generally expect answers to directly address the question asked.  BTW, yes I know you somewhat address the question a bit, but your 'answer' seems most saying do what EEAA said, but be warned about this weird quirk.
Comment: @Zoredache thanks for taking the time.  Doesn't step 1 & 2 clearly give instructions for "a preferred method for granting sudo"? Which is what the OP asked?
Answer: You don't tell us how big your environment is, but if it's more than one machine you may also want to consider configuring sudo using LDAP s an alternative to editing sudoers locally (either through visudo or using the /etc/sudoers.d fragments method).
LDAP configuration is a well-tested way of making sure that multiple machines have the same sudo configuration, and presents a nice unified environment (with central management of an important authorization mechanism).  As a bonus if you already use LDAP (or AD) for authentication/authorization in your environment you can take advantage of the existing infrastructure (and if you don't you should seriously consider it - centralization has many benefits).
Everything folks have already said in the other answers about creating authorized groups still stands - it's easier as you scale up to grant privileges to a group and manage group membership than it is to deal with managing rights for individual users.

Which method to use for granting sudo


What is the etymology of "anarchy"?

Question: I understand the word "anarchy" to mean "without a political leader" rather than "no rules". Consequently, it would seem that "anarchy" has roots in "an-" and "hierarchy". Is this correct, and would someone provide more detail?
Comment: @MattЭллен: I agree that Etymonline is a good place to start, but I don't think that a listing there should be an automatic reason to vote to close a question here. Granted, this question is pretty narrow, but _etymology_ can encompass much more than where a word comes from. Doug at Etymonline has an interesting note about the Greek calendar, but I'm sure much more could be said about the history of this word. Doug frequently updates his entries at Etymonline based on answers from this site.
Comment: Have you checked [etymonline](http://www.etymonline.com/index.php?term=anarchy)?
Comment: I agree. Their etymologies don't go back to Proto-Indo-European, for instance, which makes a lot of links clearer. Watkins' _American Heritage Dictionary of PIE Roots_ is much more thorough, especially when used in conjunction with Buck's _Dictionary of Selected Synonyms in the Principal Indo-European Languages_.
Comment: @MattЭллен Didn't know it existed - thanks for the link
Comment: @GaryRowe: Editing your question to include queries on the word's use through time and its alternate meanings may prevent this question from being closed.
Answer: Technically, you are correct, but it is the implications that are important. If there is "rule by no-one", then there are, by definition, no rules, because there is no-one to make any rules. If I refuse to accept that anyone has a right to impose any rules on me, I am free to do what I like, and what I want.
As with other similar words, the precise meaning has been expanded to include the implications of the meaning, which is reasonable, as it them becomes a shortcut for "the results of an anarchic system".
Consider, as a similar case, the word "democracy", which technically means the rule of the people, but has been expanded to mean the election of rulers by all of the people. It is a different thing, but it is the outworking of a practical system of democracy*
*possibly. That is a discussion for somewhere else.
Comment: @GaryRowe Technically, that would be rule by consensus, I reckon. The differences are very subtle though.
Comment: +1 for the useful discussion. Completely off topic, I would take issue with the assertion  that "rule by no-one" implies "no rules" since a co-operative group can arrive at a concensus of rules without a single party having control. But that is a discussion for somewhere else.
Answer: Medieval Latin anarchia, from Greek, from anarchos having no ruler, from an- + archos ruler
First Known Use: 1539
From: http://www.merriam-webster.com/dictionary/anarchy
Comment: Roger.  Yeah, that's pretty dumb.  I thought it was referring to the arch- prefix in general.  Odd.
Comment: +1 for the quote, but you might want to edit out the "arch-" part which has no bearing on the question
Comment: I think that's referring to the greek archo to rule or command.  Like anarchy, oligarchy, matriarchy, and monarchy.  The arch- prefix refers to a chief or the first in an order.
Comment: What I mean is that merriam-webster provide the "more at arch-" link which goes here: http://www.merriam-webster.com/dictionary/arch- and has nothing to do with the subject (it's about arches).

What is the etymology of "anarchy"?


Fantasy manga where MC can raise undead, and was abandoned by the hero party

Question: The story is about a kid who has undead-raising skills and was abandoned by the hero party. He was then scouted by a demon lord succubus.....I think it was a succubus, but I'm not sure.
Comment: Hi, welcome to SF&F.  Where and when did you read this?  Do you remember any details of the appearance of the main character?
Comment: i already found the manga the guy below me had given the answer it is The Rise of the Imemployed Wise Man
Answer: The Rise of the Unemployed Wise Man

When a young Farm Boy named Karna turns thirteen, he's officially recognized as an adult and undergoes the Revelation ceremony to receive a title from Heaven's Gods to determine his lot in life. To his surprise, he's given the title of "Wise Man" along with the "Necromancy" skill, granting him incredible magical power. Elated by this discovery, Karna immediately decides to put his new talents to work by becoming an adventurer to earn money for his ailing grandparents. Things couldn't get better when he's scouted to join the party of the Hero himself, which comes with a lucrative salary.
But after his first month on the job, his gross yet powerful abilities get him kicked out of the party with no money to show for it. Forced to become a solo adventurer, Karna then stumbles upon the lair of the Demon Lord of Lust, Cecilia Israfilia. After watching him easily defeat one of her strongest generals, she offers him a job rather than retribution. And so the boy who should have been a hero to humanity turns against it for the sake of earning money for his family. The rising of the formerly unemployed Wise Man begins!

Found with a search for manga necromancer succubus
Comment: thank you my friend i have been trying to find it for 2 days now XD
Comment: Jesus these Anime titles are getting worse every day.
Comment: @gamerGypps: They're kind of hearkening back to Victorian titles: "Gerald Bates: A tale wherein a boy becomes a man and loses a fortune, and then gains the world" :-D


Second MPI_Send is hanging if buffer size is over 256

Question: int n, j, i, i2, i3, rank, size,  rowChunk,  **cells, **cellChunk;

MPI_Status status;

MPI_Init(&argc, &argv);
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
MPI_Comm_size(MPI_COMM_WORLD, &size);

if(!rank){
    printf("\nEnter board size:\n");
    fflush(stdout);
    scanf("%d", &n);

    printf("\nEnter the total iterations to play:\n");
    fflush(stdout);
    scanf("%d", &j);

    srand(3);

    rowChunk = n/size; //how many rows each process will get

    for(i=1; i<size; i++){

        MPI_Send(&n,1, MPI_INT, i, 0, MPI_COMM_WORLD);
        MPI_Send(&j,1, MPI_INT, i, 7, MPI_COMM_WORLD);
    }

    cells = (int**) malloc(n*sizeof(int*));    //create main 2D array

    for(i=0; i<n; i++){

        cells[i] = (int*) malloc(n*sizeof(int));
    }

    for(i=0; i<n; i++){
        for(i2=0; i2<n; i2++){           //fill array with random data

            cells[i][i2] = rand() % 2;
        }
    }

    for(i=1; i<size; i++){        //send blocks of rows to each process
        for(i2=0; i2<rowChunk; i2++){ //this works for all n

            MPI_Send(cells[i2+(rowChunk*i)], n, MPI_INT, i, i2, MPI_COMM_WORLD);
        }
    }

    cellChunk = (int**) malloc(rowChunk*sizeof(int*));

    for(i=0; i<rowChunk; i++){    //declare 2D array for process zero's array chunk

        cellChunk[i] = (int*) malloc(n*sizeof(int));
    }

    for(i=0; i<rowChunk; i++){   //give process zero it's proper chunk of the array
        for(i2=0; i2<n; i2++){

            cellChunk[i][i2] = cells[i][i2];
        }
    }

    for(i3=1; i3<=j; i3++){

        MPI_Send(cellChunk[0], n, MPI_INT, size-1,1,MPI_COMM_WORLD); //Hangs here if n >256
        MPI_Send(cellChunk[rowChunk-1], n, MPI_INT, 1,2,MPI_COMM_WORLD); //also hangs if n > 256

            ... //Leaving out code that works

This code works perfectly if n (array size) is less than or equal to 256. Any greater, and it hangs on the first MPI_Send. Also, when sending out the array row chunks to the other processes, (first MPI_Send) the other processes receive their data perfectly, even though n > 256. What would cause just this MPI_Send to hang if the buffer size is over 256?
Comment: Can you post the full code? I dont see any problems with the snippet you posted.
Answer: You are never receiving any messages, and so the code will fill the local MPI buffer space and then deadlock waiting for an MPI_Recv (or similar) call to be run.  You will need to insert receive operations so that your messages will actually be sent and processed on the receivers.
Comment: The code is incomplete. MPI_Send is called only by the root. He left out the rest of the code as you can see in the last line. You may want to rephrase your answer.
Answer: MPI_Send is a blocking call.  The standard mandates that MPI_Send can return control as early as the message buffer can be safely modified.  Alternatively, the MPI_Send can wait to return until some time AFTER the MPI_Recv has started or completed.
The implementation of MPI you are using is likely doing an "eager" message progression if the message is <256 count (With an MPI_INT datatype, this would be a 1k message).  The message is copied into another buffer and control is returned "early."  For large(r) messages, the MPI_Send call does not return until (at least) the matching MPI_Recv call is executed.
If you post a complete reproducer, you will likely get a better answer.
Answer: MPI_Send "may block until the message is received.", so it is most likely that the matching receive is not reached. You need to make sure the MPI_Recvs are placed in the right order. Since you did not post your receive part, it is impossible to tell the details.
You could restructure your application, to make sure the matching receives are in order. It also might be convenient for you to use the combined MPI_Sendrecv or the nonblocking MPI_Isend, MPI_Irecv and MPI_Wait.