Weyl and Dirac spinors

Question: I know that the Dirac spinor is composed of two Weyl spinors and each of the Weyl spinors also has two components. Can I see its two components as two different wave functions? Can I see four different components of the Dirac spinor as four different wave functions? Let´s say that the second component of Weyl spinor is zero. Does this spinor correspond to the wave function which has complex numbers as its values?
Answer: Dirac above all proposed the Dirac-equation because it allows to construct a 4-current $j^\mu = \overline{\psi}\gamma^\mu \psi$ whose zero component $j^0 = \overline{\psi}\gamma^\mu \psi =\psi^\dagger \psi  $ fulfills the role of a probability density since it is positive-definite. Furthermore $j^\mu$ fulfills the continuity equation $\partial_\mu j^\mu=0$ as it should be for a probability current.
If the zero component of the Dirac probability current $j^0$ is expanded we get :
$\psi^\dagger \psi = (\psi^\ast_1, \psi^\ast_2, \psi^\ast_3, \psi^{\ast}_4) \left(\begin{array}{c} \psi_1 \\ \psi_2 \\ \psi_3 \\ \psi_4 \end{array}\right) $
In the probability density all 4 components of $\psi$ participate, therefore  the normalisation of the Dirac- wave function looks like this :
$\int_{-\infty}^\infty d^3 x\, \psi^\dagger \psi = \int_{-\infty}^\infty d^3 x (\psi^\ast_1\psi_1 + \psi^\ast_2\psi_2   + \psi^\ast_3 \psi_3+ \psi^\ast_4 \psi_4 )= 1$
In this respect considering only a subset of components, the first two or the second two components would no longer fulfill the normalisation condition of a wave-function, i.e. it would no longer be a genuine wave-function. This also means that positive frequency (energy) and negative frequency (energy) solutions can mix. For instance wave packet of originally only positive energy solutions can evolve partially into negative energy solutions, in particular if it is localised in an area smaller or equal of the size of the Compton wavelength.
This is actually difficult to interpret. Well, one could assume that the forced localisation of the wave packet requires an external field which can apparently lead to the creations of positrons. However, taking into account this observation we no longer deal with an one-particle theory, whereas the concept of a wave-function is actually based on this (more details in Bjorken & Drell,Vol.1, Relativistic Quantum mechanics).
This is by the way one of the reasons why the concept of a wave-function has only a very limited sense in relativistic quantum mechanics, QFT-experts prefer no longer the use of wave-functions in QFT.
So the "Dirac spinor" has indeed properties of a wave-function, but only if the localisation of its wave packets is rather relaxed and the potential energies (bound states) where it is used are small with respect to the energy equivalent of the electron mass.
Another general property of a wave-function is that it contains the complete information of the system. However, using only 2 Weyl-components of it  would no longer ensure that this is possible.
EDIT
By the way, a particle described by a Weyl-spinor fulfilling the Weyl-equation is massless and therefore not localizable (like the photon). A proper wave function for massless particles actually does not exist.

Weyl and Dirac spinors


How much energy is produced by a sphere of mirrors around a rotating black hole? How would it impact a civilisation in the Kardashev scale?

Question: So, as a bit of background, my world takes the assumption that Planet Nine is a rotating primordial black hole, and humanity, a Type I civilisation, is able to build a sphere of mirrors around it (with a little window so it doesn't explode). In this case, how much energy would the system put out, and in what place would it put humanity in the Kardashev scale?
Comment: Can you link to a page about the Kardashev scale for those of us that don't know what that is?
Answer: On the assumption that by "Planet Nine" you mean an object in our own solar system, I'm going to assume that it doesn't have a massive accretion disk... there's probably not enough stuff available for one to have remained intact until the present day. Probably. Anyway, Vogon Poet has a perfectly good answer for you if it does have an accretion disk, or you construct one by throwing things at it.
Black holes radiate energy via Hawking radiation. The intensity of this radiation is inversely proportional to the mass of the black hole. Most black holes, being much larger than our sun, don't put out much in the way of Hawking radiation. A primordial black hole can of course have substellar mass, and in this case it is probably required to have quite a low mass otherwise it would have seriously disrupted the early solar system, and your alternate-universe humans wouldn't be around to harvest it.
Very roughly speaking, the power output via Hawking radiation can be approximated by $P \approx 3.56345\times10^{32}\left(\frac{1}{M_0}^2\right)$ (where $M_0$ is the initial mass of the black hole) so in order to get a power output of more than a couple of watts, your black hole must mass less than 1016kg, eg. lighter than Phobos.
To reach Kardashev II power levels, you need to get at least 1026W out of your black hole, which means your black hole would have to weigh 1832kg.
Problem! Because of the old mass-energy equivalence, as your black hole radiates energy, its mass has to decrease! The evaporation time is given by $T_{ev} \approx 8.41092\times 10^{-17}M_0^3$, which for the sort of miniscule black hole you're after is about half a microsecond.
Your civilisation will therefore be at K2 level for less than a microsecond, on the assumption that their power collectors can harvest that much juice. During that time the remainder of the black hole's mass will be converted to gamma rays and particles somewhat resembling a nuclear explosion of about 40GT TNT equivalent yield.
I hope they enjoyed their brief moment of power.
Alternatively, they should be happy remaining mere K1s, and having something as fascinating and useful as a substellar black hole in their nighbourhood to play with.
Answer: By definition, if harvested, it would make the civilization a Type I civilization and produce that much energy.
You would be harvesting 40% of the rest mass accumulated on the accretion disk around the black hole as energy.
You are assuming the mirrors consume zero energy to construct or maintain, and they are 100% efficient in directing all black body radiation to the collectors, which consume zero energy. And transportation around the mirror array consumes zero energy as well.
In this perfect case, the energy would need to start with the mass of the matter in the accretion disk, $m_a$.
Your energy will be:
$$E=m_ac^2\times 0.4 \times \eta_m \times \eta_c$$
Where $\eta_m$ is your mirror efficiency and $\eta_c$ is your collector efficiency.
Find your starting mass, this gives you the answer. When E = 1016 Watts you have a type I.
Answer: The only energy that can be emitted from a black hole itself (and not the surrounding accretion disc) is Hawking radiation. Hawking radiation is a tiny amount of energy, so harvesting it probably isn't worthwhile.
In addition, the sphere of mirrors reflects the radiation back into the black hole, making it so you can't harvest any.
However, if you add other mass or light, you could maybe construct a Penrose mechanism to collect infinite energy.


Why did the sailors have to pick Jonah up?

Question: Why was it necessary for the sailors to pick Jonah up and throw him into the sea (1:12, 15) instead of him just jumping? It almost sounds like he is handicapped somehow, but then he does other things like going down into the hold of the ship, apparently by himself. He also builds a shelter in chapter 4. Was he just so afraid that he couldn't jump into the water? Even then I would expect a mob of sailors could pressure him into jumping without physically picking him up and throwing him. Thoughts?
Comment: He did not wish to commit suicide.
Comment: Since it was storming, they wanted to make sure Jonah would clear the perimeter/wake of the boat.
Answer: I read this is a literary theme in the Bible, namely that we pass into darkness passively (by outside forces) and deliverance happens by God.
When viewed in the context of this template, we see why Jonah would be passive (needs to be thrown overboard) rather than actively jumping in. Indeed, even though the book of Jonah records his actions, from the moment of his deep sleep (a metaphor for death) he stops being the actor and becomes the acted  upon until his deliverance. I encourage you to re-read 1.5-2.9 and observe the amount of passivity. He does nothing except confess who he is and then, once in the depths, hope for deliverance.
Other examples:

Abraham, from the moment of his deep sleep, experiencing the horror of great darkness, takes no part in the momentous covenant and oath swearing. God does all the work of swearing the covenant with himself. Gen 15.12-21

Joseph is completely passive when thrown into the pit. There is not even a record of him complaining or trying to free himself.  Gen 37.18-28.

The Israelites were expelled from Egypt by Pharoah after the death of the firstborn, they did not choose to leave. During the epic battle between Moses and Pharoah, the Israelites themselves were passive and made no decisions for themselves, all the action was a battle between Moses/God and Pharoah.

Jesus was crucified by the Romans. He did not answer in his own defense or try to free himself, nor did he take actions to take his own life. The crucifiction is a picture of passivity. This is another aspect of why his death and resurrection was the sign of Jonah. This is the "led" part of the sheep being led to the slaughter.
Comment: Joseph did plead with is brothers, his brothers said so themselves in Genesis 42:21:
Then they said to one another, "We are truly guilty concerning our brother, for we saw the anguish of his soul when he pleaded with us, and we would not hear; therefore this distress has come upon us."
Comment: And when you say Jesus was passive, are you suggesting he was unable to decide for himself, or that he chose not to?  Because he definitely had a choice:  "Or do you think that I cannot now pray to My Father, and He will provide Me with more than twelve legions of angels?"
Comment: @Millard Jesus' passivity is intentional because He was taking on our role and our fallen passive response in the face of darkness, to defeat sin. And He is so holy that it took an enormous battle with satan tempting Him to essentially stay holy and not do it for us before He could, during which He sweat blood (a condition indicative of hydrohemotosis if I remember the term, where struggle so intense capillaries burst). It doesnt say that Jesus is inherently passive, far from it. He rose from the dead for one thing. He is now the Lord of the Universe. Macarthur preaches beautifully on this.
Answer: Jonah 1:

7Then the sailors said to each other, "Come, let us cast lots to find out who is responsible for this calamity." They cast lots and the lot fell on Jonah.

With lots, the sailors found out that Jonah had something to do with the storm that was threatening their lives.

8 So they asked him, "Tell us, who is responsible for making all this trouble for us? What kind of work do you do? Where do you come from? What is your country? From what people are you?"
9 He answered, "I am a Hebrew and I worship the Lord, the God of heaven, who made the sea and the dry land."

The sailors learned that the Lord made the sea and control the sea.

10 This terrified them and they asked, "What have you done?" (They knew he was running away from the Lord, because he had already told them so.)
11The sea was getting rougher and rougher. So they asked him, "What should we do to you to make the sea calm down for us?"

The sailors had to appease the God who stirred up the storm. How?

12 "Pick me up and throw me into the sea," he replied, "and it will become calm. I know that it is my fault that this great storm has come upon you."

Why did the sailors have to pick Jonah up?
The sailors had to perform an act to appease the Lord.
Comment: Oh. Thanks so clear. I feel almost silly now having wondered the same thing til reading that
Answer: Self murder (suicide) is sinful according to Exodus 20:13.  Jonah believed that if he went from the ship into the sea, that he would die and the storm would cease.  However, if he jumped himself, that would be sinful since it would be suicide.  Instead, he told the sailors to cast himself into the sea.
In the same way, Jesus willfully died on the cross but did not commit suicide.  The Roman soldiers executed Jesus.
The parallels between Jonah and Jesus are numerous.
Comment: really? how do 3 days and 3 nights added up for jesus?
Answer: The answer may be rather simple:  The strong waves and heaving of the sea would have made it difficult for anyone, especially one who was not accustomed to sea travel, to even walk on the deck of the ship, must less manage to cast himself off from it without getting hung up on the rigging or striking some part of the ship.  Nor could a single sailor have helped to hurl Jonah far enough to clear the ship on his way down--it would have taken a team effort.
Jonah himself seems to have been quite cooperative with the effort--even urging the men to do it.  It seems unlikely he would have been unwilling to cast himself into the sea had he been able.  After all, had he not already run away from God, showing his willingness to disregard God's orders?  Why should he then be overly concerned about his guilt with ending his own life?
Answer: It's occurred to me that Jonah simply didn't want to die. He's a prophet after all, so if you inquire about the will of God he'll tell you, even if it involves his own homicide, simply as a matter of fact. Doesn't mean he's going to jump into the ocean for you.
Comment: I am thinking of Jesus His words, when He talked about the sign of Jona, foreshadowing His redemption work. If your suggestion is true, then we would have to think that Jesus did not want to give His life, but had to be forced and we know He willingly gave up the Spirit.
Comment: @sara, I don't think the moral position of Jonah was what Jesus had in mind. Jonah was a disobedient prophet and literally tried to run away from God's will. When he finally submits to God's will, only after being killed and raised from the dead, he gives a one line sermon and then throws a tantrum about it for the rest of the book. I think Jesus was only referring to the resurrection miracle. Jonah is not a good moral example.
Comment: @sara, Jonah to me is one of the Bibles most rediculous prophets, that informs my perspective on his motivations. Thanks for helping me to see that not all people view him this way.
Answer: I believe Jonah was trying one last time to get out of doing what God told him to do. He wasn't going to kill himself to get out of it. One last time he could try to get out of going to that city. And as an added bonus have someone to blame.
Comment: Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer).
Answer: Rely solely on the Old Testament, seems like Jonah is relying on the imagery in the Binding of Issac (Genesis 22), in which God calls for human sacrifice, even if He ultimately does not follow through. A second reading is the penal approach shown in Joshua and Judges, in which God is enacting Justice on those who break his commands. If you accept the very late dating of the book, then it might also be mirroring the Wisdom of Solomon (chapter 2) and/or Deutero-Isaiah (suffering servant poems), in which one person bears injustice for the sake of the wider community.
In the New Testament, Jonah is used alongside the above examples as types for Christ. In that sense, much like in Wisdom 2, Jonah is killed/damned by those afraid of the blasphemy he committed, which God shows to be part of his providence in bringing Jonah back from the dead for the sake of spreading His message. Jesus provides a good framework for interpretation if you accept the incarnation of course.
Comment: Welcome to Biblical Hermeneutics! and thank you for your contribution. When you get a chance, please take the [tour] to understand how the site works and [how it is different than others](https://hermeneutics.meta.stackexchange.com/questions/653/how-can-we-educate-new-users-about-our-site-distinctives/803#803). I also recommend going through the [Help Center](https://hermeneutics.stackexchange.com/help)'s sections on both asking and answering questions.


Are there causes of action for which an award can be made without proof of damage?

Question: Are there causes of action for which an award can be made without the plaintiff demonstrating loss/damage?
Answer: Yes. Therefore, when assessing a claim, it would be incorrect or premature to conclude simply from lack of actual harm/damage that a wronged party would have no available remedy. In order to make this conclusion, one would have to examine the statutory scheme or the nature of the tort to determine whether the claim is actionable without proof of damage.
Many statutory causes of action are actionable without having to prove loss or harm.

Canada's Copyright Act, s. 38.1 allows a plaintiff to opt for statutory damages
Texas's SB-8 creates a cause of action that allows the claimant to recover statutory damages absent any proof of harm to the claimant
The Telephone Consumer Protection Act of 1991, 47 USC § 227 provides for statutory damages in the amount of $500
In British Columbia, "it is a tort, actionable without proof of damage, for a person to use the name or portrait of another for the purpose of advertising or promoting the sale of, or other trading in, property or services, unless that other, or a person entitled to consent on his or her behalf, consents to the use for that purpose" (Privacy Act, RSBC 1996, c 373)

The common law and equity also recognize various wrongs and remedies without proof of damage
The tort of trepass is actionable without proof of damage (Peter Ballantyne Cree Nation v Canada (Attorney General), 2016 SKCA 124, at para 130). Nominal damages are the normal remedy in the absence of proven harm (Rusche v. ICBC 1992 CanLII 735 (BC SC), quoting Halsbury's Laws of England).
The tort of battery is actionable without proof of damage (Norberg v. Wynrib, [1992] 2 S.C.R. 226). Again, nominal damages are the norm (see Rusche, above, also quoting from Halsbury's Laws of England).
The equitable remedy of disgorgement may also be available without proof of damage (for example, after a breach of fiduciary duty) (Atlantic Lottery Corp. Inc. v. Babstock, 2020 SCC 19, at para 32).
Comment: "Without having to prove loss or harm" - I think not only do _you_ not have to prove it, but if the defendant can prove that damages are less than the statutory amount, they still have to pay the statutory amount.
Comment: Defamation per se, also.
Comment: In the U.S., some jurisdictions allow nominal damages in absence of proof for common law breach of contract, some do not, and some have a more complicated rule on that point.
Comment: Many U.S. jurisdictions also allow for plaintiffs to elect to recover of a statutorily set "solatium" amount in lieu of proof of damages in a common law action for wrongful death. See, e.g., Colo. Rev. Statutes § 13-21-203.5 currently $119,660. https://www.coloradosos.gov/pubs/info_center/files/damages_new.pdf


is there a way to display a message for views if there are no results?

Question: I am using user relationships and activity feed, which displays actions from a existing view.  If no view exists, it means either they have no friends or their friends have no activity so is there a way to have a message displayed for no results?
Comment: You should add information about the version you are using.
Answer: For Drupal 7 / Views 3 the answer would be:
Check the "Advanced" Options on the right side. There you can add a "NO RESULTS BEHAVIOR".
Answer: In "Basic settings," there's a field called "Empty Text" that is displayed if there are no results.
If you're using arguments, you can set "Display empty text" if the argument is not present.


Symantec Endpoint Protection toggle of firewall rules by script

Question: I'm running Symantec Endpoint Protection 11 and I'm hoping to be able to toggle a simple firewall rule with a script. If I can do it from the command line that would be preferred.
Answer: It's unclear to me what Symantec Endpoint Protection has to do w/ your question, so please let me know if I'm missing something.
In terms of manipulating the Windows 7 Advanced Firewall from the command line I believe the netsh advfirewall command is what you're looking for. Read up on the syntax at Microsoft's site and play around with it a bit and I think you'll find it fairly intuitive.
If you're looking at making changes to firewall rules on clients in an Active Directory domain environment you'd have a better time of it using Group Policy instead of a command-line script.
Comment: SEP provides its own firewall facility separate to the Win7 Firewall from what I can tell. Attempting to manage the Firewall using the Win7 GUI shows "These settings are being managed by vendor application Symantec Endpoint Protection". From dumping with netsh it looks like my configuration is not accessible there (though I'm not familiar with the netsh firewall configuration).
Comment: Hmm... I can't help you there. We moved all our Customers off of Symantec's antivirus products back when they released SEP and I haven't kept up with it. Perhaps this is a silly question, but why not use the GUI management functionality on the SEP server?
Comment: I still have folks that won't move off. I cannot understand the devotion.
Comment: I use SEP since it's what my school supports on student computers. I find the GUI to be cumbersome and I'd rather just fire and forget with a script.
Answer: Scripting SEP is painful and full of things that can go wrong that can cause you to have to rebuild the system. I haven't tried to script it since the windows firewall in vista+ became so much better (making no reason to use the SEP firewall especially since it doesn't start with the network).   You have to use the SMC command to do anything command line.  Docs for it live here. There is a vbscript sample to automate it here
Comment: Thanks! These are the docs I'm looking for. Although I think I'm going to take the inferred advice of migrate off of SEP (at least for the firewall in my case). Edit: Whoops, these are not the docs I'm looking for. Is there anything less than a "load this entire separate configuration" hammer?


Spring Controller @RequestBody with file upload is it possible?

Question: I have a Controller like this and I want to submit a form with file uploading as well as some form data like label as shown below. Also, I want to do that using @RequestBody so I can use the @Valid annotation on the wrapper as more variables will be added.
public @ResponseBody WebResponse<Boolean> updateEUSettings(
    final Locale locale,
    @Validated @ModelAttribute final EUPSettingsWrapper endUserPortalSettingsWrapper) {
}

And my wrapper is:
public class EUPSettingsWrapper {

    private String label;
    private MultipartFile logo;
// getter , setters..etc...
}

But I would like to convert it into a @RequestBody from ModelAttributes.
The way I'm trying is by having the file upload separated as request parameter like this:
public @ResponseBody WebResponse<Boolean> updateEUSettings(
    final Locale locale,
    @Validated @RequestBody final EUPSettingsWrapper endUserPortalSettingsWrapper,
    @RequestParam(value = "file1", required = true) final MultipartFile logo) {

    endUserPortalSettingsWrapper.setLogo(logo);

    // ...
}

In my mock MVC, I am setting:
getMockMvc().perform(fileUpload(uri).file(logo)
                        .accept(MediaType.APPLICATION_JSON)
                        .content(JSONUtils.toJSON(wrapper))
                        .contentType(MediaType.MULTIPART_FORM_DATA))
                        .andExpect(status().isOk());

But I'm getting an error like this which says:
org.springframework.web.HttpMediaTypeNotSupportedException: Content type 'multipart/form-data' not supported

Does anyone have a good idea of how Multipart file uploads can be used with @RequestBody? Anything I am doing wrong above?
Comment: See this https://www.baeldung.com/sprint-boot-multipart-requests
Answer: You can actually simplify your life here since all you are doing is submitting a form that contains some fields and file.
You don't need @RequestBody for what you are trying to do. You can use regular Spring MVC features, so your controller method would look like:
@ResponseBody
public WebResponse<Boolean> updateEUSettings(
     Locale locale,
     @Valid EUPSettingsWrapper endUserPortalSettingsWrapper,
     @RequestParam(value = "file1", required = true) MultipartFile logo
) {

}

The client that submits the request to this controller will need to have a form with enctype="multipart/form-data".
In your Spring MVC test you would write something like this:
getMockMvc().perform(fileUpload(uri).file("file1", "some-content".getBytes())
                        .param("someEuSettingsProperty", "someValue")
                        .param("someOtherEuSettingsProperty", "someOtherValue")
                        .accept(MediaType.APPLICATION_JSON)
                        .contentType(MediaType.MULTIPART_FORM_DATA))
                        .andExpect(status().isOk());

Comment: Very interesting, but how does the data looks in the Ajax POST request? Do you create a Object to represent EUPSettingsWrapper and a FormData to represent the MultipartFile and then you assign the FormData to, let's say, obj.logo ? Also do you JSON.stringify() that obj or not?
Comment: Unfortunately I don't really remember since the answer is pretty old :)
Comment: Another way is encode your file bytes into base64 and then generated string can be use in request json, generally this patten is not recommended but for special schenarios:
{"name":"aa","logo":encodeBase64(fileByteArray)}
for encoding follow given url: https://stackoverflow.com/questions/22172604/convert-image-url-to-base64/22172860
Answer: I couldn't find a way to use @RequestBody.
However, you can do something like this:
@RequestMapping(value = "/uploadStuff", method = RequestMethod.POST)
public MyViewDto doStuff(@RequestPart("json") @Valid MyDto dto,
                         @RequestPart("file") MultipartFile file) { ... }

You can test it like this:
MockMultipartFile jsonFile = new MockMultipartFile("json", "",
            "application/json", "{}".getBytes());
MockMultipartFile dataFile = new MockMultipartFile("file", "foo.zip", "application/octet-stream", bytes);

mockMvc.perform(fileUpload("/uploadStuff")
            .file(dataFile)
            .file(jsonFile))
            .andExpect(status().isOk());

Comment: org.springframework.web.HttpMediaTypeNotSupportedException: Content type 'application/octet-stream' not supported
Answer: Please add the following bean in your spring-servlet.xml to add the support for multipart  request.
<bean id="multipartResolver"
    class="org.springframework.web.multipart.commons.CommonsMultipartResolver" />

Also don't forget to add the dependency for commons-fileupload jar
Comment: Also see this answer for how to set it up in a Java-based configuration: https://stackoverflow.com/a/29883166/3960852
Answer: I struggled a little with this and ended up passing as simple parameters. Fine if you don't have lots to pass in your request:
myMethod(@RequestParam("file") MultipartFile myFile,
        @RequestParam("param1") Float param1, @RequestParam("param2") String param2 {}

Answer: For Spring 4 and later you can do the following to get the full object:
public ResponseEntity<Object> upload(@Payload EUPSettingsWrapper wrapper) {

}

Note: Also should work without the tag
public ResponseEntity<Object> upload(EUPSettingsWrapper wrapper) {

}


Where do spatial dimensions enter in single compartment neuronal models?

Question: I am trying to understand how the length and diameter of a compartment are specified. For example, in the Hodgkin–Huxley model, we only have conductances specified in $\rm mS/cm^2$. How do you specify that a compartment is say $100 \mu\rm m$ long?
Comment: I'm pretty sure basic Hodgkin-Huxley doesn't take into account distances or volumes, rather the spatial quantities in the units are derived from electrical properties. There is a related idea called Cable Theory that I believe does incorporate distance factors.
Answer: In a single-compartment model, you do not have spatial dimensions. Sometimes this is not a problem, for example in the stomatogastric ganglion of C. borealis, in which the neurons have a mechanism to scale the signal with distance by modifying the "effective reversal potential" (Otopalik et al., 2017). In the case of one of these models, it would be sensible to either make an approximation of the cell surface area (Liu et al., 1998 for example) or to use parameters which are normalized by the surface area, to whose explicit numerical value we remain agnostic. One would do this by using a membrane capacitance in microfarads per centimeter squared for instance (typically about unity) and then use maximal conductances in millisiemens per centimeter squared.
This way, the natural units for current divided by capacitance are mV * mS/cm^2 * cm^2/uF, or equivalent to mV/ms.
If you wanted to model multiple neurons with a decay factor, you could either use the cable equation and explicitly input the current into the descending neuron following that, or make a neuron with multiple compartments.


How to get rid of the play/pause button in Preview?

Question:
Is there any way I can remove the play/pause toolbar in Preview app ? I don't use it, so it's annoying to see it pop up now and then.
Comment: Does it only show if there is media content in whatever file you are previewing?
Answer: No option are yet available to hide or disable this Play/Pause toolbar — This feature was introduced in macOS Big Sur and still here in macOS Monterey when you enter in fullscreen mode in Preview (even after many disagreements from users about this toolbar).
The only solution if you still want to read your PDFs using Preview would be not to touch your mouse or trackpad at all but only use your keyboard to navigate between pages.
However, there are of course many other PDF viewers and editors that you could try; many of them free.
You can also provide a feedback to Apple regarding this feature via this link https://www.apple.com/feedback/ selecting your device  and hope for it to be manageable in the Preview settings in future macOS updates.


Proving stochastic boundedness in rate of contraction posterior distribution

Question: Consider a family of probability distributions $P_\theta$ indexed by $\theta \in \Theta$. The parameter space is endowed with some metric $d$. We assume that there is a true parameter $\theta_0$, and we are interested of the convergence of the Bayesian posterior distribution, given a prior $\Pi$. We denote the posterior distribution after $n$ samples by $\Pi_n(\cdot|X^{(n)})$.
The posterior distribution is said to contract at rate $\epsilon_n \to 0$ at $\theta_0$ if $\Pi_n(\theta:d(\theta,\theta_0) > M_n\epsilon_n | X^{(n)}) \to 0$ in $P_{\theta_0}^{(n)}$ probability, for every $M_n\to \infty$ as $n\to\infty$ (i.e., regardless of how slow $M$ goes to infinity).
Now I have to proof the following proposition:

Suppose that the posterior distribution $Pi(\cdot|X^{(n)})$ contracts
  at rate $\epsilon_n$ at $\theta_0$. Then $\hat{\theta}_n$, defined as
  the center of a (nearly) samllest ball that contains posterior mass at
  least $\frac{1}{2}$, satisfies $d(\hat\theta_n,\theta_0) = O_P(\epsilon_n)$ under $P_{\theta_0}^{(n)}$.

$O_P(\epsilon_n)$ is not defined but I suppose it denotes stochastic boundedness (see wikipedia), that is, for $\tilde\epsilon >0$, there are $M, N \in \mathbb{N}$ such that for $n>N$, we have $P_{\theta_0}^{(n)} ( d(\theta_0,\hat\theta_n)/\epsilon_n > M) ) < \tilde\epsilon$.
The notes state the proof is very similar to a previous proof, which brought me to the following:
Let $B(\theta,r)$ be the closed ball of radius $r$ centered at $\theta$. Define $\hat{r}_n(\theta) = \inf\{r:\Pi_n(B(\theta,r)|X^{(n)}) \geq \frac{1}{2}\}$.
Then $\hat{r}_n(\theta_0) < M_n\epsilon_n$ with a probability tending to 1, with $M_n$ an arbitrary sequence with $M_n \to \infty$.
As we have chosen $\hat\theta_n$ as a nearly smallest ball, certainly $\hat{r}_n(\hat\theta_n) \leq \hat{r}_n(\theta_0) + \frac{1}{n} < M_n\epsilon_n + \frac{1}{n}$.
Now, $B(\theta_0,M_n\epsilon_n)$ and $B(\hat\theta_n,\hat{r}_n(\hat\theta_n))$ are not disjoint with probability tending to 1, since they would have a joined probability tending to 1.5. So:
$d(\theta_0,\hat\theta_n) < 2M_n\epsilon_n + \frac{1}{n} \implies d(\theta_0,\hat\theta_n)/\epsilon_n < 2M_n + \frac{1}{\epsilon_n n}$,
with probability tending to one. In other words, for $\tilde\epsilon >0$ there is some $N$ such that for $n>N$,
$P_{\theta_0}( d(\theta_0,\hat\theta_n)/\epsilon_n \geq 2M_n + \frac{1}{\epsilon_n n} ) < \tilde\epsilon$.
However, if I understand stochastic boundedness correctly I need to somehow replace $2M_n + \frac{1}{\epsilon_n n}$ with a fixed $M$. But since $M_n \to \infty$, I don't see how this is possible. Any ideas on what I could do?

lecture notes
Answer: I think you're almost there. $X_n=O_p(a_n)$ when $P( | \frac{X_n}{a_n} | \ge M_{\delta} ) < \delta$. $M_{\delta}$ is affected by the choice of $\delta$. In other notations you can also write $M_{\delta}$ as $M_{n}$ where $n > N(\delta)$ s.t $\ni P( |\frac{X_n}{a_n}| \ge M_n ) < \delta$.
Bottom line is that in the definition of contraction rate, you could choose your $M_n$ as you please.


Does gravity get stronger the higher up you are on a mountain?

Question: So I saw this article stating that gravity is stronger on the top on the mountain due to there being more mass under you however I have read some questions other people have asked and most of the responses state that the mass is concentrated at the middle of the earth meaning gravity doesn't get stronger the higher up you go. I would like to know which one of these it is as the article is a pretty reliable source. Here is the link to the article https://nasaviz.gsfc.nasa.gov/11234
Comment: " gravity is stronger on the top of the mountain" I believe the word "stronger" is relative to another point at the same height and not relative to another point on the ground right?
Comment: Friendly reminder: to answer the question, post an answer, not a comment. Some removed.
Comment: Does this answer your question? [Do we take gravity = 9.8 m/s² for all heights when solving problems? Why or why not?](https://physics.stackexchange.com/questions/6074/do-we-take-gravity-9-8-m-s%c2%b2-for-all-heights-when-solving-problems-why-or-why)
Answer: You are getting different answers from NASA and from other sources, as they are talking about slightly different things.
NASA is talking about the acceleration of the GRACE satellite towards the earth, as it orbited over different regions.  When it went over the Himalayas, for example, the acceleration (gravity) was higher than average.
Other sources are talking about the difference in acceleration due to gravity at ground level, compared to if you were to walk up the Himalayas, then the acceleration would decrease.  That's because even though there would be more mass underneath, you've increased the distance from the earth.

More detail:
At the bottom of a cone shaped mountain of mass $m$, radius $r$ and height $r$, the acceleration due to gravity is $g$, due to the earth of mass $M$, radius $R$.
$$g=\frac{GM}{R^2}\tag1$$
the difference in gravity after climbing the mountain is
$$\frac{GM}{{(R+r)}^2}+\frac{Gm}{{(\frac{3}{4}r)}^2} - g\tag2$$
The 3/4 is due to the position of the COM of a cone.  Using 1) it's
$$g\bigl((1+\frac{r}{R})^{-2}+\frac{16mR^2}{9Mr^2}-1\bigr)\tag3$$
From formulae for the volume of a sphere and a cone and assuming equal density
$$\frac{m}{M} = \frac{r^3}{4R^3}\tag4$$
so 3) becomes, in terms of $g$
$$y= (1+\frac{r}{R})^{-2}+\frac{4r}{9R}-1\tag5$$,
putting $x = \frac{r}{R}$
$$y= (1+x)^{-2}+\frac{4}{9}x-1\tag6$$
plotting this

shows that there is a decrease in the acceleration due to gravity for all realistic cone shaped mountains.
For Everest, if it were a cone, $x=0.0014$ and the reduction in gravity is $y=0.002g$, so the usual $9.81$ becomes about $9.79 \;\text{m}\,\text{s}^{-2}$.
Comment: Intuitively, the field strength increases with the mass, but decreases with the *square* of the distance, so it takes a *lot* of mass to offset a small increase in distance. (Asymptotically, $n^2$ grows faster than $n$, even if $c_1n_0 > c_2n_0^2$ for some constants $c_1$, $c_2$, and $n_0$. Eventually, exponentiation wins for good.)
Comment: This is qualitatively correct, but I don't think that you can approximate the gravitational force from a cone by replacing it with a point mass at the cone's CM.  That would work approximately at large distances, but we're talking about standing at the apex of the cone.
Comment: Yes, there are two opposing factors, but on balance the strength of gravity get's lower at the top of a mountain, as the main factor is the distance from the earth.
Comment: @silverrahul "If someone was standing on Himalayas, won't the acceleration due to gravity measured at that point, be a little more because of the concentration of mass there" What concentration of mass? Wherever you are, consider the mass of a sphere centred on you. If you're on a flat plain, half of it contains dense mass of planet Earth. If you're on top of a mountain peak, that proportion is much less.
Comment: It could also be worth mentioning that unless you're at one of the poles there will also be a component of centrifugal force due to the rotation of the Earth, which be in a direction opposed to gravity (though not exactly opposite it, unless you're on the equator). This will reduce the force of gravity as measured at the surface. I don't know the relative magnitude of this compared to the two factors you mention, but I suspect it might be quite significant.
Comment: The centrifugal acceleration has maximum size $\omega^2R$ or about $5.3\times 10^{-9}R$, the difference of this acceleration between seal level and at the top of mount Everest height 8849m would be at most $5\times 10^{-5}$ m/s^2, it is much smaller than the other things being considered, so can be ignored.
Comment: Would the case be same for the surface of earth. If someone was standing on Himalayas, won't the acceleration due to gravity measured at that point, be a little more because of the concentration of mass there, and of course it would be lower because it is farther from earth's centre. So, wont both the factors be acting against each other ? Which one will dominate will depend on the exact situation.
Comment: Having now gone through the calculation, I get that the gravitational acceleration at the point of a cone with mass $m$, height $r$ and circular base of radius $r$ is $3 G m (2 - \sqrt{2})/r^2$.  This is not quite the same as (but pretty close to) the value you found; $3(2-\sqrt{2}) \approx 1.7574$ while $16/9 \approx 1.7778$.
Comment: @ Michael Seifert Maybe you are right (will have a look at that), but since we are already approximating a mountain that is not really cone shaped, by a cone, the change is very small, almost negligible
Comment: @ Michael Seifert looked at it now, yes you are right, thanks for pointing that out, I hadn't realised, but the graph didn't really change much, it goes from $y=-1.55x$ to $y=-1.56x$ for low (mountain sized) $x$, but as the point has been made with the existing model, the answer will be left with the 16/9.
Comment: @Nathaniel's comment is correct, and this effect is not included in the calculation of the answer. This effect makes it even more certain that the felt gravity on the top of the mountain is smaller than the gravity at the foot of the mountain.
Answer: There are two factors here working against each other.
One is the distribution of mass of earth near the spot, which is higher near the mountains and tend to increase the acceleration due to gravity at that spot.
And the other factor is the distance from the all the other mass from the other parts of the earth, which is also higher near the mountain and hence tends to decrease the acceleration due to gravity.
The net result will depend on the magnitude of these two counteracting effects, and will depend on the particular details of the mountain in question.
But the point raised in the other reply is correct about the particular NASA page you have linked. That is not a map of acceleration due to gravity on the surface of the earth. That is one measured by a satellite in orbit.  For a satellite in orbit, obviously the second factor is negligible, thus, only the first factor dominates, and hence the mountain areas show higher acceleration due to gravity.
Answer: Probably not by itself.
The gravitational acceleration of a spherically symmetric body is given by:
$$
g = \frac{GM}{r^2}
$$
where $r$ is the distance from the center. Assuming the uniform density, this would be:
$$
g = \frac{4\pi}3\frac{G\rho R_0^3}{r^2}
$$
where $R_0$ is the radius of the body. When standing on the surface ($r=R_0$), this becomes
$$
g_0 = \frac{4\pi}3 G\rho R_0
$$
Let's do some math for two extreme cases:

1) First, let's consider a spherical "mountain" of radius $R_1$ ($R_1 \ll R_0$) and the same density $\rho$. The gravitational acceleration when standing on the top of that "mountain" is:
$$
\begin{split}
g&=\frac{4\pi}3G\rho\left(\frac{R_0^3}{(R_0+2R_1)^2} + R_1\right) =
\left(\frac{R_0^2}{(R_0+2R_1)^2} + \frac{R_1}{R_0}\right) g_0 \\
&\equiv
\left(\frac1{(1+2\epsilon)^2} + \epsilon\right) g_0
=\left(1 + \frac{(\epsilon - 1)(1+2\epsilon)^2 + 1}{(1+2\epsilon)^2}\right)g_0
=\left(1 + \epsilon\frac{4\epsilon^2 - 3}{(1+2\epsilon)^2}\right)g_0 < g_0
\end{split}
$$
where
$\epsilon = R_1/R_0 \ll 1$. The inequality $g<g_0$ follows from $0<\epsilon<\sqrt3/2$.
Therefore, a "spiky" mountain, which could be roughly approximated by a sphere, will likely have a lower surface gravity on its top than the planetary average.

2) Now, let's consider a high plateau (also of the same density $\rho$) that extends long enough that its gravity on the middle of its surface can be approximated by the gravity of an infinite plate, but still negligible compared to the whole planet, i.e. a plateau of height $h$ and horizontal dimension $l$ such that $h \ll l \ll R_0$.
Gravitational acceleration of an infinite plane is $g_{\text{plane}} = 2\pi G\sigma$, where $\sigma$ is the surface density, which for the plateau is $\rho h$. The gravitational acceleration when standing on top of the plateau is then approximately:
$$
\begin{split}
g&=\frac{4\pi}3 G\rho \frac{R_0^3}{(R_0+h)^2} + 2\pi G\rho h
= \left( \frac{R_0^2}{(R_0+h)^2} + \frac{3h}2 \right)g_0 \\
&\equiv \left(\frac1{(1+2\epsilon)^2} + 3\epsilon\right) g_0
=\left(1 + \frac{(3\epsilon - 1)(1+2\epsilon)^2 + 1}{(1+2\epsilon)^2}\right)g_0 \\
&=\left(1 + \epsilon\frac{12\epsilon^2+8\epsilon-1}{(1+2\epsilon)^2}\right)g_0 < g_0
\end{split}
$$
where $\epsilon = 2R_0/h \ll 1$. Again, the inequality follows from $\epsilon$ being positive and sufficiently small. In this case, less than $(\sqrt7-2)/3$.

In both cases it turns out that the surface gravity will be lower than the planetary average. It is reasonable to assume that any reasonable mountains will be small bumps that are, regarding their gravitational acceleration, between a ball and (infinite) plateau. Therefore, if uniform densities are assumed, they will
However, all of the above considerations were under the assumption of an uniform density. If the mountain has sufficiently higher density compared to the rest of the planet (less likely) or if non-uniform density in the planet is distributed in a convenient way (more likely), then gravity will be stronger at the top of the mountain. But note that this will be because of densities, not because of the mountain. In a typical case, the surface gravity is actually likely to be lower.
Answer: The strength of gravity does vary from point to point on the Earth's surface, because the earth is not of even mass distribution. The images in the link you have provided are evidence of this.
The strength of the earth's gravitational field is given by $$a=\frac{GM}{r^2}$$ where $M$ is the mass of the earth, $G$ is the gravitational constant, and $r$ is the distance from the center of the earth.
Since it is inversely proportional to the distance from center squared, the further you move away from earth, the weaker this field strength is.
Comment: *But the force of gravity acts as if the entire mass of the earth were concentrated at the center* This is not true. If I'm aside from a cliff, and if I'm falling from its height, the geodesic I will follow will be different from the case where there is no cliff. What you are saying is only true far from the object, but when we are close to its surface, it becomes wrong to say so.
Comment: @josephh. But in general the Earth is not a featureless sphere, there will often be a mountain, cliff, skyscraper or hill nearby. Or maybe the stuff underground is not uniform. If to my North (underground) there is lots of heavy dense stuff (iron maybe), and to my South underground there are many empty caverns then the gravity where I am standing tilts very slightly to the North.
Comment: Check out https://en.wikipedia.org/wiki/GRACE_and_GRACE-FO
Comment: I was not talking about cliffs, but the case in general.
Comment: What @Dast said. In fact, geophysicists & geologists use sensitive accelerometers to locate dense minerals. See https://en.wikipedia.org/wiki/Gravimetry
Answer: If you are a satellite 6870 km above the center of the Earth, and directly below you there is flat land, you will experience some gravity. If you move on to another point, also 6870 km above the center, but this time there is a huge mountain below you, then this time you will feel a gravity which is slightly larger.
If you are a person standing on the surface of the Earth, 6370 km above its center, you will feel some gravity. If from there, you climb a 4 km high mountain, after that you will be 6374 km above Earth's center. Because your distance from most of Earth increases, the gravity you feel is slightly smaller.
(In both examples, the latitude should be the same before and after, otherwise the oblateness of Earth's shape (and in the second example also the related centrifugal force due to Earth's rotation) will influence the result.)
Answer: I looked at the link you gave, I think it may not mean to say the higher up you go on a mountain, the stronger the gravitational field.
The link's meaning, I suppose (because they mentioned it is measured by satellites, I suppose it was measuring gravity fields at the altitude of the satellites, which supposedly stayed the same for the whole measurement) is something like this: they measured gravity at the same altitude around the globe, and found that at this altitude and at spots with Mountain ranges right below, such as the Himalayas, due to the high concentration of mass, the gravity field is stronger. While at the same altitude and at spots with Ocean trenches right below, such as the Mariana Trench, due to the low concentration of mass, they measure a weak gravity field, as expected.


Difference between an endpoint and a port in SQL Server

Question: While I know why are ports used in SQL Server, I wonder what is the difference between an endpoint and a port. Ports can be managed using Configuration Manager, is it also possible to manage endpoints with CM?
Thanks for your time.
Answer: I like to think of it as the endpoint being the "SQL Server side" part of what a client connects to. There are endpoints for TCP (probably the one you refer to), Named Pipes and Shared Memory. Those are the regular endpoints that a client application connects to. You can, for instance, set privileges on an endpoint, allowing login A to connect to TCP and B connect to Shared Memory (not that I've ever had the need for this). The endpoint is implemented by a DLL (I usually refer to all this as "NetLib", and for TCP and Named Pipes exposed through a port.
Then there are endpoints for mirroring and the old SOAP web-methods as well.
Comment: I'm not sure I'd phrase it that way. A part of the endpoint is the port number. The endpoint is also manageable, in the sense that you can define permissions on it (and for other type of endpoints change port number).
Comment: Thanks for answer. Does it mean that each port has its appropriate endpoint, which helps to connect clients to a specified port??


How should I email professors regarding online research during covid-19?

Question: So I've been accepted into a masters program and there is this professor that I really want to get involved with hopefully as a research assistant. And since many if not most researches are being conducted online, I was wondering if its a good idea to email the professor to see if there is any way I can get exposure to his research by either working as his assistant or intern. I'd appreciate any comments!!
Answer: Sure you can.
Sending an email is the best way to find out if a particular professor/researcher is available. You can reach out to them via Email introducing yourself and your research area and what you intend to look into/research keeping in view the professor's research output.
If they dont reply then you can send a follow-up email after a week or so.
Hope this helps.


logistic regression sensitivity and other terms

Question: I'm a master's level statistician and have been doing logistic regression for a while. I'm helping a friend who is taking an advanced stats course and ran across some terms I'm not familiar with when working with LR. One of the LR homework problems is asking for the model's proportional by chance accuracy rate, full model's accuracy rate, and the model's sensitivity rate. I'm not sure how the sensitivity rate is different than the accuracy rate. Also, the prof wants a PDA model on the same data set to compare to the LR. I'm not sure what a PDA model is or is this a term for something that is usually referred to as something else.
Answer: Sensitivity is the proportion of true cases which the model correctly identified as cases. Accuracy is the proportion of observations which were correctly classified (ie not just cases but non-cases). Note that the proportion of true non-cases correctly identified as non-cases is the specificity.
See also the Wikipedia article https://en.wikipedia.org/wiki/Sensitivity_and_specificity


Some way to make Facebook Single Sign-On (SSO) work for Android browsers?

Question: as I know Facebook Single Sign On works only if Facebook app has been installed on the device. But if there a way to make it recognize Android browsers sessions to achieve the same results?
Answer: for that, i think our app needs to have access to the browser cookies and it needs to know the cookie key-value pairs(access_token,if any) set by facebook during the browsing sessions in the browser. I'm not sure as to whether is it really possible or not, but i guess thats one possible method.
Answer: It seems that it's not possible since even Facebook app doesn't share session with its site.


Can I increase the number of cores?

Question: Can I increase my Dell laptop from 2 cores to 4 cores? I want to use it to play videogames on it. How can I get to do this?
I have  a Dell Inspiron 15 5000
Comment: # of cores is a CPU characteristic. You would have to change the hardware and in laptops that's often not an option.
Answer: This would involve physically swapping the CPU with a different model. Given the fact that laptop CPU chips are mostly soldered in nowadays, this will turn out to be very, very difficult (albeit possible in theory).
Answer: Yes, you can if the processor is upgradable. Then all you need to do is, find a compatible replacement which has 4 cores. But some laptops have nonreplaceable, soldered-in CPUs. In that case, it is designed not to be upgradable. Therefore, you can't upgrade. (Technically, you can if you are an expert but it is not recommended and it just not worth it.)
However, if you want to play video games, then you should more concern about the GPU. Just for the record, in most laptops, you can't upgrade the GPU.

Can I increase the number of cores?


How to call your relative

Question: How to call your great aunt?
For example, if the great aunt's name is Mari,
is she called 'Great aunt Mari, or 'Aunt Mari' or just 'Mari'?
Comment: @Stephie et al. - I'm firmly against the close vote. To the learner, "There is no definitive answer" can *be* a definitive (and helpful) answer. I don't think the question here is about nicknames, but about whether or not native English speakers feel that "great" needs to be said.
Comment: Sorry, but there is no definitive answer. You might call her any name or nickname you like or agree upon. Example: My husband's grandmother was called "Uhu", which bears absolutely no resemblance to her real name. VTC.
Comment: You mean, even if you are not close to his grandmother, is it okay to just call her name/nickname? In my country, we only call Grandmother, so i am confused.
Answer: It often depends on the context.
If you asked me, "How are you related to Mari?" then, for the sake of precision, I would answer:

She is my great aunt.

However, in casual conversation, the great is often omitted, so I might say:

I need to leave work early today. My aunt Mari is coming to visit.

even though she's really my great aunt.
If I'm talking to people who already know that Mari is my aunt, the title is often omitted. So, for example, if I was talking to my mother on the phone, I could say:

Mari called me last week.

In other words, it's not considered improper to refer to her without the title of "aunt."
Through my childhood and into my adulthood, my cousins and I would omit the word "great" when talking about our great uncles. They were simply "Uncle Bobby" and "Uncle Jimmy."
Some families might change the convention to suit their needs, though. For example, suppose you had an uncle and a great uncle who were both named David. Your family might refer to them as "your uncle Dave" and "your great uncle Dave" just to avoid ambiguity.
Comment: Same -- I thought it was universal to use "Aunt (whatever)" as the polite form of address with a great aunt/uncle. I think we are both from the south though, so maybe not.
Comment: @hunter - If I was a learner and I'd watched five episodes of [*The Andy Griffith Show*](http://en.wikipedia.org/wiki/Aunt_Bee), I'd also be inclined to start assuming that we always preface an aunt's name with "Aunt". In reality, though, it varies, and depends on the local customs of the family and region.

How to call your relative


Incorrectly configured black border pi-4

Question: When you install and configure the raspberry pi desktop for the pi-4 you can select a box if you have black border on your screen. I selected this box but when I restarted the edges of the toolbar and edges of the desktop are outside the visible area. Please does anyone know a simple solution to this problem which doesn't involve rewriting your sad card and starting again?
Looking forward to your help.
Thanks
Seth
Answer: Edit the config.txt file in the boot partition and remote the overscan entries.
Comment: Thanks Milligan's. Do you mean remove overscan entries?
Answer: Put the SD card in your laptop or desktop and make an empty file called ssh in the /boot partition. It will enable SSH for your pi.
Put the card back into the pi and start it up. You can now in a terminal window on a computer (on the same network) establish an SSH session to your pi.
You can find the IP address of the pi from your LAN router, and then type in the terminal window to log in to your pi:
ssh pi@< IP address >
Then type: sudo raspi-config
The overscan option should be in one of its menus.
I don't know how to be specific for MS Windows unfortunately. Adepts speak of Putty in connection with ssh, but to me that's the stuff my father used to secure window panes in the frame. He never knew about MS. I never used either putty.
Comment: Thanks ArgenR sounds like I need computer. No access to one at the moment.
Comment: @Seth well, you wrote your SD card on some computer, didn't you? Apart from buying one ready-made I can't think of how to get the OS image onto the SD card any other way.
Comment: I did buy the pi4 bundle with pre loaded os on sd card. Thanks though.


Lightning channel decrease capacity

Question: Let's say Alice and Bob have a 2BTC channel together. Both have a balance of 1BTC. Can Alice withdraw part of her balance (say, 0.5BTC) from the channel?
Comment: I've edited your question to, in my view, make it clearer more to the point. I'm not entirely sure it was what you intended so of course feel free to roll back.
Answer: As mentioned by Antoine, Alice and Bob could make a transaction to close the channel, Alice could use her payout to make the payment, and then Alice could use the change of that payment reopen the channel with a lower capacity. Note that unless they collaborate to use both Alice's and Bob's inputs, the new channel would also lack the Bob's prior balance. The same could also be achieved more efficiently by splicing out the payment. Alice and Bob would then collaborate to spend the funding output to create a transaction with two outputs where one is the payment Alice wants to make, and the other output is a new channel's funding output. This would save a transaction reducing the overall blockspace footprint and channel-downtime as well as result in a new channel with higher balance.
Another option would be for Alice to pay someone else on the Lightning Network to execute an onchain transaction for her. If e.g. Carol who has a channel with Bob were to offer this service, and Alice would send a ₿0.5 payment through Bob to Carol (plus maybe a fee), who would then make the expected onchain payment. By creative use of HTLCs, this payment could even be linked with the payment on LN so that the whole chain executes atomically. Instead of reducing the channel capacity, this would shift some of Bob's Lightning balance from his channel with Carol to his channel with Alice (and reduce Alice's balance, while increasing Carol's). This layer-traversing payment type is referred to as a "submarine swap".
Comment: With splice outs you can make a payment from the channel and immediately create a new smaller channel. With a splice in, you can add another input and create a bigger channel. If the input is unilaterally controlled, you need to wait for confirmations again, though.
Comment: Yeah but by using splicing, we cannot create a new channel with greater channel capacity than the parent channel, right?
Comment: I didn't get properly this term "If the input is unilaterally controlled, you need to wait for confirmations again". What does this mean? Like how an input is unilaterally controlled
Comment: If one of the two channel partners is contributing the funds by themselves, they would be able to create a conflicting transaction that could cancel the channel open. One way around that would be to put the funds into a 2-of-2 with the channel partner first and wait for confirmations while the channel is still operating, so that when the additional funds are spliced in, both parties know that the source of additional funds cannot be spent in another transaction by the other one alone.
Comment: So, here for
1.)getting confirmations for 2-of-2 channel is 1 transaction
2.) settlement of balance, closing the parent channel  and opening new channel is other transaction,
Which is 2 transactions required for splice-in, but how is this efficient when compared to First settling and closing channel ->1 transaction and then
2.) opening new channel -> 1 transaction
This method also takes 2 transaction
How is splice-in method efficient when compared to normal closing and opening channel?
Comment: The closing transaction can create the new channel immediately instead of paying out the owners. The staging is optional if you do not want to interrupt channel operation at all, otherwise it can all be done in one tx.
Answer: If you mean decreasing the capacity of the channel to 1.5BTC in order to withdraw 0.5BTC onchain, it is possible in theory but not yet part of the Lightning Network protocol nor its implementations. That's called splice-out.
Of course, you can always do that today by closing the 2BTC channel and re-opening a 1.5BTC one.

Lightning channel decrease capacity


ESP8266 is not responding to AT commands and showing mem_failed on every code

Question: I was using Arduino Uno with ESP8266-12E. Today I was reading an article to blink LED using Webpage. The code wasn't uploading so I connected all the pins connected to 3.3V to 5V. Then the code was uploaded successfully. After that I switched off my laptop and Arduino. After 2-3 hours when I got back to work, the module wasn't responding to AT commands even after reconnecting it to 3.3V. The wifi is working fine since it automatically connects to the WiFi I have configured earlier. I used same settings and connections prior to that messing up. Also on every code upload it shows mem_failed. So, how can I get my WiFi to work?
Comment: I'd suggest you go and buy a new ESP8266 - and this time keep it away from 5V.
Comment: `The code wasn't uploading so I connected all the pins connected to 3.3V to 5V.` What on earth made you do that?
Comment: I don't know. I thought I should give it a try. And I don't know why it was uploaded then.
Comment: @jsotola The pins were Vcc, RST, CH_PD.
Answer: Buy a little development board and learn how to use the ESP8266. Either a NodeMCU or a WEMOS board. They have a USB to serial adapter on the board and a proper regulator.
The initial problem you encountered was most likely caused by insufficient power for the ESP8266. The power supply must be capable of supplying a minimum of 400mA. It needs to have close short wires to the Vcc and ground on the ESP module. It helps to also have a capacitor across Vcc and ground of the ESP module with short leads.
There are some horrible examples on the internet that show the ESP being powered from and Uno's 3.3v power connection. This will never be reliable if it does even work. There is not enough power.
The ESP8266 typically uses about 80mA. This is an average value. When transmitting the peak current is a lot hight. The worst case happens to be when the ESP starts after a reset. I then does an analog power calibration. (for the RF section) Expressif states this, plus the digital power requirements, will equal above 500mA.
The GPIO pins are not 5 volt compatible. A lot of internet examples show the ESP rx and tx lines connected to the rx and tx of a 5 volt Arduino board, without level converters. This is not acceptable. The RX line of the ESP8266 can be damaged.
Powering the ESP module with 5 volts can damage all or parts of the two chips on the module. (the CPU and the external Flash memory chip) Other sections may still work. That is likely what you are seeing.


new sequence formed by adding together corresponding term of a geometric sequence (G.S) and an arithmetic sequence (A.S).

Question: a new sequence is formed when adding corresponding terms of a geometric sequence and an arithmetic sequence. The G.S has a common ratio of 3 and the A.S a common difference of -2. first two terms of the new sequence are 4 and 20. calculate term 3 of the new sequence...please help
Answer: If I well understand your question the geometric progression is:
$$
a\;,\;3a\;,\;9a\;,\;27 a\;,\;\cdots
$$
and the arithmetic progression is $$
b\;,\;b-2\;,\;b-4\;,\;b-6\;,\;\cdots
$$
so, adding the corresponding  terms  $ a_1+b_1$ and $a_2+b_2$ we have
$$
a+b=4 \qquad 3a+b-2=20
$$
solving the system of the  two equation you can find $a,b$ and the third term.
Answer: If $a_1, a_2$ are the first two numbers in the arithmetic sequence and $g_1, g_2$ are the first two numbers in the geometric sequence.  We have 4 unknowns.  Can we create 4 equations based on the given information, and use that to solve for the 4 unknowns?
$a_1+g_1 = 4; a_2+g_2 = 20; a_2 = a_1 - 2; g_2 = 3 g_1$
That is enough information to solve for $a_1,g_1$ and you have the rules to find the next terms in the each sequence.


Append base tag to head of document

Question: I'm screen scraping using Simple HTML DOM. The problem is that I'm getting relative paths/URLs which I want to replace with absolute ones:
foreach($html->find('') as $e)
    echo $e->append('<base href="http://www.website.com">');

That doesn't work. I tried some other things from answers on StackOverflow with no luck. I can get it to work with preg_replace like this:
$curl_scraped_page = preg_replace("/<*>/i", "<base href='$url' />", $curl_scraped_page, 1);

But I really want to stick to Simple HTML DOM.
Answer: Search head instate of /head..
$html->find('head', 0)->append('<base href="http://www.website.com">');

Append base tag to head of document


Mass Remove File Prefix on a Mac?

Question: How do I mass remove file prefixes in a Mac? For example, inside my folder, I have the following files:
img_sometext1.jpg
img_sometext2.jpg
...
img_sometext10.jpg

How do I remove img_?
Comment: best answer https://superuser.com/a/1400717/16871
Answer: The easiest solution might be to use the commercial A Better Finder Rename to achieve this.
For a free alternative, you can install the command-line rename utility:

install Xcode
install Homebrew
open Terminal.app and do brew install rename

You can now use, in the Terminal, either of:
rename -d img_ *
rename "s/^img_//" *

to strip away the prefix.
Comment: Awesome! I already had homebrew installed and your solution worked perfectly well.
Comment: So amazing, this is just the tool I needed
Comment: beautiful! How is it not easier to find brew casks such as `rename`?
Comment: It's got renamed all the files in seconds
Answer: You can use Automator's Rename Finder Items action:

Start Automator, select Workflow, and add Get Specified Finder Items and Rename Finder Items from the library on the left to the workflow area on the right by double-clicking.
Drag and drop the files you want to rename to the list in Get Specified Finder Items.
Change Rename Finder Items to Replace Text as desired, and click the Run button.

Result after execution:
You can easily change this workflow to make it repeatable, e.g. with selected Finder items instead, and save it as Application or Service.
Answer: A quick visit from the year 2019 to give an update.
osX has something like this built into finder now.

Open finder
Select all the files you want renamed
From the right-click menu (or File menu) choose the Rename # items option
You'll be presented with a dialog window with options, one of which is Replace Text
Enter your prefix - "img_" in the Find box and leave the Replace box empty
Click Rename
Answer: If you want an elegant, easy, and feature-rich solution, I personally like Name Mangler.
Used to be called File List and was free, now it costs $10. May be a little steep for some people, but it's well-written and extremely functional if you don't want to get into the command-line methods of doing this.

Mass Remove File Prefix on a Mac?


How to get the Excel header on each print page to be the first row of the table

Question: I need the first row in an Excel spreadsheet to print as the header on all pages.
Answer: Go to file->Page Setup and choose the sheet tab. There is an option 'rows to repeat at top'.
Answer: Here is a step by step description of how to add header rows.

Start by selecting the page layout tab and then open the Page Layout dialog box.
On the Sheet tab of the Page Setup dialog box, click on the rows to repeat at top.
Clicking on the row you want to appear at the top of each page will populate the Page Setup – Rows to repeat at top dialog box. When done
  return to the Page Setup dialog box by hitting the enter key.
Select the OK button to complete the setup.
Now whenever you print preview or print your worksheet, the row you selected will be repeated at the top of each page.
Answer: also programatically (at least in c#) it's to the effect of:
<code>[excel sheet].PageSetup.PrintTitleRows = "$[firstrow]$[lastrow]";
</code>
I would expect other languages to handle it similarly though, being that it's a com interface.
Comment: This solution did not work.$[1]$[2] failed at compile time.
Comment: This will not work as it is now, the $[firstrow]$[lastrow] was just a reference to the absolute locations in excel of the rows you want to set as a header.  If I remember correctly, the right side of the equation is set to an excel range.
Comment: This works (using a constant instead of hard-coding the row (singular in my example):
_xlSheet.PageSetup.PrintTitleRows = String.Format("${0}:${0}", COLUMN_HEADING_ROW);
Answer: The problem is the missing colon(:) between rows to repeat at top.
You can even try this by viewing it as you set it manually within Excel(any version)
<code>Excel.Application xlApp ;
Excel.Workbook xlWorkBook ;
Excel.Worksheet xlWorkSheet ;
object misValue = System.Reflection.Missing.Value;

xlApp = new Excel.Application(); //Start Excel and get Application object.
xlApp.Visible = true;
xlWorkBook = (Excel.Workbook)(xlApp.Workbooks.Add(misValue));
xlWorkSheet = (Excel.Worksheet)xlWorkBook.ActiveSheet;
xlWorkSheet.PageSetup.PrintTitleRows = "$1:$1"; // Rows to repeat at top of Excel Page Setup
xlWorkSheet.PageSetup.PrintTitleColumns = "$A:$B"; // Columns to repeat at left of Excel Page Setup
</code>
Comment: Can you please explain what this code does and where he should put it? (If this should be VBA code, then there are several typos/errors)
Comment: This is C#, not VBA.
Answer: The old-fashioned way to do it is to define the name "Print_Titles" to be the rows you want printed at the top. Select the rows you want as a header, click in the text-edit box to the left of the formula bar, type "Print_Titles" and hit Enter.  Defining the name via the "Define Names" dialog or programatically works fine too, but I don't know where they hid the dialog box in the 2007 UI...
Comment: "Page Layout" > Print Titles (it's in the "Page Setup" group, 2nd from the left)
Answer: In MS Excel 2007, go over to the Page Layout tab, the first section of that tab is titled "Themes", the second section is titles "Page Setup" the last option there is "Print Title"  click it.
A dialog box will appear, simple click on the left column number 1 or your title line and the formula will auto fill. You have selected it and now "print".


C++; How to turn a string (name of class) into a type?

Question: A function should take in the name of a class and return an object of that type. How to do it in C++?
Answer: That's called reflection and is not part of the C++ language. It's possible to implement with something usually called a factory pattern. The way it works is that for each type you want to be able to create you create a mapping between a function that can create an object of this type and it's name.
This mapping could be something as simple as a std::map where the key is the name of the class and the value is a function pointer to a function returning a new instance of the class.
Comment: @Preet: As the term suggests, coming from Latin, intro_spection_ would only be the part of reflection that is about _observing_.
Comment: I thought the general term was introspection.
Answer: Depending on the exact requirements of your problem you might be asking about reflection (in the most general case) which is not natively supported by the language, but for which you might find some libraries, or a form of the factory pattern, where you create a function that receives a set of parameters and returns an object of the appropriate type. The second case is a much more limited scenario, where the types must be related, and you have to implement the factory...
So the question, would be, can you extend on your particular requirements?
Answer: You would have to rely on frameworks that introduce reflection on your objects, like the Qt Meta Object System, or write your own.
However, this is not true reflection and only works with your manual help, either in form of the need to invoke tools, or in form of you having to register the instantiable classes to the framework.


texas holdem regarding a pair K8 vs K9 and A comes on the river

Question: I have K8 the other player has K9 K on the board and A comes on the river, who wins the hand
Comment: What are all of the five cards on the table, the question can't be answered without fill knowledge of both hands.
Comment: I have tried to answer your question, but it is a bad question because it is incomplete.
Answer: The winner is whoever can find the best five cards from among their private cards and the shared cards. We often describe a hand as fewer than five cards - if I have KKA92 I might say I have a "pair of kings" or a "pair of kings with an ace kicker", but the truth is that I have a pair of kings with an ace kicker and then a 9 kicker and then a 2 kicker; it's just that those later cards usually don't matter. In your case though, it sounds like they do matter - if the best cards you can find are say KKA84 and your opponent can find KKA92, you lose.
[Note that the best five cards don't have to use your own cards at all, so if e.g. the center has AAAAK then your Q8 would tie with an opponent's 72 because both of your best five-card hands are AAAAK.]
Answer: I'm assuming no "special" features such as the unnamed cards giving anyone a  flush, or full house.
You will have a pair of kings. So does the other player. You both get the ace.
So far, your "hands" are both KK A.
You have an 8, and your opponent has a 9. At this point, you are trailing with KKA8 versus KKA9.
There will be a fifth card, X, to fill your hand. You have KKAX8, and your opponent has KKAX9.
Unless "X" happens to be a second 8, giving you a second pair, you will not win, because your 8 cannot beat his 9. In fact, you will lose unless,
The other three cards than the A on the board are something like QJT, or QQT, basically, three cards higher than your opponent's 9. Then you both "play the board," and his 9 versus your 8 becomes irrelevant, and you "tie."
If the 9 versus 8 matchup comes into play, you lose.
Comment: I think it would be much better to wait until the OP clarifies / edits his question, because as-is you are just taking a best guess as to what the answer (and the question) could be.
Comment: @GendoIkari: It's called a decision tree. Fortunately, there are only a limited number of branches, and I think I've covered most of them. A better question would leave two or three possible branches instead of five or six.


Restore SIM Card details to PC

Question: I have my SIM card from the back of my Samsung Galaxy S5. However, I do not have the phone anymore. I will not be getting a new phone for quite sometime.
My question is; is there a way to retrieve the entire contents of my SIM card, without having a phone? Maybe there is a way to download the contents to my pc. Please advise
Comment: Can you borrow a phone for a few mins? You could copy all your numbers etc to that phone, then backup to Google or elsewhere? Otherwise you'll need hardware to connect a SIM to the PC.
Answer: You can buy SIM card readers for PCs, which will come with Windows software to retrieve any phone numbers and SMS messages from the SIM card. Just search your local Amazon site or eBay for SIM card reader. Be careful not to get an SD card reader by accident!
Do bear in mind that most Android phones don't store contacts on the SIM card by default, but on the phone itself. The SIM card can only store very limited information about contacts: just a name and a number. Unless you're sure you've moved all your data onto the SIM card, you might put a lot of time into finding a reader only to find the SIM card is empty.
Answer: Your carrier, if they have a store, should also have the equipment for this and should do it for free.
You can back them up and probably use a dummy phone or gateway to sync them somewhere so this isn't an issue in the future.
If you currently do not have a carrier, they may still do it for free or for a small fee depending.

Restore SIM Card details to PC


Add some default text to Ctrl-Alt-F1 console to remind myself how to reboot properly

Question: I do know there are questions and good answers, what to do if Ubuntu just hangs (like this one: What should I do when Ubuntu freezes?). My problem is that such a hang occurs so seldom for me, that I don't remember most of the answers at that time and I have no second machine to ask the Internet while my main system hangs.
I always remember how to open the console using some Ctrl-Alt-Fx combination. So is there a possibility to have some lines of "intro text" in that console, which tell me directly after switching to the console how to kill hanging processes and how to properly reboot? Think of it as a "reminder to self".
DOS had the ability to change the prompt in a console to arbitrary output. Maybe something similar can be done here to get me remember at least the basics?
Comment: Sticky note? XD
Comment: just kidding, man.
Answer: In the text console, you'll see a line with a text like Ubuntu 10.04 darkstar tty1 just before the login prompt. This message comes from the file /etc/issue, which you can customize to your wishes. The escape sequences are described in the getty(1) manual page.
Comment: Tested. Works fine. I'm still waiting for the next distribution update to see if my changes are replaced. If so, I might switch to the other solution.
Comment: 3 months later: I have successfully used the above system on two occasions now. Both times it helped avoid rebooting. Quite good, because I usually have several projects and documents opened at the same time and don't want to risk issues with them.
Answer: Edit the 'message of the day' (motd). This is shown whenever you log in to one of the Ctrl-Alt-Fx terminals. You can edit it with this command: sudo nano /etc/update-motd.d/10-help-text. This is a shell script that prints a help message to the screen. It is only part of the motd. The other 'fragments' can be found in the /etc/update-motd.d directory.


The parity of the full automorphism group order of finite non-abelian groups of prime exponent

Question: Is there a finite non-abelian group $G$ of prime exponent such that the full automorphism group of $G$ is of odd order?
Comment: I added the Lie algebra tag, because a $p$-group of exponent $p$ and nilpotency length $<p$ can be viewed as a Lie algebra by Malcev correspondence.
Comment: Also, 32000 groups of order $5^7$ is tested and there is not such example. Only one group with odd order automorphism exist, but the exponent of this group is $125$.
Comment: Did you do any computer verification (in view of my answer, I'd be interested in a checking for groups of order $3^4$, $3^5$, $3^6$, $5^6$ expecting there are no examples, and would expect an example in order $p^7$ or $p^8$ for some $p$)?
Comment: @YCor. I have done it for all non-abelian groups of exponent $3$ of order at most $3^6$. There is no such example among such groups.
Comment: @YCor. There is also no such group of order $5^6$. Note that all groups of exponent $3$ and of order at most $3^6$ is of class at most $2$.
Comment: @YCor. There is no example of order $3^7$.
Answer: Yes:

for every prime $p\ge 7$, there's a finite group of exponent $p$ whose automorphism group is a $p$-group.

Initial answer (Jan 18' 2016)
Start from any (finite-dimensional) complex nilpotent Lie algebra $\mathfrak{g}$ that is defined over $\mathbf{Q}$ and has a unipotent automorphism group (see e.g. Luks' Lie algebra top of p14 in (Ancochea Campoamor survey) for a 16-dimensional example), see also first edit (Jan 19' 16) below.
Fix a rational structure, so we can defined $\mathfrak{g}_p$ as the corresponding Lie algebra modulo $p$ for $p$ large enough (i.e., not dividing any of the denominators). (Formally speaking, this means writing $\mathbf{g}=\mathfrak{h}\otimes_{\mathbf{Q}}\mathbf{C}$ for some Lie algebra $\mathfrak{h}$ over $\mathbf{Q}$.)
Then for $p$ large enough, the automorphism group of $\mathfrak{g}_p$ is a $p$-group. Indeed otherwise, if for a growing subsequence $(p_i)$ this is not the case, say $\mathfrak{g}_{p_i}$ has an automorphism of prime order $\neq p_i$, passing to the algebraic closure $K_i$ of $\mathbf{F}_{p_i}$ and then to a ultralimit over $i$ we get that the ultraproduct, which is a Lie algebra over the ultraproduct $K$ of the $K_i$ has a nontrivial semisimple automorphism. But this ultraproduct is isomorphic to $\mathfrak{h}\otimes_{\mathbf{Q}}K$. This contradicts that $\mathfrak{g}$ has a unipotent automorphism group.
Note that this provides a group of order $p^{16}$ with some well-controlled nilpotency length (I haven't made the computation for Luks' Lie algebra but it's easy to do), but gives no control of $p$, although for small $p$ a computer computation is doable).

We can expect a computer computation to yield explicit examples.
Anyway no example is possible for $p$-group of nilpotency length 2 (and odd exponent $p$): indeed such a group admits an action by automorphisms of the multiplicative group modulo $p$ (of order $p-1$), because the corresponding Lie algebra is Carnot. Classification along with Malcev correspondence also shows that no group of order $p^{\le 6}$ for prime $p\ge 7$ can work, because the corresponding Lie algebras have nontrivial integral gradings according to the classification by de Graaf in here (J. Algebra 2007) [this also works in order $5^{\le 5}$, and in order $5^6$ except for nilpotency length $=5$].

Edit: (Jan 19' 2016) I have checked that the 7-dimensional (with nilpotency length 6) Lie algebra given page 17 line 8 in (Ancochea Campoamor survey), viewed with coefficients in an arbitrary field, has only unipotent automorphisms. If one takes it in the field on $p$ elements for any prime $p\ge 7$, the Baker-Campbell-Hausdorff (which realizes Malcev's correspondence) provides a group of order $p^7$ whose automorphism group is a $p$-group (thus of odd order).
According to what's above and computer check by Alireza for $p=3,5$, for $p$ odd any nontrivial $p$-group of order $\le p^6$ has an automorphism of order 2. So $p^7$ is the smallest possible order for such exceptions, for $p=3,5$ possibly one has to go a little higher since Alireza checks that every group of order $3^7$ has an automorphism of order 2. (At the moment this gives no example for $p=3,5$ although they certainly exist.)

Edit: (Jan 25' 2018) Thinking a little about the remaining cases $p=3,5$, they seem different and deserve separate additional comments:
first recall by above remark that for any odd $p$, the nilpotency length of any example should be $\ge 3$.

for $p=5$, Malcev correspondence is valid in nilpotency length $\le 4$. Therefore if one searches among nilpotent rational Lie algebras of nilpotency length in $\{3,4\}$ and unipotent automorphism groups, one can reasonably hope to find one that reduces modulo 5 and for which the reduction modulo 5 has no extra automorphisms.
$p=3$ is quite different, because exponent 3 implies nilpotency length $\le 3$ (in contrast, by Razmyslov's theorem, for all $p>3$ there are finite groups of exponent $p$ and arbitrary large solvability length). So in this case, Lie algebras are of no help. Finding a finite group of exponent 3 whose automorphism group is a 3-group (or of odd order) sounds a quite different question.
Comment: Is it possible to give an explicit presentation for the group of order $p^7$ in your last EDIT? I have used the same relations as the Lie algebra with the relations of 7th powers of all generators. This gives me a group of nilpotency class 5, expoenent 7 and order $7^6$ whose automorphism group is of order 242121642.  Is this because my group is not obtained from BCH?
Comment: Yes you really have to use BCH. You have a presentation with generators $x_1,\dots,x_7$, relators $x_i^7=1$ and, for $i<j$, $x_ix_jx_i^{-1}x_j^{-1}=m_{ij}$ for all $i,j$, where $m_{ij}$ is a word in $x_{j+1},\dots,x_7$. With BCH you can compute $m_{ij}$ in the Lie algebra, that is some combination $(\ell(j,j+1),\dots,\ell(j,7))$. This has to be converted into a word of the form $x_{j+1}^{k(j,j+1)}\dots x_7^{k(j,7)}$. Then $k(j,j+1)=\ell(j,j+1)$. To find the next exponents, first compute $x_{j+1}^{-k(j,j+1)}m_{ij}$; then $k(j,j+2)$ is the $j+2$-coefficient in the resulting element, and so on.


How to invoke a fallback function from Ethereum Wallet?

Question: I would like to invoke a fallback function of a contract from Mist Wallet. However, I am not able to see it in the drop down list of functions.
Comment: Could you supply a screenshot so we can see what your browser is doing?
Comment: What is the need to explicitly invoke a fallback function?
Answer: Fallback function may be invoked when you send a transaction to the contract address  The condition is that data field must not match to the any signature of any contract function. In this case fallback function is invoked.
Leave data field empty and send payment to the contract is the usual way to invoke the fallback.
Answer: I was not able to invoke explicitly from Mist. However, I used .call() function to invoke the fallback function by passing a non existing function. ( clickk is a non existing function in my contract )
function invoke (address bt) {
        bool ret = address(bt).call(bytes4(sha3("clickk()")));
  }


How to totally remove unwanted contacts from hangout

Question: How to totally remove unwanted contacts from hangout. Totally clean out from hang out means - not appearing in archive, not appearing in block., not appearing in hidden.
Answer: It's not possible because when the Hangouts user is searching for a contact, the search results, according to See people's online status - Hangouts Help, could include:

Your contacts
Your circles
People in your domain
People on Hangouts
People not on Hangouts


Need of Image Encryption

Question: Question is simple yet confusing, why there is the need for image encryption. How text encryption is different from image encryption if using same technique like AES, DES, Chaotic algorithm. If the only difference is at implementation it's more of engineering task than science. Can same encryption technique applied to both text and image, then why image encryption a separate part.
Comment: What leads you to believe that image encryption is a separate thing? Can you cite some sources? That would help us know specifically what you are talking about.
Comment: Because non cryptographers want to feel like they can create crypto too?
Comment: @PawanYadav Your confusion is justified - "image encryption" is generally the hallmark of "cranks" who don't really understand what they're doing/talking about. There is no reason you can't apply an arbitrary encryption algorithm to a given subsection of an arbitrary file.
Comment: I think and believe that they are the same thing, the only difference is implementation. But when I see research papers with title image encryption using AES or DES or Novel approach, seems confusing, why just image, when it can be applied to other data too. Just curious. Thanks for reply.
Comment: @EllaRose Thanks for the reply. So, that means it's merely an engineering task to use that algorithm (where actual science is applied), to perform a particular task i.e. different data types.
Answer: There is no need for those image encryption algorithms.

You can encrypt an image file, like any other sequence of bytes using standard encryption.
If you really want to encrypt the pixels themselves (not recommended), you can use standard length preserving encryption, such as a four round feistel network.

I've seen some image encryption papers, but they were badly written by people with little understanding of cryptography and not published in cryptography journals/conferences.

Need of Image Encryption


How to replace thick set tile with wall?

Question: I am removing my thickset tiles in the kitchen of my 1950s home. I want to replace dated tiles with a smooth wall. Do I need to remove all the way through to the wire mesh or can I chisel off 1/2 of mortar (after removing the tile) and even it out with plaster? Thank you
Comment: What is "thick set" tile? Do you just mean tile installed over plaster? It would still be installed with mastic, and not a mortar bed like you would see on a floor.
Answer: All things considered you will probably find it much easier to simply remove the existing wall down to the studs.  Demolition is hard work but its fast work if you prepare the edges properly by cutting a seam along all the edges that goes the depth of the wall.  Then you just pull it all out and get rid of it.
After you're down to studs you can put up new, clean drywall.  Overall it's going to be faster than trying to "save" the old wall - which you won't really be likely to save anyway cause its nearly impossible to remove tile w/o destroying the wall underneath.  Tile from concrete sure, but tile from backerboard or plaster wall?  Forget it.  Demo the thing.
Comment: Thank you. Demolition seems to be the way to go (it is wire mesh). Im new to DIY so I am just concerned that if there plaster on the upper half of the wall, would drywall be able to sustain the upper plaster wall or should i plaster all the way through. Thank you
Comment: In old school thick set it is not even backer or plaster, it is wire mesh, instead of wood lath or rock lath... Still the same process of removal as you mentioned.


Tag for Bulk Rename Utility?

Question: I lack sufficient reputation; can someone please create a tag for Bulk Rename Utility?  See How can Bulk Rename Utility automatically move down to the next file, after the current highlighted file has been renamed?.
Comment: Every piece of software doesn't need its own tag, and it can be counter-productive.  Tags help to attract answerers who follow a subject.  If a tag has only one question (or a few), the tag isn't serving any purpose.  If that tag is used in place of a more general one, it will hide the question from people who follow the more general one.  If the question is somewhat generic, a program-specific tag may discourage people from reading the question or answering.  Use program-specific tags when the program has its own following.
Comment: Your question was answered in the comments, adding a non essential tag will not help get you more answers.
Answer: A search turns up only seven questions that mention the Bulk Rename Utility, and out of those, only two or three are actually about the tool. The BRU doesn't seem widespread or nuanced enough to merit a tag considering the previous.
Therefore, I don't think we need a tag for it yet. Tag such questions with the OS and what you're trying to accomplish. Mention the specific software and its version in the question too, of course.

Tag for Bulk Rename Utility?


How big does a LEO object need to be to be clearly visible from the ground?

Question: Pretty simple question I just don't know the math for. If I want my space station/megastructure that's orbiting 2000-ish km above Earth to seem roughly as large as the Moon to an observer on the ground, how large would it need to be? My blind best guess is more than ten kilometers long/wide, but I'd like to know exactly how big an object would need to be in order to partially obscure the Moon by at least 50%.
Comment: Your title asks the object to be clearly visible, then your question asks first as large as the Moon and then 50% of the Moon. Can you make up your mind and ask just for one thing?
Comment: I don't think this question is a duplicate at all. As the other query says, the ISS is "visible ... but its features cannot be distinguished". IOW, it is not "clearly visible". Z.Schr., I think if you clarified your query by defining what you mean by "clearly visible", and added a link to the other query, it could be reopened as a distinct but related question.
Comment: It's not *exactly* the same question, but the same math can be applied; just substitute your own values. Hint: the angle subtended by Earth's moon, as viewed from Earth, [ranges from 0.49 to 0.55 degrees](https://er.jsc.nasa.gov/seh/math30.html).
Comment: The questions title seems like a duplicate, but OP is actually asking for size to partially obscure the moon, not size visible from earth as in 'duplicate'
Comment: @bukwyrm OP specifies an orbital altitude and an apparent size. The math involved is thus the same; all that's needed is to apply it slightly differently. Whether an object partially or completely obscores another is a function of many things besides merely the two objects' apparent size, not least the angle at which they are observed.
Comment: @aCVn exacltly. It's the same math in the beginning, but a different question altogether.
Answer: The relationship between true size and distance for two objects with the same apparent size is linear. That is, an object twice as far away, and twice the actual size, will appear to be the same size.
The Moon orbits at an average distance of about 385,000 km. (Although the distance between you and the Moon varies by a few thousand km depending on where you are on the planet, that's not a big deal here.) Low Earth orbits vary, but are generally on the order of 1/1000th of this, or ~300 to 400 km. (The International Space Station orbits at a little over 400km.) So your object needs to be about 1/1000th the Moon's radius, or only about 1.7km. That's big in terms of sending things into space - the ISS is only about 100m long, and that's counting all the panels and such - but it's not that big in absolute terms.
However, there are a number of problems with this. One is that while the variations in distance to different parts of the Earth are fairly negligible for the Moon's size, they're not for your satellite's size; it will appear much smaller from distant parts of the Earth than from directly beneath it. A second problem is that the Moon's orbit is somewhat eccentric - it moves up to 5% closer and further from its average distance during its orbit. Naturally, this has a similar effect on its apparent size.
Also, this only ensures that your satellite has roughly the same apparently size as the Moon. Actually occluding the Moon is a much trickier subject. You can look up solar eclipses to get a feel for the geometry involved, but the short version is that the satellite would need to be in a particular orbit, it would only eclipse the Moon every so often, and the eclipse would only be visible on certain parts of the surface.


Can Nioh for PC be played with keyboard/mouse?

Question: I have Nioh for PC. It works perfectly with the xbox controller. When I try to play with keyboard & mouse, only the keyboard works; the mouse does not. Can you play Nioh for PC with a mouse?
Comment: @Roijan Thanks for edit my post. My English is terrible, i learning but is very dificult to communicate. At least I understand almost everything.
Answer: Nioh does not support mouse configuration as mentioned here
The article states:

A recent press release from KOEI TECMO America and Team NINJA, reveals that the PC release of Nioh does not have mouse support. Dubbed Nioh: Complete Edition, it's stated that while the title does support a keyboard, it's best played via a game controller.

EDIT: I did some further looking. There is a mod which I found through a steam forum post It talks about the fact that it is possible and then links to a youtube video. With a slightly older version GPDSCK 3.1
In the description there is a link to a new video with a mediafire file with the latest version GPDSCK v3.3b
Now I do not own Nioh myself. But from the amount of people commenting on it. This seems like the best solution as of now.
EDIT 2: as @Nolonar mentioned. There has indeed been an official update regarding Nioh's mouse support. You will however need to rebind the keys. I suggest you check the options menu in the game and check if it is possible.
Comment: Apparently, there's an official update incoming (if not already released), which adds mouse support to the game.
Comment: I shall look for an exact date , if true add that info


Can an accelerometer be used to detect heart sound?

Question: I've recently come across accelerometer and how it can detect electrical mechanical response. I was wondering can it be used to detect heart sound? Lets say you attach the device close to your chest (where heat lies) and detect sounds and send it over bluetooth? LPMS-B2 OEM
Answer: An accelerometer detects motion (acceleration) of the physical device.
If you can convert the sound of the heart into physical vibration then the accelerometer can detect that vibration.
Converting the tiny amount of sound the heart produces into a large enough vibration for the accelerometer to detect would entail (realistically) using a microhone, amplifier, and speaker, with the accelerometer attached to the speaker cone.
So while theoretically yes, you can do it, practically why would you when you can just use the microphone and amplifier that you'd be using anyway. It's pointless.
So in reality: no, you can't.
Comment: Well said Majenko, I was thinking the same, and quite frankly, most people agree with your reasoning! Cheers!