Arduino remove power if battery voltage is too low

Question: I want to power my Arduino using a Lithium-Ion battery. When the battery is below 3.0V, the power to the Arduino should be disconnected, and when it rises high enough again is should be reconnected again. The problem is I don't know how to do that.
I thought about using a transistor that connects in series with one of the battery power lines, and let the Arduino check the voltage and if needed disconnect the transistor. The problem is, how to power it up again?
Also if the Arduino provides power to enable the transistor, how should it get power to do that in the first place? Is there any better way to do this?
The batteries get charged by a solar panel btw
Answer: You are correct - you can't use the Arduino to do it. You'll need to make a separate voltage monitor/control circuit which does nothing but watch the battery. In principle, something like

simulate this circuit – Schematic created using CircuitLab
will work.
For this circuit, CMP1 is either a comparator or a rail-to-rail op amp which can operate at low voltages. D1 is either a zener or shunt regulator which gives a voltage of less than 3 volts (2.5 is common enough). M1 is a PMOS MOSFET with a low gate voltage requirement (well under 3 volts, and less than 2 would be better) as well as a low enough ON-resistance ($V_RDS(ON)$) to avoid much voltage drop at the Arduino. R4 is important to establish hysteresis - otherwise when the Arduino is turned off, with no load the battery voltage will rise, turning the Arduino back on, dropping the battery voltage and turning the Arduino off, etc.
The biggest problem with this setup is that it will constantly drain the battery, with the voltage reference, R1/D1 being the worst offender. But there is really not much you can do about it.
Comment: You could use LM285 for D1 or similar which consumes ~10-20uA.
Answer: Protection circuits are available to do what you want without using the Arduino at all. If you are powering your project from a single 18650 Li-Ion cell, e.g., just search ebay for "18650 Protection PCB 1S", and you'll find lots of choices for less than $1.
(Some 18650 cells are a little longer and include a protection board - these are sold as "protected")
The protection boards are fairly self explanatory and typically provide overcurrent and over/under voltage protection.
Connect the cell to the battery pads, typically labelled "B+/B-", and use the power/charge/discharge pads (P+/P-) to connect lithium power to your project. The board will shut off current to your project when the cell voltage falls below the cut-off threshold, typically around 3.0 V, but check the specs on the board you use.  The specs will also tell you the voltage at which the board will recover from the undervoltage condition and allow power to be supplied from the cell again. The solar panels can charge the cell through the P+/P- pads as well, and will not overcharge the cell.
If you are not using 18650 cells, find an appropriate protection board based on your maximum current demands. I'm assuming you are using a single 3.7V cell, or "1S" configuration. There are also protection boards for various numbers of cells in series, such as 2S (7.4V) and 3S (11.1V) and so on.
Enjoy!
Answer: I know it's for a Lithium Ion battery, but could you get a Li-po battery alarm, and when the alarm sounds, activate a relay to disable the battery connection to the Arduino?
I saw a video about this a while back, but I'm not sure if it would work with a Lithium Ion battery.
Here is a link to the video, it may help you: http://www.youtube.com/watch?v=1Fs4SfVSsLk
Comment: Yeah idk, I need this to be really power efficient, I think a lipo alarm draws some power. Disabling the power is no problem with the arduimo itself, just enabling it once voltage is high enough is a problem


Call ToolingAPI or Metadata API in APEX without adding instance url into remote site settings

Question: I need to upgrade the metadata in post install script, for instance, upgrade the picklist values for some fields, as those values are not updatable for the existing orgs.
Not matter I tried to use ToolingAPI or Metadata API, I was asked to specified the instance url in the remote site settings, otherwise, the endpoint is invalid.
Do I have to add the instance url in each of the orgs, or is there any way to bypass this limit?
Ideally, I don't want to add that in the remote site settings, as the instance url could be changed in case Salesforce does split in the future.
Answer: One method an evangelist told me about was to use a proxy, e.g. on heroku. So you callout goes every time to the same endpoint. Add the instance where your org is located to the request and the proxy is doing the final callout to the appropriate endpoint at salesforce again.
So you would only need one remote site which is the same for all orgs.
For my taste not good, because it won't make things faster and in all my scenarios I am counting each second to save...
As I said above, you can never add all possible endpoint for the all users, because of the myDomains.
What we did in the end is to add a couple of common endpoints to the package (like naXX,euXX,csXX) - but be even careful with that, because if you add to many, the confirm button will slide outside visible screen - and there are no scrollbars to reach it...
Answer: I believe you can specify one instance url, say na1, and use that as your endpoint. SF will auto-reroute the request to the proper instance that you're logged into.
Comment: While the browser is nice enough to do this for you, the API isn't as forgiving. You will indeed need to add all possible URL values to the list of remote site settings, and include this in your package. Otherwise, you'll need to provide manual upgrade steps or pre-installation steps.
Comment: unfortunately, it seems that way doesn't work. I tried add https://na1.salesforce.com as Remote Site URL, Endpoint=https://na1.salesforce.com/services/data/v30.0/tooling/sobjects/CustomField/{ID} , got exception:the System.HttpResponse[Status=Unauthorized, StatusCode=401]
Comment: Providing all possible endpints is not possible. Think about the myDomains. If you try to provide a very long list of remote sites for the standard pods, you will also end up in scrolling issues and confirm button outside visible screen.
Comment: You're right. I did forget about my domain. Manual step or proxy it is.


Volume of specials sets on sphere $S^N$

Question: Suppose I'm given $m$ points $\{q_i\}$ on the sphere $S^N$. I want to get a lower/upper bound for the volume of the following sets with respect to uniform probability measure $\mathbb{P}$ on the sphere. Let
$$
A_i = \{ x \in S^N : (q_i,x) > (q_j,x) ~\forall j \neq i \}
$$
Is there (say) a formula for such a quantity in terms of the $q_i$? Suppose I know everything there is to know about the $q_i$, is there a general strategy for calculating such things?
Answer: On a 2-sphere, such regions are spherical polygons (each of the inequalities in the definition of $A_i$ gives you a half-sphere). The area of such a polygon is given by a formula using the sum of angles of the polygon. So I am afraid you will first have to construct these Voronoi polygons. There are some algorithms for that.
In higher dimensions, the situation must be worse.
Answer: To supplement Yuri's answer:
In response to the earlier MO question, Delaunay triangulations and convex hulls, I posted this image:

Image by Maxim Rytin in a Mathematica Demo.

See that MO question for related references.

Volume of specials sets on sphere $S^N$


Should 'Next/Previous' Buttons Be Centered Or Left Aligned?

Question: I am trying to decide where I should put my pagination buttons on my site. I've noticed that most sites either choose left aligned, or centered buttons. Which place does the user look at first when they get to the end of a page?
Sites like Google and YouTube they have them centered:

Sites like Reddit and Bing they have them left aligned:
Answer: See where they look best based on the content you have on the page. Looking for eye breakpoints from image to text and then to the ones in the next row below.
Youtube has distinctive video thumbnails that grabs more attention, so probably it looks easier to find the navigation buttons when centered.
The second example has a line divider that gets the buttons its required attention. Scanning the lines - all left aligned.


Why are cursor keys in Excel moving the viewport rather than the active cell?

Question: Excel for Mac (2011) should move the currently active cell when I use the cursor keys. Currently, it is moving the viewport in the document. Is there a way to switch this back to the default setting? I cannot find anything in Excel's preferences.
Answer: This sounds like Scroll Lock is somehow activated on your copy of Excel. IF you have a large keyboard with an F14 key, ShiftF14 can turn on and off Scroll Lock. If you don't have such a keyboard, or access to such a keyboard, it gets more complicated.
Microsoft support posted this article about the various methods of deactivating Scroll Lock. They either involve connecting a keyboard with a F14 key or removing your Excel preferences file.
Answer: If you don't have an F14 key, you can use the on-screen keyboard. In Windows click the Windows key and type "osk" and then press enter. Works like a charm.
Comment: My original question was about Excel for Mac. Funnily enough, OS X doesn't have a Windows key.


Look through a file and print text from specific lines

Question: I have a file with data that I save. Now I would like to print my results into a new file.
For instance, let's take this example, randomlog.log:
Link encap:Ethernet HWaddr 08:00:00:00:00:67
inet addr:10.10.10.10 Bcast:10.10.10.10 Mask:255.255.255.0
inet6 addr: fe80::casf:sdfg:23ra:dg12/64 Scope:Link

How can I take only data from the 12th to the 20th character of the first line and then the 4th to 8th characters of the 3rd line? Output would look something like this:
Ethernet
t6 ad

Is this possible?
I want to set the line and from position to this position.
Answer: Here's a sed approach:
$ sed -nE '1s/.{11}(.{8}).*/\1/p; 3s/.{3}(.{4}).*/\1/p' file
Ethernet
t6 a

Explanation
The -n suppresses normal output (normal is to print every input line) so that it only prints when told to. The -E enables extended regular expressions.
The sed script has two commands, both using the substitution operator (s/original/replacement/). The 1s/.{11}(.{8}).*/\1/p will only run on the 1st line (that's what the 1s does), and will match the 1st 11 characters of the line (.{11}), then it captures the next 8 ((.{8}), the parentheses are a "capture group") and then everything else until the end of the line (.*). All this is replaced with whatever was in the capture group (\1; if there were a second capture group, it would be \2 etc.). Finally, the p at the end (s/foo/bar/p) causes the line to be printed after the substitution has been made. This results in only the target 8 characters being output.
The second command is the same general idea except that it will only run on the 3rd line (3s) and will keep the 4 characters starting from the 4th.

You could also do the same thing with perl:
$ perl -ne 'if($.==1){s/.{11}(.{8}).*/\1/}
            elsif($.==3){s/.{3}(.{4}).*/\1/}
            else{next}; print; ' file
Ethernet
t6 a

Explanation
The -ne means "read the input file line by line and apply the script given by -e to each line. The script is the same basic idea as before. The $. variable holds the current line number so we check if the line number is either 1 or 3 and, if so, run the substitution, else skip. Therefore the print will only be run for those two lines since all others will be skipped.

Of course, this is Perl, so TIMTOWTDI:
$ perl -F"" -lane '$. == 1 && print @F[11..19]; $.==3 && print @F[3..6]' file
Ethernet
t6 a

Explanation
Here, the -a means "split each input line on the character given by -F and save as the array @F. Since the character given is empty, this will save each character of the input line as an element in @F. Then, we print elements 11-19 (arrays start counting at 0) for the 1st line and 3-7 for the 3rd.
Answer: awk approach:
$ awk 'NR==1{print substr($0,12,8)};NR==3{print substr($0,4,4)}' input.txt
Ethernet
t6 a

Uses NR for determining line (in awk terminology - record) number, and accordingly print substring of the line. substr() function is in format
substr(string,starting position,how much offset)

Python
$ python -c 'import sys
> for index,line in enumerate(sys.stdin,1):
>     if index == 1:
>          print line[11:19]
>     if index == 3:
>          print line[3:7]' < input.txt
Ethernet
t6 a

This uses < shell operator to redirect input stream to python process from the input file. Note that strings in python are 0-indexed, hence you need to shift your desired character numbers all by 1.
portable shell way
This works in ksh, dash, bash. Relies only on shell utilities, nothing external.
#!/bin/sh

rsubstr(){
    i=0;
    while [ $i -lt  $2 ];
    do
        rmcount="${rmcount}?"
        i=$(($i+1))
    done;
    echo "${1#$rmcount}"
}

lsubstr(){
    printf "%.${2}s\n" "$1"
}

line_handler(){
    case $2 in
        1) lsubstr "$(rsubstr "$1" 11)" 8 ;;
        3) lsubstr "$(rsubstr "$1" 3)" 5 ;;
    esac
}

readlines(){
    line_count=1
    while IFS= read -r line;
    do
        line_handler "$line" "$line_count"
        line_count=$(($line_count+1))
    done < $1
}

readlines "$1"

And it works like so:
$ ./get_line_substrings.sh input.txt
Ethernet
t6 ad


Use of Nash-Equilibrium in big data environments

Question: Has there been a successful implementation of Nash-Equilibrium in big data problems like suggesting a best buy in a stock market, in traffic monitoring systems or crowd control systems.
All the above mentioned scenarios have competitive environments and one needs to get the best possible solution in them, which should suit well for Nash-Equilibrium cases.
Comment: Often you rather want to predict (stock market), which is unrelated to Nash. Also crowds/people do not follow Nash and usually you want to control the crowd, rather than game it. And Nash relies on an abstract model for you simply do not have the numbers in real life. That's my impression, but I'd be interested to see confirmed cases of usage which go beyond an academic paper.
Comment: I have done a bit of study on the topic, which is not authoritative, but I think Nash-Equilibrium gives us to choose the best decision when we have an idea about the decisions of our competitors. Secondly it is not an abstract model, all the abstractions are removed by assigning a pay-off function which is quantifiable.
Comment: I'm just saying the tasks are different. Stock prediction: We need to predict the future of a very complex system that will not care about an equilibrium. Abstract model: They are almost never known payoff-function - welcome to reality. People: They provable do not follow Nash - in a fixed round Prisoners dilemma they do not all default.
Comment: Have a look at Acemoglu (http://economics.mit.edu/files/9789) and Jackson (http://web.stanford.edu/~jacksonm/GamesNetworks.pdf). They write on games on networks, and it may have many practical applications.
Answer: This question isn't terribly clear.  Data analysis and strategic modeling (game theory) are different tasks.  Nash equilibrium is a way of understanding the incentives they have by assuming a set of players with assumed utility function and making deductive inferences about what they ought to do to maximize those utility functions given their interaction.  Data analysis is an inductive process.
There are a number of ways game theory and data analysis might interact, here are the easy top two:

Someone might use data to infer players' utility functions (I'm sure this exists in econometrics-land somewhere; also, political scientists have a technique called "ideal point estimation," to infer political preferences from voting behavior---which you can easily google to learn more);
Someone might use game theory to generate behavioral predictions which are testable by data.

Thinking about the specific kinds of cases you mention, the obvious application would be in the stock market one.  Suppose you have a ML model that can reliably predict the market behavior of other people at time T from a given feature set.  Then the consumer of the ML model might have an optimal purchase at T-1, and finding that optimal purchase is going to be strategic.
But combining the two approaches might just break the ML. This is really interesting to think about... musing out loud...
Consider the simple case of a two-player market in one stock. Player 1 wants to buy at T-1 if player 2 will be buying at T (because the price will go up); player 1 wants to sell at T-1 if player 2 will sell at T (because the price will go down).  The naive approach for player 1 is "use my ML model to predict what player 2 will do, then do it first at T-1." But, of course, P1's behavior at T-1 is itself observable by P2, and changes P2's behavior (the price has gone up); moreover, by definition P1's behavior at T-1 can't be a feature of the ML model used to predict P2's behavior at T, because it's behavior that is chosen on the basis of the ML prediction.  All sorts of fun puzzles begin here, but none of them look real good...
Answer: I have a very limited knowledge of game theory, but hope to learn more. However, I think that potential applications of Nash equilibrium in the context of big data environments, implies the need of analyzing a large number of features (representing various strategic pathways or traits) as well as large number of cases (representing significant number of actors). Considering these points, I would think that complexity and, consequently, performance requirements for Nash equilibrium in big data applications grow exponentially. For some examples from the Internet load-balancing domain, see paper by Even-Dar, Kesselman and Mansour (n.d.).
The above-mentioned points touch only the volume aspect of 4V big data model (an update of Gartner's original 3V model). If you add to that other aspects (variety, velocity and veracity), the situation seems to become even more complex. Perhaps, people with econometrics background and experience will have some of the most comprehensive opinions on this interesting question. A lot of such people are active on Cross Validated, so I will let them know about this question - hopefully, some of them will be interested to share their view by answering this question.
References
Even-Dar, E., Kesselman, A., & Mansour, Y. (n.d.). Convergence time to Nash equilibria. Retrieved from http://www.tau.ac.il/~mansour/course_games/nash-load.pdf
Comment: :Your elaboration is spot on. Right now I am implementing a 3 player problem with around 13 strategies each. That will give me an idea. In future the number of strategies as well as the number of players are going to rise and the question was in that context. I will post my interpretations and conclusions once I get some concrete results.
Comment: @AdiPiratla: I am glad to help. Good luck with your implementation. It would be interesting to read your insights upon completion.


Is there any relationship between frequency of signal and distance it travels?

Question: I'm currently researching 5G technology. Many videos/articles on this topic claim that 5G is designed for communicating on lower distances (than 4G), because of higher (than 4G) frequency. So to build a network we need more dense grid of access points. Is this some general rule, that the higher frequency means less range, or is it connected to this exact frequency range, specific to 5G?
Comment: @analogsystemsrf It's more complicated than that. 60 GHz has an oxygen absorption line, but then absorption goes back down until a second line at 118 GHz, then a water line at 183 GHz, etc. Water and other atmospheric gases have specific absorption regions and transmission windows all the way up through the infrared, where it clears up by the visible.
Comment: Atmospheric absorption peaks at  60---70Ghz.
Comment: Diffraction increases with frequency. FM has shorter range than AM because it uses higher carrier freq. Long waves can go by obstacles better. But increasing carrier wave increases BW for the information signal.
Answer: In general, yes, higher frequencies attenuate more the further distance they travel. There are two effects that are responsible for this.
First, higher frequency radio waves tend to be absorbed more readily by objects (ie: the penetration depth in the material is shorter). You may have noticed this effect with your home WiFi network. If you have a dual-band router, you probably have two networks, one at 2.4 GHz and one at 5 GHz. You may have noticed that the 2.4 GHz network reaches some corners of your house that the 5 GHz network does not - this is because the 2.4 GHz network penetrates walls better than the 5 GHz network does.
In terms of fifth-generation cell networks, this is the principal effect that limits range: people prefer to live in houses and apartment buildings, and those houses absorb more RF energy at higher frequencies.
The second effect is less intuitive, and falls out the Friis equation for free-space path loss.
$$  FSPL= 20\log_{10}(d) + 20\log_{10}(f) + 20\log_{10}\left(\frac{4\pi}{c}\right)$$
Where \$FSPL\$ is the free space path loss in dB, \$d\$ is the distance in meters, and \$f\$ is the frequency in hertz, and \$c\$ is the speed of light. Note that as \$f\$ increases, the loss increases: a doubling in frequency results in a 6 dB increase in path loss.
This equation would lead you to believe that free space in some way attenuates higher frequencies more than lower frequencies, but that's not really the truth, even though it's a convenient lie we engineers tell ourselves. The "free space path loss" is actually a geometric effect that captures the "spread" of the electromagnetic wave as it propagates in free space, the same as how the beam of a flashlight spreads out when it's shone out into a big dark room.
The reason it's frequency dependent is because it does not account for the gain of the transmitting and receiving antenna - they are assumed to be isotropic. An isotropic antenna at a higher frequency is physically smaller than one at a lower frequency, which means that geometrically they have a smaller effective aperture.
If you keep the effective aperture of one antenna at one end of the link the same physical size as you go up in frequency, you actually see that your path loss is independent of frequency. However, you would also find that antenna is now directional: as you increase the aperture size, a transmitting antenna shoots a tighter and tighter beam, and a receiving antenna can only receive signals from a narrower and narrower cone. Since engineers usually think in terms of preserving a given antenna pattern and not in aperture size (since pointing antennas can be problematic), we commonly consider free space to have "loss" that increases with frequency when in reality that isn't quite the case.
Comment: Thank you very much! It's really detailed answer.
Answer: Peter's answer is very good. The difficulty that millimeter wave has with penetrating buildings and foliage is one reason for small cells. Contrary to popular opinion, atmospheric absorption is not really a factor, even for 60 GHz, for ranges of a few hundred meters (it does help quench stray signals out of cell boundaries, however.) A dense grid has other advantages, such as higher system capacity and lower link power. The ability to beam signal means the same frequency can be used to service several users (unlike today's cells) and reduce ambient radiation exposure.
Answer: Just to add: 5G systems may not always be using higher frequencies than 4G systems. Some of the bands are designated as sub-6 GHz, using microwave frequencies comparable to 4G. But there are also millimeter wave bands that are at higher frequencies than those used in 4G.
The other answers have mostly been considering the case of the higher frequencies.


Stopping a twist timer

Question: I have a storage shed that has a twist timer so that the lights turn off every hour. Other than replacing or removing the timer (I don't have authorization to do that nor could I turn off the electricity to get it done), how can I get the timer to stop, so that the light stays on until I turn it off?
Answer: The timer was put there by the storage owner so that their electric bill isn't subject to abuse by people renting the units.  It also prevents (for instance) people using the units as marijuana growing facilities, or other kinds of production (legal or otherwise) and getting the storage service to pay the electric bill.  If there isn't an unswitched outlet in the unit, there isn't a "hack" to bypass the timer, and as you note, altering the wiring would surely violate your rental agreement.
If your need for long term power is low-draw, you may be able to rig something using batteries and an inverter, but you'd still have to supply the power to charge the batteries, or put a screw-in outlet in the light socket to providing charge on the timed power (and be limited to the amount of charge you can put into the battery in an hour at a time). As Robert Cartaino noted in comments, if light is all you need, a suitable battery lantern is probably a better solution than trying to find a way to defeat the light switch timer.
Comment: Great point about the purpose/need for the timer. That makes this an [x-y problem](http://meta.stackexchange.com/questions/66377) asking about the solution rather than the actual problem. The author needs light. A **[high-output LED lantern](https://www.google.com/#tbm=shop&q=+LED+lanterns)** would be better suited to that task.
Answer: It is somewhat jarring to have the lights suddenly go off when you are in the middle of something, but the timer is necessary to ensure the lights aren't left on long after you are gone.
If you want to ensure the lights stay on without disruption, set a recurring reminder for 55 minutes on your smart phone (or kitchen timer) so you can reset the light timer if a longer duration is needed. That will give you a bit of time to turn that twist-timer back when it is convenient… rather than getting caught stumbling around in the dark when the lights go off unexpectedly.
Comment: Carrying a pocket flashlight is also not a bad idea, just in case you don't make it back to the timer promptly.  Fortunately, smartphones have (or can download) a flashlight app.  Kitchen timers, not so much...
Answer: I have had to bypass a timer in an old storage unit once. I used a pair of vice grips on the dial of the timer so they looked like hands of a clock on the wall. Then I blocked their movement with a small nail, and patched the hole after.
Answer: it is easy put some cardboard behind the switch after you turn it on if the cardboard is thick and tight the switch will not revolve and the power would stay on. this also works on those vibrating beds in hotels that run off the same type switch
Comment: This seems unsafe.
Answer: A hack is a duct tape over the timer if it physically moves.  Not saying it would work or even if it does be appreciated by the owner but is worth a try.
Not recommended but changing out hot can be done.  120V is not going to kill you unless you just hang on and the circuit does not trip.
Comment: `120V is not going to kill you` That is horrible, potentially fatal misinformation— https://www.google.com/#q=can+120+volt+kill+you
Comment: I've changed 120V hot, too -- but I'd recommend avoiding it if possible.  All it takes is grabbing the hot with one hand while the other brushes a ground, and no one to see you fall and administer CPR, and you're dead.  30 mA of 60 Hz across your heart will induce v-fib, which is fatal if not treated within a couple minutes...
Comment: @RobertCartaino  It is not advice. "Also not recommended".  I have changed out a lot of 120 V hot.
Comment: @ZeissIkon And I recommended against it

Stopping a twist timer


How is $\operatorname{GL}(1,\mathbb{C})$ related to $\operatorname{GL}(2,\mathbb{R})$?

Question: I am trying to get a grasp on what a representation is, and a professor gave me a simple example of representing the group $Z_{12}$ as the twelve roots of unity, or corresponding $2\times 2$ matrices. Now I am wondering how $\operatorname{GL}(1,\mathbb{C})$ and $\operatorname{GL}(2,\mathbb{R})$ are related, since the elements of both groups are automorphisms of the complex numbers. $\operatorname{GL}(\mathbb{C})$, the group of automorphisms of C, is (to my understanding) isomorphic to both $\operatorname{GL}(1,\mathbb{C})$ and $\operatorname{GL}(2,\mathbb{R})$ since the complex numbers are a two-dimensional vector space over $\mathbb{R}$. But it doesn't seem like these two groups are isomorphic to each other.
Comment: @Aaron: if the OP knew how to compute dimensions of Lie algebras, presumably he/she wouldn't be asking this question.
Comment: Okay.  Sorry if that was rude or anything.  I know very little about representation theory, and I definitely didn't know that people study representations of Lie groups totally independently of Lie algebras.
Comment: An easy way to see that these are distinct is to note that they have different dimensions: $\dim_\mathbb{C}(\mathfrak{gl}_1(\mathbb{C}))=1$, while $\dim_\mathbb{R}(\mathfrak{gl}_2(\mathbb{R}))=4$.
Answer: No, they're not isomorphic. $GL(1,\mathbb{C})$ injects into $GL(2, \mathbb{R})$ but the latter consists of the set of real automorphisms of $\mathbb{R}^2$, while the former consists of the set of all complex automorphisms of $\mathbb{C}$. For instance, an element of $GL(1, \mathbb{C})$ is the composite of a scaling (dilation) by a positive real number and a rotation, so is $\mathbb{R}_{>0} \times SO(2) = \mathbb{R}_{>0} \times S^1$. However, $GL(2, \mathbb{R})$ includes more complicated things (e.g. reflections, things which even if scaled do not become orthogonal transformations).
Comment: To elaborate, the point is that being a $\mathbb{C}$-automorphism is a stronger condition than being an $\mathbb{R}$-automorphism, because the $\mathbb{C}$-structure is richer than the $\mathbb{R}$-structure, even though the underlying sets are the same.
Comment: @Sam: Implicit in the definition of a vector space is a fixed base field.  When you say "the group of all automorphisms of $V$", the base field is already chosen.  The vector space $\mathbb{C}$ over $\mathbb{C}$ and the vector space $\mathbb{C}$ over $\mathbb{R}$ are different vector spaces, even though they have the same underlying set and additive structure, so you should not expect their automorphism groups to be isomorphic.  (And the answer above gives you detail on why they are not.)
Comment: ...where by $\mathbb{R}^*$ you mean $\mathbb{R}^{> 0}$, of course.
Comment: That makes sense, and that's why I'm having trouble. They are not isomorphic, but consider the following Wikipedia entry,

If V is a vector space over the field F, then we write GL(V) or Aut(V) for the group of all automorphisms of V, i.e. the set of all bijective linear transformations V → V, together with functional composition as group operation. If the dimension of V is n, then GL(V) and GL(n, F) are isomorphic.

We can look at C as a 1-dimensional vector space over itself, or as a 2-dimensional vector space over the reals. Shouldn't this imply the two are isomorphic? What am I missing?
Comment: Thank you. It's much more clear now, although some of these concepts are still hard to grasp. That answers my question.
Answer: The one group is commutative, the other is not. So they can not be isomorphic.
Answer: $GL(1,\mathbb{C})$ can be thought of as the group of automorphisms of $\mathbb{C}$ as a complex vector space.  Each such automorphism is given by multiplication by a nonzero complex number. On the other hand, $GL(2,\mathbb{R})$ can be thought of as the group of automorphisms of $\mathbb{C}$ as a real vector space, and hence it is larger.  In terms of matrices, $GL(1,\mathbb{C})$ corresponds to all $2$-by-$2$ real matrices of the form
$\begin{bmatrix}
a & -b \\
b & a
\end{bmatrix}$ with $a^2+b^2\gt0$, which is a proper subgroup of the group $GL(2,\mathbb{R})$ of all $2$-by-$2$ real invertible matrices.
Comment: @Sam: the same mathematical object often has several different automorphism groups, depending upon what kind of automorphisms are being considered.  For instance the automorphism group of $\mathbb{R}$ as a metric space (i.e., its isometry group) is much smaller than its automorphism group as a topological space, which is (very!) much smaller than its automorphism group as a set (i.e., the bijections).  Something similar is happening here: a complex vector space has "more structure" than its underlying real vector space, hence fewer automorphisms.
Comment: @Sam: By the way, Akhil's answer gives a good conceptual way to see that the groups are not isomorphic, but you could also see this with some examples.  E.g., complex conjugation gives a real automorphism that is not a complex automorphism, and shows that there are more order 2 real automorphisms than complex automorphisms.
Comment: @Sam: I gave one reply on Akhil's answer.  A rough way to think of it is that being able to pull out complex scalars is stronger than being able to pull out real scalars, since the latter can be thought of as a special case of the former.
Comment: That makes sense. I guess I'm still having trouble understanding how the group of automorphisms is different based on how you view the vector space.
Answer: I'd like to supplement the above answers with two important examples.  Consider a hyperbolic transformation $H(x, y) = (2x, y/2)$ and a shear $S(x,y) = (x+y, y)$, both elements of $GL(2,R)$.  If you draw how these act on points of $R^2$ you will see that these distort angles.  On the other hand, elements of $GL(1,C)$ always preserve angles (and thus so do holomorphic maps, away from critical points).
That is, the extra algebraic structure preserved by $GL(1,C)$ translates to the geometric property of preserving angles and "handedness".


How much splash range does the RPG have in Fortnite?

Question: Sometimes I feel like I am super far away from the RPG blast but still get hit. What range would I have to be, away from the explosion, to take 0 damage?
Answer: The RPG has a one-square damage range. When you build 4 walls around you, the space in between is called a square, which there are thousands of on the map. If someone shoots an RPG and it lands exactly a square away from you, it will deal damage - but if you moved a tiny bit back before, you would be alive. The same applies to grenades, boogie bombs, smoke grenades and impulse grenades. If the RPG hits in the corner of one square, like in the diagram below, it will damage 4 different squares.
Red represents highest damage - usually between 140 to 240.
Orange represents normal damage - usually between 80 and 140.
Yellow represents low damage - usually between 20 and 80.
The  black dot under the player shows where they are, and the RPG image shows where the blast hit.

As you can see, 4 squares around the blast are affected, and if you are a square away from the blast you may still get fairly high damage, leading you to die.
Hope this helped.
Comment: @FlamingThunder certainly. something that helps greatly is using an impulse grenade to jump further back - but you could also build a wall, which can absorb the damage from a rocket- if someone is spamming them at you, keep building walls, and the rockets wont deal damage to someone behind them - only the walls
Comment: So if you jump right as the rocket hits near you can you potentially take less damage?
Answer: I watched a replay of me getting killed by a rocket and it was two "blocks" away from me and it killed me when I had 120 hp
Comment: Welcome and thanks for contributing. I'm sure the OP will find your input helpful, but it may have been better to post this as a comment, since this doesn't answer the question completely. You may need to [wait to comment until you have sufficient reputation](https://meta.stackexchange.com/questions/214173/why-do-i-need-50-reputation-to-comment-what-can-i-do-instead). Until then, keep on asking and answering good questions!


Like button not showing in Safari iOS on iPhone

Question: I have created a website that has social networking 'likes' etc and have included a Facebook Like button using the js version of the code.
It all works fine on PC in IE/Chrome/Safari but the Like button does not show when the website is accessed using Safari on an iPhone.  The code in the page is as follows:
 (function(d, s, id) {
     var js, fjs = d.getElementsByTagName(s)[0];
     if (d.getElementById(id)) {return;}
     js = d.createElement(s); js.id = id;
     js.src = "http://connect.facebook.net/en_GB/all.js#xfbml=1";
     fjs.parentNode.insertBefore(js, fjs);
 }
 (document, 'script', 'facebook-jssdk'));

inside a


May I summarize all answers

Question: on StackOverflow, I asked a question. There are many good answers but I can not accept just one of it. I would prefer to create my own answer where I summarize all answers. Is that allowed?
Comment: I had this same problem with a question in which the person posting the answer and I had a long discussion about solutions in comments and I wanted to summarize them for others.
Answer: Another approach is to add a comment to the "rightest" post, suggesting the author update to include the other info, with attribution where necessary.
Then you can up vote all contributors to the final answer, and accept the now complete one
That will potentially minimize posters potential frustration, and better align the resulting votes with the primary source of the answer.   And you'll even get 2 points for accepting, since it won't be your own response.
Answer: Yes, that's fine.  The idea is to get the best possible answer to the question to the top of the page so future Web searchers will find it quickly.  If you need to combine several answers into one to do that, then feel free to do so.  Just make sure you give attribution if you're copy/pasting someone else's answer (just a link to their answer).
Also remember that normal voting rules still apply, so if other people see you doing this and don't think it provides value, they're free to downvote it.  Try not to take offense to this, just use it as feedback and adjust the way you're answering.
A good example is in Hidden Features of C#?, although the summary should be in an answer instead of the question.

May I summarize all answers


Has anyone tried using ZooKeeper?

Question: I was currently looking into memcached as way to coordinate a group of server, but came across Apache's ZooKeeper along the way. It looks interesting, and Yahoo uses it, so it shouldn't be bad, but I'd never heard of it before, so I'm kind of skeptical. Has anyone else given it a try? Any comments or ideas?
Answer: ZooKeeper and Memcached have different purposes. You can use memcached to do server coordination, but you'll have to do most of this work yourself. Memcached only allows coordination in that it caches common data lookups to be used by multiple clients. From reading ZooKeeper's documentation, it has a much broader focus than this. ZooKeeper seems to provide support for server clustering, which isn't the same as the cache clustering memcached provides.
Have a look at Brad Fitzpatrick's Linux Journal article on memcached to get a better idea what I mean.
Answer: To get an overview of what Zookeper is capable of, watch the following presentation by it's creators. It's capable of so much more (creating queue's, electing master processes amongst a group of peers, distributed high performance run time configurations, rendezvous points for dis-joined processes, determining if processes are still running, etc).
http://zookeeper.sourceforge.net/index.sf.shtml
To answer your question, if "coordination" is what you are looking for Zookeeper is much better targeted at that than memcached.
Answer: Zookeeper is great for coordinating data across servers. It does a good job of ordering every transaction and making guarantees that transactions happen in order. However when first breaking into it the documentation sucks; it's very 'high-level' without enough concrete examples or explanations as how to properly handle certain events. One of the included examples (as of version 3.3.3) had its own bugs in it.
Your code will also need to be cognizant of event driven interactions, and polling interactions. With massively distributed architecture, when acting upon 'events' you can inadvertently create a stampede that could not be desirable for your environment (herding effect).

Has anyone tried using ZooKeeper?


A set definition of 'effective'

Question: In the Kalaripayattu question Matt Chan asked 'effective for what?', Dave Liepmann made a very good comment in response that by default we should assume that it means effective at fighting. I think it would be good if this becomes an official policy, to have a site-wide assumption that martial arts are about fighting, and that people are asking questions about being better at fighting.
Answer: Rather than trying to establish some local standard (that outsiders won't necessarily be aware of, and may struggle to learn as they acclimate to the site), why not just... Edit unclear questions?
Now, being a naive outsider, I would tend to assume that questions on a site named "Martial Arts" would be about fighting. So if there's any ambiguity in a post, editing it to clarify with that presumption would be appropriate - and if it turns out you're wrong, prompt the author to clarify himself.
Either way, the end result is an increase in clarity.
In most situations, I would expect there to be relatively little ambiguity to begin with, so no action (or implicit, site-local humpty dumptyism) is needed.
Comment: @Dave Comparing martial arts is off topic if it could lead to a pissing contest (excuse the vulgarity). It's not off topic if the user can compose a good question out of it. "What's better" would be off topic, "What's the difference" would be quite on topic.
Comment: @slugster I think I agree that what you describe would be fine, but currently the FAQ forbids any "which should I do" question on "non-constructive" grounds, which is frankly bonkers. (As long as the question includes some context, it's very fruitful.) The FAQ reads: "What martial arts system is "best" or if you should practice art A instead of art B (not constructive)"
Comment: The issue is that one segment of early users and mods have entrenched the frankly strange idea that comparing styles of martial arts is off-topic. Therefore reducing clarity in the assumed direction (towards fighting) immediately leads to a closed question instead of clarity. However, you are right, editing posts > setting a local standard.
Comment: @DaveLiepmann you bring up a good point, thinking about it now, Matt Chan's effective at what question was passive agressive
Answer: I don't think it is a good idea to "have a site-wide assumption that martial arts are about fighting."  That is certainly one application of martial arts, but there are plenty of martial arts that aren't about "fighting" or, at the least, are either fairly far removed from their roots or have significant priorities in addition to anything regarding fighting.
Certainly, even beyond that, there are reasons people practice martial arts beyond "being better at fighting."
Comment: Just because your priority is fighting doesn't mean that everyone else's is as well, nor does it mean that everyone else should have the same priorities that you do.  Not to mention that the topic of "fighting" is large in and of itself: There's mutual engagements, self defense, battlefields, etc.
Comment: If they're not about fighting, then there's a more appropriate site to ask questions in. If it's about fitness, ask of fitness.se, then you don't have any confusion about what your goals are. If it's about forms, ask on a dance site, and so on.

Practicing it for reasons other than fighting is most often because they realise after the fact that what they've been doing isn't any good for fighting but don't want to admit they've been wasting their time.
Comment: As you say, the topic of fighting is large and give MA.SE a large enough scope anyway.
Comment: Except that the scope of the site isn't "fighting.SE" it is "martialarts.SE".
Comment: +1, we need a place for aikidoka.
Answer: The original poster on the example question even noted that he or she was only asking for a plain comparision in response to my question about what efficacy the asker was seeking.
The problem with creating this assumption is that it is narrowing the idea of what martial arts as a whole encompasses. Like what David H. Clements stated in his answer, martial arts doesn't have to be entirely about fighting.
What makes the assumption narrowing that prescribing an assumed meaning for the question removes the onus of the user to effectively communicate what to ask, to be clear and descriptive of the . One reason is to maintain quality on this site, but another is to hope that users will learn to improve in this regard. Users shirking responsibility to put effort into a question is a reflection of the the irresponsibility of the site and those that contributing and participating in this site.
Keep in mind that not everyone here also is a native English speaker. It would be a disservice to those who aren't able to word their thoughts are well as others who are fluent in English (and sometimes I question native speakers too) by creating a site-wide assumption for a set of few words.
In short, this is a bad idea and ultimately doesn't benefit the site.
Comment: Your language isn't going to effect what you think martial arts are about. It's still going to be about fighting. Find me someone who thinks martial arts isn't about fighting who isn't themselves a martial artist who is unable to fight well.
Answer: Robin, I see your point, but have to disagree.
Aikido belongs on MA.SE. Aikido is almost always not about fighting. (That doesn't preclude mentioning how terrible it is at producing fighting-capable individuals.)  So right away, I have to disagree with your proposal. (Shog9's answer, as usual, also has the correct.)
The problem here is not a standard about fighting being the default. It's that a number of fairly obvious topics are strangely off-topic or viewed with disdain by the general MA.SE user base. For instance: comparing styles (which you and I agree should be on-topic), or that fighting is by default always relevant in martial arts.
When someone asks for a "plain comparison" in the context of a recommendation, I think it's pretty plain that we should both keep the question and take it as a question incorporating effectiveness at fighting as well as ancillary goals (which would, ideally, be explained in detail). My concern is that the question was close to closure because mods saw it as a style-comparison/effectiveness-at-fighting question, which is patently absurd in my view. (Such questions have a lot of value pretty much as soon as they get more specific than "which is better herp derp".)
I think that me and you and other users having the assumption that martial arts are about fighting is enough. I even believe that martial arts have other purposes--health, community, a sense of meaning--but that doesn't take away from the fighting being central.
Comment: I agree we need a place for aikidoka, and shorinji kempoka and taichi practitioners,but having a default definition (ie unmarked) doesn't mean non default assumption is precluded, it just means it has to be specified (ie marked)
Answer: I've been thinking about this question, going back and forth in my mind and struggling to answer. Then I found the following on Eric Raymond's blog.
Different schools and styles answer to different purposes. When speaking of these, martial artists commonly describe three categories: combative (practical self-defense), sport (competitive fighting), and do (self-control and self-improvement; this may just mean physical fitness, but in some arts shades into meditation and mysticism, most often of a Buddhist or Taoist variety).
I think he's said that rather well; "effective" doesn't always mean combat; different people do martial arts for different reasons, and "effective" means that martial art advances your particular goals.
updated partly based on R. Ashe's excellent comments
I feel the need to add some caveats.
1) I strongly support the notion that MASE is about answers, not discussion.  That said, I think that some empirical responses can be legitimate answers even without ordinal measurements.
2) I'm nervous about "combat effectiveness" as the gold standard. Every art makes assumptions about the types of attacks and attackers.  Every art compromises "effective" in favor of "safe".  (different arts make different compromises).  We have had some students come to our dojo and leave because we practice a more "pragmatic" style, and we've had some students leave because we were insufficiently "street lethal".   I'm very reluctant to conclude that either of those groups of students weren't practicing or looking for "legitimate" martial arts.  I believe it was one of the Northern Wind instructors who pointed out that very few "real" fights occur on tatami mats, but I think most of us practice in such an environment.  I don't disagree that "effective = combat" is a useful yardstick, but
Ultimately, I think this is a useful standard, but not one we should try to enforce.
Comment: Would you even claim a style is effective or ineffective in the do category? And for that matter, what separates someone practicing MA for do from someone who practices yoga? On the other hand, you can actually answer the question of effectiveness when you're talking about combatives.
Comment: Very interesting challenges.  You're correct, there is no purely objective  test for effective Do. OTOH, I think that like "pornography" or "science" we can achieve empirical consensus about the non-marginal cases.  I think Yoga is off topic by self-definition - they don't define themselves as martial arts.
Comment: Yeah, yoga doesn't self identify as a martial art, yet it's otherwise virtually indistinguishable from other arts that do identify as martial. Maybe it's time to call them out for misrepresentation.
Answer: From the FAQ:

Theatrical or stage combat that focus more on theater or entertainment (for role-playing, re-enactments, etc.) (off-topic)
Fitness issues unrelated to martial arts (off-topic, please ask on Fitness & Nutrition)

So we've got 2 topics that are already outlawed here. First of all, how do you define that a fitness issue is unrelated to martial arts, and blocking discussion of theatre and entertainment already precludes discussing another non-combative application of martial arts.

A set definition of 'effective'


Difference between DNS Spoofing and DNS Hijacking?

Question: DNS Spoofing and DNS Hijacking, both of them basically are type of attacks where the request is redirected to some other malicious website or some other web page. But I did not find some concrete difference between them, Can someone please explain the primary difference between DNS Spoofing and DNS Hijacking..
Answer: One way of explaining the primary difference between DNS Spoofing and DNS Hijacking is given by this site as:

While DNS spoofing is often confused with DNS hijacking as both happen at the local system level, they are two different types of DNS attacks.
Most of the time, DNS spoofing or cache poisoning just involves overwriting your local DNS cache values with fake ones so you can be redirected to a malicious website.
On the other hand, DNS hijacking (also known as DNS redirection) often involves malware infections in order to hijack this important system service. In this case, the malware hosted on the local computer can alter the TCP/IP configurations so they can point to a malicious DNS server, one that will eventually redirect the traffic to a phishing website.

So, DNS spoofing is where some malware or something else changes values in your local DNS cache (on your PC, for example), with fake values so you would query and go to the wrong destination.
DNS hijacking, on the other hand, is not so much about attacking your local DNS cache, but something else like the TCP/IP configurations so your PC's pointer to DNS is diverted to a malicious DNS server that could redirect traffic to a malicious website.
Comment: @auspiciou99 Thanks for answering, I got some clearance.
Comment: @AtulKumar No problem. If any of the answers helped, you could accept (click the check mark button).
Answer: DNS Spoofing is a DNS attack that changes DNS records returned to a querier
DNS Hijacking is a DNS attack that tricks the end user into thinking they are communicating with a legitimate domain name.


Can a water-damaged OBD2 scanner damage a vehicle?

Question: I have a harbor freight OBD2 scanner which was left out in the rain. I have shaken it out and dried it thoroughly. Assuming it still works at all, is there any way I could damage my car by using it to scan codes? It was only 60 dollars so I can throw it away if I need to but I'd rather try to use it if there's no damage that could occur from shorted contacts.
Comment: Describe "dried it thoroughly".
Comment: There was water on the inside. Now it is completely dry, but possibly corroded. I haven't opened it up.
Comment: Dear Mister Ford: open up the scanner then clean any white deposits (and anything else) with rubbing alcohol and a cotton swab. Let it fully dry, then re-assemble. As a precaution you could test it with a lesser vehicle before trying it on your Mighty Ford.
Answer: Since there is essentially no limit on the damage caused to the device in your question, the answer is yes it's conceivable that it could damage the vehicle.
Is it likely?  Probably not and I'll note that OBD2 circuitry is designed to be resilient but it's not implausible.


formatted tab 3 10.1 and cant install android from twrp

Question: got a problem with my samsung tab3 10.1 (5200), installed twrp and rooted the device and after that i formatted it in twrp to install a fresh android on an empty tablet. But install couldn't work , the installer couldn't make directories data and others so the install did not work ( took about 2 minutes) but at the end it says succesfull.
It cant boot past samsung logo because i think nothing really installed.
Anyone has an idea to try and install in another way ?
I'm trying to instal cwm now but says md5 hash invalid and same with the twrp file which is on the device.
Answer: already found the problem guys, after the format  it sayd you best reboot the bootloader  so i did that and then it could read and write, it's up and running without the latest offcial update that crashed a lot.
rooted and deodexed whatever that means.
grtz


What's the deal with the saarthal door

Question: I need the combination for it and can't find it any where. I have looked everywhere I can think of.
Comment: You better find it out, it won't be the first pillar puzzle you'll encounter in skyrim. :3
Comment: If you didn't look at The Elder Scrolls Wiki (linked in the answer), then you didn't look anywhere, much less everywhere.
Comment: [here](http://elderscrolls.wikia.com/wiki/Under_Saarthal)
Comment: I don't think this is a duplicate. This one is asking what the combination is. That one starts already knowing the combination, but is having trouble inputting it correctly. The answers over there don't include the combination or general solution.
Answer: You can find the answer here

Pillar Puzzle 1
After several more rooms and traps, there will be a door on the second
  floor near a broken coffin. Beyond there is a puzzle with six
  different movable pillars. The correct position for each pillar is
  shown on the wall directly behind and above them. This fact could
  easily be missed if the Dragonborn were not up close to the pillars.
  The Candlelight spell (or Night Eye) makes them easier to see. Once
  the pillars are properly set, the lever can be activated to open the
  gate. In the next room there are two wooden ramps. As the Dragonborn
  nears the top of either one, a Draugr Deathlord, Draugr Wight or
  Draugr Scourge (level dependent) arise. An effective tactic would be
  to lure the draugr back to the pillar puzzle room and shut the gate.
  The Dragonborn would then be able to shoot arrows at the enemy
  whenever it appears from around the corner. Alternatively, a high
  Sneak skill and a potion of invisibility could be combined to sneak
  through the door near the top of the ramp, and close it. Provided the
  Dragonborn were quiet, the draugr would almost certainly remain
  unaware. There is a chest and other items to loot here. Beyond an iron
  door, there are two rune traps to pass. Activating either trap using a
  shout or magic will make noise and attract the draugr, while walking
  over the traps will not. The first rune trap can be easily avoided by
  walking around it, while second rune trap in the doorway can be jumped
  over without taking any damage. Passing over the second trap means the
  draugr is ultimately evaded.

and

Pillar Puzzle 2
Solution spinning puzzle pillar There are four pillars that give you
  the solution to the spinning puzzle pillars ahead. The second pillar
  on the left should be turned to whale first (because it turns the
  other three with it.) Then, the first pillar on the left should be
  turned to snake (that will turn the two on the right.) Next, the
  second pillar on the right should be turned to eagle (that one will
  turn the last one.) And finally, the first one on the right should be
  turned to whale.

Took me 5 minutes to find this on google.

What's the deal with the saarthal door


The provider did not return a ProviderManifestToken string when attempting to connect to Azure SQL

Question: I am connecting to Windows Azure SQL and I get the error The provider did not return a ProviderManifestToken string. This used to work until some thing I am unaware of got changed. I used the default setup when the web application was created by the VS2013 wizard.
I do use entity framework also but I have a different connection string and DBContext for that.
The connection string is DefaultConnection shown below.

"DefaultConnection" connectionString="data
  source=tcp:lzol9w71f5.database.windows.net,1433;Database=Eye-Analytics;User
  ID=Eye-Analytics@lzol9w71f5;Password=[not
  displayed];Trusted_Connection=False;Encrypt=True;Connection
  Timeout=30;" providerName="System.Data.SqlClient"

Line 48:             if (ModelState.IsValid) Line 49:             {
  Line 50:                 var user = await
  UserManager.FindAsync(model.UserName, model.Password); Line 51:
  if (user != null) Line 52:                 {
Source File:
  c:\Users\grbrand\Documents\Workspaces\EA-Cloud\Eye-Analytics-Azure-Cloud-WebRole\Controllers\AccountController.cs
  Line: 50
[ProviderIncompatibleException: The provider did not return a
  ProviderManifestToken string.]
  System.Data.Entity.Core.Common.DbProviderServices.GetProviderManifestToken(DbConnection
  connection) +558
  System.Data.Entity.Utilities.DbProviderServicesExtensions.GetProviderManifestTokenChecked(DbProviderServices
  providerServices, DbConnection connection) +94
[ProviderIncompatibleException: An error occurred while getting
  provider information from the database. This can be caused by Entity
  Framework using an incorrect connection string. Check the inner
  exceptions for details and ensure that the connection string is
  correct.]
  System.Data.Entity.Utilities.DbProviderServicesExtensions.GetProviderManifestTokenChecked(DbProviderServices
  providerServices, DbConnection connection) +358
Comment: possible duplicate [link](http://stackoverflow.com/questions/11545583/the-provider-did-not-return-a-providermanifesttoken-string)
Answer: Check if the IP of the machine from which you are trying to access the SQL Azure DB is white listed. You can do this from the Azure management portal.


Why are shields often not visible in Deep Space Nine battles?

Question: In all the Deep Space Nine battles none of the ships appear to have shields, when they are hit by weapons fire the shield bubble is not visible. Why don't they show the shields?
Comment: If your example is "just go watch 7 seasons of a TV show", then I'm warming up my downvote. I'm not asking for every example. I want, at least, 1 specific, crystal-clear example.
Comment: Can you provide any specific examples that can easily demonstrate what it is you are asking about? Some vague references to "that one time when the Klingons attacked DS9" is not very helpful.
Comment: No, it did not. Do you have a video, picture, or direct reference (link) that you can edit into your question that clearly demonstrates this occurring in a specific situation? Because right now, as your question currently exists, I'd need to only provide one example of a shield bubble to challenge the accuracy of your question. I'm trying to give you the benefit of the doubt and improve your question with a clear demonstration of what you are referring to.
Comment: https://www.youtube.com/watch?v=EDLjtp2Ummw - Pretty much all the ship classes demonstrate shielding of one sort or another. The Cardassian ships seems to have hull-hugging shields whereas the Federation's seem to be more bubble-shaped. Where you see them being hit directly on the hull. it's usually when the enemy's firepower has instantly overmatched the shields
Comment: Do you have examples?
Comment: I could be wrong, but I believe they did show the shield on a few rare occasions.
Comment: When the Klingons attacked ds9, when the dominion attacked ds9, the first battle at the Chin'toka system, the second battle of the Chin'toka system, the battle at cardassia prime
Comment: @MarkRogers yeah they did at rare times, when the cardasian ship crashed into ds9 during the dominion attack on ds9 it actually had a shield bubble one of the rare occasions
Comment: Well it's pretty much a visible thing throughout ds9 compared to voyager and TNG where the ships get hit by weapons fire and there's an obvious shield bubble
Comment: That help you out
Comment: I don't know how to do that, go to you tube Type in ds9 battles see it for your self
Answer: This is a question that's bothered me for nearly 20 years now. Good on you for asking. I see a lot of attempts to explain the 'no shields' phenomenon rationally, but honestly there isn't a 'rational' in-lore explanation for it. It comes down to ease of storytelling.
Throughout the rest of the Star Trek universe contemporary with DS9 (i.e. TNG and VOY), visible (on impact, anyway) shield bubbles are ubiquitous, and generally it takes more than a single photon or quantum torpedo to destroy any warship from a major faction (Klingon, Romulan, etc.) unless said ship's shields are down. Phasers definitely couldn't one-shot a Klingon Bird-of-Prey (though because of size/strength inconsistencies and variants it's hard to tell what's what with those...), let alone take down its shields with a single hit. However, Star Trek writers are notoriously bad at maintaining consistency in their lore, which many times results in story-driven combat mechanics doing whatever the plot demands, rather than the plot giving any consideration to previously established rules of the universe.
If the large fights in DS9's dominion war were true to the way STS combat had been portrayed elsewhere, it would have taken significantly longer, with ships having to dance around as they whittle down each other's shields. The main problem the staff ran into, I think, was likely the need to portray large-scale battles within the allotted screen time in a way that would convey the action and excitement of the moment. A decision was probably made that more explosions = more excitement = better ratings, so any rank-and-file enemy fodder ships and 'redshirt' ally vessels were shown, for the most part, without shields for convenience, while any ships with main characters aboard (or that were of particular plot importance for a given episode(s)) were promoted to 'hero' status with the normal shield bubble (a.k.a. plot armor).
This is all apart from the argument concerning whether the shields should be visible as a whole or in part, or what shape or form they take -- I believe that's an entirely different discussion from what's being asked, and as such have sought to address the original question concerning their presence (or lack thereof) in the major combat during DS9's dominion war era.
Answer: Basically: as shield tech as explained in several places shield is actually not a bubble, but a layer close to the hull.
On the other hand the shield bubble is so often depicted in various movies/shows/etc that it is unclear exactly how do they work...
For sure DS9 for the most part explained away the lack of shields as "Dominion advantage". In case of battles though... this is plot requirement. It would be hard to show any battle in such short scenes they had the time for in sufficiently "carnage-y" terms. So they made them gone in bigger battles.
Also, for quite a long time DS9 itself had "barely working" defenses, including weakened shields. Unlike most starbases encountered throughout, DS9 is not... compact design, so it naturally requires way more emitters in total, which again makes them less effective. Which shows time and time again.
And for last - the whole bubble should not be visible, as it is created by multiple independent shield emitters, so it should show only parts hit.
Comment: Except that if you look at the video link in my comments, you can see the full shield bubble on DS9 on very many occasions
Comment: @Richard - Exactly. As is mentioned in the answer: "On the other hand the shield bubble is so often depicted in various movies/shows/etc that it is unclear exactly how do they work..." It is very frustrating.


Will reducing the number of explanatory variables guarantee an increase in training error?

Question: It is known that increasing the complexity of a regression or classification model reduces the training error ( see e.g. Elements of Statistical Learning Chapter 2 ).
My question is whether the converse of this is guaranteed to be true?
Does reducing the number of explanatory variables guarantee an increase in training error?
This will have practical implications for model building, i.e. if the training error is not acceptable with $k$ explanatory variables, then it is pointless looking for a better model with $<k$ explanatory variables.
At first thought it seems 'obvious' it must be true but are there any situations where it might not be true? For example if one thinks of collinearity in the predictors, which if present reduces their accuracy, it raises the question if removing some of them to
eliminate the collinearity, then with increased accuracy of the coefficients it may lead to reduced training error? I suspect that this cannot be true but I do not know how to explain it convincingly.
Answer: "It is known that increasing the complexity of a regression or classification model reduces the training error". So... it is trivial!
Assume model A is more complex than model B. Then A shows less training error than B
Now assume instead A is simpler than B. Therefore B is more complex than A. We conclude that shows less training error than B
Comment: There's something missing from your last sentence.  Also, I wonder if you accidentally switched the letters there?


Rank of fundamental groups of open subsets.

Question: Let $X$ be an open connected subset of the real plane. Then it is known that $\pi_1(X)$ is a free group. Is there a useful formula for the rank of $\pi_1(X)$? I suspect that the rank should be $b-1$, where $b$ is the number of boundary components. is this true? (i suspect that $X$ is homootopy equivalent to a bouqet of cicles.
Comment: The fundamental group of any open subset of the plane is countable; take $X$ to be the complement of the cantor set for a counterexample to your conjecture. If the rank is finite, I think I can prove you're correct.
Comment: Hey Peter, welcome to math.se. I edited your question since 'algebraic groups' means something different than the content of your question (they are groups in algebraic geometry). I've edited your tags accordingly. Best of luck!
Comment: What does "boundary components" mean for an open subset in the plane? Your suspicion is correct: this follows from the uniformization theorem and the fact that $K(\pi,1)$s are unique up to (weak) homotopy equivalence.
Comment: @AlexYoucis oups, yeah I wanted the tag "algebraic topology". I must have been a misclick. Mike what I mean is the number of connected components of $\partial X\subset\mathbb{R}^2$. I have come to think of this because it is known that for (bounded) $X$ we have $X$ simply-connected iff $b=1$.
Comment: @MikeMiller Strangely I cannot find this statement elsewhere on the internet. But I think it is very plausible
Comment: @Peter: I'll write up my proof tonight or tomorrow for you.
Comment: @MikeMiller: Thanks, i look forward to it.
Answer: There is a couple of related questions: $H_2$ and $\pi_1$ of open subsets of $\mathbb{R}^2$ and fundamental groups of open subsets of the plane concerning the fact that the fundamental group of each open connected planar set is free of countable (possibly finite) rank, since $R^2-X$ is homotopy equivalent to a connected locally finite graph. If you want to compute rank of the fundamental group, the easiest thing to do is to use homology. Rank of $H_1(X)$ equals the rank of $\pi_1(X)$. On the other hand, by the Alexander duality, $H_1(X)\cong \check{\tilde{H}}^0(R^2 -X)$ (the reduced Chech cohomology). In the case when the complement to $X$ is reasonably nice (say, a finite CW complex), then indeed, the above formula shows that the rank of $\pi_1(X)$ is the number of complementary components minus 1.
Comment: I don't think you need the complement to be nice. 0th Cech cohomology of a Hausdorff space counts components, so this is all you need.
Comment: @MikeMiller: Quasicomponents, see http://math.stackexchange.com/questions/317882/is-there-a-homology-theory-that-counts-connected-components-of-a-space
Comment: I meant to say compact Hausdorff, where quasicomponents and components agree; see the nLab. In any case if we're doing our Alexander duality in the sphere instead of $\Bbb R^2$ the complement of $X$ is closed hence compact hence we're ok.
Answer: Studiosus's answer explains how to get the result you're looking for. This post is orthogonal: it's about how to understand the homeomorphism type of connected open subsets of the plane.
Every noncompact manifold without boundary has an exhaustion by compact submanifolds: $M = \bigcup M_i$, where $M_1 \subset M_{2} \subset \dots$ are compact manifolds contained in the interior of the next. (You can prove this by first demonstrating the existence of a proper Morse function on $M$, but it might be best to just take it for granted.)
So let $M$ be your open subset of $\Bbb R^2$. What can $M_0$ be? By the classification of compact surfaces, and the fact that no surface of positive genus (with boundary or not) can embed in $\Bbb R^2$, it has to be $S^2$ with a few open discs deleted. The same is true for all of the $M_{i+1} \setminus \text{int } M_i$.
First, a quick calculation: by the Mayer-Vietoris sequence you can see that $\chi(M_{i+1}) = \chi(M_i) + \chi(M_{i+1} \setminus \text{int }M_i).$ (This is essentially because $\chi(S^1) = 0$.)
Let $\Sigma_{0,n}$ be $S^2$ minus $n$ open discs. Then $\chi(\Sigma_{0,n}) = 2-n$. The only $\Sigma_{0,n}$ with positive Euler characteristic and with boundary are the disc $\Sigma_{0,1}$ and the annulus $\Sigma_{0,2}$. Gluing on a disc reduces the number of boundary components by one, and gluing on an annulus doesn't change the homeomorphism type of your manifold. Thus, putting together everything we've said above, because $\chi(M) = 1 - \text{rank}(\pi_1)$ if $\text{rank}(\pi_1)$ is finite, $H_k(M) = \lim_{i \to \infty} H_k(M_i)$, and our assumption that $\text{rank}(\pi_1)$ was finite, we see that the homeomorphism type of an open connected subset of the plane with $\pi_1(M)$ of finite rank is a sphere punctured $\text{rank } \pi_1(M)+1$ times. That is, it's homeomorphic to $\Bbb R^2$ with $\text{rank } \pi_1(M)$ points deleted.


Markup on COGS or investment?

Question: I'm reading the Innovator's Dilemma by Clayton Christensen and came across the following text and table:
Discounters didn't accept lower profits than those of traditional retailers, however; they just earned their profits through a different formula. In the simplest terms, retailers cover their costs through the gross margin, or markup, they charge over the cost of the merchandise they sell. Traditional department stores historically marked merchandise up by 40 percent and turned their inventory over four times in a year - that is, they earned 40 percent on the amount they invested in inventory, four times during the year, for a total return on inventory investment of 160 percent. ... Discount retailers earned a return on inventory investment similar to that of department stores, but through a different model: low gross margins and high inventory turns. Table 5.1 summarizes the three positions.

I think I get the point: you can cover the costs associated with running a store either by having higher margins or by having a higher inventory turnover. If your inventory turnover is low, the inventory that you sell needs to have a higher gross margin to cover the costs of holding that inventory vs if your inventory turnover is high. However, the explanation in this book confuses me as it appears to use inconsistent definitions.
In the text "markup" is defined as the gross margin charged over the cost of the merchandise that is sold. If traditional department stores historically marked merchandise up by 40 percent then that would mean that if they bought \$100 worth of product they would sell it for \$140. If this is the correct interpretation of the definition then the ROI of 160% makes no sense. Suppose that a full inventory is valued at \$100. If they ... turned their inventory over four times in a year then that would mean that they would sell an entire inventory four times, meaning that they would incur costs of \$400 and achieve a revenue of \$560. ROI = (\$560 - \$400) / \$400 = 40% and not 160%.
The only way in which this works is if the markup is calculated with respect to the costs associated with holding a particular inventory for an entire year (like cost of space, administrative costs, etc). If the markup is relative to the total costs that you would incur from running the stores and not costs of goods sold then the 160% ROI makes sense. However in this statement the 40% markup is clearly defined as the margin charged over the cost of merchandise they sell which I would interpret as COGS.
Answer: The idea is that I only need \$100, not \$400, since I recoup the \$100 with each sale.

I have \$100. This is my capital, I will only use this in the business for a year.
I buy one set of goods for \$100, I have \$0 left.
I sell the goods for \$140.
I buy a new set of goods for \$100, I have \$40 left.
I sell the goods for \$140.
I buy a new set of goods for \$100, I have \$80 left.
I sell the goods for \$140.
I buy a new set of goods for \$100, I have \$120 left.
I sell the goods for \$140.
I now have \$260, and I started out with \$100, thus the ROI is 160%.

Markup on COGS or investment?


synchronizing separate folders when new documents are added

Question: I would like the documents in one folder on a sharepoint page to contain the same documents as that of another page of the same site. So when one page has updated information it synchronizes with the other.
Answer: If I understand what you need you have a single document library in a site.
When a new item is added in that document library you need the document to be copied to another folder within the same doc. library don't you?
If this is the case add an event receiver to the document library with this code:
<code>public class CustomEventReceiver: SPItemEventReceiver
{
    public override void ItemAdded(SPItemEventProperties properties)
    {
        base.ItemAdded(properties);

        SPListItem item = properties.ListItem;
        item.File.CopyTo(item.ParentList.RootFolder.Name + "/Dest Folder Path/" + item.File.Name, true);
    }
}
</code>
Regards


Does Codename one support Split Pane UI component?

Question: I take a look into all classes which are supported by Codename One and don't see any class which have spell like "Split". Does Codename One support a UI component like Java Swing Split Pane -https://docs.oracle.com/javase/tutorial/uiswing/components/splitpane.html?
Answer: That UI element doesn't make much sense in a touch device or mobile phone so it was never implemented. There are many potential replacements for common use cases of the split pane.
E.g. we use the side menu of the toolbar to place collapsable elements we'd like to work with.
You can probably implement this UX by adding 3 components to a TableLayout container with varying width/height constraints to allow the split pane look (the middle component would be the split). E.g. the middle component can be a button styled as the split where you override the pointerDragged() callback to remove and re-add the cells withmodify the new width constraint and then revalidate().


Not able to approve a redaction

Question: A redaction was carried out by another mod to remove an email address, but somehow something has gone awry, and although it shows in my mod review queue, when I try and approve the action, I get a "No changes found to redact" message.
Comment: Link to the review queue, please?
Comment: http://sound.stackexchange.com/admin/dashboard
Answer: After a fair bit of thinking about this, I've come to the conclusion that the difficulties here arise from the confluence of several issues:

Folks tend to come in with an unfortunate mental model of how redactions (and by extension, revisions) work here.
No error or warning when you propose a redaction that will do nothing.
The automatic redaction suggestion tool that pops up after a different revision has already been redacted (or a redaction proposed for a different revision) would cheerfully let you submit a do-nothing redaction even when it already knew that it hadn't suggested any changes.

So here's what I've done to address them:

Guidance on the redact tool itself.

Block submission of redactions that do nothing
Block the system from suggesting automatic redactions that will do nothing.

Also made the page responsive while I was mucking about with it. So, lemme know if I broke anything there...
Comment: ... *starts wondering what's wrong with [this revision](https://meta.stackexchange.com/revisions/322013/2)*
Answer: This has happened to me too.  It kind of makes sense that you can't approve what's not there -- there's nothing to approve.  When I saw this I rejected the redaction (the only way to clear the flag/notification) and talked with the other moderator about what we needed to do.
IMO the bug isn't that you can't click the "approve" button; it's that the system knows it's going to reject the redaction and yet the redaction exists.  The best fix for this problem -- best for the approving mod and best for the redacting mod, because redactions are confusing -- would be to reject the redaction attempt.  The moderator attempting to make a no-op redaction should get an error message, instead of seeing something "work" that doesn't really, only to learn the truth when a second moderator has tried to act on it.  If we have enough information to reject it at approval time, we have enough information to reject it at creation time.
Comment: But Rory clearly said "remove an email address" - so why nothing to approve?
Comment: @ShadowWizard the redaction *comment* says "remove email", but it appears that the redaction didn't actually do that.  The redaction interface is confusing; several moderators have made the mistake of thinking they're redacting a *revision* when what they really need to do is "edit in redact mode" (so to speak).  I suspect that's what happened here.
Comment: In this case it is reacting the original rev after I applied an edit to remove the email. The current rev is rev 2. I started a redaction on rev 1.  So what you are saying is that it reacts all history prior to a rev instead of just one part of the Rev history? So I'd react rev 2 making it the new rev 1?  That is confusing.
Comment: @AJHenderson it doesn't remove the entire revision; it removes the part you redact (by editing it out) from the revision that's shown in the history.  Yeah, confusing.
Comment: So really it is "redact this change from previous revisions". Got it.
Comment: Might be worth changing to a change request for better wording atleast. Nothing on either page remotely seems to indicate the actual behavior.
Answer: We're seeing this on Ask Different with one moderator two times a couple days apart.

https://apple.stackexchange.com/admin/dashboard?flagtype=modrevisionredactionapproval
https://apple.stackexchange.com/revisions/348560/1
https://apple.stackexchange.com/revisions/348560/2

I'll reject and queue it up for the other mod to approve. The first moderator did not get a message that there was no diff - it went through to the queue, but the second cannot approve it.

So the first redaction I made was approvable with a diff. Now the second change should get re-evaluated to provide a proper "diff" and be approvable. Doing to be a bit of a dance to change once - approve - then change the second - approve.
Comment: So far, I'm able to queue up changes and have others approve them, what's broken is another moderator can't queue a change that's approvable by the rest of us.

Not able to approve a redaction


How to setup Sony A58 for clear movie recording?

Question: I have a Sony A58 camera and 18-55mm lens. I did some recordings with AF (Auto-Focus). The frames are a bit blurry. They are actually clear, but it seems to me like the camera is taking two shots and then overlaying these to images to form a frame.
When playing the video this comes off as the video is blurred but when I pause the video, you can clearly see the two images in one frame.
I tried different different shutter speeds with MF with no change in the output.
Answer: The solution is to change the video file format in the Menu:

From AVCHD to MP4.


Setting up a recovery email

Question: I moved to another city and changed internet providers.
My old email address is associated with my old internet provider (Frontier).  The people at Frontier said they will continue to keep this email address active for one year. After that I guess emails will no longer come thru via the Frontier address.
I bought a new computer (a Chromebook) and established a new Gmail address. But in configuring the Gmail account sign in information they ask for a "recovery" phone number and also a "recovery" email address (it can't be the Gmail address I just established). I gave my cell phone number for recovery, but if I give the old Frontier email address it will no longer be functional after a few more months.
I intend to use my new Gmail address for all of my usual email needs from now on. Oh yeah, I'm retired so I don't have a work email address.
So should I establish a new email address somewhere else, like with Yahoo!?
Comment: Do you have a friend you trust? A significant other? Any reason you can't create a Yahoo! or Outlook.com address?
Answer: Set up a 2nd email address to use as your recovery email - it can be with Yahoo! etc., or even a 2nd Gmail address.
Alternatively, don't give any recovery email and just rely on the phone being able to receive text messages.
The one thing you should not do under any circumstances is to give an email address that you might not have access to in future (eg one from your former ISP or even your current job).
Answer: Personally I use another email service provider as the recovery email because I'm a web developer and it's natural for me to have more than one, but in your case it might be cumbersome to create and maintain several email accounts.
You might want to consider adding the email of your significant other as your recovery email. In my case I've added my email as the recovery email for my parents and some friends because the necessary trust exists.

Setting up a recovery email


How to set up shader materials with main node Principal BSDF

Question: I have issue with exporting shaders on blender model. I need to export model with shaders in GLTF . The problem is that shader materials are not exporting - only the main color of Principal BSDF node. I've got an idea from google answers, that shader materials can be exported in GLTF only if the main node will be Pricipal BSDF, that is going directly though material output node. But now i have shader mixer, that goes though material output. Is there any way to change order and plug all shaders to Principal BSDF, that will be plugged directly in material output?
Comment: For those of us who don't understand the language, what is the other shader you are using before the mix shader node?
Comment: @susu that is Emission node. Johny, Principled has Emission input socket itself. So try to plug emission map right into that one, move emission+mix shaders out of the way leaving only principled > output and export. That could do it if GLTF indeed works as you mentioned
Comment: @MrZak there is Color ramp node as well, and it is plugged into mix shader, how can i make it also plugged into Principal?
Comment: ColorRamp is the only one you'd be plugging since it has the emission map, mix shader is irrelevant to this. I meant to plug the output of the ColorRamp (the end of the chain with emission color map) into Emission socket of Principled, then try to export. If GLTF supports that it should be exported
Answer: The glTF format has a different material model from Blender, and does not support arbitrary nodes.  It uses a principled PBR model powered by textures and uniforms.
For some materials, it's possible to use the Blender Cycles "Bake" panel to render a complex node graph to a texture atlas.  This allows such a material to be used even on lighter-weight mobile rendering clients that wouldn't normally support arbitrarily large numbers of shading nodes.
For complete usage instructions, see the Blender Manual on glTF.


Can't Access internet through laptop wifi in my xperia u

Question: I was able to create a hotspot through Connectify software in my laptop, but when i connect my phone to it ,it shows i am connected but i am not able to access the internet. Is there any option that should be enabled on phone?
Answer: Here's a useful post from XDA-Developers website: refer to this link.
Configuring laptop/pc

First, you need to create an adhoc network:
Open network and sharing center on control panel
click on manage wireless networks then add , a windows is shown, select create an ad hoc network click on next then input a network name(for example name it 015) then choose the security type (you can select either open or WEP) then check the box save this network
Now reopen network and sharing center on control panel then change adapter settings.
Right click on your internet network and click on properties then select the tab sharing and check the "allow other network users to connect through this computer's internet connection" (choose wireless network, if multiple networks are shown).
check also the "allow other network users to control or disable the shared internet connection"
next click on setting and check all items..
Right click on wireless network connection and double click on "internet protocol version 4(tcp/ipv4)"
on the new window select use the following ip address 192.168.137.1
and subnet mask 255.255.255.0
now activate your new adhoc network (if not already) go to the network icon next to the clock and select it and connect.
Congratulation your laptop/pc is now configured .

Configuring the android device :
Now, we will configure the android device to make it able to access this new adhoc network

Go to setting on the menu of your device
then wireless and networks then wi-fi settings then activate wi-fi .
Right click and choose advanced. Check the "Use static IP"and fill in :

ip address: 192.168.137.5 (for example)
Gateway : 192.168.137.1
Netmask : 255.255.255.0
DNS 1: 192.168.137.1
DNS 2 : 22.214.171.124

right click and save.
Finally, click on the adhoc network (and input password if you use WEP security) then connect.
If you encounter problems connecting ,try to disable then to reactivate wifi, else reboot your android device.
Comment: i tried all ur steps but there is no option like "use static ip" in my phone's advanced wifi setting  . There is abother option in my phone call"Auto IP Support-Assign Auto IP adress if DHCP fails"..any  idea?
Answer: after the successfully connected internet to your laptop install and run this software "Virtual Router Plus" and shared connected connection then search for the wifi in any device u can access it by entering correct key.
Comment: ..i tried befor but not warking.Means cant access internet. ty
Answer: You need administrator for this.

Start your hotspot using "Connectify" or "Virtual Router" (which is better IMO as it doesn't shutdown all 30 min like Connectify Free Version)
Go to network and sharing center on the control panel on your laptop and press on "change adapter settings"
Right-Click the adapter you are using to connect to the internet and press on the "sharing"-tab.
Check "Allow other Users in the Network to use this connection as internet connection"
Select your hotspot network and press okay.
Restart your hotspot and connect your phone.

You're good to go.


Extjs4, aligning a field right in an anchor layout

Question: I want to place my fields, in an anchor layout, in the right. When I add a field with anchor: '50%' in this layout, it will be displayed like this:

How can I place it in the right.
Answer: This anchor layout is not meant for this kind of layout.  Use a column or table layout instead.
The only way you could come close to achieving what you want with the anchor layout is to use a pixel based offset, which doesn't make sense since you are using percentages for the width of the fields.


What is the most efficient way to make Concrete from Concrete Powder?

Question: I have an entire chest full of Concrete Powder that I want to turn into normal Concrete.
What is the most efficient way to turn the Powder into Concrete?
Answer: As pointed out in a comment, this answer does not work for MCBE. It was written while the question had both tags.
The easiest way is to put a pickaxe into your main hand, concrete powder into your offhand and hold both mouse buttons ("use" and "break" actions) while aiming next to water.
The issue with this is that the items fly out in all directions, because you place a new block where they appear, accelerating them outwards. The best solution to this is to put hoppers everywhere around you, wherever items can land.
You will also eventually run out of concrete powder. To keep going, you need to dispense new concrete powder to your player (if you want to do it AFK). Either you find the perfect rythm for that (unlikely, especially with client lag) or you need to pick up excess powder with a hopper and direct it back into the dispenser. To make sure that the powder and concrete blocks don't end up in the same hopper, you can separate player and placement spot with a wall that has just a small hole in it to click through, but not big enough that items can fly through. Usually slabs should work fine, but if you want to be absolutely 100% sure, you need to use snow layers.
Answer: Another way to achieve this without the need for mining the concrete, would be to make use of the fact, that TNT now drops all the blown up blocks.
So you could insert the powder into a piston feed tape, which is next to water => powder gets converted to concrete.
The stream of concrete get blown up by TNT after that. With a simple water stream collection system in the end you can build something that works like a charm.
If you search for TNT blast chamber you will most likely find something that works wonders.
Disclaimer: Many of the designs out there make use of a bug [Java version 1.15] in the game to duplicate the TNT block that is used to blow everything up. I don't think that this will work for bedrock, but if you have enough gun powder you should be able to achieve the same result with normal TNT


Force a control to DataBind from callback function executed in modal

Question: I am working on a Kentico Webforms project, my requirement is to provide a modal window that allows us to update a value within a parent control.
The parent control sets a static callback function that is executed from the modal when a selection is made. The call back executes within the modal form passing back and setting the correct value. I call DataBind() on the updated control but the value is not updated and if I set up a DataBinding callback it is not executed
//Static container for call back reference
public static class CallbackContainer
{
    public static Action<string> Callback { get; set; }
}

Parent control
protected override void OnPreRender(EventArgs e)
{
    //Set callback
    CallbackContainer.Callback = id => Value = id;

    txtOrgName.DataBinding += (sender, args) =>
    {
        //Never executes
        Debugger.Break();
    };
}

public override object Value
{
    get
    {
        return txtOrgName.Text;
    }
    set
    {
        txtOrgName.Text = value.ToString();
        txtOrgName.DataBind();

        Page.DataBind();
        DataBind();
    }
}

Modal form
//Executed on selection
protected void userGrid_OnAction(string actionName, object actionArgument)
{
    //Callback passing selected value
    CallbackContainer.Callback(actionArgument.ToString());
}

Any ideas??
Comment: Please provide also the aspx markup.
Answer: If I understand your code correctly, the callback seems to have closure on the control instance from the previous request at the time it is called.
userGrid_OnAction is called within the post actions phase of the page life-cycle, which is just after the Load and before PreRender so the execution takes place in this order:
Parent1.Load
Child1.Load
Parent1.PreRender
- CallbackContainer.Callback = set Parent1.Value
Child1.PreRender

Parent2.Load
Child2.Load
Child2.userGrid_OnAction
- set Parent1.Value
Parent2.PreRender
- CallbackContainer.Callback = set Parent2.Value
Child2.PreRender

While Parent1 and Parent2 are objects from different requests
You can start with moving the callback assignment from PreRender to OnLoad, but the code still won't be thread safe as you will be sharing one static state for all the requests to the same page and they may collide.
This is how the life cycle will look like after that change:
Parent2.Load
- CallbackContainer.Callback = set Parent2.Value
Child2.Load
Child2.userGrid_OnAction
- set Parent2.Value
Parent2.PreRender
Child2.PreRender

But the requests may happen also this way:
Parent2.Load
- CallbackContainer.Callback = set Parent2.Value
Parent1.Load
- CallbackContainer.Callback = set Parent1.Value
Child1.Load
Child2.Load
Child2.userGrid_OnAction
- set Parent1.Value
Parent2.PreRender
Child2.PreRender
Parent1.PreRender
Child1.PreRender

To make that property request-specific so that individual requests don't collide you can use code similar to this:
public static class CallbackContainer
{
    public static Action<string> Callback
    {
       get
       {
         return (Action<string>)HttpContext.Current.Items["CallbackContainer.Callback"];
       }
       set
       {
         HttpContext.Current.Items["CallbackContainer.Callback"] = value;
       }
    }
}


Get the default contact phone number

Question: When we dial a selected contact, the first phone number is always picked (unless another number has a default flag set in DB). How can someone get that first phone number? How are those numbers ordered?
Answer: You can define the default number yourself:

open the "contacts" / "people" app
tap the contact to view it
long-tap (i.e. tap-and-hold) the number you want to make the default, a pop-up will open
select "make default"
Comment: May also say "Make Primary". depends on Andriod version.

Get the default contact phone number


Fertilizing plumerias with homemade fertilizer

Question: Wondering if there is a combination of commonly found household items , e.eg. Food , oil, whatever, that can be used to fertilize plumerias
Comment: In general, if you doesn't have many (really many) plants, it is not practical to create most fertilizers. Food is often salty (no good for most of plants). For preparation items, it will be mostly vegetables, so low density). You can still find organic fertilizers (or just the correct soil type).
Answer: In short, no. Fertilisers are made with various formulations, the principal ones being Nitrogen, Phosphorus and Potassium, shown as NPK on containers of fertiliser. Plumeria (if you'd like to try to get it to flower) require a lot of phosphorus, and not too much nitrogen if they are growing in pots. Trying to get the formula right using, for instance, home made compost tea is very difficult, and certainly oils and foodstuffs will do nothing at all other than maybe kill your plant. Further information here https://www.gardeningknowhow.com/ornamental/flowers/plumeria/how-to-fertilize-plumeria.htm


Take a custom taxonomy value and save as a standard Product Tag

Question: I'm trying to find a way to take a custom taxonomy value, and add it as a tag to that same product.
Long story short: a third party CRM only respects woo native categories & tags, so we'd like to take three custom taxonomy values and save them as tags. For instance, if a product is a Ganni dress in UK size 10 and has a 'style profile' of Romantic, then the three custom tax values retrieved will be 'ganni', 'uk-10', and 'romantic'.  These should then be saved as standard tags.
Here's a stab at the 'product_brand' custom tax, which doesn't work. Can anyone please point me to where it's going wrong?
(This needs to happen any time a product is created or saved)
add_action( 'save_post', 'action_save_product_data', 20);
function action_save_product_data( $post_id ) {
    global $typenow;
    if ( 'product' === $typenow ) {

        $terms = wp_get_post_terms( $post_id, 'product_brand', array( 'fields' => 'all' ) );
                if ( $terms ) {
                    $prod_brand = $terms[0]->slug;
                }

        wp_set_object_terms( $post_id, $prod_brand, 'post_tag', true );
    }
}

Answer: Got it worked out, working code as follows:
function action_save_product_data( $post_id ) {
  if ( 'product' !== $post->post_type ) {
    $terms = wp_get_post_terms( $post_id, 'product_brand', array( 'fields' => 'all' ) );
    if ( $terms ) {
      $prod_brand = $terms[0]->slug;
      wp_set_object_terms( $post_id, $prod_brand, 'product_tag', true );
    }
  }
}