Invariants of exterior powers

Question: Let $\mathfrak{g}$ be the Lie algebra of $GL(n,\mathbb{R})$. Let $\theta(X) = - X^T$ be the Cartan involution on $\mathfrak{g}$; it induces decomposition as $\mathfrak{g} = \mathfrak{k} \oplus \mathfrak{p}$ of $+1$-eigenspace $\mathfrak{k}$ and $-1$ eigenspace $\mathfrak{p}$. Then $\mathfrak{k}$ is the Lie algebra of $K = O(n)$. I want to compute the dimensions of $K$-invariants $\textrm{Hom}_K(\wedge^q \mathfrak{p}, \mathbb{C})$, which, I suppose, is equal to $(W/ \mathfrak{k} W)^*$ where $W = \wedge^q \mathfrak{p}$, where $\mathfrak{p}$ is viewed as $\mathfrak{k}$-module by adjoint-representation. Could you someone point a way further?
Comment: when you said "compute the invariants" what exactly are you looking for?
Comment: I see that you updated your question to mean the dimension of the space of invariants. In that case, I think my answer completely solves that. The dimension is the number of integer partitions of $q$ with distinct parts that are all congruent to 1 mod 4. More precisely, this is the case if $n\ge q$. Let me know if you have any questions about my argument.
Answer: To offer a slightly more geometric viewpoint on the same, the space $\bigoplus_q \mathop{\mathrm{Hom}}_K(\Lambda^q(\mathfrak{p}),\mathbb{C})$, which is the direct sum of all spaces you are considering, is the cohomology of the Lie algebra $\mathfrak{gl}_n$ relative to its subalgebra $\mathfrak{o}_n$, which, by a standard argument, is the same as $H^*(U(n)/O(n))$. It is well known (it really is; if you need some reference, see, for example, page 28 of lecture notes of Haefliger - http://www1.mat.uniroma1.it/people/piazza/HaeDC.pdf) to be the exterior algebra generated by elements $\xi_{4k-3}$, for all $k$ such that $2k-1\le n$. In fact, $\xi_{d}$ is the anti-symmetrisation of the trace of product of $d$ matrices. This confirms the very nice answer given by Abdelmalek Abdesselam.
Comment: @Dotsenko : I was looking at Vogan's article where this isomorphism is sketched. Your reference helped a lot. Thank you.
Comment: Thanks for bringing more perspective to my bare hands brute force approach... I knew from looking at the yellow book by Loday a long time ago that Lie algebra cohomology is related to invariants of matrices as studied by Procesi, Rasmyslov, Formanek and others but I didn't study that connection in earnest.
Comment: @AbdelmalekAbdesselam : to be fair, a lot of computations of Lie algebra cohomology need results like Procesi/Rasmyslov/Formanek if one needs to explain them to "hardcore algebraists". However, in many cases using algebraic topology gives alternative proofs (e.g. via the Serre spectral sequence for various fibrations).
Answer: Edit:
I misread the question and understood $\mathfrak{p}$ as corresponding to antisymetric instead of symmetric matrices. So what immediately follows answers a different question. See the end of this post for a complete solution of the OP's case.

I don't know what you mean exactly by "compute the invariants": perhaps finding an explicit linear basis? Essentially $\wedge^q\mathfrak{p}$ is the same as the antisymmetric plethysm $\wedge^q(\wedge^2(\mathbb{R}^n))$. If I remember correctly, this kind of objects appears in relation to the Hodge conjecture for certain Abelian varieties as in work by Ken Ribet and Fumio Hazama. Namely, in some particular situations, the invariant elements in such a plethysm are the Hodge classes in the cohomology of the variety.
See in particular the article "Branching rules and Hodge cycles on certain Abelian varieties" in AJM 1988. There could be some useful tools for your question in that literature.
As for a linearly generating set of invariants, it is easy to construct as follows. Let me call a Wick contraction any set partition $P$ of $\{1,2,\ldots, 2q\}$ with blocks of size two. Let me denote by $P_{\ast}$ the special case $$
\{\{1,2\},\{3,4\},\ldots,\{2q-1,2q\}\}\ .
$$
For indices $i,j$ in $\{1,\ldots,n\}$, let me use the Kronecker delta notation $\delta_{i,j}$ for the indicator function of the condition $i=j$.
For a Wick contraction $P$ and a collection of $2q$ indices $i_1,\ldots,i_{2q}$ in $\{1,\ldots,n\}$, let me write
$$
A(P)_{i_1,i_2,\ldots,i_{2q}}=\prod_{\{\alpha,\beta\}\in P} \delta_{i_{\alpha},i_{\beta}}\ .
$$
One can view $\wedge^q(\wedge^2(\mathbb{R}^n))$ as the real vector space of all arrays $T=(T_{i_1,\ldots,i_{2q}})_{i_1,\ldots,i_{2q}\in\{1,\ldots,n\}}$
which change sign if one exchanges indices within a block of $P_{\ast}$ or if one rigidly exchanges two blocks.
Now define the linear forms $L_P$ indexed by Wick contractions given by
$$
L_P(T)=\sum_{i_1,\ldots,i_{2q}\in\{1,\ldots,n\}}
A(P)_{i_1,i_2,\ldots,i_{2q}} \ T_{i_1,i_2,\ldots,i_{2q}}\ .
$$
By the first fundamental theorem of 19th century invariant theory for $K=O(n)$,
these form a linearly generating collection for ${\rm Hom}_K(\wedge^q\mathfrak{p},\mathbb{C})$. Of course one can restrict to $P$'s which are "transverse" to $P_{\ast}$, i.e. , such that $P\cap P_{\ast}=\varnothing$.
I don't immediately see how to prune the remaining collection to get a basis, since I expect tons of linear relations. The stable case $n\ge 2q$
might be easier to analyze first.

In the OP's case the relevant space is $\Gamma:=\wedge^q({\rm Sym}^2(\mathbb{R}^n))$.
The description of a generating set of invariants is exactly the same.
The only thing that changes is the identification of $\Gamma$ with a space of arrays $T$. In this situation $T_{i_1,\ldots,i_{2q}}$ must stay the same if two indices in the same block of $P_{\ast}$ are exchanged and it must change sign if two blocks are exchanged. Also the transversality condition can be dropped.
Note that one can reduce the generating set a bit as follows. Instead of Wick contractions (aka perfect matchings) $P$ one can index invariants by integer partitions $\lambda$ of $q$. If one takes $T=A^{(1)}\wedge\cdots\wedge A^{(q)}$ for a bunch of symmetric matrices $A^{(1)},\ldots,A^{(q)}$ then the invariant encoded by $\lambda$ is the complete antisymmetrization of a "manual polarization" of
$$
\prod_{a}\ {\rm tr}(A^{\lambda_a})\ .
$$
By "manual polarization" I mean replace each $A$ factor by an $A^{(k)}$ so everyone is used exactly once.
If one thinks of $P$'s as fixed-point-free involutions, take the cycle type of the composition $P\circ P_{\ast}$ and divide all the cycle lengths by two (extra care needed if lack of transversality). That gives you the partition $\lambda$. It is easy to see that the invariant $L_{\lambda}$ vanishes unless all the parts $\lambda_a$ are congruent to 1 mod 4. It also vanishes if there are repeated (odd) parts. Indeed if one does a cyclic permutation along a trace of length $\lambda_a$ one gets the identity $L_{\lambda}=(-1)^{\lambda_a-1}L_{\lambda}$. So an even part kills the invariant. For $\lambda_a$ congruent to 3 mod 4 one can do a "mirror symmetry" of the cycle which fixes a vertex. This involves $(\lambda_a-1)/2$ disjoint transpositions which is an odd number. If there are two cycles of length $\lambda_a$ then exchanging them gives $(-1)^{\lambda_a^2}=-1$ since we reduced the discussion to odd parts.
So your space of invariants $(\wedge^q({\rm Sym}^2(\mathbb{R}^n)))^{O(n)}$ is of dimension 1  for $q=1$. Then it vanishes for $q=2,3,4$. I suspect it has dimension 1 for $q=5$ and $n$ not too small. By the above it has at most that dimension. Showing equality means showing that the antisymmetrization of
$$
{\rm tr}(A^{(1)}A^{(2)}A^{(3)}A^{(4)}A^{(5)})
$$
is not identically zero.
Let $N(q)$ be the number of integer partitions $\lambda$ of $q$ with distinct parts that are congruent to 1 mod 4. The argument I just gave proves the upper bound
$$
{\rm dim}(\wedge^q({\rm Sym}^2(\mathbb{R}^n))^{O(n)})\le N(q)\ .
$$
Interestingly, the computations by Vit also give a computer assisted proof that, in fact, equality holds for $q\le 14$ (and $n$ large enough, i.e., in the stable case).

Update: In the trace of five matrices case one can prove nonvanishing as follows. The invariant $L_\lambda$ corresponding to $\lambda=(5)$ is
$$
L_{\lambda}(T)=\frac{1}{5!}\sum_{\sigma\in\mathfrak{S}_5}
\varepsilon(\sigma)\ {\rm tr}(A^{(\sigma(1))}\cdots A^{(\sigma(5))})
$$
when $T=A^{(1)}\wedge\cdots\wedge A^{(5)}$. Now take the following $5\times 5$ matrices. Let $A^{(1)}_{12}=A^{(1)}_{21}=1$ and all other entries zero.
Let $A^{(2)}_{23}=A^{(2)}_{32}=1$ and all other entries zero. Etc.
Let $A^{(5)}_{51}=A^{(5)}_{15}=1$ and all other entries zero. Namely, consider the graph given by the cycle $(12345)$. For each edge in the cycle take the adjacency matrix of the corresponding one-edge graph. If I did not mess up my computation, the corresponding specialization of $L_{\lambda}$ is equal to $1/12$.
This can be generalized for a  partition $\mu$ of $q$, also with distinct parts congruent to 1 mod 4. One then defines an element $T_{\mu}=A^{(1)}\wedge\cdots\wedge A^{(q)}$ as before. Namely, build a graph $G$ with vertex set $\{1,\ldots,q\}$ made of disjoint cycles
with lengths given by the parts of $\mu$. For each edge in $G$ build the adjacency matrix of the corresponding one-edge graph to get the $A$ matrices. If one has a part $\mu_a=1$ corresponding to a cycle $(j)$ then take the matrix with $A_{jj}=1$ and all other entries zero. A quick combinatorial argument
shows that $L_{\lambda}(T_{\mu})$ is an invertible diagonal matrix (with rows and columns indexed by partitions). By construction products of $A$'s give zero most of the time unless $\lambda$ replicates $\mu$. This immediately implies that $N(q)$ is the  exact answer to the OP's question.
Answer: You are basically looking for trivial $O(\mathbb{C}^n)$ representations contained in $\Lambda^k \mathfrak{p}^*.$ Since your representation $\mathfrak{p}$ is the space of symmetric matrices, you can find the whole decomposition into irreducibles  of $\Lambda^k S^2 \mathbb{C}^n$ as a special case of plethysm for the Lie group $O(\mathbb{C}^n).$ In fact, this very special case of plethysm was already dealt with on this site for the group $GL(\mathbb{C}^n)$ in (at least) two questions:
Known decomposition of $\bigwedge^k Sym^d \mathbb C^n$ in special cases?
What is known about this plethysm?
Please note, that irreducible $GL(\mathbb{C}^n)$ representations decompose further under restriction to $O(\mathbb{C}^n)$ -- see e.g. Symmetry, Representations, and Invariants by Nolan Wallach and Roe Goodman.
To check whether you get correct decompositions and/or multiplicities you can use mathematical software. See e.g.:
Symmetric powers of Schur polynomials
I've whipped up some Sage code which however seems to be quite slow: https://cocalc.com/share/25e624ba-9091-484f-af2e-71deb7120f58/trivial%20reps%20in%20exterior%20algebra.sagews?viewer=share
Comment: Pattern $1,0,0,0,1$ for $q=1,2,3,4,5$ is confirmed on these few cases. However, for $B_3$ I got "Multiplicity of the trivial representation in the 14-th exterior power: 2"
Comment: seems I misread the question the matrices are indeed symmetric instead of antisymmetric.
Comment: Sign error. Happens to everybody. :)
Comment: Thank you I was thinking along similar lines but not beyond the following: By schur's lemma it following that the given object is equal to the $\mathbb{C}$ times multiplicity of trivial representation in $\wedge^k \mathfrak{p}$.  Then I thought, "IF" adjoint representation of $\mathbb{k}$ in $\mathfrak{p}$ is irreducible then we get zero for $k =1 $ and by duality for $k= n-1$.  I could not proceed further. Thanks for the insight.
Comment: @user49908 The representation of $O(V)$ on symmetric matrices is not irreducible. The symmetric form defining $O(V)$ is invariant!
Comment: @VítTuček: Does your code confirm my predictions for $q=1,\ldots,5$ ?
Comment: @VítTuček: thanks for checking +1. Sorry I didn't get what $B_3$ means.
Comment: @AbdelmalekAbdesselam It means the Cartan type. At least that's how they call it in Sage. So it's result for $O(7)$.
Comment: @VítTuček: I also did not get why you said "However" for $q=14$ when your computations confirm that my upper bound is in fact exact. Indeed, $14=13+1=9+5$ so there are two partitions with distinct parts congruent to 1 mod 4.
Comment: @AbdelmalekAbdesselam Sorry, I misunderstood your sentence "By the above it has at most that dimension."
Comment: @Vit Tucek : Thank you for the solution.

Invariants of exterior powers


Looking for the title/author of story about snail-like creatures

Question: Trying to find title/author of story I read many years ago, around 1964. Story was written from the point of view of a snail like creature. The central character describes (stream-of-consciousness?) himself and other characters moving along a path in a constant search for food. The story ends with the main character falling into what turns out to be the fuel tank of a space ship.
Comment: As in he carried a shell on his back? Left a slime trail? Was hermaphroditic? And when was "many years ago"?
Comment: The central character describes (stream-of-consciousness?) himself and other characters moving along a path in a constant search for food. The story ends with the main character falling into what turns out to be the fuel tank
of a space ship.
Long time ago= 1964
Answer: There may be others but I nominate "James", a short story by Gordon R. Dickson, first published in the The Magazine of Fantasy and Science Fiction, May 1955, available at the Internet Archive. (The title refers  to "The Four Friends" by A. A. Milne.)

James huffled.
He paused, his horns searching the air. Something was coming toward him along the brick he himself was traversing. For a moment he tensed, then his trained perception recognized that the one approaching was another snail. James glowed with pleasure and hurried to meet him.
"I'm James," he said, joyfully touching horns. "And you?"
"Egbert," replied the other. "Honored to make your acquaintance, James."
"Honored to make yours," replied James; and then, avidly, as all snails do, he asked, "What's new?"
"The word," said the other. "The word is being passed."
"No!" said James.
"Absolutely," confirmed Egbert.
"It's Homo Sapiens, of course; you might have expected it." He sighed.
"H. Sapiens?" asked James. "Why, I wouldn't have thought it of them. They seemed like such large harmless creatures, for all their rushing around. I've just been observing one—"
"They may look harmless," interrupted Egbert, sternly, "but the mischief's in them. And we can't tolerate it, of course. After coming halfway across the Galaxy to try and get away from Them, you know."
"True," agreed James. He added, a trifle wistfully, "Sometimes I think we should have crushed Them the last time they overran the planet we were on. If not the previous time. Or the time before that."
"But what a labor it would have been," protested Egbert. "Of course all they had were primitive material weapons: space warps, disintegrators and the like. But there were so many of Them—thousands of planetary systems all populated up to the plimsoll mark. What a weary task to zzitz hard enough to exterminate them all. And how easy, comparatively, to zzitz just enough to protect ourselves."

If that doesn't ring a bell, maybe a quotation from the Milne poem will:

"James gave the huffle of a snail in danger—
And nobody heard him at all."
Answer: This is  "On the Fourth Planet" (1963) by J. F. Bone. The question was asked before as "Short story where creatures have squares of territory." Originally published in the April 1963 issue of Galaxy and widely anthologized.
Comment: That is it! Thank you.
Comment: @TomWeeks:
If this is the right answer, please click on the check-mark to accept it.
Answer: You don't give much detail, but it sounds like Dragon's Egg by Robert Forward. From Wikipedia: Dragon's Egg is a neutron star with a surface gravity 67 billion times that of Earth, and inhabited by cheela, intelligent creatures the size of a sesame seed who live, think and develop a million times faster than humans.
Comment: Were they snail-like?
Comment: yes...the gravity of the neutron star squishes them flat and they crawl like snails.
Comment: **Snail**-like creatures living a million times **faster** than humans?


C as K and S and silent (rules of thumb for pronunciation of C?)

Question: I am just learning Spanish. For the most part, I find that pronunciation is very consistent. However, I am having a little difficulty with the letter "C." Most of the time it is pronounced like "K" in English, but there are exceptions. In the word "Discipulos" it appears to be silent; in "Cierto" it is pronounced like "S" in English. Are there rules for determining when C is silent, and when it is pronounced like "S" or do I just need to memorize these exceptions?
Comment: In "Discípulos", it is not the "c", which is silent.  "dis" is the first syllable. "cí" is the second syllable. So, the second syllable, "cí" takes the sound, not the first syllable "dis".
Answer: C is never silent.
'c' has three sounds.

When combined with 'h' it creates the digraph 'ch' with the same sound as english 'chair' ('choza').
When followed by 'a', 'o' or 'u' or by another consonant it has the 'k' sound ('casa', 'cobre', 'ósculo', 'actor').
When followed by 'e' or 'i' it has the 'z' sound ('cereza', 'ciruela').

Your problem arises with this third sound. Spanish is divided in two big areas that we can call "standard" and "seseante" (Spanish word for 's-using'). In "seseante" zones (you are learning in one of them, and they are majority through Latin America) the 'z' sound has disappeared and both 'z' and 'ce'-'ci' are pronounced as 's'. So with "discípulos": on a "seseante" zone you have an 's' followed by an 's' sound, and since there is no long 's' in Spanish you end up pronouncing just one 's'.
In summary:
Zone         Discípulos      Cereza     Casa    Choza    Acción
Standard     Dis-ZI-pu-los   ze-RE-za   CA-sa   CHO-za   ak-ZION
Seseante     Di-SI-pu-los    se-RE-sa   CA-sa   CHO-sa   ak-SION

Comment: The second case (k sound) is also used when c is followed by another consonant, as in *actor*, *octubre*, *acción* (aK-Zión).
Comment: Perhaps you want to add that the sound that you call 'z' sounds like english 'th' in 'thing'
Comment: Considerando que México por si solo tiene más del doble de la población de España, no sé si sea lo más razonable distinguir entre seseante y "estándar". Yo diría que actualmente lo estándar es el seseo, y lo anormal es distinguir s de c.
Answer: For c + vowel you can memorize the standard rules:
1.   ca, co, cu = ka, ko, ku

2.   ce, ci = ze, zi

where z is pronounced like 'th' in 'think'
Now, depending on the zone you are, 'seseo' changes all cases of rule 2. into
2.   ce, ci = se, si

Comment: This is for Spain, right (the "th" sound)? Not Mexico?
Comment: In Mexico is like case 2. We don't pronounce the "th" sound as in Spain. Is a plain "s" sound even por words written with z

zapato = sapato
Answer: I would add something to @Envite answer (I can't comment):
In spanish the sound it's more important than the way of writing (always respecting the orthografy). This means that if a word changes you have to update the way you write it.
Also, the 'z' before 'i' and 'e' it's almost forbbiden, it turns into 'c', except for very few words for ethimological reasons ("enzima", "zinc","azimut","nazi","zigzag") and in "zeta" (because is it's own name).
This is important in making plurals:

"procaz" --> "procaces"
"audaz" --> "audaces"
"pez" --> "peces"
"maíz" --> "maíces"
"vez" --> "veces"
"nuez" --> "nueces"
"arroz" --> "arroces"
"luz" --> "luces"
"tenaz" --> "tenaces"
"matiz" --> "matices"
And a lot more.

And with the "conjugación" of the verbs:

"cazar" -> "cace" (1ª s.), "cacemos" (1ª p.)…
"cocer" -> "cuezo" (1ª s.), "cueza" (another tense), …
"zurcir" -> "zurzo"…
"sacar" -> "saque" (1ª s.) and "saquemos" (1ª p.).
Answer: You are right in American Spanish the sequences -sci- and -sce- are pronunced always /si/ and /se/ (in European Spanish the most frequent pronunciations are /-sθi-/ and /-sθe-/).
One might expect that the equalization in American Spanish of /s/ and /θ/ would lead to forms such as */-s:e-/ or */-s:i-/, but this is not the case, since Spanish language lacks tense or geminate consonants as Italian does. In American Spanish /-sce-/ and /-sci-/ are pronounced always with a plain consonant:
ascensor [asen'soɾ] // consciente [kon'sjente]
Answer: Actually, C is never silent in Spanish. In Discipulos, both S and C make the [s] sound, kind of like in English where C and K both form the "ck" digraph and both are pronounced [k]. In Spanish, C before I and E produces the [s] sound but also the [th] sound in European Spanish so C certainly isn't silent in those regions.
Comment: Do you mean that English speakers pronounce ck with two k sounds?  We do, for instance pronounce bookcase with two but that is different.


Calculate usable storage space with different size drives in Windows Storage Spaces?

Question: I'd like to create a parity storage space in Windows 10 with a 5 tb disk and two 3 tb disks. Is there a way to calculate how much usable space this will give me?
Answer: While the above answer is correct for Raid-5, Windows Storage Spaces is a slightly different animal.  For example, I have the following drives in a Parity Space formatted with ReFS (gotta use PowerShell in Windows 10 Pro if you want to use ReFS for Parity, as far as I can tell):

4x1 TB (3.63 TB usable)
3x2 TB (5.44 TB usable, 2.72 TB each)
2x3 TB (5.43 TB usable, 1.81 TB each)
1x1 TB (931 GB usable)

Total usable space before parity is 15.4GB (actual capacity of all drives).  Total usable space after Parity is 10.2GB.  Therefore, it appears in Storage Spaces, you can add up all usable space for the pool and divide by 1.5 to get an estimate for usable storage space on a Parity Pool.
Therefore, in your case you would have the following:
(2.72 * 2 + 4.54) / 1.5 = 6.65 TB of usable space.
Answer: Yes, there is. The only redundant storage technique available that uses 3 drives is called RAID-5. This storage array allows one drive in your system to fail, while still retaining all of your data.
The basic math behind Raid-5 is
<code>(# of Drives * GB per drive) - ( GB per one Drive)</code>
Raid can only use the maximum disk space for the smallest drive you have. In your case, a typical 3TB drive is 2794 GB. This plugged into the equation gives:
(3 * 2794) - (2794) = 5588 GB of usable storage.  (5.58 TB)
Your 5TB drive will essentially waste it's extra 2TB and be used as a 3TB drive.
Answer: 1st of all, for both parity and mirror redundancy the usable space base unit is always the capacity, C, of the smallest drive in the array. This is a fundamental property of all RAID implementations, because they all use the rows/stripes/columns paradigm. Assuming N drives are in the array, usable space for parity is:
C(N - 1)
While for n-way mirroring it's:
C(N/n)
Ergo OP's usable storage space is:
3(3-1) = 3*2 = 6 TB
Dan's usable storage space is:
1(10-1) = 9 TB


How to organize data for a CMS that controls several websites?

Question: We are building a CMS that controls data for 3 different portals. These 3 portals are not the same although connected to each other. Think of it like there's a portal for Renters, portal for Tenants, and portal for Agents (just an example). These 3 portals may have different contents but they all have users, data lists, settings, etc. and they are all editable via 1 CMS.
What is the best way to organize them in the CMS in such a way that it's easy for the Master Admin to navigate through?
Should I create the major division in the CMS...
By website / portal?
Website 1: Dashboard, Users, Data List, Analytics, etc.
Website 2: Dashboard, Users, Data List, Analytics, etc.
Website 3: Dashboard, Users, Data List, Analytics, etc.
Or by section name?
Dashboard: Website 1 Dashboard, Website 2 Dashboard, Website 3 Dashboard
Users: Website 1 Users, Website 2 Users, Website 3 Users
Data List: Website 1 Data List, Website 2 Data List, Website 3 Data List
Comment: What do you mean by "building a CMS"? Are you developing a competitor to Drupal, Sitecore, etc.? Building a solution that uses one of those tools? Building a custom CMS software just for managing these 3 portals?
Answer: Why not both view?
I think that the view choice will be changed according to the goal of the super admin. You should focus on the goal , tasks of the administrator. Does admin searches based on the website or users? Why does admin need divided information? In order to complete xxxxx, which view makes more sense?
Try to make a list to show + and - of each clustering attempt.
From technical perspective, you can re-render the data without loading the page depending on your tech stack. There isn't a best view solution without having a bind to its content and context...
Answer: The best way to organized information will be "the way human eye human eye perceive information"
Human eye perceive information in hierarchically, so i would make more sense, to take all together a third approach apart form section name and portal.
My approach will be to organization information based on user groups, as display below.


What is the maximum amount of data i passed through querystring of jquery ajax?

Question: What is the maximum amount of data i passed through querystring of jquery ajax?
Answer: Query strings form part of the URL for an HTTP GET request, so the main limit you'll hit is URL length.
Here's a question about that:
What is the maximum length of a URL in different browsers?
So for typical browsers stay inside of 2,000 characters in total. But keep in mind that other clients may not deal with URLs of this length (e.g. proxy / caching servers).
I'd recommend that staying under 500 characters you should be safe. Anything more and consider using a POST request instead.
Answer: This would depend on the browser and/or server
IE 4.0 and above is ~2048 characters
All other browsers seem to support much more.  So basically if you are trying to implement a cross browser web site/application then its probably best not to exceed 2048 characters.
Also note Web servers can be configured to limit the amount of data passed though a QueryString.  This is rare but it can be done.
Answer: The maximum url length for any http request varies from browser to browser.  Jquery won't limit you, but the browser the request is being made from will.
See this post:
What is the maximum length of a URL in different browsers?


looking for ethereum account easy management process

Question: Suppose I want users to answer surveys and that each response are hashed and sent to ethereum. My issue is the user experience of creating an account and login without metamask which is not user friendly enough for the population I am targeting. Is it possible to get for each user an public/private key created in the backend stored on a server, filling their account with gas, and then triggering the ethereum transactions on their behalf but in the same time, letting the private keys visible to none except the user. Is it possible ?
Answer: Generating and storing private keys at the server-side is leading the concept to ad absurdum. If you want to simplify the process for the users and let them work ether-free, then you can design your contract in the way that a function call requires user's signature as additional parameter. In this case, you can let  your server call the function on behalf of the user
function storeResponse(bytes32 responseHash, uint8 v, bytes32 r, bytes32 s) {
   address msgSender = ecrecover(responseHash, v, r, s);
   responses[msgSender] = responseHash;
}

instead of
function storeResponse(bytes32 responseHash) {
   responses[msg.sender] = responseHash;
}

This will work, however, you'll have to handle two more issues:

spamming - how the server can decide for who to relay?
replay-attach - how to avoid replaying a transaction. E.g. solution would be to use the nonce.
Comment: thanks you for your response. What do you mean by "requires user's signature", how can the user sign, does he have to enter the private key when the transaction event is triggered ? or do you mean that all the private keys are managed by a single central entity ?
Comment: Every user creates himself the private key. This private key can be used to sign the responseHash locally offchain and then the user can let the server submit this signature to the smart contract.
Comment: thank you, the background of my thoughts is more on the UX side: here the user needs to create a key, to store it and then to use it to sign, which is not user friendly I think. Do you see a way to prevent from this ?


PDF drawing objects from view on a page that should be on the next page

Question: I am attempting to create a PDF from a View that may be so long it has multiple pages.
This view has subviews of at least 100 height, but can vary.  So i'm checking to see if a view will be split due to a page switch or not, then attempting to adjust its Y value so it is displayed on the next page.   I am using this code to do so
currentRowFrame = CGRectMake(currentRowFrame.origin.x,currentRowFrame.origin.y + contentRow.frame.size.height + 5, 728, 100);

if (currentRowFrame.origin.y > 692 && currentRowFrame.origin.y < 792)
{
   int extraSpace = 812 - (int)currentRowFrame.origin.y;
   currentRowFrame = CGRectMake(currentRowFrame.origin.x,currentRowFrame.origin.y + extraSpace, 728, 100);
}

A page is of size 792, so I'm checking to see if the origin falls in that space that would overlap, and if so attempting to scroll it down.
The problem I am having is when the PDF gets drawn, it still sees the last (and possibly split) row regardless of how far I try to move it down, and adds it to the first page, then again on the second.
This is my PDF draw code:
// Creates a mutable data object for updating with binary data, like a byte array
NSMutableData *pdfData = [NSMutableData data];

// Points the pdf converter to the mutable data object and to the UIView to be converted
int pageSize = 792;
UIGraphicsBeginPDFContextToData(pdfData, view.bounds, nil);
CGContextRef pdfContext = UIGraphicsGetCurrentContext();

NSInteger currentPage = 1;
BOOL done = NO;

do
{
    //CGRect currentPageRect = CGRectMake(0, (pageSize.height*currentPage), pageSize.width, pageSize.height);
    UIGraphicsBeginPDFPage();

    // draws rect to the view and thus this is captured by UIGraphicsBeginPDFContextToData
    CGContextTranslateCTM(pdfContext, 0, -(pageSize * (currentPage - 1)));
    [view.layer renderInContext:pdfContext];

    // If we're at the end of the view, exit the loop.
    NSLog(@"%f", view.frame.size.height);
    if ((pageSize * currentPage) > view.frame.size.height)
        done = YES;
    else
        currentPage++;
}
while (!done);

// remove PDF rendering context
UIGraphicsEndPDFContext();

return pdfData;

my understanding is that this should grab everything from 0 - 796 on the view the first run through, then if there is still space on the view above 796, go again to make another page starting at 796 and going to 1592.
However, it always seems to be grabbing the last row I am trying to move off the first page, back on to the first page, and just increasing the length of the first page (visually) to fit it, while also adding it to the second page where its actually suppose to be.
Answer: I found the issue.
The problem was on the line
UIGraphicsBeginPDFContextToData(pdfData, view.bounds, nil);

the view.bounds was generating a full page of the entire view, so I made a specific rect of CGRectMake(0, 0, view.bounds.size.width, 792); and it worked out just fine.


JMeter stress testing - server error is "The remote host closed the connection. The error code is 0x800704CD"

Question: When I try to stress load my ASP MVC Web API 2 by JMeter - an error occurred in the server side.
Here the server error:
2015-07-20 16:11:02.2636 ERROR 81 System.Web.HttpException (0x800704CD): The remote host closed the connection. The error code is 0x800704CD.
   at System.Web.Hosting.IIS7WorkerRequest.RaiseCommunicationError(Int32 result, Boolean throwOnDisconnect)
   at System.Web.Hosting.IIS7WorkerRequest.ExplicitFlush()
   at System.Web.HttpResponse.Flush(Boolean finalFlush, Boolean async)
   at System.Web.HttpWriter.WriteFromStream(Byte[] data, Int32 offset, Int32 size)
   at System.IO.StreamWriter.Flush(Boolean flushStream, Boolean flushEncoder)
   at MyApp.Export.Impl.MyExport.Export[T,V](Stream stream, Func`2 transferFunc)
   at MyApp.Controllers.MyController.<>c__DisplayClass3.<MyReturnResponse>b__0(Stream outputStream, HttpContent httpContent, TransportContext transportContext)

JMeter give me an error :
java.net.SocketException: Connection reset

I read a lot of information about it. There are some assumptions about proxy server and et al.
Could you give me advice or solution for these errors?
May be JMeter is closing the content downloading?
Thanks a lot!
P.S.: also I already read the article The remote host closed the connection. The error code is 0x800704CD
EDITED : I completed the test on Azure VM and it passed successful!
Answer: Check any component between JMeter and your server:

Firewall is the biggest suspect
Load Balancer


Why does drupal use .yml and not officially recommended .yaml

Question: Per yaml page https://yaml.org/faq.html they recommend .yaml as file extension but I see drupal uses almost exclusively .yml, how so? And does adding .yaml to file extension even work for drupal 8 or will it be skipped?
Comment: Probably because of Symfony - they didn't support the .yaml extension until later on (see https://github.com/symfony/symfony/commit/6727a2610bb5070394dd269089b1616a9207537e). I'd imagine Drupal just went along with what was available at the time. Incidentally: no, the .yaml extension doesn't work with Drupal as of 8.6.5
Answer: Drupal uses '.yml' because Symfony uses '.yml'
This was discussed in https://www.drupal.org/project/drupal/issues/2091669
I am assuming that '.yaml' would not work, but I haven't tried it. For consistency reasons it is best to stick to '.yml'.
EDIT: Looks like Symfony has started recommending '.yaml' from version 4.0. Can be seen by comparing this page https://symfony.com/doc/4.0/routing.html with the 3.4 version
Comment: I remember now I got one occasion where I used .yaml and d8 module didnt work. I was surprised as my code editor was enforcing .yaml as extension and I didnt think it would matter, but it did.
Answer: because drupal 8 based on symfony 2 and .yaml is not recomended in symfony 2 , it's recomended just for version 4 of symfony 4


Magento2 : What is the difference between Order Status And Order State

Question: Does anyone know how we can differenciate Order Status And Order State ?
Comment: have a look at https://amasty.com/knowledge-base/what-is-the-difference-between-magento-order-status-and-order-state.html and https://www.mageplaza.com/kb/magento-2-order-status-order-state.html
Comment: Can you specify what you are looking for? Means what you want to achive?
Comment: i am little bit confused why magento uses both status as well as state , thats why , i wants to know what actually state and status is .
Answer: The order state and order status are usually mixed up since their names and functions are similar.
An order state is a position of an order in the current processing flow. Magento has the following pre-defines order states:
New
Pending Payment
Processing
Complete
Closed
Canceled
On Hold
Payment Review

Each order state can have one or more order statuses assigned to it. This makes processing easier.
For example, a "Pending Payment" order state can have the following order statuses:
Pending Payment Paypal
Pending Payment Card
Pending Payment Store Credit

Magento provides a way for create custom order statuses. For this:
1. Admin Panel>System>Order Statuses;
2. click the "Create New Status" button;
3. fill necessary information in the "New Order Status" page;
4. click "Save Status";
5. assign a recently created  status to a particular order state.

Comment: Cite your sources: https://amasty.com/knowledge-base/what-is-the-difference-between-magento-order-status-and-order-state.html
Comment: Thanks @Dhiren Vasoya , i think now i am clear about state and status
Comment: great, if answer help you mark as solution so it will help other in community.
Comment: and @FabianSchmengler , i think it is better that he does't paste link directly ,but he explain me in their way , so this is matter.
Comment: @SanjayShiyal the answer is a plain copy/paste, it doesn't explain anything more.
Answer:
The "order state" and "order status" are usually mixed up since their
names and functions are quite similar.

1,Order Status. All orders have an order status that is associated with a stage in the order processing workflow
1,An order state is a position of an order in the curent processing flow.
2,Magento Order State  is used to define processing order
2,Magento Order Status is used by the administrator to know the exact order flow

Source
Answer: The order status is just a label for the order state. It doesn't represent any logic or workflow.
You could even assign the "status" closed for pending payments.
If you have PayPal, CC and Checkmo as Payment options, you might want to assign different order statuses for each of those when there's a pending payment. Like pending CC, pending Paypal etc.


Ideals whose union is an ideal

Question: Does someone have an example of three ideals such that no one is contained in another, yet their union is an ideal?
Answer: I have no better idea than to built on the example of the three proper subgroups of $C_2\times C_2$: let $M$ be a module over the commutative ring $R$. Then one can define a ring structure on the product $R\times M$ as follows:

$(r,m)+(s,n):=(r+s,m+n)$,
$(r,m)\cdot(s,n):=(rs,rn+sm)$.

For every submodule $N$ of $M$ the subset $0\times N$ is an ideal of this ring.
Now consider $C_2\times C_2$ as a $\mathbb{Z}$-module and look at the ring $\mathbb{Z}\times (C_2\times C_2)$ with the operations just described. The three subgroups then become ideals in that ring and their union is an ideal as well.
Remark: a technical result in commutative algebra says that given ideals $p_1,\ldots ,p_n$, $n\geq 3$, such that $p_1,\ldots ,p_{n-2}$ are prime ideals and an ideal $I$ with the property
$I\subseteq\bigcup\limits_{k=1}^n p_k$
then $I\subseteq p_k$ for some $k$.
This result yields that in any example of three ideals pairwise not contained in each other and such that their union is an ideal none of the three can be a prime ideal.
Comment: One can also consider $C_2\times C_2$ as a ring with zero multiplication.

Ideals whose union is an ideal


What is a "data-ad-slot" for Google Adsense and why is inline styling required?

Question: I have this adsense ad code:


Time Machine does not backup all content?

Question: I had to move from a Macbook Pro to a Macbook Air, and so I backed up my Pro using time machine onto an external hard drive. The backup ran smoothly and no errors were displayed. When I went to see the files in the "application support" directory (on the external hard drive using the new Air laptop), some folders "Steam" and "Minecraft" were missing. Is it possible they did not backup? Could they be hidden on the hard drive? I know the hard drive was not full. Also, I do not have access to the Macbook Pro.
Answer: Could you (or someone else) have setup exception rules for those folder so that they are not included in the Time Machine backup? (Possibly because they are too large)
You can either enable Finder to show hidden folder (just Google Finder show hidden folders) or view the folder from Terminal (ls -a).
Also, you may want to check the different "snapshots" of the Time Machine backup if it had been backed up before.


iPhone 6 Plus Sounds Stopped Working

Question: I've check all my settings, my phone is not in Do Not Disturb mode, but I cannot get my alert sounds (messages, phone calls, etc) to work. Only vibrate works. Toggling settings off and on does not work either.
Comment: something stuck in the headphone socket?
Comment: I've linked to some of the many settings that need to be checked. If you want to edit to list each setting you have checked - that might help us help you. Hopefully the broad HW/SW troubleshooting in my answer will help in any event.
Answer: If you can't play music either or listen to voicemails (to check the receiver and the speaker) then you have a hardware or software issue.
If you can play music and listen to voicemails, then you have a software issue or a configuration/setting mismatch with what you want the device to do.
Hardware issue - usually starts with eliminating software issues, but in this case observing the headphone port for damage might be a great quick fix.
Software issues, back up the device and test after restoring it and verifying the settings.

iPhone 6 Plus Sounds Stopped Working


Magento catalog url rewrites undo

Question: Is it possible to Undo Magento Catalog URL rewrite?
By accident this happened and I was wondering if it´s possible to undo this and then have the old URLs back.
Answer: Look for the new url in Catalog->Url Management and delete it. And make sure you manually add the old url back.
Comment: Is there a way I can do this in bulk? It seems like Magento changed all products after a certain date and gave it new URLs after changing the images.
Comment: From the UI you cannot do it in bulk. You will have to create a script. Unfortunately I don't have one.
Comment: Thanks Marius, I will look into that and post an update how i go. Do you know if I run the script will all the internal references update automatically?

Magento catalog url rewrites undo


Experienced HTML/CSS programmer trying to "jump" to dynamic stuff

Question: I've mastered the art of the static website, and now I'm picking up books on PHP, SQL, PEAR, etc so I can get a better handle of making a database-driven website. Now, I'm helping a small startup company get everything necessary off the ground while paying the minimum for third party help (I have yet to look into odesk or elance).
There are two main sites (we'll call them .com and .biz)
.com is the corporate site (an independently run wordpress site with cpanel & email accounts)
.biz is the indiviual reseller's site (expensive software program generating wildcard subdomains with replicated websites and a "virtual office" on asp.net and sql server... this is where our e-commerce is done)
With what I have, right out of the box, there are THREE different logins when there should only be ONE login to get you logged in to interact on the blog, check your webmail, and enter into your virtual office.
All I want is to be able to tie everything in together. Just like this website, after i've logged in once, all of these things are possible by calling php. If the cookie knows who you are, you're automatically logged into all three.. etc etc. Maybe even a header that displays how many messages are in your inbox FROM the wordpress site.
Here's my question.. and I apologize in advance for how uneducated this may sound.
What type of programmer should I turn to for this kind of assistance? I know this will require PHP & SQL, but should I expect any other languages to make this possible? Unless there are clear-cut tutorials available online, I've got to hire a programming ninja that can translate these needs into code. Thanks for any advice you can give!
Answer: Well it really depends on how your solution to these tasks looks like but yes it could probably be done simple with just php/SQL.
Answer: You may want to look into web services in order to help your sites communicate.   This can be done via PHP.


Why can I not use the Make Segments command on my Surface NURBS Curves?

Question: I followed the tutorial on the Modeling/Surfaces/Skinning wiki page, and then I created a simple test. I created a Surface NURBS curve, made 3 copies with space between them, selected all, and hit F, but nothing happened. No error or any indication that F is supposed to do anything was displayed. I am new to Blender and am using version 2.70, so not sure what I am doing wrong. Any ideas?
Comment: Did this answer solve your problem?
Comment: If the answer below solved your problem, don't forget to click the ["Solved" checkmark](https://drive.google.com/file/d/0B_yQeQQ8ImENMnU1ZmpBYjI4WlE/edit?usp=sharing) to let everyone know the question has been solved. :)
Answer: After reading the tutorial, here are a few points you can check in your workflow:
Point #1
Make sure you add a Surface NURB Curve, not any other kind of object. A "Surface" is different from a "Mesh" or a "Curve", as you can see here in the Add menu:

Notice there are other objects that have NURB or Curve in their name, but these are not what the tutorial is describing:

So, when adding a new object, go by the first level of names, as shown here:

Point #2
After Adding the first Surface NURB Curve, you must be in Edit mode when you duplicate it
(SHIFTD), because the Make Segments command (F) will only work in Edit mode.

If you were not in Edit mode when you made the duplicates, each one would be it's own separate object and the F command would not work.
By duplicating the surfaces while in Edit mode, all of the duplicates are considered one object,
even if they are not connected (which they aren't until you use F)
Point #3
After duplicating the Surfaces, stay in Edit mode, then select All with A, and then press F to Make Segments (connect them all together):

Just to explain the name of the command, when you use "Make Segments" (F), the "segments" that are made are the ones connecting the vertices together, shown here in yellow on the right:
Comment: Thanks, I will try when I get home later.  But I see I was not doing point #2 or #3, as I didn't get that I needed to be in edit mode.


How to join a Windows PC to a Ubuntu domain

Question: I am running Ubuntu Server 14.04.  I have tried numerous Samba config files with no success in having Windows 7 & 8 machines join the Samba domain.  Using the Official Samba 3 HowTo Guide, page 49, I stripped my smb.conf file to bare bones.
Here is my smb.conf file content.
# Global parameters
[global]
    netbios name = FRANK-N-STEIN
    workgroup = TUX-NET
##  passdb backend = tbdsam
#   os level = 33
#   preferred master = yes
#   local master = yes
    domain master = yes
    security = user
    domain logons = yes
#   logon path = \\%N\profiles\%u

When I try to join from Windows, I get this message: "The specified domain either does not exist or could not be contacted."
However, I searched the web and discovered a Windows built-in procedure which locates domain controllers on a local network.
To use it:

Open Windows terminal screen
(2) Change directory to Users\Administrator "cd
C:\Users\Administrator
Enter at the command prompt nltest /dcname:{name of domain}

On my Windows machines, they quickly find my domain controller, "FRANK-N-STEIN".
Can someone help me?  The nltest utility finds the domain controller but the Widows connect to a domain function can't seem to find it.  I really need to get a basic domain in operation using Ubuntu server 14.04.
Answer: For an NT4 domain run by Samba 3 you need to specify:
security = domain

And create a UNIX user so you can login using it from Windows.
In the other hand, you need to use Samba 4 so your Windows 7 and Windows 8 computers can join an Active Directory Domain Controller run by Samba.
Here is the howto: http://wiki.samba.org/index.php/Samba_AD_DC_HOWTO


Can a Bag of Devouring empty an ocean?

Question: If you opened a Bag of Devouring underwater could it empty an ocean?
Comment: Is there a particular edition of D&D you want an answer for?
Comment: [Related] [What would happen if you opened a Bag of Holding underwater?](https://rpg.stackexchange.com/q/79458)
Comment: 5th edition is what im askin about
Comment: one of my players is tryin to do that now
Comment: @MichaelZBiggs I've edited your question to remove the additional questions that were unrelated to your primary question. Feel free to ask them in a separate question.
Comment: Did you players do it to get a specific effect (which one?) or in order to find what happens?
Answer: RAW No - because it won't consume water at all
A Bag of Devouring is a "a feeding orifice for a gigantic extradimensional creature". Logically speaking, a creature would have to be larger than the ocean itself to be able to consume such a volume of liquid.
However, there are no rules written for how the bag interacts with a substance such as water.
There are rules for

Animal or vegetable matter
Inanimate Objects

Water is not an object according to the game definition:

For the purpose of these rules, an object is a discrete, inanimate item like a window, door, sword, book, table, chair, or stone, not a building or a vehicle that is composed of many other objects.

Mainly, water is not discrete.
So according to the rules of D&D, if an object does not say it has an ability and a general rule also would not dictate that it does, the object cannot do that thing. So, since the Bag of Devouring is not listed as having the ability to process non-object non-creature entities, it does not have such an ability. Thus, it would not consume any water at all.
How should this be described in-game?
So if the ruling is that the bag will not consume water maybe simply say (after maybe a round or two of taking in water) that the bag's orifice has closed tightly shut as if it were the lips of some extradimensional creature that did not want to consume salt water.
Houserules to allow water consumption
If you wanted to allow this and make this work with the rules as written you
could adapt the current rules to allow it to consume an amount of water comparable to the rates currently written in the rules.
Considering water an object (rule #2)
The easiest and most logical rule to adapt would be the object rule set (#2) since water would could be argued to be closest to an inanimate object than living things.
Using this ruling it would be able to consume 1 cubic foot of water per day which would be periodically ejected into a random plane. After consuming that much it would presumably refuse to take on any more water. Or you could make the bag / creature suffer an ill effect (stomach bursting, vomiting, etc.) after a few rounds of forced water consumption after this limit was reached.
Using creature consumption rules for water (rule #1)
The other method would be to try to fit water into the rule for devouring living things. Obviously water is not living, but this  could be justified by saying that water is often consumed much as animal flesh and vegetable matter is. Thus the Bag of Devouring (and thus the extradimensional creature it is linked to) is literally drinking the ocean.
Using this rule, the bag could consume, at most, a volume equal to the largest creature size we have rules for (gargantuan) per turn.
Using the house rules, how long would it take?
Even if you ruled it capable of consuming water from an ocean, according to the rules given it looks like it is capable of handling 1 creature's worth of material every 6 seconds and/or a cubic foot of objects each day. It is going to take a LONG time to empty an ocean at that rate.
For example, the Pacific Ocean has an estimated volume of \$2.5\times10^{19} \text{ cubic feet} \$ of water.
Considering water an object (rule #2)
This case is very simple as it would take  \$ 2.5\times10^{19} \text{ days}\$ (\$ 6.8\times10^{16} \text{ years}\$) to empty the ocean.
This an unfathomable amount of time. This is the longer of the two options.
Using creature consumption rules for water (rule #1)
So let's be super generous and allow the use of creature rules (#1) since it can consume one creature per round at best and this would allow for the absolute most material consumption according to the RAW.
If we assume this creature to be gargantuan that is \$8000 \text{ cubic feet} \$ in \$6 \text{ seconds} \$.
(This is also making the very generous assumption that a gargantuan creature occupies all of the 20x20x20 space it is said to control in the rules. This is highly unlikely.)
\$ \frac{8000 \text{ cu ft}}{6 \text{ seconds}} = 1333.3  \frac{\text{cu ft}}{\text{sec}} \times 60 \frac{\text{sec}}{\text{min}} \times 60 \frac{\text{min}}{\text{hour}} \times 24 \frac{\text{hours}}{\text{day}} = 1.1 \times 10^{8} \frac{\text{cu ft}}{\text{day}} \$
\$ \dfrac{2.5 \times 10^{19} \text{ cubic feet of ocean water}}{1.1 \times 10^8 \frac{\text{cu ft}}{\text{day}}} = \dfrac{2.1 \times 10^{11} \text{ days}}{ 365 \frac{\text{days}}{\text{year}}} = \text{ over } 575 \text{ million years} \$!
Hope your PCs are REALLY patient!
tl;dr RAW no, but if you want to houserule then it will still take a LONG time to empty an ocean using a Bag of Devouring
Comment: I think that works out to slightly over 575 million years? Better bring a book.
Comment: Correct! I added that in since that is a slightly more comprehendible number.

Can a Bag of Devouring empty an ocean?


Access 2016 parameter issues

Question: I have a database of products. One of the tables is a supplier history listing who we have purchased each product from and when. Suddenly the table for supplier history is asking me for parameters. I've been using it for a long time and it never did this before. Please note this is happening in a table, not a query. The table does have two relationships to other tables but again this never happened before.
Answer:
Inspect expressions in a table
If Access displays the Enter Parameter Value dialog box every time that you open a table, the incorrect expression is most likely in the Row Source property of a Lookup field in that table.

Right-click the table in the Navigation Pane, and then select Design View.
To determine if a field is a Lookup field, select the field name, and then under Field Properties, select the Lookup tab. If the tab contains a Row Source property box, then the field is a Lookup field. Examine the Row Source property. If it contains an SQL statement, then one of the identifiers in the statement may be incorrect, and causing the Enter Parameter Value dialog box to appear.

Note: A table can have multiple Lookup fields, so be sure to check the Lookup tab for each field.

Found here from Microsoft. This might help point you in the right direction.

Access 2016 parameter issues


Kali Linux tools on Ubuntu 15.04

Question: I am wondering if I could install the Kali hacking tools on Ubuntu Vivid Vervet. I have seen multiple guides about installing it on 14.04 - 14.10 but none on 15.04. I have already tried installing the debian repositories which I now know breaks your distro. Before posting duplicates please read what version of Ubuntu the PPA was built for eg. Utopic, Raring etc. I need it for Vivid Vervet.
Comment: Do you have any specific tools that you want to install?
Comment: I have already install metasploit framework and aircrack-ng suite but when i try to install veil it breaks everything
Comment: no, you cannot install those repositories on Vivid Vervet or even Utopic. I have already searched through the forms
Answer: katoolin is a script that helps to install Kali Linux tools on your Linux distribution of choice. Those who like to use the penetration testing tools provided by the Kali Linux development team can effectively do that on Ubuntu by using Katoolin. The following instructions are for installing Katoolin on Ubuntu 15.04. These instructions also work on all other currently supported versions of Ubuntu.

Open the terminal and type:
sudo apt-get install git
git clone https://github.com/LionSec/katoolin.git && sudo cp katoolin/katoolin.py /usr/bin/katoolin

Make /usr/bin/katoolin executable.
sudo chmod +x  /usr/bin/katoolin

Run Katoolin as follows and you will see the Katoolin interface:
cd /usr/bin/
sudo ./katoolin

When you go to View Categories and then enter 0 for all, the installer will immediately return to where you were. Scroll up, and you may see that a number of the packages can't be found. Those packages are no longer maintained or have been removed from the Kali repositories. If this happens the best option is to install Kali linux tools one tool at a time in a series of distinct steps.

Warning about updates after installing Kali linux tools
The LionSec Katoolin GitHub webpage clearly warns Katoolin users to be careful when updating software.

Before updating your system, please remove all Kali-linux repositories to avoid any kind of problem.

All kinds of problems can occur if you don't do this.
Comment: Just as a warning: Some users have reported the bizarre issue of the katoolin script changing their OS's identity from Ubuntu to Kali Linux, among other problems. As another answer pointed out, install Kali tools in Ubuntu at your own risk, as they might not "play nice" or uninstall cleanly.
Answer: I doubt you'll find all the Kali tools.  As well, it's not just the tools you need.
Kali is a purpose built distro.  The software in it is selected for the (intended) purposes of ethical hacking and forensics.  The kernel has modifications, the software is based on Debian, and most if not all the packages are actually modified in some way from Debian.
Ultimately, while you will not likely find all the Kali tools, you may find some, such as Metasploit, but you're missing on some purpose-built security-centric changes that Kali does in addition to Debian and Ubuntu (i.e. it stops services loading at boot, and other things).
Comment: @begueradj Ceases support after raring (check the referenced PPAs).  The only one it does support while being not EOL is Precise which in turn EOLs in the next two years.  I'd rather just say "Go get Kali"
Comment: What do you think about [this](http://exploiterz.blogspot.fi/2013/08/how-to-integrate-kali-linux-tools-in.html) ?
Comment: @beguueradj and while it looks like the user was GOING to create a 14.04 and newer PPA for the tools, it remains empty.  So same assessment.
Answer: Kali linux does not use PPA's like the other distros this is part of their security. How ever it is possible to add PPA's to kali and Kali PPA's to other distros.
! ! ! ! ! !  AT YOUR OWN RISK ! ! ! ! ! ! ! ! ! ! !
WAGUNGS archive @ launchpad they are not official please go to kali.org
Please get all of the Kali linux PPA's from the tools listing on the Kali site. They have a updated list of tools with links and PPA's for all of the stuff on their distro's. Not that Wagungs tools are not safe but that being open source any one can make changes to it and I will not tell you or any one to get stuff I myself would not. They may be safe but I advise using Kali to go the the official source of all the individual projects for safety of your system. So you know exactly what your getting is the real deal with untampered code.
! ! ! ! ! !  AT YOUR OWN RISK ! ! ! ! ! ! ! ! ! ! !
If you would like the install kali tools on Ubuntu or other distros you may run in to binary dependency problems. You can find a list of all the kali linux tools on their site here.
Kali Linux Official Sites Tools List
They have all of the PPA's and official project links well organized and kept up to date if you wish to install with the PPA's. You can all so read their Documentation on Kali to install their PPA's and tons of other neat stuff. Like most distro PPA databases Kali's is all so kind of hidden so it's easiest to just have a disk to live boot to get all their PPA's or play with their tools.
I believe that Kali and Ubuntu have multi-arching compatibility issues. I am running on trusty and I have had some binary compatibility issues with installing some of their tools. So you will need binary, source, library, and PPA's that do not conflict from both to have %100 successful blend.
Kali unfortunately is designed not to use PPA's ever except for the install default two or three provided by Kali themselves. This is part of their tight security feature that makes their Distro so secure since it's much harder to be tampered with by viruses and malware and such.
You want to make sure that you do not have to many Kali PPA's or to many Ubuntu or Debian or Arch whatever of any kind because mixing PPA's can drag you to your grave. They will essentially start fighting over your system when you sudo apt-get upgrade causing install and removal of various packages, libraries, and etc... This can cause incompatibility issues and conflicts beyond just a simple fix. They can really make things get funky quick.
It is ok to do sudo apt-get update with the PPA's but do not upgrade. You will want to comment out the extra PPA's for the tools after updating to you do not screw your system over with upgrade. Most of Kali's tools are going to have to be installed by source code and mixing PPA's and using apt-get upgrade can delete necessary things for Kali tools or Ubuntu to work.
It is most import and I have to stress that Debian PPA's (Kali's Deb based) do not really get along with Ubuntu PPA's. Though every one is technically Debian based. They should be thought of more like In laws. There family but not really tolerable but you can get along.

Kali Linux tools on Ubuntu 15.04


Can I use steelwool for soldering iron cleaning

Question: Wondering should I use steel wool for cleaning my soldering iron tip.
Is it bad?
Will it impact my tip?
Will it clean the black oxidization off?
Answer: Steel is typically a harder metal than the plating on soldering iron tips.  So while coarse steel wool might clean a tip, it would also quickly destroy the plating, thus it should only be used "in an emergency" or with a cheap tip you are willing to soon replace.
The metal sponges arguably appropriate are made of softer materials, such as brass.  And they really should be brass all the way through, not some sort of copper plating on a steel core, as you might source at the dollar/kitchen store.
But even with a soft material, abrasion counts - something like a cellulose sponge will also eventually wear a tip.  And so will sitting hot with solder and flux on it.
Tips are wear items.  The less they are "cleaned" and the less time they sit hot, the longer they last.  But cleaning is of course necessary, especially for modern fine pitch soldering.
The most modern professional solder stations have high power heaters and very tight control loops, so they can quickly go into a reduced temperature tip-saving mode when idle, and heat right back up again in the time the operator picks up the iron from the stand and applies to the work.
Comment: One point that may be worth clarifying. If the tip is going to sit, it should have solder on it. Keeping the tip "wet" helps prevent oxides from building on it. That protective blob should be cleaned off directly before soldering the component. Slightly more wasteful, but produces cleaner easier work with less need for abrasive tip maintenance.
Comment: Though my solder irons (Weller) have 900\$^{o}\$F tips, I keep them down to 400\$^{o}\$F. Enough to melt solder and not burn the PCB, and last a long time.


Restore Chrome tabs while preserving tab groups, window names, and virtual-desktop positions

Question: At any given time, I have about 150 tabs open in Chrome. They are organized into different tab groups. These groups are organized into different windows, and I use Chrome's "Name window" feature to assign meaningful names to each window. Finally, the windows are divided among seven different virtual desktops.
I want to be able to save this set of tabs, groups, and windows, and to restore it whenever I please. Specifically, I want to start from a single tab (say, the New Tab window) and restore all tabs and windows while meeting these four conditions:

Tab groups restored
Window names restored
Chrome windows restored to the correct virtual desktop (rather than having all Chrome windows restored to whatever virtual desktop happens to be current).
All tabs and windows restored at once. If I had 15 Chrome windows open, I don't want to click 15 times to restore all of them.

Exiting Chrome (Alt-F → X) and immediately opening Chrome again meets conditions 1, 2, and 4, but not 3. And it restores only the tabs and windows from the previous session---not, say, tabs and windows from a session that I had last week.
Is there a Chrome extension that meets the four requirements that I've listed above?
What I've tried

The Session Buddy and Spaces extensions are good, but they don't meet conditions 1-3.
The OneTab, Tab Groups, and Tablerone extensions may be great for other purposes, but they don't suffice for my purposes.
I've searched this site and others, but found nothing that helps.
Answer: Unfortunately the chrome API doesn't yet support access to the window name so no extension can satisfy your condition #2. Please see https://bugs.chromium.org/p/chromium/issues/detail?id=1190160


How can I develop on a cloud using eclipse?

Question: I want to be able to access my code from any computer on eclipse. is it possible?
edit: i am developing for android using java
Comment: @tuğrulbüyükışık i want the code to be stored on the cloud so i can access it from any where as long as i have eclipse installed
Comment: @SpK Yes. its not really what i am looking for. i want something like how you can access your personal bookmarks, settings etc on any chrome browser
Answer: I just keep my Workspaces inside Dropbox along side my normal process of backing up via Mercurial to an offsite service. Has worked well for me.
You could easily replace Dropbox and Mercurial with any one of the many free alternatives.
Answer: A professinal solution would be using an Source Code Control System like Subversion, CVS or Git. There are several distributers where you can get such repositorys for free.
A definitly not professinal solution, but much less complex, so this might even be better for you, is to host your eclipse Projects in something like DropBox/Google Drive/Skydrive whatever.
Since you said, you want to have the ability to work on your code from all your devices, but not that there are severel people working on the code at the same time, i would propose keeping your projects in something like DropBox, since its really really easier and less complex.
When it might happen to you that several people will work on the source, you need a professional solution. For nearly all these professional solution are eclipse plugins available, so you can update/commit/merge your code out of eclipse.
Answer: Try a Source Control Management system. You'll find several plugins for Eclipse, for example EGit in combination with GitHub
Answer: Although it's much easier to setup a cloud service account and a folder that is synced between your computers it's much better to use a Source control management system like Git. The reason for this is that the SCM systems provide history of your development with messages for every commited change, you can see differences between your changes and many more.
According to your comment:

i want something like how you can access your personal bookmarks, settings etc on any chrome browser

you might be looking to sync your eclipse and workspace directories via any cloud service of your choice.


Is there a way to compare and record changes to code without VCS?

Question: I'm working for a client that has no version control system in place. I want to record changes to code without having to add all changes to a spreadsheet. I'm restricted to using Notepad++ so would a plugin or macro for this be another option?
Comment: Why can't you start using a version control system now? If you are "restricted to using Notepad++", why are you looking for IDEs?
Comment: Are you recording individual code changes, or [a group of related changes] (ie bug, feature, etc)?  There's nothing wrong with using a spreadsheet to track the later.  It's certainly done in most F500 companies :)
Comment: @Paul it's the individual code changes that I want to record
Answer: Version control systems are those systems that allows you to capture changes and create a history for files. That's their purpose and the main reason for which they were created.
Therefore if you would like to record changes you should use a version control system, any one out there will do. Nevertheless you should still make and informed decision, and pick the most appropriate one.
Story:
At my current job, during my initial employment weeks, I've received a task of creating a notifications service to be integrated into one of the companies internal applications. It happened that at the exact time the Configuration Manager, that was supposed to give me access to the company's source repository went on holiday. I've simply installed a VCS (Mercurial) locally and continued my work. When the CM came back from holidays, I've committed all my work into the company's repository.
Morale: even if there is no VCS available you can always use one locally.
Comment: and the story was very helpful!


Are you allowed to swap seats with a friend in a different booking class?

Question: Me and a friend are looking at taking a transcontinental flight together. It appears that for this particular flight, business class is $2000 more than economy. This would be too expensive for us to book, but what if we shared? Would it possible for me to fly in the business class seat for the first half of the flight, then swap with my friend who has booked an economy seat? That way we both get to sleep for half of the flight without spending too much money.
Comment: (On some flights) business class is not just about the seat, the airline may also offer you some meals/drinks/... In that case they might not like it, based on the idea that two different people can eat/drink/... more than one person.
Comment: They may not like it either for safety reasons - I imagine they would want to be sure from their boarding records who is sitting in which seat in case of an emergency.
Answer: Generally no. Almost all airlines have policies these days that you have to stay in your ticketed cabin. Only one name can be on a ticket and on the boarding pass that assigns a seat to the passenger and the flight attendants use this info to find stragglers, hand out special meals, count passengers, give out status goodies, etc.
As with most things flying, the flight crew has a fair bit of discretion, and you can always ask. They may say yes, they may say no, there is no way to tell up front.
Here is a related cautionary tale: The family of a 94 old woman chipped in for a business class ticket so she could go from Australia to the US to visit relatives (probably for the last time). Her daughter was flying with her so she could attend to her frail mother's needs occasionally (operate seat, open food, etc.). However the daughter could only afford economy and needed permission to occasionally go into business and check on her mother. On the outbound, that all went fine. On the return, the crew categorically denied her access to business and since the old woman couldn't be unattended for 16 hours, they had to move her to economy which was a traumatic experience. https://www.mirror.co.uk/news/world-news/united-airlines-staff-forced-frail-10216619
So the answer is: Maybe, if you are lucky and staff feels like it.
Answer: Practically, it should work fine; but you have no guarantee.
Changing seats is very common, so once you are on board, nobody cares about seat switches within the class. They do care for switches between classes, but mostly because people might use it to 'sneak' into business class and take an unsold seat.
Formally, the personnel on board has the ultimate decision where you sit, and they typically don't let someone walk from Economy into Business class. However, if the person in business class goes back, and you then go forward, it should work. I recommend that you exchange your boarding passes (very simple if they are electronic), so when you walk forward, if asked, you can pull out his boarding pass to show you have that business class seat. But they might remember your face and his, so you will have to explain what you do, and then it's up to their mood of the day.
We have successfully done that before, but as I said, no guarantees that they will not have their picky day.


Picking an answer

Question: I posted This question a while ago, and both answers are really good, and both worked/are working pretty well. How can I go about accepting an answer if both answers are solving my problem?
Answer: You are not obligated to select either answer in any defined time line (or ever).  It has only been one week and it may be several more before you have defined which was actually the better recommendation.  Occasionally people will find that parts of two different answers where helpful and in the end they used a third solution that was a combination of two (or more) answers.  It sounds like this might be the case here.  You can write a third answer describing what worked for you and giving credit to parts of other answer you found helpful.  You can accept the 3rd answer as the 'best for you'.
There is no rush, wait and see what really was the best in the end and then do what you feel will be most helpful to others in your situation.
Answer: Up-vote both (+10 bounty each), then pick the answer you like the best (and solved your problem; +15 bounty to him) and would prefer to be at the "top" of a list of answers.  If the community finds a different answer to be better, the accumulated up votes on it will eventually bubble it above your selected answer.
In case of a tie, pick the one that has the earliest timestamp (hover over the "answered Month Day at Time" for an exact timestamp to appear in a floating tooltip if you need to).

Picking an answer


Regular Expression simplification

Question: Does $(0 + 10^{*}1)^{*}$ simplify to the following language: Set of all binary strings with even number of ones.
In specific, does the * inside the brackets get evaluated first or the outer * gets evaluated first. Or does it even matter while simplifying as what we finally need is the set of all strings possible with this expression?
Comment: I'm not sure what you mean by "get evaluated first".
Comment: Not sure in which sense you mean this is a "simplification".
Comment: Anyway, what have you tried? Where did you get stuck? You claim that the given regular expression generates a specific language, so try an prove your claim!
Answer: Yes, $(0+10^*1)^∗$ denotes the  set of all binary strings with even number of ones. Or more technically $L(\ (0+10^*1)^∗ \ ) = \{ w \ |\ w$ is a binary string containing even number of 1's $\}$. We denote language of a regular expression $E$ as $L(E)$.
To understand regular expressions, you need to understand the recursive definition of regular expressions.
if $E$ and $F$ are regular expressions $E$+$F$ is regular expression.
if $E$ and $F$ are regular expressions $EF$ is regular expression.
if $E$ is regular expression $E^*$ is regular expression.
For basis, $\epsilon$ and symbols from alphabet $\Sigma$ are also regular expressions.
Next language of regular expressions for each of the above operations is defined: union, concatenation and repetition, respectively. For basis, it is sets of empty string or a single symbol, as the case may be.
Now if $w \in L(E)$ then $L(E^*)$ is not just $wwwww...$, it is also any $w_1w_2w_3...$ (0 or more times) such that $w_1 \in L(E)$,   $w_2 \in L(E)$, $w_3 \in L(E)$, etc.
So $(0+10^*1)^*$ is really $(0+10^*1)(0+10^*1)(0+10^*1)...$ (0 or more times). Thus, you work with the outer $*$ operator first and then work with the inner $*$ operator.
Next comes the question of simplification. Either you want to describe the language of a regular expression in most simplest manner possible, or you want to describe the most simple regular expression for a given language. Both these are hard to do. Even if you are given a minimum DFA of the language, to compute minimum regular expression for it is NP-complete (the decision version: does there exist a regular expression of less than $k$ length for the given DFA).
We can minimize DFA but unfortunately we do not have efficient algorithms to minimize NFA or regular expressions unless $P = PSPACE$. See Minimizing NFA's and Regular Expressions
Gregor Gramlich and Georg Schnitger.
However $(0+10^*1)^*$ is set of all binary strings with even number of ones. Yet another expressions are $0^*(10^*10^*)^*$, $(0^*10^*1)^*0^*$, $(0^*10^*10^*)^*$ and so on. The outline of proof that the regular expression  $(0+10^*1)^*$ is indeed the language mentioned above is as follows:

First we draw a DFA for the language. If we eliminate the state $q_1$ we get the equivalent (enhanced) DFA in the right. It is easy to see that the equivalent regular expression is same. This is kind of reverse-engineering.
Sometimes it is easy to go this way, rather than finding the language of regular expression by automated procedures. Sometimes we can use regular expression algebra also to analyze and simplify regular expressions.
Comment: I disagree that the question should be answered in its current form. That said, the OP asks "is this correct?" and I think any answer should provide at least the sketch of a proof -- why should the OP believe your (or anybody's) verdict any more than their own?
Comment: Fine, here  it is, a simple enough proof outline.
Answer: One way to go about this is to show that $S=T$, where
$S = $ the set of all strings over $\{0,1\}$ containing an even number of 1s,
$T = $ the set of all strings which can be represented by the regexp $(0+10^*1)^*$
Showing that $S\subseteq T$ can be done by induction on the number of 1's in a string and showing that $T\subseteq S$ is even easier.
Answer: (This is not a question on formally proving the meaning of expressions and their equivalence, but on how to read them.)
I see your point: if you match an expression with a string then the outer $*$ fixes the number of pairs of $1$'s, and the inner $*$ determines the number of $0$'s in between each of these pairs. That suggests outside in.
Technically the meaning ("evaluation") of $10^*1$ however is not choosing a single string, but the full language of any number of $0$'s between two $1$'s. Then (once the inside language is evaluated) we concatenate arbitrary sequences of elements in the string. That definitely is inside-out.
Compare this with another example. The expression $(0+1)^*$ has the same source of confusion. It is not: I choose either $0$ or $1$, and then repeat that letter, but I repeat the choice   $0$ or $1$ while concatenating. That seems outside-in, however the evaluation of $(0+1)$ is not a single letter, but of the set $\{0,1\}$. Then the star evaluates that to $\{0,1\}^*$, the set of all strings over  $\{0,1\}$.

Regular Expression simplification


How do I link an installed app in iBooks Author?

Question: I'm trying to making an iBook for educational purposes, and in that book I linked to web pages, embedded a video, embedded an image. I want to link to an installed iPad app in my iBook, is it possible in iBooks Author?. If so, then can someone guide me how to do this or provide some link for that. Any help should be appreciated.
Answer: It is possible in WebKit so it is probably possible in iBooks too. The URL depends on the application, as it's the developer who chooses it. More info here, with the example of launch center, an app which is basically a list of URLs to apps.
Try it with the free app Twitterrific (make your link to twitterrific:// – no http://!).
Comment: This seems correct, however within iBooks I see no way to make a link such as "twitterrific://" without creating a custom widget. The standard way of entering a hyperlink automatically prepends the "http://" no matter what.
Answer: Just use a URL-shortener service, like tinyurl.com or similar.
Make the tinyurl redirect to for instance twitterific://
Comment: That might be a clever hack indeed. Have you verified that it actually works? And it probably will not work while you are offline.


Did Saitama have some level of superhuman strength before training?

Question: In his encounter with Crablante before he started training, Saitama is hit by him and thrown away like 30 meters or more, and then hit again 2 more times with those gigantic claws Crablante has. If Saitama was a regular human, how could he support this beating and still stand like it was nothing and fight back?
Comment: [The OP has re-asked this question](https://anime.stackexchange.com/questions/52648/was-saitama-a-weakling-before-being-a-hero-or-not/52659#52659), which has attracted answers of its own.
Answer: Seems like Saitama doesn't really know he has it before then. From what I remember, Genos said when he was train fighting with Saitama that he wanted to show or let know what Saitama's power really is, something like that.
Answer: Just saying, the hundred push-ups stuff is what Saitama thinks is the reason for his incredible power. And remember Saitama isn't exactly the smartest person to say the least.
I heard somewhere that the reason Saitama is so strong is due to the fact that he broke his "limiter". Now there isn't much information on this but I imagine that it works like this: every person has a limiter based on who they are. This limiter determines how strong they can get mentally and physically. So in Saitama's case he not only trained really hard but also gave everything and when I say everything I mean EVERYTHING.
Before he became super strong he had no job, no family, no friends, he basically had nothing to live for. As Crablante said "I see that you have lifeless eyes." "From one pair of lifeless eyes to another I will let you live." (Something along those lines, but you get the point.) Back to the limiter. What I am trying to say is that Saitama gave it his all, his desire so strong that he broke the barrier that stops everyone from becoming too strong.
This is my main theory on why Saitama is so strong. Now there's this other theory about him eating all his enemies to become stronger and stuff, but that's a whole other story. (I mean no offence to anyone as this is only opinion on this topic. The people who make One Punch Man probably have this completely different explanation on why Saitama is so powerful.)
Answer: Before training, at the time of fighting with that Crablante, Saitama told that he wants to become a hero who can kill any monster with one punch.
I think there is someone/something which grants power to humans or awakens their power according to wish and righteousness. After fighting with Crablante, we can see Saitama inherited/awakened his power which is shown with his eyes being orange color. After that, he trained a lot and became a super powerful one.
Answer: If Saitama was able to even attempt to do his physical training regimen of 100 pushups/100 situps and 10km run, he had to be physically capable to a certain extent to even attempt something as vigorous. So even at that time, he might've been as strong enough to be a high-ranked C-class hero or low-ranked B-class hero perhaps. Also, Crablante is only a Tiger threat-level monster.
Comment: 100 pushups, 100 sit ups, 10km in a day is completely realistic.  That is the joke.  Admittedly I have never done that (I suck at pushups) but most healthy people should be able to do that (even if it takes them from dawn to dusk). It is no where near a B rank superhero level.
Comment: Every day for 3 years consecutively? Even when he felt he broke a bone, he continued. He also didn't use the heater when it was cold or air conditioning when it was hot to make his mind stronger. No every "Healthy" person can do that lol. Plus, most of the C rank hero's are a joke. Mumen rider is C rank 1 and he seems a lot weaker than even the younger saitama. Also, saitama took a good beating during his fight and It wasn't as though he defeated crablante with a single punch.
Comment: That is just dedication not a sign that he is strong.
Answer: Yeah, of course, he had to have had some capabilities to be able to attempt that regimen for over 3 years, but saying that he "only defeated a tiger-level" before he started training is belittling the hell out of what happened, no way he's a high C/Low B-class hero.
To beat a tiger-level disaster (in this case Crablante), you have to either have 5 B-class heroes or 1 A-class. So, he would have been in a higher class since then.


Internet Explorer Security

Question: I've been googling all day trying to find the right solution for this. I've found bit and pieces but I haven't had any luck.  I need the ability to change the security properties in the security tab of Internet Explorer with either a .bat, .reg or some other type of exe that will change them for me.  I've got over 100 computer that need all the same settings and this would save me a lot of time.
Comment: If all systems require the same settings you should use Group Policies to set them.
Comment: Did you have an particular settings in mind?  Adding systems to the zones is a bit different from modifying the zone settings.
Answer: This might help you.  It's an explanation of the security zones and where the settings are stored in the registry.
Internet Explorer security zones registry entries for advanced users

Internet Explorer Security


RMSProp and Adam vs SGD

Question: I am performing experiments on the EMNIST validation set using networks with RMSProp, Adam and SGD. I am achieving 87% accuracy with SGD(learning rate of 0.1) and dropout (0.1 dropout prob)  as well as L2 regularisation (1e-05 penalty). When testing the same exact configuration with RMSProp and Adam as well as the initial learning rate of 0.001, I am achieving accuracy of 85% and a significantly less smooth training curve. I do not know how to explain this behaviour. What can be the reason behind the lack of smoothness in the training curve and the lower accuracy and higher error rates achieved?
Comment: This depends on the network. Can you show us details about the network? Also can you provide the learning curves?
Comment: This is a network with 5 layers (Dropout, Affine, ELU in each layer), set up as follows: 150 hidden dimensions, ELU activation function used, 0.1 learning rate for SGD, 0.001 learning rate for RMS and Adam, L2 regularisation with 1e-05 penalty, Dropout with 0.1 exclusion probability.
Comment: And when you say "exact same configuration ... initial learning rate of 0.001" do you mean you used a different learning rate or you did two experiments: one with the same learning rate and one with a different one? It may depend on the actual software you're using as to what parameters default to what.
Comment: So I used 0.1 for SGD and 0.001 for both Adam and RMSProp. This is because when I ran Adam and RMSProp with 0.1 learning rate they both performed badly with an accuracy of 60%. Also, 0.001 is the recommended value in the paper on Adam.
Comment: You should post learning curves, and whether you measure error on test or training data.
Answer: After researching a few articles online and Keras documentation it is suggested that the RMSProp optimizer is recommended for recurrent neural networks.https://github.com/keras-team/keras/blob/master/keras/optimizers.py#L209
Stochastic Gradient Descent seems to take advantage of its learning rate and momentum between each batch to optimize the model's weights based on the information of the loss function in my case is 'categorical_crossentropy'.
I suggest https://www.ruder.io/optimizing-gradient-descent/ for additional information about optimization algorithms.
Comment: I am not sure what do you mean by "RMSProp optimizer is recommended for recurrent neural networks". The link you put is now broken and it is nowhere mentioned that it is recommended.
Comment: For the life of me I can't remember which paper it was in, but I have also read the advice that RMSProp is recommended for RNNs.
Comment: They removed this part of the Keras documentation: https://github.com/keras-team/keras/issues/12460

RMSProp and Adam vs SGD


Can I play 3DS games on an NDS emulator?

Question: What is the (or is there any) difference between 3DS and NDS games? Is it possible to play 3DS games on NDS emulator?
Comment: Close voters- emulation is not off-topic here and is not inherently illegal.
Comment: The 3DS is the successor to the NDS. Their ROMs are as different as the NGC's and Wii's, or the Wii's and Wii U's. If there was such a thing as a 3DS emulator, you might be able to play NDS ROMs on it, but not the other way round. That's because not only do they feature different hardware, but the 3DS has more features as well, which the NDS (and thus, NDS emulators as well) does not have. For instance; the 3DS possesses a 3D slider and an analog pad, which the game needs to account for. Trying to access those will undoubtedly lead to a crash or otherwise undefined behaviour on the NDS.
Answer: It is not possible. Although the structure is more or less the same, the 3DS has a new firmware, which has yet to be emulated. There is no 3DS-emulator out yet, but you could hack 3DS-roms like normals ROMs, because the system is still the same.
Answer: As the name implies, the NDS is the earlier version of the Nintendo 3DS.
The 3DS has better graphics (and sold better). Concerning the ROMs I think that will just be a tug of quality, because the 3ds is better I think the NDS will be substandard to its brother. I think that a ROM for the NDS cam work on the 3DS but I am quite sure you cannot use the 3ds ROM on the NDS because of its backward compatibility
Answer: Just to re-iterate what the other posters have said:
This all comes down to backward compatibility, as does every other device. A newer device will generally play old content (with a few exceptions). However, an older device will not play newer content; this is either due to drivers, graphics, core framework and the like...
As Looper advised - there is currently no 3DS Emulator out as of yet. So in short - No, it isn't possible to play 3DS games on a standard NDS Emulator.


Why do futures allow higher leverage?

Question: Why do futures allow higher leverage? Shouldn't the risk of a futures contract be the same as the spot. In that case, why would brokers feel more comfortable handing leverage to futures traders vs spot traders?
Comment: You "pay margin" ?
Comment: You pay only margin.
Comment: Sure but the clearing house doesn't care what you pay, they care that you can hold up your end of the deal, and this responsibility should theoretically be pushed to your broker to maintain a maintenance margin. Form your broker's POV, the risk is exactly the same between futures vs spot
Answer: Return is generally measured based on the amount initially invested. If you buy a barrel of oil for $80 and sell it for $100, you earn a 25% return ($20 profit / $80 invested).
With a futures contract, you don't initially pay anything. You enter into a contract to buy/sell something at an agreed upon price and date (and location for physically settled futures).
So if you "bought" a future to buy a barrel of oil at $80, you would pay nothing upfront. If the price of oil went to $100, you could buy the barrel at $80, sell it for $100, and make $20 profit with no initial investment so your relative return is infinite (20/0).
In reality, brokers require some margin to be placed to ensure that you can afford any losses, but that is generally a portion of the futures value, so there is some initial cash outlay, and return is not infinite, but is it several times higher than it would be without buying the oil upfront and waiting to sell it.
Also in reality, most commodity futures are settled before expiry, so one would instead sell the future for $100, collecting the $20 profit without having to pay anything other than margin.
So futures allow leverage by allowing you to invest more with the same initial outlay, or, they multiply relative returns by reducing the amount of initial investment, depending on how you want to look at it.

Why do futures allow higher leverage?


Where exactly is the file linux/kernel.h?

Question: I am reading through Salzman's Linux Kernel Module Programming Guide, and I was wondering about where the file linux/kernel.h is located. I couldn't find it with find. Or rather the files I found did not have any printk priority macros in them.
Answer: The linux/kernel.h header which gets used for module builds is the header which is part of the kernel source. When modules are built in the kernel source tree, that's the version which is used.
For external module builds, the build process looks for the header in /lib/modules/$(uname -r)/build/include/linux/sched.h. That file is provided by kernel header packages, e.g. on Debian derivatives, the linux-headers-$(uname -r) package.
The /usr/include/linux/kernel.h is intended for user processes, not for kernel modules.
The printk priority macros now live in linux/printk.h and linux/kern_levels.h. I'm guessing you're reading the original guide, which is based on the 2.6 kernel series; for modern kernels you should read the updated guide (currently for 5.6.7).
Answer: On my Mint 18.x system with the build-essential BUT not any full source tree installed -
user@localhost:~ $ locate kernel.h | grep \/kernel.h$
/usr/include/linux/kernel.h
/usr/src/linux-headers-4.4.0-21/include/linux/kernel.h
/usr/src/linux-headers-4.4.0-21/include/uapi/linux/kernel.h
/usr/src/linux-headers-4.4.0-21-generic/include/config/debug/kernel.h
/usr/src/linux-headers-4.4.0-21-generic/include/config/firmware/in/kernel.h
/usr/src/linux-headers-4.4.0-53/include/linux/kernel.h
/usr/src/linux-headers-4.4.0-53/include/uapi/linux/kernel.h
/usr/src/linux-headers-4.4.0-53-generic/include/config/debug/kernel.h
/usr/src/linux-headers-4.4.0-53-generic/include/config/firmware/in/kernel.h
/usr/src/linux-headers-4.8.0-53/include/linux/kernel.h
/usr/src/linux-headers-4.8.0-53/include/uapi/linux/kernel.h
/usr/src/linux-headers-4.8.0-53-generic/include/config/debug/kernel.h
/usr/src/linux-headers-4.8.0-53-generic/include/config/firmware/in/kernel.h

Per Jeff's comment on your question, I would assume that most times /usr/include/linux/kernel.h is what will be used,
I'm sure if you extract a kernel tree tarball it may have another copy in its directory structure as well. A quick check shows them all as being different sizes... or empty files.
Comment: `locate '*/kernel.h'` is how you can get `locate` to match the exact filename (also, `locate` supports regexes as well). (I'm assuming `mlocate` given it's Linux Mint)
Answer: the answer to this might significantly depend on the linux distribution... SUSE/SLES vs RHEL/Centos/Fedora vs debian vs mint and so on,
and could it also differ based on RPM flavors of linux distros vs debian ?
in any case my experience is mostly with SLES version 11.4,
and for that I can vouch for
/usr/src/linux/include/linux/kernel.h

where for me   /usr/src/linux -> /usr/src/linux-3.0.101-108.21

uname -r    for me returns 3.0.101-108.21-default

as I update the kernel to newer versions, the soft link changes accordingly  along with kernel.h.  I think it is safe to say if you are looking for the kernel module version of kernel.h it will be under some folder related to uname -r and be part of the kernel source package for your linux distribution.