Basically, I am wondering if there is a way to automatically run a function when an element becomes hidden or visible, not on a user click but automatically in another script.  I don't want this to just run one time, because the elements (such as a slider) constantly change from visible to hidden.  Would this be something that jQuery can do with bind? Such as binding the element's visibility to a function (I don't know how to write this)  If you need me to elaborate more on what I'm trying to do, let me know. Thanks  Pseudocode:   $('#element').bind('display:none', function); function(){     //do something when element is display:none }  $('#element').bind('display:block', function2); function2(){     //do opposite of function }
I'm loading elements via AJAX. Some of them are only visible if you scroll down the page. Is there any way I can know if an element is now in the visible part of the page?
What pins on a nRF51822 do I connect to a STM32 programmer? Recently, I have answered a few questions that were upvoted by factors more than the accepted answer, but not accepted. , at the time of my writing, has an accepted answer that the asker said was not what he wanted. I don't know why. In the future, when people view this, people might only look at the accepted answer and move on. Would it be possible to have a "community accepted" feature? Maybe only the people at the top can vote to accept it or something. How much rep, if any, should go to that person? Additive function $T: \mathbb{R} \rightarrow \mathbb{R}$ that is not linear. A function $T:V \rightarrow W$ is additive if $T(x+y) = T(x) + T(y)$ for every $x, y \in V$. Prove that there exists an additive function $T: \mathbb{R} \rightarrow \mathbb{R}$ that is not linear.  My attempt: Let $T$ be the function $T: \mathbb{R}$ (over the field $\mathbb{Q}$) $\rightarrow \mathbb{R}$ (over the field $\mathbb{R}$). The set $\{1, \sqrt{2}\} \subseteq \mathbb{R}$ is linearly independent for the vector space $\mathbb{R}$ over $\mathbb{Q}$. Then, there must exist a linearly independent set $W \subseteq \mathbb{R}$ (over $\mathbb{Q}$) such that $\{1, \sqrt{2}\} \subseteq W \subseteq \text{span}(W) = \mathbb{R}$ (over $\mathbb{Q}$).  I have been told that the function defined as $T(1) = 1$ and $T(w) = 0$ for all $w \in \text{span}(W) \setminus \{1\}$ is additive but not linear, but I cannot see why this is? I can see why it is not linear, clearly $T(\sqrt{2} \cdot 1) = 0$ but $\sqrt{2} T(1) = \sqrt{2}$. But, why is $T$ additive? For example, $T(1+1) = T(2) =0$ but $T(1) + T(1) = 1+1 = 2$? Is there a mistake somewhere? $N_1,N_2,N_3 \unlhd G, N_i\cap N_j =\{e\}, G = N_iN_j$. Want to show that $G$ is abelian, $N_i$ are isomorphic. The following is a problem from the Berkeley Problems book.      Let $G$ be a group with three normal subgroups $N_1$ , $N_2$, and   $N_3$. Suppose $N_i \cap N_j = \{ e\}$ and $N_iN_j  = G$ for all   $(i,j )$ with $i \ne j$ . Show that $G$ is abelian and $N_i$, is   isomorphic to $N_j$ for all $i, j$ .   Attempt:   I have not got very far. The only thing that comes to my mind is that as $|HK|=\frac{|H||K|}{|H \cap K|}$, $|N_1|=|N_2|=|N_3|=m$, and order of $|G|=m^2$. I have made other futile attempts of trying to show m prime, finding an isomorphism between the $N's$. I think the fact that the equation $N_i N_j=G$, could be seen as, left coset of $N_j$ with the multiplying elements restricted to only $N_i$ could provide me an answer, but I haven't got anywhere with this.   Thanks in advance. Finding value of an expression If $x^2-3x-1=0$ then find the value of $(x^6+1)/x^3$ I tried to solve the quadratic but it became too complicated any way of doing this without a calculator How can I release and renew my DHCP lease from Terminal? From the Terminal, how can I release and renew my DHCP lease?  Currently, I'm doing the following for the wireless interface, but I'm wondering if there's a better way:  sudo ifconfig en1 down sudo ifconfig en1 up   For the wired interface, replace en1 with en0. Apparently recurrences like this cannot be solved with the Master Theorem:  $T(n) = 2T\left(\frac{n}{2}\right) + \frac{n}{\log(n)}$  Because $n^{\log_b(a)} = n^1$ is not a polynomial multiple of $f(n) = \frac{n}{\log(n)}$ since $\frac{n}{\frac{n}{\log(n)}} = \log(n)$, which is less than $n^\epsilon$ for any positive $\epsilon$.  But when is this really even an issue?   For example why wouldn't the time complexity be $n \log n$ using case 2 of the Master Theorem? Unrolling the recursion:  $$T(n) = n\sum_{k=1}^{\log_2(n)} \frac{1}{\log_2(2^k)}$$  $$T(n) = n\sum_{k=1}^{\log_2(n)} \frac{1}{k}$$  Doesn't this suggest $\Theta(n \log n)$ even though it supposedly cannot be done with Master Theorem? What does a "real" quantum computer need for cryptanalysis and/or cryptographic attack purposes? The cryptographic world has been buzzing the word "quantum" for a while now (even the NSA is currently preparing itself for a post-quantum crypto world) and quantum-related hardware engineering is evolving constantly. For example: the 5-qubit quantum computer created at MIT by using the technique of ion traps succeeded in prime-factorizing 15. Does that mean that since it succesfully managed that, that it is a all-purpose quantum computer which could be used for cryptanalysis and/or cryptographic attacks?   If that's not the case, what exactly would a "real" quantum computer need (think: rough description of expected technical abilities, aka specs) to enable its users to use it for cryptanalysis and/or cryptographic attack purposes? And - ignoring rumours about potentially existing but confidential governmental projects - does any such system already exist today? Where do I suggest new Stack Exchange sites? Is there an appropriate place to suggest new Stack Exchange based sites, perhaps a place for them to be voted upon?  I wish there was a Stack Exchange site for Aviation (both real-life and simulated). Keras CNN with low/constant accuracies Remove default ID attribute from HTML helpers in ASP.NET MVC How to escape text for regular expression in Java Can I define keyboard shortcuts using the Super key? How can I play around targeted discard? Many decks in competitive Magic have access to targeted discard spells, like  and .  Against counterspells, you can rely on a variety of tricks like baiting counters, bottlenecking your opponent's mana, and good old-fashioned counter wars. Targeted discard cards allow your opponent to attack your hand on the very first turn of the game, and go right for your key cards &mdash; and it can often be backbreaking when your opponent takes away a crucial card like a combo piece or a sweeper.  What tricks and tactics can you employ, either during deck-building or in play, to play around an opponent's targeted discard?  (I know that one of the answers is going to be . That's excellent, but please also include approaches that work in formats without free countermagic.) I have upgraded from Ubuntu 16.04 LTS to Ubuntu 18.04 LTS. I was surprised to see that the context menu entry "Make Link" (keyboard shortcut Ctrl+M) in Nautilus doesn't seem to exist anymore. It used to appear upon right mouse click on a file or folder and allowed the user to create a symbolic link. I am using Google Spreadsheets to create a matrix (time/activity) as a daily schedule for staff to sign into.  Is there a formula to calculate the number of cells in a column that are shaded (or not shaded) a certain color?  For example: 20 of the cells are gray and 31 are not gray (shaded any other color) and instead of manually counting them, it calculates this at the bottom of reach column. How to roll perception checks for characters who aren't actively looking without arousing suspicion? This applies to all d20 systems, but with an example from the from the Pathfinder  (emphasis mine):  Stonecunning: Dwarves receive a +2 bonus on Perception checks to potentially notice unusual stonework, such as traps and hidden doors located in stone walls or floors. They receive a check to notice such features whenever they pass within 10 feet of them, whether or not they are actively looking.  In this case, does the GM roll the check in secret or ask the player roll the check? If the GM asks the player to roll for the check, what stops situations like:  GM: (interrupting) &quot;Gimli, Roll a perception check.&quot; Dwarf player: &quot;Oh, it's a natural one, I guess I don't see anything.&quot; Human player: &quot;Okay, I'll roll a perception check for anything unusual in this room. Nice! 19. How about 19, does 19 work for you?&quot; GM: &quot;Gimli, everything looks kosher to you. Aragon, you notice a rock coloured tarp on the ground here, covering what looks like a pit trap.&quot;  In this case, by telling the dwarf to roll his &quot;free&quot; perception check, he's telegraphed to the players that there is something to notice. How can this be fixed, without bluffing checks for nothing in particular to throw off the signal to noise ratio of similar checks? SEO and buying expiring or dropped domain Does it make any difference for SEO benefits to buy dropped and already available domains other than backorder domains that are expiring soon?  I heard somewhere that whois gets deleted after being dropped. But I didn't find any confirmation if it's true or not.  Anybody can tell me if there are benefits of one against the other, if yes what? What books would you recommend to start learning about software testing I'm trying to learn more about software testing, so I want to know which books you would recommend on this topic Energy-Momentum Tensor in QFT vs. GR What is the correspondence between the conserved canonical energy-momentum tensor, which is $$ T^{\mu\nu}_{can} := \sum_{i=1}^N\frac{\delta\mathcal{L}_{Matter}}{\delta(\partial_\mu f_i)}\partial^\nu f_i - \eta^{\mu\nu}\mathcal{L}$$ (the four conserved Noether currents corresponding to four possible spacetime translations)  where $\{f_i\}_{i=1}^N$ are the $N$ matter fields in the theory, and we assume $f_i\mapsto\alpha^\nu\partial_\nu f_i$ for translations,  and stress-energy tensor from the Einstein-Hilbert action, which is: $$ T_{\mu\nu}\equiv-\frac{2}{\sqrt{-g}}\frac{\delta\mathcal{L}_{Matter}}{\delta g^{\mu\nu}} $$   In particular, how do you get that the two are equal (are they?) for Minkowski space, for which there is no variation in the metric?