Losing power steering fluid 2011 Honda Accord 4cyl

Question: Car is losing power steering fluid very slowly. Months go by before it needs to be topped of again. No apparent leak, no noise, no foam in fluid.
Answer: There's a leak there somewhere - there are only two places where power steering fluid can go: where it's supposed to go, and where it's not. "Not" means outside of everything, onto the ground & into the air. There aren't any places where it can leak into any other fluid reservoir in the vehicle.
Answer: On a very small fluid loss the first thing is too tighten any hose clips or unions. These can allow the fluid to 'sweat' out of the system. Any clips that show any sign of oil around them require critical attention as the hose at the joining may be starting to perish internally.
Comment: Thanks. My main concern is the possibility that the steering rack has a leak which I believe usually means replacing the entire rack. Would no air bubbles getting into the fluid rule out a leak in the rack?
Answer: Check inside the boots on your steering rack. With your vehicle properly supported on jack stands, remove the wheels and take a pair of pliers and squeeze the clamps on the outer collar of the inner tie rod boots on the rack and slide a small pocket screwdriver or something similar CAREFULLY between the tie rod and the boot collar to see if there is any fluid residue inside the boot. There should be none at all. If there is any amount of fluid the outer seals are leaking and should be replaced. It should be dry or very close to it inside the boots. The seals can be replaced without changing the rack (I have done it myself) but you will be hard pressed to find a mechanic that will do that because it's faster to just change the rack.
Comment: Actually, the reason why mechanics won't repair the rack is due to the safety risks. If somebody does an improper repair and the car suddenly violently turns to the direction of the oncoming traffic, a serious accident could happen and whoever did the improper repair could be liable to pay millions. Thus, the usual solution is to replace the rack with a junkyard part (assuming the car is old and no new parts are being made), which will usually fail within a year or so because such junkyard parts have old rubber seals too.


Does MSAA make sense in audio / 1d data streams?

Question: In graphics, MSAA is a technique where  you take multiple samples of something per pixel and then average the values to get the final pixel value. The image quality improves as a result, and its considered a form of anti aliasing.  Does this technique have an equivalent in audio samples or other 1d data streams?
Comment: And er... I guess a box car filter might be similar but not sure if there's a deeper answer than that :p
Comment: Why do you consider audio as a 1D stream? That is just one representation. The STFT representation is equally valid, and a 2D stream.
Answer: No. The reason is that MSAA works in the visual domain. Optically, we have hardwired edge detectors. MSAA eliminates unintended edges in generated images.
Acoustically, we do not have such edge detectors, and therefore there's no reason to remove them. Also, loudspeakers already filter out such edges mechanically.
Answer: Oversampling of audio can be used to reduce aliasing artifacts that result from non-linear processing. Harmonics generated by the nonlinear process can be filtered from the oversampled signal by a lowpass filter. A graphics analog of this is supersampling. If Wikipedia is to trust, multi-sample antialiasing is a further optimization in which only the mixing proportion of background and foreground is calculated at each edge pixel of the foreground object, using supersampling.
An analogous audio problem would be implementation of amplitude modulation by a square wave. Hearing is more sensitive to frequency domain errors than vision, which operates more in the spatial domain. Linear cross-fading at the sample point nearest to each square wave edge would create a beating artifact that for each overtone would have an amplitude proportional to its amplitude and squared frequency. For a high-enough fundamental frequency of the square wave, the artifact would be audible, demanding the use of another method with better frequency domain behavior.


Inside the Photon sphere of a black hole

Question: A photon sphere is defined as the innermost orbit in which the gravitational force of the compact object causes light to orbit it. The event horizon is the boundary at which the escape velocity is the speed of light. So, why is it that any photon crossing the photon sphere, at 3/2 Schwarzschild radius spirals into the black hole? Why do we see a black hole shadow?
Comment: There isn't such thing as "black hole shadow". And we don't see anything about black hole, just things which fall into black hole near event horizon and due to that emit EM waves, which being a bit further than even horizon is able to escape BH attraction.
Comment: Related: https://physics.stackexchange.com/q/680685/123208
Comment: Here is a picture of a black hole shadow @AgniusVasiliauskas https://physicsworld.com/wp-content/uploads/2019/05/eso1907a-2.jpg
Comment: @ProfRob. I do not have anything against this pic. It's just unclear for me,- which sections of that image do you call "shadow" and why ? Is that relatively darker regions near to black hole in emission ring zone ?
Answer: Imagine pointing a laser pointer in the direction of a black hole. Two things can happen:

If you point close enough to the black hole the laser beam will disappear into the black hole.
If you point further away from the black hole, it will mass the black hole, but the light beam will be deflected by the black hole.

Which of these two things happens depends solely on how far away from the black hole you point the laser (the impact parameter $b$).
Consequently, there must be a critical value of the impact parameter $b_{crit}$ such that when $b < b_{crit}$ the beam is absorbed and when $b > b_{crit}$ the beam if deflected.
This leaves the question of what happens when $b = b_{crit}$. This is of course an unrealistically fine-tuned case, but we can see what happens mathematically. The answer is that the beam must asymptotically approach an unstable circular orbit. Since there is only one lightlike circular orbit in Schwarzschild spacetime, it has the the light-ring at $r=r_{LR}$.
So the critical case of  $b = b_{crit}$ is exactly the case where the pericenter passage of the beam is $r_{peri}=r_{LR}$. When $b > b_{crit}$ we will also have that $r_{peri}>r_{LR}$. Moreover, any beam that passes closer to the black hole than  $r_{LR}$, must have $b < b_{crit}$ and will be absorbed.
When looking at a black hole you get this same picture, but in time reverse. Instead of following a laser beam travelling forward in time towards the black hole, you now follow the beams travelling towards your eye backwards in time. Since the math is exactly the same, we conclude that you will only see light beams coming from the stars at infinity approach with an impact parameter $b>b_{crit}$. In particular $b_{crit}$ is the size of the shadow cast by the black hole.
Answer: Just as one constructs effective potentials for orbiting bodies in Newtonian gravity, we can do this in the Schwarzschild geometry (the spacetime of a black hole) for both massive objects and light beams.
Hence, the plunge you describe can be understood by just the same reasoning.
Mechanics of freely falling objects and light in general relativity are given by the geodesic equation; really a set of 4 ODEs for motion through each dimension of the spacetime.
In the Schwarzschild geometry, two of the equations reveal two conserved quantities, specific angular momentum and specific energy. One of the equations can be gotten rid of by assuming motion is in the equatorial plane of the black hole (this is okay because spherical symmetry allows us to rotate the coordinate system to make this true). The final equation describes radial motion.
Combining this information, we can derive the following equation describing the dynamics of light beams near the black hole:
$$\frac{1}{2}\mathcal{E}^2 = \frac{1}{2}\left(\frac{dr}{d\lambda} \right)^2 + \frac{\mathcal{L}^2}{2r^2} - \frac{R_s}{2} \frac{ \mathcal{L}^2}{r^3} = K.E. +  V_{eff}(r)$$
where $R_s$ is the Schwarzschild radius, $\mathcal{L}$ is the aforementioned angular momentum and $\mathcal{E}$ the energy; we have written the total energy of the light beam as the sum of a term resembling classical kinetic energy resulting from radial motion and a term resembling an effective potential.
The photon sphere is discovered by requiring the effective potential is constant - this is the condition of circular orbit. You can carry out the calculation by solving $$\frac{d}{dr} V_{eff}(r) = 0$$.
So then passing closer to the black hole than the photon sphere causes light to plunge for the following reason:

The yellow curve is the effective potential as a function of r and the black horizontal line is the total energy. The purple vertical line is the photon sphere's radial value.
As this image is drawn now, a photon would orbit in the photon sphere: its total energy equals its potential energy and hence it exhibits no radial motion.
But a little push to smaller $r$ would mean an increase in kinetic energy; the distance between the black line and yellow curve is the difference in total energy and potential energy - the kinetic energy.
As a little bit of KE has been added, we move closer to the black hole and the effect snowballs with the stronger pull of the central mass (which we can't call a force; remember GR says gravity is the curvature of spacetime); the state of the previously orbiting light beam plunges down the yellow curve, and so $r\to 0$.
Comment: All energy of the photon is kinetic. Photons don't have potential energy. In fact, there is no potential energy in GR at all, because gravity is not a force in GR while potential is a concept of the force field. And since energy is conserved in the Schwarzschild spacetime, a photon has the same kinetic energy everywhere, no matter how or where it moves.
Comment: I agree, however I am making an analogy with classical mechanics. The "kinetic" and "potential" energies I refer to are quantities defined by the spacetime that merely resemble their counterparts in the Kepler problem. What one would more rigorously call the energy of the photon as you have is indeed what I gave as the conserved specific energy. I'll make it more clear the use of KE and PE are metaphoric.
Answer:
Why do we see a black hole shadow?

The image shows what you call "shadow", but  The word "shadow" is really inappropriate. Note that the background is not lighted either. In this link there is a discussion of the so called "shadow", from the abstract:

This signature is a sharp-edged dip in brightness that is coincident with the black-hole shadow, which is the projection of the black hole's unstable-photon region on the observer's sky. We highlight two key mechanisms responsible for producing the sharp-edged dip: i) the reduction of intensity observed in rays that intersect the unstable-photon region, and thus the perfectly absorbing event horizon, versus rays that do not (blocking), and ii) the increase of intensity observed in rays that travel along extended, horizon-circling paths near the boundary of the unstable-photon region (path-lengthening)


Lorentz-invariance of step function

Question: I was reading about the Lorentz invariant integration measure $\int \frac{d^3k}{2E_K}$, and ways to prove that this was Lorentz invariant. Many of the proofs I have read use the step function (or Heaviside function) $\theta(k^0)$, and claim that this is obviously Lorentz-invariant (e.g Alex Nelson's notes). Other sources claim that there is some requirement that the Lorentz transformations have determinant = 1, or that $k^\mu$ is timelike.
What are the actual conditions on the vector $k$ for the step function to be lorentz-invariant?
Comment: Can you link to a specific proof, please? Taken out of context this leaves too much to guess, at least for my taste. The question for a quality proof is, of course, legitimate.
Comment: @CuriousOne quite a good proof can be found here http://physics.ucsd.edu/students/courses/fall2009/physics130b/PS_3.pdf
Comment: Related: https://physics.stackexchange.com/q/164076/
Comment: Related: https://physics.stackexchange.com/q/36384/2451 , https://physics.stackexchange.com/q/83260/2451 , https://physics.stackexchange.com/q/246706/2451 and links therein.
Answer: Proper, orthochronous Lorentz transformations can't change the sign of a $x^0$ component in a time-like four-vector - $dx^\mu dx_\mu$ and $\text{sign}\,x^0$ are both Lorentz invariants if $x_\mu$ is time-like. Because $\text{sign}\,x^0$ is Lorentz invariant, the step function $\theta(x^0)$ is Lorentz invariant - the condition is that $x$ is time-like.
A general Lorentz transformation that wasn't orthochronous could violate causality by making one observer see time-like events occurring in a different order.
Comment: @LouisYang See my answer
Comment: Why proper, orthochronous Lorentz transformations can't change the sign of $x^0$ of a time-like vector?
Answer: I'd like to add to Innisfree's answer, which depends on the orthochronous property of certain Lorentz transformations, so as to clear up the follow-up question to his/her answer::

Why proper, orthochronous Lorentz transformations can't change the sign of $x^0$ of a time-like vector?

First let's clear up some terminology. An orthochronous Lorentz transformation means, by definition, one that doesn't reverse the sign of the time component $x^0$ of a timelike vector $X$, i.e. one for which ${x^0}^2-{x^1}^2-{x^2}^2-{x^3}^2 > 0$. It can reverse the $x^0$ component if this inequality is not fulfilled. So this nonreversal is something that is a by-definition property of orthochronous transformations, so, in these terms, the question has no physical content. But a question that does have physical consequence, and whose answer is crucial to Innisfree's arguent, is that:
The identity-connected component of the Lorentz group $SO(1,\,3)$ comprises only orthochronous transformations
Physically, what this means is that no finite number of finite rapidity boosts and rotations can reverse the sign of $x_0$. This is what allows us to salvage a sound notion of causality from special relativity even though simulteneity is observer-dependent, as long as we postulate that supraluminal signalling is impossible.
The proof of the statement is the following simple argument.
Let's suppose that $(t,\,x,\,y,\,x)$ is an event in an observer's future such that $t^2 - x^2 - y^2 - z^2=Q^2 > 0$.
Then, under the action of any Lorentz transformation, this event's co-ordinates become $(t^\prime,\,x^\prime,\,y^\prime,\,x^\prime)$ where:
$${t^\prime}^2 = Q^2 + {x^\prime}^2 + {y^\prime}^2 + {z^\prime}^2\tag{1}$$
where $Q$ (the Minkowski length of the vector) is constant and therefore:
$$t = \pm\sqrt{Q^2 + {x^\prime}^2 + {y^\prime}^2 + {z^\prime}^2}\tag{2}$$
which means that, as $t,\,x,\,y,\,z$ are varied through a Lorentz transformation, either $t \geq +Q$ or $t\leq-Q$, and $t$ is excluded from the interval nonzero length interval $(-|Q|,\,|Q|)$.
But if the event co-ordinates $X^\prime$ are acted on by a Lorentz transformation from the Lorentz group's-identity connected component, this means there is a continuous path of the form:
$$X_s:\mathbb{R}\to\mathbb{R}^{1+3};\;X_s(s) = \prod_{k=0}^N\exp(s\,K_k)\,X;\;X_k\in\mathfrak{so}(1,\,3)\quad X_s(1) = X^\prime\tag{3}$$
linking $X$ to $X^\prime$, so the time co-ordinate must vary continuously along this path. Therefore, it cannot jump the excluded interval $(-|Q|,\,|Q|)$ and so therefore, the negative root of (2) is ruled out and we conclude that the time component must stay positive. Thus all members of the Lorentz group's identity connected component are orthochronous and no finite number of finite rapidity boosts and rotations (i.e. the $\exp(K_k)$ in (3) at $s=1$) can reverse the time order of timelike-separated spacetime events.

The idea for this little argument comes from the the technique in Schreier's original 1926 proof of Schreier's theorem that any discrete normal subgroup of a Lie group is needfully contained within the Lie group's center. See Schreier, O. "Abstrakte kontinuierliche Gruppen",
Abhandlungen aus dem Mathematischen Seminar der Universitat
Hamburg, 4: pp15-32, 1926
Answer: Thanks WetSavannaAnimal aka Rod Vance for the rigorous proof. Here I would like to add a short answer in a different perspective.
An orthochronous proper Lorentz transformation can always be split into a boost and a rotation. The rotation part doesn't change the $k^0$ component. A boost on $k^{0}$ has the form
$$
k^{0\prime}=\gamma\left(k^{0}-\vec{v}\cdot\vec{k}\right).
$$
Since for time-like or light-like vectors, $\left|k^{0}\right|\ge\left|\vec{k}\right|$,  $\left|v\right|<1$, and $\gamma>0$, boosts preserve the sign of $k^{0}$. Thus, $\theta\left(k^{0}\right)$
is Lorentz invariant for time-like and light-like vectors.

Lorentz-invariance of step function


Is Neural Network Architecture independent of Data?

Question: If I change my dataset (let's say it is always images), should I change the architecture of my neural network?
Answer: Because your two questions are phrased a bit differently, I'm going to answer the one in the title.

Is Neural Network Architecture independent of Data?

Generally speaking, yes.
One simple reason why you might have to change the architecture is if your new task has a different number of classes. If so you must change the last layer of your network.
Another reason is that some deep CNNs perform multiple stages of spatial subsampling (e.g. through pooling). This requires the input to be larger than a minimum shape. E.g. InceptionV3 and InceptionResnetV2 require the input to be at least $75 \times 75$, Xception $71 \times 71$, and so on.
Even if you don't necessarily have to, sometimes you should. An architecture that does well in MNIST, won't necessarily do well on ImageNet, because the latter is much harder. It requires models with a higher capacity.


using "the" before "adjective + name of the country"

Question: Do I need to use "the" if I say "mysterious Japan" or "vast Russia"? Will it be "the mysterious Japan" or just "mysterious Japan"?
Answer: In my opinion, it is not advisable to say something like "The mysterious Japan" or "The vast Russia". For example, you have "The mysterious Japan". I suppose it won't take you long to recognize the problem if you just remove the adjective, which will be "The Japan" - There is no country such as "The Japan", right?
In your context, I suppose the appropriate way to use adjectives with country names is "The mysterious country of Japan" or "The vast land/country of Russia".
Comment: You've picked up on the facts that 'The mysterious Japan' is highly unidiomatic, but 'mysterious Japan' is also unidiomatic. Your alternative **is** idiomatic.


Firestore conditional array query

Question: I am trying to get all documents where the length of the "users" array is less than 2 and where the userId is not present already. I am doing the following query, but it is not executing correctly. What is the problem and how can I fix it? I just want all documents where there is only one entry in the array "users" and where the array does NOT contain the current userId.
await FirebaseFirestore.instance
  .collection('rooms')
  .where("users"[0], isNotEqualTo: userId)
  .where('users'[1], isEqualTo: null)
  .get()
  .then((snapshot) async {
// If no empty room is found, create room
if (snapshot.docs.isEmpty) {
  print("No empty room found, creating new room");
  roomId = await createRoom(userId);
  return roomId;
}

Answer: You can't query individual array elements in Firestore. You can only check whether an array contains a specific item.
It sounds like your array items have a specific meaning, in which case you should create (nested) fields that indicate/name the roles. For example:
participants: {
  creator: "uid1",
  receiver: "uid2"
}

With that you can then query the nested fields with dot notation:
.where("participants.creator", "!=", "uid1")
.where("participants.receiver", "==", null)

Keep in mind there that the participants.receiver field still has to exist in the latter case and have a value of null. Firestore can't filter in fields that don't exist.
Comment: Adding a nested field, is done by passing the first snippet I have in my answer. Querying and updating a nested field is then done with dot syntax. Also see https://firebase.google.com/docs/firestore/manage-data/add-data#update_fields_in_nested_objects for the latter.
Comment: Thanks so much! Perfectly answered my question! Just one follow-up question: I am adding the participants in my room in the code like: "users": [userId1]
- How do I add the nested field when doing the firestore query?

Firestore conditional array query


Is the Abrahamic Covenant an unconditional Covenant for believers today?

Question: Is the Abrahamic Covenant an unconditional Covenant for believers today (Genesis 12:1-3)?
I discovered in the Bible that God alone is responsible for the performance of the Abrahamic Covenant for Abraham, but is it the same for believers today?
Comment: Of course, it is.  "All the families on earth will be blessed through you" can be also translated as "all the families on earth will be grafted through you" (through your seed, Gen.22:18 & Romans 11:17-24).
Comment: The root of the word ונברכו is the same as that of מבריך, "to graft."
Comment: The Abrahamic Covenant was and remains eternal covenant, Gen 13:15, 17:9, 13, 19.
Comment: It is unrelated to today's believers since it was made with Abraham its a promise of the nation.
Answer: I suggest that the most relevant quotation is "Those who are men of faith are blessed with Abraham who had faith" (Galatians ch3 v9), which echoes the "blessing" of Genesis ch12 v2.
In that sense, we have a relationship with God on the same terms that Abraham had a relationship with God. For that reason, the men of faith are regarded as "sons of Abraham" (Galatians ch3 v7), which is part of the fulfilment of "make you a great nation".
Hence, a little further down the Galatians page, we see the assurance that a covenant cannot be annulled (v15) and that this covenant was not cancelled by the law which came later (v17). We have an inheritance which "God gave to Abraham by a promise" (v18).
There is a slight difference, in that Abraham trusted in that promise (compare Hebrews ch11 vv8-9), and our trust is in the fulfilment of that promise (Galatians ch3 v24).
I'm not sure that "unconditional" is the right word, because "faith" is a kind of condition. It's a question of semantics.
Comment: Please don't answer off topic questions.
Answer: Yes, the Abrahamic covenant is still applicable today.  The New Covenant is just a renewal of the same covenant which God has made with us in the past, including the Noahide covenant (see Genesis 6:18; 9:9-17), the Abrahamic covenant (see Genesis 15:18; 17:2-21) , and so on.  Only the covenant which we attempted to make with God (see Exodus 24:7), and broke (we cannot keep our promises), is invalid: it is called the Old Covenant.
God's covenant is a promise that we will be enabled to keep His law.  The Ten Commandments are part of His covenant.

And he was there with the LORD forty days and forty nights; he did
neither eat bread, nor drink water. And he wrote upon the tables the
words of the covenant, the ten commandments. (Exodus 34:28, KJV)

The Ten Commandments are an enduring part of God's covenant.  There will never come a time when we are supposed to break them.  God's covenant is also called "the everlasting covenant" (see Leviticus 24:8).  All who enter a covenant relationship with God, enter His covenant.
Comment: Please don't answer off topic questions.


Sending a json object over Flash Builder 4 webservices

Question: Can I use the webservice wizards in Flash Builder 4 to send a json encoded object...not as a string but as type application/json; charset=UTF-8
Answer: Solution I've used is to simply use the WSDL services to map data instead. Not really a solution to using JSON, but more an over arching solution that my apply to your project.


Children's book in which there seems to be another person on the opposite side of their mirror

Question: I remember reading a book in which there seems to be another person on the opposite side of their mirror. Its a children's book, and it is one of the books of a big series. I can't seem to recollect which book it is. Could someone help me?
Comment: Hi, and welcome to Lit SE. There are a fair few children's books with people or ghosts in mirrors. Can you try to narrow it down a bit? What happens in the story, how old is the book, what country and language did you read it in, is the protagonist male or female or is there a group of characters acting together? If you look at the tag info it will suggest other info you may be able to recall. Also, are there titles that you have already ruled out?
Comment: Possibly in the Harry Potter series. Harry has a sliver of mirror, and catches glimpses of Albus Dumbledore's brother, Aberforth. Earlier, there is a mirror showing the observer's desires (Harry's dead parents; Ron Weasley as Griffendor Quidditch captain). But there were many prior examples.
Comment: Thanks for your help!, I got the name of the book, it was The Zack Files series By Dan Green
Answer: It is Zack Files by Dan Green. This is not an individual book but a series of books. The book is Through The Medicine Cabinet
Comment: Hi and welcome to Literature Stack Exchange. Could you please add some details about the book series that confirm that it matches what the question is asking about? For example, where in the series does there seem "to be another person on the opposite side of the mirror"?


Using ReactiveOAuth with Windows Phone 7, to access Dropbox

Question: I am building an application which requires accessing Dropbox. Since there is no api for windows phone yet, i am using the ReactiveOAuth to achieve this.
I was referring to this tutorial, http://blogs.developpeur.org/kookiz/archive/2011/11/13/wp7-upload-a-file-to-dropbox-using-reactiveoauth-wp7.aspx.
I have followed all the steps, but VS shows an error saying

Error 1   'DropBoxTest.MainPage' does not contain a definition for
  'RequestToken' and no extension method 'RequestToken' accepting a
  first argument of type 'DropBoxTest.MainPage' could be found (are you
  missing a using directive or an assembly reference?)

I have added all the mentioned classes and references. Could anyone please have a look and help?
Answer: You should take a look to Spring.NET Dropbox.
It supports WP7 and provides a sample too.
http://www.springframework.net/social-dropbox/


MacBook Pro keyboard and trackpad not working

Question: I have a 2017 MacBook Pro 13" without touchbar (2 usb-c ports)
I am trying to install ubuntu from a usb to another usb, but my keyboard and trackpad is not working on the installation, or live ubuntu.
I tried connecting a wireless mouse with a usb input, and it works. But then I am left with only 1 usb port available.
Is there a way to use my MacBook's keyboard and trackpad instead? Because even if a buy like a usb-c to 3 usb-a adapter, I don't really want to use external keyboard and mouse all the time.
Thank you..
Answer: The newest line of MacBook Pros is poorly supported by Ubuntu (and vice versa). While it is possible to get Ubuntu working, it will take some extra work until Ubuntu catches up with the hardware changes.
To get your builtin trackpad and keyboard working, use a USB keyboard and mouse for the installation (you'll likely run into NVMe SSD issues that you can learn more about here when selecting your partition setup)
When your install is complete, refer to this link to regain control of your builtin hardware.
Answer: I've experienced this issue using a Virtual Machine (parallels) and instead of loading Linux 4, I selected the previous Linux 4 and it worked so logically it could be something in Linux 5's kernal that is not supporting the trackpad/mouse driver for the Macbook Pro.


What does the \fill command do?

Question: I have been reading about vertical spacing commands in LaTeX and have come upon the command \vspace{\fill} which is similar to the command \vfill. My question is this: what does the \fill command do? Can it be placed outside the argument to some other command like \vspace? If not, is this because it defines a kind of "variable" version of a length like \baselineskip?
Answer: \fill is defined as \skip20 (well allocated with \newskip\fill, so the number might differ in different formats and builds), so it calls the skip register 20, which's value is 0pt plus 1fill. So \fill can be used anywhere where TeX expects a skip value or skip register, e.g. after \vspace or \hspace or after the primitives which are called by those (\vskip and \hskip). It is the same as anything defined with \newlength\foo and then \setlength\foo{0pt plus 1fill}.
A skip of 1fill means 1 of the second order of infinity, TeX has three orders of infinity fil, fill and filll, each being infinitely smaller than the following but infinitely larger than a finite value such as \maxdimen (which in turn is set to 16383.99998pt, being the largest dimension representable by TeX). The infinite units fil, fill and filll can only be used in the stretchable or shrinkable part of a skip, so after plus or minus (a skip is something like <len> plus <stretch> minus <shrink> with both the stretch and shrink being optional).
Comment: and `fi` units in luatex and ptex:-)
Comment: @DavidCarlisle yes, but those weren't part of Knuthian TeX, feel free to edit if you want to add it, or write your own answer (which will most likely be better than mine anyways).
Comment: No, I was only being awkward, they are fairly useless: I  only noticed them recently as they broke one of our test files.

What does the \fill command do?


How can I layer two images, to be used as height information in a Bump node, while retaining control of the Strength Value of each?

Question: I am trying to understand how to cleanly and efficiently layer two images, which will both be connected to a Bump node's Height input, while retaining the ability to control the Strength value of each contributing image. One of the images will also be used as the Factor value in a Mix Shader node. Here is my node work with an empty area where my question is.
Comment: Did you try using a mix color node (maybe on add?) and a math node on each input to it?
Comment: Should work well with MixRGB node set to multiply
Comment: MixRGB set to multiply does work well but doesn't leave me with the option to adjust the strength of each incoming image. When I use Math nodes before each input into the Mix RGB, I still don't seem to be able to control the strength.
Comment: @BrysonJack you can adjust it with the factor value on the MixRGB node
Comment: http://i.stack.imgur.com/OXeRS.gif
Comment: Thanks Denis, I was able to get that far but I was looking more for independent controls for each contributing image.
Answer: Keep in mind, the contrast of the textures you use is important. If one texture is extremely contrast and one has only grey values ranging from 0.3 to 0.5, the contrast one will almost always be the more visible one.
Using the Bump node is basically a game of values (brightness/darkness of the pixel). You should convert coloured images to black and white using Converter->RGB to BW node (they are converted anyway)
Also keep in mind that both textures should have brighter colors on the "hills" and darker colors in the "crevices" of the surface. Alternatively you can check Invert on the Bump node to have it the other way, but both textures should correspond with each other in this area.
Bump node calculates the normal map based on the difference of the values of the pixels given to it. So basically you should be careful when mixing two or more textures - their actual values and the way they are mixed using MixRGB is important. You can also use Math node by the way. Since values of bitmaps are actually math anyway but both ways have their pros and cons.
It mostly depends on what you are actually trying to accomplish. Usual case I've seen is mixing the main UV mapped bump map of the model with a second one which is for detail - little perforations/scratches/bumps/glued dirt. This detail bump map is usually mapped using Texture Coordinate->Object and the texture having Box mapping instead of Flat mapping. Detail bump maps don't really need elaborate UV mapping since it's only important that the detail mapping is uniform.
Initially I should give some information about MixRGB node, since it's important here. It has 2 inputs. The top one is the "main" input. It is the one that the chosen function will alter based on the input values of the lower input and then this altered version of it can be grabbed on the output. This is true for all function except Mix, which basically mixes the inputs according to the factor (fac) you choose.
Whenever you want to mix a detail bump map onto an actual bump map, remember that there are basically 2 ways to choose from depending on the given case.

Crevices

If it's a general bump map of bricks and then a detail bump map of the
  little perforations in the brick (meaning you want to add crevices and
  not hills), it should be mixed so the crevices are darker than the
  upper input. The way you mix it is dependent on the actual texture's
  contrast and values.

Hills

On the other hand, when the detail bump map is meant to depict small
  bumps (hills - like dried color drops) on the surface, it should be
  mixed so the bumps are lighter than the upper input. The way you mix
  it is dependent on the actual texture's contrast and values.

As to the other question of controlling which texture is stronger. You must give me an actual material and textures for which to solve this, since it would take way too much time to talk about all types of possibilities.
All wrapped up, there is really no true way to mix bump maps in an organized way unless you get your actual bitmap texture values organized. Ie what is lighter/darker than the other. Most of the time, a simple MixRGB->Mix might work. But I'd recommend using a Converter->Math->Multiply before putting the values in the inputs of the MixRGB. You can then change the values in the multiply nodes to strengthen/weaken the bump textures.

First tip - You can always check the values you are working with using the Emission shader. Remember though, that in Properties->Scene->Color Management you often need to change the exposure or gamma to see certain changes in values, since your monitor can't dislay all of them most of the time.
Second tip -Try using Converter->Color Ramp or Color->RGB Curves to alter the textures without using 2D editor.


How to find out the host for a dubious website?

Question: I've recently received a spam email that links to a website of legally doubtful content. How can I find out the Internet provider for the site, such that I can complain about the site? The whois-service gives some information, but the data seems to be about the domain registration, not the actual hosting provider or ISP. Is there some other service where I can find out who to complain to? Or am I just reading the whois output wrong?
Comment: What are you trying to achieve exactly?  If they host their own server its unlikely you will have any luck shutting them down, even if you do, they can replace their server within hours.
Answer: The question is a bit tricky.  Whois is normally a good place to start as it gives you a feel for the site, including the nameservers which, if often, but not always give you a hint about the hosting provider.
In order to work out where a site is located, you need to get its IP address.  This is as easy as doing a "ping" to the site.   Even better, if you use traceroute it will show you all the hops between your computer and that site - and usually the hops immediately before will give you a clue of their ISP's router.   Importantly, using traceroute will do a reverse lookup on the domains and this will help you work out who their ISP is.  You can then google the results to try and find a contact detail for their domain name.
Another technique might be to look and see how mail is handled for the site, and see if there is a link (again, not always).  To do this you need to do a DNS lookup for the MX record for the site.  (Googling "MX Lookup") should help you come up with a tool for this.  If they are farming their mail out to an ISP, you should be able to do a WHOIS to find more about the ISP and contact them.
Answer: If you look up their IP address, you can run a WHOIS on that IP to get the registration info for that address (which would include the ISP).
Comment: While a Whois is a good idea, it does not include their ISP, it includes their registrar and technical contact - if you are lucky.
Comment: @davidgo Not if you run a whois on the IP address. That shows the IP registration info, not the domain name info.
Comment: The given rule for contacting an abuse departments at any given isp is to use abuse@.com. That address almost always works.
Comment: It might just be an america-centric ISP thing, but any ISP I've ever dealt with, including the ones I've worked for, have always had an abuse@ address. This goes for AT&T, Megapath, CenturyLink, etc
Comment: That is a good technique. Of-course, it doesn't help if the ISP is purchasing a block of space from a bigger ISP who has the ARIN/APNIC/RIPE/AFRINIC etc block, but definately worth pointing out.  The key being to do the whois on the IP rather then the domain.
Comment: @davidgo This does get you contact info for the ISP, so you can report abuse there.
Comment: @MaQleod - You must live on a very nice, quaint part of the Internet !
Answer: Once you find out IP, you have to go to the right Organisation. Now ICAAN have designated IPv4 range to huge organisation like apnic.net (for asia pacific) and ripe.net (for europe region).  You can WHOIS search and find out to which organisation does the IP belongs to? And Later you may contact to corresponding organisation. I hope they might help.


VMWare ESX and templates

Question: Recently we faced with one problem. We have to have many CMS on different virtual machines located on our ESX server. One CMS for one VM (it is important). But we don't want to store them all simultaneously and we're searching for solution to configure VMs on demand. All machines are differed only by CMS, underlying OS and all soft (apache, php etc) are the same. Can anybody help us with this? May be there are existing opensource (or not very expensive) solutions? Thanks in advance!
Answer: There are at least 2 oob ways to clone a VM with EXS.

If you have vCenter you can just use Clone option
If you don't have vCenter then you can just create a copy of VM disk and then create a new VM pointing it to that disk

If you don't want to bother with vSphere client for these tasks, then you can just create simple scripts with vCLI or PowerCLI. If you are cloning Windows VM, then it might be useful to do to this over syspreped image.
While the above is the answer to the question you asked, but this is probably not the answer you want, because, as far as I understood, your primary problem is configuring of CMS inside of VM (I might be mistaken here) which is actually not the thing that ESX should worry about. If so, then you need to elaborate your question and provide as much details as you can, e.g.:

What is "different" CMS's? Are these really different CMS's or just different versions of the same CMS
CMS is you SUT or you run your SUT at the top of some third-party CMS's?
What OS is inside your VM
Comment: Yes, the primary goal is to install/configure completely new CMS on a clean OS AFTER machine is cloned. What OS it doesn't matter. It can be Windows or Linux. CMS are all different (joomla, drupal, wordpress etc) and they are not our SUT. So, roughly speaking, I want clone machine, may be pass a param with CMS name, after cloning OS is boot and then magic happens which installs software for me :)
Answer: There's a couple of options I can think of right now.
The low-impact version is to have an off-server data store where your VM images are kept and moved to the ESX server on demand. This can be automated fairly easily using the sysinternals tools and command line (I'm presuming you have command line access to manage your ESX server).
If you need to install and configure the VM and then the CMS on the fly things get more complex: you could probably still do this with a command line interface but it would be a whole lot more complicated to set up.
If your issue is purely with drive space, I'd recommend investing in some hard drives and use these as your template locations so the server platters are only hosting the currently active VMs.
If your issue relates to IO then things get more awkward.
Comment: No, we don't have problems with disk space, but we are limited in CPU and RAM (CPU is the main problem). And yes, I want to install soft on the fly :) One thing I'm thinking of is a python automation (WebDriver). But it can be quite difficult to maintain.
Comment: Any automation you use to install on the fly is going to be difficult to maintain - I'd suggest having your automation pull as much of the config data as it can from some external data source to minimize the data you code in. That helps with maintainability.

VMWare ESX and templates


Wire sizing when connecting multiple motors

Question: I'm connecting two electric motors and an electric heater in parallel together in a circuit, all three phase. Electric motor 1 has a rated current of 20A, motor 2 is rated 2.5A, and the heater is rated 25A. Branch circuit conductor sizing per the NEC is as follows: 125% of highest rated motor full load current (FLC) + 100% of each other motor FLC + 125% of non-motor noncontinuous load FLC. This totals to an FLC of about 59 amps. A conductor carrying 59A should be about 6 AWG THHM wire. My question is this, do I need to be running 6 gauge wire throughout my circuit (contactors, circuit breakers, etc)? This seems to be what the NEC recommends, but shouldn't the small motor receive 2.5A at most, why does it require such a thick wire?
Comment: Because (presumably) you have the branch circuit protected with a 210.20 Overcurrent Protection device rated at about 59 amps.
Comment: Yes, the branch and motors have circuit breakers for overcurrent protection.
Comment: Are the breakers in the industrial control panel rated for branch circuit protection, or are they supplementary protectors?
Comment: I believe from NEC 430 you're required to have short circuit and ground fault protection for each motor.
Answer: The wire gauge required by the NEC is determined by the circuit breaker protecting the branch. In the case of a short, even in a low current branch, the wire conductors need to be able to handle the momentary over-current of the short. If the short is not "perfect", the breaker will happily supply 60 Amps+ into it for an indefinite period of time. Not a good situation if the conductors are sized to carry 2.5 amps (presumably #14 wire, the smallest permissible gauge for branch circuits). For safety all branches of the circuit are assumed in the NEC regs to be able to carry the amperage dictated by the circuit breaker serving that branch.
By the way, if you have "long" cable runs to the high amperage motor you may find that the motor is starved for starting current due to the round-trip resistance of the conductors. This resistance may create a voltage drop in the wires sufficient to prevent the motor from starting, or cause it to start slowly or erratically. In your specific case you have that 25 Amp heater complicating matters. If the heater is also on the same long branch of the circuit, it will create its own voltage drop in the wiring which will affect the voltage available to the motor when it starts. In these cases you will need to use a heavier gauge cable than is dictated by the normal ratings of the motor.
Comment: If you used smaller gauge wire after the motor circuit breaker, wouldn't the breakers protect the conductor?

Also, isn't the resistance in a 6 AWG cable fairly negligible? The round trip distance through the cable and branch circuit couldn't be more than 100 feet. I am not sure about the heater's resistance.
Comment: schafbo: I wrote my answer just before you posted the wiring diagram. On the face of it you could easily use #14 AWG wire for the small motor branch between the 4 amp breaker box and the motor. However, as ThreePhaseEel suggests, the "legitimacy" of the branch circuit under NEC regs will depend on the nature of the circuit breaker.( I'm a bit out of my  comfort zone in this area of the NEC regs.) Also, what's up with the "Wall Socket" in the diagram, that is not mentioned  in the text? Is it there for additional devices, or does it actually connect the 60 Amp branch to the three devices shown?
Comment: schafbo: Regarding #6 AWG copper wire, it has a resistance of approximately 0.4 milli-Ohms per foot.  Or, 80 milli-Ohms for the 200 ft round trip. Insignificant? Probably. Do you know what the instantaneous starting current is for the "20 Amp" motor? In other words, how much current it will draw from the mains for the first cycle or two when voltage is applied with the rotor at a dead stop, and under its normal starting load.
Comment: I think I've misunderstood the NEC regarding what a feeder and branch circuit is. I'm not an electrician, but I assumed a 'feeder circuit' was the connection into the master breaker from the electrical grid and a 'branch' was any wires beyond the master breaker. But now I see that a 'motor feeder' is the wire connecting multiple motors in parallel, I wasn't reading the diagram from NEC 430.1 correctly.

The wall socket just shows that I'm connecting a control panel to the master circuit breaker, the enclosure just also happens to have circuit breakers in it.
Comment: The inrush current for the large motor is 70A (I think in general it's about 4 times the rated current) but the circuit breakers are time delay so they shouldn't be tripping.
Comment: So, 80 milli-Ohms x 70 amps = 5.6 volts drop in the wires when the motor is starting. Not a big deal. ( I had a case once where a local lumber yard ran about 500 feet of "legal" size cable to a radial arm saw in a lumber shed. The saw had a tough time starting because the wire was dropping about 10-20 volts when it was first turned on. )


How to allow access to page variant (Page Manager) if user belongs to list

Question: The Situation
I have an ECK entity called "Event" in my Drupal 7 site.
I have an entity reference field on Event that collects users who flag the Event with a non-global flag called "Sign up" via a rule.
I use Page Manager to control how an Event entity is shown to the users.
My context:
Edit relationship "User from Event (on Event: List of attendees [field_attendees]"
Event: Entity being viewed
Identifier: User from Event Attendees [field_attendees])
Keyword: event_attendees
Delta: 0
Here is the Selection Rule:
User: compare    logged_in_user is User from Event Attendees [field_attendees]
The Problem
As you can see, one of my Page Variants has a selection rule that checks if the logged_in_user is on the list of attendees but it doesn't work because the selection rule takes a "delta" and that means that it takes a hard coded integer to select one of the list. And if I leave this empty, it automatically takes "0" i.e. the first one in the list. There seems to be no option to set the delta to include all or any.
The Question
How can I create this selection rule to check if this user is 'on the list'?
Answer: Currently I'm using a selection rule that checks if the logged-in user has "flagged" the Event with a Signup. This works but checking if the logged-in user is on the list would be a waterproof solution.


Are algorithm questions allowed on SO

Question: I recently posted an algorithm   question on SO and it was closed as a non-programming related. As far as I know, algorithms were always part of CS.
Answer: It has been nominated for reopening and is (temporarily at least) open again.
I would say that algorithms are reasonable questions for StackOverflow.  Clearly, not everyone agrees, but it doesn't belong on SuperUser or ServerFault (or Meta), so where else could they be asked.
Comment: Algorithm-related questions **may** be reasonable on SO. This particular question is basic logic / math; it's no more related to programming than solving a linear equation would be.
Comment: You're making the assumption all questions belong somewhere on the Trilogy. That isn't true.
Answer: Technically it's purely math related, but computer science is simply heavily applied math. I wouldn't vote to close because it is very clearly related to programming (i.e. it's for programming purposes). It wouldn't make sense to ask:

To find out whether N is a prime number, we only need to look for all numbers less than or equal to sqrt(N). Why is that? I am working as a carpenter and trying to understand the reasoning behind the floor plans.

Therefore, I would say it's okay for Stack Overflow.
Answer: Not really programming related. It is basic mathematical reasoning, and you would have been better off puzzling over until you got it yourself.
But close enough that I wouldn't vote to close. On the other hand, I wouldn't vote to reopen either...
Answer: As a proponent of leaving the question closed I suppose I should reply.
Not all questions belong in the Trilogy. To say "it doesn't belong on SU or SF, therefore it must belong on SO." isn't valid.
I do agree it's a thin line. But imagine if the question had no language attached and the user had simply asked "To find out whether N is a prime number, we only need to look for all numbers less than or equal to sqrt(N). Why is that?" I don't think anybody here would think it was programming related, because it's pure math. In the same manner saying "How do they make waffles look so tasty? Oh, because I'm programming a waffle simulator" doesn't suddenly make waffles programming related, I don't think "Why is pure math question X so? Oh, I'm implementing it" makes the question related to programming.
Yes, programming is applied mathematics, but it's the application we talk about, not the pure mathematics. I don't find saying "well then algorithms etc also aren't programming related since they are math" is valid either. They are programming related because we implement them. We take these algorithms and apply them. How can one "apply" why the minimum number to check is sqrt(N)?
Answer: That is so not an algorithm question. And if you think it is, you're wrong.
Comment: Yup. The word "algorithm" s being thrown around the comments thread like it was a magical Shield of Appropriateness +2, but the question is fundamentally about arithmetic.
Answer: Look at your question I can honestly say that you should ask it at mathoverflow.net.
Does this mean that you can't ask any math question? I think no; you can ask math questions that are not too technical or specific, something like high school algebra or first year undergrad calculus are accepted, I think. Beyond that, I suggest you take it to mathoverflow.

Are algorithm questions allowed on SO


Finding output values of point density calculation?

Question: I ran the point density tool and got an output, but because the 'Area Units' option in the Point Density was locked to Square_Map_Units - I don't know how to tell what units the density was calculated with, and no way to convert that into density/km2 which is my desired output.
Comment: the (area units) should be adjustable when you select your point shapefile.
Comment: Moh, the (Area units) option remains greyed out through the whole of entering information into the tool. I tried creating a new arcmap document and re-added my layers and it is still greyed out.
Answer: Based on the tool (Point Density) that:

If the output units is anything other than feet or meters, the output
  area density units will be set to SQUARE_MAP_UNITS. That is, the
  output density units will be the square of the linear units of the
  output spatial reference.

For example,

if the output linear units is
  centimeters, the output area density units will be SQUARE_MAP_UNITS,
  which would result in square centimeters. If the output linear units
  is kilometers, the output area density units will be SQUARE_MAP_UNITS,
  which would result in square kilometers.
Comment: Thank you Moh, between this and your other answer I was able to find out what the issue was. I needed to change my data to a projected coordinate system (using the project Data Management tool). I thought I had done that already, but I did it for my Data Frame, not my actual Data. Thanks for the help!


SDK for SCIM Implementation

Question: I have developed a REST based webservice to manage user identities on a custom identity store. The API supports basic operations such as create user, update user and view user. I want to make the API SCIM compliant and provide SCIM endpoint URLs for user operations. The System for Cross-domain Identity Management (SCIM) documentation mainly talks about the specification but doesn't provide the details to create a SCIM compliant service. Is there any SDK available to create a SCIM service.
Answer: Are you using Java? If so, have you considered using the UnboundID SCIM SDK? See https://github.com/UnboundID/scim2
Answer: Here is a list of resources: http://www.simplecloud.info/#Resources
The page also contains a lot of documentation and useful links wrt SCIM.

SDK for SCIM Implementation


Testing for heteroskedasticity of time series in R

Question: I wish to test my time series data for volatility clustering, i.e. conditional heteroskedasticity.
So far, I have used the ACF test on the squared and absolute returns of my data, as well as the Ljung-Box test on the squared data (i.e. McLeod.Li.test).
In a recent paper (http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1771862, the test is reported on page 8) co-authored by a well-known researcher, they have employed the White test (http://ideas.repec.org/a/ecm/emetrp/v48y1980i4p817-38.html) to directly test for heteroskedasticity.
I have tried the same approach, however was unable to do so.
From my understanding, the White test needs residual variance (usually from a linear regression model) as an input.
Now my question is: How did the researchers perform the White test? I do not understand which inputs they used for their White test.
While searching for solutions, I have found the sandwich package which uses the vcovHC and vcovHAC functions to estimate a heteroskedasticity-consistent covariance matrix, however the input is also a fitted linear regression model..
Answer: You should try Mcleod Li Test for heteroskedasticity available in R's TSA package. That package can take just time series as input.


I need to delete a Gmail account but don't want my photos associated with that account to be lost

Question: I have three email accounts.  I need to delete one that has been found on the dark web.  Most of my photos are associated with this account as well as a few games that I am very far on. How can I save my photos and game accounts and still get rid of this one email address for good.
Answer: Remove the Gmail service from your Google Account. In order to be able to do this you will need an email address that is not used as the primary or alternative email address of another Google Account. For step by step instructions please read the official help article:
Delete your Gmail service
Related

Can I re-create deleted Gmail accounts?
Need to change email address but want to keep connected YouTube, Google+ and miscellaneous accounts currently associated
Answer: From Google Account Help:

Delete your Gmail service
  If you don't want your Gmail address and emails anymore, you can remove them from your Google Account. Deleting them won't delete your entire Google Account.
Delete Gmail
  If you use Gmail through your work, school, or other group, contact your administrator.

Before deleting your Gmail service, download your data.
Go to your Google Account.
On the left navigation panel, click Data & personalization.
On the Download, delete, or make a plan for your data panel, click Delete a service or your account.
On the Delete a Google service panel, click Delete a service. You might need to sign in.
Next to "Gmail," select Delete icon.
Follow the steps on the screen.

Note: If you use the Gmail Offline app, you will also need to clear your browser's cache and cookies.
What happens when you delete your Gmail service

Your emails and mail settings will be deleted.
You can no longer use your Gmail address to send or receive email. If you change your mind, you may be able to get your Gmail address back.
Your Gmail address can't be used by anyone else in the future.
Your Google Account won't be deleted; only your Gmail service will be removed. You'll still have your activity and purchases you made on Google Play.


Resolution Issue

Question: When I connect my raspberry pi to a monitor through an HDMI cable, the resolution gets lower at the boot of the desktop UI, but when I click on start menu it turns to 1920×1080. Sometimes it randomly changes.
I set the resolution at 1920×1080.
What is the matter?
Answer: Unless this is the result of some prior fiddling with the resolution, I'd say that either your HDMI cable, your monitor or your Raspberry Pi is broken. Try another cable, or another monitor first. Or flash a fresh Raspbian onto another SD card and boot from that. Any changes?
Answer: You can force the raspberry pi to use a specific resolution for HDMI, you do this by plugging you sd card into a computer and modifying the /boot/config.txt file.
specifically you want to uncomment the following lines:
framebuffer_width=1920 #set the resolution of the TV
framebuffer_height=1080 #set the resolution of the TV

and change the two values to the appropriate resolution for your TV

Resolution Issue


External Lookup Relationship

Question: I want to create a master detail relation ship on my contact. But instead of master detail i am able to see External Lookup Relationship. what is the use of External Lookup Relationship, and where is master detail Lookup Relationship option. Now how can we create master detail Lookup Relationship.
Comment: We need more details to answer your question authoritatively - what is the other object you're trying to link the Contact object with?  Is Contact the parent or child?
Answer: Without know what object you're linking Contact with and which is the parent or child, there are a couple of possible reasons:

Standard objects (such as Contact) can only be the Master in a Master-Object relationship.  If you want to create such a relationship, you need to do it on the child (custom) object.
Per the official documentation, Salesforce will not accommodate a master-detail relationship to a custom object that already contains data:

This is because creating a master detail relationship adds a new
  required field to the custom object (known as a "foreign key" to
  database administrators). Each data record in the object needs to have
  a valid value in the field -- it cannot be left blank.
A possible workaround is to delete the data in your custom object, and
  then add the master-detail relationship.
If you don't want to lose all of your existing data, another approach
  is as follows:

Create a Lookup relationship instead of a Master-Detail relationship. This adds the new "foreign key" field to the custom
  object, but it is not required to have a value for each data record.
  Do NOT make the Lookup "required".
Add a valid value in the lookup (foreign key) field of each data record in the custom object. (You may need to create a custom tab to
  facilitate this data entry.)
Edit the object relationship and change the relationship type from Lookup to Master-Detail.

External Lookup Relationship


How can I apply volume cube node with texture effect to different kinds of geometry?

Question:
I found this volume cube node is helpful with making the sponge-like structure. However, I can only apply this effect on the cube. How can I apply this effect to others geometry, like cylinder?
Answer: For simple figures like a cylinder, you can check if the position of a voxel from top-down view is inside a circle. You can compare the result with texture using multiply or boolean and:

Sphere is easy also:

You can try to get more complex shapes like torus:

If you want to use a complex object, that hardly can be described using math, you can use boolean operation:
Comment: Thank you so much! This helps me a lot!
Comment: Please don't add "thanks" as answers. Invest some time in the site and you will gain sufficient [privileges](//blender.stackexchange.com/privileges) to upvote answers you like, which is the Blender way of saying thank you.


Best way to claim a winning lottery ticket anonymously

Question: What is the best way to claim a winning lottery ticket anonymously?
Comment: @RyanTheLeach I assume the intent to remain anonymous to _the public_, not necessarily _the IRS_.
Comment: I suspect it wouldn't be possible, and that it would be against several tax laws in some jurisdictions.
Comment: Seven states allow winners to shield their identities (Delaware, Kansas, Maryland, North Dakota, Ohio, South Carolina, Texas)
Answer: I'm sure you won't have that problem, but just in case:
Several states allow the price to be claimed anonymously. It is unclear if the lottery company wouldn't know who you are, but it definitely means that the public and the press would not know who you are.
In the other states, you could send a lawyer with a power of attorney to handle it for you, or found a trust that receive the money, without your name being publicly on it.
However, typically you signed away your rights to anonymity by buying a lottery ticket - you agreed that if you win, the lottery company can use you picture, video, and name for advertisements, and sometimes you are even required to cooperate (meaning show up, dress nicely, and smile when they take the pictures/videos), otherwise, you simple don't get the winning price.
You can read this in the fine print on their website; each state will be probably very different.
Although the lottery company might not report you to the IRS, they will keep the highest possible tax rate from your winnings (and send them to the IRS).
If you never file with the IRS after that, you effectively overpaid on taxes, so the IRS couldn't care less who you are.
Probably the best approach is to sit the circus out, and move afterwards to a different state or country.
Comment: The IRS will most definitely know exactly who you are and what you won.
Answer: It will depend on the state. Most states do not allow anonymous winners for purposes of transparency and trust. Would you want someone from the Lottery Commission to rig the lottery in their favor and claim the prize anonymously?
One way to possibly hide your true identity is to create a Blind Trust, and claim the winnings in the name of the trust. Again, though, some states may not allow this for the same reasons.
Comment: There's no such thing as winning anonymously ... the Lottery Commission knows who won. However I think it's unethical to allow them to require usage of your person if you win.

A simple solution would be to hire law firms, which change every week, to act as oversight to insure the winners are legit.

What possible reason does the public have to know who won? (none).
Comment: @RandyZeitman I (and presumably others) mean anonymous from the _public_. Certainly the commission  (and related tax entities) need to know your identity. One reason for preventing anonymity is for transparency and accountability - would you want the head of the commission to anonymously win millions of dollars by rigging the lottery?
Comment: I believe I answered that before you apparently deleted and reposted your answer.
Comment: @RandyZeitman Not sure what you mean - I did not delete and report my answer.
Comment: You replied to my answer ... "@RandyZeitman" ... after I replied to yours. I answered your question "would you want the head of the commission to anonymously win millions of dollars by rigging the lottery" ... which is that it's not a problem, simply have oversight through law firms.


multiple if() or database read is faster?

Question: I need in onCreate() read some values based on a value that is stored in SharedPrefrences...
So i can have the values that i want after many if elseif statements or from reading the values from the database!
Which will be faster? multiple if's or search and read from the db?
Answer: The ifs are not the issue in themselves. If they do not call cpu-intensive functions, then they will be very fast, especially on Froyo or later, thanks to the JIT.
A read from the DB can be very fast, but can also be very slow. NAND is unpredictable performance-wise, and concurrent I/O will lead to a noticable delay. If you are sure that you do not call heavyweight functions in your ifs, I'd go with them.
The best way would be to wrap the section of code in
    // start tracing to "/sdcard/calc.trace"
    Debug.startMethodTracing("calc");
    // ...
    // stop tracing
    Debug.stopMethodTracing();
(taken from http://developer.android.com/guide/developing/tools/traceview.html). Then get the file from the sdcard, open in Traceview and compare both alternatives. Another, easier way is to Log.d (TAG, "Start: " + System.currentTimeMillis ());, do your code, then Log.d (TAG, "End: " + System.currentTimeMillis ()); Do this for both alternatives and see which one was faster.
Read more on the topic here: http://developer.android.com/guide/practices/design/performance.html
Comment: yes,you're right i don't call cpu-intensive functions,also i will try a speed test...
Answer: Agree with @kread but here is my notice.
As for me reading from the DB shouldn't be performed in onCreate() method as it's an IO operation. It can noticeably block the GUI thread. DB query should me moved to a separate thread.


What is the difference between a 2011 i5, and a more recent i5?

Question: I am looking at my daughter's MBP.  It is circa 2010/2011, and has a 2.4 i5. Why are processors today called the same name, but are advertised with slower clock speeds?
Answer: So lets compare the i5 family of CPU on MBP.
The i5 is a brand name for a family of processor, that is why is it still called i5.
Core i5" 2.4 13-Inch (Late 2011) features a 32 nm "Sandy Bridge" 2.4 GHz Intel "Core i5" processor (2435M), with two independent processor "cores" on a single silicon chip with a 3 MB shared level 3 cache.
The 2015 MBP has up to 2.9GHz dual-core Intel Core i5 processor (Turbo Boost up to 3.3GHz) with 3MB shared L3 cache.
Based on this alone the 2015 model is >30% faster.
Comment: Thanks for that. In the old days, we labelled each processor differently. We had the 68000, the 68010, 68030, and of course 8008, 80186, 80286, etc. I'm trying to understand the rationale (similarities?), that allow modern processors to keep the same basic name, even as you describe the differences. Is this just a marketing thing?
Comment: ps. I modded you up. Wish  I could add a couple more. This (at least to me), is important stuff.
Comment: Thanks David, yep I know in the good old days it was more clear what one is dealing with.
Comment: Could you give more details please ? is it like turbo boost is the nominal performance of the processor which is underclock for battery purpose ? I'd like to understand what's the difference between my late-2011 with 16Gb ram and ssd and a brand new MBP


Cartoon where a little kid controls a huge robot which used to be small toy using glove

Question: I remember a poor kid (main lead) who can't afford that much studies which rich kid. He saw a toy and wants to play with it. The rich kid broke it and threw it away but he took it from the trash tries to repair it. Something happened and the robot becomes huge and does whatever the kid says, gives him a glove where it shows different mods of that robot in a circular holographic disk form. He uses it to fight aliens (I guess).
Answer: Heroman

Orphaned American boy Joey lives with his grandmother, working at a restaurant in the West Coast city of Center City (センターシティ Sentā Shiti, based on Los Angeles), while going to school. Upon hearing of a new toy robot called the Heybo, Joey believes that getting one will make his life better, turning him into a hero to protect his friends and family. However, he cannot afford to buy it on his meager salary. His luck changes when he picks up a broken down Heybo abandoned by a school bully. He tries to fix it, naming it Heroman, but does not have any luck in getting it to work. However, when it gets struck by a bolt of strange lightning, it transforms into a giant robot, just in time to save his friend Lina from impending danger. Now, Joey and Heroman are Earth's only defense against the evil insectoid Skrugg (スクラッグ Sukuraggu) aliens, unknowingly summoned to Earth by Joey's science teacher.

Joey, Heroman, and Joey's circular glove, can be seen in the cover of the first issue of the manga:

Trailer

Found by searching for anime poor kid giant toy robot after searching for cartoon poor kid giant toy robot failed to get a good answer.
Comment: If this is your answer, you can accept it by clicking on the checkmark by the voting buttons.


Markov inequality with coin flips

Question: Let's say Dave has a biased coin with P(heads)=0.6. He tosses this coin $N$ times and, out of the $N$ times, the coin lands on heads 134 times. He says that the probability of seeing at least this many heads is at most 0.8. The best lower bound, using Markov inequality, on the number of times John tossed the coin = $0.8 * \frac{134}{0.6}$. However, I do not quite understand the intuition behind this. Given that he saw 134 heads, it makes sense to say that the total number of flips is 268. However, I don't quite understand how the information about the probability of seeing at least 134 heads can be factored in. Can someone explain this on a high level and explain how it leverages the markov inequality?
Comment: "Doesn't that make it unbiased? " Yes. Are you sure you got it right?
Comment: Yes, I typed it word for word. Perhaps the value P(heads) is set to random values using a random number generator and that's why the wording is "baised"
Comment: I edited the question and reassigned the $P(heads)$ so that it is less confusing.
Answer: I think I understand now. What we have is the following:
$$P(X \geq 134) = \frac{N*P(\text{heads})}{134}$$ $$0.8 = \frac{N*0.5}{134}$$ $$N = \frac{0.8*134}{0.5}$$

Markov inequality with coin flips


Minimal distance from origin to quadric surface

Question: How can we find the shortest distance from the origin to the following quadric surface?
$$3x^2+y^2-4xz = 4$$
I see lagrangian multipliers being used, partials and such, but have trouble organizing into a different setting. Thanks.
Comment: Please use LaTeX when writing mathematical expressions - makes your question easier to read :)
Answer: Minimize $x^2+y^2+z^2$ given $g(x,y,z)=3x^2+y^2-4xz=4$
Let $f(x,y,z,\lambda)=x^2+y^2+z^2+\lambda (3x^2+y^2-4xz-4)$
Now, using Lagrange Multiplier Method,
$\frac{\partial f}{\partial x}=2x+6\lambda x-4\lambda z=0$
$\frac{\partial f}{\partial y}=2y+2y\lambda = 0$
$\frac{\partial f}{\partial z}=2z-4x\lambda = 0$
Also $3x^2+y^2-4xz=4 $
Solve these four equations in four variables, you will get the nearest point $(x,y,z)$
But, check Hessian also to assure whether point gives minima or maxima or saddle point.
Answer: You want to minimize the function
$$f(x,y,z)=x^2+y^2+z^2$$
which represents the distance squared of a point with coordinates $(x,y,z)$ to the origin $(0,0,0)$ provided that point also lies on a quadratic surface with equation
$$g(x,y,z)=3x^2+y^2-4xz=4 \; .$$
Several techniques are possible. You could find an explicit formula for the coordinate $z$ in terms of $(x,y)$:
$$z=\frac{3x^2+y^2-4}{4x}$$
and substitute it into $f(x,y,z)$ which will give you a new function $\tilde{f}(x,y)$ of two variables. You now have to look for the minimum of this function. Also note that by constructing the explicit formula, we divided by $x$ and have excluded potential minima with $x=0$. These have to be handled separately.
The other most common technique is the technique of the Lagrange multipliers. Again, starting from the function and condition, you construct the Lagrangian
$$L(x,y,z,\lambda)=f(x,y,z)-\lambda(g(x,y,z)-4) \; .$$
You know look for the critical points of this Lagrangian by computing the partial derivatives to every variable and then equating the results to 0 each time. You thus obtain a set of 4 equations for 4 variables. The solutions of these equations are candidate minima for the function $f(x,y,z)$ satisfying the constraint $g(x,y,z)=4$. You thus are left with checking which of those are indeed minima.


Wireshark capture filter from list file

Question: Is it possible to pass Wireshark or tcpdump a file containing a list of host IP addresses and/or networks to be captured?
Answer: Both have mechanisms for filtering your capture, but you'll need to create a filter in the expected syntax (BPF) rather than just providing a list of IP addresses to include or exclude.
Wireshark has the additional capability of filtering the displayed packets while capturing all of them. The syntax for this is different.
https://wiki.wireshark.org/CaptureFilters
https://www.wireshark.org/docs/wsug_html_chunked/ChWorkDefineFilterSection.html
http://www.tcpdump.org/manpages/pcap-filter.7.html

Wireshark capture filter from list file


Analysis Services 2008 configuration for OWC 10

Question: We're upgrading a data warehouse from SQL Server 2000 to 2008 R2. A favorite user reporting tool is a web site using OWC 10 (Office Web Components) -- it's basically ASPX pages connected to the Analysis Services 2000 database via the OWC object.
We migrated the warehouse SQL tables and Analysis Services database into 2008. I'm trying to get the OWC10 web site to connect to the 2008 R2 Analysis Services. I changed the ASPX connection definitions to the new server, and can see them in debug messages. However the web page gives me the error "Cannot connect to the server 'blahblah.blah.com' The server is either not started or too busy."
I suspect there are permissions or security setups required to open up Analysis Services 2008 for OWC10 queries. Has anyone done this or similar? Any ideas where to look?
Thanks.
Answer: change the provider in the connection string to MSOLAP.4 instead of the default MSOLAP.2


Why isn't the magnetic and electric flux, $\Phi_E$ and $\Phi_M$, typeset in italics?

Question: In many references including Wikipedia, electric flux and magnetic flux is written as $\Phi_{E}$ and $\Phi_{B}$, respectively. But they are not vectors (even then, they have to be bold) nor units. I think they should be written as $\it{\Phi}_{E}$ and $\it{\Phi}_{B}$. Shouldn't they?
Comment: @EmilioPisanty I think this question falls squarely under Qmechanic's type 2: "What is the standard notation for this quantity?" Why do you think it's not covered? Because typography is distinct from a narrow idea of "notation"?
Comment: @BioPhysicist "I have never seen anyone make an explicitly stated distinction between italics and non-italics variables" $-$ you *absolutely* have, starting with this very site (though it is understandable if you have failed to notice). Notating the distinction between variables and operators by typesetting them in italics and upright type, resp., is essentially universal in professional typesetting. (Consider e.g. the difference between $sin(x)$ and $\sin(x)$.) OP's concern ("why does this universal convention not extend to this symbol?") is perfectly reasonable.
Comment: @BioPhysicist I disagree that this is opinion-based. This is a question on historical consensus. (It could be migrated to the History of Science SE, possibly, but shouldn't be closed as opinion-based.)
Comment: @BioPhysicist As I said, if you haven't seen the distinctions (if you want, seen them explicitly stated), it is only because you have never looked at the natural places where they are stated. This is a perfectly objective question, and it isn't really covered in the off-topic categories in [the canonical Meta thread on notation questions](https://physics.meta.stackexchange.com/q/1083), either. Just sayin'.
Comment: @Acu I disagree with that characterization but I won't push the point either.
Answer: It is generally very unusual for uppercase Greek letters to be typeset in italics, though this depends on where you are.
Quoting from the Wikipedia page Typographical conventions in mathematical formulae, as far as 'international' recommendations (specifically IUPAC, NIST and ISO) go,

anything that represents a variable (for example, h for a patient's height) should be set in italic type, and everything else should be set in roman type. This applies equally to characters from the Latin/English alphabet (a, b, ..., z, A, B, ..., Z) as to letters from any other alphabet, most notably Greek (α, β, γ, ..., ω, Α, Β, Γ, ..., Ω).

That same Wikipedia page blames the exception on the "American" system:

the American rule that italic type is used for all letters representing variables and parameters except uppercase Greek letters, which are in upright type.

In practice, this "American" convention is the default setting on LaTeX systems (unsurprising, since Donald Knuth is American, and the default mathematics package is the AMS standard), which has since become the de facto standard worldwide. Indeed, that is what this site does: note how italics are used on <code>$a A \mu \Gamma$</code>, which produces $a\,A\,\mu\,\Gamma$, with an upright $\Gamma$.

As a general rule, there are no hard rules when it comes to typesetting: there are only conventions, with varying degrees of universality.
If you are writing for publication, the only rules you have to follow is the style guide of the publication venue you are writing for. (As an example, if you are publishing in an APS journal, you have to follow the Physical Review Style and Notation Guide, which specifies in §IV.A.1, p. 16, that variables in Latin script are typeset in italics and variables in the Greek alphabet are typeset upright.)
If you are writing for your own use or for 'self-publication' (say, handing out notes to students), you can use whatever conventions you feel are most appropriate. There is definitely a strong push to use a consistent notation within each document (or series of documents), but that's about it.
If you are reading a document: unless the document's notation is so chaotic that it induces actual confusion about what the content is, complaining about superficial matters is... well, superficial.


Can broad and narrow transcription be distinguished by whether a transcription makes use of diacritics?

Question: When doing transcription of English (British or American) in IPA, is broad transcription exactly the kind of transcription which doesn't make use diacritics, and narrow transcription the kind which makes use of diacritics?
Answer: No.
First off, "broad" versus "narrow" transcription is a spectrum. One transcription can be broader or narrower than another (or broader/narrower in particular ways) but there's no firm dividing line that makes some transcriptions "broad" and others "narrow" in a vacuum.
But also, a very broad transcription can use diacritics: the Kota language has a three-way contrast between dental, alveolar, and retroflex stops, and the IPA doesn't have three separate symbols for those, so any useful IPA transcription (no matter how broad) will need to find another way to distinguish them. Outside of IPA, it's common to use symbols with diacritics like š or č in broad transcriptions.
Similarly, a very narrow transcription doesn't always need diacritics. If you're transcribing a perfect exemplar of a high front unrounded vowel in IPA, then that's simply [i], no diacritics needed.
Answer: For English, that is a reasonable standard. There are languages with phonemic distinctions ("broad transcription") that require diacritics such as the dental vs alveolar distinction, or sonorant phonatory distinctions like [a̤] versus [a], or [m] vs [m̥]. Any such differences are part of narrow transcription in English. You could decide that [i] is really "advancd i" so you could systematically write [ɪ̟] instead of [i] (English "i" is far enough off from the IPA reference value that this is viable), but the desideratum of only using diacritics when unavoidable rules against that choice, therefore broad transcriptions should be as diacritic-free as possible. More accurately, the broadest transcriptions exclude all sub-phonemic detail, then you can include more and more sub-phonemic detail is an increasingly narrow transcription, which will at some point include diacritics and also auxiliary (often phonemic – but general-purpose) symbols like [ʲ ʰ].


Change current page to account of it's own

Question: I currently have a business Facebook page connected to my personal Facebook . How do I make that page an account of it's own and keep all the likes and history?
Answer: What you can do is, create a new profile or account for your business, then using the current profile make the newly created account admin of the page and then remove yourself as admin.


Configuring UART TX and RX pins to accept CAN TX and RX signals

Question: The microprocessor I'm using, the BeagleBone Black, has an option to send CAN messages to/from it through the UART Tx and Rx pins. I'm not sure, though, if this is a 1:1 translation (i.e. the UART TX port corresponds to the CAN TX port) or if it's vice versa (i.e the UART TX port corresponds to the the CAN RX port).
Comment: What is the question?
Comment: CAN doesn't have TX and RX, it has High and Low. You need a transceiver to connect TX/RX signals to the CAN bus. What transceiver are you using and is this not covered in its documentation?
Answer: No, UART port does not directly correspond to CAN. In the Beaglebone you have physical pins that can be muxed to different peripherals, say pin E16 can be configured as UART0_TXD or as DCAN0_RX, but you can as well have pins that can be configured for CAN but not for UART (say pins D17/D18) and vice versa.
If you need a CAN functionality you need to configure your pin as a CAN RX/TX port in your device tree (or device tree overlay). Then, as @nekomatic  says you need to connect CAN RX/TX to an external CAN transceiver that eventually should be connected to the CAN bus.


Will PDF 2.0 compatible with PDF 1.x

Question: Will a valid PDF 1.x document be a valid PDF 2.0 document? Will PDF 1.x readers gracefully accept PDF 2.0 documents?
Answer: Those who worked on PDF 2.0 in ISO made great effort to be as compatible with present-day implementations as possible and to break as little as we could possibly do. Some changes (like adding UTF-8 string object support) weren't possible in a means that is totally backward-compatible. Most changes, however, are clarifications to the standard and updates to better align the ISO standard to the behaviors of implementations. For example, the section on Tagged PDF was rewritten in a way that is much clearer and easier to understand, and includes a new tag set for PDF 2.0 that does not match the PDF 1.7 tag set. However, the PDF 2.0 tag set is not the default - the default remains the PDF 1.7 tag namespace - so that Tagged PDF files can be promoted to PDF 2.0 without the tags needing to be rewritten.
PDF 2.0 is an evolution of the PDF standard, not a drastic change to the specification. It does include some new capabilities - such as the ability to specify string objects in UTF-8 format - that PDF 1.7 viewers will not be able to handle correctly. However, most PDF 1.7 viewers should handle most PDF 2.0 files perfectly well. In this respect, your comparison to PDF 1.6 vs. PDF 1.7 is a fair comparison: viewers that don't know about PDF 2.0 revisions or features will either ignore these or not handle these correctly. However, I expect most PDF 2.0 files will be written in a way where they are compatible with present-day PDF 1.7 viewing implementations.
If you're interested in more information, Peter Wyatt's presentation at PDF Days Europe 2017 can be downloaded from https://www.pdfa.org/wp-content/uploads/2017/05/PDF20Keynote.pdf ; or you can watch it via https://youtu.be/AR4lGlDh9Ac.
Disclaimer: I am the chairman of the PDF Association
Answer: No, a PDF 1.x document is not a valid PDF 2.0 document.
A PDF 1.x document could be a valid PDF 2.0 document if at the very least the only changed required was the version number in the PDF. There are a number of other changes required for PDF 2.0 though like appearances for annotations being defined in the PDF (in 1.x they were optional and viewers would generate them on the fly if not found or simply not display anything) and the deprecation of XFA.
Some PDF 1.x readers may accept PDF 2.0 documents. It will be up to the vendor though to determine what level of support they offer for PDF 2.0 .
Comment: So is PDF 2.0 a huge breaking change from 1.x or are the differences between PDF 1.7 and 2.0 similar to the differences between 1.6 and 1.7?
Comment: It is not a huge breaking change, there are a number of things that have been deprecated and should not be written into PDF 2.0 files and a number of issues in the specification addressed where the language was ambiguous and was interpreted differently by implementors. There are also new features, some of which are things that have been supported in PDF through extension levels defined on top of 1.7 by Adobe. For more specific information about these changes check out the PDF Association article : https://www.pdfa.org/what-will-pdf-2-0-bring/

Will PDF 2.0 compatible with PDF 1.x


What cannot stand outside a door?

Question: Let there be a house of which there is a beautified front door that is closed. Now: what is that "thing" for which it is impossible, logically (and irrefutably), to be outside this closed door?
Comment: The door, the house, a square circle...
Comment: My irrational friend, it is very much possible to construct another house (a small one it may be, with a lesser height) outside the door of the house mentioned. It is logically possible, that is what I say. And the answer to the question, is of such a kind that it is impossible, very much impossible, logically, to be outside the door.
Comment: @Kalis: he did not say "a door", he said "*the* door". Your puzzle has too many answers.
Comment: @Kalis Welcome to PSE. As you have noticed, questions of this nature tend to come under high levels of scrutiny. It is very difficult to create such a question that truly only has one answer. As such, most of these questions are closed as being too broad. I would suggest adding limiting clues/suggestions in order to try and limit the possible answers and thus allow your question to be reopened.
Answer: I'm gonna go with...

 The inside
Answer: There are probably many answers, but here:

 The threshold

What cannot stand outside a door?


Regression of circular variable with scikit-learn

Question: I am trying to use Support Vector Regression on a (neurophysiological) dataset where the position of points on a circular manifold in N dimensions is correlated with a circular variable (phase of an oscillation of a separate system).
Before starting, I am trying to solve this on a dummy dataset. I have dots from a circle $X$, plus some noise, and each is associated with a circular variable $y$ which is the angle of the dots, plus some noise (this recapitulates reasonably well my dataset, which has just more dimensions and a less regular circular manifold - just stating this in case there might be better approaches than what I am describing below).
from matplotlib import pyplot as plt
import numpy as np
from sklearn import svm
from sklearn.model_selection import train_test_split

n_points = 1000
rad_sd, phase_sd = 0.2, 0.5

angles = np.random.rand(n_points) * 2*np.pi
X = np.array([np.cos(angles)+np.random.randn(n_points)*rad_sd,
              np.sin(angles)+np.random.randn(n_points)*rad_sd]).T
y = angles + np.random.randn(n_points) * phase_sd

f, ax = plt.subplots(figsize=(3, 2.5))
im = plt.scatter(X[:, 0], X[:, 1], c=y)
ax.set(xlabel="$x_1$", ylabel="$x_2$")
plt.colorbar(im, label="phase $y$")
plt.tight_layout()

I am then fitting the vanilla SVR to the data:
X_train, X_test, y_train, y_test = train_test_split(
    X, y, test_size=0.5, random_state=42)

regr = svm.SVR()
regr.fit(X_train, y_train)
predicted = regr.predict(X_test)

f, ax = plt.subplots(figsize=(4, 3))
ax.scatter(y_test, predicted, lw=0)
ax.set(ylabel="Predicted $y$", xlabel="Test $y$")

Which looks very good, apart from having a problematic transition from $0$ to $2\pi$.
I guess that what I would need it to somehow make the optimiser know that this is a circular variable, and that distances for the fit should be calculated accordingly. It is not clear to me however how could I add a step to the pipeline/modify the loss function to get that distance calculated.  I get the feeling that any kind of optimisation I try in scikit-learn would need to deal with this issue
Any clue? Thank you very much in advance for any pointer that could help me with this problem!
Answer: Found a solution thanks to other posts here. It is possible to fit to more than one $y$ the model; so I regressed $\sin(y)$ and $\cos(y)$ in a MultiOutputRegressor model and took the $\arctan2$ of the solutions:
from sklearn.multioutput import MultiOutputRegressor

y_train_multi = np.array([np.sin(y_train), np.cos(y_train)]).T
y_test_multi = np.array([np.sin(y_test), np.cos(y_test)]).T

regressor = MultiOutputRegressor(SVR(kernel='rbf', C=1e3, gamma=0.1))

regressor.fit(X_train, y_train_multi)
prediction = regressor.predict(X_test)

angle_predicted = np.arctan2(prediction[:, 0], prediction[:, 1])

f, ax = plt.subplots(figsize=(4, 3))
ax.scatter(y_test, angle_predicted, lw=0)
ax.set(ylabel="Predicted $y$", xlabel="Test $y$")


Can I charge a simple Nokia phone which has USB input (5V=450mA) with a 5V=2A/7V=1.8A/9V=1.8A/12V=1.3A supply?

Question: I have a Nokia Asha 501 Dual Sim phone which comes with the power supply as stated in the title. It recently broke, and I decided to test if the phone's USB port which I thought was only for data transfer will act as supply as well. It did, surprisingly for me. I have 3 chargers, one is an original firm charger from another device and others is cheap ones. The original one and one of cheap ones has 5V=2A and other cheap one is all from the question title (except 5V=450mA).
I observed how they all charge the phone, and the cheap ones make the phone glitchy and heat the charger extremely fast. The original one seemingly charger fine, no extreme heat ups or glitches of the phone.
However, are the supply specs itself safe? Will they fry the phone eventually and/or something?
Comment: If this is off-topic, [why this isn't?](https://superuser.com/questions/600401/can-i-use-a-charger-with-more-output-amperage-than-the-device-needs/600426#600426)
Comment: @grawity depends how you look at it, USB isn't unique to computers. Either way, this is either off-topic, or a dupe.
Answer: You can fry the phone with a voltage too high, or inversed polarity. If the charger provides 2A, but the phone only needs 450mA, there's no problem. The charger heating, maybe the phone draws more than the charger can provide.


Snort Sensor Placement

Question: I have a snort sensor monitoring some of my network being fed from a mirrored port. This mirrored session only monitors traffic between the firewall and peering switch. Since this just sees traffic enter/exiting our network we miss a lot of internally routed traffic. What useful places on the inside of our network should I be looking at to place more snort sensors?
Comment: Let's go for more paranoia than not.
Answer: Sensor placement can be very tricky as there are loads of variables to consider. At minimum, you should take into account

Classification level of monitored resource
Network design
System throughput
Personnel time (for management and analysis)
Resource availability

Throwing all of those into a blender and turning on high for a few minutes will give you some nice data to start with for determining your deployment. Deployment planning is a multiphase process, and while they are not intrinsically separated, it is beneficial to remember that they are different parts of the same plan.
Data Collection and Planning
More likely than not, what you're going to want to do is construct a list of all of the systems that you want to monitor, then rate them based on importance or risk. That should give you a prioritization of what systems you really need to be watching now. In a perfect world, we would have a sensor monitoring the link connected to each and every system. However, that would be scary expensive, difficult to maintain, and noisy. Instead, talk to your network team and take a good hard look at your network design. Figure out on the network map where your prioritized systems live and figure out where the choke points are. Look at what hardware you have available to turn into sensors. In an awesome environment, you could have one big box with a few 10Gbps interfaces and do all of your monitoring for an entire enterprise using a single sensor. However, more likely, you're going to have a few surplus systems that used to be used by department secretaries and will need to spread the load.
Array Design and Deployment
Now is the time to think long and hard about what risk acceptance threshold is. How close to the sensitive data do you feel like you need to have a sensor, and how far away do you feel comfortable placing it? In some cases you may really need to monitor the switch port that a server is directly connected to. In other cases placing a single sensor on a building or floor uplink, and ignoring any intra-switch traffic, is sufficient. In another case you may feel as if mirroring a specific port is not good enough, and instead mirror an entire VLAN.
Workload and Other Considerations
As you're building our your sensor deployment strategy keep in mind that it can get very complicated. As you decide where to place your sensors, make sure to account for all of the other issues that arise. For every sensor you deploy there will be management overhead for an employee to actually maintain the system (apply patches, hardware replacement, etc), application management overhead (updating signatures, tweaking rulesets, making sure snortd stays running), and analyst time (interpreting the alerts and taking action). Depending on  your design, and how much time you're willing to front-load, these numbers can vary wildly. For example, using the right configuration management/automation tools, it's not that difficult to manage several dozen snort sensors using a fraction of an FTE.
Comment: @ktothez: You've ended up asking an exceptionally broad question whether you meant to or not. As you go through the process pop up other, more specific, questions that you run into. Don't get discouraged, I have some of my most fun when doing sensor installs!
Comment: I guess it was pretty broad.  Thank you though.  I'll ask if I run into something.
Answer: If you have Cisco networking equipment you can use Catalyst Switched Port Analyzer (SPAN)  to mirror traffic from a port to another one which you have your snort sensor on.
Their is a Cisco SPAN Configuration example at http://www.cisco.com/en/US/products/hw/switches/ps708/products_tech_note09186a008015c612.shtml.
Other networking equipment has similar capabilities.
We use this to mirror all outbound and inbound traffic on our network without inserting a device in the flow.

Snort Sensor Placement


Member from group with edit permissions can't add/edit items, other users from same group can

Question: I have this weird thing where sometimes, a user contacts me to say they can no longer add or edit items from a document library or list. When I check the groups that have edit permissions on those lists or libraries, the user usually is a member of that group.
So I have a user X, who is member of group Y. Group Y has edit and read permissions on list Z. All other users of group Y can add or edit items from list Z. But user X can't.
What causes this? And even weirder, if I remove user X from group Y, then add user X to group Y again, user X all of a sudden can add or edit items from list Z. Why couldn't user X do so before? Is there a known bug or issue or anything else known about this? It's something that I occasionally see, roughly once every two months or so, but it's been going on for over a year now and I'd like to know why this is.
Any help would be greatly appreciated.
Answer: Magali,
This very same problem happened to us not too long ago...and I was pulling my hair out for days. It may not apply in your case, but some of our user AD accounts were recreated for some reason. Even though their user name stayed the same, the SID is different when you recreate and account. We had to do exactly what you mentioned. We had to delete the user from the group and add them back for the new SID to take.
Check with your AD administrator and see if this has been happening.
P.S. Congrats on living in an amazing area...once drove from Heidelberg to Ghent just to fill up a car with Tripel Karmeliet. Good times...