Tried to remove one GU10 bulb, afterwards lost the entire fixture

Question: We are in a new-to-us home, and the breakfast nook has a hanging fixture with 5 GU10 (or at least I think they are GU10) bulbs, all in a row. The 4th one has been dark since we moved in so I decided to tackle it earlier today.
After much wrasslin' and cussin', I ended up breaking the bulb despite trying the rubber gloves 'push and turn' method.
After getting most of it out, glass shards and all, some of it was still left in there so I tried some pliers, only making the problem worse.
Left it for another day, but as I was about to close up for the night I dimmed this fixture (the fixture uses a Lutron I believe) and after working as normal for a few minutes there was a sound like something between a loud click and a snap, and the entire fixture went dark.
The dimmer switch does not respond at all, and nothing lights up on the little dots in the switch. The breaker panel is all fine, nothing tripped.
I am concerned this could be a fire issue, and of course I'd like to get the fixture working again, even with 4 out of 5 bulbs.
What is the likely problem? Is the fixture toast, or the dimmer, or both? How do I go about troubleshooting? I've done light electrical work before (and one time, in a foolish prior life, actually added a 20 amp breaker to a box but I won't be trying that again). I do have some tools but before trying anything I thought I'd check here first.
Thanks in advance!
Comment: so, it sounds like you were poking the pliers into a live circuit ... if you did not turn off the breaker before you tried to extract the bulb, then you should be calling an electrician to do the repair and lightbulb extraction, because you may just be lucky to be alive and you should not push your luck any further
Comment: You worked on this live, even pushing pliers into a live socket and you wonder why it finally blew something?? Just get a professional as next time it might be your Darwin Award entry.
Answer: Just replace the stupid fixture.  The entire point of the GU10 was to force people to stop using filament bulbs and replace them with Compact Flourescent bulbs.  This was in the days when the cost for CFC was higher than filament and the lifetime was the same as filament so naturally nobody was interested in buying them except California who was struggling with the shortage of generation capacity due to their stupidity in electrical regulation.
Today, with LEDs the Edison-base replacement market -DWARFS- the GU10 market and with LEDs costing the same as filament and the lifetimes of them so much longer, there is no need for goofy sockets to force people to replace lights with LEDs the cost savings and reduced replacement intervals are plenty good enough for that.  The final nail in the GU10 socket was when CA stopped requiring them in new construction.
I haven't seen a new GU10 fixture at Home Depot for quite a while now.  Everything is Edison-base and the vast majority of LED bulbs are Edison-base.  They have a few token GU10's in basic sizes for apartment dwellers stuck with this strange deviation from what has got to be the most foolproof light socket ever designed, but the cost of GU10 bulbs is rising as the demand has been falling and we all know where that vicious circle is headed.
The former owner of the home knew the future of that light in your nook was fixture replacement and left it for you to do.  Take your wife shopping at HD and let her pick out a new fixture and get some good husband brownie points for this one.
Comment: And for crying out loud, the OP needs to *turn the breaker off* before they work on it!
Answer: Thanks all, good comments including pointing out my stupidity. Everything is a learning experience! In my (partial) defense, I did make sure the switch was off. One challenge to turning off the breaker was that I didn't know which breaker it was (I do now, read on).
So I thought, since we don't like the fixture anyway (esthetically as well as practically), and I had a spare, simpler one, I installed that (after turning off ALL breakers to that area of the house).
After installing the new fixture, the light still didn't work, so I replaced the Lutron dimmer with a standard switch, and it lit up. So I guess the dimmer switch burned out. Remember I said that on full on, it was working fine, it was only when I left it in partial position that it popped.
Can anyone tell me why the dimmer popped? I don't need this info now but would be good to know. I will probably buy a new dimmer switch to replace the standard one.
Comment: Dimmers are (compared to standard switches) complex electronic devices. As such, they are sensitive to surges, such as can happen when there is a short in a fixture. If you get a new dimmer, you need to beware of neutral needs. The old dimmer may or may not have needed neutral. Your standard switch does *not* need neutral. A new dimmer, particularly to be LED compatible will *probably* need neutral. If in the process of replacing the dimmer with a regular switch you ended up with an "extra" white wire, that is neutral and you'll be OK. If not, post pictures here and we'll try to help.
Comment: Thank you. I will try to get to this after work today or tomorrow but I do not recall there being an extra white wire. So I think you are saying that newer dimmers will not work if this is the case?
Comment: I said "will probably" and I meant it. You need to check the installation instructions. Some will make it very clear "needs neutral" or "does not need neutral". For others you will need to look through the details to see.
Answer: It may be on an arc fault breaker and if you're not familiar with that type breaker wouldn't notice that it tripped. Another possibility is that it tripped a gfci so you may need to reset any of those thats tripped. Check bathrooms and kitchen area or even outside or garage receptacles. You can disconnect the individual socket from the other 4 in the light fixture itself if you want to keep using it for now.


Is barium sulfate soluble in dilute mineral acid?

Question: I have read that $\ce{BaSO4}$ is soluble in $\ce{HCl}$ , but I am not sure whether this works for dilute acid as well.
The reaction is -
$\ce{BaSO4 + 2 HCl ->BaCl2 + H2SO4}$
Comment: H2SO4 does not form, $\ce{HSO4-}$ does. And you have to add the physical states as you are documenting how a substance goes from solid to aqueous. Another hint: chloride is a spectator ion.
Answer: The key point is to have an acid with such a high $\ce{H+}$ activity that in large extent shifts the below reaction to the left :
$$\ce{  HSO4-  + H2O <=> SO4^2- + H3O+ } \\ K_\mathrm{a2}=1.0 \cdot  10^{-2}$$
Then activity of sulphate ions from dissolution of $\ce{BaSO4}$ is decreased by the equilibrium reaction and the solubility increases.
$$\begin{align}
K_\mathrm{s}&=a_{\ce{Ba^2+}}\cdot a_{\ce{SO4^2-}}=1.1\times 10^{-10}\\
\frac{K_\mathrm{a2}}{a_{\ce{H+}}}&=\frac{a_{\ce{SO4^2-}}}{a_{\ce{HSO4^-}}}\\
\end{align}$$
The  effective solubility product
$$K_\mathrm{s,ef}=K_\mathrm{s} \cdot    \frac{a_{\ce{H+}}}{K_\mathrm{a2}}$$
Note that despite activity coefficients {gamma} decrease with increasing ionic strength, for concentrated acids this tendency reverses and raises very rapidly
<code>[HCl]  Gamma
0.0005 0.975
0.01 0.904
0.1 0.796
1 0.809
2 1.01
5 2.38
10 10.44
12 17.25
</code>
Therefore, $a_{\ce{H+}}$ of 10 M HCl = 104.4.
$$K_\mathrm{s,ef}=K_\mathrm{s} \cdot    \frac{104.4}{K_\mathrm{a2}}\\=1.1\cdot 10^{-10}\cdot 1.044\cdot 10^4=1.148\cdot 10^{-6} \mathrm{~ mol^2 L^{-2}}$$
Solubility would be then $ M \cdot \sqrt{K_\mathrm{s,ef}}=233.4 \cdot 0.001072=0.25\mathrm{~g/L}$
Conclusion: The $\ce{BaSO4}$ solubility in concentrated $\ce{HCl}$ is limited, in diluted one is very low. The solubility in concentrated sulphuric acid would be much higher, as $a_{\ce{H+}}$ would be very high.


Failing Jarque-Bera test but residuals looks normal on q-q plot and histogram

Question: If I'm failing the Jarque-Bera test but the residuals still appear to be normally on a qq plot and histogram, is it acceptable to say that my residuals are approximately normally distributed? Asked another way, how reliable are those normality tests and do you need to meet them to pass the normality assumption.
Comment: [This question](https://stats.stackexchange.com/questions/2492/is-normality-testing-essentially-useless) may be useful.
Answer: Your question is very general and it's hard to answer specifically without more details from you

what are you trying to use this data for ?
How big is your dataset ?
Are you interested in the tails of the disrtribution of your sample or the bulk ?
Have you cleaned-up your data to remove outliers ?
The qq plot is only visual test whereas Jarque-Berra is statistical so hard to compare the 2
Have you tried other normality tests ? Kolmogorov-Smirnov is not sensitive to tails as much as JB

For more infos you can look a lot of material online. See this nice presentation about normality tests
Comment: 1) Ultimate goal is a predictive mode.
2) Interested in the bulk.
3) Reluctant to remove outliers but have done normalizing transformations. e.g., log (y)
4) I have tried the shipiro test, which also fails.
5) Data set of about 2,400
Comment: Thanks for extra details, please update those into your question for better quality. Have you tried KS test ?
Comment: Haven't, but will. How about the sample size? In the source you referenced,it said that as the sample size increases, the tests become more restrictive and less important. Might that be the case here?
Comment: @Ajk it is hard to make any statement absent any numerical data
Comment: What numerical data do you need?
Answer:
If I'm failing the Jarque-Bera test but the residuals still appear to be normally on a qq plot and histogram, is it acceptable to say that my residuals are approximately normally distributed?

No, it is appropriate to state they are bell-shaped after transformations and normalizations.

Asked another way, how reliable are those normality tests and do you need to meet them to pass the normality assumption.

Your question depends on the characteristics of the sample.  Restated, your question is "does the Jarque-Bera have sufficient power to test my hypothesis?"
That is, unfortunately, a complex question that doesn't generate a simple automatic answer for this topic.  Failing Jarque-Bera after the transformations in your comments is a pretty good statement that your data is not normally distributed.  Assuming your sample size is large enough to have power over the hypothesis, then Frequentist decision theory says you should behave as if the data were not normally distributed.
Given the seventy years of data on heavy tails, Jarque-Bera is ideally suited to detect them while other tests look for other types of departure.  Alternatively, the Shapiro-Wilk test will test disturbances in the position of order statistics.  A rejection by Shapiro-Wilk implies that not only are your tails wrong, but everything is in the wrong place.  If your sample is large enough to have power, then these would be the most powerful tests for your problem.
Based on your results, you should reject normality.  You also should not go test hunting in the hopes of finding a result that fits what you want.  Equity data, in particular, is notoriously non-normal.  Think of all the transformations you had to do just to get it close.
The importance of the normal distribution for most applications is the existence of a covariance matrix.  Not all distributions have them.  If it does not exist, you are in a different class of problems.
The question you should be asking is "if the normality assumption does not hold, what does this imply for the specific problem that I am facing?"
Predictive work is sensitive to the distributions involved.  If these are equities and given your transformation $\log(y)$, then the distribution should be the hyperbolic secant distribution, but that won't necessarily hold for an index.  That is also ignoring the impact of liquidity costs and constraints.


During a government shutdown, is it possible for US rocket companies to launch from outside the US?

Question: With the ongoing shutdown, it's causing some test flights of SpaceX and others to be pushed back.  If it goes on for an extended period, is it possible for said rocket company to launch from another site, like in French Guyana?
Comment: But how long does the preparation of an outside launch take?
Answer: No. There are at least 2 government agencies that must approve of a launch under normal circumstances, the FCC and the FAA.
Per FCC guidelines

Satellites authorized by an
  administration other than the United States do not require any FCC approval if earth station operations are
  exclusively outside the United States.

The FAA requirements are as follows

An FAA license is required for any launch or reentry, or the operation of any launch or reentry site, by U.S. citizens anywhere in the world, or by any individual or entity within the United States.
An FAA license is not required for space activities the government carries out for the government, such as some NASA or Department of Defense launches.

So you could only do it if you are launching by a rocket company that is not based in the US, and has no intention of ever communicating to an Earth Station inside of the US. A military launch, however, could still be approved, as it does not require FAA authorization.
Answer: Violation of trade restrictions
In addition to @PearsonArtPhoto 's answer of the FAA and FCC regulations, launching from another facility would violate the International Traffic in Arms Regulations and Export Administration Regulations ( ITAR and EAR).
From the ITAR wiki page:

For practical purposes, ITAR regulations dictate that information and material pertaining to defense and military related technologies (items listed on the U.S. Munitions List) may only be shared with U.S. Persons unless authorization from the Department of State is received or a special exemption is used.[3] U.S. Persons (including organizations; see legal personality) can face heavy fines if they have, without authorization or the use of an exemption, provided foreign persons with access to ITAR-protected defense articles, services or technical data.

All rocket and satellite technology (and its associated technical data) is considered ITAR. You would need special permission from the State Department to export it. Which you wouldn't get.
Answer: The government shut down did not stop SpaceX from launching an iridium satalite.
https://www.cbsnews.com/news/spacex-launches-falcon9-rocket-iridium-next-satellites-live-stream-today-2019-01-11/
SpaceX has many existing launch licenses.  See Faa.gov below.
https://www.faa.gov/data_research/commercial_space_data/licenses/
Answer: A launch pad with a launch tower suitable for that specific rocket would be neccessary. Also a launch control center with all those computers and terminals. Antennas and receivers for the telemetry of the rocket.
A lot of connections fitting to the rocket for tanking of fluids and gases. Many electrical connections for ground power and sensors needed for all checks during count down.
All that equipment present in French Guyana fits to other rockets. There is no unified universal launch complex that may be used for many different rockets from different nations.
To build all equipment missing there would take many month at least, if not a year or more.
Construction of a new launch pad for the Soyuz rocket was started in the Guiana Space Centre 2007 and finished 2010.


Use of から which means "from", for i-adjective

Question: I have learned about two uses of から which is for "from" and for "because". But for using of から for "because" that is warning that you have to use だから for Na adjective and unconjugated verb because it will be mistaken for から for "from". What I want to ask is how you use から to mean "from" for other than Na adjective and unconjugated verb (I adjective and verbal clause) without it being mistaken for から which means "because"?
Comment: I don't quite understand what you question is, but does this example help? From far away: tookukara. Because it is far: tooikara.
Comment: Why is it tooku?
Comment: Hmmm, my Japanese grammar is quite rusty, but it changes the adjective to an adverb I think (and I only have a vague understanding of what an adverb is in English). Tookuhe itta: He went far away, vs. tooi tokoroni iru: He is in a far away place. In this case the place is far away. For lack of a better explanation, I think you should just remember that when kere is used as meaning "from", you use the -ku form of the -i adjective
Comment: You should make it an answer! Thank you very much. It's not covered in the material I learned from (you have to use -ku).
Comment: I'm glad my confused explanation helped you :) It's not good enough to make an answer out of I feel though... Good luck in continuing your Japanese studies!
Answer: から in the sense of "from" must follow a noun or nominal phrase, or a verb in the conjunctive ‑te form.  It simply doesn't make sense to put から after an adjective to mean "from" + [ADJECTIVE], much as it doesn't make sense in English to put "from" before an adjective: for instance, "from happy" or "from reddish" or "from sour", these are all just gibberish.
Note: The comments under the question introduce some confusion, by suggesting that turning an ‑i adjective into a ‑ku adverb allows one to add から in the "from" sense.  This is a mistake, as the example phrase tōku kara is an exception.
Both 遠く (tōku) and 近く (chikaku) are special.  These are composed as adverbs (the averbial ‑ku forms of regular adjectives ending in ‑i), but they have also lexicalized (see Wikipedia): that is, in certain contexts, they act instead as standalone words of their own with different grammatical rules. Specifically, depending on context, these two words change from adverbs to nouns: 遠く means both "distantly" as an adverb, and "a far-away location" as a noun; 近く means both "nearly, closely" as an adverb, and "a nearby location" as a noun.  Thus, 遠くから (tōku kara) equates grammatically to [NOUN] + から ("from").
Using から ("from") after other ‑ku adverbs does not work.  For instance, *良くから (yoku kara, "from well"), *美しくから (utsukushiku kara, "from beautifully"), *赤くから (akaku kara, "from redly") are all incorrect, and make about as much sense in Japanese as they do in English.
(PS: If this does not fully answer your question, please rephrase.)
Comment: "I went from happy to sad", "From brainy to brawny" etc is one counterexample. (Though it makes no sense to say something is wrong in Japanese because it's wrong in English, anyway) Thank you for your edit on lexicalised words though- really interesting!
Comment: @rjh: The counterexamples are interesting.  However, they are also not quite counterexamples -- the English sentences have omissions, such as the word "being", as in "I went from _being_ happy to _being_ sad".  Conceptually / semantically, what is being talked about in the English is still a nominal: "happy" not as an adjective, but as a state.
Comment: @rjh: Re: wrong in one language versus the other, my underlying point is that certain combinations don't make sense _semantically_.  Since the asker of this particular question is clearly a beginner with Japanese, I thought it would make more sense to provide English examples by way of analogy.  :)


How to change an Image extension when user click to bottom to open it?

Question: I have an image folder which contains .tif image and when the user search for an image the image must be .png or .jpeg file extension to avoid browser incompatibilities while display .tif images. How can i do that? Please, notice that the images are save in a directory, not in a database.
Comment: Can you clarify your question? I didn't understand whether you want to convert an image or just change an extension. Also, what have you tried already?
Comment: What need is, once the user search a document that docment is being found, the user will have a bottom that will display the image, the images are in .tif format and i need them in .png format to avoid problems. Its like change the image extension but not save it, i just want to DISPLAY the image.
Answer: TIFF, or  "Tag Image File Format", is a raw file format with little or no compression. PNG and JPEG are both compressed formats.
You're going to have to find a way to write PNG & JPEG files or install some SDK plugin to do this.
You can't just change the extension and display a TIF as one of these compressed formats.
Links provided for WIKI references.
Hope that helps.


remote connections and mysql on ubuntu?

Question: I have Ubuntu running in VMWare. I installed mysql 5 server and comment out bind-address and restarted the mysql server. I am now trying to connect to mysql but i cannot. I tried using 1) Code and 2) A gui app from MySql website. Both report it cannot access the server. What do i need to do to get this to connect?
Comment: Are you sure the problem still is that you cannot access the server, or that it won't allow you to login? A MySQL user is not only specified by its username, but also with the ip address or hostname from which it accepts logins.
Answer: A number of things could cause this (firewall, other inbound port blocking problems, VMWare NAT'ed without port forwarding, MySQL not listening on the correct interface / MySQL not running networking, incorrect MySQL grant...)
Things to consider:

Is MySQL running and running with networking (you may need to specify a user/pass for these)?

    mysqladmin --protocol=socket ping                # check if accessible via UNIX socket
    mysqladmin --protocol=tcp ping                   # check if accessible via localhost TCP/IP
    mysqladmin --protocol=tcp --host=ipaddress ping  # check if accessible via external IP (MySQL can be configured to listen on the loopback address only, it can also be configured to *skip-networking* entirely)

Is the machine accessible from other machines? Run nmap -sT -p 22,3306 ipaddress  from another machine, this will give an indication whether the machine is accessible on the SSH/MySQL ports or not.
If the VM is running in NAT networking mode (as opposed to bridged), then you'll need to ensure the correct ports are forwarded to the machine's real IP address, or otherwise use the NAT address (where accessible) for communicating
Is a firewall on the VM, or the VM's host preventing access to port 3306 (the default MySQL port)? Check your firewall rules (iptables -L for iptables).
If you're accessing the MySQL server via DNS, is DNS causing the problem? You can try connecting using the IP address instead of a hostname in this case to eliminate this possibility
If logins are working on the machine, but permission is being denied remote machines, remember that MySQL performs access control using username, password and hostname (with wildcards permitted). You may need to adjust your grant tables.

I hope one/some these help you track down the problem!
Lockie
Comment: Great answer! `mysqladmin --protocol=tcp --host=ipaddress ping  ` failed (i changed ipaddress to the machine actual address). I have commented out the bind-address before posting. Right now I dont see the skip-networking and notice that could be a problem from google yesterday. Here is my current config which was the default + commenting out bind address http://www.pastie.org/742545
Comment: The last line of your config, "!includedir /etc/mysql/conf.d/" looks like a mistake (the exclamation mark). Otherwise the config runs okay on my machine.
Comment: $mysqladmin --protocol=tcp --host=192.168.100.129 ping  --port=3306
mysqladmin: connect to server at '192.168.100.129' failed
error: 'Host 'name-desktop.local' is not allowed to connect to this MySQL server'
Comment: "# Generated by iptables-save v1.3.8 on Mon Dec 14 06:52:22 2009
*filter
:INPUT ACCEPT [1782:1078946]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [1490:81549]
COMMIT
# Completed on Mon Dec 14 06:52:22 2009
"Looks like the port is in the accept range. Weird. I googled and looked. There doesnt *seem* to be a firewall. Maybe i am better off getting hosting from a free service online.
Comment: I tried your answer again on another distro and it help me find the problems perfectly and on a unfamiliar disto (and being inexperienced) i had everything working within the hour!
Answer: You can also do something like "sudo tcpdump port mysql" on the MySql server box and see if you get any packets when trying to connect from the remote client. That will help narrow down which side of the network the issue is on.

remote connections and mysql on ubuntu?


Are there only two irreducible affine singular cubic curves?

Question: It's known that every irreducible projective singular cubic curve in $\mathbb{CP}^2$ is isomorphic (actually projectively equivalent) to either a cuspidal cubic $$y^2z=x^3,$$ or a nodal cubic $$y^2z=x^3+x^2z.$$ If we focus on the affine case, is it still true that every irreducible affine singular cubic curve in $\mathbb{C}^2$ is isomorphic to either $$y^2 = x^3$$ or $$y^2=x^3+x^2?$$ If not, what is a counter-example?
Answer: If you remove some (non-singular) points from the curve $y^2=x^3$, you get a singular cubic which is still affine (it is an open affine subset), yet it is not isomorphic to the original curve. Indeed, any isomorphism would induce an isomorphism between the regular loci of the curves. These loci are just projective lines minus finitely many points, and the isomorphism class determines the number of missing points.
EDIT. This argument is partly relevant because I forgot that the OP asks for affine plane curves. However, one can give a counter-example to the OP's question.
Note that the cubics $y^2=x^3$ and $y^2=x^3+x^2$ have only one point at infinity. Let's try for a singular plane cubic with three points at infinity. Consider the family of plane cubics
$$C_k : x^3+y^3+kxy+1=0.$$
The singular fibers are given by $k \in \{-3,-3\zeta_3, -3\overline{\zeta_3}\}$. For example, when $k=-3$ the (unique) singular point is $(x,y)=(1,1)$ and is a node. The regular locus of $C_{-3}$ is isomorphic to the projective line minus 5 points, hence $C_{-3}$ cannot be isomorphic to the above cubics. I don't know however if $C_{-3}$ (or other singular plane cubic curves) can be isomorphic to open subsets of these two cubics.
EDIT 2. A simpler example is given by Descartes's folium $x^3+y^3=3axy$ for any $a \neq 0$. It has the singular nodal point $(0,0)$ and again 3 points at infinity.
Comment: Is this still a cubic (= locus of zeroes of an irreducible polynomial of degree $3$ in $x, y$)?
Comment: @Francesco Polizzi Hmm you're right, the resulting curve may not be planar, although I have no example of either case.
Comment: This is really a good example! So we are saying a 2-sphere minus 5 points cannot be isomorphic to a 2-sphere minus 1 point only, even topologically.
Comment: Yes this should also be true topologically, thanks to the fundamental group. But I'm not sure of the nodal case, since the neighbourhood of the singular point is the union of two discs glued at one point. Removing the singular point disconnects the two discs, unlike the case of a cusp.
Comment: I was not saying it correctly. Topologically, the projective closure of a nodal cubic is a 2-sphere with 2 points identified (so removing the singular point is like removing 2 points on the 2-sphere), and that of a cuspidal cubic is a 2-sphere. So the regular loci of $y^2=x^3$, $y^2=x^3+x^2$, and $x^3+y^3=3xy$ in the affine open patch $z=1$ are 2-sphere minus 2 ,3, and 5 points respectively. So the three affine cubic curves are distinct topologically, and hence algebraically.
Comment: @YuhangChen Thanks for these precisions. Now it's clear that the curves are distinct topologically even before removing the singular point, because (1) the type of singularity (node or cusp) is determined by the topology near the singular point, and (2) in the nodal case, any homeomorphism must match the nodal points, hence it induces an homeomorphism between the regular loci.
Answer: Take an affine irreducible singular cubic curve  $C$ of degree $3$ in $\mathbb{A}^2$, and embedd $\mathbb{A}^2$ into $\mathbb{P}^2$. The closure is an irreducible curve $\Gamma\subset \mathbb{P}^2$ of degree $3$ with one singular point in $\mathbb{A}^2$, so no singular point on the line $L=\mathbb{P}^2\setminus\mathbb{A}^2$ (by Bézout with the line through the points or by genus formula, a cubic has only one singular point). It is moreover one of your two examples. So the curve $C$ is equal to $\Gamma\setminus L$ for some line $L$ in $\mathbb{P}^2$. If you want to classify $C$ up to affine change of coordinates, you classifiy the pairs of cubics $\Gamma$ and lines $L$ up to change of coordinates. As the group of automorphisms of $\mathbb{P}^2$ preserving a cuspidal curve is of dimension $1$, and the set of lines if of dimension $2$, you get a family of dimension $1$ in this case. For the nodal case, there are only finitely many automorphisms of $\mathbb{P}^2$ preserving the curve, so you get a family of dimension $2$ of examples.
You can then ask for a classification up to isomorphisms. In this case, the isomorphisms between the affine curves are the same as the isomorphisms between the singular curves which map the points at infinity on the points at infinity. This arleady makes a difference between the cases with $3$, $2$ or $1$ point at infinity, but moreover you again can check that the group of automorphisms of the cuspidal cubic is of dimension $2$ (corresponds to the automorphisms of $\mathbb{A}^1$ when removing the point) and of the nodal cubic is $1$ (automorphisms of the complement of the singular point: a torus and an involution). In the first case, you get only finitely many possibilities, but in the second case, you still get infinitely many pairwise non-isomorphic affine nodal cubic curves.


If I install the same module in sites/all/modules vs sites/example.com/modules, which is used?

Question: I assume that example.com would use its own version of said module, but I don't know. I have the same question regarding themes.
Answer: The sites/site.com/modules will be used over anything in sites/all/modules.
There's a really good description of how it works on Acquia:

Site-specific modules and themes
Each site in a multi-site install contains at least a settings.php and
  a /files directory. But each multi-site directory can contain modules
  and themes too - and any modules or themes in those directories will
  only be available to that site.
For example, imagine I have two sites, example.com and example2.com:
/sites/all/modules/contrib contains all of the community contributed modules that I want both sites to share. For example, Views might live there.
/sites/all/modules/custom contains all of my custom modules, written specifically for my Drupal installation.
/sites/example2.com/themes contains any themes you want to only be available on example2.com.
/sites/example2.com/modules contains any modules you want to only be available on example2.com.
When Drupal looks for available themes and modules, it searches in the
  following order:
/modules/
/profiles/
/sites/all/
/sites/[sitename]/
So, when I write my custom theme for example2.com, I can put it into
  the example2.com multi-site directory:
/sites/example2.com/themes/chicken
And the "Chicken" theme will only be available to users of
  example2.com. Users of example2.com will still have access to all of
  the themes in /sites/all and /themes, but example.com won't be able to
  see the "Chicken" theme at all.
Comment: Most excellent! Thanks for that. I read the Drupal docs but not the Acquia ones : )


Are the keycodes of modifier characters independent of keyboard layout and keyboard model?

Question: For example, is the keycode of left control always 37? Where can I find a list of such keycodes?
Comment: Yes, well mostly. There will be other keyboard types. But these are now rare.
Comment: Related question https://askubuntu.com/q/874934/21005
Answer: No - it depends upon the keyboard configuration (ultimately upon hardware).  If you're using the same hardware all the time, this is not an issue.
xterm uses keycodes in the modifyOtherKeys feature.  Some of the background (and examples for several keyboard types) are given in the XTerm – "Other" Modified Keys page.
The tables on that page are generated by modify-keys.pl, a script which imitates xterm's behavior for a given X keyboard configuration.  It gets some of the information from "localectl status", and some from setkbmap (in more or less readable form).  Ultimately that comes from tables which are compiled from other sources, but those utilities were the easiest way to get usable information from the X keyboard configuration.
Checking my memory, I made a script to show the details of the variations in those tables:
#!/bin/sh
for kbd in apple altgr-intl pc105
do
for lang in us gb fr
do
setxkbmap -model $kbd -layout $lang -print | \
        xkbcomp - -C -o - >/tmp/$kbd-$lang.log 2>/dev/null
done
done

The X keycode happens to be the index into the symCache array defined in those source-files, e.g., around here:
#define NUM_SYMBOLS     358
static KeySym   symCache[NUM_SYMBOLS]= {

But the table-size changes with different configurations:
altgr-intl-fr.log:#define NUM_SYMBOLS   347
altgr-intl-gb.log:#define NUM_SYMBOLS   348
altgr-intl-us.log:#define NUM_SYMBOLS   254
apple-fr.log:#define NUM_SYMBOLS        358
apple-gb.log:#define NUM_SYMBOLS        359
apple-us.log:#define NUM_SYMBOLS        265
pc105-fr.log:#define NUM_SYMBOLS        375
pc105-gb.log:#define NUM_SYMBOLS        376
pc105-us.log:#define NUM_SYMBOLS        282

and the left/right control symbols appear at different offsets in some of the tables:
altgr-intl-fr.log:       XK_Control_L,      XK_Super_L,      XK_Shift_R,    XK_Control_R,
altgr-intl-gb.log:       XK_Control_L,      XK_Super_L,      XK_Shift_R,    XK_Control_R,
altgr-intl-us.log:        XK_Num_Lock,      XK_Shift_L,    XK_Control_L,      XK_Super_L,
apple-fr.log:       XK_Control_L,      XK_Super_L,      XK_Shift_R,    XK_Control_R,
apple-gb.log:       XK_Control_L,      XK_Super_L,      XK_Shift_R,    XK_Control_R,
apple-us.log:        XK_Num_Lock,      XK_Shift_L,    XK_Control_L,      XK_Super_L,
pc105-fr.log:       XK_Control_L,            XK_q,            XK_Q,           XK_at,
pc105-gb.log:       XK_Control_L,            XK_a,            XK_A,           XK_ae,
pc105-us.log:        XK_Num_Lock,      XK_Shift_L,    XK_Control_L,      XK_Super_L,

So I'd not expect those keycodes to always be the same values for all keyboard configurations.
The comment about xev mentions a way to see the keycodes for the current configuration.  On mine, the left control is 67 (not 37):
KeyRelease event, serial 34, synthetic NO, window 0xa00001,
    root 0x111, subw 0xa00002, time 51155669, (23,30), root:(43,73),
    state 0x4, keycode 67 (keysym 0xffe3, Control_L), same_screen YES,
    XLookupString gives 0 bytes:
    XFilterEvent returns: False

KeyPress event, serial 34, synthetic NO, window 0xa00001,
    root 0x111, subw 0xa00002, time 51156901, (23,30), root:(43,73),
    state 0x0, keycode 70 (keysym 0xffe4, Control_R), same_screen YES,
    XLookupString gives 0 bytes:
    XmbLookupString gives 0 bytes:
    XFilterEvent returns: False

Comment: I just need the codes for a script that is supposed to detect if a modifier key is pressed from `xinput`'s output. And it would be great if the script would work on other people's computers, too.
Comment: "xinput test" gives some numbers, but those aren't X ***keycodes***.  You might find [this answer](https://unix.stackexchange.com/questions/12510/relationship-of-keyboard-layout-and-xmodmap?rq=1) helpful, though some of it is incorrect...
Comment: Are you sure? It gives the same number as `xev` gives for "keycode".
Comment: sorry - I was looking at the *keysyms* column of a table.  xev is (agreed) giving consistent results for *keycodes*


Condensation on spray foam in basement

Question: I am in the progress of having a home built and we are presently at drywall stage so humidity is fairly high in the house. Our 6' concrete crawl space will be heated. We have two construction heaters and a fan that was placed in the crawl space to dry it up however I'm wondering if it's created a problem with condensation. We have spray foam insulation on the walls with fibreglass bats over top. I pulled a piece of fibreglass off to look at the spray foam and noticed condensation on the foam. Will this dry as the basement drys out or should I get a dehumidifier to assist. Is the heat causing this problem?
Comment: Stock "construction heater" dumps a bunch of moisture into the air as a byproduct of combustion, since they don't have a vent and just dump the exhaust into the space being heated.
Comment: 1.0# of propane becomes CO2 and about 1.3# of water through combustion. You haven't been pumping water into this area, have you?
Comment: These construction heaters are 220v electric not combustible type
Answer: Exhausting the moist air to the outside with a fan should be your first instinct. Only if it's very cold outside and the space is heated will a dehumidifier work better. Even in that case, you should also use a fan or fans to accelerate things by blowing moisture saturated air away from wet surfaces. I suppose that high relative humidity outside could change the calculus, but I'm skeptical.
You can't get the heat from combustion, though. Propane is C3H8. By combining with oxygen in the air (complete combustion implies C3H8 + 5O2 ➔ 3CO2 + 4H2O), it becomes water and carbon dioxide. Assuming 80% combustion efficiency and tracking hydrogen through the combustion process, 1.0# of propane transmogrifies into 1.3# of water:
(0.80)(1.0#)(1000g/2.2#)[(1mol C3H8)/(36g+8g)][(8mol H)/(1mol C3H8)][(1mol H2O)/(2mol H)][(2g+16g)/(1mol H2O)](2.2#/1000g) = 1.3#.
That's not going to dry anything.

Condensation on spray foam in basement


How to answer the question of the challenges of back to work after 4 years out?

Question: We moved to the East Coast almost 4 years ago with my daughter that was 1.5y at that time.  I was working full time before and was really hard with the baby in day care all the time back those days, so I decided to stop working and take care of my family.
Time passed and  I have been in 2 or 3 interviews since then, with any luck. I'm a basic scientist, I have been reading about my field and help with some work as consultant since then.
Now my child is in kindergartden and I'm ready to work again.
But my potential employers keep asking about my confidence to back to work and the possible challenges that I saw on coming back.
I have almost 20 years of experience on bench lab work and I feel like I know how to afford and solve problems and the way to work efficiently and that is something that you never forget.
Comment: I would quote them the Scientific Method, and quite simply imply that there is no challenge.  Brush the question off as though it is by nature answered and otherwise of little importance.    It will give the interviewer the impression that there IS not anything to be overcome, and shows confidence (because they are asking the question to see if you are confidant in your ability)
Comment: Maria, why not say exactly that? "I'm probably a bit out of date on the latest trends in the industry, but I'm sure I can pick those up quickly as needed." That's how I'd describe myself even without a sabbatical...
Comment: Before anyone knee-jerk declares this a duplicate, it's not. Read the question in its entirety as well any question you propose as a dupe. I searched myself and couldn't find any. I just wish I had an answer.
Comment: A new job is always a challenge by itself. I'm just trying to say and make them clear that Im ready for the job, and because my experience that I can afford the challenges more efficiently and faster.
Comment: @Maria The answer I would suggest is: 1. You know and have considered the challenges (be sure that you actually know and can talk BRIEFLY about what they are - e.g. a couple examples); 2. You know exactly what you would do in these situations to ensure that these challenges do not interfere with your productivity (be sure to have 1-2 brief examples for such strategies). I think this should be all you need to effectively address this question.
Comment: @JoeStrazzere Scientific Method *(consisting of systematic observation, measurement, experimentation, and the formulation, testing, and modification of hypotheses.)* breaks the job down into smaller components that are manageable. It's also systematic and has not changed in a very long time.  If you're doing anything in the scientific field (excluding studying evolution) you follow the scientific method. The job itself may have challenges, but they would be approached in exactly the same way, and having had a several year break or not does not change the approach.
Answer: If your return to the workforce is to be a success, you must know the answer to this question yourself. What is going to be difficult? What are you doing about that? There are basically two aspects of it:

working when you have a small child (something they are not allowed to ask you about in the US, but can ask in disguise with a question like this)
returning to a field that may have moved after some time away from it (could be illness, caring for an aging parent, or other reasons)

When it comes to answering, you can give a generic answer or you can name challenges. The problem with naming challenges is that it can bring you into areas that are not ok to discuss in an interview, such as your parental status, and can plant worries in the interviewers mind (sick daycare provider? sick more often because of germs brought home from school?) that were not there before. So I prefer a more generic answer in the interview for the child-related parts, but only after you do a very detailed analysis yourself. For the absence-related parts you can crank up the details and show that you consider things thoroughly.
So think long and hard about before and after school care, your child being ill (and thus unable to go to school), the buses not running, you being ill, days the school gives the kids off that your workplace doesn't (Eg Easter Monday here in Canada, March break, etc) and have a plan for each and every one of them. And summarize to yourself what you have done to stay up to date in your field and all the non obsolete skills and experience you are drawing on. And then when you get the "confidence" question you say something like

I have given this a great deal of thought. I didn't start applying for jobs until I knew that I had my personal situation arranged in a way that made fulltime employment feasible. I have no concerns on the personal front and I'm completely confident. Now while it's true I have been out of the workforce for 4 years, I haven't completely ignored my field. [Elaborate on the reading and the consulting you mention in your question.]  After all, I have almost 20 years of experience in bench lab work, I know how to afford and solve problems and the way to work efficiently. That is something that you never forget and that is never obsolete.

Then smile. You're confident. You've got this.
Comment: I would say analyze and solve problems not afford and solve.
Comment: I was just copying from the question to show that the OP already knows much of this answer.
Answer: Realistically, there will be challenges, and you probably already know them. If you address them head-on, they don't become problems. Some off the top of my head:

juggling sick/school/snow holidays for the kids (what's your backup plan so you can still work?)
re-distributing household chores (significant other? hiring cleaning services?)
adapting to newer technology (MS Office may now be Google Docs)
missing kids while you're at work (they'll be in  school anyway)

Some people do fail coming back to work because they don't plan to re-arrange their personal lives to accommodate the new routine. "Winging-it" might work for some, but a decent plan shows you're not just qualified at the technical aspects of the job, but capable of putting in the time. The employer's initial investment in getting you up to speed is wasted if you decide in 2 months these other aspects of the job aren't good for you.
Comment: Any parent has these challenges. Do you really think that all parents interviewing for jobs should need to explicitly address these things? Maybe just ask them if it's a problem for other parents working there.
Comment: With myself, if anyone I was interviewing also had significant changes with their life that would occur at the same time as starting to work for me, I would ask a gentle question about it. It has the potential to upset their settling into the role, and I would be looking for confirmation that they have thought about it, and will cope. Returning to work when children start school is a change, but it's not a major change. If they didn't have a plan on how to cope if their child was ill for a week, I would follow up by explaining the flexibility we could give them to assist.
Comment: It's certainly a question that comes up for new parents, particularly for high commitment roles (e.g., a VC will raise this issue if a founder has young children). I know I wouldn't personally ask, and separate from that, I've found that parenting teaches amazing time-management skills, but some people will.
Comment: Um, current employees have babies all the time. It's probably even happened at the places the OP is applying to.


Does the EPA have a list of the nation's major environmental issues?

Question: I went to their site and read each of the topics in the "Learn the Issues" tab but, is there a list that the EPA deems to be the most important issues that need to be dealt with?
Comment: I edited your Q and added a link to the "Learn the Issues" resource you mentioned. Please remember to provide links in your Q's.
Comment: My question is specifically for the U.S. By "Does the EPA have a list of the nation's major environmental issues?" "nation's" refers to the United States.
Comment: Shouldn't there be a NAS study on that? http://www.nap.edu is a good starting point.
Answer: The US EPA mandate is quite broad as are the range of environmental issues. The issues aren't really amenable to such a list because it is subjective to decide what is 'major' except in very broad terms. Major could mean greatest risk or it could mean of greatest importance to address soon. Those could be different things, for example, carbon dioxide emissions are high risk but difficult to address whereas an industrial site with leaky chemical drums might have only a local risk but need dealing with right away to contain the problem.
The 'Learn the issues' tab gives the important areas in a general sense; you could look at the EPA organisation chart to see where they are putting their resources.
For the specific case of pollution from old industries, The Comprehensive Environmental Response, Compensation, and Liability Act (CERCLA or Superfund) maintains the National Priorities List (NPL) for sites needing cleanup.


Should I not drive with this huge chipped rim?

Question:
Slid while turning and hit a curb. I am pretty sure I shouldn't drive with this but wanted to get opinions.
Comment: That is an astounding picture. I have seen chipped rims but I have not seen a more catastrophic failure than this magnificent example. Cracked from spoke to spoke. That thing is liable to have multiple internal cracks and might just shatter like a vase. Please do not drive another inch, as everyone suggests.
Comment: Is the wheel itself damaged, or just the hubcap?
Comment: Count your blessings that you were able to make it home on that thing after hitting the curb. Now get that rim replaced for the sake of everyone's safety.
Comment: How fast were you going in that turn?!?
Comment: I'm pretty sure this is just the plastic hubcap that's "chipped"; I don't see any damage to the rim. It's ridiculous that the answers are not addressing this (at least attempting to determine it, or explaining their reasoning for why they agree that the rim is damaged).
Comment: Voted to reopen as this is **not** a question about "tire health" but of safety of a rigid part of the vehicle and whether it needs repair.
Comment: I have voted to reopen this question as it is not a question of tire health, but rather of the rim itself.
Comment: OP, is that a hub cap or the actual rim?
Comment: I can't believe this one was holding air. It looks like a alloy wheel to me, not a plastic cap that are common on steel wheels. Where's the steel rim, if this was a steel wheel? Also, in the crack, it looks like you can see a portion of the tire bead. This is the part that seats along the rim, holding the air. That would not be possible if this was just a cap.
Answer: Do NOT drive this at all.
Change the wheel before driving it again.
That can cause sudden loss of control if the bead shifts.
Comment: Good thing I made right choice.
Comment: 100% agreed. No driving at all. Until changed.
Answer: Well i am not sure this should be answered but in compliance with the site rules, DON'T.
Also if i may ask back isn't your tire deflated?
Comment: "its only flat on the bottom...."
Comment: Amazing that it holds air at all .
Comment: It's a little flat. But not entirely.
Comment: Might be a "run-flat" kind.
Answer: The wheel is done, so you're better off just buying a spare.
You can buy matching OEM wheels online from a variety of web sites, and also through interchange amongst full-service scrap yards.
The wheel is made of aluminum and steel, and recycles nicely. Let the tire shop do it. If the tire is undamaged just have a tire shop transfer it to the new wheel.
Limping: Stay under 20 mph at all times. Expect a blowout!

You can venture around local streets in your neighborhood if you keep it below 20 mph or so.  The general concept is don't drive it hard/"normal".
You can zigzag through side streets to get from your house to a wheel shop, Pick-n-Pull, what have you, again keeping it down to 20 mph.

Venturing out onto arterial roads should be kept to an absolute minimum, because you can't move fast enough to be safe -- a car going a dramatically different speed from everyone else creates a significant hazard to other drivers.   If you have heavy commute hours, exploit them: for instance if I had to cross the Golden Gate Bridge I would do it in the thick of commute hour, where you'd be lucky to go 20 mph.
The freeway is out of the question.
A good way to find off-beat routes is to ask Google maps. One of the rows lets you select public transit routes, bicycle routes, walking routes, etc.  You can browse those to see if they will put you on smaller roads.  Many towns have a network of alternate smaller roads, and they designate them as official bike routes.
What's the deal with going so slow?  Physics.
We're assuming there will be a blowout or wheel breakage, and moving so slow it's safe.
We're relying on one of the laws of physics, about kinetic energy.  You have to spend energy to get your car moving, but once it is moving, it stores energy - it will coast for a distance, and you must use brakes to stop it.  Right?  That is kinetic energy.
The amount of kinetic energy decides how much mangulation will happen in a crash, how much forces will act on the car in a tire blowout, how much dynamic force acts on the wheel when you hit a bump, etc. It's impractical to move the car unless we can keep these forces VERY small.
Here is the formula for kinetic energy.

E = M  V 2

Energy = Mass (car weight) x Velocity (speed) squared.
The squaring of velocity is what makes this possible.  If you go 1/4 the speed, you have 1/16 the kinetic energy.  Cars are designed for blowouts to be manageable by a competent driver at 80 mph.  At 1/16 of that, they're so easy I have confidence anyone can do it.
At the low speed, things happen at proportionately lower speed (1/4 of 80 mph). But the main win is the massively lower kinetic energy, which does some things for us.

It lets the brakes stop in 1/16 the distance- less than the car's length!
A blowout may make the car swerve out of the lane (though I've blown out tires at 80 mph and it didn't do much of that). But where does the energy come from to swerve? The kinetic energy of the car - which we reduced to nothin'.  So the swerve won't be hard or fast; you can easily counteract it with the steering wheel.
The car can't flip over; there's not enough kinetic energy to do that.

Keep in mind that while energy is 1/16 of 80 mph, speed is only 1/4. That means reaction time still matters - it will be 1/4 not 1/16 - so you must be fully attentive.  As a limper, you have one job - to react promptly to the expected problem.
Why not just tow or use the spare tire, if a blowout is so certain? Tell you a secret, a blowout is rather unlikely at 20 mph. But we're gonna plan for the worst and hope for the best.
Comment: This is bad advice. 20 mph is well fast enough to kill a pedestrian on a footpath that you mount when that wheel catastrophically disintegrates. As for the digression into kindergarten physics - if the OP doesn't know that going faster means more energy, he shouldn't be driving a car.
Comment: Rational answer.  I love all the armchair mechanics with the "Don't even look at the car, you'll die instantly" responses.
Comment: @OscarBravo Either you arrived with your mind already set, or I failed to fully convey how much effect the physics have.  I have edited to clarify, including the question of the swerve.  As for "catastrophically disintegrates", *you really do not understand the "kindergarten physics".  What's that say about you lol!*
Answer: Jack it up (chock the wheels) install your spare wheel, Throw away the destroyed hubcap and look up "Wheel Repair" in your local yellow pages.
Answer: Yes, you should drive slowly, (not on the highway) and with the hazard lights on to the nearest wheel and tire shop and replace it.
Just kidding, you'd be safer putting a spare on, but if it holds air you could drive on it in an emergency.
Driving that at speed would be extremely dangerous due to increased risk of a blowout, which could send you into a telephone pole or oncoming traffic, or a pedestrian, roll the car etc.
Comment: I once took my flat car tyre to the auto shop on the back of a bicycle.   Safer than driving, for me and for everyone else on the road.


Show only one page link in content pagination

Question: Im currently using the  wp_link_pages tag to show the pagination links for content that is split inside the Post. Is there a way to show only the next page link and not all page number links or not show next & previous links? I just want to show only one next page link
Comment: are you using the main query or a custom one?
Answer: To show prev/next links rather than numbered pagination you need to set the next_or_number argument to next.
Then if you want to remove the previous links, you can filter the HTML for the links with the wp_link_pages filter.
But, you can be craftier and filter on the wp_link_pages_link hook.
Although it is used in a number of contexts, when it is called for the previous link it passes a value representing the page number of the previous page.  If you check this against the global $pages, you can come up with the right logic to decide whether you are filtering a "previous" link rather than "next" or numbered pagination.
add_filter( 'wp_link_pages_link', 'wpse_235716_kill_previous', 10, 2);

function wpse_235716_kill_previous( $link, $prev ) {

    global $page;

    if ( $prev > 0 && $prev > $page ) {
        return false;
    } else {
        return $link;
    }

}

Comment: your filter doesn't work it does the opposite. It kills the next link instead of previous link


Multiple cross cuts

Question: I make crosses for my ministry to hand out at various events. Up until now I have cut these out individually using a band saw. This is very time consuming. Recently I had the idea of using a dado blade or router table to cut my stock into the shape of a cross when viewed from the end, then "chopping" it into the proper thickness (~1/2") using a chop saw or a table saw. The problem is both have a tendency to want to launch the crosses when the cross cut is made. Can anyone offer a suggestion for holding the crosses after they are cut? I'm thinking I may have to build a custom jig, but I'm not sure how to design it.
Comment: There are some simple ways to do the needed crosscuts here (including just sawing by hand in a mitre box) but I would advise against your proposed method because the crosses will end up being 'short grain' pieces, which like all offcuts from the ends of boards are quite weak and can often be snapped just with finger pressure. Since you have access to a table saw so you can quickly and accurately form dados how about making the crosses up from two pieces, using half-laps? If you take a batch-production approach I imagine you could knock out a couple of dozen in an hour after some practice.
Comment: A sacrificial fence for the chopsaw (even something as simple as a 2x6) would prevent your crosses flying, but listen to Graphus about the short grain problem.
Answer: You could create a jig that is a "negative" of the cross-section of your piece, with a stop to reference the thickness of each cut.  Something like this would probably also help when you're milling the profile as well, since otherwise you'll be running the piece referencing a very thin edge on both the table and the fence.
However, I agree with @graphus's comment that this is generally not a good idea since it will result in your finished piece being entirely short-grain.  The workflow he suggested would be much better.  To expand on it:

Mill a bunch of square stock
Cut an equal number of pieces to length for the vertical and horizontal pieces
Set up a dado stack to the same width as your stock
Set a stop-block on a miter gauge or crosscut sled to locate the dado in the center of the horizontal pieces.  Set the height to be half the thickness of the stock.  Make sure you have a "zero clearance" surface both under and behind the workpiece to avoid tearout.
Cut a dado in all of the pieces
Glue and clamp them together

Multiple cross cuts


Premium SMS and IVR payments methods in iOS Apps

Question: Actually I'm developing an iOS application for specific mobile operator,
The app will be free , and some content need to be paid so the operator
need users to pay via Premium SMS or IVR (interactive voice replay),
But after make some search i found that Apple maybe will reject the app.
because the need all payment being done via there system i.e via in-app purchase
or paid Model .
What is the ways to solve this problem , and How can i achieve this (Premium SMS ,paid IVR) ?
Comment: I cant get your question clearly.. are you trying to send SMS from mobile i.e iPhone to other users am I right?? if that is the case the cost of the SMS will be determined by the service provider.  Correct me if I am wrong.
Comment: @DilipRajkumar No , my question is : i want to make a free application and some of his content need to buy via operator (not via in-app purchase) , the operation of buying this content by sending an SMS called premium SMS (to short number)and this SMS will cost the user more that the normal SMS , after that i can know who payed to the operator (who send the SMS) via service that provided from operator so i let this user who paid to view the content because he paid for this data (the cost of data is the amount of money he paid for SMS OR how much he paid cost for the SMS) did you got it ?
Comment: Ohh I got it..  If you are ok to leave the application while sending the SMS.. you can solve this problem like using the iPhone sms (MFMessageComposeViewController) by giving the message and number see this link http://blog.mugunthkumar.com/coding/iphone-tutorial-how-to-send-in-app-sms/ .. hope it helps..
Comment: @DilipRajkumar thanks for Replay but it seems you need more clarification , the problem not in technical issues, the problem in model i.e i expect apple will not allow to this model be on store (to pay vis sms) they aim to make payment via in-app purchase
so if i develop this app with this concept dose apple reject my app ?
Comment: I hope your app should not get rejected. But I am not sure.  I know my answer is not that satisfactory sorry for that..  One lame solution is you can submit to app sore and check whether they will reject or not.  YOu will not get any loss right..:)
Answer: The bad news is: you can't ship an app that is solely based on paid sms from within the app. As this article on arstechnica states:
Content providers can continue to offer outside subscriptions that are accessible via an iOS app, so long as no external links to outside purchasing mechanisms are built into the app. If subscribers can pay for content within the app, it must use in-app purchasing APIs, though content providers are now free to set whatever price they like.
If you really want to deploy paid text messages, you could integrate in-app-purchase with a high price. Additionally you offer paid text messages at a lower price(Users send a text message via their ordinary message app to a number you tell them via your web page or ad or any other way). So users will tend take advantage of the lower price and will send text messages. An obstacle will be, that Apple won't allow a reference to the cheaper payment method from within the app. So it depends, on how you inform your users about your app and payment methods.
Comment: This is not 100% true. It depends on the product you want to cell. If it is digital content unlocked inside the app, you have to use in-app purchase. If it is a "real life" product or a service outside the app store, you can use your own payment method. This may be helpful http://stackoverflow.com/questions/6481517/accept-payment-on-ios-apps


Is there a way to disable the save states on PPSSPP menu?

Question: I want to hide or disable the save states on the PPSSPP pause menu since I don't use it so I'd rather have the interface clean of it. I've checked out every section in the settings and can't seem to find it. That or I'm just blind.
Answer: Based on what I can tell from a quick look at the code for the pause screen, specifically the GamePauseScreen::CreateViews() function, it doesn't seem like there's a conditional check that would remove the save states feature.
That said, if you're feeling adventurous, you could try removing the entry from the pause screen and recompile.  That may be more trouble than you're willing to go through, though :)
Comment: Alright thanks! I have to consider first if I'm willing to go through setting up the source and compiling


YouTube Data API v3 Queries per day

Question: Good day, I need your help, I use in one of my application YouTube data API v3, but I every day there is an excess of the quota limit (Queries per day = 1 000 000). Please tell me whether it is possible to increase the quota, even for money? And it turns out that the application almost half a day does not work.
enter image description here
Comment: Hi,I'm face the same issue,my app can't functions with the current quota, do you have any solution? did u get your extension ?
Answer: Yes there is a way to increase your quota but it's not easy. You have to go about filling up this form
It will ask you a bunch of questions and information to reach you and then they will decide. It starts with this

This Application will ask you detailed questions about:
(i) your business,  (ii) your use of each YouTube API (current and
  proposed use, as applicable), and  (iii) each of your website or
  software application that uses or will use YouTube API(s) (each an
  "API Client").
This application also requires you to submit screenshots and design
  documents relating to your API Client(s) and your use of YouTube
  API(s). If you do not have these ready, please apply once these are
  available.
We will strive to respond to your application as soon as possible,
  provided that, all required supporting materials are submitted and
  sufficient, and all questions are thoroughly answered.
Note: Please do not apply for more quota unless you are actually close
  to hitting your current limit.

Good luck with this
Comment: Ohh how hard it is(. Is it possible to connect additional quotas for a fee?
Comment: It's hard in the sense that you have to fill the form and then they determine. I haven't been through the process myself, so I don't know fully

YouTube Data API v3 Queries per day


Logistic Binary or Poisson?

Question: My outcome had a prevalence of 51% (yes, disease). I need to know which is the best regression to use Binary or Poisson Logistics in the identification of the associated factors. All my data is categorical (male, female / yes, not / younger, older) ....
What are the implications on my results of using one regression instead of another?
Comment: @SmallChess My best guess is actually the opposite - you can use Poisson regression to approximate a binomial distribution.
Comment: I never heard of "Poisson Logistics"? Any reference? Fitting Poisson with logistic function?
Answer: What the "best" regression to use is will depend on many factors. And, as @SmallChess has noted, I've never heard of "Poisson Logistics" despite doing an awful lot of disease related research, so I'm going to guess and give you three options for what I think you mean:

Logistic Regression: Conventionally, in clinical and epidemiological studies, logistic regression is used to study case-control data with rare outcomes, as in that case the odds ratio obtained from logistic regression approximate the relative risk you would obtain from a cohort study. You don't specify if your data is a case-control study or not. If it is, and you use logistic regression, in your case the odds ratio does not approximate the relative risk.
Binomial Regression: Binomial regression can be used in a cohort of patients with binary outcomes to direct estimate the relative risk. If you can use binomial regression, it's good to try it. Unfortunately, unlike logistic regression, binomial regression models are often sometimes poorly behaved, and have trouble converging.
Approximation of a Binomial model using Poisson regression: Poisson regression with a robust variance estimate can be used to approximate what you'd get from a binomial regression model, and is likely better behaved. See Zou G. A modified Poisson regression approach to prospective studies with binary data. Am J Epidemiol. 2004;159(7):702–706. for a theoretical treatment of the topic, and Rivers, C., M.S. Majumder and E.T. Lofgren. Risks of Death and Severe Disease in Patients With Middle East Respiratory Syndrome Coronavirus, 2012–2015. Am J Epidemiol. 2016;184(6): 460-4. for an example of using this in practice.
Comment: @AndréAraújo The reviewer is suggesting #3 in my list, which is appropriate for cross-sectional data.
Comment: @arielhasidim Yes, that's correct. The "log" link function is what I'm referring to.
Comment: Sorry for the language, I'm not native.
In a journal submission, the reviewer suggested that I use Poisson regression instead of binary logistical because of the high prevalence found (51%).
I do not know to what extent this is really important given that the study design is cross-sectional. Is the reviewer correct?
Comment: @DanChaltiel Your link leads to a login screen.
Comment: @DanChaltiel The Zou paper is mentioned as #3 in my answer...
Comment: @Fomite For the sake of clarity, when you mentioned "2. Binomial Regression:" you meant log-binomial? If I understand correctly, logistic regression is a binomial distribution with a "logit" link function, but to get RR instead of OR, I should use the "log" link function. Is this right? This is the most lucid explanation that led me to this conclusion: https://stats.stackexchange.com/a/581688/323174
Answer: Your reviewer suggested the right thing which is to choose Poisson regression. And I disagree with Formite in that the reasoning to choose Poisson regression over logistic is not to approximate binomial model. This is a very poor justification. The only reason to choose Poisson regression is because you are doing a large cross-sectional study, which means the total sample including all cases and controls is a random variable following Poisson distribution, as opposed to the binomial (number of either exposed or diseased fixed) or multinomial model (total sample size fixed).
Whether to choose logistic or Poisson regression depends on your sampling scheme. Logistic regression enjoys certain attractive properties such as the unbiasedness of the regression coefficient estimators under different sampling scheme including case-control sampling. That said, you could still use a logistic regression in your case, however, the resulting estimator will yield a higher variance than the one from a Poisson regression so why to use it? Additionally, odds ratio in logistic regression only gives information about the odds but not the risk or rate for each exposure group (unless the disease is rare) and in some research, the risk/rate for each exposure can be of interests.
However, I'm not sure why your reviewer suggested Poisson regression based on the crude prevalence of the disease. This does not sound conventional and perhaps, you could as him/her why? Does this mean if the disease prevalence is low, you are to use logistic regression? This is a quite strange justification. Please keep me posted if you find out.

Logistic Binary or Poisson?


What counts as an academic affiliation for arXiv?

Question: Is it just being enrolled at a university with a recognized school email address?
Answer: arXiv states (step 2 of registration):

Claimed affiliation should be current in the conventional sense: e.g., physical presence, funding, email address, mention on institutional web pages, etc.

arXiv's notion of conventional sense seems peculiar. They omit perhaps the most common conventional notion of affiliation: employee. Other common notions -- e.g., those involving some written agreement -- are also omitted. (Perhaps arXiv want ties beyond employment or perhaps this was an oversight.)
Comment: @TejasRao It's unclear what _funding_ means in this instance. It could mean salary, but funding is a peculiar choice of synonym, so perhaps it means grant associated with the affiliation. Given that many researchers -- including most PhD students -- don't have funding, you can assume that it isn't required. More generally, you don't need to satisfy all of those criterion. Thus, a part-time researcher without physical presence, but with an email address and mention on institutional web pages, would be considered as affiliation.
Comment: My question is whether you need all of those qualifications. For example, if I have an email, a physical presence, and a mention on the institutional web page, but no funding, is this acceptable? Does the statement imply needing all of the qualifications, or some?


android 2.2 emulator -- Fails to load Wi-Fi driver

Question: I can't connect my emulator -- Target: Android 2.2 -- to connect to my home wifi that I know works ok. (Had also been able to do that a couple of months ago.) The emulator displays "(No Service)" on top right of start screen. LogCat shows:

10-26 05:53:16.531: INFO/WifiService(60): WifiService starting up with Wi-Fi disabled
  ...
  10-26 05:57:44.963: ERROR/WifiService(60): Failed to load Wi-Fi driver.

Have tried running Dev Tools > Connectivity > Enable Wifi, but only see another "Failed to load Wi-Fi driver entry in LogCat.
But emulator -- Target: GoogleAPIs on Platform 2.1-update1 -- displays "Android" on top right, and seems to connect to the same home wifi fine. Eclipse and emulator run on my Windows XP laptop.
Appreciate any insights...
CL
Answer: The emulator will do networking, but the wifi doesn't load a driver due to not being able to access the host hardware.
You need to test wifi code natively.
Answer: I also encounter such problem when trying to perform WiFi scanning from the emulator. However when i tried running the program on my physical device, no such problem encountered.


Real world usage of DelayQueue

Question: What would be a real world usage of DelayQueue, what common problem it was designed to solve?
Answer: This class is perfect for a thread that wants to process multiple delayed events their proper order.
Suppose, for example, you have a display with 100 flashing lights, and all the lights flash at different unrelated rates.  You could have a thread for each light, or you could have one thread coordinate all of them using this class.  It would work something like this:

have a Light class with a flash rate
create an implementation of the Delayed interface that points to the light, say LightFlash
create your DelayQueue and add a new LightFlash for each light, with the delay set appropriate for the light's flash rate
loop:

get an event with DelayQueue::take().
toggle the light on/off
add a new event to the queue for the light's next flash with DelayQueue::put(E).

DelayQueue takes care of getting the next event to process.
Two real-world examples I can think of:

A (non-multithreaded) server that needs to perform certain timed actions, e.g. connection ping on each connection.
An implementation of a javascript-enabled browser, that needs to deal with the arbitrary number of timed events created with setInterval() and setTimeout().  Oh, and animated GIFs.

DelayQueue is probably implemented as a priority queue, which is generally best implemented as a heap.
Answer: I recently used a delay queue for rate limiting.
For a limit of X events per second, place each event into a delay queue with a 1 second delay.
If there are X events on the delayQueue, take() from the queue (which blocks until at least 1 expires). That way you allow a short term burst, without exceeding any long-term limits.
Answer: the main usage would be task timers like the for Timer classes
if one could make the delay independant from the system clock (which I beleive you can, not sure though) you can use it for game events like "after 5 ticks move to X" (otherwise clock jitter wold make this unreliable)
Answer: Note that the delays are associated with the elements that go on the queue rather than the queue itself.  Some objects that go into the queue could have a delay of zero, whilst some can have a much longer delay:
http://docs.oracle.com/javase/6/docs/api/java/util/concurrent/Delayed.html
With this in mind, I can think of a few use cases - though they would probably be fragile and a bit of a code smell with regards to your messaging flow.  I'd use alternatives to all of them except in specific situations:
1) Control flow - we know that an order takes 60 seconds to process, so don't read the next order off of the queue until the object has been there for at least 60 seconds.
2) Message flow - A highly asynchronous system where we send off requests to 2 or 3 external services and then release the next task to process the order N seconds later once we know the first batch of jobs will at least have had a chance of completing.
3) Message batching - maybe orders of a certain type are bursty, so lets not process orders received in the last N seconds so we can see if similar orders come in shortly after that can be processed as a batch on the next run.
4) Message priorities - different messages or different customers could get a slightly higher quality of service with a lower or zero delay.
Answer: In some cases, objects that you place on a queue should be on that queue for a certain amount of time before they are ready to be dequeued. This is where you use the java.util.concurrent.DelayQueue class, which implements the BlockingQueue interface. The DelayQueue requires that queue objects be resident on the queue for a specified amount of time.
For real world usage example see Minding the Queue article at devx site

...The real world example that I thought of to illustrate this (which might make you hungry) involves muffins. Well, Muffin objects (as we are talking Java—no coffee pun intended). Suppose you have a DelayQueue upon which you place Muffin objects... The getDelay method, in essence, states how much time is left for the object to be kept in the DelayQueue. When the number returned by this method becomes zero or less than zero, the object is ready (or in this example, baked) and allowed to be dequeued...
Since you don't really want to eat a Muffin that's not fully cooked, place the Muffin on the DelayQueue for the recommended cooking time...
Comment: I understand what it does, but not what common problem it was designed to resolve, I'm looking for the use case(s)

Real world usage of DelayQueue


Zero power after new Gfci installed

Question: While using hairdryer power went out. Nothing was tripped in the breaker panel. The gfci switch would not reset. Bought new gfci switch and replaced it for old one. Still no power in master bathroom, hall bath outlet does not work either as well as a few other outlets in different rooms. Is this possibly a burnt wire? Electrician came in and tested breaker box and all light switches and outlets in the home. All was fine except the original issue which still read at 0. He was unable to diagnose the problem. He suggest running new wire from gfci outlet to the panel..... is this safe if it is a faulty or burnt wire? Since the wire was not found.. just worried is all I don't need a bigger problem on top of what I already have. Any advice???
Answer: I would expect this to be a wiring problem, but there is a 99% chance the problem is at one of the ends of wires, i.e. Where they connect to a device like an outlet, switch or splice.
Code requires that all junction points be accessible in junction boxes.  Almost all junction boxes are behind switches, outlets, lamps, or other points of use.
So I would shut off the breaker and note what things have lost power.  It is likely a wire connection problem at one of them.
It almost has to be at the last one which is working or the first one that failed, but that depends on the idea of them being in a "string" one to the next to the next, and it is often difficult to guess where those are.
The #1 type of wire connection problem is called a "backstab".  We have a lot of Q&A about those.
Comment: Unfortunately nothing seems to be wired in a line. Every outlet has been replaced. Every light switch has been checked. The breaker box isn't labeled clearly and is incorrect. The master bath outlet is where the problem started and jumps to the master closet light down to the closet outlet. The jumps to the neighboring kitchen where only 1 outlet affected on the wall is not working which is for the gas stove. The kitchen light above the stove and island were affected as well.
Comment: Then skips over joined dining room as well as next room which is laundry room and power out in hall bathroom outlet but the light and exhaust work. the outlet on outside of home is not working (which we've also replaced) if it helps it's a double mobile home. 1991. All started 4 am nobody awake but me and power went out after 3 min using blow dryer. The lights dimmed slightly while using the dryer then power went out. Short of taking down walls/ or chilling how can I find the wire that is bad/faulty? Believe the wire leads up into ceiling from the master bathroom outlet which is a gfci outlet

Zero power after new Gfci installed


Gas line inside of cabinet

Question: I'm moving into a new apartment in a few days and I just noticed the gas stove has the gas line running through the side of the cabinet going inside of the cabinet. It's just hanging there. Is that safe? It doesn't look right to me. I hope that picture is good enough that I sent. As you can see it has the knob on top and it has the flexible line on one side and it's on the bottom cabinet right next to the stove where my kids can get into it. You can't even install the shelf in the middle because the gas line is in the way. I'm worried about canned goods, pots and pans moving it around
Comment: Most plumbing codes and building codes require support (for example a clamp/strap) for horizontal pipe lines every 3 feet for pipe in 1/2"-1" diameters, and every 4 feet for pipe with diameters greater than 1". Support spacing should be in accordance with applicable plumbing and building codes. Obviously building codes may vary between countries/continents..
Comment: Hi thank you very much for answer that definitely makes sense because it's just hanging there and it doesn't look right I'm going to try and call somebody this morning just waiting for places to open thank you
Answer: Others will be along shortly to say if that is legal or not.  If it's not legal your landlord will have to fix it.
It looks very sketchy.  At the absolute minimum, I would put some sort of strap in place to hold the pipe up.
There's no reason you couldn't put a shelf in with a cutout to allow the flexible pipe to pass through.  (If you make the cutout big enough, you can slide the shelf in without taking the pipe out.)
Once you have a shelf in, you could probably fasten a bit of wood in place between the shelf and the top of cupboard.  If the piece had a cutout in it, it would then secure the pipe.
As to children, you will have to teach them they must not disturb the pipe, and this prohibition is in the "do not run into the road because it may kill you" class rather than the "do not hit your mother's leg with a wooden brick because it will vex her" class.
Comment: +1 for "vex your mother". The rest is good, too.
Comment: I have to admit I stole "because it will vex her" ("him" in the original) from Nick Maclaren (nmm1) in uk.d-i-y.  He was the sort of guy that would never change his opinion just because everyone agreed with him - but he would use it as a warning flag that he should revisit his assumptions.
Answer: It's safe in the same sense that a bear is safe; don't disturb it and nobody will get hurt.
I would consider that cabinet off-limits to your children; don't store anything in there which they would need. Keep a lock on it so that your kids don't cause a gas leak.
If you must store stuff in there then just don't bump the gas line too often.

If on move-in day a big pot happened to bump the yellow line hard enough to cause a gas leak then turn that valve to the off position, leave the building, and call the gas company (not landlord) about a gas leak in your kitchen.
This will cause them to come out and inspect everything. Hopefully they force the landlord to properly run a gas line for the stove instead of this nonsense.
Comment: I don't think you need to wait for a gas leak to ask the gas company to come and inspect it.
Comment: Thank you for your answer unfortunately the cabinet space is very limited here and with four children I definitely need the space
Comment: However I do like your idea about oops accidentally bump the line
Comment: @CindyKahao Well, just make sure that cabinet is only accessible to you. When the inevitable gas leak happens just make sure there are no ignition sources present, avoid turning on or off any lights, and simply leave the building and call the gas company.
Comment: "come out and inspect everything" actually the first thing they would do is lock the meter and tell the landlord to fix the problem.
Answer: UCC code related gaslines for appliances can be found in G24188.8.131.52 (4188.8.131.52) Prohibited Locations and Penetrations.
G24184.108.40.206 states that a value needs to be installed ahead of semi-rigid connector, which is the case. The connection is serviceable (not buried), which is good. Rigid piping material was used in passing through the floor/wall, which is good.
Net-net, this looks fine. It's common for a cooktop's gas line to run through cabinetry, which then connects to a flex line and regulator with-in the cabinet.

Gas line inside of cabinet


Node.js API request loop without a memory overload

Question: This might seem strange but I'm trying to refresh an API as many times as possible until a response.data value reaches a certain number. Here's my code below
const axios = require('axios');
const api = require('./api.json');
const infinity = 0;

let url = 'http://api.site.com/api.php?i=${api[item].appid}';

function api_call(item){
  axios.get(url)
    .then(response => {
      let id = response.data.id;
      if (id > 10){
        return true;
      }else{
        return false;
      }
    })
    .catch(error => {
      console.log(error);
    });
  }

  function loop(variable) {
    while (infinity < 1) {
      if (api_call(variable) > true) {
        break;
        console.log('Found');
      }
      console.log('-');
    }
  }

This might seem strange, but obviously, I've modified it although this code would still achieve a similar goal to what I'm trying to accomplish with my code. Basically, it monitors an API until a value change triggers an action. Possibly I'm doing something wrong but when I run my version of this code (only changes are the API and value names) I start using massive amounts of Memory to the point that the program stops and gives me this error
<--- Last few GCs --->

[11524:000001E5724778C0]    93390 ms: Mark-sweep 1395.2 (1426.2) -> 1394.5 (1425.7) MB, 629.4 / 0.0 ms  (average mu = 0.139, current mu = 0.053) allocation failure scavenge might not succeed
[11524:000001E5724778C0]    94039 ms: Mark-sweep 1395.4 (1425.7) -> 1394.8 (1426.2) MB, 638.3 / 0.0 ms  (average mu = 0.079, current mu = 0.016) allocation failure scavenge might not succeed

<--- JS stacktrace --->

along with more information (if that's required I can edit the post and include it), I believe this is due to how I'm collecting the data, possibly there's some procedure I'm forgetting about I'm not so sure and can't find any similar topics regarding this. Thanks in advance for any help. If more information's required just ask I'll add more.
Answer: I had a little play around and this is what I ended up getting to work.
     const axios = require('axios');
     const api = require('./api.json');
     const infinity = 0;

    function api_call(item) {
      let url = `http://api.site.com/api.php?i=${api[item].appid}`;
        axios.get(url)
    .then(response => {
      let id = response.data.id;
      if (id > 10){
        return true;
      }else{
        return false;
      }
    })
    .catch(error => {
      console.log(error);
    });
  }

    async function checkAPI(variable) {
      const res = await api_call()

      if (res) {
        //success
      } else {
        //Fail
      }
    }

    checkAPI();


Where is the folder that Termux defaults to?

Question: The Termux app is a terminal emulator. If I create a file or a folder there, and then use another file explorer app to browse my device, where can I find these files?
Comment: `/data/data/com.termux/files/home `  ??
Comment: If you're looking for other folders, they're probably in `/storage/emulated/0`. For example `/storage/emulated/0/Download` (no "s") for your downloads or `/storage/emulated/0/DCIM` for your images.
Comment: @beeshyams that is what I got from the pwd command, but is it mounted? I didn't think apps could get access to the root directory, and terminal would have to read it to find out its pos. I assumed that terms mounted the `data` folder somewhere and cannot see past the mount.
Comment: I was right. `data` is mounted inside `Android` folder, accessible from inside the file explorer..
Answer: You don't need to root your device. All you need to do is run the following command on a non-rooted (or rooted) device to allow termux to access your existing directories, particularly /storage/emulated/0:
termux-setup-storage

this creates a new directory in termux, ~/storage, which contains simlinks to /storage/emulated/0 and can be accessed by a standard gui file manager.
You will need to grant file access to termux when prompted after you run the command.
See here.
Comment: This worked!  Though I'll just point out to anyone who didn't pick up on it, that it's not the **~/storage** directory itself that is `/storage/emulated/0`, but that location is rather the symlink **~/storage/shared**.  Hence putting things into `~/storage` directory wouldn't help you access the files.
Comment: Where can I access that file in USB mode? I need to edit the extra key config file. I don't have ctrl key now, can't do much via termux
Comment: This worked for me also after I ran `pkg install termux-am` as mentioned from this [issue](https://github.com/termux/termux-app/issues/3647#issuecomment-1763556222). This [comment](https://github.com/termux/termux-app/issues/3647#issuecomment-1868384046) also mentions another install that I believed I installed once too that has helped with this issue as well
Answer: The default directory is: /data/data/com.termux/files/home.
Since Termux supports bash commands, user can run pwd to print current working directory.
Note: pwd is an acronym of print working directory.

Reference: Unix.SE - How to get current working directory?
Comment: Thanks... But my data directory is empty. My phone is not rooted... Does that matter?
Comment: @Maxcot Unfortunately, yes. The `/data/` folder is only accessible to all if the phone is rooted. By default, only Termux can write & read that folder.
Comment: @Maxcot you might want to copy (or move, but becareful) them to `/sdcard` if you want. Refer to [this question on SO](http://stackoverflow.com/questions/3643848/copy-files-from-one-directory-into-an-existing-directory)
Comment: [Termux help](https://termux.com/storage.html) may provide a way out ( not tried by me)
Comment: What I don't understand is why I have access to the folders through termux, but not through any other app like ES File Explorer. It's like the permissions are dependant on the app, not the user.
Comment: @Maxcot Sorry for late reply. Yes, it's because each running app is sandboxed for security reason so that other apps cannot read/write other apps' data directly.
Answer: Provided that you don't want to root your phone, it is possible to change permission for Termux (Settings->Applications->Termux->Permissions) and enable the Storage permission.
This way you are granted access to phone and sdcard storage and you can use it as superuser (mv, ls and other commands work as intended) in the application.
So, you can move or copy the files you need into internal storage.
Comment: You may also need to run `termux-setup-storage` in Termux to gain access to the SD Card or Internal Storage
Answer: You can query the $HOME variable to find the "default folder" regardless of the terminal app you're using:
$ echo $HOME
/data/data/com.termux/files/home

Answer: You can access the files inside the termux folder by simply doing this. (Without using any third-party app/rooting your device)
Step 1: Go to Downloads on your Device

Step 2: Go to the Appbar

Step 3: Scroll down till you find Termux

Step 4: Click on Termux and you can see your files
Answer: Termux has its default directory that's inaccessible to newbies. To verify this, on the CLI, type
$ pwd

and data/data/com.termux/files/home should appear.
To be able to manipulate your Android directory from Termux, on your Android device, go to Settings - Apps - Termux - Permissions - tap "Storage" on.
Now on the CLI, in Termux, type
$ cd /storage/emulated/0
$ pwd

and /storage/emulated/0 should appear.
You can as well create a new file in your local storage,  type
$ echo hello world > MyFirstTermuxFile.txt

That's it. You can now play with your local device storage.
Answer: You can touch it on data/data/com.termux/files/home. That's the default main directory of Termux.
It's impossible to find the file that you've created on Termux main directory as I mentioned above on your phone because it's not rooted on any device.
It works as sort of a server. By thereon data/data/com.texmux/files/home, which is the default main directory of Termux, you can already browse files, create files, manipulating them the same sort you're using your file manager
Answer: You can view it easily with Material file manager.
https://www.learntermux.tech/2020/10/Termux-File-Manager.html
Here is a guide I found useful to me.
Comment: Hi, whilst this may theoretically answer the question, [it would be preferable](//meta.stackoverflow.com/q/8259) to include the essential parts of the answer here, and provide the link for reference. Consider [edit]ing to summarize the content and/or expand the answer.
Comment: While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference.  Link-only answers can become invalid if the linked page changes. - [From Review](/review/late-answers/250757)


Prometheus Alertamanger - how to silence all alerts for a given period during a maintenance?

Question: A work scenario that I can't cover currently is that I want to set a maintenance mode, meaning all alerts received from Prometheus to be ignored, I want to be able to set it through the UI for a given period until maintenance finish. One way to do it is manually to start covering each alert which in Prometheus-operator scenario is not sane, or I would lose a couple of hours. I can change config from secret to route all to null, but that is not practical as it requires multiple actions and is not good for on time or other user usage.
So I tried to use regex for key and value. Both set to .* .* regex. On preview I get all alerts covered, but when I click Create I get "Bad Request"? I couldn't find examples in internet and on official page which surprised me quite a lot.
Answer: With alertmanager 0.22 (perhaps even earlier?) the solution using regex is a bit less obvious as there is no longer any checkbox to tick for using a regex.
Instead, you must use Name="Value" for an equality check and Name=~"RegEx.*" if you want to use a regular expression. So you must use the =~ operator.
Answer: What about Name = "prometheus", Value = ".*". That is something that worked for me.
An alternative can be Name = "severity", Value = ".*" also.
Comment: thank you, your answer made me realize I didn't test key alertname with value .*, which works as well as the options you have covered, thanks a lot. It looks like request with any key is not acceptable to the api.
Answer: If it's the only selector alertmanager (0.24) doesn't allow it to match an empty string.
So use prometheus=~".+" or severity=~".+" instead of prometheus=~".*", otherwise you get the error "silence invalid: at least one matcher must not match the empty string" from alertmanager.
Comment: In 2023 I am using severity=~".+" based on this answer.


Restrictions in windows phone 8.1 vs. desktop windows 8.1

Question: What kind of restrictions exist in windows phone 8.1 compared to the desktop OS, pertaining to execution of software? I've heard, for instance, that it's a hassle to run selfmade software.
And, does everything have to be an "app", or would it run software which are .NET based (e.g. WinForms program), compiled with target "Any CPU"?
Answer: Windows Phone's only run apps that have been compiled either specifically for the phone (using a variant of Silverlight), or newer Universal apps that can also run on windows 8.1 devices.
Microsoft encourages people to write apps of their own, and there are a number of routes into this, with App Studio, and Visual Studio Express being available free of charge.
Comment: Ah, so it all has to be "apps". Never heard of Universal apps before - good pointer.
Answer: "Tablet" Windows (RT) and Windows Phone are more closely related to each other than either to desktop Windows. Neither will run programs compiled for desktop Windows as the target architectures are different (x86 vs ARM).
Comment: I was talking about win 8.1 when referring to tablet (mine has regular win 8.1), maybe it was confusing. Well, question changed now anyway.
Answer:
Restrictions in windows phone 8.1 vs. desktop windows 8.1

The best discussion I have seen related to restrictions and security architecture is Alan Meesus' Windows Phone: Security Deep Dive on Channel 9.
It covers a number of topics, from trusted boot to sandboxes to update policies. Platform architectures, like x86 vs ARM, and languages, like C++ vs C#, don't really don't matter much because the security architecture is consistent across the mobile platforms.

And, does everything have to be an "app", or would it run software which are .NET based (e.g. WinForms program), compiled with target "Any CPU"?

No. I had to port OpenSSL and Crypto++ to Windows RT and Windows Phone for a couple of projects. OpenSSL is C and Crypto++ is C++. (It was painful in some places, like Windows RT, because of the anemic APIs).


Does the block effort matter when mining in a pool? How does it impact earnings?

Question: I've been using two or three pools so far. One of them always seems to need higher effort to find a block. Does that impact me personally in any way.
I've seen one go 600% and it took ages to get it. Did I lose time on it?
How does a 10% effort block change things then?
Answer: The effort is just an educated guess based on the total pool hashrate.
At X Hashes/s, a block should be found in Y time.
I basically ignore it, its it a guess and not factual.