Converting Injection Molded STLs to printable STLs

Question: I bought a 3D printer kit a few years ago, and it's been working pretty well, the kit was made with injection molded parts. -- It's similar to a Huxley, and through the years, it's started to turn into a repstrap as I've repaired it with non-printed parts.
The parts are all open source and the STLs are provided by the maker, but they're optimized for injection molding, so instead of having flat surfaces, the surfaces usually have a lot of extra support going on -- here's an example of what I'm talking about:

Mind you, this is one of the simpler parts. -- But mostly I just want to clean these parts up -- make the edges flat by "filling in" these gaps (because: 1. it will print easier, 2. I can let my slicer handle the infill for me, etc.)
Currently, I've been using mostly TinkerCad and trying to make little rectangles and other shapes and boolean union them together to fill these gaps.  But this is a lot of work, trying to get it just right without covering up important gaps or leaving pockets in the middle of the part is very time consuming and error prone.
Additionally, I'd like to be able to make minor beveled edges so that the parts are easy to peel up. -- I currently do this with boolean subtractions of a bevel shape I made (again, in TinkerCad).
Is there any software out there that makes these options easier? -- What's the easiest way to fill in these gaps and add beveled edges? -- I'm hoping to spend no more than 10 to 15 minutes per part.  (Right now, it's hours.)
Comment: I am voting to close this question as primarily opinion-based. Although @fred_dot_u made a valiant attempt at answering it objectively, ultimately there are still too many valid answers (there are hundreds of CAD packages that can do what you ask) without a good way to distinguish which is "best".
Answer: Although the foundation of your question is aimed at getting an opinion, I find nothing wrong with that, as long as answers are provided with an equal foundation based on facts.
I'm a fan of Meshmixer (free) but it's not well suited for this project, in my belief (opinion) as it's primarily aimed at organic modeling. On the flip side of this point is the fact that you have a working STL from which to build. Meshmixer will enable you to extrude the portions that sit below the surface level and create a flat plane. You can also "bridge" the elevated portions into a plane, but only if you remove the lower panels first. Leaving them in place creates an unprintable model.
Of course, Meshmixer has its own learning curve.
Along the same train of thought, Blender (free) is suited for performing similar tasks, again aimed at organic models. Again, starting with your STL makes it less of a complication.
Unfortunately, in my opinion, Blender's learning curve is substantially steeper, as the program does many things unrelated to 3d printing. It has spectacular control over the model and if you are able to learn the necessary controls and sequences, there isn't anything you can't do with it.
Meshmixer is more intuitive than Blender and therefore easier to learn. You may also find it easier to find YouTube resources for Meshmixer actions than similarly for Blender, mostly because the phrasing of your search will be clearer with Meshmixer.
As an example, one would create face groups of your STL. Various segments would then turn colors. You select the depressed face group and say, "cheer up" then delete that group. Using the appropriate tool, which currently escapes my alleged mind, you'd then bridge those faces remaining after the delete. What was once a shallow pool becomes a flat contiguous surface.
I would recommend using Lynda.com tutorial material if you can find it. There is also a resource called Honeypoint which somewhat specializes in Meshmixer tutorials.
Not out of the question is to engage the free Fusion 360 program and use all those YouTube resources, among others, to import your STL and create extrusions and modifications you require. Our local library has an agreement with Lynda.com which provides free access to Lynda.com's tutorial library. Conveniently for me, it has a great collection for Fusion 360.
I've become so accustomed to manipulating models in the above software and other programs that I attempted to rotate your image to see the other side! If this is one of the simpler ones, you have quite a job ahead of you!
Be sure to use an STL printability checker program to ensure your resulting models are workable. Meshmixer has that feature built in and a couple online services will repair your model free. One service I attempted to use destroyed the model, while the Microsoft version did not, but created a .3MF format. That added one more step to get it reconverted to .STL, but the results justified the effort.
Good luck


What is the probability that in 3 rolls of a pair of six-sided dice, exactly one total of 7 is rolled?

Question: I tried to solve the exercise and it seems meaningful, but the problem is that in the book the result is $25/72$, while mine is $1/7776$. I don't know if maybe I didn't understand the problem, but by the text I understood that there are two dices rolled three times, and I have to calculate the probability to have 7 as result. Now, I could use the binomial probability density function, but I didn't know very well how to use the data I have (if someone can also explain me the resolution with this structure I'll thank him). By logic, throwing three times two dices, the total number of possibilities is 46'656, because I have $36^3$. Now, to have 7 as result and a dice must have at least 1 as value, the only possibility that I have to reach 7 is 11/11/12 (the first two dices are 1, the 3th and 4th 1, the 5th 1 and the 7th 2) and all the combination of this sequence:
11/11/12
11/11/21
11/21/11
11/12/11
21/11/11
12/11/11
Calculating the probability, I have $3* (1/36 * 1/36 * 2/36)$, and the probability of having 7 as result is $6/7776$
I don't know where I'm wrong.
Answer: To get the result you can start by calculating the probability of obtaining a sum of 7 when rolling two dices:
P(7)= 6/36 = 1/6
And then as you say its a binomial:
So it's combinatory of 1 in 3 times the probability of success to the power of 1 times probability of failure to the power of 2
So: (3!/1!*(3-1)!) * (1/6)^1 * (5/6)^2
Hope it makes everything clear
Comment: But I don't understand why I have to put 3 choose 1, because I know that 3 is the total and 1 is the success


jQuery ui loads before jQuery

Question: I have a rails project that uses the jquery-ui slider widget.
My problem is that the jquery-ui widgets only appear if I reload the page. The first time the page loads the widget doesn't appear. If I press f5, it does.
I think the problem that jquery-ui is loading before jquery, but I have it in the correct order in my application.js.
This happens in chrome and firefox too.
Thanks in advance for your answers and your time.
Comment: If the `
Comment: Indeed it's in the right order:
`

`
Comment: Have you checked for errors in the browser console?
Comment: ok, solved! The problem is that I was including several times the same javascript files. Thanks everyone!
Answer: ok, solved! The problem is that I was including several times the same javascript files. Thanks everyone!

jQuery ui loads before jQuery


Are log-linear models exponential models?

Question: What is usually referred to as "log-linear models"? Is a log-linear model an exponential model where the normalization constant is 1 (since its logarithm needs to be a linear function)? Or is there very little difference between the use of the two terms, and they are in fact interchangeable?
Answer: It is hard to say what is "usually referred to" without more context, as terminology is not well standardized across fields.
In the most common statistical context, I would say "log-linear model" refers to a Poisson GLM that is applied to a multi-way contingency table and presented in a special form.  This is the way Agresti uses the term in his Categorical Data Anaysis, for example (Google book search).  I have an R-based example of using a log-linear model here: $χ^2$ of multidimensional data.
Answer: They are different, but it's a bit ambiguous without extra context.
Log-linear models usually refer to an OLS linear model with logged response, or sometimes a GLM with a Normal family, log link function. The Normal distribution is in the exponential family.
If you actually have an exponential response,  you would use a GLM with Gamma family, but this typically uses the inverse link, not a log. Also in the exponential family.


Pubchem, InChI, SMILES, and uniqueness

Question:
PubChem compound 6140 is L-phenylalanine in its neutral (not zwitterionic) form.  According this PubChem, this molecule has the following SMILES and InChI indentifiers:

SMILES: C1=CC=C(C=C1)CC(C(=O)O)N
InChI: InChI=1S/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)/t8-/m0/s1

PubChem compound 6925665 is the zwitterionic form of L-phenylalanine (protonated amine and deprotonated carboxylate).  Pubchem has decided that this species should be called "(2S)-2-azaniumyl-3-phenylpropanoate".  The SMILES and InChI identifiers are:

SMILES: C1=CC=C(C=C1)CC(C(=O)[O-])[NH3+]
Inchi: InChI=1S/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)/t8-/m0/s1

Confusion.  My confusion is why these different compounds have different PubChem entries (CIDs), and different SMILES identifiers...but the same InChI structure.  The different SMILES identifiers each appear to reflect the respective structures displayed by PubChem, but the single InChI identifier given for both compounds seems to reflect only the neutral form.  I even put the InChI into rdkit and converted it back to InChI.  The result was the same and rdkit interpreted this InChI as the neutral (not zwitterionic) species.  What is the reason for this discrepancy between InChI duplicity yet structural uniqueness?

Here are some possibilities:

PubChem is in error.  They should change the InChI for the zwitterionic compound.  (If so , to what?)
PubChem is right but is using definitions of compound and CID that are different than mine.
I have some kind of fundamental misunderstanding of the purpose of InChI, which I had thought would uniquely specify a molecular structure.  But InChI is designed to handle ambiguities like zwitterion vs. neutral.
rdkit interprets InChIs weird.
Something else.
Comment: I know this discussion is long gone, but... I've faced a similar struggle. I needed to cluster all compounds having identical first three layers in standard InChI. I made a perl script to create these clusters. In case anyone is interested I can share it.
Comment: Please do share!  Also I think your answer will be deleted soon because it is not really an answer.  If you can comment (not answer)  to an existing answer or the original question with a link to the script, thank you!
Answer: Unfortunately Pubchem is right, the two structures have the same InChI string and key, since the protonation state is the same in the zwitterion and the neutral form. So the reason for the discrepancy is by design.
I also always thought, InChI was designed for distinguishing between these conformations, but it turns out to just be one of the limitations of the system. The issue is addressed in section 13.2 of the technical FAQ of the InChI trust:

The different protonation states of the same compound will have InChIKeys differing only by the protonation indicator (unless both states have a number of inserted/removed protons greater than 12; in this case the protonation flag will also be the same, 'A').
  This is exemplified below by standard InChIKeys as well as standard InChI strings for neutral, zwitterionic, anionic and cationic states of glycine (note that neutral and zwitterionic states do not differ in the total number of protons so they have the same standard InChI/InChIKey):
Comment: @Curt Yeah, i thought the same thing as you and to be frank it does not make any sense to me why it should be that way. Maybe they address this in the second version, but knowing IUPAC they'll take their time \*sigh\*.
Comment: @CurtF. Although the FAQ is still the same, there is a new version of InChI available. However, I doubt they address this issue, but you still might be interested.
Comment: Great answer.  I had no idea that InChI was designed this way.
Comment: Based on your link, it seems like specifying zwitterions and some tautomers might be possible with a non-standard InChI (`InChI=1/...` instead of `InChI=1S/...` that includes a fixed-hydrogen layer...if I figure it out I might post a separate answer, but I never would have known if not for your link so thanks again.
Answer: InChI is intended to ignore tautomeric forms. As Martin indicates this also means zwitterions are considered identical to the neutral form.
Unlike you and Martin, I'm not sure I see this as a bug, since predicting the most stable tautomer or zwitterion/neutral is a complicated issue.
If you want to keep track of zwitterions, I think SMILES is a better format, since you can specify exactly what you want as far as explicit hydrogens and charges. You'll need to stick to a particular toolkit to create a canonical ordering.
Moreover, there's a complicated relationship between CIDs and InChI / InChI keys.
There are other cases where PubChem will have separate records for compounds that might be "the same" under InChI.

Axial or non-traditional stereochemistry. For example hexihelicene (CID=98863) should have two enantiomers, but the InChI reflects no stereochemistry.
"Extra" stereo centers. PubChem takes depositions in the SD file format, which allows 2D stereochemistry in wedge/hash notation. If you take the actual 3D geometry, you might realize the wedge/hash were used for appearance, not for indicating a stereo center (i.e., multiple CIDs generate the same InChI from the full 3D molecule).

There are also cases where PubChem indicates an InChI key computed from the 2D depiction in the SD file, but there are missing or undefined stereo centers.
So I'd say that because of incomplete stereochemistry and/or inconsistencies in representations, PubChem CIDs will not always match up with "structural uniqueness" and this is by design, both for PubChem and InChI.
The moral of the story, frankly, is that chemistry is complicated and coming up with "perfect" unique identifiers is incredibly hard.
Comment: @CurtF. Your comment indicates *gaseous* compounds.. Keep in mind that most organic chemistry is done in *solution* and what's the rate of interconversion between these compounds in water or another protic solvent? As I said.. this is why it's incredibly hard to come up with "perfect" chemical identifiers.
Comment: Thanks for the suggestions on SMILES and the discussion of PubChem / InChI is very illuminating.  On whether Inchis treatment of zwitterions/tautomers is a bug or a feature, I agree that predicting the "most stable" one is very complicated, but how is stability related to representing InChI?  What would the rate of interconversion between gaseous CID 6140 and CID 6925665  be in a near vacuum at say 100 or 200 Kelvins?  My guess would be very low, which is why I think of them as separate molecules.  So to me separate InChIs would be good.
Comment: Oh yeah I don't think anyone is after "perfect".  Just better.  Or at least more consistent.
Answer: Martin's answer led me to discover an important extension of InChI that does allow for specification of some tautomer and zwitterion identification.

InChi identifiers that begin with InChI=1S/... are standard InChI.  In standard InChI, the InChI identifier "must be the same for any arrangement of mobile hydrogen atoms", with the quote from Section 6 of the Technical FAQ of the Inchi Trust.
However, non-standard InChIs are also possible.  These start with InChI=1/....  Note the missing S.  In non-standard InChI, there can be an extra layer beginning with /f that is called the fixed hydrogen layer.
Playing around with rdkit (via its Python API) I was able to produce a non-standard InChI that I think corresponds to Pubchem compound 6925665.

from rdkit import Chem
zwitterion_phe_smiles = 'C1=CC=C(C=C1)CC(C(=O)[O-])[NH3+]'
zwitterion_phe_mol = Chem.MolFromSmiles(zwitterion_phe_smiles)

# produces "standard" InChI so not explicitly zwitterionic
print Chem.MolToInchi(zwitterion_phe_mol)

     InChI=1S/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)

# produces "non-standard" InChI with fixed-H layer so zwitterion can be IDed
print Chem.MolToInchi(zwitterion_phe_mol, options='/FixedH')

     InChI=1/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)/f/h10H

# going from respective InChIs to SMILES
## The standard InChI produces neutral SMILES
zwitterion_nonstandard_inchi = 'InChI=1/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)/f/h10H'
standard_inchi = 'InChI=1S/C9H11NO2/c10-8(9(11)12)6-7-4-2-1-3-5-7/h1-5,8H,6,10H2,(H,11,12)'

print Chem.MolToSmiles(Chem.MolFromInchi(zwitterion_nonstandard_inchi))
print Chem.MolToSmiles(Chem.MolFromInchi(standard_inchi))

     [NH3+]C(Cc1ccccc1)C(=O)[O-]
     NC(Cc1ccccc1)C(=O)O

So for zwitterions tautomeric InChI's are possible.  Worryingly, however, some kinds of tautomerism are not handled even by non-standard InChI, again quoting from section 6 of the FAW:

In its current state, InChI recognizes the most common form of H migration (for the full list, see Table 6, Section IVb of the InChI Technical Manual). However, several ways of tautomeric migration that are not supported by default may appear important for some chemists. In particular, these are keto-enol and long-range tautomerisms.

Why Pubchem chose to list standard InChI instead of non-standard InChI is not entirely clear to me.  I suppose it is difficult to figure out programmatically when non-standard InChI would be required.  Ideally I suppose Pubchem would have both standard and non-standard InChIs for each of their molecules, but I'm not sure when/if they will ever make that change.
Comment: Basically you're not supposed to use non-standard InChIs in a public-facing service. A standardized InChI is what it is - but you'd need to know the exact flags passed to the code to understand a non-standard one.
Comment: I don't think PubChem obscures the difference. If you search by InChI or InChI key, you'll get multiple CIDs. I agree that many people don't realize that InChI is imperfect and there is *not* a 1:1 correspondence between a chemical structure and an InChI.
Comment: PubChem clearly has different ideas about what a "compound" is than standard InChI does, or else the different CIDs wouldn't exist in the first place.  To me using the same InChI for different CIDs obscures this fact.  Plus, there is a widespread conception, which I now realize to be very wrong, that "[there is a 1:1 correspondence between every organic chemical structure and a single InChI](http://metamolecular.com/blog/2012/12/12/twelve-things-organic-chemists-should-know-about-inchi-and-inchi-key/)".  Maybe that's the real issue.
Comment: I do think that many people using PubChem don't realize its limitations (e.g., as listed in my answer). That included myself when we started to build PQR.

Pubchem, InChI, SMILES, and uniqueness


How do I find the most popular search terms by browser?

Question: How do I find the most popular search terms categorized by browser? I tried http://www.google.com/trends/explore, but it doesn't let you filter by browser.
Comment: Why are you looking by browser? The browser if often not a factor for much anymore.
Comment: People who use certain browsers have different interests and levels of sophistication.
Comment: While I think this is true, after-all no little ol'e lady is going to install firefox or chrome and then search knitting, I am not sure how far it goes for keywords when you factor in all users. I am sure there is an effect! Interesting thought. From my experience, I have not seen keyword or log file data sliced and diced this way. Is there a way you can find using a log file analyzer? I use sawmill and it allows me to select any data segment (by browser in this case) and then view anything I want after that.
Answer: Trend information is not detailed niche information
Google trends is merely an insight on what's trending, Google and most likely all the other search engines do not provide detailed information on niche information such as keyword + browser. They do however provide an insight into country, which can be used to GEO target.
Why do not they share detailed niche information?
Well there's many reasons. Firstly nothing is free in this world and gathered data earns Google a lot of money. Because of their Google adwords services, sharing too much information would actually lose them money, a situation would be that people could target a keyword + location + browser and therefor the bidding price would decrease and Google would make less money.
What about harvesting your own data?
The best way of finding out who is using what and searching for what is using some kind of analytic on your website and using that data to advantage, but if you wanted to use this information based on browser type with adwords sadly you can't, Google will only let webmasters filter by device type (Tablet, Desktop Computer and Mobile Phone). Google Webmasters can shed some light as well but also note that if a user is logged into Google your analytic or webmaster tools will not display this information because of the SSL.
Comment: Where could I buy it then? I can't harvest my own because my site is not a general purpose search site. People arrive only after searching for specific keywords. You would need a general search portal to gather keywords + browser. Maybe Google would not share, but what about a smaller search engine? Maybe one that installs a toolbar or hijacks the home page?


I've completed Masters of Engineering in Computer Science from India, can I apply for MBA in Canada?

Question: I've heard that, Canada Government will reject these kind of files, if already masters is completed and applying for another masters. But that's MBA-IT and now I want to be in Management side in my career.
Answer: I don't think that the govt will reject a visa if you have been accepted into a valid university/college,have the required funds and all your documents are in order. Visa requirements have been further loosened in the last few months, so you need not worry if things are in order.


Air intake cleaning/ yes or no?

Question: 2007 Impreza wagon 2.5. Previous owner didn't take car of it and I was thinking of using the CRC intake valve cleaner. I would love your opinions on whether to do it or not. Please explain why it's good to do or bad to do. Thank you
Comment: Why are you thinking about the intake, are you having an actual problem with the car you are trying to solve? Is it running the right mileage?
Answer: I've used a lot of different induction cleaners, including CRC Intake Valve Cleaner, on many different cars and trucks.  It does work, to a widely varying degree, to improve acceleration, idle, and gas mileage.  Its effectiveness depends on how much deposit buildup exists, how much oil the engine burns, and how long the car has been neglected.
Though CRC Cleaner is safe and easy to use if you follow the instructions, you should be careful.  One threat is to spray too much cleaner at too low of an idle, which I've seen cause harmful rod knock.  If you spray the cleaner into the intake with the engine off, upon starting you could potentially hydro-lock the pistons and destroy the engine!
Another, much less serious drawback is that some of the cleaner will wash past the piston rings and get into the crankcase oil, thinning and degrading the motor oil and carrying carbon particles into the engine's oil circuit.  It's therefore a good idea to change the oil and filter within 500 miles of using the product.  I've had as much as 40% of the cleaner get into the crankcase, amounting to a small rise in my oil level on the dipstick.  After about 100 miles of driving, I sometimes get a flickering oil light on my dashboard while stopped at red lights, which disappears once I change the oil and filter.  I use a motor flush for five minutes before my shop drains the oil, which helps to remove the carbon particles.
CRC requires multiple applications if the engine is old and neglected.  Carbon buildup can be extremely hard and stubborn.  It helps greatly to pre-treat the engine with Marvel Mystery Oil in the gas tank, 2 oz. per gallon, for several weeks in between intake cleanings.
After successfully cleaning on an old car, there is a final problem.  Carbon pack on old cylinder walls and worn piston rings has a sealing effect, and removing the carbon can  ironically cause a loss of compression and an increase in oil burning.  In such cases, I compensate by adding Engine Restore to the crankcase.
Answer: You don't need to clean intake valves on a port-injected gasoline engine using a dedicated valve carbon-removal solution as the valve neck and face are constantly being washed by the fuel injectors. The valve face is the only part of a valve susceptible to carbon buildup on older, indirect/port-injected engines.
It's a different story on both diesel and gasoline direct-injected engines as neither offer a constant fuel stream passing over the intake valves which would otherwise prevent the buildup of carbon deposits. This affects all DI engines without a supplementary port injection system. This is why intake valve cleaning products such as the CRC line exist.
However, cleaning the entire fuel system via a cleaning agent deposited into the fuel tank can be very effective as it will help dissolve deposits within your fuel injectors and all fuel delivery components leading up to those injectors. Products sold as "Fuel System Cleaner" or "Injector Cleaner" would be more appropriate for your Subaru if it has been neglected as it will help restore injector spray pattern, critical for an effective and complete combustion cycle.

Air intake cleaning/ yes or no?


What is the distinction between variable and number in these two expressions?

Question: The author here discriminates between the two functions as a is a fixed number, and x is a variable. I am confused as to this distinction, as it seems the reason why we would need to use 'a' instead of a number is to account for many different possibilities of 'a', such that 'a' is essentially a variable. I would appreciate an explanation as to the difference between these two, and when something expressing the meaning of 'a' would be used as opposed to something with the meaning of 'x'.
thanks
Comment: Both are of the form $a^b$. Saying one of $a,b$ is a "*variable*" means that you focus on the behavior as a function of that variable while considering the other one as a fixed parameter. If you call $a$ to be the variable the focus is on the power function $x^a$. If you call $b$ to be the variable the focus is on the exponential function $a^x$.
Answer: It is not the "Distinction between Variable & Number" ; It is the "Distinction between Variable and FIXED Number" ....
In other words , we have Variables & Constants , both of which may be Numbers.
$f(x)=2^x$ , $g(x)=x^2$ , $h(x)=3x$ , $i(x)=3a^x$ are functions with 1 Variable , where $a$ is FIXED Constant.
$F(x,a)=a^x$ , $G(x,a)=x^a$ , $H(x,a)=ax$ , $I(x,a)=3a^x$ are functions with 2 Variables , where $a$ is not a Constant.
Answer: In the expressions$$a^x$$ and $$x^a,$$ $a$ is variously called a fixed number, a constant, an arbitrary constant and a parameter, to indicate that the value of $a$ can be arbitrarily fixed (so that we are considering an exponential function and a power function, respectively), after which we are considering the value of, say, $7^x$ or $x^7$ as $x$ varies. To capture how $a$ and $x$ vary, you can draw a family of curves, each curve corresponding to a value of $a,$ similar to how you might draw a family of curves to represent the antiderivatives $\int 2x\,\mathrm dx=x^2+C,$ where $C$ and $a$ play the same role.
In truth, the terminology for these placeholders is informal, and $a$ is indeed just a special variable.


Blower stopped working

Question: My blower stopped working suddenly on my  04 Trailblazer. I figured it was the resistor but as Murphy's law would have it, the battery died a few days later. I replaced the battery and the blower worked initially (about an hour) then stopped again. The fuses are good to go.
Comment: Welcome to Motor Vehicle Maintenance & Repair!
Comment: Manual or automatic climate control?
Answer: More than likely it's the blower motor itself which is bad. This can be from a "dead" spot where the brushes meet the motor or what have you. Then some vibrations got it to a "good" spot and it decided to work again ... until it hit the bad spot again when it stopped. You can pull the blower motor and see if it will work by applying power directly to it. You can test my theory a little bit by manually moving the fan a little and applying power to it. Do this several times until you get the fan around 360°.
Comment: Very interesting!

Blower stopped working


If I flip my picture horizontally then would it be the accurate depiction of how people see me in real life?

Question: I was curious to know that if I flip my picture, which is taken from a rear camera, selfie, DSLR etc. horizontally then would it be the accurate depiction of how people see me in real life?
Comment: It would depend on whether you are using the camera to take the picture directly of yourself or if you are using it to take a picture of your reflection in a mirror. Which is it?
Comment: The bad news is no. You are the only one that look at yourself fliped every morning.
Comment: Vote to close because it's unclear what's being asked.  E.g., is this a question about left-right reversal or is it a question of philosophy?
Comment: @CarlWitthoft I meant left-right reversal. Hope it clears now.
Answer: No. The picture straight out of your camera is what you look like to others. You don't need to reverse it. Think about it - when you take a picture of something else with your camera, you don't need to reverse it to see it how others would. (Otherwise any text in a photo would be backwards!) So it's the same when taking a picture of yourself.
You might be interested, though, in artists who have experimented with facial symmetry:
"Both Sides Of" by Alex John Beck, for example, makes images of peoples left side mirrored to the right and vice-versa.
EDIT As mentioned in the comments, your cell phone may reverse the image during preview if you're using the front-facing camera. But once it takes the picture, it's no longer reversed. This is because it's easier to fix your hair/make-up/tie/etc. because you're probably used to doing those things in a mirror.
Comment: The confusion might stem from the fact that smartphone rear cameras usually flip the picture while previewing, to create a mirror like effect. But the final picture is not flipped.
Comment: @ths, I think that is called the front camera.
Comment: @ths You did certainly mean *front*, not *rear*.
Comment: I'm always unsure where he front and back of a phone are supposed to be, but the op wrote "rear camera", so i went with that.
Answer: In case you're using the front camera, this depends on the software you use to take your pics - it may or may not flip the pic automatically. The rear cam always shoots you "as-is", without flipping (obviously).
If you're worried that the front cam flips the image, just check whether the picture is already normal or flipped by taking a pic of anything first with the rear cam, then with the front cam.
Answer: No, if you're worried about what you look like after you have taken a selfie and flipped it, don't. It isn't accurate, the lighting will be off and everything will look weird. If you are wondering what you really look like, use the camera on the back of your phone.


What is Java 9's new string implementation?

Question: How are strings implemented in Java 9 under the hood? Is each character stored as one or two bytes?
Comment: Since Java 9 hasn't been released yet, is this behavior officially finalized?
Comment: @DanielPryden - Valid point.  However, this late in the development cycle for Java 9 it is *unlikely* that they will reverse this change.
Comment: @StuartMarks Just to clarify your last sentence of "It's not coming out" you mean it's not coming out of Java-9 or its not coming out with Java-9? It seems like you mean the former because of your first sentence.
Comment: @DanielPryden (Java 9 developer here) I concur with Stephen C. The compact strings work is integrated, and it's been well tested and benchmarked. It's not coming out.
Comment: @A_Arnold A fair point! I meant, it's not going to be removed from Java 9, so it will be delivered along with Java 9 when the whole thing is released.
Answer: Because most usages of Strings are Latin-1 and only require one byte, Java-9's String will be updated to be implemented under the hood as a byte array with an encoding flag field to note if it is a byte array. If the characters are not Latin-1 and require more than one byte it will be stored as a UTF-16 char array (2 bytes per char) and the flag. See JEP 254 .


Parser and solver for percentage calculation problems

Question: I'm working on a coding challenge to help with regular expressions, and how to write better comments in my code. The class parses a percentage question, and can return the answer.
If anyone has any feedback on the general organization of my class, variable names, or whether or not my comments can be improved, it would be appreciated. My goal is that anyone reading my code can clearly understand what it does and how it works, keeping the 'maintenance' programmer in mind.
package com.percent.model;

import java.util.Arrays;
import java.util.Collection;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

/**
 * Class represents a solver for a percentage question.
 * @author steve
 */
public class PercentageQueryPatternSolver {

    //? is x% of y
    private static final Pattern findIsPattern = Pattern.compile("(\\?) is (\\d+)% of (\\d+)");
    //x is ?% of y
    private static final Pattern findPercentPattern = Pattern.compile("(\\d+) is (\\?)% of (\\d+)");
    //x is y% of ?
    private static final Pattern findOfPattern = Pattern.compile("(\\d+) is (\\d+)% of (\\?)");

    /*Although the numeric values in the queryString passed to the constructor must be integers, we
     *store them as Doubles since the value that we are solving for may not be a whole number, and
     *we don't know which of the 3 values we are solving for in the beginning. When the query
     *is solved, we will remove any trailing .00 values to clean up the output.
     */
    private Double firstIsValue;
    private Double secondPercentValue;
    private Double thirdOfValue;

    //These are the valid forms that we expect the query string to take
    private Collection<Pattern> validQueryStringPatterns = Arrays.asList(findIsPattern,
                                                                         findPercentPattern,
                                                                         findOfPattern);

    /**
     *
     * @param queryString query to be parsed. must take one of the following forms:
     * ? is x% of y    (example: ? is 10% of 32)
     * x is ?% of y    (example: 12 is ?% of 62)
     * x is y% of ?    (example: 25 is 40% of ?)
     *
     * 'x' and 'y' must be whole numbers, and both values are required
     * '?' represents a value to be solved for, and must be entered as '?'
     *
     *  If the queryString does not take one of the above forms, an IllegalArgumentException is thrown
     */
    public PercentageQueryPatternSolver(String queryString){
        initialize(queryString);
    }

    //parses the queryString and populates the firstIsValue/secondPercentValue/thirdOfValue variables
    private void initialize(String queryString){
        boolean queryStringMatchesAValidQueryPattern = false;
        for(Pattern pattern : validQueryStringPatterns){
            final Matcher patternMatcher = pattern.matcher(queryString);
            if(patternMatcher.matches()){
                queryStringMatchesAValidQueryPattern = true;
                setQueryParameters(patternMatcher);
            }
        }
        if(!queryStringMatchesAValidQueryPattern) {
            throw new IllegalArgumentException(queryString + "does not match a known pattern.");
        }
    }

    //pulls the query parameters from the matcher and sets the respective attributes
    private void setQueryParameters(Matcher validatedPatternMatcher){
        firstIsValue = getDoubleValueOfGroupFromMatcher(validatedPatternMatcher, 1);
        secondPercentValue = getDoubleValueOfGroupFromMatcher(validatedPatternMatcher, 2);
        thirdOfValue = getDoubleValueOfGroupFromMatcher(validatedPatternMatcher, 3);
    }

    //returns the double value of a particular group from the matcher
    private Double getDoubleValueOfGroupFromMatcher(Matcher matcher, int groupNumber){
        String groupValue = matcher.group(groupNumber);
        return "?".equals(groupValue) ? null : Double.valueOf(groupValue);
    }

    //returns the inputDouble formatted for output purposes (remove trailing decimal if 0)
    private String getOutputFormattedDoubleValue(Double inputDouble){
        String output = String.valueOf(inputDouble);
        if (inputDouble == Math.floor(inputDouble)){
            output = String.valueOf(inputDouble.intValue());
        }
        return output;
    }

    /**
     *
     * @return the original queryString (used to construct this pattern) with the
     * missing value populated.
     */
    public String getSolvedPattern(){
        if(firstIsValue == null){
            firstIsValue = (thirdOfValue * secondPercentValue) / 100;
        }
        else if(secondPercentValue == null){
            secondPercentValue = (firstIsValue * 100) / thirdOfValue;
        }
        else if(thirdOfValue == null){
            thirdOfValue = (firstIsValue * 100) / secondPercentValue;
        }
        return getOutputFormattedDoubleValue(firstIsValue) + " is " +
               getOutputFormattedDoubleValue(secondPercentValue) + "% of " +
               getOutputFormattedDoubleValue(thirdOfValue);

        }

}

Answer:
    //? firstIsValue x% of y
    private static final Pattern findIsPattern = Pattern.compile("(\\?) is (\\d+)% of (\\d+)");
    //x firstIsValue ?% of y
    private static final Pattern findPercentPattern = Pattern.compile("(\\d+) is (\\?)% of (\\d+)");
    //x firstIsValue y% of ?
    private static final Pattern findOfPattern = Pattern.compile("(\\d+) is (\\d+)% of (\\?)");

The first rule of writing good comments is not to tell what the code is doing but why it is doing it.  E.g.
    // Define separate patterns depending on whether we are searching for
    // the subject,
    // the subject's complement, or
    // the object of the preposition.
    private static final Pattern subjectFinder = Pattern.compile("(\\?) is (\\d+)% of (\\d+)");
    private static final Pattern complementFinder = Pattern.compile("(\\d+) is (\\?)% of (\\d+)");
    private static final Pattern objectFinder = Pattern.compile("(\\d+) is (\\d+)% of (\\?)");

Now we can easily see that the reason why we have three different patterns.  It's because we might be looking for three different things.
I don't try to restate what the code is doing.  This is because I had no idea what ? firstIsValue x% of y meant.  I had to read the code to understand the comment, which is completely backwards.  Assume that the reader knows enough to understand what the code does directly.  Comment to tell them what the code does indirectly.
I changed the names to ones that I found clearer.  If you like Hungarian Notation, which is common in Java, you can add Pattern to each name.  I usually prefer to leave it off, with exceptions where I find it useful.  If you read the linked article, I would prefer Apps Hungarian names to Systems Hungarian.
The new names describe the parts of the "sentence" that is being patterned.  Sometimes, it is worth doing a little research to come up with better names.  For example, I didn't remember that the noun after the "is" (or other linking verb) is called the subject's complement.  I just remembered (vaguely) that it was called something different with a linking verb than with an active verb.  Google assisted.
Good naming is often better commenting than comments.
Even better, consider unit tests.  Names and comments can fall out of synch with the code.  For example, your original name findOfPattern.  If you change the "of" to "in", your code and name will be out of synch.
With unit tests, they will tell you if the code and the test are out of synch.  Some of the tests will fail.  You can then either make the code match the tests or in some cases, alter the tests to match the code.
Because of this characteristic of enforced synchronicity, unit tests often make for better comments than comments do.
To reiterate, when you do use comments, please use them to tell the reader why you are doing something.  You should very rarely have code so obfuscated that you need to explain what you are doing.  The code itself should tell us what the code is doing.  The comment only needs to add why.
Comment: thanks for the feedback. i did a find replace and ended up messing up some of the comments, oddly enough. i just fixed that.


Bicarbonate added to tomato sauce, will the acidity of the tomatoes neutralize it?

Question: Sodium bicarbonate is often used as a meat tenderizer. But if you forgot to soak the meat in advance and you add it to meat that is going to be cooked in a tomato sauce will it work?
Will the acidity of the tomatoes lower the ph neutralizing the bicarbonate effect?
Comment: If it's going in a tomato sauce & you haven't already added the bicarb, just cook it longer. You only need a tenderiser on short-cook meals.
Answer: Adding bicarbonate during cooking isn't going to have the effect you want. Sodium bicarbonate is bitter and can add a slightly metallic taste if it remains unreacted with acid, when bicarb is added as a tenderizer it's rinsed off before cooking so you won't taste it. If you add enough to tenderize meat it will definitely impact the flavor.  Plus, it takes time to work, longer than cooking time, so it wouldn't tenderize the meat much.


JQuery: How to select window and some other divs by id?

Question: I have a context menu that pops up whenever a click happens at a certain div inside a container and I want it to hide if either the window element or its container is scrolled.
How can I add the 'window' element in there?
<code>$("#tree-container").scroll(function(){
    $cxtMenu.hide();
});
</code>
Answer: If i understand your question, try:
<code>$("#tree-container").add(window).scroll(function(){
    $cxtMenu.hide();
});
</code>
If not, please consider to provide a jsFiddle which replicates your issue
Answer: You can add a scroll handler directly to the window like
<code>$( window ).scroll(function() {
     //Do stuff
});
</code>
(Per "Example: To do something when your page is scrolled" of http://api.jquery.com/scroll/)


In discord, can I maintain a conversation with only one player while listening to the whole group?

Question: I host a tabletop game using discord and sometimes I feel like I need to pass information directly to a player and not having the others to listening. Is it possible to direct my voice channel to a particular person while still listening to everybody else?
Comment: You can "Deafen" them. Kinda the reverse of mute.
Comment: @Robotnik That's counter productive. The intention is for the flow to not be disrupted. When you deafen everybody, but the person you are relaying the message to, all other players won't be able to hear. They'll likely be confused as to why the channel is suddenly silent and possibly start to chatter as to what's going on, disrupting the private chat. Keep inm nid, a deafened person can still tlak, but can't hear anything. So, the two people who aren't deafened can hear everything.
Comment: @Rapitor Discord is considered on-topic here, there was a recent [meta post](https://gaming.meta.stackexchange.com/q/12989/152051) about it specifically.
Comment: I'm voting to close this question as off-topic because this doesn't really have to do with gaming or a specific game, but a separate application entirely, that is not a game.
Comment: @Virusbomb, wasn't aware of that. Not sure I agree, but meta is law.
Answer: This is called whisper functionality, which Discord currently doesn't feature. Here you can vote to have this implemented.
Currently, you have to use one of the following workarounds:
1) Use a voice chat, which has whisper functionality, e.g. teamspeak.
2) Send the player the private message via text. This is cumbersome, but I feel the best solution, if you want to continue using Discord.
3) Call the player via discord. This removes you from the group chat for the  duration of the call.
4) Move the player and you to a secondary audio channel. Also removes you from the group chat and makes it obvious you are relaying a private message to them.
5) Create a second discord account and use that to relay private messages to your players either via option 3 and 4. This allows you to stay in the main channel, but requires mic on/off juggling, whenever you want to send a private message (mute your main account while sending the message, then unmute after having finished)


What does rotational invariance mean in statistics?

Question: What does rotational invariance mean in statistics? The property that the normal distribution satisfies for independent normal distributed $X_i$,  $\Sigma_i X_i$ is also normal with variance $\Sigma_i Var(X_i)$ is referred to as rotational invariance and I want to know why.
Comment: There is a nice formatting guide for formulas that you might want to look at: http://meta.math.stackexchange.com/q/5020/166535
Answer: Let $X_i$ have mean $\mu_i$ and standard deviation $\sigma_i$, and write
$X_i = \mu_i + \sigma_i Z_i$ where $Z_i$ are independent standard normal random
variables.  The joint density of $Z_1, \ldots, Z_n$ is
$$f(z_1, \ldots, z_n) = (2 \pi)^{-n/2} e^{-(z_1^2 + \ldots + z_n^2)/2}
= (2 \pi)^{-n/2} e^{-\|{\bf z}\|^2/2}$$
which is rotationally invariant, i.e. invariant under rotations of $n$-dimensional space, because it only depends on the length of the
vector ${\bf z} = (z_1, \ldots, z_n)$.  Now $Z_1 = (1,0,\ldots, 0) \cdot \mathbb (Z_1,  \ldots, Z_n)$ has a standard normal distribution.  But because of the rotational invariance, so does ${\bf u} \cdot (Z_1, \ldots, Z_n)$ for any unit vector $\bf u$.
In particular, take ${\bf u} = (\sigma_1, \ldots, \sigma_n)/\sigma$ where
$\sigma = \sqrt{\sigma_1^2 + \ldots + \sigma_n^2}$, and we get that
$(\sigma_1 Z_1 + \ldots + \sigma_n Z_n)/\sigma$  has a standard normal
distribution, which means $$X_1 + \ldots + X_n = (\mu_1 + \ldots + \mu_n) + \sigma \dfrac{\sigma_1 Z_1 + \ldots + \sigma_n Z_n}{\sigma}$$ has a normal distribution with mean
$\mu_1 + \ldots + \mu_n$ and standard deviation $\sigma$.
Comment: Why does $u$ have to be a unit vector?
Comment: @student010101 , because $u \cdot \left(Z_1,\ldots,Z_n\right)\sim N(0,u_1^2+\ldots+u_n^2)=N(0,1)$ if the vector is unit.


How do I make lingering potion last longer?

Question: I want to make the lingering potion particles last longer after it has been thrown. How (if possible) can I do this?
Answer: You can't customise the cloud of a lingering potion after it has been thrown, although you can summon custom clouds without the lingering potion.
/summon minecraft:area_effect_cloud ~ ~ ~ {Radius:5,Duration:10000,Effects:[{Id:5,Amplifier:0,Duration:60}]}
Where the first duration is the time the cloud lasts in ticks, and the second duration is the time the potion effect lasts in ticks.
If you absolutely want the lingering potion to be thrown though, you could have one command block checking for potion clouds and removing them:
execute if entity @e[type=minecraft:area_effect_cloud] run kill @e[type=minecraft:area_effect_cloud]
then have another command block summon your custom potion cloud. The first command block would have to be deactivated quickly before the second one.


Where is the logfile located for Xcode Scheme Post-Actions?

Question: I am running a script in my Xcode project in the Scheme's Build->Post-actions "Run Script". It runs fine but I would like to see the console output of that script. It doesn't seem to be included in the Log Navigator tab, where can I find this log?
Comment: I see pre-build actions logs in Xcode 14.3.
Answer: The output from those scripts doesn't seem to be logged anywhere by default. Your best bet is to manually redirect the output of the script to a known location. For example, add the following as the first line of your script:
<code>exec > /tmp/my_log_file.txt 2>&1
</code>
This will redirect all following output to stdout and stderr to your specified log file.
Comment: For some reason even after adding this, neither the folder or files are visible in the project directory but if I use terminal I can see all the files. To print the output of log file you can use: cat /tmp/my_log_file.txt


A humanoid with six arms?

Question: How could a humanoid species evolve to have six arms, all in relatively the same part of the body, the top corners of the torso, like us? It can't be as simple as tree-climbers moving back to the ground, could it?
Comment: People who ask how would something evolve questions usually display a lack of understanding of evolution. Something evolves because there are natural selection pressures that favour organisms with that given trait or who possess traits capable of being adapted to whatever it is you expect to evolve. Where is an evolutionary biologist when you need one?
Comment: Look up Polymelia for how such a thing can come about. You would then have to have a selective mechanism for it to continue.
Comment: Relevant answer to a semi-related question [here](https://worldbuilding.stackexchange.com/questions/181713/evolution-of-werewolves/181733#181733).  Unsettling pictures of HOX gene manipulation in flies [here](https://biology-forums.com/gallery/27_02_11_13_1_17_58.jpeg)
Comment: More info:  some forms of Polymelia are inheritable, and some are not.  Only polymelia with a genetic cause would be inheritable.
Answer: It doesn't fit the standard vertebrate body plan, so the short answer is no, but the long answer is "maybe."
If you want an 8-limbed vertebrate, you have to start very early in evolutionary history. The 4-limbed body plan for animals arose around 500 million years ago, and ever since we've been stuck with it.
It's certainly possible to evolve 8 limbs, but there needs to be a selection pressure for it. Limbs are expensive to maintain, as they cost energy (i.e. food) to form. You'd need some kind of selection pressure to push for and maintain 8 limbs. You can see this in the fossil record, as many animals that are bipedal give up their forelimbs, Tyrannosaurus sp. and flightless birds being a prime example. So even if you start out with 8 limbs, there's no guarantee they'll keep all of them.
Note also we've never had a situation where more than 4 limbs were added through evolution, which is why you have to start early in your body plans.
That said, even if you can preserve the 8 limbs, what you're likely to end up with in a humanoid is something more like a centaur, with 6 legs and 2 arms, than what you're looking for, with 6 arms and 2 legs, so you'll need a way to push for bipedal motion.
Another side effect is that it won't be just your humans that wind up with 8 limbs, but all vertebrate animals. The Anime/Manga "A Centaur's Worries" is interesting in that it captures this fact properly: all vertebrates have 6 limbs. Humans might have two of those limbs become wings, or they might be a centaur, but the limb count still adds up to 6. In addition, even dogs in that universe have 6 limbs, so do cats, birds, etc., so it's obvious the 6-limb bodyplan came early in that world's evolutionary history.
Comment: i'm agree, to have 8-limbs the shape of body is more near to arachnid. The torso is unbalanced because 6 arms must have six shoulder and a tall vertebral column, so the legs to maintain balance are more large and long.
Answer: Yes, through the mutation of Hox genes.
You do not need a long evolution to develop an 6-armed humanoid.
Hox genes specify regions of the body plan of an embryo along the head-tail axis of animals.
Mutations in the Hox genes can result in body parts and limbs in the wrong place along the body, missing limbs, or even duplicate limbs.
One Hox gene experiment on the fruit fly stated "In Ubx loss-of-function mutants, Ubx no longer represses wing genes, and the halteres develop as a second pair of wings, resulting in the famous four-winged flies. "
While it is true that all vertebrates share the same basic body plan of 4 limbs, this is in part because the Hox genes are so well-protected against mutation, and also in part because a drastic Hox (i.e. body-plan) mutation is unlikely to be beneficial and propagate.
If something allowed Hox genes to mutate frequently, and you got very lucky, a humanoid could get a Hox mutation for 6 arms in as little as a single generation.
However, this would probably be of limited utility (and possibly even painful), since the rest of the body is not built to deal with this body plan.  I speculate that there would most likely be some kind of severe extra strain/torsion on the spine, to start with.
In order for this mutation to survive and continue, the 6-arm body plan would have to provide some kind of specific survival benefit, so it would be naturally selected for.
Over a long time (or a shorter time, with additional luck), there would be further mutations to accommodate this radical change, limiting some of the drawbacks.

A humanoid with six arms?


Background on Joshua 5:10-11

Question: Why were there no celebrations of the Passover while Israel wandered for 40 years in the wilderness?
Comment: Welcome to BHSX.  Please take the tour below.  Thanks for your question.  Is there anything that prompted this question?
Answer: The usual answer why there was no Passover during  the wilderness wanders has several components; all practical.

Until the Israelites arrived in the promised land they lived on manna and so had no materials with which to celebrate the Passover such as, roasted grain, bitter herbs, etc.  This was symbolised the day after they celebrated the first Passover - manna stopped because they now had access to local produce (Josh 5:11, 12)
The people had to be circumcised before partaking of the Passover (Josh 5:5-9)

Thus, the Passover was not celebrated because the elements to celebrate it we not available and because circumcision had not been practised.
Comment: Thanks so much for sharing your insight.

Background on Joshua 5:10-11


Using CSS to style Ruby objects in erb

Question: I have Googled around but can't find the answer to this question.  How do I use CSS to edit RUby objects in erb.  For example:
<%= f.label :email, "Enter your email address for updates" %>

<%= f.text_field :email %>

Here, I want to use CSS to style the text and the form box.  How can I do that?
Answer: You can use the :class option to specify a CSS class:
<%= f.text_field :email, :class => "login" %>

and then put that in your css:
input.login {
  color: red;
}

Also, you can specify inline CSS if you want:
<%= f.text_field :email, :style => "color: red;" %>

Answer: Adding on to what Dylan said...
You can use :id option to specify a CSS id:
<%= image_tag "illustrations/clipboard.png", :id => "clipboard" %>

and then put in your css:
#clipboard {
     border: 1px solid #000;
}

Using CSS to style Ruby objects in erb


Bracha on frozen grape juice

Question: For a cold dessert, I often like to freeze a cup of grape juice and then eat it with a spoon like an Italian ice.  What is the appropriate bracha to say before and after eating this delicacy?
Comment: Some wines are made from gape juice that has been concentrated down to the form of semi solid, (cube), and at a later date reconstituted and fermented to wine. What should be the
brocho over that kind of wine?
Comment: @AvrohomH, Welcome to Judaism.SE! I recommend that you [post](http://judaism.stackexchange.com/questions/ask) your question as a new question, possibly referring to this one as its inspiration. If you can refer in the question to examples of the wines you're talking about, and/or to a writeup of the process, that'd be cool.
Comment: @AvrohomH, Please use the "Add Comment" button to comment or reply to comments.
Answer: "There is a huge machlokes in the Poskim regarding exactly this issue if grape juice only maintains its special status as a liquid or even when hardened. Therefore, it would be ideal to make borei pri hagafen on liquid grape juice and shehakol on something else before eating the ices. In the likelihood that this is not practical, one should say shehakol."
http://revach.net/ask/article.php?id=1205
"Grape Juice Ices: According to The Halachos of Brachos (Rabbi
Binyomin Forst, Shlita), "Frozen grape juice (i.e., grape ices) or wine
may have lost its status as wine since it was transformed into solid food.
One should therefore not recite a Borei P'ri Hagofen either on frozen
wine or wine that was thickened into solid form.""
http://www.aishdas.org/avodah/vol09/v09n080.shtml
"The proper bracha for grape ices is Shehakol. (Laws of Brachos p. 313)"
http://www.mevaseret.org/mmy/searchshiurim.php?shiur=259
Comment: I believe according to R. Schachter the bracha is ha'eitz
Answer: I don't know for certain (CYLOR, of course), but some possible relevant sources:
Rambam (Hil. Nezirus 5:2) groups together wine and "coagulated wine," classifying them both as "fruit" (as opposed to vinegar, which is considered "waste products of the fruit").
In a few places the Gemara also refers to "coagulated wine." Two of these (Sukkah 49a and Me'ilah 11b) are referring to the residue remaining in the drainpipes (shisin) under the Altar, which was cleaned out and burned "once every seventy years." The other two (Sukkah 12a and Sotah 48b) speak of "coagulated wine that comes from Senir" - which might indeed be the same as your delicacy, as Senir is Mount Hermon, which is snowcapped all year round. Evidently, though, even when solidified it can still be called "wine."
Based on all of this, then, it would seem that freezing grape juice doesn't downgrade its status, and it should keep the same berachah. (Indeed, freezing it is less of a change than drying it out, since frozen juice will melt but dried-out wine can't necessarily be reconstituted.)
(Incidentally, if "coagulated wine that comes from Senir" means wine ices, then you've rediscovered something quite important; the Gemara in Sotah there says that this hasn't been available since the destruction of the first Beis Hamikdash!)
Answer: Rav Shlomo Zalman Aurbach held that grapejuice or wine ices is not downgraded brachawise and one should make a borei pri hagafen.
Text:
Answer: According to some poskim, the correct berachah will be shehakol. This is ruled by the Birkei Yosef (Orach Chaim 202:2), Ben Ish Chai (Year 1, Matos 10), Shevet Halevi (9:39, who rules that shehakol should be made on account of a safek), and Sheraga Hameir (3:32; 8:113).
However, it appears that most poskim rule that the blessing is borei peri hagafen. This was the ruling given by Rav Shlomo Zalman Auerbach (cited in Ve-aleihu lo Yibol, Vol. 1, p. 110), Kinyan Torah Behalachah (2:108), Shevet Hakehasi (6:123), Rav Chaim Kanievsky (Aseifas Yitzchak, Cheshvan 5768), Mekor Haberachah (Shut 2), and Avnei Yashfei (ibid., Kislev 5768), who explains that because the ice is licked, the manner of consumption is drinking, and therefore the blessing is surely hagafen, and adds that even if the ice is bitten and chewed, hagafen should be made (based on the principle that this berachah is valid bedieved even for grapes).
Some poskim leave the matter as being a safek: See Peri Megadim (Eishel Avraham 202:11, who writes that the question is whether to make a hagafen or borei peri ha'eitz); see also Sha'arei Haberachah 18:8; Chukei Chaim, Orach Chaim 3:38.
The most difficult aspect is the final bracha, since borei nefashos cannot cover an Al Hagefen, especially that some poskim maintain that the bracha of maain shalosh, al hagfen, is doireisa, biblically mandated.
Therefore, although the issue remains unresolved, it appears that one who makes borei peri hagafen (certainly for licking the ices, and even for chewing them) is acting properly.
Nonetheless, it's best to add a large amount of other liquids to avoid the shailah.

Bracha on frozen grape juice


How bad is the Prague flooding going on (current as of June 2013)?

Question: What impact will the flooding in Prague have on the trip I am planning at the end of June, and should I reschedule?
Comment: I wonder, is this question too localized? Because it won't be useful two months from now.
Comment: I do not think this question is answerable since the authorities in Prague itself right now are arguing how the situation will develop.
Comment: @svick: it is indeed too localized now, and can be closed as such when the situation is resolved; in the mean time, I think this sort of question is relevant, and we've had some similar ones before.
Comment: There is also a significant benefit in a question like this, the overall notion of travelling to where a disaster has occurred (one of the reasons I gave +1).
Comment: Very apt to have such a question at the time of event. But we do need some way to indicate that the floods are over, or which flooding we're talking about.  I'm going to edit the question to indicate as such.
Answer: The water level in Vltava fell down considerably since the culmination on 4 June. There are still some restrictions on mass transit and for example some metro stations in the city center are still closed. Though I would expect most of those restrictions to be gone by the end of the month.
UPDATE: All metro stations are now open. The temporary flood walls are still up (at least on some places), not sure why.
Comment: @LexVjatkin [That page also has a version that's (partially) in English](http://hydro.chmi.cz/hpps/hpps_prfdyn.php?seq=307225&lng=ENG)
Comment: Metro is opened from today (9 June) 15:00. Charles bridge is open too. For Vltava flow rate see http://hydro.chmi.cz/hpps/popup_hpps_prfdyn.php?seq=307225 (rate below yellow line is safe.)


Edit the token values submitted by webforms

Question: I am using webform for user registration and confirmation page as profile page.
I have included the token as follows
" [submission:values:name]
[submission:values:email]
[submission:values:country]
[submission:values:date]
 "
Now the submitted values are displayed in profile page but my requirement is the user should be able to edit and save only few fields but view all fields.
How i would include edit option for displayed data using tokens.
Please help me on this issue. Thanks
Answer: Have a look at the Field Permissions module. From its project page:

... allows site administrators to set field-level permissions to edit, view and create fields on any entity.

Since users are entities also, it should work for any of your fields.
Comment: Thanks for the reply. It works for content types and profile types. In webforms,only for comments I guess. Because webform nodes are not retrieved in the entity list while configuring the module. If you are sure that it works ,please brief out the steps.


Minimum size of black hole

Question: What is the minimum size a black hole could be? I have been told that they were worried that the LHC would create a black hole, yet they say  the Sun cannot be a black hole. I understand that the black hole may evaporate very quickly, but I still don't understand what the minimum size is.
Comment: Then I don't think there is any such limit - in classical GR, if you get the required mass inside the Schwarzschild radius, you get a black hole. In reality, there will probably quantum effects at very small scales making that classical statement invalid, but since we do not have a quantum theory of gravity, there can't be an accepted answer what happens.
Comment: Duplicate of [How small are the smallest black holes?](http://physics.stackexchange.com/q/55091/50583).
Comment: @ACuriousMind I disagree. That question asked about stable black holes. This asks about any black hole.
Comment: It's not that the Sun "cannot" be a black hole, it's that the process that makes a star into a black hole won't work unless there's enough mass. There has to be so much gravity that nothing can stop the collapse. Less mass and something--electron degeneracy pressure for white dwarves, etc--will be able to make it balance.
Comment: @ACuriousMind and Jimmy360 I do mean any black hole. Not just stable black holes.
Comment: Probably Planck radius.
Answer: There's no minimum size. There's a minimum density. Stars turn themselves into black holes when they exhaust their fuel and collapse. For that to yield a black hole, they need to start off with around 25 solar masses. If a star starts with enough mass, natural processes cause it to eventually suffer a core collapse which greatly compresses some of its mass. (The rest gets blasted outward into space by the resulting shockwave.) If that explosion's large enough, the mass that's falls inward can reach the critical density for a black hole. (Thus the black hole's mass is less than that of the progenitor star.)
Particle accelerators can (perhaps, according to some versions of theory) create microscopic black holes by manufacturing large subatomic particles. Since the particles are created with high nominal densities, they can be considered black holes. They also tend to be moving near the speed of light, and even though they're "large subatomic particles", they're still expected to have masses much less than, say, a Uranium atom. Since it's the total mass which sets a black hole's radius, this would yield (at worst) nucleus-scale black holes moving near the speed of light. Such black holes would drill through matter, disrupting anything encountered along the way in a nucleus-wide path. Since atoms are really small (and nuclei are even smaller), you could have a few of these going through you and not notice... but they'd technically be black holes. The "disruption" caused by them would basically be a narrow beam of ionizing radiation. Such black holes would also decay very rapidly.
Comment: Massive stars do not explode due to thermonuclear runaway, that is the low-mass stars. Massive stars go through core-collapse. And you typically need at least 25 solar masses to get a black hole.
Comment: This scenario (I mean paragraph 2) sounds quite wrong to me. What about Hawking radiation? To get to the moon, travelling at the speed of light, you would have to create black holes of mass $>10^{5}$ kg, since a lower mass black hole would evaporate in a fraction of a second, releasing $\sim 10^{21}$ J during that time. The black holes you are talking about would evaporate in a vanishingly short time.
Comment: I thought the density of the center of all black holes is infinity because a singularity has infinite density and zero volume.
Comment: Thanks to @kyle-kanos for correcting me. To answer benichiwa's concern: The singularity itself reaches possibly-infinite density, but there's a convention of referring to the size of a black hole based on the radius of the event horizon. The black hole's mass can be divided by that volume to yield the density I intended above. My original answer is probably still fudging things slightly, but if Kyle or another astrophysicist can come up with a more-accurate concise answer, I invite them to do so.
Comment: I did ignore Hawking radiation, and didn't mean to treat the LHC as a shoot-down-the-Moon gun. I was trying to show that the black-holes one might get from the LHC would not stick around long enough for the Earth to get sucked in. Such was a concern in some quarters before the accelerator's upgrade. I'll remove the lunar sentence.
Answer: I agree with the previous answers which say that within classical GR there is no such thing as minimal BH size. However, there might be a limit if quantum effects are taken into account. In the absence of consistent theory of quantum gravity, it does not go beyond mere hypothesizing, but there are some conjectures which you are free to embrace or discard. Take this paper by J. Bekenstein as an example arXiv: gr-qc/9710076. In short, Bekenstein conjectures that the horizon area of a black hole can be thought of as an adiabatic invariant of a black hole which, according to the prescriptions of the old quantum theory, needs to be quantized. The size of area quantum turns out to be on the order of [Planck length]$^2$, which gives you the minimum BH radius.
Answer: Stars having mass as big as 25 solar masses are prone to collapse to form black holes, during the process a part of the star spills out and most of the part collapse to form a black hole, after a period of time the collapsed core after emitting its all energy into space; obtain a certain finite density and hence size.
Comment: As it's currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer).

Minimum size of black hole


When does a POA for Medical Come become effective

Question: Imagine a mother has given her adult son a POA for medical when she cannot speak for herself. After some time, she has dementia and needs to go to the emergency room. In the emergency room it is determined that she cannot make a rational decision about her health care. It is also determined that she is not a danger to herself or others. Given these two facts, would the POA give the son the right to force medical treatment (and possible a hospital stay) on the mother?
Answer: It would seem that the scenario you describe is the exact purpose of the document.
But, there may be specific requirements that are needed to become effective.  In my personal and recent experience, two letters from people "licensed to practice medicine" attesting to the disability were required, and one had to be from a primary care provider.
Bottom line, read the document - it should tell you when and how it becomes effective.
Answer: W.r.t. New Jersey law, I assume the mother properly executed this form whereby she

appoint[s] a health care representative with the legal authority to
make health care decisions on my behalf and to consult with my
physician and others.

The directive becomes operative

when (1) it is transmitted to the attending physician or to the health
care institution, and (2) it is determined pursuant to section 8 of
this act that the patient lacks capacity to make a particular health
care decision

but also

Treatment decisions pursuant to an advance directive shall not be made
and implemented until there has been a reasonable opportunity to
establish, and where appropriate confirm, a reliable diagnosis and
prognosis for the patient

Note that under NJ. Stat. 26:2H-57(d),

A patient who lacks mental capacity may suspend an advance directive,
including a proxy directive, an instruction directive, or both, by any
of the means stated in paragraph (1) of subsection b. of this section.
A patient who lacks mental capacity and has suspended an advance
directive may reinstate that advance directive by oral or written
notification to the health care representative, physician, nurse, or
other health care professional of an intent to reinstate the advance
directive

where the simplest method is

Notification, orally ...by any other act evidencing an intent to
revoke the document

i.e. saying "I revoke your medical power of attorney".
Assuming that didn't happen, there must be a medical determination of incapacity, which involves the attending physician and at least one other physician (also, neither can be the patient-selected health care representative). If the directive has been revoked, there would have to be a court procedure to have the son appointed as guardian.
Answer: No
For two reasons:

A power of attorney allows the attorney to make financial decisions. To make medical decisions you need a guardianship. These are two different things.
A power of attorney automatically lapses when the granger is no longer legally competent (which a dementia suffer may or may not be depending on the severity of the condition) unless it was set up as an enduring power of attorney.

The easiest way to get guardianship is to have the person grant it while they are still legally competent. Failing that, a close relative can apply to the court to be made guardian which may be contested by others (including the hospital). A legally incompetent person without a guardian is a ward of the state and there is usually a government organisation which handles the decisions for them.
Comment: Ohio allows a medical/healthcare power of attorney. Even if a guardian is appointed, the court has to state that it overrides an existing medical POA.
Comment: To back up the OP, I have a durable POA that covers medical and financial.  So, your answer is incorrect.
Comment: @Dale M Perhaps I did not state it correctly. I wrote: POA for medical meaning the purpose of the document is to give  power to the son for medical decisions.  It only goes in effect when the mother cannot make her own decisions. That is, it is durable.
Comment: Neither of these propositions is commonly true in the U.S., durable powers of attorney for medical care are common in the U.S. (durable jeans it survives the disability of the principal). I write maybe a dozen durable medical powers of attorney for clients each year.
Comment: The main difference between an MPOA and a guardianship is that an MPOA is only effective when the principal is incapacitated in the current moment as visible to the medical provider and that while it grants authority it can't be used to say no to a principal who is able to communicate and appear to have capacity. A guardian, in contrast, may force a ward to, for example, go to a nursing home or not have access to a doubtful treatment.


Azure Storage - Uploading .zip file with PowerShell

Question: I have an Azure DevOps build pipeline that includes a PowerShell task. That task uploads a file to Azure Storage. At this time, I've created the following script:
PowerShell Script
New-Item -ItemType directory -Path ./test
New-Item -Path ./test -Name "file.txt" -ItemType "file" -Value "hello world"

Compress-Archive -Path ./test/* -DestinationPath ./test.zip

$azureStorageKey = "<MyAccessKey>"
$storage_context = New-AzureStorageContext -StorageAccountName "mystorageaccount" -StorageAccountKey "$azureStorageKey"
Set-AzureStorageBlobContent -Context $storage_context -Container "mycontainer" -File "./test.zip" -Blob "temp/test.zip" -Force

This script successfully runs on my local machine and in Azure DevOps. While I can see the test.zip file in my Azure Storage account, it seems corrupted.
From the Azure Portal, I choose "Download" from the test.zip file blob context menu. The test.zip file gets downloaded to my machine. I then try to unzip the archive file by selecting "Expand All..." from the File Explorer on Windows. When I do that, I receive an error that says:
Windows cannot open the folder.

The Compressed (zipped) Folder 'C:\Users\me\Downloads\test.zip' is invalid.

Why does this archive file seem corrupt? It's fine on my local machine. But, when I download it from the Azure Portal, I can't extract the contents of the archive. What am I missing? Thank you for your help.
Comment: Have you checked the validness of test.zip before uploading it?
Comment: @ZhaoxingLu-Microsoft - Yes. The test.zip is valid before it's uploaded.
Comment: Any update this issue?
Answer: The issue seems caused by blob storage itself, I can reproduce your issue on my side.
Even if upload and download the compressed file(have test .zipand .rar type) manually in the portal(also test with v1 andv2 tier of storage account), it also gives the error.
You could open a issue in the github, besides, if it is possible, you could use file storage to do that, Managing Azure file shares with Azure PowerShell, it will work fine.
Update:
It may be a bug of azure portal, I download the compressed file in the storage explorer and upzip it,  it works fine. So you could try to use storage explorer to do it.


Should you show buttons in previews?

Question: A user can create a form for the users to fill in by adding input fields etc. They want to be able to preview this form and see how the fields look like for the user. They have no control over the submit button and cancel button. Should those buttons still be visible in the preview even though those buttons do nothing or should they be hidden? Disabled?
Comment: I think they should be shown in Preview mode. The intention for the whole feature is for the 'super user' to get a perspective on what the end user will see ultimately. There is no real reason to hide those buttons IMO. Disabled ? may be .. but that is still 'in view', that should be fine, if you have to disable. In preview mode, buttons dont trigger any action anyway (?)
Comment: The argument we are having inside our team is that the buttons aren't modifiable by the user so they will always be the same. Some in our team argue for that you should only be able to preview things you can change because that is what is directly relevant for you. Adding buttons would confuse them.

You are correct that the buttons wouldn't trigger anything if they were clickable in preview mode.
Comment: Now reading your post again.. '.. you wrote "A user can create a form for the users..." is there a difference between the two 'users'.
Comment: Yes, it's more like "An admin can create a form which are used by students" or something similar.
Comment: Why would the buttons confuse the Admin in Preview mode ? Preview is meant for making sure the look and feel is as per expectation-design. I would keep Buttons. You really need to hear a strong reason from the other side, for not displaying buttons in Preview mode.
Comment: I agree with you but some in my team are making the case that having buttons that don't do anything is useless and don't add anything to the preview. Furthermore, some say use disabled buttons because if the buttons don't do anything then they shouldn't be clickable.
Comment: I'd rather the buttons exist in the exact location and format as the official page, but just send me a quick message when I click the action, telling me that this is only a preview.
Answer: By all means, Preview means to show what user will see when they act on. It's like a final rehearsal before doing the actual action. If Preview is missing some elements, it misses the point. What if buttons don't look like user wanted? Or located not where they wanted? Or named not like they wanted? Yes, they have no means to change that, but giving them a hint of how the final form will look like is a good UX practice. And the buttons should not be grayed out or somehow else visually affected. We want the preview to be a carbon copy of actual form.
If you like to look at an example of a good preview, try Facebook ads. You will see your ad as other users will. There are all kinds of buttons, images etc, but none of them are clickable.

Should you show buttons in previews?


How can I find out which enchantments that I know?

Question: In Skyrim, there is an Enchanting mechanic. You learn an enchantment by disenchanting something with that type of enchantment. Other than by visiting an Arcane Enchanter, is there a way to find out which enchantments that I've learned? This will help me by reducing the amount of enchanted weapons that I hoard by letting me dispose of items whose enchantments I already know.
Answer: There is no way to know which enchantments you have learned other than visiting an arcane enchanter or keeping track of it manually.
Answer: Or there is a Mod on Skyrim Nexus that appends the name of items that are currently disenchantable by your character with a (U). it's called "Unknown Enchants".
Link: http://www.nexusmods.com/skyrim/mods/32380/?
Comment: This mod is no longer available.


Adding colormap to add_collection (surface in 3d plot)

Question: I am making a 3 sided pyramid I have made the sides using add_collection3d(Poly3DCollection
But I want to add a colormap based on the z axis so that the top is red and it gradually change to blue but the details does not matter. I tried the cmap option but that does change the color.
I have added a script with one side to illustrate the problem.
from mpl_toolkits.mplot3d import Axes3D
from matplotlib import cm
import matplotlib.pyplot as plt
import numpy as np
from mpl_toolkits.mplot3d.art3d import Poly3DCollection

fig = plt.figure()
ax = Axes3D(fig)

#Pyramid side 1
xp1 = [1.1184,2.46,2.46]
yp1 = [0.5592, 1.23,2.73]
zp1 = [-1.5,0,-1.5]
verts1= [zip(xp1,yp1,zp1)]

cmhot = plt.cm.get_cmap("hot")
ax.add_collection3d(Poly3DCollection(verts1,cmap=cmhot))

ax.set_xlim(0,5)
ax.set_ylim(0,5)
ax.set_zlim(-2.5,5)
plt.show()

Why does this not work?
Many thanks in advance.
Answer: You have to convert zip into list format
list(zip(xp1,yp1,zp1))


Arcane Archer - Piercing Arrow Half Damage

Question: For Arcane Archer, when a creature is hit by piercing arrow but passes their save do they take arrow damage (1d8,1d10,etc) + half of 1d6 + modifiers or does it take half of arrow damage + 1d6 + modifiers?
Answer: Half of (arrow + 1d6 + modifier).
The text of piercing arrow says:

On a failed save, a creature takes damage as if it were hit by the arrow, plus an extra 1d6 piercing damage. On a successful save, a target takes half as much damage.

Compare this to fireball:

A target takes 8d6 fire damage on a failed save, or half as much damage on a successful one.

When a creature succeeds a save and takes half damage, it means that they take half of the damage they would have taken on a failure.
Answer: A creature who passes the save takes half of your regular damage with that weapon. The extra 1d6 piercing damage is only for those who fail the save.

"On a failed save, a creature takes damage as if it were hit by the arrow, plus an extra 1d6 piercing damage."
Comment: I don't think this is the correct interpretation, as fireball uses very similar text, but we know "half as much" means 8d6 / 2 in that scenario.
Comment: "Takes half as much damage" means "takes half as much damage [as they would have if they had failed the save]". There's no basis for the meaning you suggest ("takes half as much damage [as they would have from the arrow component of the damage they would have taken if they had failed the save]"). I even had to invent the concept of "arrow component of damage"!
Comment: You know what, true. If they didn't want to include the extra 1d6 it would have been clear.


Why can't I expand this event object in the chrome console?

Question: Simplified, what I'm doing is running this in the console:
window.onbeforeunload = function (e) {
    console.log(e);
}

In the console, when the event fires (by trying to "leave page" in the middle of writing an SO question) what I see is this:
Event {clipboardData: undefined, cancelBubble: false, returnValue: true, srcElement: document, defaultPrevented: false…}

With a little "i" graphic next to it. When I click the arrow next to it to expand the object in the console, nothing happens. The arrow turns to indicate that it has expanded, but it doesn't expand.
What am I missing here??
Answer: This is happening because although you're letting the console persist over page changes, the Object no longer exists - it was destroyed when you left the page. This means it's simply not available to be inspected anymore, so clicking the down triangle is not helpful.
Try this instead, to prevent the page actually changing:
window.onbeforeunload = function (e) {
    console.log(e);
    return true;
}

Now the page will prompt to ask you what to do. Click 'cancel' in the prompt that comes up in order to remain on the page. Now you can inspect the Event in the console as desired.
The difference is that the onbeforeunload function is now returning a value that isn't null/undefined. The return value could be anything, even '' or false, etc...anything except null and undefined, and it will still cause the page to prompt before navigating away and thus giving you an opportunity to inspect the event. Remember that with no return statement, JavaScript functions return undefined by default.
Whenever you can't inspect something in the Chrome Dev Tools, 90% of the time it's because some action has caused that thing to become unavailable...the page has moved on from when that object existed.
Answer: The failure to expand can mean that the object was subsequently removed from memory: possibly deleted or garbage-collected, or (especially if you're using Chrome dev tools on a Node.js script) it could be that the script completed, so all refs now point nowhere.

It's a good practice when inspecting objects that can change later to drop in a debugger instead of console.log:
window.onbeforeunload = function (e) {
  debugger; // Now go find `e` in the local variables section
}

This pauses the execution of the code, so you know for sure you're seeing what the variable was at this point, rather than seeing any subsequent changes.
This way, you can access more context and don't need to worry about changes to output caused by what happens later in the code.

Always remember that in JavaScript, any time you deal with a variable that points to an object, you're dealing with a live reference, to the latest state of that object.
console.log logs the reference, not the object's contents, and when you view and expand the logged reference, you're viewing what that reference points to at the time you look at it, not the time you logged it. This might be nothing if it has been removed from memory or reassigned.
Variables pointing to primitives like strings and numbers point to values not references, so you could also:

log a stringified version of the object, like console.log(JSON.stringify(someObject)) (although that output may be harder to read).
if the object's properties are all primitive, log a shallow clone like console.log({ ...someObject }) (though any properties that are objects may face the same problem)

The debugger approach is usually better.
Answer: Old question. But this simple solution worked better for me. Use
function(e) {
  console.dir(e);
}

Answer: I just came across this question with a problem I had where my API PUT request was showing as cancelled in my console tab in chrome dev tools and I was seeing the same behavior where I couldn't expand the object and the little i icon was showing next to the console entry. I decided to post this answer with a link to my question in case it might help anyone else.
Api PUT request showing as "cancelled" with error message "TypeError: failed to fetch"


How safe is it to use a used MacBook Pro with t2

Question: I just got my self a used MacBook Pro 2020 with the T2 Chip. I'm wondering how secure is it to use the Mac. I heard about a security breach in the t2 Chip what means there could be malware on the chip. Does that malware get removed by updating the macOS / reinstalling macOS ? What steps should I 100% do before using it ? Should I reinstall bridgeos? Would be interesting to know.
Comment: Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.
Comment: The question is: how likely is it that the seller has infected the T2 chip on this Mac, as a means of doing something malicious? Selling infected laptops is a high-cost, low-yield strategy for badness.
Answer: I had to read up on it, but I found this article in Wired magazine with this key quote:

There are a few important limitations of the jailbreak, though, that keep this from being a full-blown security crisis. The first is that an attacker would need physical access to target devices in order to exploit them. The tool can only run off of another device over USB. This means hackers can't remotely mass-infect every Mac that has a T2 chip. An attacker could jailbreak a target device and then disappear, but the compromise isn't "persistent"; it ends when the T2 chip is rebooted.

Thus, it doesn't expose you to malware on the web. Somebody would need to plug a device into the USB port on your Mac in order to exploit it. So as long as you keep your Mac physically secure you should be okay.
Apparently the T2 chip isn't always rebooted when the Mac is rebooted. I'm not sure if a full power-down powers down the T2 or not; I would think so, but would want to research it.
Somebody needs to come up with a utility that lets you check the status of the software running on your T2 chip to make sure it hasn't been compromised. (Of course that utility could be a vector for infection, so you'd have to have a good chain of trust for that utility.)
Comment: Now, if I understand it correctly, the person I bought the Mac from would not have been able to install malware on the t2 chip, it would need a USB stick plugged in to run? I read somewhere that people are able to read and write code on the t2 chip it self which gives them the ability to infect your system no matter how often you reinstall the os
Comment: the person you bought it from could have installed malware on the T2 chip if they new what they were doing since they had physical access. You only need to have something plugged into USB to infect it, and then until the next time the T2 chip is restarted it will be infected.
Comment: So if I would restart the t2 Chip I'm safe? How to restart the t2 Chip too? Aren't people able to write stuff on the chip it self or does that only last until the restart ?
Comment: From the article I linked in my answer, malware installed on the T2 chip only persists until the chip is restarted. The article goes on to say that it isn't certain that the T2 chip gets restarted when you restart your Mac. I'd suggest fully discharging your battery and letting the machine completely die. That should force everything to shut down. (I don't know if a normal power-down also powers down the T2 chip.)
Comment: In the article they also say they suggest resetting the chip to factory state/default settings. Any ideas how todo so ?
Comment: No, sorry. I learned about the vulnerability from that article.


system files application

Question: How to open/access app file folder such as; device;sdcard;emulater0; sdcard emulater; and what do they mean?  when i try to open them it says "doesn't have app to view" What is a good app to get to view them? do i need to do it on a computer? Also  Facefile says no media with a bunch of letters  What is this?; How to view Thumbnailsin the file folder?  thank you in advance for any help with this. i have a samsung Galaxy s3
Answer: I would try ES File Explorer. It's a really useful manager and could probably open it.
If not, you can use Root Explorer. Yes, you will need root, and yes, it costs, money. But if you change your system files a lot it's a really great tool. Plus, you have a 2 hour trial period after you purchase, so if it doesn't work you can get a refund.
Answer: First off you need to root your device and after that you can download root explorer(paid) to acess that file
You can download via torrent if you don't wanna pay for the app
For root you can check xda developers

system files application


How to use HTTPS in an ASP.Net Application

Question: I want to use HTTPS in my ASP.NET web application, but only for the Login.aspx page.
How can this be accomplished?
Answer:
First get or create a certificate
Get the SecureWebPageModule module from http://www.codeproject.com/Articles/7206/Switching-Between-HTTP-and-HTTPS-Automatically-Ver.  Instructions for setup can be found in the article.
Add secureWebPages tag to web.config
<configuration>
    ...
    <secureWebPages enabled="true">
        ...
    </secureWebPages>
    ...
    <system.web>
        ...
    </system.web>
</configuration>

Add files and directories to be use for https protocol:
<secureWebPages enabled="true">
    <file path="Login.aspx" />
    <file path="Admin/Calendar.aspx" ignore="True" />
    <file path="Members/Users.aspx" />
    <directory path="Admin" />
    <directory path="Members/Secure" />
</secureWebPages>

Hope this helps!
Comment: The SecureWebPageModule project has been renamed "SecuritySwitch", and can be found at [http://code.google.com/p/securityswitch/](http://code.google.com/p/securityswitch/)
Answer: You can publish your own certificate or you can purchase one.  The caveat is that purchasing one, depending on the company, means that it's already stored in the certificate store for most browsers.  Your self published one will not be and your users will have to take the extra step of installing your cert.
You don't say what version of IIS you're using, but here are some detailed instructions for IIS 6
You can purchase relatively cheap certs or you can go with the big boys (verisign) and get an extended validation certificate which turns your address bar in IE, green.  It's also a somewhat rigorous validation process and takes time.
If you know all of the users that will be hitting your website, there's no problem with installing your own.  However, for an open website with anonymous users (that you don't know), it's probably best to purchase one that is already in most major browsers, certificate stores.
You can enable SSL via IIS and require it for only your login.aspx page and not for the rest.
Answer: After you get SSL setup/installed, you want to do some sort of redirect on the login page to https://. Then whatever page the user is sent to after validation, it can just be http://.
Protected Sub Page_PreRender(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.PreRender
    If Request.IsSecureConnection = False And _
        Not Request.Url.Host.Contains("localhost") Then

        Response.Redirect(Request.Url.AbsoluteUri.Replace("http://", "https://"))
    End If
End Sub

This may be easier to implement on a master page or just all the pages you require https. By checking for "localhost" you will avoid getting an error in your testing environment (Unless your test server has another name than check for that: "mytestservername").
Comment: i don't know how to redirect login page with HTTPS:// that is my problem. thanks
Comment: Add Guiness' code to the page that contains your login control. I'd probably actually move it to the top of page_load, or into OnInit, as that saves processing everything else, but this will work nicely.
Answer: disclaimer - I was involved in the development of this project
I would recommend using http://nuget.org/packages/SecurePages/ It gives you the ability to secure specific pages or use Regex to define matches. It will also force all pages not matching the Regex or directly specified back to HTTP.
You can install it via NuGet: Install-Package SecurePages
Docs are here: https://github.com/webadvanced/Secure-Page-manager-for-asp.net#secure-pages
Simple Usage:
SecurePagesConfiguration.Urls.AddUrl("/cart");

or
SecurePagesConfiguration.Urls.AddRegex(@"(.*)account", RegexOptions.IgnoreCase | RegexOptions.Compiled | RegexOptions.Singleline);

Comment: Thanks for posting your answer! Please be sure to read the [FAQ on Self-Promotion](http://stackoverflow.com/faq#promotion) carefully. Also note that it is *required* that you post a disclaimer every time you link to your own site/product.
Answer: You can enable HTTPS in your IIS config, but it won't be "secure" unless you acquire an SSL Certificate and plug it into IIS. Make sure you have port 443 open.


Significance of Sharabha avatar defeating Narasimha?

Question: What is the spiritual significance of sharabha avatar pacifying Narasimha avatar ?
Answer: spiritual significance of narasimha-sharabha battle is to glorify anyajanma tirtha & narasimha returning to vishnu form as described in vamana purANa ch. 36 :

28. A holy place anyajanma falls on the east from saraka. It is popular throughout the three worlds.
29. Attaining the form of a lion and slaying the powerful demon, lord Visnu then dwelling among the animals developed affection for lions.
30. All gods including Gandharvas the worshipped lord Siva, saluted him and prayed to him to manage the situation. They explained that the
return of Nrsimha back in the original form of visnu has become
necessary.
31, 32, 33. Mahadeva disguised himself as Sarabha and fought against Nrsimha for several thousand divine years. Both gods fell
into a reservoir while fighting. Divine hermit Narada was in
meditation on the bank of that reservoir under a pipala tree. He was
suddenly disturbed and looked at them. Lord Visnu turned in his
original form and Siva in the form of a linga. Narada duly
worshipped them.
35. Salute to god Siva, salute to impressive Visnu. Salute to administrator god Visnu and the god of destruction Siva.
36. Salute to Hara of varied forms and Visnu of universal form. Salute to great merciful tyambaka and krsna, the cause of knowledge.
37, 38. I am lucky and noble as I could see simultaneously both purusas. My asrama purified by you has indeed become sacrosanct.
This place shall gain popularity as anyajanma throughout the three
worlds.

mahAbhArata vanaparva ch.LXXXIII also has an anecdote to above tirtha:

To the east of Saraka, O chief of the Kurus, there is an
auspicious tirtha known by the name of anyajanma, of the
high-souled Narada. He that bathes there, O Bharata, obtaineth,
after death, at the command of Narada various unrivalled regions.