Why does ISIS continue to do things to make their "enemy" even more determined to go after them?

Question: Why do groups such as ISIS and Al Qaeda continue use terrorism attacks, which only do temporary physical damage. It seems to have the primary effect of aggravating huge military entities such as N.A.T.O or the U.S.
The swift downfall of Al Qaeda's power after the 9/11 attacks is an example of such a thing happening, and considering that ISIS started as a small branch of Al Qaeda they have seen this kind of thing happen firsthand.
So I am confused why they continue to do the same thing instead of any alternative ways to achieve their goals?
Comment: Related: https://politics.stackexchange.com/questions/4980/why-is-isis-taking-hostages
Comment: Various comments deleted. Please don't try to answer questions with comments.
Answer: The stated goal of ISIS is to eliminate "the grey area". Today there is a sizeable minority of Muslims living in western society. ISIS wants to show that it's not possible for Muslims to live in the western world. Their method is to perform terrorist attacks in the hope it will cause a backlash against Muslims living in the western world.
ISIS states this very clearly:

"the time had come for another event to … bring division to the world and destroy the grey zone"

and:

"the world today is divided into two camps": that of kufr, or unbelief, and that of their own warped interpretation of Islam. In between these lies the "grey zone", inhabited by those who call themselves Muslims yet fail to join Daesh."
Comment: @Sidney Don't think of them as evil crazy people. Their brains aren't damaged - they just have a different set of values and goals. The same strategy was applied over and over in history, and some of the ISIS leaders may have even had personal experience with it back from the Cold War. And don't think they have *one* goal, and *one* strategy - in any asymmetric conflict, you're basically trying to cause an auto-immune response in the target - make them expend huge amounts of resources and damage themselves, wildly out of proportion to the actual threat (and more importantly, your own costs).
Comment: Well, this is sinister. I much preferred just assuming they didn't like the white devils of the west
Comment: @EpicKip If it took brain damage for humans to do bad things, the world would look quite a bit different. It's sad, and we need to change that, but claiming that The Enemy is brain-damaged isn't helping - it's the exact same attitude The Enemy has against you (that is, "they're not really human, so it's okay to kill them/force them to do what you want"). It usually takes that kind of framing for a human to willingly kill another human, but that's *all* it takes, as history shows and evolutionary "behaviorology" explains.
Comment: Post hoc self rationalizations and stated goals are not explanations.
Comment: Also they want the west to get involved in multiple conflicts that they can not win. The hope is that this will bankrupt countries involved overtime just as the prolonged Russian invasion of Afghanistan helped in the collapse of the USSR.
Comment: @mega_creamery Not quite. They want to "Bring the end of times" by bringing about the Armageddon, if you can call it that, between "Islam" and "Christianity". They think it will fulfill some prophecies and the world will end. They don't care about winning those conflicts militarily or through attrition.
Comment: I don't see how this answer addresses the question let alone provides a correct answer.  I read the question as, "why would ISIS choose a strategy that could easily lead to their destruction?"  They may intend to cause a backlash, but that's separate from why they are not worried about the long game of their strategy.
Comment: @someguy that's what you think. Oil wars have been around long enough and they're not rare, and you can call it an oversimplification but I'll call it the truth. Just because governments blame something/someone else for a war did not mean its not about oil/money.
Comment: @Lee: The answer is correct, albeit incomplete. The point is that eliminating the grey zone means more potential recruits for them, and thus more power for their leaders. Moderates won't willingly join Daesh, and they need plenty of blood for their wars. This is the same for far right (and other radical movements) all over the world, really.
Comment: Can you even read your own quotes? Western world is "kufr", end of story. Shi'a, moderates like Tunis etc. r clearly "warped interpretation" as per Sunny fundamentalist ISIS. "grey area" r those who are "true enough Muslims" (as per ISIS) to even be considered as those that can join in with ISIS, which of course sees itself as the pinnacle of "true Islam" (as per ISIS). ***NO***, the goal is to escalate, cause civil war ***inside*** the Muslim world and force more of the "true Muslims" to join in with ISIS. As per your own quotes. (And ***then*** conquer the world of kufr, but that's a given).
Comment: ... and of course, to win that civil war and take control of the whole Muslim world. (and then attack the West... I think we've all seen the quotes about conquering Rome etc.) So they want to provoke  West's aggression to cause civil war *inside* the Muslim world, to make life very hard for "good Muslims" (per ISIS), causing them to seek their defender in ISIS and join in. this is exactly what happened with Mosul's Sunny population few years back, that's why they welcomed ISIS as their protector. Where once were stable half-secular states, now lay vast areas ripe for ISIS control.
Comment: @Luaan Even if its done before or there is some sort of thought behind their "plan" doesn't mean their brains aren't damaged, if you act like that your brain is damaged in some way for sure.
Comment: @Luaan As long as anyone blows up themselves and a load of people that have nothing to do with the fight/discussion than that person definitely has brain damage. This is not a "normal" war about money etc. this is a bunch of extremists that bomb people, there are no 2 sides to this (I say this mainly because I strongly believe in freedom of speech and if they bomb us for what we think or say its not 2 sided)
Comment: @EpicKip "Normal" wars have to consider the aftermath (regardless of whether the war is won or lost). When you start on a genocidal rampage, there is no aftermath (or so you think); the gloves come off. And it's nice that you believe in freedom of speech, but that's your ethics. Theirs don't include freedom of speech. Indeed, many people who endorse freedom of speech don't really believe it, at least not fully - surely you know people who'd harm a person who offended them (and even feel good about it). Don't focus on "islamists" - Europe was so much fun for most of the 20th century :)
Comment: @Luaan Many wars do not consider aftermath, and when one tries to exterminate people who don't think like him I would definately call that brain damage. Also I am from Europe and know plenty of turkish/maroccan/egyptian people that are all muslims, its just the terrorists I hate with all my hearth (and honestly anyone who supports them, stupidity is not an excuse)
Comment: ISIS has been making the Germans angry lately. Looking forward 10 years or so I am concerned what effects ongoing economic problems in the EU, stress and pent-up resentment and anger will have on the German political climate. History has shown us a very angry Germany is not a good thing.
Comment: @EpicKip one could argue that war for money is much more depraved and abnormal than a war for ideals (like cold-blooded murder vs a crime of passion). In fact big wars were never "for money". That meme (that wars are fought for money) is a very recent Western invention.
Comment: @someguy so the oil wars are not wars?
Comment: @EpicKip what "oil wars"? -- you said "war about money" was "normal". no war is normal except in self-defense.
Comment: @someguy ... seriously?... what oil wars? `In fact big wars were never "for money".` this depends on what you call big. America bombing countries for oil is what I call big enough so there have been big wars for money.
Comment: @EpicKip which countries did America bomb for oil? Afghanistan? (no) Iraq? (no) Libya? (no). I can't think of any other that you might have meant here. Could you give me its name please?
Comment: @someguy you can say (no) all you want but its Iraq. Google oil wars
Comment: @EpicKip this is an oversimplification of enormous proportions.
Comment: `the world today is divided into two camps": that of kufr, or unbelief, and that of their own warped interpretation of Islam.` If I understood the source correctly, that's from an ISIS spokesperson, in which case ..in which of those two camps does ISIS consider themselves? The latter, I guess. But then... do they admit their interpretation of Islam is *warped*?
Comment: @xDaizu That is (non-Muslims (kufr/unbelief) and liberal Muslims ("that of their own warped interpretation of Islam")) versus Daesh (ISIS).
Comment: @liftarn ...so, for them, the world is divided in **3** camps: non-muslims, liberal muslims and them *("proper" muslims?)*, isn't it?
Comment: @xDaizu No, still just two, it's them vs everybody else.
Answer: This question seems a little like why do terrorists commit terror?
The aim of a terrorist group isn't usually to be left alone, but more to provoke conflict, or as a form of violent protest against what they believe is a wrong.
You are mistaken when you claim terrorism

only do temporary physical damage

The value in a terrorist attack isn't really the attack itself, but the reaction that accompanies it. People and governments react to terrorism by becoming more fearful of certain subsections of the population, fearful to carry out actions they may previously have no problem in doing (e.g. going to a concert, boarding a plane etc.) or fearful of the group itself i.e ISIS/ Al-Qaeda.
All three of these things benefit terrorist organizations:

Fear of a certain subsection of the population (e.g. Muslims) - Leads to oppressive laws and environments for them to live in for example racial profiling, watch-lists/registry, a rise in hate crime and other generally discriminatory things.. When people are oppressed they are more susceptible to an extremist ideology - so more recruitment for the organization.
Fear of carrying out normal actions - one of the major ways to win a war or any form of war is to disrupt normal life in your enemy state.
Fear of the group - the ultimate macho objective, if people think your group can go head to head against the country with the most powerful military on earth and cause significant damage (9/11) - then suddenly they want to negotiate with you, join you etc. you gain a lot of soft power, and ability to blackmail e.g Give me X or I will bomb the whitehouse

Another point you seem to misunderstand is that you think they are thinking about western retaliation to their attack. Most terrorism is usually in retaliation to something the west did in the first place. From the terrorists perspective they are the ones committing the retaliation or "evening things out". For example the 2013 attack on Lee Rigby was committed in retaliation to the Invasion of Iraq and atrocities committed by coalition forces. Edit in request for more examples: The November 2015 Paris attacks were claimed as a response to French Airstrikes in Syria, Stated motives for the 9/11 attacks include US military presence in Saudia Arabia and UN Resolution 661, a friend of one of the 7/7 attackers claims that he often watched "videos of Muslim suffering around the world inc Palestine and Chechnya" and this may have motivated the attack in the BBC Documentary "Biography of a Bomber", the Boston Marathon bombings were allegedly done in response to U.S. wars in Iraq and Syria. Edit thanks to bain for pointing out that the 7/7 attackers left pre-recorded videos, where they claimed there motivation to be "Your democratically-elected governments continuously perpetuate atrocities against my people all over the world. And your support of them makes you directly responsible". Source.
You also mention

do the same thing instead of any alternative ways to achieve their goals

This is a false premise, terrorist organizations do several other things to achieve their goals including capturing territory, enforcing laws and spreading propaganda.
Another thing you claim is:

The swift downfall of Al Qaeda's power after the 9/11 attacks is an example of such a thing happening, and considering that ISIS started as a small branch of Al Qaeda they have seen this kind of thing happen firsthand.

It could be argued that this isn't really true since a vast number of ISIS recruits were originally members of Al-Qaeda and they share a very similar ideology. In fact ISIS is much bigger and stronger than Al - Qaeda ever was and at their peak controlled upwards of 100,000 sq km of land and has tens of thousands of foreign fighters. In their eyes they've gotten a lot stronger.
In conclusion terrorism is part of the eternal cycle of "he hit me first" or to quote Exodus 21:24 "An eye for an eye", and generally has worked to provoke a response from the west, which has further aggravated an oppressed population who are then more likely to support a terrorist group who then commit another attack who then ..... cycle goes on.
So to be incredibly cynical in a terrorists eyes: the question isn't why it's why not.
Further Reading

Why do terrorists commit terror? - Peter Bergen (NY Times)
What motivates terrorists? - Simon Cottee (Atlantic)
Causes of terrorism - Amy Zalman PHD (ThoughtCo)

Just to be clear I abhor terrorism but if we really want to get to the bottom of why someone does something we have to examine our actions also
Comment: An excellent example of that reaction is the recent car crash in Times Square.  There was almost an audible sigh of relief from the nation when it was found that "Oh, it's just another DUI.  No terrorism here folks!"  This despite the fact that DUIs kill orders of magnitudes more than terrorists.  We simply respond so strongly to terrorism.
Comment: While this may be true for Islamist terrorism, it isn't quite true for _all_ terrorism. The IRA was notable for trying to _avoid_ civilian casualties during its campaigns, preferring to target economic and military targets, such as the 1996 manchester bombing which killed zero people, but is still the largest bomb detonated in england since WW2 and which caused nearly $1bn in today's dollars of damage. Or perhaps the Weather Underground who (for most of their attacks) made sure they hit symbolic and unoccupied targets. These groups do not fit the characterization given in this answer.
Comment: This is also a cycle, as the west continues to bomb terrorists(in retaliation to attacks) but harm civilians, the civilians are more likely to join or support organizations like ISIS.
Comment: Can you cite the "most terrorism is usually in retaliation to something the west did in the first place" a little more fully, one example doesn't really define a majority.
Comment: @SleepingGod It's better, the meaning of Exodus 21:24 is more or less what you say. The context is the opposite, though: the idea there is that you need to limit your retribution to no more than an eye for an eye, etc., so as to not escalate conflicts. (Note: I'm not easymoden00b)
Comment: +1 for the detailed info on retaliation as a motive. Attacks and civilian killings happen both sides --- it's just that when [US air strikes kill civilians](https://www.google.com/search?hl=it≷=it&tbm=nws&authuser=0&q=US+air+strikes+kill+civilians) it barely makes the news in the West.
Comment: @veryRandomMe Sure thing, ive updated the answer with another few examples with citations. Are there any other parts you'd like me to expand on?
Comment: A couple of other things terrorism may cause are:  It may cause the what to other (countries) may seem like an (violent) over-reaction - eg. a limited terror-attack is answered with a full-scale attack, that kills a large number of civilians.  It may cause increased government survailence (especially of certain political/religious/ethnic groups), freedoms may be limited (censorship, f. of movement and travel), soldiers in the street, and decreased protection if suspected for a crime - ie. things not really mixing with that of the ideal free democracy.
Comment: @Knetic Well, that goes into the area of "Terrorists or freedom fighters?" There's a violent conflict. You are convinced you're right, but your oppressors (imagined and otherwise - this is really a spectrum) are stronger. So you choose strategies that minimise the enemies advantage, or outright uses their strength against them. IRA wanted to break the hold of the British, but the last thing they wanted was to turn people's opinions against themselves - indeed, they really needed popular support in both Ireland and England, Robin Hood-style. The same isn't true of ISIS, but may be for others.
Comment: the way isis described the manchester attack "we killed some crusaders" is pretty much the report westerners get every time a western bomb blows a wedding to pieces in the middle east "we killed some terrorists". seems like they made a point to parrot the same rhetoric
Comment: @inappropriateCode that Wikipedia article says _"The IRA said it had made a mistake and that its target had been the British soldiers parading to the memorial. The bombing was strongly condemned by all sides and weakened the IRA's and Sinn Féin's support for its campaign."_. The ultimate aim of a terror campaign is to strengthen support for the cause, not weaken it. A strategy of targeting police, security forces, & economy is notably different to a strategy that targets civilians, even though in the end both result in civilian deaths.
Comment: @inappropriateCode All weapons are "indiscriminate". The IRA issued apologies for civilian deaths numerous times during the Troubles, and after. I don't claim to hold up the IRA as some kind of virtuous organization, but the point stands that modern Islamist terrorism _doesn't_ apologize for civilian casualties, it craves and relishes in them, and that's very different than what used to happen. Before 9/11 a plane hijacking was mostly to take hostages and demand ransom or political asylum. It still stands that terrorist tactics have not always been identical to Islamist tactics.
Comment: Matthew 5:38 means [almost exactly the opposite of what you're claiming it does](http://biblehub.com/bsb/matthew/5.htm)  Perhaps you mean Lev 24:19-21, [A section on Judaic law, something superceded by the doctrine espoused by Christ in the Sermon on the Mount](http://biblehub.com/bsb/matthew/5.htm)
Comment: @Charles I've strikethroughed that particular line, it is like the least consequential part of this answer and was receiving a disproportionate amount of attention - this answers key theme is the causes of terrorism not biblical interpretations
Comment: @SleepingGod I think yours is an excellent answer (+1), thanks for putting up with the pedants trying to improve it. :)
Comment: That would not be blackmail. It would be extortion.
Comment: The evidence that the 7/7 attackers were motivated by desire for what they saw as retaliation is even stronger than suggested - the attackers [left pre-recorded videos](https://en.wikipedia.org/wiki/7_July_2005_London_bombings#Videotaped_statements) explaining their motivation - quote _"Your democratically-elected governments continuously perpetuate atrocities against my people all over the world. And your support of them makes you directly responsible"_
Comment: All weapons are not indiscriminate.  That is why we arm police with accurate rifles and not explosive devices.  A person may use a firearm indiscriminately but that is not the same as being an indiscriminate weapon.
Comment: @Knetic I think we can agree on that point, certainly.
Comment: @easymoden00b I've changed it to Exodus 21:24 is that better?
Comment: Terrorism was once defined as "kill a few, scare millions".
Comment: @bain I've updated the answer with your evidence, thanks for that!
Comment: @Knetic "The IRA was notable for trying to avoid civilian casualties during its campaigns" [Where did you hear that](https://en.wikipedia.org/wiki/Remembrance_Day_bombing)?  [It was only luck which saved 50 children and their parents from a 70kg bomb.](http://www.apnewsarchive.com/1987/Police-IRA-Planted-Bomb-in-Town-Near-Enniskillen-That-Didn-t-Explode/id-61973ff2d09ef7925a981f7ee2ea991f) Trying to avoid civilians?  Hah!
Comment: @bain They targeted [both military and civilian targets](https://en.wikipedia.org/wiki/List_of_bombings_during_the_Northern_Ireland_Troubles_and_peace_process). Bombs are indiscriminate weapons, the choice to use them routinely, and especially on civilian targets, with and without warning, is all the evidence you need that their strategy was not limited to military and economic targets.
Comment: @Knetic To say all weapons are indiscriminate is absurd.  A bomb isn't the same as a rifle.  It's true that the tactics and beliefs of terrorist organisations vary, but to claim that the PIRA was "notable for trying to avoid civilian casualties" will not sit well with a lot of people.  For every time they gave a warning about a bomb, there's another time they didn't.  For every attack on a soldier, there was an unarmed victim.  Two thousand civilians died during that era, and Republican groups did their share.  How many Jihadis will apologise for their crimes 30 years from now?  We don't know.
Comment: @inappropriateCode We're getting drug into the weeds. This answer claims to group all terrorism under one umbrella and explain them all; but if you took any non-Islamist group and tried to apply this answer's logic to them this answer would not make the slighest bit of sense. It doesn't matter if it's the IRA, the WU, late-19th anarchists, whomever. I'm not arguing that some terrorists are better or worse than others because they killed fewer civilians in proportion to soldiers, what I'm saying this that this answer paints with too broad a brush and loses connection with reality because of it.
Comment: @CortAmmon have you seen the video? driving perfectly straight on a street, then making a perfect 180 on an intersection into a sidewalk and then  driving perfectly straight again on the sidewalk is not an accident, quite self-evidently.
Comment: this answer is delusional and stupid too smart for its own good, judging ISIS by your own good self as it does, my good Sir. Yes for the West it indeed is a cycle of violence because West is not aggressive by its nature right now (does not dream to conquer the world). ISIS on the other hand is on the world conquering quest right now. They initiate, not react. Them speaking of retaliations is black propaganda, just to confuse the feeble-minded. With lots of success, evidently.
Comment: @inappropriateCode I vividly remember the oft-repeated and almost mundane CNN/SkyNews reports of "large London areas evacuated in advance of an IRA phoned-in bombing". as far as I remember, they always phoned in 2 hours in advance before a bomb would go off in London (and elsewhere, presumably... not sure about the Northern Ireland). one exception was Omagh bombing, yes? this is my recollection anyway. No, I'm not from UK. Reading your comments, it seems I was ill-informed by those "news channels"?
Comment: @inappropriateCode the real datapoint would be to know, for what percentage of their bombings did they give warnings?
Comment: @someguy They didn't always phone in, and sometimes when they did it was too short notice, or ambiguous.  Enniskillen bombing was presented as an exception, but that's too generous, and Omagh was RIRA not PIRA so it's an outlier.  [Have a look](https://en.wikipedia.org/wiki/List_of_bombings_during_the_Northern_Ireland_Troubles_and_peace_process).  Never mind the aforementioned bomb which could have killed 50 children and their parents in Enniskillen which didn't go off by pure luck.  Policy was said to be to give warnings prior to civilian targets, but it wasn't fool proof or consistent.
Comment: @inappropriateCode so there was a policy, after all. thanks for clarifying that. so what percentage was phoned in, excluding the clearly military targets? above 90%? above 95%?
Comment: @someguy I do not know, that'd require some research.  One would have to decide how and why to filter that, based on whether message was received, intelligible, acted upon, or its absence was because PIRA could not send the message rather than did not want to.  And then of course check what may have been typical for different branches of the IRA, as the PIRA were not the only one.
Comment: Let us [continue this discussion in chat](http://chat.stackexchange.com/rooms/59605/discussion-between-inappropriatecode-and-someguy).
Answer: Many answers here are attempting to answer your question in a similar perspective, and they are all extremely interesting and most of them seem very well documented.
What I'll offer you is an attempt to destabilize some "absolutes" that emerge from both your question and most of the answers that I do not find so obvious. Forgive me if this is a rebuttal-question by itself more than an answer, I can see the shower of downvotes coming but I think it's still worth it if at least a little bit of reflecting will follow from my answer.

("racist stereotypical elements" are used on purpose, and if someone thinks I'm condoning terrorism... You're missing my point by quite a lot)
Imagine a person your age and gender sitting on their carpet somewhere in the Middle East (it is well known middle-easterns don't have chairs), typing on their keyboard full of weird wiggly symbols we don't really understand. They're writing on the Middle-eastern equivalent of politics.stackexchange and their question is:
Why does Western Governments continue to do things to make their "enemy" even more determined to go attack them?
Maybe they're asking this question after the thousandth drone strike killed tens of civilians out of the blue in a crowded market. Except for the fact that they could almost have gotten used to it (I can't even imagine what it means to get used to such stuff), probably the first time they saw children and women torn into pieces it felt not too different from what those people in Manchester have experienced.
What would then be the Middle-eastern versions of the answers we are getting here? Would they sound similar, modulo switching a couple words?
I won't dig deeper into the topic, as I think this first taste is enough to provoke some thought (and possibly get me on a few kill-lists. Oh, well.)
What I can add is the simple but interesting statement that maybe, in the end, everyone actually thinks they're the good guys
Comment: Exactly my thoughts. It is any surprise that people get pissed when a western power bombs a children's hospital, killing hundreds, then says "Whoops, collateral damage. By the way, you can't actually hold us accountable for this and if you do we'll kill you".
Comment: @Stefano "Why does Western Governments continue to do things to make their "enemy" even more determined to go attack them?" oh that's easy: OIL
Comment: Not quite oil. Petrodollars. Without USD settlement of OPEC trades, there would not be a USD as a reserve currency
Comment: @warsong sadly that is true
Comment: @SleepingGod: I cite myself from a few lines above, where I say _"racist stereotypical elements" are used on purpose_ . From the same part one also finds _keyboard full of weird wiggly symbols_ , and I would have talked about the person's _mud house not too far from the loud bazaar_ too but I guess the intent of depicting the "unknown and stereotypicized middle-eastern" to add to the fictional narration had already been reached... or maybe not.
Comment: @funky-future, I am well aware of chairs in M.E. :) it is a narrative trick to add to the effect of "look! that person that you think is so different than you because *insert stereotype here* is actually thinking the same thing (modulo sign) you do". I think (or hope?) we are all cultured enough to know that M.E. people don't all fly on carpets or stuff like that.
Comment: @preston I'd guess it's more about controlling the oil supply rather than the oil itself; you only have a reason to use violence when either party in a trade uses violence (e.g. boycott, tariffs, ...). I'd love to see a thorough analysis, but in the absence of such, I'm pretty sure the costs are much, much larger than the savings (potential or realised) of "getting the oil". But look how much stronger the government gets with each new step - more military, more restrictions of freedoms, more "evils for the good of everyone"... It doesn't make oil cheaper; it makes those in power more powerful.
Comment: @Sentinel ultimately the same thing though. Controlling the oil is what gives them the ability to hold the world at ransom and basically force everyone to use the petrodollar. So yes, the oil is not the end goal, it's hegemony, but the primary method to achieve that is to control the OIL.
Comment: @warsong Essentially, agreed, and with all those dollar surpluses, they (Saudi) can spend 350bn on US weapons (recent Trump deal). At the end of the day, it's just paper for weapons, in a deal that permits the US to reap the rewards of a USD reserve currency
Comment: There are chairs in the Middle East! And you don't need to claim the opposite to make your point.
Comment: "everyone actually thinks they're the good guys" reminds me of the Mitchell and Webb sketch. "Are we the baddies?" https://www.youtube.com/watch?v=hn1VxaMEjRU
Answer: A short answer is the last paragraph.
Born and raised as a Muslim, though I am more inclined to defend my lifestyle choices with progressist politics, rather than entities with extra-political world views, like ISIS, I shall attempt to answer your question.
First, ISIS doesn't do all the attacks (it just claims to do so) and not mainly for inflicting fear on its targets or anything because, as your question presumes well, against NATO-like military organisations, no movement - no matter how well equipped it is - can resist and though it is unreasonable, ISIS knows this for a fact and thus it tries to become a symbol. ISIS promotes two different images to different societies.
In my opinion, what ISIS does is to try to appear as a "hope zone" to those who are marginalised by the very society in which they live. They openly target the second generation of immigrant families and prisoners for recruitment into wealthy societies. The first generation of immigrants, those that arrive, most of the time are just grateful to be alive, maybe not in the conditions, they had hoped for but also in no position to be attacking the very fabric of the society in which they have been received. I am a first generation immigrant, and that is how I see the people around me, I can clearly weigh my options and see that my prospects of living here are more reasonable than my home country.
The second generation, though, for the most part, has a severe identity crisis. This identity crisis for some cases results in major isolation from the society. That's where a search for something starts. For some that something results in Isis. A poor choice in all prospects, but some go along with it. The possibility of being part of something, like anything, especially something that is condemned by the society from which you feel isolated, must be thrilling for some people. Even the thought probably gives excitement to some. One also has to admit that ISIS acknowledges this, that is you do your part, go explode somewhere, kill a lot of people, then ISIS does its part and acknowledges your "achievements" by declaring you as part of them, and their cause.
It plays a totally different game in near-east countries though. It also attacks those countries too, by the way. Turkey alone had seen 23 ISIS related bombings in 2014-2016, or Iraq had seen 15 of them in the first 6 months of 2015 or 2014, I don't remember the year really well, but media in here doesn't talk about it if it is not European among the dead. In near-east, it uses the misery of the life conditions of the people. Think of it this way: you are in your early 20s, you have no money, you barely survive by working in long shifts in poor conditions, with no money or a decent job, you have a very poor chance at marriage if you are an average looking guy or woman, and let's say you have been raised with conservative values, though not being necessarily very well versed with the interiors of the religion that is supposed to be the basis of those values. In all that misery, some colleague says one day: "hey I have this friend who is organising an event for discussing such theme in some locale, would you like to come?" As time passes on, this friend proposes you the following option, become a soldier of ISIS, have a wife from their captured sexual slaves, have a steady income, live in the designated houses either for very cheap prices or free. You are promised to die as a martyr of Islam, which is a very high status for some.
To answer your title question directly, ISIS doesn't really care about presenting itself as the enemy, as long as it can appear as a community, to those who are marginalised by the targeted countries, which destabilises the society of the targeted countries. And let's face it as long as the Syrian civil war exist, they will continue to exist, and probably even after that, since the civil wars in Libya and Sudan also are going on in the region, they have high chances of continuing their organisation there as they feed on the misery of the people for their staff.
As for the question of why reproduce the Al-Qaeda methods, well... They are not reproducing it. Al-Qaeda was strictly against non-Muslims, so countries like Iraq, Iran, Egypt, Turkey, didn't really suffer from that organisation. According to Al-Qaeda, the enemies were and still are the non-Muslim countries. For ISIS, the definition of the infidel includes different sections of Islam, you might find it hard to believe, but in Turkey, the most ardent attackers against ISIS came from extreme right and radical Islam, since they refused to be branded as infidels, just because some new kid decided for them to be so. Plus accepting ISIS would mean a loss of control in their communities, etc.
Regarding the use of terrorism by both organisations, my personal belief is that both of the organisations are a disgrace to Islam that I have been raised with, but their attacks don't necessarily appear as such to their relative communities. Think of it this way, bombing ISIS for saving Yezidis was an incredibly human gesture of US that would be remembered for a long time among Kurdish community, but the bombing of Iraq would not be considered so. The action is the same, but its perception differs among the people. The same goes for the community that might be willing to associate themselves with that movement, those actions are not perceived as terrorism. They differ considerably by the way. Al-Qaeda is still against the attacks in regions like Pakistan, Egypt, etc. For Al-Qaeda, the attacks in those regions are what you would call terrorism. Though this doesn't change much as far as the non-Muslim societies, I am just trying to say that they do differ in their perception of the enemy, but not in the choice of action. Why choose terrorism at all you might say, well that is quite easy. It is the only course of conceivable hostile action that would put you into the headlines if you are an organisation from the Middle East.
Comment: @adelphus I was born and raised in Turkey, and now currently live in France
Comment: This is a really interesting read. I'm curious what country you originated from and where you live now.
Answer: One reason for provoking powerful opponents is to establish in the eyes of potential recruits that you are a powerful organization that can accomplish what other organizations cannot.
Doing this may cause recruits or financing sources to support your cause because they think highly of your group relative to others that "play it safe" by comparison. Generally, establishing yourself as the most extreme player is a good strategy for securing the time and treasure of people who want to support an extremist cause.
Less cynically, the leaders of ISIS may sincerely think that the Western way of life exemplified in rock concerts, large scale commercial banking activity contrary to Islamic law, and government institutions of countries that advance a way of life contrary to Islamic law in the world, is evil and that it is their duty to take action, on behalf of God, to punish this evil in a public way that discourages others.
To use an example familiar with Christian readers, Jesus violently disrupted the activities of the money changers in one episode depicted in the Bible, because it was contrary to Jewish law and his ideals. Obviously, that one act of low grade terrorism did not end the money changing business in the Levant. But, it did clearly establish his credentials as a force opposed to this conduct widely viewed in the Jewish community at the time as immoral, and this may have helped him win converts to his movement.
Launching a terrorist attack aimed of rock concerts or frolicing mostly naked beach goers, for example, both of which may be viewed from the ISIS perspective as exemplary of the depravity of the West, may serve a similar purpose.

So I am confused why they continue to do the same thing instead of any
  alternative ways to achieve their goals?

This question also contains a false premise.
Yes, they do the same thing, but they also employ alternative ways to achieve their objectives (e.g. seeking to militarily control territory in Iraq, Syria, Afghanistan, Northern Pakistan, Northern Nigeria, Somolia, etc.). Taking one approach does not prevent them from simultaneously taking other approaches.
Comment: @easymoden00b It doesn't have to be a "military objective". It is more of a public relations and moral objective.
Comment: Just remember it was the "sin" of square dancing in 1950s in the US that set the Islamists ball rolling in Egypt.  This later birthed al Qaeda, the Muslim Brotherhood, Salafi extremism and other terrorists movements.
Comment: The implication of an economic benefit is very insightful, I think!
e.g. if your organization is fighting against X, by highly visibly terrorizing X, you can get more funding from others who oppose X economically, but do not want to jeopardize themselves by overly using violence themselves.
Comment: @TheDarkLord You are employing unauthorized violence against people conducting business with official approval for the relevant authorities in charge of the Temple, in pursuit of a religious or political agenda. It sounds like terrorism to me. Surely, not all terrorism needs to result in death.
Comment: What is the military objective of the suppression of rock concerts?
Comment: I'd hardly describe throwing money-lenders out of a temple as "low grade terrorism".
Comment: @ohwilleke So if I spray an anarchist symbol on my bins and shove the person collecting them does that make me a terrorist?!
Answer: Why does ISIL attempt to provoke a fight they cannot win?  The answer is simple.

much of what the group does looks nonsensical except in light of a
  sincere, carefully considered commitment to returning civilization to
  a seventh-century legal environment, and ultimately to bringing about
  the apocalypse.

This summary comes from a widely circulated and sometimes critiqued article published by The Atlantic: "What ISIS Really Wants".  I'd recommend reading it.  What's particularly interesting is that the author, Graeme Wood, went out to try and find what ISIL and their ilk thought of his conclusions.  They approved.
It is incorrect to assume that jihadi ideology is monolithic.  Al-Qaeda was very much of the old school of jihadi thinking that emerged in the 90s; that horrific acts of violence would be shocking enough to awaken the Muslim world to the injustices against it.  This would summon the umma together to overthrow those attempting to enslave and destroy them: Jews, crusaders, dictators, etc.  This would allow Islam to unite and return to a romantic and idealised past where Muslims were united, powerful, and free to govern themselves... or so the theory went.
Incidentally, Al-Qaeda didn't fall from power after 9/11 - they never had much power to begin with.  They were always a small organisation, and though America hunted for them in Afghanistan they never found the capabilities they presumed Al-Qaeda had.  In the end it was the instability in Iraq which allowed Al-Qaeda to spread and mutate.
ISIL emerged as a virulent offshoot of Al-Qaeda Iraq, and began to believe that the end of times was fast approaching.  It was thus their duty to make sure this happened.  Al-Qaeda's strategy was to use attacks to lure west and east into a clash of civilisations; which of course would result in a united and victorious Muslim world.  ISIL's strategy was to use attacks to lure the west into triggering the apocalypse.
This seems comparable to America's Evangelical Christians supporting Israel in the hope that when all the Jews are in Israel it will trigger the second coming of Christ.  Both groups seek to utilise outside forces to achieve their preferred prophecy.

other parts are based on mainstream Sunni sources and appear all over
  the Islamic State's propaganda. These include the belief that there
  will be only 12 legitimate caliphs, and Baghdadi is the eighth; that
  the armies of Rome will mass to meet the armies of Islam in northern
  Syria; and that Islam's final showdown with an anti-Messiah will occur
  in Jerusalem after a period of renewed Islamic conquest.
The Islamic State has attached great importance to the Syrian city of
  Dabiq, near Aleppo. It named its propaganda magazine after the town,
  and celebrated madly when (at great cost) it conquered Dabiq's
  strategically unimportant plains. It is here, the Prophet reportedly
  said, that the armies of Rome will set up their camp. The armies of
  Islam will meet them, and Dabiq will be Rome's Waterloo or its
  Antietam.
"Dabiq is basically all farmland," one Islamic State supporter
  recently tweeted. "You could imagine large battles taking place
  there." The Islamic State's propagandists drool with anticipation of
  this event, and constantly imply that it will come soon. The state's
  magazine quotes Zarqawi as saying, "The spark has been lit here in
  Iraq, and its heat will continue to intensify … until it burns the
  crusader armies in Dabiq." A recent propaganda video shows clips from
  Hollywood war movies set in medieval times—perhaps because many of the
  prophecies specify that the armies will be on horseback or carrying
  ancient weapons.
Comment: This. People somehow keep thinking people pledged to strap themselves to a bomb and blow up a market still think exactly like them, in terms of political goals. But what does politics matter when 'Allah is on your side'?
Comment: This is 100x better than the answer that has 100 upvotes currently.
Comment: Well-spoken and well referenced!
Comment: ^^ this. shows you the depth of delusion in which the West wallows right now.
Comment: @someguy Come again?
Comment: @inappropriateCode your answer is 100x better than those other ones. Them being upvoted so much, shows the depth of delusion &c.
Comment: @someguy Thanks!  I was just confused about the subject of your statement and why you regarded the others are deluded rather than just incorrect.
Answer: Terrorist groups such as ISIS seek to disrupt life in Western society. Since they don't have an air force or any advanced milatary capabilities, they use the weapon most readily available to them: fear.
By carrying out violent attacks in public places, they create heightened tensions around the world, forcing governments to ramp up security and limit the freedoms of citizens in an effort to make the public feel safe. This has proven to be an incredibly effective tactic.
After the U.S. invaded Iraq in retaliation for the 9/11 attacks, it left a power vacuum that allowed ISIS to grow throughout the region. So, while the countries that have fallen victim to terrorist attacks might be more "determined" to go after the perpetrators, this tactic can potentially play right into their hands.
Comment: I downvoted because this answer should include a way for readers to know that it is true. If you are some kind of expert or professional in a field that deals with terrorism, you can cite your own experience. Otherwise this should be backed up with a reference to some source that shows this is what ISIS is doing.
Comment: I up-voted it to counter at least one of the down votes. This answer is actually spot-on, at least from the perspective of a former US military person who was trained on terrorism. The first paragraph of this answer is pretty much the definition of terrorism, and the two paragraphs that follow give good examples of how terrorism is used in the modern day.
Comment: Al Qaida the group responsible for 9/11 was based in Afghanistan not Iraq.
Comment: @adelphus In a free society, shouldn't I have the freedom to fly to Denver without having my genitals grabbed and my naked body observed through a body scanner by a government employee? In what world are such policies "just laws"?
Comment: Why was this answer down voted?
Comment: *...ramp up security and limit the freedoms of citizens* - although this may be a common thought, there's no real evidence for this actually happening. Wherever attacks have taken place, there may be an increase in security for a short time, but no freedoms are limited.
Comment: @adelphus For one:  Air travel became quite onerous, and continues to be more restricted than it was prior to late 2001.  Expanded statutory definitions of terrorism and sanction of military action against those accused of such.  They have changed the lifestyles of many people in many places of the world.
Comment: @adelphus Actually this can be seen in many ways. Many new laws are justified with the fight against terrorism: [Most mass surveillance](https://www.theguardian.com/world/2014/dec/08/mass-surveillance-exposed-edward-snowden-not-justified-by-fight-against-terrorism), e.g. with [a new German data retention law, which passed in 2015](https://tutanota.com/blog/posts/germany-data-retention) or the  maybe most extreme surveillance law in western society (Investigatory Powers Bill, also known as [Snoopers charter](https://www.snooperscharter.co.uk/)) in Britain.
Comment: @rugk you're missing the difference between laws and freedoms. Surveillance laws of the type you are talking about do not **limit** any freedoms - people are still free to communicate however they see fit. The laws may be viewed as an unnecessary intrusion, but that's more of a democratic argument rather than a restriction in freedom. My argument is  that freedom constitutes the ability to live a normal life - you can still fly in planes, you can still send encrypted messages, etc
Comment: @Jon Letko Awesome metaphor. I have nothing more to add. ☺
Answer: They want to create a culture of conflict between the Ummah and Western Society. You see, because of western benevolence there are tens of millions of Muslims now living across the west (and thousands more each day). If they increase the tension between Westerners and Muslims the result will be conflict predominating within western society and a fracturing of the very fabric of these societies. The Ummah, being a monoculture, does not have this problem and would be a united front in a cultural conflict between the two sides.

The swift downfall of Al Qaeda's power after the 9/11 attacks is an example of such a thing happening

The taliban is still a thing.  The "crusaders" are a potent recruiting tool.  When the US finally leaves the current afghan government will likely collapse.
Comment: Could you elaborate in "The Ummah, being a monoculture"? Not only because of the tensions between countries like Iran, Saudi Arabia, Yemen and the like, but also because of data showing that most victims of Daesh and AlQaeda are Muslim (http://www.independent.co.uk/news/world/americas/donald-trump-muslim-ban-immigration-visas-refugees-syria-iraq-terrorism-isis-attacks-most-victims-a7550936.html, http://www.globalresearch.ca/muslims-are-the-victims-of-between-82-and-97-of-terrorism-related-fatalities-us-government/5516565)
Comment: @SJuan76 Right, so the end goal is to unite Islam into a Caliphate.  That caliphate will be governed by Shariah.  Under Sharia the dictates of the Quran are the sole dictates that govern society.  One of these dictates is to fight non-believers until they either no longer exist, or they exist in subjugation (dhimmitude).  The Ummah is the worldwide body of Muslims.  "Daesh", Al-Qaeda, the Wahhabis, etc. are a manifestation of the will of the politic, defeat individually does nothing.  Current violence in the Middle East is a side show.  End-game is cultural conflict between Islam and the West.
Comment: @easymoden00b Except it's demonstrably not the case and when faced with that reality, you declare that a "side-show"…
Comment: @Relaxed This is about ideology.  The reality of the Muslim world is in pursuit of this ideological goal by it's very nature.  That *is* the reality.  Who is what or where is doing to whom is a footnote.  It doesn't matter.  They'll be replaced. The ideological foundation that is the driving force behind these groups will remain unchanged and the conflict will continue unabated as it has for the past 1300 years.  These groups act as a manifestation of the ideology.  Just as the marxists did in Cambodia.
Comment: Right, but what about the reality of the Muslim world?
Comment: This should be backed up by a reference to a credible source showing that ISIS does want to create a culture of conflict between Ummah and Western Society.
Answer: If you want to know why just check what happen to the families and children in Afghanistan Iraq Syria and many other countries after the NATO strike.
I think maybe it's the same answer of the question why Japanese did the horrible attack of pearl harbor
Comment: Answers need to be able to explain and justify points, preferably with references. The answer needs far more effort.
Comment: What is the similarity of Pearl Harbour and let's say 9/11 from the attacker's perspective?
Answer: You say "do things to make ... determined": these things are for media attention. ISIS's funding and recruiting depends on this. ISIS is very good at teasing the media by providing sensational video and promoting it on social internet.
Comment: This answer is very terse, to be honest I don't really see how it expands on the existing answers that elaborate on the same point much more.


Event Receiver with NAPA

Question: Is there any way to create and deploy an event receiver onto a sharepoint site using only the NAPA development tools and an O365 development site? If not, is there any way to create and deploy an event receiver using Visual Studio 2013 with only a O365 development site and no local sharepoint development server?
Answer: Since your question has references to "NAPA", "local SharePoint development server", so I assume you are asking about Remote Event Receivers. Apps developed using NAPA are SharePoint-Hosted apps and SharePoint Hosted apps don't contain remote event receivers. Moreover in NAPA you can add few file types only like .js, .css and web pages only.

In SharePoint 2013, the code that runs when the event is triggered is
  served by a web service. This means that if you register a remote
  event receiver, you also need to tell SharePoint which web service to
  invoke.

So you can create remote event receiver using VS 2013 and O365 but you need a site apart from SharePoint site which will host the service for remote event receiver. This is the reason if a remote event receiver is added to a SharePoint-Hosted app, it immediately changes into cloud hosted app and adds a web application project as well.

Event Receiver with NAPA


Generating two differnet pseudorandom numbers using the same seed

Question: Is it possible to generate two different psuedorandom numbers on two separate program runs without using time as the seed? i.e. using the same seed on both runs, is it possible to get two different numbers?
Comment: anything is possible, but I am thinking same seed == same numbers
Answer: In general, it is not possible to get different pseudorandom numbers using the same seed.
Pseudorandom numbers are, by definition, not truly random numbers and therefore are not composed from sources of entropy.  Or, if the numbers do contain some entropy input, the input is not enough to cause the sequence to qualify as statistically "random."  (An example of a property that such a sequence should have is runs of 1-bits n-bits-long with probability of 2^(-n), among many other properties of statistical randomness.  The definition of statistical randomness becomes more sophisticated (in a sense, more "actual" or close to nature) as mathematics around randomness improves.  This is another way of saying that, at any given time, the definitions of statistical randomness are about to become out-dated or obsolete.)
In any case, the vast majority of pseudorandom number generators are, in fact, completely deterministic.
The canonical1 example of a pseudorandom number generator is a linear feedback shift register (LFSR).  The LFSR can be implemented as a digital logic circuit containing a register which holds N bits, some gates numbering M, much less than N (e.g., M=1, M=2), usually these are XOR gates, which "feed back" into the register's bits at certain "tap bits."  There is a lot about this on the web.
Given the same seed input, the LFSR will always generate the same sequence.
It is possible, using Walsh-Hadamard matrices, or otherwise called "M matrices", additionally called "sequency transform", to sample the output of an LFSR and determine that the sequence is, in fact, from an LFSR and also the structure of its gates and taps, as well as the current register content.  From this information all sequence values are known, and it is possible to reverse out the possible seed values which were used as input.  For these reasons, LFSRs are not suitable for security purposes such as random tokens for authentication.

By canonical, I am refering to Don Knuth's use of the LFSR as an example, as well as the timeless tradition which has ensued therefrom.
Answer: Not sure if you want to generate 2 different random numbers from same seed - or avoid it! But, if you really do want that, then similar to LFSRs, LCGs (Linear Congruential Generators) are often used to generate deterministic psuedo random numbers. You can 'easily' create 2 simple LCGs using different constants, which will generate 2 different psuedo random numbers for the same seed.


Laser Diode driver circuit help

Question: I'd like to understand the functions of Q2 and Q4 in the driver below. Also, why there's a shunt RC branch at Q5 base? Is Q2 simply a buffer or does something else? Also, in the diagram, it says "0.2mA" at the photodiode branch, with that current Q2 would be in cutoff even when no signal at Q3, so the laser would be off - that makes no sense...
Comment: Q4 is likely for SOA fold-back to limit the laser drive current to (1Vbe/10) or approximately 60 mA. Q1 & Q2 together form an error-amplifier attempting to maintain 1.2 V at node X.
Comment: @strange_bakery Probably the most important thing to know in explaining the circuit is the expected leakage in the photodiode when the laser is off. This relates to R4. The rest is easy. RC and CC just limit how quickly Q5's base can be pulled up. It's a good idea. Q1 and Q2 are just a diff-amp. I'd probably need to read the LM385 datasheet, as I hope it works well in hundreds of microamps. Also, I'm curious how it fails if the current is still less. But the basic idea seems sound without having all the details at hand.
Comment: Could you cite the source that this came from, as a link if it's on the web?  Does it not describe the circuit operation?
Comment: @TimWescott it's from The Art of Electronics by Horowitz. But the circuit explanation is really brief, not much details provided.
Answer: This looks like a RAP or Winfred Hill design that was made to work well in the lab, but not optimized for production tolerances without a pot.  It was designed for binary ASK. (low/hi level current lasing)
In addition to the other fine explanations.  I'll add my two bits below.
R3 and R2/R1 control the desired binary current levels with some smaller subtracted current from the PD and use a pot for R2 to bring up current slowly at first try.   Q1,Q2 have roughly the same Vbe values of 1.2V, so Q1 may turn off as the pair act as a differential.
Q2 does not turn off as the current from R3 exceeds the PD (photodiode) feedback with two selected base currents for an optical AM transmitter hi/lo, not on/off.
All the parts in yellow with the PD feedback affect the luminous intensity levels with very low effective CTR (current transfer ratio) for the necessity of optical feedback.  These come included with the laser diode.
The input RC filter gives some edge boost while the output RC filter is a snubber to prevent the laser from having a lethal orgasm with rapid NTC effects on power levels and tendencies towards thermal runaway.  So the slew rate is reduced for stability.
R4 controls the low current level.
There's a lot of parts that affect current levels in the laser. So one would start with a pot in R2 and bring the current up slowly with the 10 Ohm < 60 mA safety net on Q4 limiter.
Comment: No Vb is around 1.2V from regulated other side so without diode current is 1.2V / 29k= < 400uA and 200uA modulates this.
Comment: Thanks for the explanation! But still, I don't get the 0.2mA - like, if Q3 is on then the voltage drop at R3 is 6800*0.2/1000+Vcbq3 ~=  1.66V which is higher than 1.2V - shouldn't Q2 emitter-base be reverse biased in this case?
Answer: Laser diodes are notoriously unstable and easy to blow up. (It's not if, but when if you are designing drivers for them. I speak from bitter experience. It is best to develop and learn on cheap ones. Most suppliers of the high end ones will sell a driver with the diode, you buy a sealed unit.)
The photo diode and Q2 are negative feedback to reduce laser current if it gets too bright. Reducing Q2's current will reduce diode drive, so the photodiode has to decrease its voltage with more light.
Q4 is current limiting, it will start to shunt current away from the drive transistor at about 50mA.
One issue with laser diodes can be that absolutely any ringing in the leads going to them will create transients which will kill the diode after a few million pulses. It's often a good idea to limit switching slew rates to reduce this. That may well be what the CR network is about. Their time constant is about 150ns, so this circuit can probably pulse the diode down to a us or so.
EDIT - One comment about this circuit. Because of the horrible vulnerability of laser diodes to any transients (causing damage by overvoltage), it is not generally recommended to drive them with a transistor and a resistor as here. It might be OK if the diode is on the driver PCB (thus extremely short traces) but I ran into problems with leaded diodes where the leads were only about 4 or 5cm with such an approach, with lasers failing after many millions of pulses. We then went to another approach which was to drive the laser with a current source, always on, and then put a "soft switch" transistor in parallel with the laser, shunting current away from it to turn it off. By turning the shunt transistor on and off softly (say 200ns) we avoided diode failures. I can't say whether that is a commonly used approach, but it worked quite well for us.
Answer: I think the book does a decent job explaining the circuit:

Just compare
the monitor photodiode current with a threshold, and adjust
the drive current accordingly. It's a good idea to include a
current limit, so you don't blow out the diode; and you'll
need to compensate the feedback loop to make it stable.
Figure 12.67 shows a "good-enough" driver circuit: it converts
the monitor current to a proportional voltage (switchable
between two levels by Q3), compared with a diodecompensated
1.2V reference voltage. Q5 drives the laser,
with current limiting via Q4. CC and RC compensate the
loop, with final "cut-and-try" values as shown.

Source: Horowitz, Hill: The Art of Electronics 3rd edition
So the use of Q4 for current limiting the laser current should be clear. A higher laser current leads to higher voltage drop at \$R_{CL}\$ which leads to Q4 pulling the base of Q5 lower.
The photodiode current is converted to a voltage either with \$R_3\$ and \$R_4\$ in series if the input signal is low, or with \$R_3\$ and via Q3 to ground if the input signal is high. The circuit of Q1 and Q2 build the mentioned comparator. You could also think of it as a differential amplifier with one input being about 1.2V if that helps.

Also, in the diagram, it says "0.2mA" at the photodiode branch, with that current Q2 would be in cutoff even when no signal at Q3, so the laser would be off - that makes no sense...

When the input signal at Q3 is low, Q2 is supposed to be in cutoff. But when the input signal at Q3 is high, the voltage at the base of Q2 is lower so that it is not in cutoff region.
The overall idea of the circuit is to monitor a part of the laser power using the photodiode and use the measured power feedback for biasing to keep the average laser power relatively constant. Otherwise the optical output power of the laser diode would vary a lot with temperature and aging.
\$C_C\$ and \$R_C\$ make sure that this feedback doesn't cause oscillations.

Laser Diode driver circuit help


Can anyone explain how magento sync/index data to Elastic search in Magento 2.4.2

Question: Can anyone explain how magento sync/index data to Elastic search in Magento 2.4.2. How it works and what are files called to index the products.
Answer: How it works

php bin/magento indexer:reindex catalogsearch_fulltext

What data indexed

Products by default

what are files called to index the products

Modules start with Magento_ElasticSearch there are mainly around 2-3 modules which might interact with ElasticSearch.
As your site runs on 2.4.2 then it would be ElasticSearch 7 so Magento_ElasticSearch7 and Magento_ElasticSearch modules will be the main modules from Magento framework point of view.
Further, Magento_ElasticSearch module will call the client elasticsearch which is available in the magento-root/vendor directory.
See this - https://github.com/magento/magento2/blob/2.4/composer.json#L38

Files which are available in the following directory are responsible for indexing.
https://github.com/elastic/elasticsearch-php/tree/master/src/Elasticsearch


How energy stored in magnetic field gets used up?

Question: An inductor stores energy in form of magnetic field. In case of capacitors the energy is stored in electric field, and since electric field can do work the stored energy can be spent. Here, magnetic field does not do work, then how stored energy gets spent?
Answer: "magnetic field does not do work" But when the magnetic field changes there is an electric field around the changing magnetic field. The electric field does work on charges, for example those in a coil.
Comment: Is it means that magnetic field can store energy and spent through electric field?
Comment: That's a neat summary, I think.
Answer: Sometimes it's a good method to see things on the particle level.

In case of capacitors the energy is stored in electric field,...

In detail, electrons are separated and accumulated on one side of a capacitor. For the separation is needed energy and connecting the two sides of the capacitor the electrons flow back to the other side. Having some device (resistance, lamp, motor) in the circuit, you'll "see" the work from this current.

... and since electric field can do work the stored energy can be spent.

The better description is to talk about a potential difference between two points of a circuit. This potential difference is the result of a charge separation. And the charge separation in turn always has the effect of a macroscopic electric field.
Besides the electric charge, the electron is a magnetic dipole. In permanent magnets the macroscopic magnetic field is caused by the alignment of electron (and protons). This self-alignment is destroyed by higher temperatures.
In an inductor the electrons get align with their magnetic dipoles during the electron flow on their spiral path and a macroscopic magnetic field is created. But only for temperatures near zero Kelvin a self-alignment occurs, in the common case the alignment gets lost immediately after switching of the current.

Here, magnetic field does not do work, then how stored energy gets spent?

Starting a current through an inductor, a higher resistance is measurable in the circuit. Partially this resistance comes from the work, which has tobe done to align the electrons magnetic dipoles during their transition through the inductor. switching off the current, for a moment a current in the opposite direction is remarkable (Lenz's law). this current is the work, realized from the magnetic field of the inductor. And, in detail, it occurs from the return of the aligned electric dipoles into their random directions.
Answer: The existence, sustained in time, of a magnetic or electric field, entails an energy associated with the existence of such a field. In particular, the electromagnetic energy associated with a generla EM field is given by:
$$\mathcal{E}_{EM} = \frac{1}{2} \int_{\mathbb{R}^3} \left(\varepsilon_0\mathbf{E}^2 +
\frac{\mathbf{B}^2}{\mu_0}\right) \ dV$$
Even if for a specific observer we have $\mathbf{E} =\mathbf{0}$ (not all observers will fulfill that condition) even for a specific field occupying a specific region of space. A magnetic field, even if it does not increase the energy of charged particles, can be used to generate electromagnetic waves. If we derive the expression with respect to time of the electromagnetic energy density we have:
$$\varepsilon_0\mathbf{E}\cdot\frac{\partial \mathbf{E}}{\partial t}+
\frac{\mathbf{B}}{\mu_0}\cdot\frac{\partial \mathbf{B}}{\partial t}=
-\mathbf{E}\cdot\mathbf{j}-\frac{1}{\mu_0}\left(\mathbf{B}\cdot\boldsymbol\nabla \times \mathbf{E} - \mathbf{E}\cdot\boldsymbol\nabla \times \mathbf{B}\right) = -\mathbf{E}\cdot\mathbf{j} - \boldsymbol\nabla \cdot \left( \frac{\mathbf{E}\times\mathbf{B}}{\mu_0} \right)$$
even if initially we have $\mathbf{E} =\mathbf{0}$. The vector $\mathbf{S} := \mathbf{E}\times\mathbf{B}/\mu_0$ is the Poynting vector associated with electromagnetic energy flux. Then, it is clear that the variation of the existing magnetic field will eventually generate an electric field and, therefore, a flow of electromagnetic energy (regardless of whether we initially have $\mathbf{E} =\mathbf{0}$).


Calculating star radius from temperature and absolute magnitude - what am I missing?

Question: In an attempt to visualise nearby stars, I've tried to get the star radius (measured in solar radii) using the equation provided on the following site:
http://cas.sdss.org/dr4/en/proj/advanced/hr/radius1.asp
Now though the equation seems to work fine for a star like Sirius, when I plug in the values for absolute magnitude and temperature for Barnard's star (according to wikipedia, 13.21 and 3134 K respectively) I get a radius of 0.0722. The radius provided by wikipedia is more than twice that value, at 0.196.
There are many potential culprits. Could it be floating point errors in the php code? The equation looks like this by the way:
$$\text{radius = pow(5800/3134, 2)} \times \text{pow(pow(2.512, (4.83 - 13.21)), 0.5})$$
Another possibility is that the equation is too simplistic, and there are other variables I need to take into account.
Any insights would be greatly appreciated!
Michael
Comment: I think you would want to use the Stefan-Boltzmann law and calculate flux from absolute magnitude. I'm on mobile now, so I can't work it out in full.
Comment: "Any insights would be greatly appreciated!". hmm...
Answer: The page you quote is guilty of a gross simplification (or error). The luminosity ratio cannot be estimated from the difference in visual magnitudes for stars of different spectral type. You need to use the difference in bolometric magnitude, which indicates the luminosity integrated over all wavelengths. This will involve making bolometric corrections to the visual absolute magnitudes.
A star like Proxima Cen radiates much of its light outside the visible band and has a much different and larger bolometric correction than the Sun or Sirius. This accounts for your problem.
Example:
The correct calculation uses a table of bolometric corrections vs temperature. This rapidly changes for M-dwarfs in the visual band (you would be more precise using K magnitude), but is about 2.6 mag for a star at 3100 K (see Zombeck 1992). That is, the bolometric magnitude is smaller than $M_V$ by 2.6 mag. The equivalent correction for the Sun is only 0.1 mag.
$$ M_{\rm bol}= M_V - BC$$
Thus there is a 2.5 mag less difference in the bolometric magnitudes in your final equation than the difference in absolute visual magnitudes, and I get a radius for Barnard's star of $0.23\ R_{\odot}$.
The probable reason for the discrepancy between this and the radius quoted in wikipedia (actually it is the radius determined by an interferometric angular diameter measurement plus the parallax by Lane et al. 2001; a more recent measurement by Boyajian et al. 2012 gives $0.187\pm 0.001\ R_{\odot}$) is that (a) the assumed temperature is too low or (b) that the bolometric correction scale for V-band magnitudes is not very well defined for very cool stars. Both (a) and (b) are possible, especially as Barnard' star probably has a significantly subsolar metallicity.
Answer: In order to calculate this, you can use the Stefan-Boltzmann law to calculate the star's surface flux and its absolute magnitude to get the luminosity.  Once you know the surface flux and luminosity, you can find the radius of the star.
Stefan-Boltzmann Law:
$$
F=\sigma T^4
$$
Absolute Magnitude - Luminosity calculation:
$$
\frac{L}{L_\odot} = 10^{0.4(M_\odot - M)}
$$
where $L_\odot$ is solar luminosity and $M_\odot$ is the absolute magnitude of the sun.
Next, you use the formula for intensity and solve for distance:
$$
r = \sqrt{\frac{L}{4\pi F}}
$$
Compiling all this into one equation,
$$
r = \sqrt{\frac{L_\odot * 10^{0.4(M\odot - M)}}{4\pi \sigma T^4}}
$$
As long as you use SI units for $L_\odot$, $\sigma$, and $T$, you'll get $r$ in meters.
Comment: You're missing an important caveat: bolometric. I'm not sure, but I think that the distinction between band-pass (approximately spectral) fluxes and luminosities and bolometric (total) quantities is probably what's causing problems here.
Comment: Yes I played around with Stefan-Boltzman, but the trick explained both in the link I put in the original equation, and this link: http://www.astronomynotes.com/starprop/s4.htm (at the bottom), we can get the ratio of the two stars' luminosity if you have their absolute magnitudes from L1/L2 = 2.512^(M2 - M1). I wonder if the issue is indeed to do with bolometric magnitude than anything else. I suspect Barnard's star has much more going on in the R and I magnitudes...
Comment: Did you double check on your units?
Comment: This just makes the same mistake as the linked page that the OP gives.


Numerals: how to read and understand

Question: Please, help me to puzzle it out:)
I've read the sentense in the text about school:
"There are about one 600 pupils". The author writes how large the school is.
I understand the meaning of the phrase, but don't know how to read and understand "one 600 pupils" - does it mean "one thousand and six hundred"?
Thank you!
Comment: Welcome to ELL.SE. Context is essential to meaning; where did you read this sentence? What are the surrounding sentences? It currently makes no sense; you would not normally write "about one 600 pupils," but we have no idea what was intended. Please [edit] your post to include more detail.
Comment: Are you certain you are transcribing faithfully? *About 1 600* would be conventional, and *about one-six hundred* can be explained, but *about one 600* is neither here nor there, and would be taken as erroneous, so there is no way to know what the intended meaning is unless you ask the author.
Comment: Hello, thanks a lot for answering! I've edited the post and I hope it's more informative now)
Comment: Yeah, there's something wrong with the text, I guess... But it was taken from our English text book) Thank you very much!:)
Answer: This is not a standard way of expressing a number. You must say "one thousand six hundred" if you mean 1600.  (it is possible to say sixteen hundred but this is rarer).
It is not possible to say "one six hundred" to mean 1600, or any other number. So the quoted text contains a mistake that makes it hard to understand.  It could be a mistaken way of saying "one thousand six hundred", or it could a speaking error (The speaker meant to say 600, but accidentally said "one", then corrected himself)
Comment: Thank you very much for such a detailed answer!:)

Numerals: how to read and understand


Java Video Player

Question: I need a java api, that cannot use JMF, to play video interpreted by the SO codecs but i want to retrieve the each frames in java code. Somebody know some?
Answer: Have a look at FMJ.  It does not require the Java Media Framework (JMF).
They have an example at the bottom of the page that writes out the first 5 frames of the video to files, so you should be able to get to the individual frames.
Answer: FMJ is very much out-of-date and JMF is a lost cause (yes one of those is IMHO). If you want something that works and will do exactly what you have described, try Xuggle. In their media tools examples they offer a simple player example using AWT / Swing.
http://xuggle.com/
Comment: Link down......
Comment: Yep, they got bought and started a new project under https://github.com/artclarke/humble-video Also the post is 6+ years old now.
Answer: If you're OK with Java wrapper around FFMpeg, try velvet-video.
Code snippet to extract images from a video file:
<code>IVelvetVideoLib lib = VelvetVideoLib().getInstance();
try (IDemuxer demuxer = lib.demuxer(new File("/some/path/example.mp4"))) {
    IDecoderVideoStream videoStream = demuxer.videoStream(0);
    IFrame videoFrame;
    while ((videoFrame = videoStream.nextFrame()) != null) {
        BufferedImage image = videoFrame.image();
        // Use image as needed...
    }
}
</code>
A more advanced example of video player implementation using velvet-video can be found here.
Disclaimer: I am the author of velvet-video.
Comment: Just linking to your own library or tutorial is not a good answer. Linking to it, explaining why it solves the problem, providing code on how to do so and disclaiming that you wrote it makes for a better answer. See: [**What signifies "Good" self promotion?**](//meta.stackexchange.com/q/182212)

Java Video Player


How to view a privilege level attached to a command in Junos?

Question: According to Juniper documentation, each top-level CLI command and each configuration statement has an access privilege level associated with it. Is there a command which allows one to see the privilege level attached to a command?
Answer: The closest thing to what you want would be show cli authorization.  You won't be able to get down to the individual command level unless you specify them yourself with things like allow-commands, deny-configuration, etc.
It will show the user logged in, what permissions they have.
Here's an example of a custom login class that has all permissions except for specific types of configuration modes:
jhead@SRX1> show cli authorization
Current user: 'jhead       ' class 'CUSTOM'
Permissions:
    access      -- Can view access configuration
    access-control-- Can modify access configuration
    admin       -- Can view user accounts
    admin-control-- Can modify user accounts
    clear       -- Can clear learned network info
    configure   -- Can enter configuration mode
    control     -- Can modify any config
    edit        -- Can edit full files
    field       -- Can use field debug commands
    firewall    -- Can view firewall configuration
    firewall-control-- Can modify firewall configuration
    floppy      -- Can read and write the floppy
    interface   -- Can view interface configuration
    interface-control-- Can modify interface configuration
    maintenance -- Can become the super-user
    network     -- Can access the network
    reset       -- Can reset/restart interfaces and daemons
    rollback    -- Can rollback to previous configurations
    routing     -- Can view routing configuration
    routing-control-- Can modify routing configuration
    secret      -- Can view secret statements
    secret-control-- Can modify secret statements
    security    -- Can view security configuration
    security-control-- Can modify security configuration
    shell       -- Can start a local shell
    snmp        -- Can view SNMP configuration
    snmp-control-- Can modify SNMP configuration
    storage     -- Can view fibre channel storage protocol configuration
    storage-control-- Can modify fibre channel storage protocol configuration
    system      -- Can view system configuration
    system-control-- Can modify system configuration
    trace       -- Can view trace file settings
    trace-control-- Can modify trace file settings
    view        -- Can view current values and statistics
    view-configuration-- Can view all configuration (not including secrets)
    all-control -- Can modify any configuration
    flow-tap    -- Can view flow-tap configuration
    flow-tap-control-- Can modify flow-tap configuration
    flow-tap-operation-- Can tap flows
    idp-profiler-operation-- Can Profiler data
    pgcp-session-mirroring-- Can view pgcp session mirroring configuration
    pgcp-session-mirroring-control-- Can modify pgcp session mirroring configuration
    unified-edge-- Can view unified edge configuration
    unified-edge-control-- Can modify unified edge configuration
Individual command authorization:
    Allow regular expression: (^configure exclusive$)|(^edit exclusive$)
    Deny regular expression: (^configure.*)|(^edit.*)
    Allow configuration regular expression: none
    Deny configuration regular expression: none

Here is an even more restricted example where individual categories are configured instead of all:
jhead@SRX1> show cli authorization
Current user: 'jhead       ' class 'CUSTOM'
Permissions:
    admin       -- Can view user accounts
    routing     -- Can view routing configuration
    routing-control-- Can modify routing configuration
    system      -- Can view system configuration
    view        -- Can view current values and statistics
Individual command authorization:
    Allow regular expression: (^configure exclusive$)|(^edit exclusive$)
    Deny regular expression: (^configure.*)|(^edit.*)
    Allow configuration regular expression: none
    Deny configuration regular expression: none

Comment: I tried this in a lab environment and most of the permissions simply permit to view or modify certain part of the configuration. As much as I tested, then only following permissions are directly related to some operational mode command group: `field`, `view`(`show` commands), `reset`(`restart ` commands), `network`(`ping`, `telnet`, `ssh` etc), `shell`(`start shell ` command) and `clear`(`clear` commands).
Answer: It's in the table you've linked to: read-only can only view, operator can additionally run clear, network, reset, trace, and view and superuser can do everything.
If you create your own class the permission bit table below shows all the privileges you can assign to it.
Comment: I meant the association between the commands and permission bits. For example, which permissions requires a `file copy /var/tmp/file.txt re1:/var/tmp/` command? Or `monitor interface em0` command. I guess one way to solve this would be an additional `display` option, e.g `monitor interface em0 | display required-permission`


Can't boot Ubuntu or Windows 10 after running Boot-Repair using USB

Question: I installed Ubuntu alongside Windows 10, but when booting my laptop would automatically boot to Windows, so I used the installation USB to load Ubuntu and use the Boot-Repair program. However, doing this left my computer unable to boot either Windows or Ubuntu. It just lists some errors.
Comment: what errors specifically?
Answer: First thing I would try to do is check grub (purple screen where you choose which operating system to load) and try to make it work. Here is a solution for a similar problem. you can search the archive more (example).
If grub doesn't work you can try, either repair windows or remove ubuntu (to install it later again). For this you have some tips here


What should I learn in cloud computing as a .net developer

Question: I have query related to learn the Cloud computing and Microsoft Azure. I am a .net programmer working on asp.net, C#, Sql server, WCF. If I learn the cloud computing then how it can help me in future as professional growth and How would it benefit me as a developer?
What should I learn specifically in cloud computing and Azure which would help me in future as professional growth.
Comment: You may have better luck with this on http://programmers.stackexchange.com
Answer: To answer your first question, becoming familiar with cloud computing (even just Microsoft's platform) will help you to understand what is involved with deploying to the cloud, how cloud billing works, and understanding how elastic the environment is.
Specifically what to learn about Azure, I'd do the following:

Sign up for a 30-day azure pass.
Download the Azure Training
Kit.
Download the latest Azure SDK (1.4)
Work through some of the Training Kit examples in coordination with your 30-day free pass to Azure.
Comment: hi David, Thanks for your suggestion. Your help is really needful. But still I have doubt that how can it help me as professional growth (What will my demand in market if I learned this). It is at all different technology or it is just a layer above .net technology. So I have to still work on asp.net, WCF, Sql server even I learn the cloud computing.
Comment: Yes, you will still have to learn ASP.NET, WCF, SQL, etc. because those are the programming tools that you use.  Azure is a platform that your application runs on or in.  So you don't have to "program" Azure so much (although there are specific things that you can call for Azure, like config strings and such), but understanding how Azure works will become no different than understanding how IIS works when debugging a problem.  Understand the platform and you becoming a better programmer.  And cloud computing is the direction of the future, IMHO, so it helps to learn it now.
Answer: In addition to David's answer, I recommend Azure Fundamentals on the free portal Microsoft Learn. On Microsoft Learn there are many courses organized by role. You can just study or take also one or more certifications.
Other than that, notice that as a .NET developer you are not bound to the Microsoft Cloud solution, but you can learn and use any Cloud provider.


Finding source code of the Tor metrics site

Question: Hello I'm creating my own private tor network for me and my friends but I was wondering does anyone know where I can find the source code of the tor metric site? It would be really nice if I could see how my nodes are doing instead of having to look at a command line
Answer: Well, you better use - actually - the original network, sharding is the key to vulnerability. You can make a VPN hop-network to yourselves, which is an easy task for OpenVPN, but you will be protected by the number of nodes. If you're making a separate network - you'll still be vulnerable to the nature of the Directory Services. If you need more info - just drop me a line!
Answer: The Tor Metrics website and related repositories can be found at https://gitlab.torproject.org/tpo/network-health/metrics, but there are a lot of pieces involved in making it run. For example the data collection is separate from the website itself. It would probably be fairly complicated to get all of the Tor Metrics website running for a private network.


Hanging pictures of living people

Question: Did anyone ever hear of not putting up pictures of people that are still alive in their house?
Answer: The concept is based off the Gemara in Rosh Hashanah 24b which discusses what one is allowed to make pictures of. When it discusses making pictures of humans it writes:

אֶלָּא מֵעַתָּה פַּרְצוּף אָדָם לְחוֹדֵיהּ תִּשְׁתְּרֵי? אַלְּמָה תַּנְיָא: כׇּל הַפַּרְצוּפוֹת מוּתָּרִין חוּץ מִפַּרְצוּף אָדָם! אָמַר רַב הוּנָא בְּרֵיהּ דְּרַב אִידִי: מִפִּרְקֵיהּ דְּאַבָּיֵי שְׁמִיעָא לִי: ״לֹא תַעֲשׂוּן אִתִּי״ — לֹא תַּעֲשׂוּן אוֹתִי.
The Gemara raises a difficulty: However, if that is so, let the fashioning of an image of a human face [partzuf ] alone be permitted. Why, then, is it taught in a baraita: All faces are permitted for ornamental purposes, except for the face of a person? Rav Huna, son of Rav Idi, said: From a lecture of Abaye I heard that there is a different reason why one may not form an image of a human face, as the verse states: "You shall not make with Me [iti]" (Exodus 20:19). This can be read as: You shall not make Me [oti]. Since man is created in the image of God, it is prohibited to form an image of a human being. (William Davidson translation and notation)

The SA YD 141:4 writes:

וכן צורת אדם לבדו כל אלו אסור לעשותם אפילו הם לנוי
And similarly, the figure of a human being. The production of any of these are forbidden even if only being produced for ornamental value.

Likewise, the Tur, YD 141 echoes this sentiment:

אלא בשאר צורות ופרצופין אבל כל אלו אסורין בכל ענין בין לעשותן בין להשהותן
But all other images and that of a human face - all of these are forbidden in any matter whether making or whether hanging...

With this in mind several acharonim take a hardline against hanging photos in their home.
For example, refer to HaRav Moshe Shternbach shlita in Teshuvos Vehanhagos 3:263 (who speaks about taking a trip to a museum and seeing all the photos etc.) who mentions that any drawing whether embossed or debossed/depressed, and even photographs are problematic. He notes how he knows of many tzaddikim who were actively against having photographs as they viewed it as "מזיק" - i.e. some form of (spiritual) damage/degradation. However, he notes that most people nowadays are lenient and taking photos involves some form of grama (indirect action) which makes it okay. That being said, he does warn against it:

משום שמזיק לנפש שעי"ז עלול ליתפס רוח טומאה על התמונה
Because it is harmful to the soul that through this it is likely that an impure spirit may catch on the image.

Although, he does say that it is allowed to have images of tzaddikim as they go in the way of Hashem etc.
Comment: The question was about living people.
Comment: I know - read it through. The first part is the premise why it might be problematic and Rav Shternbach talks about the potential issue...

Hanging pictures of living people


Prove that $F_{x^{n+1}} \sim 5^{\frac{x-1}{2}}F_{x^n}^x \forall x,n \geq 1$, holding either variable constant while the other goes to infinity

Question: I noticed from looking at the prime factorizations of some Fibonacci numbers that all those with an index equal to a power of 5 divided that power of five, a property not guaranteed by the strong divisibility property alone. It was while searching for the approximate value of the characteristic factors of these numbers that I noticed $\frac{F_{5^{n+1}}}{F_{5^n}^{5}}\sim 5^2$ as n goes to infinity. Recognizing 5 as 2*2+1, I found that the above could be generalized to a special case of the asymptotic equality that I'm looking to prove in which x is odd. The difference between the two sides of the identity in question grows quite rapidly in absolute value as n increases, but this value is telescoping. For particular x, can we somehow use the set of approximations given by repeated application of the main identity to recursively identify the value of the Fibonacci number whose index is the following power of x?
Answer: Since $F_n \sim 5^{-\frac 12} \phi^n $ for large $n$, (where $\phi = \frac {1+ \sqrt 5}2$)
For fixed $x$ and large $n$, we have
$F_{x^{n+1}} \sim 5^{-\frac 12} \phi^{x^{n+1}} = 5^{\frac {x-1}2}(5^{-\frac 12} \phi^{x^n})^x  \sim 5^\frac{x-1}2 F_{x^n}^x$
Comment: Great! Is this not sufficient to also prove asymptotic equality for fixed n and large x?
Comment: to prove the equivalence for fixed $n$ and large $x$ you need more precision on how $F_n$ behaves and a more involved calculation.
Comment: @mercio I'm not sure you'd need more information on the behaviour of $F_n$ to analyse the "fixed $n$, large $x$" case. The value $x^n$ is going to be large if $x$ is large and the asymptotics for $F_k\sim 5^{-1/2} \phi^k$ is pretty tight enough even for small values of $k$ (since the other root, $\frac{1-\sqrt{5}}{2}$, is very small in absolute value).


Error: Process aborted, when installing zip in Moto Razr XT910

Question: I rooted my Motorola Razr XT910 already, then I followed the process and everything went excellent. But when I wiped my data, cache, and the dalvik cache, and then choosing install zip, I received the message that the process aborted!
I realized that I didn't backup and reset. So my ROM (the last one) was gone! I thought to transfer other files for the ROM I wanted to install, but everything said that it aborted! All of them.
Every time I plugged my phone LED color was white. I thought it means that there is no battery, and the computer isn't strong enough to charge the phone.

I plugged it into the wall and it turned on showing Motorola's logo (happens every time you turn it on) and remains stuck on that logo.
I plugged it out and the logo was gone.
I plugged back in and the logo showed up again, so I thought it's just the battery. After 12 hours and more the logo was still there.
I plugged out the phone from charging, and the logo stayed there.
I plugged it into the computer and the white LED light lit up.

How do I resolve this highly problematic issue?
Answer: Try downloading the correct ROM. It seems like your .zip file is not adequate.
To transfer it to the phone, enter recovery, and then tranfer either byadb push command, or by entering "ADB sideload" option (in recovery), and then using adb sideload command on PC.


Can I propagate a Jasminum sambac from an already growing plant?

Question: I already have a nicely flourishing Jasminum sambac outside my home. Its fragrance is so wonderful that I plan on growing it inside, near my room. Is there any way that I can grow it in a pot?
Answer: Propagation is usually with semi ripe cuttings taken in summer - keep them misted and they should root very quickly. Alternatively, you could try layering - peg a couple of shoots down into the soil and wait, they should form roots, but it takes quite a while for this to happen usually, some months.
Once you've got roots, grow the plant on in an appropriately sized pot - pot up into larger pots as it grows, until it's in a large pot, maybe 15 - 20 gallons, indoors. You will need to provide support for it in it's pot, or it'll twine round itself and then collapse, becoming a trailer and not a climber.
To grow successfully indoors, you need to be living in Zone 8 or higher. They like hot and humid conditions during the day, with cool nights, and a sunny spot; they will grow in shadier conditions, but tend to be darker with fewer flowers. May reach 5 feet indoors.


Money Market Account

Question: What is a Money Market account and what is its function? How does a money market work and can it protect large amounts of money? I want to protect my money and the FDIC only protect up to $250k. I don't have any knowledge of where to park my money safely. That's why I am here.
Comment: See too this answer http://money.stackexchange.com/a/3646/3361
Comment: Make sure you don't confuse `money market accounts` (e.g. at a bank) with `money market mutual funds`.  I can't think of any money market mutual fund that is FDIC insured, whereas *some* money market accounts (depending on the institution) *are* FDIC insured.
Answer: Money market accounts, insured in the same way as other deposits, are strange hybrids of traditional bank deposits and bond mutual funds.
Because of the high inflation of the 1970s, banks were starved of deposits and could not produce loans at sufficient rates.  For this reason, they desired a way to fund loans, and Congress enacted the Depository Institutions Deregulation and Monetary Control Act which permitted a new form of account that retained the functionality of a deposit account, such as checking and now electronic transfers, yet transferred the risk to the account thus most of the profit.  This allowed banks to fund each others' new loans through packaging them into asset backed securities to be held in these special accounts.
As an added "protection", they are not permitted to carry a market value less than what's owed to depositors and are forcibly liquidated and paid in such event.  This is a rare occurrence because of the nature of the assets held: credit assets such as commercial paper, mortgages, and corporate bonds.  This is the opposite case of deposits because so long as a bank can maintain payments on its liabilities and satisfy a few other regulatory requirements, non-regulation satisfying assets could theoretically carry a zero balance, meaning that a bank could owe depositors more than what could be paid by liquidating all assets.
Money market accounts will typically pay a higher rate because of their structure.  While inflation is low and immediate term interest rates set by the central bank are also low, the net figure will not appear high, but the ratio will be fantastic, usually something like 3x.
The one downside to money market accounts is that withdrawals are restricted by frequency.  This is not such a problem as before since brokerages are now issuing debit cards tied to brokerage accounts, and excess money can be "swept" into money market accounts, bypassing the regulatory restriction.
In short, money market accounts are currently a far better choice than traditional checking accounts but pay less than savings accounts.
Comment: Why do you say "pay less than savings accounts?"
Comment: I have the same question as @Ender. I just received a promotional offer from CapitalOne where they are offering 1.00% rate on their money market account.
Comment: Excellent history.  However, 2.5 years later, MMAs don't pay nearly the rate of standard savings accounts from online banks.
Answer: The FDIC guarantee is up to $250,000 per depositor per insured bank. If your goal is primarily to protect your money, you may want to consider depositing your money in multiple insured banks.
I'll leave it to someone else to accurately define money market accounts and how they function, and the (very low) risks you take with them.
Don't forget that inflation will eat into your money. It's unlikely you'll make enough interest either in a savings account or in a money market account to cover the inflation. You should factor this in to your overall investment plan.
Answer: My brokerage account (E-Trade) automatically spreads cash balances that exceed the FDIC insured amount into several partner banks, so just about any amount gets insured.

Money Market Account


How to customize the "New" button standard page with fewer fields?

Question: My requirement is when clicking "New" button in Opportunity Tab, in the standard page, it shows fewer fields. For example, if you only need to input the Name of the Opportunity, the page only show the Name field.
Point is that it should stay as pop-up, I tried override "New" button with Visualforce page but it is not pop-up anymore.
Comment: Welcome to SFSE. please include any code snippets you tried before. so people can help you.
Comment: This link in trailhead might help with over-riding a quick action. https://trailhead.salesforce.com/en/content/learn/modules/lex_javascript_button_migration/javascript_buttons_to_lightning_actions
Answer: If I got your requirement correctly then I suggest you can go to the page layout of Opportunity SObject and remove all the other fields that are not required without using Visualforce. The procedure is Setup > Object Manager > Opportunity > Page Layout > Oppotunity Layout
Answer: Thank y'all.
After one day's struggling, I finally find a solution - to override New Button with a lightning component, which has a modal style and looks like a popup. It kind of solve my problem (although unliking a "action", the background do change after I click the button).
Thank you angain for all the help, I do appreciate.