question
stringlengths
6
13.7k
text
stringlengths
1
25.8k
source
stringclasses
3 values
In our computer systems lecture we were introduced to the MIPS processor. It was (re)developed over the course of the term and has in fact been quite easy to understand. It uses a RISC design, that is its elementary commands are regularly encoded and there are only few of them in order to keep the wires simple. It was ...
There is a general historical trend. In the olden days, memories were small, and so programs were perforce small. Also, compilers were not very smart, and many programs were written in assembler, so it was considered a good thing to be able to write a program using few instructions. Instruction pipelines were simple, a...
https://api.stackexchange.com
Are there any theoretical machines which exceed Turing machines capability in at least some areas?
Yes, there are theoretical machines which exceed the Turing machines in computational power, such as Oracle machines and Infinite time Turing machines. The buzzword that you should feed to Google is hypercomputation.
https://api.stackexchange.com
Why the drain the source terminal of the MOSFET function differently while their physical structure is similar/symmetrical ? This is a MOSFET: You can see that the drain and source are similar. So why do I need to connect one of them to VCC and the other to GND ?
Myth: manufactures conspire to put internal diodes in discrete components so only IC designers can do neat things with 4-terminal MOSFETs. Truth: 4-terminal MOSFETs aren't very useful. Any P-N junction is a diode (among other ways to make diodes). A MOSFET has two of them, right here: That big chunk of P-doped silicon...
https://api.stackexchange.com
Everyone discusses the Fourier transform when discussing signal processing. Why is it so important to signal processing and what does it tell us about the signal? Does it only apply to digital signal processing or does it apply to analog signals as well?
This is quite a broad question and it indeed is quite hard to pinpoint why exactly Fourier transforms are important in signal processing. The simplest, hand waving answer one can provide is that it is an extremely powerful mathematical tool that allows you to view your signals in a different domain, inside which severa...
https://api.stackexchange.com
This cool design was "tattooed" on this leaf. I found it on the windshield of my car. What's up with it?
That is the work of a leaf miner. A leaf miner is the larval stage of an insect that feeds on the inside layer of leaves. Notice how the galleries (tunnels) start small and then get larger as the larva matures? Most leaf miners are moth larvae (Lepidoptera)
https://api.stackexchange.com
I am using Louvain clustering (1,2) to cluster cells in scRNAseq data, as implemented by scanpy. One of the parameter required for this kind of clustering is the number of neighbors used to construct the neighborhood graph of cells (docs). Larger values result in a more global view of the manifold, leading to lower num...
A general rule of thumb is that in order to improve the variance $n$ times you need $n^2$ neighbours. This is only applicable if you consider the $n^2$ nearest neighbours of a cell to be biologically identical (i.e. "similar enough"); if your data includes 10 types of cells with 10 cells each, then using the 20 nearest...
https://api.stackexchange.com
For the following quantities respectively, could someone write down the common definitions, their meaning, the field of study in which one would typically find these under their actual name, and most foremost the associated abuse of language as well as difference and correlation (no pun intended): Propagator Two-point...
The main distinction you want to make is between the Green function and the kernel. (I prefer the terminology "Green function" without the 's. Imagine a different name, say, Feynman. People would definitely say the Feynman function, not the Feynman's function. But I digress...) Start with a differential operator, c...
https://api.stackexchange.com
Let $ V $ be a normed vector space (over $\mathbb{R}$, say, for simplicity) with norm $ \lVert\cdot\rVert$. It's not hard to show that if $\lVert \cdot \rVert = \sqrt{\langle \cdot, \cdot \rangle}$ for some (real) inner product $\langle \cdot, \cdot \rangle$, then the parallelogram equality $$ 2\lVert u\rVert^2 + 2\lVe...
Since this question is asked often enough, let me add a detailed solution. I'm not quite following Arturo's outline, though. The main difference is that I'm not re-proving the Cauchy-Schwarz inequality (Step 4 in Arturo's outline) but rather use the fact that multiplication by scalars and addition of vectors as well as...
https://api.stackexchange.com
According to this article (and a lot more published today on the same topic), Kosovo electricity net production balance has decreased during the last weeks. This has led to a small deviation of the European network’s frequency (from 50Hz to 49.996Hz). In turn, this frequency deviation led to some electric clocks (like ...
From the Reuter's article referenced: SARAJEVO, March 7 (Reuters) - European power grid lobby ENTSO-E urged Serbia and Kosovo to urgently resolve a dispute over their power grid, which has affected the broader European network, causing some digital clocks on the continent to lose time. Figure 1. The ENTSO-E System O...
https://api.stackexchange.com
Related: Safe current/voltage limit for human contact? From what I've heard: 110 V (or 220 V; household voltage pretty much) is dangerous (i.e. can kill you) I think there's consensus on this, no need to try :) 60 V (old telephone lines) is supposedly dangerous (never tried, only heard it once... probably won't try)...
How much voltage is dangerous is not really a static number as it depends on your body resistance, time of exposure and source "stiffness" (i.e. how much current it can supply). You get figures like 60V (or as low as 30V) which are an attempt at an average figure above which "caution should be taken". However, dependin...
https://api.stackexchange.com
I have heard several conspiracy theories regarding the origin of the new coronavirus, 2019-nCov. For example that the virus and/or SARS were produced in a laboratory or were some variant of Middle Eastern respiratory syndrome (MERS), shipped via laboratory workers. I am well aware bioinformatics has debunked many cons...
The scenarios are impossible and would be laughable if they were not so serious. The evidence is in the phylogenetic trees. Its a bit like a crime scene when the forensics team investigate. We've done enough crime-scenes often going to the site, collecting the pathogen, sequencing and then analysis - (usually neglected...
https://api.stackexchange.com
Say you cook up a model about a physical system. Such a model consists of, say, a system of differential equations. What criterion decides whether the model is classical or quantum-mechanical? None of the following criteria are valid: Partial differential equations: Both the Maxwell equations and the Schrödinger equat...
As far as I know, the commutator relations make a theory quantum. If all observables commute, the theory is classical. If some observables have non-zero commutators (no matter if they are proportional to $\hbar$ or not), the theory is quantum. Intuitively, what makes a theory quantum is the fact that observations affec...
https://api.stackexchange.com
Most of the time RS-232 and UART come together in serial communication theories. Are they both the same? From my readings I concluded UART is a hardware form of the RS-232 protocol. Am I correct?
No, UART and RS-232 are not the same. UART is responsible for sending and receiving a sequence of bits. At the output of a UART these bits are usually represented by logic level voltages. These bits can become RS-232, RS-422, RS-485, or perhaps some proprietary spec. RS-232 specifies voltage levels. Notice that some...
https://api.stackexchange.com
I just starting taking a course on Data Structures and Algorithms and my teaching assistant gave us the following pseudo-code for sorting an array of integers: void F3() { for (int i = 1; i < n; i++) { if (A[i-1] > A[i]) { swap(i-1, i) i = 0 } } } It may not be clear, bu...
This algorithm can be re-written like this Scan A until you find an inversion. If you find one, swap and start over. If there is none, terminate. Now there can be at most $\binom{n}{2} \in \Theta(n^2)$ inversions and you need a linear-time scan to find each -- so the worst-case running time is $\Theta(n^3)$. A beauti...
https://api.stackexchange.com
I am a set theorist in my orientation, and while I did take a few courses that brushed upon categorical and algebraic constructions, one has always eluded me. The inverse limit. I tried to ask one of the guys in my office, and despite a very shady explanation he ended up muttering that "you usually take an already know...
I like George Bergman's explanation (beginning in section 7.4 of his Invitation to General Algebra and Universal Constructions). We start with a motivating example. Suppose you are interested in solving $x^2=-1$ in $\mathbb{Z}$. Of course, there are no solutions, but let's ignore that annoying reality for a moment. We...
https://api.stackexchange.com
I have been on a date recently, and everything went fine until the moment the girl has told me that the Earth is flat. After realizing she was not trolling me, and trying to provide her with a couple of suggestions why that may not be the case, I've faced arguments of the like "well, you have not been to the space your...
I love this question, because it's a very simple demonstration of how to do science. While it's true that in science one should never accept anything 'without evidence', it's also true that blind skepticism of everything and anything gets one nowhere - skepticism has to be combined with rational inquiry. Your date has ...
https://api.stackexchange.com
I am a big fan of the old-school games and I once noticed that there is a sort of parity associated to one and only one Tetris piece, the $\color{purple}{\text{T}}$ piece. This parity is found with no other piece in the game. Background: The Tetris playing field has width $10$. Rotation is allowed, so there are then ...
My colleague, Ido Segev, pointed out that there is a problem with most of the elegant proofs here - Tetris is not just a problem of tiling a rectangle. Below is his proof that the conjecture is, in fact, false.
https://api.stackexchange.com
I understand that a DSP is optimized for digital signal processing, but I'm not sure how that impacts to the task of choosing an IC. Almost everything I do with a microcontroller involves the processing of digital signals! For example, let's compare the popular Microchip dsPIC30 or 33 DSP and their other 16-bit offer...
To be honest the line between the two is almost gone nowadays and there are processors that can be classified as both (AD Blackfin for instance). Generally speaking: Microcontrollers are integer math processors with an interrupt sub system. Some may have hardware multiplication units, some don't, etc. Point is they a...
https://api.stackexchange.com
The event horizon of a black hole is where gravity is such that not even light can escape. This is also the point I understand that according to Einstein time dilation will be infinite for a far-away-observer. If this is the case how can anything ever fall into a black hole. In my thought experiment I am in a spaceshi...
It is true that, from an outside perspective, nothing can ever pass the event horizon. I will attempt to describe the situation as best I can, to the best of my knowledge. First, let's imagine a classical black hole. By "classical" I mean a black-hole solution to Einstein's equations, which we imagine not to emit Haw...
https://api.stackexchange.com
Not to be confused with what is the mechanism of acid-catalyzed ring opening of epoxides. What is the correct order of regioselectivity of acid-catalyzed ring-opening of epoxides: $3^\circ$ > $2^\circ$ > $1^\circ$ or $3^\circ$ > $1^\circ$ > $2^\circ$? I am getting ready to teach epoxide ring-opening reactions, and I n...
First part It won't decide the issue but the Organic Chemistry text by Clayden, Greeves, Warren and Wothers also mentions that the matter might not be as clear-cut as the majority of your textbooks make it seem. This might strengthen the position of the textbook you're using a bit. But again, there are no references gi...
https://api.stackexchange.com
Lots of chips nowadays require smoothing capacitors between VCC and GND for proper function. Given that my projects run at all sorts of different voltage and current levels, I was wondering if anyone had any rules of thumb for a) how many and b) what size capacitors should be used to ensure that power supply ripple doe...
You need to add a couple of more questions -- (c) what dielectric should I use and (d) where do I place the capacitor in my layout. The amount and size varies by application. For power supply components the ESR (effective series resistance) is a critical component. For example the MC33269 LDO datasheet lists an ESR rec...
https://api.stackexchange.com
I need to design a moving average filter that has a cut-off frequency of 7.8 Hz. I have used moving average filters before, but as far as I'm aware, the only parameter that can be fed in is the number of points to be averaged... How can this relate to a cut-off frequency? The inverse of 7.8 Hz is ~130 ms, and I'm worki...
The moving average filter (sometimes known colloquially as a boxcar filter) has a rectangular impulse response: $$ h[n] = \frac{1}{N}\sum_{k=0}^{N-1} \delta[n-k] $$ Or, stated differently: $$ h[n] = \begin{cases} \frac{1}{N}, && 0 \le n < N \\ 0, && \text{otherwise} \end{cases} $$ Remembering that a discrete-time syst...
https://api.stackexchange.com
These two seem very similar and have almost an identical structure. What's the difference? What are the time complexities for different operations of each?
Heap just guarantees that elements on higher levels are greater (for max-heap) or smaller (for min-heap) than elements on lower levels, whereas BST guarantees order (from "left" to "right"). If you want sorted elements, go with BST. Source: Heap is better at findMin/findMax (O(1)), while BST is good at all finds (O(...
https://api.stackexchange.com
How are PCA and classical MDS different? How about MDS versus nonmetric MDS? Is there a time when you would prefer one over the other? How do the interpretations differ?
Classic Torgerson's metric MDS is actually done by transforming distances into similarities and performing PCA (eigen-decomposition or singular-value-decomposition) on those. [The other name of this procedure (distances between objects -> similarities between them -> PCA, whereby loadings are the sought-for coordinates...
https://api.stackexchange.com
I was making pasta, and I noticed the pasta boiling over. I thought about it some more, and I realized I had no idea why this was happening. When the lid is on, the foam rises. When the lid is off, the foam dies back. Clearly there's some surfactant at work allowing bubbles to form, and the bubbles are mostly full of s...
The starch forms a loosely bonded network that traps water vapor and air into a foamy mass, which expands rapidly as it heats up. Starch is made of glucose polymers (amylopectin is one of them, shown here): Some of the chains are branched, some are linear, but they all have $\ce{-OH}$ groups which can form hydrogen bo...
https://api.stackexchange.com
I have noticed that I find it far easier to write down mathematical proofs without making any mistakes, than to write down a computer program without bugs. It seems that this is something more widespread than just my experience. Most people make software bugs all the time in their programming, and they have the compile...
Let me offer one reason and one misconception as an answer to your question. The main reason that it is easier to write (seemingly) correct mathematical proofs is that they are written at a very high level. Suppose that you could write a program like this: function MaximumWindow(A, n, w): using a sliding window, ca...
https://api.stackexchange.com
We have a multivariate normal vector ${\boldsymbol Y} \sim \mathcal{N}(\boldsymbol\mu, \Sigma)$. Consider partitioning $\boldsymbol\mu$ and ${\boldsymbol Y}$ into $$\boldsymbol\mu = \begin{bmatrix} \boldsymbol\mu_1 \\ \boldsymbol\mu_2 \end{bmatrix} $$ $${\boldsymbol Y}=\begin{bmatrix}{\boldsymbol y}_1 \\ {\boldsymbo...
You can prove it by explicitly calculating the conditional density by brute force, as in Procrastinator's link (+1) in the comments. But, there's also a theorem that says all conditional distributions of a multivariate normal distribution are normal. Therefore, all that's left is to calculate the mean vector and covari...
https://api.stackexchange.com
I have a DNA sample which I know doesn't quite match my reference genome - my culture comes from a subpopulation which has undergone significant mutation since the reference was created. The example I have in mind is E.coli. We've tried assembly using a couple of different tools and the de-novo assembly isn't as high q...
One approach to this is to use whatever data you have to iteratively update the reference genome. You can keep chain files along the way so you can convert coordinates (e.g. in gff files) from the original reference to your new pseudoreference. A simple approach might be: Align new data to existing reference Call vari...
https://api.stackexchange.com
I am searching for some groups, where it is not so obvious that they are groups. In the lecture's script there are only examples like $\mathbb{Z}$ under addition and other things like that. I don't think that these examples are helpful to understand the real properties of a group, when only looking to such trivial exa...
Homological algebra. Let $A,B$ be abelian groups (or more generally objects of an abelian category) and consider the set of isomorphism classes of abelian groups $C$ together with an exact sequence $0 \to B \to C \to A \to 0$ (extensions of $A$ by $B$). It turns out that this set has a canonical group structure (isn't ...
https://api.stackexchange.com
Generally speaking, I've heard numerical analysts utter the opinion that "Of course, mathematically speaking, time is just another dimension, but still, time is special" How to justify this? In what sense is time special for computational science? Moreover, why do we so often prefer to use finite differences, (lea...
Causality indicates that information only flows forward in time, and algorithms should be designed to exploit this fact. Time stepping schemes do this, whereas global-in-time spectral methods or other ideas do not. The question is of course why everyone insists on exploiting this fact -- but that's easy to understand: ...
https://api.stackexchange.com
Male and female brains are wired differently according to this article: Maps of neural circuitry showed that on average women's brains were highly connected across the left and right hemispheres, in contrast to men's brains, where the connections were typically stronger between the front and back regions. But since l...
Short answer Yes, men and women's brains are different before birth. Background First off, learning effects versus genetic differences is the familiar nature versus nurture issue. Several genes on the Y-chromosome, unique to males, are expressed in the pre-natal brain. In fact, about a third of the genes on the Y-chr...
https://api.stackexchange.com
Power supplies are available in a wide range of voltage and current ratings. If I have a device that has specific voltage and current ratings, how do those relate to the power ratings I need to specify? What if I don't know the device's specs, but am replacing a previous power supply with particular ratings? Is it OK...
Voltage Rating If a device says it needs a particular voltage, then you have to assume it needs that voltage. Both lower and higher could be bad. At best, with lower voltage the device will not operate correctly in a obvious way. However, some devices might appear to operate correctly, then fail in unexpected ways un...
https://api.stackexchange.com
I have a FASTA file: > Sequence_1 GCAATGCAAGGAAGTGATGGCGGAAATAGCGTTAGATGTATGTGTAGCGGTCCC... > Sequence_2 GCAATGCAAGGAAGTGATGGCGGAAATAGCGTTAGATGTATGTGTAGCGGTCCC.... .... I want to generate a BED file for each sequence like: Sequence_1 0 1500 Sequence_2 0 1700 The BED regions will simply be the size of the sequences. Q...
You can do this easily with bioawk, which is a version of awk with added features facilitating bioinformatics: bioawk -c fastx '{print $name"\t0\t"length($seq)}' test.fa -c fastx tells the program that the data should be parsed as fasta or fastq format. This makes the $name and $seq variables available in the awk comm...
https://api.stackexchange.com
Especially when drinking water after the fact, mint can give a sharp cold sensation inside one's mouth. What process causes the sensation to occur?
Menthol it self gives a cold feeling in the mouth because it is active at the same receptor (an ion channel) on the tongue that cold temperature triggers. Interestingly, although they act at the same receptor, they act at different sites, so that provides the intensified response when eating a mint and then drinking wa...
https://api.stackexchange.com
When treated with hot, concentrated acidic $\ce{KMnO4}$, arenes are oxidised to the corresponding carboxylic acids. For example, toluene is oxidised to benzoic acid. I've tried to examine how this happens, using the mechanism of oxidation of double bonds via cyclic intermediate as a reference, but I can't manage to coo...
Some general information on side-chain oxidation in alkylbenzenes is available at Chemguide: An alkylbenzene is simply a benzene ring with an alkyl group attached to it. Methylbenzene is the simplest alkylbenzene. Alkyl groups are usually fairly resistant to oxidation. However, when they are attached to a benzene ri...
https://api.stackexchange.com
It's a hilarious witty joke that points out how every base is '$10$' in its base. Like, \begin{align} 2 &= 10\ \text{(base 2)} \\ 8 &= 10\ \text{(base 8)} \end{align} My question is if whoever invented the decimal system had chosen $9$ numbers or $11$, or whatever, would this still be applicable? I am confused ...
Short answer: your confusion about whether ten is special may come from reading aloud "Every base is base 10" as "Every base is base ten" — this is wrong; not every base is base ten, only base ten is base ten. It is a joke that works better in writing. If you want to read it aloud, you should read it as "Every base is ...
https://api.stackexchange.com
I'm developing neural networks comprised of just 3 to 10 layers of virtual neurons and I'm curious to know if there are any insect brains out there with fewer than a thousand neurons? Are there any tiny creatures with small numbers of neurons? Do neuronal maps exist for those simple nervous systems?
Short answer As far as I know, a complete neural map (a connectome) is only available for the roundworm C. elegens, a nematode with only 302 neurons (fig. 1). Fig. 1. C. elegans (left, size: ~1 mm) and connectome of C. elegans (right). sources: Utrecht University & Farber (2012) Background Looking at the least complex...
https://api.stackexchange.com
The following is a quote from Surely you're joking, Mr. Feynman. The question is: are there any interesting theorems that you think would be a good example to tell Richard Feynman, as an answer to his challenge? Theorems should be totally counter-intuitive, and be easily translatable to everyday language. (Apparentl...
Every simple closed curve that you can draw by hand will pass through the corners of some square. The question was asked by Toeplitz in 1911, and has only been partially answered in 1989 by Stromquist. As of now, the answer is only known to be positive, for the curves that can be drawn by hand. (i.e. the curves that ...
https://api.stackexchange.com
I was discussing with a colleague about using dark-mode vs. light mode and remembered an article arguing that humans vision is more adapted to light-mode rather than dark-mode: I know that the trend “du jour” is to have a dark mode for pretty much everything, but look around the world is not dark with a bit of light, ...
A question that requires quite a lot of guts to ask on this site :) Nonetheless, and risking sparking a debate, there are a few arguments that spring to (my!) mind that can support the notion that we thrive better in 'day mode' (i.e., photopic conditions). To start with a controversial assumption, humans are diurnal a...
https://api.stackexchange.com
It is well known that when you add salt to ice, the ice not only melts but will actually get colder. From chemistry books, I've learned that salt will lower the freezing point of water. But I’m a little confused as to why it results in a drop in temperature instead of just ending up with water at 0 °C. What is occurrin...
When you add salt to an ice cube, you end up with an ice cube whose temperature is above its melting point. This ice cube will do what any ice cube above its melting point will do: it will melt. As it melts, it cools down, since energy is being used to break bonds in the solid state. (Note that the above point can be c...
https://api.stackexchange.com
I'm trying to implement various binarization algorithms to the image shown: Here's the code: clc; clear; x=imread('n2.jpg'); %load original image % Now we resize the images so that computational work becomes easier later onwards for us. size(x); x=imresize(x,[500 800]); figure; imshow(x); title('original ima...
Your image doesn't have uniform brightness,so you shouldn't work with a uniform threshold. You need an adaptive threshold. This can be implemented by preprocessing the image to make the brightness more uniform across the image (code written in Mathematica, you'll have to implement the Matlab version for yourself): A si...
https://api.stackexchange.com
I have heard anecdotaly that sampling complex signals need not follow Nyquist sampling rates but can actually be gotten away with half Nyquist sampling rates. I am wondering if there is any truth to this? From Nyquist, we know that to unambiguously sample a signal, we need to sample at least higher than double the band...
Your understanding is correct. If you sample at rate $f_s$, then with real samples only, you can unambiguously represent frequency content in the region $[0, \frac{f_s}{2})$ (although the caveat that allows bandpass sampling still applies). No additional information can be held in the other half of the spectrum when th...
https://api.stackexchange.com
I have looked at other questions on this site (e.g. "why does space expansion affect matter") but can't find the answer I am looking for. So here is my question: One often hears talk of space expanding when we talk about the speed of galaxies relative to ours. Why, if space is expanding, does matter not also expand? If...
Let's talk about the balloon first because it provides a pretty good model for the expanding universe. It's true that if you draw a big circle then it will quickly expand as you blow into the balloon. Actually, the apparent speed with which two of the points on the circle in a distance $D$ of each other would move rela...
https://api.stackexchange.com
I have a PyMol session file I was using to create my figures. It contains a protein and ligand broken into several groups of atoms with a fair bit of overlap. There are also a few meshes built from a density map for a few figures. Unfortunately, I wasn't quite done with refinement, and now Refmac has given me shiny n...
Until someone identifies an ‘update’ function in PyMol, I think the next best thing is to use scripting. (See the pymol wiki) It is an imperfect solution, but it may work for the situation presented in the original post if the session may be reproduced. To begin capturing the commands in PyMol, including menu selection...
https://api.stackexchange.com
I cook frequently with aluminum foil as a cover in the oven. When it's time to remove the foil and cook uncovered, I find I can handle it with my bare hands, and it's barely warm. What are the physics for this? Does it have something to do with the thickness and storing energy?
You get burned because energy is transferred from the hot object to your hand until they are both at the same temperature. The more energy transferred, the more damage done to you. Aluminium, like most metals, has a lower heat capacity than water (ie you) so transferring a small amount of energy lowers the temperature ...
https://api.stackexchange.com
Does DNA have anything like IF-statements, GOTO-jumps, or WHILE loops? In software development, these constructs have the following functions: IF-statements: An IF statement executes the code in a subsequent code block if some specific condition is met. WHILE-loops: The code in a subsequent code block is executes as m...
Biological examples similar to programming statements: IF : Transcriptional activator; when present a gene will be transcribed. In general there is no termination of events unless the signal is gone; the program ends only with the death of the cell. So the IF statement is always a part of a loop. WHILE : Transcription...
https://api.stackexchange.com
Joris and Srikant/user28's exchange here got me wondering (again) if my internal explanations for the difference between confidence intervals and credible intervals were the correct ones. How you would explain the difference?
I agree completely with Srikant's explanation. To give a more heuristic spin on it: Classical approaches generally posit that the world is one way (e.g., a parameter has one particular true value), and try to conduct experiments whose resulting conclusion -- no matter the true value of the parameter -- will be correct ...
https://api.stackexchange.com
With social-distancing measures being implemented in many countries I would expect other viruses, like the ones that cause seasonal flus, to have also a hard time propagating in these circumstances. Are there any estimates or research (epidemiological models) I can check, about the possibility we are winning by acciden...
Yes, this helps as well with other infectious diseases. A good example is the flu, which season was measurably shorter this year than in other years on record. See the figure from the reference 1 for comparision: Reference 2 shows that this is also true for other respiratory diseases (figure 2): This shows very well ...
https://api.stackexchange.com
I'm by no means an expert in the field, merely a curious visitor, but I've been thinking about this and Google isn't of much help. Do we know of any lifeforms that don't have the conventional double-helix DNA as we know it? Have any serious alternatives been theorized?
To follow up what mbq said, there have been a number of "origin of life" studies which suggest that RNA was a precursor to DNA, the so-called "RNA world" (1). Since RNA can carry out both roles which DNA and proteins perform today. Further speculations suggest things like a Peptide-Nucleic Acids "PNA" may have preced...
https://api.stackexchange.com
Apologies in advance for the naivety of this question. I am a 50 year old artist trying to properly understand computers really for the first time. So here goes. I have been trying to understand how data types and variables are handled by a compiler (in a very general sense, I know there is a lot to it). I'm missing so...
Storing local variables on a stack is an implementation detail – basically an optimization. You can think of it this way. When entering a function, space for all local variables is allocated somewhere. You can then access all variables, since you know their location somehow (this is part of the process of allocation). ...
https://api.stackexchange.com
How can the gravitational n-body problem be solved numerically in parallel? Is precision-complexity tradeoff possible? How does precision influence the quality of the model?
There is a wide variety of algorithms; Barnes Hut is a popular $\mathcal{O}(N \log N)$ method, and the Fast Multipole Method is a much more sophisticated $\mathcal{O}(N)$ alternative. Both methods make use of a tree data structure where nodes essentially only interact with their nearest neighbors at each level of the ...
https://api.stackexchange.com
Most modern day Cathode Ray Tube (CRT) televisions manufactured after the 1960s (after the introduction of NTSC and PAL standards) supported the circuit-based decoding of colored signals. It is well known that the new color standards was created to permit the new TV sets to be backwards compatible with old black and wh...
The color burst is also an indicator that there is a color signal. This is for compatibility with black and white signals. No color burst means B&W signal, so only decode the luminance signal (no croma). No signal, no color burst, so the decoder falls back to B&W mode. Same idea goes to FM stereo/mono. If there is no 1...
https://api.stackexchange.com
I'm going to start developing a USB 1.1 device using a PIC microcontroller. I'm going to keep one of the USB ports of my PC connected to a bread board during this process. I don't want to destroy my PC's USB port by a short circuit or connecting \$\pm\$Data lines to each other or a power line accidentally. How can I pr...
This is to expand on Leon's suggestion to use a hub. The USB hubs are not all created equal. Unofficially, there are several "grades": Cheap hubs. These are cost optimized to the point where they don't adhere to the USB spec any more. Often, the +5V lines of the downstream ports are wired directly to the computer. ...
https://api.stackexchange.com
I think this is a fairly common observation that if one does some significant amount of exercise, he/she may feel alright for the rest of the day, but it generally hurts bad the next day. Why is this the case? I would expect that if the muscles have undergone significant strain (say I started pushups/plank today), the...
Unlike the conventional wisdom, the pain you feel the next day (after a strenuous exercise) has nothing to do with lactic acid. Actually, lactic acid is rapidly removed from the muscle cell and converted to other substances in the liver (see Cori cycle). If you start to feel your muscles "burning" during exercise (due...
https://api.stackexchange.com
On many boards I've seen, there are little copper dots used for the purpose of "Copper Thieving". They're small round copper dots connected to nothing and arranged in an array. Supposedly they're for balancing the copper on the boards to improve manufacturability, but no explanation I've heard has convinced me that the...
Unfortunately the other 3 answers to the question are incorrect, but helps keeping a common misunderstanding alive :-) Thieving is added to the outer layers in order to help a more balanced chemical process for the plating. Also notice that there is no need to "balance copper" (or stackups for that matter) in modern P...
https://api.stackexchange.com
It's very easy to filter a signal by performing an FFT on it, zeroing out some of the bins, and then performing an IFFT. For instance: t = linspace(0, 1, 256, endpoint=False) x = sin(2 * pi * 3 * t) + cos(2 * pi * 100 * t) X = fft(x) X[64:192] = 0 y = ifft(X) The high frequency component is completely removed by this...
Zeroing bins in the frequency domain is the same as multiplying by a rectangular window in the frequency domain. Multiplying by a window in the frequency domain is the same as circular convolution by the transform of that window in the time domain. The transform of a rectangular window is the Sinc function ($\sin(\om...
https://api.stackexchange.com
I searched and couldn't find it on the site, so here it is (quoted to the letter): On this infinite grid of ideal one-ohm resistors, what's the equivalent resistance between the two marked nodes? With a link to the source. I'm not really sure if there is an answer for this question. However, given my lack of experti...
This is the XKCD Nerd Sniping problem. It forced me to abandon everything else I was doing to research and write up this answer. Then, years later, it compelled me to return and edit it for clarity. The following full solution is based on the links posted in the other answer. But in addition to presenting this informat...
https://api.stackexchange.com
I was just wondering whether or not there have been mistakes in mathematics. Not a conjecture that ended up being false, but a theorem which had a proof that was accepted for a nontrivial amount of time before someone found a hole in the argument. Does this happen anymore now that we have computers? I imagine not. But ...
In 1933, Kurt Gödel showed that the class called $\lbrack\exists^*\forall^2\exists^*, {\mathrm{all}}, (0)\rbrack$ was decidable. These are the formulas that begin with $\exists a\exists b\ldots \exists m\forall n\forall p\exists q\ldots\exists z$, with exactly two $\forall$ quantifiers, with no intervening $\exists$s....
https://api.stackexchange.com
I am running linear regression models and wondering what the conditions are for removing the intercept term. In comparing results from two different regressions where one has the intercept and the other does not, I notice that the $R^2$ of the function without the intercept is much higher. Are there certain conditions...
The shortest answer: never, unless you are sure that your linear approximation of the data generating process (linear regression model) either by some theoretical or any other reasons is forced to go through the origin. If not the other regression parameters will be biased even if intercept is statistically insignifica...
https://api.stackexchange.com
Complex numbers involve the square root of negative one, and most non-mathematicians find it hard to accept that such a number is meaningful. In contrast, they feel that real numbers have an obvious and intuitive meaning. What's the best way to explain to a non-mathematician that complex numbers are necessary and meani...
There are a few good answers to this question, depending on the audience. I've used all of these on occasion. A way to solve polynomials We came up with equations like $x - 5 = 0$, what is $x$?, and the naturals solved them (easily). Then we asked, "wait, what about $x + 5 = 0$?" So we invented negative numbers. Then w...
https://api.stackexchange.com
Searched high and low and have not been able to find out what AUC, as in related to prediction, stands for or means.
Abbreviations AUC = Area Under the Curve. AUROC = Area Under the Receiver Operating Characteristic curve. AUC is used most of the time to mean AUROC, which is a bad practice since as Marc Claesen pointed out AUC is ambiguous (could be any curve) while AUROC is not. Interpreting the AUROC The AUROC has several equiv...
https://api.stackexchange.com
I am looking to design a set of FIR filters to implement a low pass filter. I am also trying to reduce the latency of the signal through the filter so I am wondering what the minimum number of taps I can use might be. I know that more taps can lead to a sharper cutoff of the frequency and better stop band rejection etc...
Citing Bellanger's classic Digital Processing of Signals – Theory and Practice, the point is not where your cut-off frequency is, but how much attenuation you need, how much ripple in the signal you want to preserve you can tolerate and, most importantly, how narrow your transition from pass- to stopband (transition wi...
https://api.stackexchange.com
Now I have been learning chemistry for five years. I remember when I started organic chemistry, it was fun to draw arrows between molecules to show, as if in a mathematical demonstration, how the reactions occurred. In every lesson I had, teachers explained to us how a specific reaction (for example the Shapiro reactio...
Great question! When I was teaching, Anslyn and Dougherty was a decent text for this. Here are some general comments: First, please note that you cannot be sure about a mechanism. That's the real killer. You can devise experiments that are consistent with the mechanism but because you cannot devise and run all possibl...
https://api.stackexchange.com
In my math lectures, we talked about the Gram-Determinant where a matrix times its transpose are multiplied together. Is $A A^\mathrm T$ something special for any matrix $A$?
The main thing is presumably that $AA^T$ is symmetric. Indeed $(AA^T)^T=(A^T)^TA^T=AA^T$. For symmetric matrices one has the Spectral Theorem which says that we have a basis of eigenvectors and every eigenvalue is real. Moreover if $A$ is invertible, then $AA^T$ is also positive definite, since $$x^TAA^Tx=(A^Tx)^T(A^Tx...
https://api.stackexchange.com
I vaguely remember, that the original plan of Oxford Nanopore was to provide cheap sequencers (MinION), but charge for base-calling. For that reason the base-calling was performed in the cloud, and the plan was to make it commercial once the technology is established. Of course, this limits the potential uses of MinION...
Short answer: yes, but you need to get permission (and modified software) from ONT before doing that. ... but that doesn't tell the whole story. This question has the potential to be very confusing, and that's through no fault of the questioner. The issue is that for the MinION, sequencing (or more specifically, genera...
https://api.stackexchange.com
I would like to run some simple simulations of scattering of wavepackets off of simple potentials in one dimension. Are there simple ways to numerically solve the one-dimensional TDSE for a single particle? I know that, in general, trying to use naïve approaches to integrate partial differential equations can quickly e...
In the early 90s we were looking for a method to solve the TDSE fast enough to do animations in real time on a PC and came across a surprisingly simple, stable, explicit method described by PB Visscher in Computers in Physics: "A fast explicit algorithm for the time-dependent Schrödinger equation". Visscher notes that...
https://api.stackexchange.com
I read some methods but they're not accurate. They use the Archimedes principle and they assume uniform body density which of course is far from true. Others are silly like this one: Take a knife then remove your head. Place it on some scale Take the reading re-attach your head. I'm looking for some ingenious way of do...
Get someone to relax their neck as much as possible, stabilize their torso, then punch them in the head with a calibrated fist and measure the initial acceleration. Apply $\vec F=m \vec a$.
https://api.stackexchange.com
In these notes by Terence Tao is a proof of Stirling's formula. I really like most of it, but at a crucial step he uses the integral identity $$n! = \int_{0}^{\infty} t^n e^{-t} dt$$ , coming from the Gamma function. I have a mathematical confession to make: I have never "grokked" this identity. Why should I expect...
I haven't quite got this straight yet, but I think one way to go is to think about choosing points at random from the positive reals. This answer is going to be rather longer than it really needs to be, because I'm thinking about this in a few (closely related) ways, which probably aren't all necessary, and you can dec...
https://api.stackexchange.com
I have a reference genome and now I would like to call structural variants from Illumina pair-end whole genome resequencing data (insert size 700bp). There are many tools for SV calls (I made an incomplete list of tools bellow). There is also a tool for merging SV calls from multiple methods / samples - SURVIVOR. Is t...
I think the best method or combination of methods will depend on aspects of the data that might vary from one dataset to another. E.g. the type, size, and frequency of structural variants, the number SNVs, the quality of the reference, contaminants or other issues (e.g. read quality, sequencing errors) etc. For that re...
https://api.stackexchange.com
Among my friends it is a sort of 'common wisdom' that you should throw away water after a couple of days if it was taken from the tap and stored in a bottle outside the fridge, because it has 'gone bad'. First of all, the couple of days is not very well defined, which already makes me a bit suspicious. Second, I cannot...
First of all, it depends on how the tap water was treated before it was piped to your house. In most cases, the water was chlorinated to remove microorganisms. By the time the water arrives at your house, there is very little (if any) chlorine left in the water. When you fill you container, there is likely to be some m...
https://api.stackexchange.com
If I have sampled a signal using proper sampling methods (Nyquist, filtering, etc) how do I relate the length of my FFT to the resulting frequency resolution I can obtain? Like if I have a 2,000 Hz and 1,999 Hz sine wave, how would I determine the length of FFT needed to accurately tell the difference between those two...
The frequency resolution is dependent on the relationship between the FFT length and the sampling rate of the input signal. If we collect 8192 samples for the FFT then we will have: $$\frac{8192\ \text{samples}}{2} = 4096\ \,\text{FFT bins}$$ If our sampling rate is 10 kHz, then the Nyquist-Shannon sampling theorem say...
https://api.stackexchange.com
After some google searches, I found multiple tools with overlapping functionality for viewing, merging, pileuping, etc. I have not got time to try these tools, so will just see if anyone already know the answer: what is the difference between them? Performance? Features? Or something else? Which one is generally prefer...
The obvious answer is that different people wrote them. It's fairly common in bioinformatics for people with a computer science background to get frustrated with existing tools and create their own alternative tool (rather than improving an existing tool). Over time, tools with similar initial aims will have popular fu...
https://api.stackexchange.com
I've been using the $K$-fold cross-validation a few times now to evaluate performance of some learning algorithms, but I've always been puzzled as to how I should choose the value of $K$. I've often seen and used a value of $K = 10$, but this seems totally arbitrary to me, and I now just use $10$ by habit instead of th...
The choice of $k = 10$ is somewhat arbitrary. Here's how I decide $k$: first of all, in order to lower the variance of the CV result, you can and should repeat/iterate the CV with new random splits. This makes the argument of high $k$ => more computation time largely irrelevant, as you anyways want to calculate many ...
https://api.stackexchange.com
Are all Morse code strings uniquely decipherable? Without the spaces, ......-...-..---.-----.-..-..-.. could be Hello World but perhaps the first letter is a 5 -- in fact it looks very unlikely an arbitrary sequence of dots and dashes should have a unique translation. One might possibly use the Kraft inequality but...
The following are both plausible messages, but have a completely different meaning: SOS HELP = ...---... .... . .-.. .--. => ...---.........-...--. I AM HIS DATE = .. .- -- .... .. ... -.. .- - . => ...---.........-...--.
https://api.stackexchange.com
It is known that acid should be added to water and not the opposite because it results in an exothermic reaction. Our stomach contains HCl, so why don't we explode when we drink water?
The hydrochloric acid in the stomach is already quite dilute; its pH is in fact no less than 1.5 so that at the extreme maximum there is only 0.03 molar hydrochloric acid. And even that small amount is, of course, stabilized by being dissociated into solvated ions. There is just not enough stuff to react violently.
https://api.stackexchange.com
Every scientist needs to know a bit about statistics: what correlation means, what a confidence interval is, and so on. Similarly, every scientist ought to know a bit about computing: the question is, what? What it is reasonable to expect every working scientist to know about building and using software? Our list of co...
"Computational Scientist" is somewhat broad because it includes people who doing numerical analysis with paper/LaTeX and proof-of-concept implementations, people writing general purpose libraries, and people developing applications that solve certain classes of problems, and end users that utilize those applications. T...
https://api.stackexchange.com
We know the halting problem (on Turing Machines) is undecidable for Turing Machines. Is there some research into how well the human mind can deal with this problem, possibly aided by Turing Machines or general purpose computers? Note: Obviously, in the strictest sense, you can always say no, because there are Turing Ma...
It is very hard to define a human mind with a such mathematical rigor as it is possible to define a Turing machine. We still do not have a working model of a mouse brain however we have the hardware capable of simulating it. A mouse has around 4 million neurons in the cerebral cortex. A human being has 80-120 billion n...
https://api.stackexchange.com
I have been looking into C++ linear algebra libraries for a project I've been working on. Something that I still don't have any grasp on is the connection of BLAS and LAPACK to other linear algebra libraries. Looking through this article on linear algebra libraries I found it interesting that: some libraries are indep...
As far as I know, Lapack is the only publicly available implementation of a number of algorithms (nonsymmetric dense eigensolver, pseudo-quadratic time symmetric eigensolver, fast Jacobi SVD). Most libraries that don't rely on BLAS+Lapack tend to support very primitive operations like matrix multiplication, LU factoriz...
https://api.stackexchange.com
After my online research on the subject, I learnt that, biologically speaking, many scientists believe that there is no such thing as a race. Homo sapiens as a species is only 200,000 years old, which has not allowed for any significant genetic diversification yet, and our DNA is 99.99% similar. I've read statements th...
Firstly, it's not true that you can't tell racial background from DNA. You most certainly can; it's quite possible to give fairly accurate phenotypic reconstruction of the features we choose as racial markers from DNA samples alone and also possible to identify real geographic ancestral populations from suitable marker...
https://api.stackexchange.com
I have two annotations of the same genome generated with different annotation pipelines. I want to identify overlapping gene models. An important feature of this genome is that there are many 'genes within genes', i.e. a genemodel in the intron of another genemodel. Therefore, I only want to count two genemodels as ov...
Short Answer: In my opinion, my approach would be to pull out the CDS exons and run bedtools on those. A Few More Details: When you pull out the exons, make sure that you assign them all IDs if the don't already have them assigned and record which IDs "belong" to which genes. Now when you get exons that overlap, you ...
https://api.stackexchange.com
Polytetrafluoroethylene was discovered by accident. It now is an important material in the industry mainly because of its extremely high bonding energy, which prevents corrosion, halts reaction, and reduces friction (yeah carbon-fluorine bonds!) And people would have definitely put it to the test, making it contain som...
Corrosion Resistant Products, Ltd., with the help of Dupont, has established this source of information on what can and cannot eat teflon. Here's a list: Sodium and potassium metal - these reduce and defluorinate PTFE, which finds use in etching PTFE Finely divided metal powders, like aluminum and and magnesium, cause...
https://api.stackexchange.com
I am looking for books or articles, or blog-posts, or any published material in general, that address specifically the uses of C++ modern features (move semantics, the STL, iterators, lazy evaluation, etc.) in scientific computing. Can you suggest any? I think that these new features will make it easier to write effici...
Two examples of libraries that use modern C++ constructs: Both the eigen and armadillo libraries (linear algebra) use several modern C++ constructs. For instance, they use both expression templates to simplify arithmetic expressions and can sometimes eliminate some temporaries: (presentation on expression templ...
https://api.stackexchange.com
According to this famous blog post, the effective transcript length is: $\tilde{l}_i = l_i - \mu$ where $l_i$ is the length of transcript and $\mu$ is the average fragment length. However, typically fragment length is about 300bp. What if when the transcript $l_i$ is smaller than 300? How do you compute the effective l...
The effective length is $\tilde{l}_i = l_i - \mu + 1$ (note the R code at the bottom of Harold's blog post), which in the case of $\mu < l_i$ should be 1. Ideally, you'd use the mean fragment length mapped to the particular feature, rather than a global $\mu$, but that's a lot more work for likely 0 benefit. Regarding ...
https://api.stackexchange.com
I'm all bent out of shape trying to figure out what Bent's rule means. I have several formulations of it, and the most common formulation is also the hardest to understand. Atomic s character concentrates in orbitals directed toward electropositive substituents Why would this be true? Consider $\ce{H3CF}$. Both the...
That's a good, concise statement of Bent's rule. Of course we could have just as correctly said that p character tends to concentrate in orbitals directed at electronegative elements. We'll use this latter phrasing when we examine methyl fluoride below. But first, let's expand on the definition a bit so that it is cle...
https://api.stackexchange.com
When carbon-14 decays, the decay products are nitrogen-14 and an electron (and an electron antineutrino, but that's chemically irrelevant*): $$\ce{^14_6C -> ^14_7N + e- + \overline{v_e}}$$ Let's assume that the carbon atom in question is part of a carbon dioxide molecule in the atmosphere. What would happen to the mole...
An article by Snell and Pleasanton, 'The Atomic and Molecular Consequenses of Radioactive Decay', (J. Phys. Chem., 62 (11), pp 1377–1382, $1958$) supports Ben Norris's comment. It is clear ... that $\ce{^{14}CO2}$ remains predominantly bound as $\ce{NO2+}$, a result that is perhaps not surprising. [This occurs in] $81...
https://api.stackexchange.com
I am looking for the fastest available algorithm for distance transform. According to Image Processing Learning Resources - HIPR 2 (HYPERMEDIA IMAGE PROCESSING REFERENCE) - Morphology - Distance Transform: The distance transform can be calculated much more efficiently using clever algorithms in only two passes (e.g. R...
Pedro F. Felzenszwalb and Daniel P. Huttenlocher have published their implementation for the distance transform [archive]. You cannot use it for volumetric images, but maybe you can extend it to support 3d data. I have only used it as a black box.
https://api.stackexchange.com
In today's pattern recognition class my professor talked about PCA, eigenvectors and eigenvalues. I understood the mathematics of it. If I'm asked to find eigenvalues etc. I'll do it correctly like a machine. But I didn't understand it. I didn't get the purpose of it. I didn't get the feel of it. I strongly beli...
Imagine a big family dinner where everybody starts asking you about PCA. First, you explain it to your great-grandmother; then to your grandmother; then to your mother; then to your spouse; finally, to your daughter (a mathematician). Each time the next person is less of a layman. Here is how the conversation might go....
https://api.stackexchange.com
MIT has been making a bit of noise lately about a new algorithm that is touted as a faster Fourier transform that works on particular kinds of signals, for instance: "Faster Fourier transform named one of world’s most important emerging technologies". The MIT Technology Review magazine says: With the new algorithm, ca...
The idea of the algorithm is this: assume you have a length $N$ signal that is sparse in the frequency domain. This means that if you were to calculate its discrete Fourier transform, there would be a small number of outputs $k \ll N$ that are nonzero; the other $N-k$ are negligible. One way of getting at the $k$ outpu...
https://api.stackexchange.com
To be clear, I'm not doubting that Homo sapiens and Homo neanderthalensis did interbreed: of that much I'm convinced. Within the past few years I've seen an upcropping of pop-sci articles discussing the interbreeding between pre-historic species of humans. In everything that I see in these articles, as well as in scien...
Short answer The concept of species is poorly defined and is often misleading. The concepts of lineage and clade / monophyletic group are much more helpful. IMO, the only usefulness of this poorly defined concept that is the "species" is to have a common vocabulary for naming lineages. Note that Homo neanderthalis is s...
https://api.stackexchange.com
I am trying to understand the difference between convolution to cross-correlation. I have read an understood This answer. I also understand the picture below. But, in terms of signal processing, (a field which I know little about..), Given two signals (or maybe a signal and a filter?), When will we use convolution and...
In signal processing, two problems are common: What is the output of this filter when its input is $x(t)$? The answer is given by $x(t)\ast h(t)$, where $h(t)$ is a signal called the "impulse response" of the filter, and $\ast$ is the convolution operation. Given a noisy signal $y(t)$, is the signal $x(t)$ somehow pre...
https://api.stackexchange.com
I wonder if it is possible to build compilers for dynamic languages like Ruby to have similar and comparable performance to C/C++? From what I understand about compilers, take Ruby for instance, compiling Ruby code can't ever be efficient because the way Ruby handles reflection, features such as automatic type conversi...
To all those who said “yes” I’ll offer a counter-point that the answer is “no”, by design. Those languages will never be able to match the performance of statically compiled languages. Kos offered the (very valid) point that dynamic languages have more information about the system at runtime which can be used to optimi...
https://api.stackexchange.com
When I close one eye and put the tip of my finger near my open eye, it seems as if the light from the background image bends around my finger slightly, warping the image near the edges of my blurry fingertip. What causes this? Is it the heat from my finger that bends the light? Or the minuscule gravity that the mass in...
OK, it seems that user21820 is right; this effect is caused by both the foreground and the background objects being out of focus, and occurs in areas where the foreground object (your finger) partially occludes the background, so that only some of the light rays reaching your eye from the background are blocked by the ...
https://api.stackexchange.com
I do component-level repair of tablet mainboards, and I have seen this puzzling situation on two different models of Samsung tablet mainboards so far (SM-T210, SM-T818A). There are ceramic chip capacitors on the PCB that are clearly connected to the ground plane on both ends. Resistance checks confirm, plus it's pre...
There are four comments on this reddit thread that may be on to something: By silver_pc: could it be a form of 'paper towns' on maps - AKA fictitious entry to identify direct copies? By toybuilder: Not that they are necessarily doing this, but I've heard it said that mass manufacturers will keep removing capacitors ...
https://api.stackexchange.com
I don't understand the different behaviour of the advection-diffusion equation when I apply different boundary conditions. My motivation is the simulation of a real physical quantity (particle density) under diffusion and advection. Particle density should be conserved in the interior unless it flows out from the edges...
I think that one of your problems is that (as you observed in your comments) Neumann conditions are not the conditions you are looking for, in the sense that they do not imply the conservation of your quantity. To find the correct condition, rewrite your PDE as $$ \frac{\partial \phi}{\partial t} = \frac{\partial}{\par...
https://api.stackexchange.com
We often see component values of 4.7K Ohm, 470uF, or 0.47uH. For example, digikey has millions of 4.7uF ceramic capacitors, and not a single 4.8uF or 4.6uF and only 1 listed for 4.5uF (specialty product). What's so special about the value 4.7 that sets so far apart from say 4.6 or 4.8 or even 4.4 since in the 3.. seri...
Due to resistor colour-coding bands on leaded components two-significant digits were preferred and I reckon this graph speaks for itself: - These are the 13 resistors that span 10 to 100 in the old 10% series and they are 10, 12, 15, 18, 22, 27, 33, 39, 47, 56, 68, 82, 100. I've plotted the resistor number (1 to 13) a...
https://api.stackexchange.com
I am trying to teach myself more about image compression using the wavelet transform method. What is it about certain wavelets that make them preferable when compressing images? Are they easier to compute? Do they produce smoother images? Example: JPEG 2000 uses the Cohen-Daubechies-Feauveau 9/7 Wavelet. Why this one...
Overview The short answer is that they have the maximum number of vanishing moments for a given support (i.e number of filter coefficients). That's the "extremal" property which distinguishes Daubechies wavelets in general. Loosely speaking, more vanishing moments implies better compression, and smaller support implies...
https://api.stackexchange.com
I am currently finishing my MSc in computer science. I am interested in programming languages, especially in type systems. I got interested in research in this field and next semester I will start a PhD on the subject. Now here is the real question: how can I explain what I (want to) do to people with no previous knowl...
If you have a few minutes, most people know how to add and multiply two three-digit numbers on paper. Ask them to do that, (or to admit that they could, if they had to) and ask them to acknowledge that they do this task methodically: if this number is greater than 9, then add a carry, and so forth. This description the...
https://api.stackexchange.com
Having recently constructed a lot of phylogenetic trees with the module TreeConstruction from Phylo package from Biopython, I've been asked to replace the branch tip labels by the corresponding sequence logos (which I have in the same folder). I thought that it would be more efficient to make a code to generate the log...
To expand on my comment from yesterday. You could do this with the ETE Toolkit (I just copied one logo file rather than converting all 26 to png): from ete3 import Tree, TreeStyle, faces def mylayout(node): if node.is_leaf(): logo_face = faces.ImgFace(str.split(node.name, '.')[0] + ".png") # this doesn't se...
https://api.stackexchange.com
How are computers able to tell the correct time and date every time? Whenever I close the computer (shut it down) all connections and processes inside stop. How is it that when I open the computer again it tells the exact correct time? Does the computer not shut down completely when I shut it down? Are there some proc...
Computers have a "real-time clock" -- a special hardware device (e.g., containing a quartz crystal) on the motherboard that maintains the time. It is always powered, even when you shut your computer off. Also, the motherboard has a small battery that is used to power the clock device even when you disconnect your com...
https://api.stackexchange.com
In a standard algorithms course we are taught that quicksort is $O(n \log n)$ on average and $O(n^2)$ in the worst case. At the same time, other sorting algorithms are studied which are $O(n \log n)$ in the worst case (like mergesort and heapsort), and even linear time in the best case (like bubblesort) but with some a...
Short Answer The cache efficiency argument has already been explained in detail. In addition, there is an intrinsic argument, why Quicksort is fast. If implemented like with two “crossing pointers”, e.g. here, the inner loops have a very small body. As this is the code executed most often, this pays off. Long Answer Fi...
https://api.stackexchange.com