Why are transform values in inspector different from animation tab?

Question: I'm trying to make animation in timeline. But transform values in animation tab and inspector are different from each other. It causes problem when ı try to rotate player. It doesn't rotate the way I want.
Answer: Let me say first that Unity inaccuracies on the scale of, i.e. 0.00001 is completely normal.
In your case, it's far off from that. The reason to that could have different reasons.
If it rotates back to it's original position for example it might be because of "Apply Root Motion" being unchecked.
However, in your case, it seems to be a general problem.
The warning message at the bottom could be the reason why this problem occurs. Setting an inital offset on rotation can mess up transform values. So make sure that your rotation is set to 0, 0, 0 prior to recording.
If there are more Unity warning messages, please share them so we can help out further.
Comment: Really thanks for your interest . I found solution

1)Right click "Rotation" on the left side of the animation pane

2)Hover "Interpolation"

3) Select Quaternion

And ıt worked! Now the object rotates the way I rotate


Java HttpClient get http reponse body missing carriage return (CRLF)

Question: Use httpclient to get response body and found the CRLF is replaced by white space.
if I check the request url with parameter manually(in browser), I can the the xml format response in expected format(with new line break). After I use ....BodyAsString().. then print... everything is in one line and the place supposed to be carriage return is replaced by white space.
Please help... Thanks in advance.
Answer: You need to set the Content-Type header to UTF-8 when transmitting your data over HTTP. This should solve your problem.
Comment: The data I get from a web service(in this web service it calls db and get the data. I cannot access the web service code ), the only thing I can do is send the request and receive the http response. So that means I cannot set the content-Type. Right?
Comment: yea there is nothing to do in that case :). you can check with the WebService author if they handle this.
Comment: From the http response in browser I can see the new line break, but after I get the response by using Java httpClient, I cannot see it anymore.
Comment: dont you see them as CR LF characters? these are not displayable characters.Are you reading the response character by character from the outputstream? If not give that a try.
Comment: I get the http response(the xml format) and I checked it--view source(in IE browser) I can see the expected format with carriage return. I use httpclient and get the response body as string, then I print the response string, I found the place supposed to be carriage return(crlf) that is replaced by "white space". How could that be? why?
Comment: Java String encoder treat CRLF from http as white space?
I am pulling my hair because of this issue....


How to Use 'Consequently' in Academic Writing

Question: In class, our teacher talked about different ways to use consequently. We can use it at the beginning of a sentence, or use it after colon(;) to connect two sentences. However, our teacher say that we can put consequently between commas to connect two sentences.(e.g.: The weather is good, consequently, we can go picnic today.) The teacher said consequently can be used in the third way for academic paper. But I am just not sure it can be used this way. Can anyone help me with this question?
Answer: Your teacher is incorrect; "The weather is good, consequently, we can go (have a) picnic today." uses a comma splice, which is considered an error, particularly in the strict context of academic writing. Stick to the first two methods.
Answer: I'm sure some people write that way — it's not unusual to see a comma where a semicolon would be more appropriate — but that's not specific to consequently, it's not specific to academic writing, and it's not a good model to follow.
Your teacher may have been led astray by (standard) usages like "Everyone seemed to agree with the proposal; I felt, consequently, that I had no choice but to go along with it." In this example consequently is surrounded by commas because it's embedded inside the "I felt that […]" clause.
Answer: "This research shows that dogs are more likely to eat brand one over brand two. Consequently, owners are feeding their dogs brand one, even though it stunts dog growth."
Use it in the exact same way!


ASP.NET MVC 5 mask download link to Amazon S3 resource

Question: I'm using Amazon S3 to host multiple files on my ASP.NET MVC web application, but in order to allow a download, I'm sharing with the end user the direct S3 url, so I have many security issues, like if the user shares this link, it would perform download directly without requiring to sign up on my site, or that they know on which Amazon S3 Bucket their files are hosted. What options do I have in order to mask this download link so the user should authenticate first on the site?
Answer: If you share the S3 link to your hosted file and you have the bucket set to public access, you can't really control much.
You would need to create a proxy endpoint that handles your authentication, then streams the S3 hosted file to your response.
Comment: I want to change the bucket access level too. Is there and example of how to do this? I automatically thought of a 301 Redirect but I think I could still present flaws


Ensemble neural network

Question: I had run artificial neural network on Matlab. Although i used the same design structure of ANN and the same data set, the result always different. Some suggested using ensemble neural network. From my reading ensemble is combine ANN with different design structure. Do this applicable in my problem. Other than that, why is ANN produce different result every time i run it?
Answer: Why ANN produces different results: this is probably the training procedure involves "randomness", for example,

Your training may use random parameter initialisation.
Your training may use random dropout as regularisation.
Your training may use SGD and shuffle the data order every epoch.
...

And ANN is a not a convex function, so any of these "randomness" may lead to different local optimum.
And ensemble method is a very general method to reduce the variance of predictor then improve the performance. It is not necessarily specific for ANN. And there are many ways to train an ensemble of ANN (like using different datasets, using different initial parameters, using different structure/dropout). This is really an "art" which means you need to try a lot and pick the best way for your specific dataset.
Comment: If i only have one data set, Can i only take the average of the output?
Comment: @bbadyalina you can try different parameter initialisation. You can also obtain multiple datasets by bootstrapping the one dataset you have. Just to remember that, if you are using averaging ensemble method, try to "decorrelate" the different models as much as possible  (i.e. make them as noncorrelated/independent as possible).
Answer: Your second question is more simple so I'll answer that first.
When you train an ANN you start with random weights in the network. The network is trained to try to minimize the cost function of training. We usually cannot find the exact minimum of the cost function during training so each time you train an ANN it starts with different weights and ends training with different weights.
Training a single ANN is quite costly so it could be difficult to train 10 ANNs and make an ensemble of them all. Instead we use a clever trick called dropout when training one ANN, dropout is a type of regularization which acts like training an ensemble of networks inside one network.
Here is a description of dropout, scroll down to read about dropout.
Comment: So if train the network ten times using the same structure, and take the average of the output. Is that reliable result?
Comment: @bbadyalina Yes if you have the computing power to train a network 10 times then taking the average output is more accurate. You should use the standard deviation of the output to create a confidence interval and use that to understand how reliable the average is.
Comment: ok hugh.. is there any reference that i can use for this method.. or it is the same as ensemble ANN.. from what i read ensemble ANN is combine different sturucture of ANN. but i did not find any of regrading single structure.
Comment: @bbadyalina The ensemble will work if you use the same structure for all ANN's but it helps if you use different structures. I don't know any references for choosing the different structures
Comment: If for same structure, do have any reference?
Comment: @bbadyalina ensemble will work with any models that are pooled or averaged, there is no need for an ANN study to show this.

Ensemble neural network


Is retransferring possible between Xbox One and 360 on GTA V?

Question: I hope so. Otherwise its pointless for me to continue playing GTA V on the Xbox 360.
Comment: Just to get this clear, do you mean to transfer a second time?
Answer: You can transfer from the Xbox 360 to Xbox One, but it is a one time process.
What actually happens is that a copy is made of your Xbox 360 profile at the point it is transferred.  Any future progress made on the 360 profile does not reflect on the Xbox One profile.  They will both be independent of each other.
The process is detailed on Rockstar's official site.


Where to learn texture painting?

Question: Texture painting has been really hard for me. Can anyone recommend me a nice place to learn texture painting to lighten my headache?
Comment: Really need a better description and examples of what you expect to learn to do with regards to Texture Painting. You have from Physically Based Rendering examples as Substance Painter styled realism to hand painted styles in World of Warcraft, and many different examples between them. I have my own youtube channel exploring all the many facets of painting in Blender, but it is very unconventional and I don't teach a 'style' , I teach the tools and work arounds to get things done.
Answer: Xrg have made a very nice tutorial serie about texture painting. However it's not focused on PBR (for that you probably need to look at Substance Painter).
https://www.youtube.com/watch?v=jR7Axe2hbz8&list=PLNHJ5gduZOiWXtbeiZZi3q082bclOHQY4
and
https://www.youtube.com/watch?v=L7ALfRw6I5I

Where to learn texture painting?


When braking I hear/feel a clunk at 40km/hr

Question: I have a 2004 Toyota Sienna.  When I am braking, I hear a clunk sound. I can feel it as well. Kinda like I have something rolling around in the back, but I don't.  Thing is, this only happens when braking when I get to 40km/hr.  I took it in and they did the brakes for me but it is still happening.  Why only at 40km/hr?
Answer: I have a similar clunk on a 96 Intrepid. I never did officially find out what it was, but my best guess has always been the transmission disengaging due to the application of the brakes.
Comment: I have similar ifni hard brake. So I experimented. Drive at 60 put in neutral and then hard brake. Did not feel it at all. So concluded I had was you describe and ignore it. For me it happens around 30 km/hr


How To Animate With High Poly Mesh

Question: I wanted to provide an answer for this question I was struggling with. You have a model and armature with a high poly mesh. How do you lower the mesh poly count and apply the same animation to it? I got you covered, here is my personal method, proxy-free!
Answer: Basic Rundown:
With the rigged high poly mesh, you will duplicate the mesh and rig, lower the poly count, animate with it, and then apply the animation from the low poly rig to the high poly rig.
Directions:

Make sure high poly mesh and it's rig are all present in a collection.
Duplicate the entire collection. Make sure to label the mesh, armature, and collection all as low poly to avoid confusion.
Lower the poly count of the mesh. With your statistics enabled in the Viewport Overlays tab, go to Modifiers < Decimate, and lower the ratio until the model is safely around 20,000 triangles. Make sure the Decimate Modifier is above the Armature Modifier, and apply the Decimate Modifier.
Animate and apply animation to high poly mesh rig: Now you can animate freely with the mesh not bogging down your system. Animate the low poly rig. In the Action Editor, label this animation as the low poly rig. Click on the armature of the high poly rig, locate the low poly rig animation, and apply it. Done.
Comment: Helpful. Thanks!

How To Animate With High Poly Mesh


How do you increase a Blade's strength?

Question: There are a lot of merc missions that require a certain strength to proceed with them. Since this seems to be the only thing in the game using strength, is it right to assume that just sending them on merc missions will increase their strength? Or do they have to be the leader, or is it entirely random?
Comment: Done a lot of missions with some persistent teams, and I don't really think strength is supposed to be increased at all.
Comment: Also, some people say that strength actually increases damage of physical arts.
Comment: @lentinant strength definitely goes up. Kora for me started at 20 something str, and is now up to 37. Wulfric is up to 57. I just need to know how it goes up. It looks like merc missions but it's hard to tell.
Answer: I don't quite understand the correlation, but for the lot of blades I checked, it seems to be +/-2 from the number of orbs they've unlocked in the affinity tree. So, the safest bet is to just unlock more orbs and strength will go up as a result.

How do you increase a Blade's strength?


How to transfer remote files in Aptana Studio 3 when connected via Connections Manager?

Question: How to connect to remote files from Aptana Studio 3 without connecting to FTP. On rt-click I only get "Run web deployment wizard" and no other options like "Transfer files and all other options". And I am connected in connections manager.
Comment: How do you want to transfer that isn't FTP?
Answer: Apparently your project is not connected.  If you follow through with the "Run Web Deployment Wizard" it will ask you for your ftp credentials, etc.  After that, you should be able to edit the files in the project and transfer them without bothering with the ftp information again.  I think that the wizard will come up one time for each project you connect to a remote server.
I have a remote project and when I right-click, I get options for transfer of files.  Your connected project should have a subfolder called "Connections" which contains all the files in the project. I wanted to upload screenshots of my project view, but I don't have the permissions yet.


Virus protection for flash drives

Question: At school, there is a large network with lots of non-technical minded people and lots of viruses. How can I protect my flash drive from these worms and viruses so I don't bring them home and infect my home computers?
Answer: I actually just use a small SD card reader and an 8GB SD Card.  I set the locked switch on the SD Card so that nothing can jump onto this card.
I did look for a large capacity Flash/USB drive with a lock switch, but they're hard to find these days.
Comment: In my opinion, this is what answers the best the question, as it is the only way to make sure you won't catch a virus on a school computer. However, this has the major drawback that you can't write on the key, only read its content.
Comment: If no data was to be moved from school to home, there is no need for a locked drive. Just format it straight on the next use.
Answer:
Configure your home pc to never autorun USBs when they are mounted
Keep a policy to never get home executable programs from school

get compilable sources and recompile :-)
if you need tools from the web download straight from home

Keep the USB connected at school for a minimum time when transferring data

Of course, if you are happy with moving data from home to school
and never want to get any back home.
Just format the USB every time you get it back from school.
Comment: +1 for disabling autorun. Always disable it for everything.
Comment: In this case it's more a "what to do after your usb is infected", unfortunately, it doesn't protect the flash-drive in the first place. Though these are the things to do, when it's too late.
Comment: @Gnoupi, following these rules will keep your home-pc protected by drawing a line between the home-pc and the school. The flash drive can safely remain on the school side of this fence. It is easier that way.
Comment: +1 for disabling autorun - but -1 for formatting on next use... that's *really* slow, in my experience :)
Comment: @warren, you are troubled by a "quick format" that protects your home PC from potential malware? And, I'd still suggest keeping Autorun off at all times (regardless of using this scheme).
Answer: Try Panda USB Vaccine.
Answer: See

http://answers.Yahoo.com/question/index?qid=20090616091607AApD6Zy)

for a link. I would've posted it, but have signed out of OpenID, and apparently unregistered/new users can only post one link in a message. And, reading the Yahoo page will be quite useful.
The "unmodifiable" autorun.inf is actually:
a) a directory named autorun.inf with SHR attributes that,
b) contains a very strange file, named "lpt3.This folder was created by Flash_Disinfector", which can neither be copied, deleted, or renamed by Windows. If I remember correctly, documentation somewhere says that the only way to remove this unmodifiable autorun.inf folder is by formatting the drive. However, Linux is not subject to these restrictions, and can easily copy/move/rename the folder.
Flash_Disinfector.exe is actually a RAR-SFX (self-extracting) archive. One of the archive's contents, nircmd.exe - which is used to silently execute commands - might trigger your existing security software.
Comment: Disabling Autorun: one way is to via Microsoft's TweakUI. Install and run it, and then (inside it) navigate to My Computer->AutoPlay->Types. There, uncheck "enable Autoplay for all CD and DVD drives" and "enable Autoplay for removable devices."
Answer: One of the main suggestions would be to ensure that you have up to date antivirus software on your home computer.  There are many free solutions out there including the popular AVG free anti-virus.
You can test basic functionality if you are concerned by downloading the Eicar test file to check if it is detecting nasties.  Simply save the Eicar file onto your flash drive from school, take it home and see if your antivirus detects it when you plug it in or if you go to open the file.  It is NOT a virus, it is just a file which contains a certain string of text that the majority of antivirus programs have been programmed to recognise as a virus for testing purposes.
Obviously, nothing will completely stop viruses so only copy from your school network what you really know about.
Does your school network have antivirus software running on all the computers?  Again, you could test this by downloading the Eicar test file above and try to open it.
Answer: Use a virus scanner and a personal firewall, don't enable sharing on any of your drives and don't let others use your flash drive.
Comment: Actually, I think he means using a flash-drive on a school computer, and in this case he probably can't do any of this (besides the "don't let others")
Answer: There's a simple way: you can protect your flash's root so viruses will fail to modify autorun.inf, as MOST of them do. ACLs will help! You must have NTFS filesystem there to have ACL enabled.
Comment: How can I protect the flash drives root?
Comment: Console example: "cacls X:\" - lists the current ACLs. You'd probably see "X:\ ALL:(OI)(CI)F" there.
Now you should delete all users from the list, one by one: "cacls X:\ /E /R COMPUTER_NAME\USER_NAME" ("cacls X:\ /E /R All" in my case).
And now add a read permission: "cacls X:\ /G All:R".
Now the Access Control List looks like this: "X:\ All:(OI)(CI)R"
Comment: "convert X: /fs:ntfs" - this will convert flash drive's file system to NTFS without deleting all your data :)
Comment: This still doesn't prevent viruses from infecting files — like, for example, antivirus software updates — stored on your flash drive.
Answer: "Flash_Disinfector.exe" works in a way sort-of similar to Panda USB Vaccine, by creating an unmodifiable autorun.inf entry in the root of partitions and pen drives.
There is, however, one scenario in which the protection afforded by an unmodifiable autorun.inf can be bypassed. There's an infection - which may be called "New Folder.exe" - that scans flash drives, and creates copies of itself in every directory, giving those copies the same name as the directory. Even with an unmodifiable autorun.inf, it is possible to mistakenly execute the malware's copies...
In short:
a) keep one's own computer clean,
b) disable autorun/autoplay
c) always launch pen drives from Start->Run or the address bar in Windows Explorer
d) ensure that hidden files and file extensions are viewable.
Comment: I'm curious, how can it create an unmodifiable autorun.inf ? Because a simple "read-only" wouldn't be enough. Also, give a link, possibly.
Answer: Use a live USB GNU/Linux distribution, maybe with a separate FAT32 partition for your files if you use Windows at home. To access your files at the school, don't insert the flash into the working computer but boot from it instead. This will guarantee that no viruses at the computer are activated, and will let you access your files as usual (if the Linux distro supports NTFS, but most of them do this now)

Virus protection for flash drives


How do I tune my cello to play the second Bach suite(prelude)?

Question: None of the videos on youtube are is concert pitch.
Answer: There might be a second question here, which regards the internal tuning of the cello strings, relative to itself. Cellos are typically tuned in fifths (C-G-D-A) of course, but there are pieces that require a different tuning (a technique called scordatura). In this case, wikipedia mentions that Bach's 5th Cello Suite was written for a scordatura in which the A string was tuned down to G. However, no such mention is made of a similar technique being used in Suite No. 2, so I assume it is written for standard tuning.
I don't know if this was your question, but I figured it was at least worth mentioning the issue.
Answer: These days many musicians who play Baroque music such as Bach tune their instruments down to the lower pitch of A=415, which is exactly one half-step below the modern standard of A=440.
It is generally accepted by modern performers of early music in the historically-informed style that A=415 was the tuning that Bach himself used for the string pieces he composed.
I'm quite sure that many examples you can find on YouTube are of a musician playing in A=415; furthermore, such a musician would be playing a specially-designed Baroque cello with period-correct strings made of sheep gut, not modern strings made of steel. Such a "baroque" cello would be designed, braced and set up differently than a modern cello, and would use a different kind of bow as well, and would be played in a different style -- for one thing, using a great deal less vibrato than "modern" cello players use. A Baroque cello with sheep-gut strings has a different sound than a "modern" cello. It is not as loud and cutting, but it has a character of sound that early music fans love.
The whole point of historically-informed performance is to try to use modern scholarship to go back to the sounds, instruments, and playing techniques that, to the best of our knowledge, were used by Bach himself, in contrast to playing on a modern instrument with modern strings and modern playing technique.
All this notwithstanding, if you want to learn to play Bach, you should tune your modern cello to A=440 and play it in the modern fashion with your modern bow. That is what your particular cello was designed and built to handle, and it's perfectly correct to play your instrument in that fashion.
I know many professionals (mostly college professors) who own both a Baroque cello and a "modern" cello, and a variety of different bows built after the design of different historical periods (I know people who have six different kinds of bows!) and use one cello or the other depending on the orchestra they are performing with and the type of music being performed. These people, however, are deeply committed to early music; extra cellos and bows are very expensive.
Answer: As MarkM pointed out, your claim is unsubstantiated.  Consider further that "concert pitch" is not a fixed value.  In the Good Old Days of Yesteryear,  middle-A could be anything from 409Hz on up ( Wikipedia).
Whether any particular YouTube recording was pitch-shifted in postprocessing is unknown.
Answer: Maybe you could point out which videos you're listening to. Period tuning is sometimes lower than A 440, but from a random sample of top results in youtube I found:
Mischa Maisky :

Mstislav Rostropovich:

Both squarely in D minor and A440 as I would expect.
Comment: Your second video link is dead.
Answer: Concert pitch depends on the orchestra. My instructor tunes to 441, as do I. It also depends on the acoustics of the hall and the atmosphere. So, many orchestras tune between 440 and 445 or 6. I noticed that some European orchestras are tuned to 445. NY orchestras to 442 or 443. Boston to 442. West Coast to 441 or 2. Right now, I'm tuning to 441 for the Bach Cello Suites.
Here's a thread on the topic. Why are orchestras tuned differently?
Answer: I play the second suite with normal 440 pitch, and it sounds fine to me. In the fifth suite, I'm pretty sure you're meant to tune your C-string down to a D so that you can get the bottom note, but that's not what you were asking.
Comment: A string down to G. C string down to a D would make it worthless while C string up to a D would make the low Cs inaccessible.


Why is lithium the most reducing alkali metal, and not caesium?

Question: Caesium has a larger size, and the effective nuclear charge that the valence electron experiences will be far less compared to that of lithium's, right? But lithium is still considered the strongest reducing agent among all the alkali metals, and this is evidenced by its large and negative reduction potential. Why is this so?
Comment: I think it has to do with solvation. The more solvated the resulting ions, the more favourable electron loss is. Even though its ionization energy is higher, lithium creates a very small cation which is strongly solvated in water, which drives the oxidation of metallic lithium thermodynamically towards the products.
Answer: The trend in the reducing power of the alkali metals is not a simple linear trend, so it is a little disingenuous if I were to solely talk about $\ce{Li}$ and $\ce{Cs}$, implying that data for the metals in the middle can be interpolated.
$$\begin{array}{cc}
\hline
\ce{M} & E^\circ(\ce{M+}/\ce{M}) \\
\hline
\ce{Li} & -3.045 \\
\ce{Na} & -2.714 \\
\ce{K} & -2.925 \\
\ce{Rb} & -2.925 \\
\ce{Cs} & -2.923 \\
\hline
\end{array}$$
Source: Chemistry of the Elements 2nd ed., Greenwood & Earnshaw, p 75
However, a full description of the middle three metals is beyond the scope of this question. I just thought it was worth pointing out that the trend is not really straightforward.

The $\ce{M+}/\ce{M}$ standard reduction potential is related to $\Delta_\mathrm{r}G^\circ$ for the reaction
$$\ce{M(s) -> M+(aq) + e-}$$
by the equation
$$E^\circ = \frac{\Delta_\mathrm{r}G^\circ + K}{F}$$
where $K$ is the absolute standard Gibbs free energy for the reaction
$$\ce{H+ + e- -> 1/2 H2}$$
and is a constant (which means we do not need to care about its actual value). Assuming that $\Delta_\mathrm{r} S^\circ$ is approximately independent of the identity of the metal $\ce{M}$, then the variations in $\Delta_\mathrm{r}H^\circ$ will determine the variations in $\Delta_\mathrm{r}G^\circ$ and hence $E^\circ$. We can construct an energy cycle to assess how $\Delta_\mathrm{r}H^\circ$ will vary with the identity of $\ce{M}$. The standard state symbol will be dropped from now on.
$$\require{AMScd}
\begin{CD}
\ce{M (s)} @>{\large \Delta_\mathrm{r}H}>> \ce{M+(aq) + e-} \\
@V{\large\Delta_\mathrm{atom}H(\ce{M})}VV @AA{\large\Delta_\mathrm{hyd}H(\ce{M+})}A \\
\ce{M (g)} @>>{\large IE_1(\ce{M})}> \ce{M+ (g) + e-}
\end{CD}$$
We can see, as described in Prajjawal's answer, that there are three factors that contribute to $\Delta_\mathrm{r}H$:
$$\Delta_\mathrm{r}H = \Delta_\mathrm{atom}H + IE_1 + \Delta_\mathrm{hyd}H$$
(the atomisation enthalpy being the same as the sublimation enthalpy). You are right in saying that there is a decrease in $IE_1$ going from $\ce{Li}$ to $\ce{Cs}$. If taken alone, this would mean that $E(\ce{M+}/\ce{M})$ would decrease going from $\ce{Li}$ to $\ce{Cs}$, which would mean that $\ce{Cs}$ is a better reducing agent than $\ce{Li}$.
However, looking at the very first table, this is clearly not true. So, some numbers will be needed. All values are in $\mathrm{kJ~mol^{-1}}$.
$$\begin{array}{ccccc}
\hline
\ce{M} & \Delta_\mathrm{atom}H & IE_1 & \Delta_\mathrm{hyd}H & \text{Sum} \\
\hline
\ce{Li} & 161 & 520 & \mathbf{-520} & 161 \\
\ce{Cs} & 79 & 376 & \mathbf{-264} & 211 \\
\hline
\end{array}$$
Source: Inorganic Chemistry 6th ed., Shriver et al., p 160
This is, in fact, an extremely crude analysis. However, it hopefully does serve to show in a more quantitative way why $E(\ce{Cs+}/\ce{Cs}) > E(\ce{Li+}/\ce{Li})$: it's because of the extremely exothermic hydration enthalpy of the small $\ce{Li+}$ ion.
Just as a comparison, the ionic radii of $\ce{Li+}$ and $\ce{Cs+}$ ($\mathrm{CN} = 6$) are $76$ and $167~\mathrm{pm}$ respectively (Greenwood & Earnshaw, p 75).
Comment: That's pretty much the same as what I wrote, except it's more descriptive and less quantitative. OP's argument is that it is difficult to remove the electron off lithium, therefore lithium should be hardest to oxidise. However, in reality, lithium is coerced to give up its electron by the surrounding water molecules, which are very happy to form ion-dipole interactions with the small ion $\ce{Li+}$.
Comment: I did not understand the formulas you provided. I hope to be able one day. My Russian textbook says: "lithium ions are much smaller than Na and K ions. That's why they will have stronger electrical fields around them. Hence, more active hydration. This eases the transition of electrons from Li into the solution and explains Li's position in the electrochemical series".
Answer: To decide which is the best reducing agent we only not consider that who has less ionisation energy yet it follows 3 steps:

Metal (solid) to Metal (gaseous state) sublimation energy
Metal from gaseous state to M+ ionisation energy
M+ to M+ (aqueous state) hydration energy

Lithium having more charge density has more sublimation energy and ionisation energy than caesium but hydration  energy is released in  such a big amount that it compensates the S.E and I.E. and caesium's hydration is less than lithium. That's why lithium is good reducing agent.
Answer: Well there might be more reasons than these two:

Lithium has a higher reduction potential.
If you also look at the electronegativities of just Lithium and Cesium then you would notice that the shielding effect is more prevalent in Cesium, thereby reducing the electronegativity and affecting the reduction potential. So Lithium however, just compared to Cesium, has a higher electronegativity.

I think these are the two main reasons, please correct me If I am wrong.
Comment: (-1) Saying that "lithium is a stronger reducing agent because it has a higher reduction potential" is just like saying "fluorine is reactive because it reacts with a lot of species readily". It's a tautology. Secondly, the greater shielding effect in caesium works to make *caesium* a stronger reducing agent because it reduces the first ionisation energy. It's exactly the same thing that OP states in the question.


Do non-American space travellers train on Dragon capsule as well?

Question: Soyuz is a spacecraft which still uses technologies from soviet era. The Dragon capsule is state of the art with its electronic upgrades. With Russia and US sharing the International Space Station along with few other countries, do the non-American astronauts and cosmonauts train on Dragon?
Answer: At time of this writing only one Crew Dragon has flown, so tense shall be future tense.
There are two ways to handover crew at the ISS. Direct, where a new crew launches and there are three crews on station for a week or so, and then the old crew departs. There is also indirect transfer where one of the crews departs and the new crew arrives a few days later.
There is a desire to always have 1 Russian and 1 American on station at any given moment in time.  Thus in an indirect handoff (which seems to be the current option for the last bunch of handovers) one of the vehicles be it Soyuz (from 2011-2020 the only option) or Dragon or CST-100 is leaving. Which means if Soyuz only carries Russians and Dragon/CST-100 only Americans, then the station could be crewed without a mixed crew.  (Europeans, Canadians, and Japanese etc figure out which one they fly on and can be ignored for the purposes of this conversation).
The Americans and Russians are trading seats on each vehicle going forward to keep to this standard. Thus Americans will still fly in Soyuz and thus require training. Russians will fly as part of the crew on a Dragon or CST-100 and thus require training.
A more interesting question is how much cross training is there on any particular crew?  I.e. Does an American arriving on a Soyuz have to train on how to land in a CST-100?  To what extent? And the converse?
Comment: An American arriving on a Soyuz and leaving on a CST-100 would need two suits, one for the way up and another one for the flight back. Both suits a compatible to only one life support system of the capsules.
Comment: @uwe True enough. And you do NOT switch vehicles lightly (or at all, if it is even possible. You do wonder if there is a really bad emergency plan for that).  I think I was trying to answer that some russians will fly on Dragon and some on Soyuz, some Americans on Dragon and some on Soyuz. But not on the same mission.
Answer: After some successful test flights with two american astronauts there will more tests with more than two astronauts.
After all those tests were done, selling of seats to non american astronauts may follow.
But training of non american astronauts may be delayed by some months up to years by Covid-19 disease.


Changing the ending of "Suffer with Me"

Question: When at the ending of "Suffer with Me," how do I change the ending? I've pressed rewind story at the replay mission but I always have to kill "Menendez." I've even rewinded the entire campaign and it never works.
Answer: Every single story line involves this ending in the level. There are a couple of decision points in the game that will affect later storylines and decisions however this is not one.

 No matter what you must kill Alex as this is what causes Menendez to shoot Hudson and spawnes the hate in David after seeing his father die.

Storyline spoiler:

 If the player wounds Mason by shooting him anywhere but the head or chest, he will survive. However he will remain absent in the thirty year gap for reasons unknown. In the ending cutscene, Mason visits Woods at The Vault. Soon David comes to visit Woods and is re-introduced to Alex, who tells him that the day that David fell from the tree was the one that made Alex proud as he got back up.

Changing the ending of "Suffer with Me"


Checkerboard painted on fuselage of Boeing test aircraft

Question: What is the purpose of the four square block checkerboard painted on the aft fuselage of Boeing's flight test aircraft?  It is either break in markings for fire rescue or some sort of optical measurement for speed, distance associated with flight testing, I believe.
Answer: the checkerboard mark allows accurate indication of the position of the plane using cameras as the plane flies by. by tracking the movement of the checkerboards between frames of a series of camera shots, the plane's speed, roll rate, acceleration, etc. can be measured.
Comment: @Kim It's not telemetry per se but accelerometers (AHRS) became much smaller, cheaper, and accurate, and GPS became available. Though some test flights still require chase planes, in general its cheaper, easier, and safer to rely on on-board instrumentation. Also in the old days, you'd do photogrammetry by manually measuring the image. Now we have computers that can in real-time correlate natural features on the plane, exactly the same principles as AR apps on your smartphone.
Comment: A little hairsplitting if you will, but I'd say these parameters can be calculated rather than measured... great answer though!
Comment: indeed, but photogrammetry is a good failsafe in case your telemetry links fail.
Comment: Yes, of course! What I mean is that with photogrammetry, you calculate the rates and accelerations rather than measuring them (you measure pixel displacement and then derive test aircraft flight mechanics parameters)
Comment: I have added a link to a picture (see above) that shows what I am asking about.  I appreciate your answers.  Is this still used today, or has it been replaced with telemetry?


Copper pour = Ground in layout terms?

Question: Is copper pour meaning ground in the layout terms?
Answer: It was suggested I put my comment as an answer. So here it is:
No. Copper pour is a copper pour. As the words suggest it is an area filled with copper.
You may connect this copper to any net you like. Often GND, sometimes 0V, sometimes a voltage rail, sometimes to chassis. Depends on what you need.
Note that GND, 0V, CHASSIS are all different, and are often used as copper pours for differnt reasons.
You often also have copper pours for the power rails.
You can also use copper pours as heat-spreaders, useful for LDOs or Power FETs. I've used copper pours to suck heat out of FETs to allow for better water cooling.
Comment: I think it is worth noting that when PCBs are actually manufactured, they start fully copper plated and the waste is etched away, so "pour" might be a bit of a linguistic misnomer. The word "pour" is an industry term to describe an large swath of copper that is left on the board after etch, and usually that pour is connected to a signal.
Comment: And in general, pours are eco-friendly as less copper then has to be etched away, leading to less manufacturing waste.
Answer: No, you can pour as much copper as you want and connect it anywhere you want or leave it unconnected.
So ground is only one of the options, but you must connect the pour where it makes most sense in an application.

Copper pour = Ground in layout terms?


The relative error of approximating a binomial

Question: Are there any good approximations for a binomial CDF that work well in terms of the relative error, as opposed to absolute?  For the usual normal approximation, the absolute error is very well-studied and does an excellent job, but obviously the relative error could be arbitrarily bad by comparing CDF's at $X=0$ since the normal distribution will always give a positive (albeit small) value.  Has anyone proposed an approximation whose relative error is known to behave well?
Comment: Related: [1](https://mathoverflow.net/q/143589/40432), [2](https://stats.stackexchange.com/q/70123/28285). If interested, I can give you more detailed information about the proved range of validity for the bounds mentioned in the questions
Answer: $\newcommand\ep\varepsilon$Let $S_n$ be a random variable (r.v.) with the binomial distribution with parameters $n,p$. Then, by Theorems 1 and 2,
$$P(S_n\ge an)\sim\frac1{1-r}\frac1{\sqrt{2\pi(1-a)a}}e^{-n D(a\|p)}$$
where $n\to\infty$, $1>a>p>0$, $an$ is an integer,
$$r:=\frac p{1-p}\Big/\frac a{1-a},$$
$$D(a\|p):=a\ln\frac ap+(1-a)\ln\frac{1-a}{1-p},$$
and
$$\frac{(a-p)^2}{(1-p)^2}\frac{1-a}{a}\,n\to\infty. \tag{1}\label{1}$$
In particular, condition \eqref{1} will hold if $p\in(0,1)$ is fixed and $(1-a)n\to\infty$ and $(a-p)^2 n\to\infty$.
If $n\to\infty$, $1>a>p>0$, $k:=an$ is an integer, $(1-a)n=O(1)$, and $p$ is fixed (or, more generally, $(1-a)p/(1-p)\to0$), then it is easy to see that
$$P(S_n\ge an)=P(S_n\ge k)\sim P(S_n=k)=\binom nk p^k(1-p)^{n-k}
\sim\frac{(np)^k}{k!}\,(1-p)^{n-k}.$$
If $p\in(0,1)$ is fixed and $n\to\infty$ and $(a-p)^2 n=O(1)$, then, by the central limit theorem,
$$P(S_n\ge an)\sim P\Big(Z\ge(a-p)\sqrt{\frac n{p(1-p)}}\,\Big),$$
where $Z\sim N(0,1)$.
The three cases considered above provide a complete description of the asymptotic behavior of the right-tail probabilities $P(S_n\ge an)$ at least when $p\in(0,1)$ is fixed -- in fact, the same will hold if $p$ just stays away from $0$ and from $1$. (If $p$ is close to $0$ or $1$, then a Poisson approximation becomes relevant.)
Clearly, the similar results hold for the left-tail probabilities $P(S_n\le an)$, with $1>p>a>0$.
Answer: Don't forget that far out in the left tail, the Binomial CDF is multiplicatively approximated by the PMF, because terms grow geometrically.
Example. For $t \leq \frac{np}{2}$, we claim $\Pr[X = t] \leq \Pr[X \leq t] \leq 2\Pr[X = t]$.
Proof.
Let $f = \Pr[X = t] = {n \choose t} p^t (1-p)^{n-t}$.
Immediately, $\Pr[X \leq t] \geq f$.
On the other side:
\begin{align}
\Pr[ X \leq t ]
&= \sum_{k=t}^0 {n \choose k} p^k (1-p)^{n-k}  \\
&= f ~+~ f \frac{1-p}{p} \frac{t}{n-t+1} ~+~ f \left(\frac{1-p}{p}\right)^2 \frac{t(t-1)}{(n-t+1)(n-t+2)} ~+~ \cdots \\
&\leq f \sum_{j=0}^t \left(\frac{(1-p)t}{p(n-t+1)}\right)^j \\
&\leq f \frac{1}{1 - (1-p)t/(p(n-t+1))}  \\
&\leq f \frac{1}{1 - (1/2)}  \\
&=    2f.
\end{align}
At the end, we used $t \leq \frac{np}{2}$ as follows:
\begin{align}
\frac{(1-p)t}{p(n-t+1)}
&\leq \frac{t - pt}{np - pt}  \\
&=    \frac{1 - p}{(np/t) - p}  \\
&\leq \frac{1 - p}{2 - p}  \\
&\leq \frac{1}{2} .
\end{align}
Answer: My paper here (Adv. Appl. Prob., 21 (1989) 475-478), Theorem 2, provides an estimate over all values of the parameters with relative error that is $o(1)$ if either $\sigma\to\infty$ or $x\sigma\to\infty$, where $\sigma$ is the standard deviation and $x$ is the number of standard deviations from the mean.
Comment: Your result is very nice. However, it does not seem to give a negligible relative error when $x\to\infty$ but $\sigma x\not\to\infty$.
Comment: Also, I started reading the proof of your Theorem 2. For $k=n$, I get $E(n)=-\sigma \ln(xY(x))$ instead of your $E(n)=-x \ln(xY(x))$.
Comment: @IosifPinelis On your first comment, thanks, I simplified too much and fixed it now.  On your second comment, I need to work on it; it has been a long time.
Comment: @IosifPinelis I couldn't figure it out then by a miracle I found my 34-year-old notes. At $k=n$, we have $x=\sqrt{qn/p}=\sigma/p\ge \sigma$. Also, $xY(x)<1$ for $x>0$. So $-x\ln(x Y(x))$ is an upper bound on $-\sigma\ln(x Y(x))$. I'm not sure why I didn't use the smaller bound, probably something to do with how the induction works.


How to disable "Available" on the Application display?

Question: When I use the Search Application box, I keep getting suggestions for applications, which boggle the speed of the search down to a halt (The whole thing is very slow as it is, on a EEEpc netbook), Is there a way to make Unity stop offering suggestions? I can't find anywhere to actually configure that thing
Answer: This problems needs to be reported as a feature request/bug to the unity bug tracker:
https://bugs.launchpad.net/unity
Because the solution will be to have a code solution or improve the speed of apt-cache.


What are the stages of Fermentation?

Question: How do you know when a beer is done fermentation and how long does it take before bottling it?
Answer: There are various answers to this question depending on how technical one wants to be. The usual and "technically correct" answer is that the brew has finished fermenting when the specific gravity (SG) of the brew remains unchanged over a few days. However there are also things like "stuck fermentations" or weirdly acting yeasts that can be an exception to this rule. Bretannomyces fermentation can take much longer.
Most brewers don't get that specific. They leave the brew to ferment for (say) 10 days to 2 weeks and then check the SG is near to that desired and then (usually) prime and bottle the brew. My personal philosophy is that slightly longer fermentation is better than the quicker option. So bottling anything before 14 days is rarely worth it (unless it is real ginger beer).
However once in the bottle/keg/cask/whatever is is a very good idea to wait at least another 2 weeks before sampling the brew. My personal preference is to bottle condition the brew for at least 2 months. I have many bottles that have been conditioned over 6 months and a few crates that are over a year old. The beer, in the main, just gets better. Lager for instance is often/usually "lagered" (hence the name) for 3 months or so in a cool place before consumption.
Answer: There are three main stages of fermentation: Primary, Secondary and Lagering.
Primary
Primary fermentation is actually two stages in itself. During the first stage, the yeast performs aerobic respiration, and undergoes a series of changes to adapt to its new environment, hence the name Adaptive Phase. During this stage the main byproducts of respiration are CO2 and water, and the yeast cells develop membranes which are permeable to the sugars and nutrients in your beer. This stage lasts only a few hours.
The next step of primary fermentation is known as the Attenuative Phase. This stage is marked by the growth of a large head of foam at the top of your fermentation vessel known as krausen. This is the part where the vast majority of the sugars in your beer are converted to alcohol. The main byproducts of this stage are again CO2 but also different types of alcohols. This stage will take a varying amount of time depending on the style of the beer and factors such as temperature, but it will typically take at least 2 days but no longer than a week.
Secondary
By the time secondary fermentation has begun, the majority of wort sugars have already been metabolized by the yeast and the beer will be very close to its final alcohol content. It is marked by an extreme slowdown of the speed of fermentation. At this point many brewers rack or move their beer from the primary fermentation vessel to a secondary one. During this step some of the more complex sugars are consumed by the yeast, as well as some of the byproducts of primary fermentation which would otherwise mar the taste of your beer. The beer reaches its final alcohol content at the end of this phase. This process usually takes around a week or sometimes more.
Lagering
Calling this its own stage is a bit of a stretch, as it's really the same as the secondary stage. Essentially for lager beers, the secondary stage is drawn out over the course of several months by keeping the beer cool. During this stage most of the yeast settles out of the beer and the byproducts of primary fermentation are broken down.
Sources:
How to Brew
Wyeast

What are the stages of Fermentation?


Equal area map projections: Lambert azimuthal or Albers conic?

Question: When making small-scale regional maps on the order of 500-5000 km in extent where an equal-area projection is desirable, which would you prefer, the Lambert azimuthal or Albers conic? I realize this could be a matter of the cartographer's personal preference and graphical constraints (e.g. aspect ratio of the final map), but is there a general rule of thumb about when to choose one projection over another?
Answer: It depends also on the location you want to map which you did not specify.
From ArcGIS Help, on Albers Equal Area Conic:

Limitations
Best results for regions predominantly east–west in orientation and located in >the middle latitudes. Total range in latitude from north to south should not >exceed 30–35°. No limitations on the east–west range.
Uses and applications
Used for small regions or countries but not for continents.
Used for the conterminous United States, normally using 29°30' and
45°30' as the two standard parallels. For this projection, the maximum
scale distortion for the 48 states is 1.25 percent.
One method to calculate the standard parallels is by determining the
range in latitude in degrees north to south and dividing this range by
six. The "one-sixth rule" places the first standard parallel at
one-sixth the range above the southern boundary and the second
standard parallel minus one-sixth the range below the northern limit.
There are other possible approaches.

ArcGIS Help for Lamert Azimuthal:

Limitations
The data must be less than a hemisphere in extent. The software cannot
process any area more than 90° from the central point.
Uses and applications

Population density (area).
Political boundaries (area).
Oceanic mapping for energy, minerals, geology, and tectonics (direction).
This projection can handle large areas; thus it is used for displaying entire continents and polar regions.
Equatorial aspect: Africa, Southeast Asia, Australia, the Caribbean, and Central    America.
Oblique aspect: North America, Europe, and Asia.
Comment: I think the answer from @MarcM is very informative but perhaps the use of one projection over another is subjective and hence a matter of opinion.
Comment: There are a few few helpful rules in the above, but is still not particularly informative. ArcGIS says to not use Albers for a continent but one often sees North America plotted in an Albers projection, even if it squashes the high latitudes...
Comment: I see, I am not familiar enough with North America being from western Europe


LSL communications

Question: Years ago I created a programming collaboratory in Diversity University MOO -- a room written in MOOcode that used TCP/IP to communicate with a perl server back at my campus to compile and execute C, Perl, Bash and other programs and return results to the MOO collaboratory -- all for demonstrating programming languages in a MOO teaching environment.  The application is usually a romp in five or six languages and fun to play with.  Now I'd like to do the same thing in SecondLife using LSL. The only suggestion I've gotten so far from that crowd is to use a WWW request, presumeably constructing an http POST message to a CGI process.  I never cared much for html forms so I'd rather use TCP/IP or some other communications protocol.  Has anyone tried this who'd care to provide a few hints?  There are several good LSL demo sites in SecondLife but I'd like to demo other compiler and script languages, maybe even PowerShell.
Dick S.
Answer: REST is now in fashion for web services. There is no real reason to get down to TCP/IP layer for something which from your description does not require super performance or response times. LSL HTTP support is quite good so you should not have any problems.
Of course it is not ideal to get the output of your programs back in real-time - for that you would need to open http connection on the server and constantly write to the body of the page (while the client would read that). But even with going back and forth between the server and the client you should get moderately good experience.
Answer: LSL's external communication options are limited to three specific options.  The official LSL wiki provides more detailed information on each option.

Raw HTTP: requests must be initiated by LSL script
XmlHTTP: requests must be initiated by external service
Email: full two-way communication, but with enforced sleep timers.
Answer: I would tend to agree with Ilya.
The Best you might be able to pull if you want the script to be very responsive is to have your server side code call back to the object once the server is made aware of it using the XML-RPC.
The main wiki for Second Life is pretty good for sample code, etc.  XML-RPC
Answer: LSL's llHTTPRequest function and corresponding http_response event are definitely your best bet.
Contrary to the assumption posed in your question, using http does not necessitate using "html forms".  The POST (or PUT) payload can contain data organized however you want.  A REST interface is a good way to do the kind of machine-to-machine http communication we're talking about.  One advantage of REST over html or xml is that REST can be much less verbose.  This is important when you start approaching LSL's 2048 character limit on http responses.
Though LSL has two other methods of communicating with the rest of the internet (email and xml-rpc), their use in LSL scripts is highly discouraged these days.  Both of these systems (as currently implemented in Second Life) rely on centralized servers to route messages to their destinations.  This doesn't scale well.  These servers are under ever-increasing load as Second Life grows.  llHTTPRequest on the other hand runs entirely on the simulator running your script, which means you don't have to worry about missing messages because of overloaded central servers.
Finally, there will soon be a new feature added to LSL allowing any script to act as an http server (see http://wiki.secondlife.com/wiki/LSL_http_server).  It's currently (as of June 2009) deployed on the beta grid, but should be on the main grid with the next major update.  With this addition, many of the current LSL-to-web programs that regularly poll a web server for updated data will instead be able to have updates pushed to them when they happen.
Answer: As Ilya said, REST and LSL-HTTP would be the way to go.
The new implementation of JSON within the Linden Scripting Language should help with that. You might want to start with reading the Json usage in LSL page on the official wiki.

LSL communications


How are commercial protein bars made so dense?

Question: I am trying to make protein bars at home from protein powder and natural sweeteners. I have basically all the ingredients mentioned on the pack, but mine come out much softer, whether or not I cook them. How are they made so dense? Are they processed under pressure perhaps?
Comment: What do you mean by "natural sweeteners"? If they are soft, you are probably putting too much moisture in them. If you are using, say, agave syrup, they will be soft because the protein powder won't thicken the syrup. If you are using stevia powder and binding with a small amount of somehing else, then you have good chances of keeping them hard.
Comment: Have you tried cooking your sugars to caramel/soft ball stage, then adding the other ingredients? Sounds like too much water to me.
Comment: I am using stevia powder, whey protein powder, soy protein powder, flavourings like cocoa powder or vanilla, and as little water as possible. I've also tried thickening with xanthan gum, but that just gives me a jelly/paste like consistency. The ingredients I don't have are polydextrose and soya lecithin. Any other ideas?
Comment: AFAIK, polydextrose behaves a lot like amylum, smoothing and densing the substance. The main difference (and advantage, especially in the case of a protein bar) is much lower energy value.
Answer: Yes, they would be processed under pressure. What I'm not seeing in your ingredient list are any thickeners or binding agents, which definitely works against creating density in the final product.
Now, I've never made protein bars (because I'm a fat kid and don't eat them (not that I'm actually fat)), but I have made granola bars, and in granola you use a combination of molasses and butter (or butter, honey and brown sugar, in some recipes) to hold it all together and create that density. Not the nutritional effect you're looking for, but in terms of physics, the same idea.
As far as the ingredients you don't have, both are readily obtainable. Soy lecithin, or any kind of lecithin, is an emulsifier, which basically means that it assists in mixing ingredients of differing types. Most commonly, that means mixing an ingredient that is water-based with one that is oil-based (mayonnaise and pretty much any baked good other than yeast breads are all good examples of this - the lecithin in the egg yolks is what holds everything together). Not sure what your grocers are like, but I could buy soy lecithin from the baking aisle at mine. Bob's Red Mill manufactures bags of the stuff.
As for polydextrose, it's an "artificial sweetener" made from natural sugars (dextrose), sorbitol (a low-GI sugar alcohol that can either be made by reducing glucose or found in peaches, pears, apples, etc.), and a little citric acid. Note that it's considered artificial because the substance is man-made, not necessarily any of the component parts. What it does is help hold everything together, because it's also used as a thickening and hardening agent (which is ironic, because it's also used as a humectant, which means it keeps things moist). In other words, without this one ingredient, not only is your recipe not going to be able to hold any kind of density without something to replace it, but it's also likely to taste like flavored cardboard. The good news is that you can buy it on Amazon.
My honest advice would be to obtain the missing ingredients - the polydextrose at the very least - and use something heavy - perhaps a tortilla or burger press with a couple weights on top? - to press the mash before you cook it (and yes, you should cook it, I think for 10-15 minutes? Play with that.). Then refrigerate it all for a couple hours to harden it, then cut.
If all else fails, give up, and make granola bars with lots of nuts for protein. :-) In any case, here's a link to a pretty good explanation of how to make granola bars. I know, I know, not what you want to come up with, but I would imagine the process should be roughly similar.
Answer: They are very likely extruded under considerable pressure. A sausage stuffer or extrusion (not rolling) type pasta-maker (both being things that go on a meat-grinder-like screw feeder) is probably as close as home-scale equipment comes, and it's likely not close enough in terms of pressure levels. But I can't think of any common home kitchen item that's likely to be any better than one of those.
You could also try drying/dehydrating after forming and cooking - but I say that as a person with a dehydrator (full of apples at the moment.) You may be able to cobble up something with an oven to dry, but a dehydrator does make it an easier thing to get done effectively (though the old standing pilot gas oven did a fine job - but so few folks have one of those these days.) Some, but not all, electric ovens have a "warm" setting/range that actually is low enough to be useful for this.
If going for a "Not trying to replicate the commercial product you've been buying" approach seitan might be an interesting approach/binder/ingredient if you don't have celiac disease and are not a "trendily avoiding gluten without any good reason" person. It's sho 'nuff protein, and you could mix your powders into it. Then again, you could skip buying the soy protein and try mixing the other stuff into home-made tofu, as you were making it.


How might a business overthrow the U.S. government?

Question: Is there any way that a high-end fortune 500 company with the technological development of Google or Apple could successfully overthrow the U.S. government?
Comment: This might be more on topic in [worldbuilding](http://worldbuilding.stackexchange.com/). It's a bit too hypothetical and open ended. To be on topic here you could ask for a historical example of a business overthrowing a government, information about a buisiness that plans on overthrowing the us government, or  a constitutional mechanism that would allow a big company to take control of the US government.
Comment: @lazarusL  - W.R. Hearst. Not fully overthrow, but he did manage to start a whole war with Spain. Without, mind you, the resources or capabilities of Google.
Comment: @lazarusL oh , sorry
Comment: @TheoclesofSaturn nothing to be sorry about. This site has a very specific definition of what is on topic which is not always obvious. I'm just trying to be helpful and help you find an answer rather than closing it without an explanation.
Answer: It's unlikely, but not impossible. After all, Hearst did manage to start a war, and that was 100 years ago.

Approach #1: Bully the vote

OK, we are shutting down GMail, Google Search, etc... unless you elect 100% the slate of leaders we want elected.

There are enough Google fankids or people desperately relying on Google infrastructure out there that they just might gain enough votes that way, especially of the slate they choose seems to be what 50% of electorate already likes but has hidden pro-Google agenda long term.

Approach #2: Buy their way in.
Some of the tactics to use (in conjunction):

Finance candidates they want

Finance attack ads and opposition research on candidates they dislike

Bribe candidates with money

Bribe candidates with policies if they already pretty much align ("hey, I know you care about urban housing. We'll invest $100M into building new urban housing and advertise it for free and advertise your policies for free, if you pass this set of laws we like. Small print: all the housing will have technology to redirect 100% of internet usage to Google Services. So we recoup what we did in 5 years in advertizing fees")

Approach #3: influence their way in.
They already do at small scale (lobbying). And major media companies already succeeded in helping elect US President they liked in 2008. And in the next 10 years Google and Apple may very well likely become far more of media powerhouses than they are today.
So electing people they want to positions of power is quite within realms of possibility.

Tweak their search algorithms to shape the information people see or don't see.
They already do that. They refuse to include "extremist" websites, which today they defined as "ISIS". They influenced searches for Brejvic (the guy who attacked kids in Norway). But there's no proof they will, or even have, limit themselves to ISIS in what they defined as "extremist". Tomorrow, it may be someone opposed to Net neutrality. Day after tomorrow, someone opposed to Google.

Publish content they want. 50% of youth in USA will vote the way Comedy Central humor hosts tell them to vote. Google can buy Comedy Central and make it their propaganda arm. Goal achieved.

... and once they have the candidates they hand selected elected, those candidates can pass any vote the company wants, amending the structure of the government.
The only missing piece is to appoint SCOTUS members who will interpret all that as fully constitutional. Not exactly a big stretch, considering how insurance companies managed to coopt SCOTUS in AMA situation.
Comment: I would say that #2 or #3 do not qualify as "overthrow", and the most likely result of #1 is most likely to backfire (and if not, I am not a big fan of them but I would always bet for the US Army or even just the PD against Apple fanboys). Also the "once they have the candidates [...] elected [..] can pass any vote the company wants" ignores the separation of powers (unless you assume the business gets to elect all of the candidates).
Comment: @SJuan76 - separation of WHAT powers? As the last 8 (or even 16) years showed, executive is pretty much the only power left. Congresscritters just vote for whatever President wants - Or, he signes and "Executive order" if they don't. Or just elect both Prez and congresscitters you want - not much of a challenge for the latter.


How to mint 10000 NFT at single or minimum no of transactions on ethereum?

Question: I have to mint 10000 NFTs. But calling mint function 10000 times is not a good idea I guess. Even I created a batchMint function that is calling mint function in loop and it is able to mint multiple NFTs at once (it is saving default gas of 21000 for each mint call).
But I just want to know is there any standard or better approach to mint these 10000 NFTs at once.
Comment: Please see answer below, did that help?
Comment: I want to make sure you are *required* to mint this. It sounds like a "push" pattern, which might be better replaced with a "pull" pattern: Let users/buyers/to-be-owners mint them instead. I know you mention you "have to," but not sure if that is due to thinking the push pattern is the only way or not. Just making sure :-)
Answer: Please see the smart contract for https://tenthousandsu.com. This includes:

Mints 10,000 NFTs
All at once
And supports ERC-721 Enumerable

Su Squares is the first ERC-721 contract, it is mentioned in the ERC-721 specification as a demo, and it was recently re-released as fully open source so you can copy away!
Answer: You can also look at the ERC721A contract. The contract supports minting of multiple NFTs at gas cost of one.
There are some limitations, though:

Token IDs must be subsequent
Reducing the gas costs of minting NFTs is more important than optimizing any other ERC721 call. This means, for example, that read operations like ownerOf is no longer O(1).


I want to borrow $25,000 for 1 year and pay it back at end of a year?

Question: What type of loan would be best to look for in the US, if I have an already paid off house as collateral for a $25,000 loan for 1 year?
Comment: OP, is it that you want to repay not a cent during the year, and then repay it all at once at the end?  Is that correct?
Comment: It might be a good idea to mention how you know you'll be able to pay the money back after 1 year. You may get some additional good advice as a result.
Comment: "Best" in what way?
Answer: An advantage of some home equity products is that you have the ability to have 5, 10 or even a 15 year payback period. This means that your required monthly payments are low, but you can also pay it back quicker.
If you have a home equity line of credit you can spend up to the limit, then pay it back, and have access to that amount of money again as long as the line of credit is still in the active period. The types of products give you a period of years where you have the ability to spend up to the limit, then the rest of the years are used to payback the loan.
Before 2018 an answer would discuss the rules for deducting interest payments on a home equity loan or line of credit, but in 2018 the new tax law changed those rules significantly. How you spend the money is the most important factor. In the new tax law the money has to be spent on fixing or improving the house in order to be tax deductible. Check the requirements before factoring taxes into the decision.
Answer: You can take the cash as  a lump-sum payment and repay the loan over time at a fixed interest rate.
You can do a home equity line of credit (HELOC) and borrow what you need, as you need it, up to the credit limit.  A HELOC offers flexibility to borrow money as you need it but tend to come with variable interest rates


Refraction inside a refracting medium

Question: After a light ray gets refracted at the boundary of a refracting medium, why do sent the light ray keep refracting
inside. Cause if you divide the medium into many boundary layers then light should keep refracting inside. There is no way each layer in the medium can know that refracred ray has already been refracted. So the light ray must bend. Please bring out the fundamental flaw in this question.
Comment: Should at least one of those "refract" occurrences be "reflect"? I'm having trouble understanding the question. When a light ray gets refracted at the boundary of a medium, the **refracted** ray leaves the medium - it doesn't keep "refracting inside". However, the **reflected** ray does stay inside the medium. Is that what you're asking about?
Comment: In general, it would help if you'd carefully proofread your question - for instance, if you read the title carefully, you wrote "**refraction** inside a **retracting** medium". There are other errors too, and it's not as obvious what you meant by some of them.
Comment: What I meant is why dosent light keep refracting inside the second medium can't we divide the medium into individual layers, light should keep refracting as refraction is a boundary phenomenon
Answer: If I understand your question correctly, the answer is the light does keep refracting inside the second medium. Let me explain what I mean:
Let's, as you suggest, divide the second medium into layers. Assuming the medium is homogeneous, the index of refraction of each layer is the same! They're all made of the same material.
So, if we apply Snell's Law of Refraction:
$$n_1 \sin(\theta_1) = n_2 \sin(\theta_2)$$
But $n_1 = n_2$ for every one of our layers:
$$n_1 \sin(\theta_1) = n_1 \sin(\theta_2)$$
$$\sin(\theta_1) = \sin(\theta_2)$$
$$\theta_1 = \theta_2$$
So what do we conclude? That for each of the layers we've divided our medium up into, the angle of incidence is the same as the angle of refraction. What does that look like? A straight line!
So yes, in a sense, the light beam is continuously refracting. However, you only see a change in direction of the light beam when the index of refraction changes, for example at a boundary between two different media.
Comment: Can u please explain the derivation for snells law then .that would really clear my doubts
Comment: There are multiple ways to derive Snell's law, but that's really a separate question that you could ask. The derivation is available in Wikipedia here: [Snell's law: Derivations and Formula](https://en.wikipedia.org/wiki/Snell%27s_law#Derivations_and_formula)

Refraction inside a refracting medium


Can i backup Ubuntu Windows Installation?

Question: I have Ubuntu-11.10-desktop-i386.iso and wanted to install  it within Windows. I found out the Ubuntu recognized my wireless device without even installing any drivers, which i didn't see in Linux Mint 15, so i plan to install this Ubuntu-11.10-desktop-i386 within Windows and update it quickly and make a backup of this Ubuntu.
Is it possible to do so? since this will be installed within Windows.
Any suggestions are welcome.
Comment: Please try 12.04 (supported until Apr 2017) or 13.04 (supported until Apr 2014). [11.10 is not supported since May 2013](https://wiki.ubuntu.com/Releases), therefore you won't get support from the official channels if you install it (and may have problems installing software from the repositories).
Comment: And, please avoid Wubi (= installation "inside" windows). It is discouraged and has lots of problems. Please do the dual boot installation unless you have a very good reason not to
Answer: The Ubuntu installation is stored on a virtual disk on the windows file system. From the windows point of view the virtual disk containing the Linux install is just another file. So the easiest way is probably to make a backup from the windows side. Locate the file and copy it to a external medium. It probably resides in the folder C:\Ubuntu\disks.
You might want to have a look at this URL:
https://wiki.ubuntu.com/WubiGuide
Comment: I am currently downloading ubuntu 13 as sosytee suggested and follow up with what Hinz said, if the entire Ubuntu Windows Installation resided just another file, then i would probably do that. Copy that file residing in C:\Ubuntu\disks.  Thank you all you have been a great help, please keep suggesting queries, it might help to not start another topic. Thank you. :)


OpenSolaris 2009.06 Vmware Tools

Question: I have been trying to get vmware-tools installed in my Vmware Fusion OpenSolaris 2009.06 guest OS for some time now at no avail.  My experiences are the same as this thread on the VMware forums, and I was hoping someone here would have a solution.
Comment: You'll have to wait until VMware ports the X tools to the newer version of Xorg that comes with OpenSolaris 2009.06...  I don't think there's anything that can be done in the meantime.
Answer: There might be a bigger chance that you will not encounter any problems if you use VirtualBox instead, since it also comes from Sun.
Comment: Try it again, a new version has come out.  If Solaris is important with regards to guest support you should use VirtualBox.   Nobody but Sun prioritizes Solaris as a guest os.
Comment: Tried Virtualbox.  It was just clunky and slow compared to VMware IMO.
Answer: I followed that exact fix in the forum post and it works well enough for me. It doesn't give you all the tools features for X, but it does give you clean guest shutdowns (and the eth driver in OpenSolaris 2009.06 already gives you 1000 throughput).
If you're looking for X support, you'll need to contact vmware.
Comment: The problem is, VMware charges for support.. :(

OpenSolaris 2009.06 Vmware Tools


Recurring Payments via PayPal

Question: How do I stop Civi sending a receipt notification to member that pays a recurring contribution via PayPal.  They get one from PayPal and one automatically sent from Civi so we are getting calls thinking they have paid twice
Answer: My suggestion would be to edit your receipt template and put some language in there for folks who pay by Paypal. It's always important for them to get a Civi receipt since it gives the full details on what the payment is for.

Recurring Payments via PayPal


Meaning of "stable to increasing/decreasing"

Question: What does "stable to increasing/decreasing" mean in the picture below? Does it mean "stable or increasing/decreasing" or "steadily increasing/decreasing"?
Comment: For me, it looks like an indication of population status taken from a defined scale. Something along the lines of:  Decreasing > Stable to decreasing > Stable > Stable to increasing > Increasing.
Answer: You have three ranges of population change: decreasing, stable, increasing. If a value is near the boundary between one level and the adjacent one, you could link the two levels with 'to' so that 'stable to increasing' means 'stable, but near the boundary with increasing', that is the high end of the stable range. 'Stable to decreasing' means 'at the low end of the stable range'.


Convert a polygon geopackage into a multi-polygon geopackage in QGIS

Question: I have a series of polygons in a geopackage file of QGIS polygons. Is it possible to transfer the contents of this file to another geopackage that has multipolygons as vector data type?
I need to fix this error because I need to merge multiple polygons and I can't do it using the simple source "polygon" geopackage but I need a "multipolygon" geopackage.
Comment: https://gdal.org/programs/ogr2ogr.html `ogr2ogr -f gpkg output.gpkg input.gpkg -nlt promote_to_multi`. Dissolve does not work if the table has fixed geometry type "polygon" because contraint prevents inserting multipolygons into such table.
Comment: You simply need to dissolve based on a suitable attribute, and you'll get multipolygons.
Answer: Open both layers in QGIS and simply Copy&Paste your features from source to target. QGIS converts your polygons automatically and even transforms your CRS if necessary. Then you can select your features in edit mode and merge them (command "Merge selected features").
Answer: user30184 posted a programatic response but you will need to know how to use GDAL libraries.
The assumption is that your existing geopackage has geometry type of 'Polygon'. This geometry type does not allow multi-part polygons. A 'Merge selected features' action on a geopackage wit that geometry type will cause QGIS to error when you attempt to save those changes.
eg: could not commit changes to layer AAABBBCCC
Errors: ERROR: 1 feature(s) not added - geometry type is not compatible with the current layer.
When creating a new geopackage, you should have created multipolygon geometry type. The way to fix this, is to use the GDAL libary as mentioned by user30184.
The only downside is that this method and all other methods are going to create a new file. It would be neater if you could apply the geometry type change to te existing file and just overwrite the existing file, but retain any existing data. (like what happens in some database technologies).


How do the public key recovery methods like secp256k1.RecoverPubkey(msg, sig) recover public key from a transaction signature

Question: For a signature done using a private key, we know that the corresponding public key is needed to verify. When the address is a one way hash function of the public key (which means from the address, it is infeasible to compute the public key directly), how does the public key recovery methods find the public key from the signers address, transaction message details including the digital signature? Is there a mapping between the addresses and the corresponding public keys from where the methods recover the public key or a service? Can someone show and explain.
Answer: Both the unencrypted data and the signed data are received. With those two things the public key can be figured out, and then the sender's address from the public key.
I guess this is a cryptography question, so crypto.stackexchange.com is it's natural home.
https://crypto.stackexchange.com/questions/62904/rsa-deduce-the-public-key-from-message-signed-message
Comment: The crypto.stackexchange.com link points to another problem and solution on identifying the public key from M and its signature for specific Public Key algorithms if many such pairs of M || DS[m] are available. I will post the answer that i figured out shortly. Thanks.
Answer: My earlier assumption (which is incorrect), based on which i posted the question was that, the signed transaction does not contain the public key. But I found out that in the bitcoin context every signed transaction comes with an Unlocking Script (scriptSig) which contains both signature and public key . Since public key is available in the transaction block itself, signature can be directly verified from that. In other contexts like in ethereum addressed below, where it is not directly there in the transaction the platform fetches it through a method. It is clear now that the signer's public key is provided by the signer to the miner for verification.
In the Ethereum context following is the way verification is done:
"ECDSA signatures in Ethereum consist of three parameters r, s, and v. Solidity provides a globally available method ecrecover that returns an address given these three parameters. If the returned address is the same as the signer's address, then the signature is valid.
Signatures produced by web3.js are the concatenation of r, s, and v, so a necessary first step is splitting those parameters back out.
Both smart contracts and Ethereum clients have the ability to verify ECDSA signatures." - For more details refer to the source of the above quote: https://yos.io/2018/11/16/ethereum-signatures/
Comment: The ECDSA can be used in two ways 1/ to verify the signature given the message and the public key, 2/ to derive the public key given the signature and the message. In the wikipedia article you have more details https://en.wikipedia.org/wiki/Elliptic_Curve_Digital_Signature_Algorithm.


Explain internal energy and enthalpy

Question: Internal energy and enthalpy. I am finding it hard to distinguish between the two. Confused. Can someone explain me the two terms and difference between them? I tried learning from wikipedia but it said for both the above terms that it is the total energy contained by a thermodynamic system, so Iam confused?
Comment: Enthalpy is internal energy + energy to create the system (fighting the 'atmospheric' pressure)
Comment: The wizard analogy is great for understanding enthalpy intuitively. https://physics.stackexchange.com/questions/356412/what-does-enthalpy-mean/356432#356432
Comment: Enthalpy is internal energy + $PV$. The term $PV$ does not require any deep interpretation; it is added to energy for convenience, in descriptions of isobaric processes and processes that begin and end at the same pressure (while in between, the pressure may vary).
 @Danu: When we consider how thermodynamic systems are prepared, often the atmospheric pressure does not need to be fighted (any isochoric process).
Answer: In pure thermodynamics, the internal energy is defined operatively: given a state of reference of our system, the internal energy of another state it's defined as the work needed to bring it to the new state:
$$U=W,$$
provided the system is thermally isolated.
The empirical observation behind this definition is that "this definition makes sense", i.e. there exist substances such that, if the system is entirely contained in some recipient made of these, then the amount of work $W$ is the same for all transformations that bring the system in the new state, which is the precise meaning of the phrase "being thermally insulated".
Enthalpy is $$H=U+PV.$$
Comment: You definition of internal energy is almost right, but you confused the sign in front of $W$; energy in state A is the work that was supplied to get to the state A. Also it should be said that the system has to be isolated, otherwise the work $W$ would depend on how the state A was approached (with heating, without...).
Answer: When you create something 'out of nothing' you need the energy $U$ to make it, but you also have to add additional energy to create room for it i.e the volume displacement. Or if you annihilate a system, this additional energy is the energy you would get when the atmosphere collapses. Enthalpy $H$ is then this total energy required for this process.
$H=U+PV$
Notice, that this is at constant pressure.
As you see, internal energy $U$ is energy without this displacement. It's the energy cointained in the system without the volume displacement.
Comment: A statement says'the energy stored within the substance or the system that is available for conversion into heat is called the enthalpy'

confused
o_O
Comment: Okay. For example a chemical reaction $H_2+1/2 O_2->H_2O$. Now the enthalpy change for this is according to my reference table $\Delta H=286kJ$. This is the amount of heat that you would get if you burned a one mole of hydrogen.
Answer: The internal energy of a system is simply the sum of its potential and kinetic energies i.e.
E(int) = U + K
The enthalpy is then the total internal energy of the system as well as how much pressure the system exerts on the volume it inhabits i.e.
E(enthalpy) = E(int) + PV
I hope this helps!
Comment: It should be said that $K$ is the kinetic energy of the constituents of the system, not of the system's center of mass. Similarly, $U$ is total potential energy of the constituents of the system, not potential energy of the system in some external field.
Answer: Well now if you don't mind abusing mathematical notation and formulas, perhaps a more hand-wavy answer can help illustrate the difference more intuitively.
Let's say we have some ideal gas in some sealed bag at absolute zero -- i.e, $T = 0$. Then, according to the ideal gas law, $PV = nRT = 0$, so we must have either $P = 0$ and/or $V = 0$. However, it actually follows that $V = 0$, since $V \ne 0 \Rightarrow P = nRT/V = 0$ and so the bag will be crushed into oblivion ($V = 0$) by the external atmospheric pressure $P_{atm} > 0$ anyway!
But, let's say we want our bag to actually have some $V' > 0$. Then, by the ideal gas law, our new temperature $T'$ would have to be $$T' = \frac{P_{atm}V'}{nR} > 0$$
But how in the world do we accomplish this? Clearly, we must supply some amount of energy to the system to raise its temperature, and then even some more on top of that to make it expand against the atmosphere in order to occupy the newly desired $V' > 0$.
Without changing the system's volume (i.e., have any mechanical work done on or by the system), we can simply supply some energy just to heat up the system to our desired $T' > 0$. How much do we need? Well, simply just $E_1 = nC_vT'$, where $C_v$ is the specific heat of the gas at constant volume.
So now we're at the target temperature $T'$, but how do we expand from $V = 0$ up to our desired new volume $V' > 0$? We don't want to use the system's own internal energy for this (since that will in turn lower the temperature!), so, once again, the energy required must come from its surroundings! Since the atmospheric pressure $P_{atm} > 0$ is relatively constant, we'll just need to also add $E_2 = P_{atm}V'$ in the form of heat to the system.
And so, we have now arrived at the concept of enthalpy! That is, $H = E_1 + E_2 = U + PV$ — the amount of energy needed to give a system some internal energy $U > 0$ (all the way from absolute zero), and also to expand it against its surroundings to occupy some desired positive volume as well.
Answer: The internal energy and the enthalpy are thermodynamic potentials. I will explain them as in the book A Modern Course in Statistical Mechanics by L. Reichl, which, I think, is a very intuitive and simple way to do it. "In conservative mechanical systems, such as a spring or a mass raised in a gravitational field, work can be stored in the form of potential energy and subsequently retrieved. Under certain circumstances the same is true for thermodynamic systems. We can store energy in a thermodynamic system by doing work on it through a reversible process, and we can eventually retrieve that energy in the form of work. The energy which is stored and retrievable in the form of work is called the free energy (sic)."
There are as many different free energies as there are combinations of constraints. For example, for a reversible process carrried out at fixed entropy ($S$), volume ($V$), and number of moles ($N$), the change in internal energy (U) [which simply is the energy stored in a thermodynamic system] is equal to the total amount of work that can be done on or by the system. In other words, for a reversible process carried out at fixed $S$, $V$ and $N$ work can be stored in the form of internal energy and can be recovered completely. Therefore, the natural variables of the internal energy are $S$, $V$ and $N$, i.e., $U=U(S,V,N)$.
In systems which are thermally isolated and closed but mechanically coupled to the outside world, we can only stored work in the form of enthalpy ($H$). In other words, for a reversible process at constant $S$, $P$, and $N$, work can be stored as Enthalpy and can be recovered completely.The natural variables of the enthalpy are $S$, $P$ (the pressure of the system), and $N$, therefore $H=H(S,P,N)$.
Answering your question, enthalpy and internal energy are both thermodynamic potentials, which means that both of them can be used to store useful work. They only differ in their natural variables, $U=U(S,V,N)$ and $H=H(S,P,N)$. We want to express the thermodynamic potentials in many different variables because some of them are easier to measure than the others. For example, we do not measure entropy directly, we measure temperature. Sometimes it is easier to measure pressure instead of volume, so the enthalpy is a good option in theses cases. To change from one variable to another, we use the Legendre transformations, that's why the enthalpy is defined as $H=U-PV$, in this way we change the variable $V$ in $U$ to $P$ in $H$.
Note that thermodynamic potentials have different names depending on their natural variables. The internal energy is the thermodynamic potential which has $S$, $V$, and $N$ as its natural variables. A thermodynamic potential, which natural variables are $S$, $P$, and $N$ is called the enthalpy. The Gibbs free energy ($G$) has $T$, $P$, and $N$ as its natural variables, and so on. For a more detailed discussion about this, I strongly encourage you to read the second edition of A Modern Course in Statistical Mechanics by L. Reichl. Hope this help you to figure out what is the difference between enthalpy and internal energy.

Explain internal energy and enthalpy


Study of Black-body Radiation

Question: Why did scientists study black body radiations from something as complicated as a hollow container rather than the radiation from something simple like a thin solid cylinder?
Comment: Unclear what you're asking and primarily opinion-based. To the others: Don't waste your 30 votes on this question. Flag/VTC it instead.
Comment: This question just came up while i was studying and if you don't have any idea about it, just say so, I'll understand...
Comment: Um, no. If I wouldn't have an idea about it, I would just  leave it as it is, maybe vote upp,    and not comment on it .     It is *your* opinion that   the latter is simple. And really very unclear what the context is . I'm convinced that I probably should downvote, as this "question" was actually upvoted ! .
Comment: I'm hesitant to vote this closed. It would be helpful if you could provide motivation for the question. Also, given that the studies on black-body radiation were done a long time ago, are extremely accurate, and that no matter which way would be better it makes no difference now, are you purely interested in physics history or is there a sub-textual (perhaps unconscious) effort to point out that you could do the same thing but simpler and are, thus, smarter than the physicists who did the original work? Not implying anything, just sincerely curious.
Comment: I don't mean any of that. I just came across this question in a physics hand book and was curious to know the answer(as there was no answer given). I'm not light headed enough to think that I could outwit any of the physicists who did the original work. For that matter I don't even know how a solid cylinder is simpler than a hollow cylinder, as you might have to take into account the internal absorption and reflection of incident light by individual atoms inside the solid whereas in the case of hollow cylinder you just have to take into account only the surface phenomena.
Answer: A black body is a perfect absorber, and in practice it's difficult to make a material that is a perfect absorber. So to make a black body we choose a material that is as good an absorber as we can find, and form it into a hollow sphere with a small hole in it. The black body is then the hole, not the sphere. It's a nearly perfect absorber because any radiation falling on it is multiply reflected within the sphere. Because the material of the sphere is a good absorber and absorbs most of the radiation at each reflection, the chance that any radiation falling on the opening reflects out again is vanishingly small.
I've never heard of a hollow cylinder being used to model a black body, but the hole at the end of the cylinder would be a black body in a similar way to the hole in the sphere.
Comment: I've seen cylinder used as a black body model. Or rather hole on it's side. This was in experimental setup in basic physics laboratory, that was used to check Stefan–Boltzmann law. It was very compact. In fact black body model and  detector were both mounted on top of a power supply. Sphere would be quite hard to make, while cylinder was in fact a section of pipe with front faces screwed in. Something that our workshop made without trouble during single workday.
Answer: Since a black body is an exact absorber and during practice it's demanding to make things that is really exactly a good absorber so to make black body we choose a material that is as good an absorber as we can obtain it into a hollow Sphere with a small hole in it. The black body is then the hole not the sphere. It is nearly perfect absorber because any radiation falling on it is multiply reflected within the sphere because the material of the sphere is a good absorber and absorbs most of the radiation at each reflection.

Study of Black-body Radiation


Computing distance to clique in FPT time

Question: I am a research scholar, and I currently work in parameterized algorithms. My current work involves proving that a problem is FPT for the parameter distance to clique. Although it is known that computing a distance to clique of size $k$ can be done in FPT time using a simple branching algorithm, I couldn't figure out how. Please elaborate on this. Once I get this, then I can assume that the distance to clique is given and solve the rest.
For a graph $G = (V, E)$, the parameter distance to clique is the cardinality of the smallest set $D \subseteq V$ such that $V \setminus D$ is a clique.
Comment: If the distance to clique is 0, then its about solving the problem for a clique. If i assume that for distance to clique it is FPT, then in this case it is polynomial time solvable on clique. @PålGD
Answer: The distance to clique is the fewest number of vertices to remove such that the resulting graph is a clique.
Let us take the complement graph $\overline G$ of $G$.  Now, we instead want to find the fewest number of vertices to remove such that the resulting graph is edgeless.
Recall that if $I$ is edgeless (i.e. an independent set), then $C$ is a vertex cover of $G$.  Hence, distance to clique is simply vertex cover in the complement graph.


How do I speed up media scanning?

Question: When putting new music files or images onto the sd card of my android phone, android needs to scan for new files. Is there any way to speed up this process? E.g. putting all files in one directory? Currently I organized my music this way: music/artists/albums/files.mp3 Any suggestions?
Comment: I also have this problem. I am using Musicolet player and there is an option to use Musicolet scanner or system scanner; also there is an option to choose which folders to scan. However scanning is slow. If I have huge audio files, scanning a single file can take minutes. So I wonder does the scanner have to scan each file byte by byte or what takes so long time?
Answer: One method is to put a file called .noMedia in the root of every folder that you don't want to be scanned.  It won't improve the scanning of actual media, but it will prevent wasted time searching elsewhere (or indexing things that you don't want indexed, such as app assets).
Comment: Just a notice. It won't speed up scanning by a lot. Files with a `.nomedia` will still be **indexed**, but not **categorized**. You may wish to open Media Provider's database and see the table entries.
Answer: some of the slowness may be due to the speed of your storage media.
If it's built in storage than there's not much you can do (apart from what Matthew Read suggested)
if it's an SD Card, maybe check that it's not a class 2 or something. perhaps try and get a class 10 to speed things up.
beyond those changes it's down to the device CPU speed
Answer: There's no need to organize your files in any other theme. Android is indexing the media file and since api 1.0 player should query the Media Store which is using this index.
Comment: I guess you got me wrong. Building up the index is too slow, and I aimed on asking how it can be speed up.

How do I speed up media scanning?


Search API Autocomplete does not return any suggestions when input contains ąčęėįšųūž or similar characters

Question: I am using Drupal 7, Solr 4.x, search_api, search_api_autocomplete modules in project. We have a page, which contains fulltext search with autocomplete settings. Problem is - it does not return any kind of results, when these contain non utf characters, for example ąčęėįšųūž.
Answer: Install the Transliteration module and enable the homonymous processor for the index.


How do I test a chain extension used in the runtime?

Question: I am aware of this example that shows how to create a mock chain extension and test that. However, I do not know how to test the chain extension that is used by the runtime and calling functions from pallets. How do I ensure the chain extension is interacting correctly with pallets?
Comment: Do I understand you correctly that you're asking how to write unit tests for the chain extension? So unit tests that sit in the Substrate runtime?
Comment: Yes, I am asking how it is recommended to test that the chain extension is implemented correctly.
Answer: I'm not sure if this is the simplest way, but I came up with a solution.

Write a basic smart contract that calls each chain extension function
Create a mock runtime using the chain extension
Write a test that builds the contract, uploads it with pallet_contracts::bare_upload_code and pallet_contracts::bare_instantiate. Then call the contract's functions and verify the state of the appropriate pallets.
Comment: Sounds good. Do you have example of all this steps?
Answer: There doesn't seem to be a clear way to test that e.g. a given call function in a chain extension is set up to behave the way that is expected(because it's difficult to instantiate the Environment struct externally).
Instead, you might break some parts out of call and test them individually. For example, the matching on the func_id is a large portion of the chain extension's work https://github.com/paritytech/ink/blob/6f105c2a0288b9a160385e1795375e5ad0350e34/examples/rand-extension/runtime/chain-extension-example.rs#L29-L48. You might split this out into a separate function that takes the function id and returns the expected call, if you can figure out a clean way to separate it from the env.write(). Then, you can test this new function, for example.
You can also look at the existing ink! tests in the chain extension example that test chain extension setup more implicitly. In this case they are checking the state after using a chain extension that calls an extrinsic. https://github.com/paritytech/ink/blob/6f105c2a0288b9a160385e1795375e5ad0350e34/examples/rand-extension/lib.rs#L124-L155
Comment: Writing the internals of the chain extension in a separate function could be useful. You could probably have reasonable confidence that it is working with that approach, but you would not be 100% sure.

For the second part, that is a mock chain extension, not the actual chain extension. That is just testing the smart contract itself, not the chain extension.


Are relational integrity and referential integrity the same thing?

Question: I found the same definition for referential and relational integrity. Are they the same? I have researched the two terms separately but cannot find any good definitions.
Comment: I have never heard the term "relational integrity", only "referential integrity"
Comment: "I have researched the two terms separately" is contradicted by "cannot find any good definitions" since it is easy to find good definitions of "referential integrity". And what non-"good" definition attempts did you find? Where did you find "relational integrity" used? How was it defined there?
Answer: Yes, they are the same thing. The term "Referential Integrity" is used much more though.
Referential Integrity relates to Foreign Keys in a Relational DB. For a table to exhibit Referential Integrity, the Foreign Key must either be null or reference an existing PK value in the related table.
Comment: They are not the same. "Relational integrity" is not a common term but has an obvioius interpretation from its constituent terms--DB integrity in a relational DB. Referential integrity is a special case of DB integrity & has a particular meaning for a relational DB.