Multiple User Messages on list Validation Settings

Question: Is there any OOB way to display different user message per validation?
Comment: Hi @Damian, did you check my answer below? Let me know if you still need any help with this.
Answer: Unfortunately, No.
You cannot add multiple user messages on list validation settings. You will have to combine all the validation messages in the single text box as validation message is a simple text input.
Documentation: Validation element (List)

Additional:
If you have any validation which will use only single column value in formula, consider using the column validation under column settings - here you can add different validation user message:

Note: If your formula/condition is using multiple column values, you will have to use the "list validation" only as column validation does not support reading values from another columns in the formula conditions.


How to kill a stored procedure which is in open transaction?

Question: I have a stored procedure which is running since four hours but it's uncommitted. How to check if it's running currently and kill it.
Answer: Download SP_WhoisActive from here: http://whoisactive.com/
run it with this query: SP_whoisactive
the result will show everything running at the moment, you will be able to identify your running stored procedure.
then run: kill [session_id from query above]
the transaction will be rolled back.


Is there a minimum spacing planted trees need to grow?

Question: Does this game use the New Leaf rules?
Answer: No, it's not quite like New Leaf but back to that in a sec.
Yes, you need space all around the tree/sapling, as in it can't be up against a building, right next to the slope to the beach, or even on that peninsula jutting out to the right on the island. A tree that cannot grow in that spot will just remain a stunted sapling.
A good way to test whether a tree can grow in that spot is to dig up a sapling from elsewhere and try to plant it in the target spot (rather than planting the seed or fruit). The hole won't let you plant the sapling if it's a bad location.
But back to that New Leaf stuff, the weird issue of tree spacing (in which the tree in the middle of a group of trees wouldn't grow) has been resolved:
Comment: Hmm, in my experience I needed the trees to have 1 space inbetween them horizontally, but 2 spaces vertically. Your pictures show 1 and 1. What did I do wrong?
Comment: A small exception to the building rule is that you _can_ build fences directly next to trees
Answer: Yes, new leaf rules still apply, you need space all around for a tree to exist. even if you uproot the whole thing using hunger, it wont let you replant the tree if there isnt room.


cross border contract

Question: If two entities from different countries A, B sign a contract, does the contract follow:

law of the country, where the contract is signed
law of a country of choice from A and B
international contract law

?
Thank you.
Answer: The question you have posed is called a "choice of law" question. All three of the possibilities that you suggest (and more) are the right answer in some circumstances.
Choice of law by agreement
Unless the choice of law for some reason violates public policy (e.g. because the law of country A does not make something illegal, but the law of country B where the contract is to be performed does make something illegal) a choice of law made within a clause an international contract that has any connection to the parties or the contract will be honored (which is your possibility number 2).
General choice of law rules when there isn't a contractual choice of law
Before you have a contract, the issues of contract formation, and other contract law issues to the extent that there is no choice of law clause in the contract that does not violate public policy, could be governed by the law of the place where the contract is signed, by the law of A or B since they are parties to the contract, or, for example, by the law of the place where the contract is to be performed.
The leading choice of law rule in the United States in these circumstances is to apply the law of the one of those options with the most significant relationship to the contract, which is a test that is just as fuzzy and indeterminate and open to case by case interpretation as it seems.
Also, there isn't necessarily only one set of laws that will apply to the contract. The legal term for applying different laws to different issues that arise in the same legal case is called dépeçage.
For example, the law of the place where the contract is signed might govern the issue of contract formation, while the law of the place where the contract is to be performed might govern performance of the contract.
Consumer protection laws are often applied to contracts with consumers based upon the place where the consumer is domiciled or is located when the contract is entered into by the parties.
It isn't unusual for a contract to be subject to the law of more than one place on issues other than issues of contract formation, and other than on issues of contract interpretation. But, any given legal issue related to a contract is ordinarily subject to only a single jurisdictions laws (unless it is a public policy regulation).
Unless anyone argues in court that the law from another place should apply to an issue and that law is different from the legal rule in the place where the court is located, in a court case, a court will apply the law of the place where the court is located (called the "law of the forum."
Exceptions to the general rule
There are some international treaties which create exceptions to the general rule and instead provide that a contract will be governed by law established in an international treaty (which is your possibility three). There are at least two such treaties to which the United States is a party which are notable and come up with some frequency.
One of them is the CISG, which is the Convention on the International Sale of Goods that governs international contracts for the sale of goods that are not expressly excepted from the treaty (mostly business to business sales of goods), when both the seller and the buyer are associated with a country that is a party to the treaty.
Another is the New York Convention a.k.a. the "Convention on the Recognition and Enforcement of Foreign Arbitral Awards" a.k.a. the "New York Arbitration Convention" which governs governs contracts with arbitration clauses in them that involve parties from different countries that are both parties to the Convention.
In addition to these treaty provisions, some international contracts are governed in the United States by admiralty law, rather than by the federal and state laws that would otherwise apply to these contracts. Obviously, the affected contracts are contracts with a maritime dimension, either in international waters or in the "navigable waters of the United States."
I am certain that this list of exceptions governed by special laws is not complete (e.g. certain international treaties apply to contracts involving international airline travel), but the question doesn't identify anything about the contracts that make them stand out.
Answer: Very often in internation contracts there will be a choice of law clause, which will specifically address this issue.
If no choice of law clause is part of the contract (very unlikely) then it seems according to at least some sources in this case https://www.trans-lex.org/971000/_/law-applicable-to-international-contracts/

(a) A contract shall be governed by the law chosen by the parties. The choice shall be made expressly or clearly demonstrated by the terms of the contract or the circumstances of the case. By their choice the parties can select the law applicable to the whole or to only part of the contract. The parties may at any time agree to subject the contract to a law other than that which previously governed it.

(b) Absent a choice of law by the parties, a contract is governed by the law with which the contract is most closely connected ("centre of gravity test"; "engster Zusammenhang"; "liens les plus étroits").

(c) Contracts are most closely connected with the law of the country where the party required to effect the characteristic performance has its habitual residence, seat or place of business.

(d) Where it is clear from all the circumstances of the case that the contract is manifestly more closely connected with a country other than that indicated in paragraphs (b) or (c), the law of that other country shall apply.

(e) The law applicable to a contract by virtue of this Principle shall govern in particular:

i) interpretation;

ii) performance;

iii) the consequences of a total or partial breach of obligations, including the assessment of damages in so far as it is governed by rules of law;

iv) the various ways of extinguishing obligations, and prescription and limitation of actions;

v) the consequences of nullity of the contract.

cross border contract


Will a mobile provider cut off services?

Question: For instance, if a mobile phone provider received a court order/request for subscriber details because of 'illegal' activity, would they cut that subscribers services because of it or even make their connection slower?
Comment: It's asking about potential consequences of illegal activity. It's as much a legal question as "will I go to jail for activity X"?
Comment: How does this pertain to law? Are you asking if they are legally allowed to?
Answer: Whether or not a provider will cut off or restrict service depends on (a) what the contract says and (b) whether the company is willing to ignore the contract. If they ignore the contract, and the contract doesn't allow them to cut off service in that circumstance, they may get sued, but that depends on the customer. No principle of law say that if a company receives a court order to produce data pertaining to a customer, the provider is compelled to terminate service (a court order could conceivably itself mandate terminating service). Without specifying a jurisdiction it is hard to say whether it is true in all countries, but in no jurisdiction that I know of is a provider entitled to breach a contract because the court has issued an order to provide information about a customer. In general, if you want to know what a phone company can do, read the contract.
Answer: It is routine for contracts with service providers to contain provisions where the customer agrees not to use the service for illegal activity, and it is routine to include provisions allowing the provider to take certain actions as a result.
I don't know anything about your mobile contract, obviously, but I can tell you that AT&T, for instance, will slow down service for people who are repeatedly the subject of DCMA infringment notices, and that they at least threaten to cut off service, as well. Don't ask how I know that.


Preventing an unauthorized mobile application from calling REST back end services

Question: In my scenario, I have an Android mobile application which calls my back end REST services. I want prevent other application to call my back end REST services.
If I use certificate and shared key as well as obfuscating my application's code, attackers can beautifier my source code and do reverse engineering.
Answer: This is near impossible to achieve (short of white-listing IP addresses). Given someone has enough time and resources, they will almost certainly be able to send calls to your API outside of your client. In general, you want to assume attackers know everything about your API and design your API to be resilient to attacks (Ex. good authentication practices with correct limiting, etc.), otherwise, you would likely be fighting a losing battle.
A great example I like to bring up is the Pokemon Go API (link here). Hackers were quickly able to create 3rd party clients that would send erroneous location data and allow users to catch Pokemon from all over the world. Despite API updates, hackers continuously re-reversed engineered the necessary steps to send valid API calls.


Streaming live video from a camera to a display using two arduino UNOs

Question: My question is pretty much in the title. Is it possible to send live video from a camera connected to one arduino uno, to another arduino uno with a monitor connected? (Via wifi, Bluetooth, radio, etc.) Will they have enough processing power and can any simple data transfer methods allow such large amounts of data? Please inform me on the details if this is possible, or if not possible, explain other ways using a similar setup.
Thanks in advance.
Comment: Your best bet would be to take out the Arduino from the equation, **especially** when sending and receiving data wirelessly. Two FPGA's could easily do the job, but they are not the cheapest, also there would be a lot of _programming_ and _learning_ because FPGA's don't work exactly like microcontrollers.
Answer: Possible yes - practical very difficult.
In theory you can send video, but the uno has very little processing power which means that the resolution and framerate you will achieve is probably unsatisfying. I'm not currently aware of any libraries supporting this, so if you did go for this solution you will have to do a lot of programming your self.
I would recommend you to use a raspberry pi instead, or similar. This has the advantage of you being able to use a lot of ready made streaming library. In the end this will take you a lot further much quicker.
Check this out to get inspired: http://www.instructables.com/id/Raspberry-Pi-Video-Streaming/


Option 81 in DHCP

Question: Just curious about this.
When we enable option 81 on a DHCP network, the DHCP server will start updating the zone that comes along with the client's FQDN.
Now, how would client will ever know its domain even before getting an IP address?
My apologies if the question sounds dumb.
Thanks in advance, everyone.
Answer: Two locations:

Configure the Primary DNS Suffix for a Client Computer.
Configure a Connection-Specific DNS Name

Option 81 in DHCP


Available memory of a 16GB microSD card?

Question: Out of my newly bought Class 10 16GB microSD card I am getting only 14.71GB. Is this normal?
Comment: Yes, this is normal. Please read the "Customer confusion" part https://en.m.wikipedia.org/wiki/Gigabyte
Answer: Gigabytes are base 10, but Android uses Gibibytes (base 2)
See: http://www.wolframalpha.com/input/?i=16GB+to+GiB.
This is needed because binary data is written in base 2, but SI units are base 10.
Answer: Adding on to @GiantTree's answer, the binary-metric confusion is definitely one reason you encounter these kinds of differentially reported storage counts. Another thing is the formatting / file system overhead involved.
Normally, larger the SD card, larger will be the lost available storage due to the storage space required by the file system data structures like allocation tables, etc.
Android uses FAT32 or VFAT for SD cards by default, and, yes, this formatting does cause a significant loss in available storage.
Note also that newer Android devices or devices with modified kernels can support other file systems on the SD card such as ext4, NTFS or exFAT. All of these file systems have larger overheads compared to the FAT32/VFAT default, and ext4 and NTFS the highest among these.
As @Edgar posted, this can be thought of as the difference between the volume of a container measured internally and externally. The file system overheads account for the thickness, and the other part involves a different system of units used for measurement.
Put together, the decimal(metric)-binary confusion, file system overheads and also manufacturing issues cause this difference between advertised and reported storage capacity.
About manufacturing defects, I'm quoting from the accepted answer to this Unix&Linux SE question:

Typically a part of flash storage is faulty, and is marked so during manufacturing. There are also other bits that can go wrong (becoming unchangeable, unsettable, or unclearable), these parts must be marked faulty as well during the lifetime. This information is stored in a reserved space, on the same chips as your data. This is one of the several reasons a 4GB thumb drive is not showing 2^32 bytes capacity.
Answer: Also, all disks have 'bad sectors' which are not reported in the user available space.
Another thing that takes up space in a drive is the file structure inherent in the device itself.
A good way to understand this is to measure the exterior front wall of your house, then go from room to room, measuring the inside dimensions, omitting the interior walls and total up THOSE dimensions. Not the same, are they?
Comment: This answer seems a better fit for SuperUser than Android Enthusiasts. Please try to post an answer which is relevant directly to Android on Android Enthusiasts.


Replacing identical NIC cards creates eth1 instead of using eth0 in Ubuntu

Question: I changed out a NIC card that was the exact same make and model.  The setup process for Ubuntu 11.04 was very seemless and easy so I figured it would be smart enough to setup up the replacement card.  However, it gave the replacement card a new name of eth1 where all my scripts make reference to eth0, not to mention everywhere else in the OS eth0 may exist.  Am I forced to track down every eth0 reference and change it to eth1 or is there a way to rename the replacement card back to eth0?
Answer: Check udev config files.
A file like this:
    /etc/udev/rules.d/70-persistent-net.rules
ties the NAME (ethX) to the Mac address.
You probably have the old cards MAC tied to eth0. Remove its line and change the new card to eth0.
Comment: Thanks!  I did see in another post about the 70-persisten-net.rules file, but was in reference to fedora.  The file was just in a different location, but good know it is the same file.
Comment: To think I was using `ifrename(8)` and scratching my head! This solution is much more elegant.
Answer: You can set the name of network interfaces either through udev (on any modern Linux system) or through /etc/network/interfaces on Debian, Ubuntu and other distributions using ifupdown. Not Now's answer covers udev; I'll discuss ifupdown.
In /etc/network/interfaces, you can use the mapping directive to give a nicknames to an interface based on the result of running a shell script. Typical uses for this feature are to give interfaces different names based on the network surroundings (e.g. eth0-home and eth0-work) or to set the name of an interface based on its characteristics such as the MAC address. There is an example script called get-mac-address.sh that you can use to set the name of an interface based on its MAC.
auto eth0 eth1
mapping eth0 eth1
    script /usr/share/doc/ifupdown/examples/get-mac-address.sh
    map 11:22:33:44:55:66 lan
    map AA:BB:CC:DD:EE:FF internet
iface lan inet static
    address 192.168.42.1
    netmask 255.255.255.0
iface internet inet dhcp

Now your two network interfaces are called lan and internet. If you ever replace one of them, you only need to update the MAC address in that one place in /etc/network/interfaces.


Two mirrors facing each other

Question: What happens when you place two mirrors facing each other? Is it possible to have an infinite amount of reflections?
Comment: Related: http://physics.stackexchange.com/q/13500/2451 and links therein.
Answer: This question reminds me of Zeno's paradoxes.
It is assumed that the two mirror surfaces are absolutely parallel.
In classical physics the electromagnetic waves that create the reflections are uniform and the energy loss due to the reflection ( depending on the material of the glass) will be what will make the reflections fainter and fainter, but the process is continuous and the limit will be a limit in luminosity. In principle a totally reflecting material would have no limit, going to infinite reflections as time goes to infinity. {corrected from the original statement that the wavefronts are instantaneous: Maxwell's equations obey special relativity i.e. the velocity c of light is finite}
Reality is quantum mechanical and also special relativity dependent.
With special relativity in the problem it will take time to reach the next reflection, so even for a total reflector infinity will also be reached only at infinite time, during observation, though there will be an enormous number of reflections.
Quantum mechanically there can not be a totally reflecting mirror, even in a thought problem. There will always be a probability of absorption and thus termination of the wavefront eventually, the images getting less and less defined until they become individual photons and finally totally absorbed.
Since quantum mechanics reigns, in reality, no, there will not be an infinite amount of reflections.
Comment: Thank you for providing a concise answer! And for including the quantum mechanics portion. :)
Answer: Such arrangements are common in lasers: "An optical cavity, resonating cavity or optical resonator is an arrangement of mirrors that forms a standing wave cavity resonator for light waves. Optical cavities are a major component of lasers". https://en.m.wikipedia.org/wiki/Optical_cavity
The loss in such resonators are characterised by the q factor: https://en.m.wikipedia.org/wiki/Q_factor
Comment: To fully answer the question, you need to point out that to get infinite reflections, you would need a Q factor of infinity, which is not achievable in practice. Any non-infinite Q-factor will eventually lead to the dissipation of the input energy.

Two mirrors facing each other


How to share files between two machines in a network with a router?

Question: I have a notebook with ubuntu 13.04 and a desktop with Debian 7.1.0 and I want to know how can I share files between the two machines, I'm using a router and the notebook is connected to the wireless network, since the desktop is on eth0. Can someone tell me how to share files betwen the two? Because I know absolutely nothing of networks. Thanks to those who respond.
Comment: I have a friend who uses sshfs for Linux to Linux connectivity.
Answer: What do you mean by "sharing"?
If you just want to download a small number of files from one computer to another, you can run python2 -m SimpleHTTPServer 8001 in the directory of the files to be shared on one computer. Then on another computer, use your browser (or other tools like wget) to navigate to the url http://x.x.x.x:8001/ to view/download the files. x.x.x.x is to be replaced by the IP address of the former computer.
If you have a large number of files to copy, I suggest rsync though ssh. But it works well if you have ssh server up and running at least one computer.
If you want more complicated sharing, you may want to try NFS or sshfs.
Comment: Wow, I never knew you can set up a temporary HTTP server that easily, and always ended up downloading apache. This is certainly very handy!
Answer: On nautilus you can right click the folder and choose share options. This will install the required software and share the folder using samba. This share will be visible form linux, windows and mac.
Answer: There are many ways. Everything has it's advantages. This is a good one that should be mentioned. Very easy to set up.
Bittorrent Sync
I recommend BTS especially for very big files like videos or so. It's easy to use and also can work over the internet (by default). It is similar to Dropbox (syncs folders), but without a central server. Available for Win, Mac, Linux, Android, iOS. More Information in this answer: Peer To Peer (P2P) Sync and Share Ubuntu
Answer: Patterson Eaglesoft is very picky!
On the XP server machine, go to:
My computer
Tools
Folder options
View
Uncheck Simple file sharing
Go to your Data folder
Sharing
Share the folder
Make sure that everyone has full control
Should work now.  If not on the remote PC, go the the technical reference, data base setup and type Host=name of server PC.  Example. Host=dell1525
Answer: SYNCTHING
This is an opensource alternative to dropbox, Google-drive, etc, and like Bittorrent Sync, does not require storing your data on a third party server (something I once heard referred to as "running naked through the google-plex". An apt description I think). It is also cross platform. Linux, Windows, Apple, Android. Once installed and set up, you create a folder on each machine, exchange ID keys and they stay in sync. Changes in any one are reflected across all, data being exchanged/synchronized at any time the two (or more) machines are online at the same time. If you have a home server (raspberry pi with a large HDD attached ??) that is online all the time, you can have a fully private dropbox equivalent.
check it out for yourself here:
https://docs.syncthing.net
Answer: The easiest way is to just use a flash drive to transfer files.  You could also upload your files to the cloud(eg: Google Drive, Dropbox, Ubuntu One, ect.) and download them on your other computer.


Formula for Cohort Fertility Rate

Question: I understand the definition of Cohort Fertility Rate as the average number of live births that a woman born in a particular year has had by the end of her reproductive life. But is there a formula to calculate it? I tried googling but in vain. I have seen formula for many other fertility indicators like CBR, IMR etc. All of them have some formula for direct computation but I couldn't find any such idea for CFR. If there isn't any formula then please direct me to the mechanism of its calculation.
Comment: Seems like you could derive this? I think you would need: (1) age, year specific fertility rates and (2) age, year specific mortality rates. There may be a bit of trickiness at the interaction of fertility and mortality within a year, but I imagine getting that right doesn't matter for rich countries with low mortality rates.
Answer: I'm not a demographer, but here's my stab at what it would be:

Let $d_{a,t}$ be the mortality rate for women age $a$ in year $t$.
Let $x_{a,b}$ be the fraction of women age $a$ that were born in year $b$ and still alive.
Let $f_{a,t}$ be the fertility rate for women age $a$ in year $t$.
One hundred percent of women born are alive, hence: $x_{0,b} = 1$. Then we have:
$$ x_{a+1,b} = (1 - d_{a,a+b}) x_{a,b}$$
Let $l_{a,b}$ be live births for women age $a$ and born in year $b$. You might want to think about this more, but somewhere to start might be:

$$ l_{a,b} = f_{a,a+b} x_{a+1,b} \quad \text{<--- assumes all women that die don't give birth... probably not right}$$
Then lifetime cohort fertility would be:
$$c_b = \sum_a l_{a,b}$$
Comment: Yeah, the latter assumption creates a problem especially when we are dealing with developing and under-developed countries data. $x_{a+1,b}$ factor creates a problem in the $l_{a,b}$ formula.

Formula for Cohort Fertility Rate


CTRL J on my mirrored object is creating a duplicate

Question: For some reason, when i use CTRL + J on my model selecting first the helmet (which is mirrored) and then the rest of the other parts of my model (which some of them are mirrored too), the result is my model being together yes, but also having a duplicate inside of it as well as the images below show. The first is before CTRL + J, the second is the result.
Answer: When you join objects, the modifiers on the active object (the last selected before joining) are kept as is, and the modifiers of all the other objects are ignored. If your joined all your character's parts into the one object with a mirror modifier, then the final object will still have the mirror modifier and will therefore mirror the whole object.
To avoid duplicated mesh, either delete half of your character before joining so that the mirror does what you intend, or apply the mirror modifier before joining the object.


Is there any good documentation on sysfs?

Question: I'm looking for good documentation for sysfs; the man page is incomplete and even has one sentence that just stops half way through. I've found the Linux kernel documentation but that's a little bit too geared towards programmers as opposed to administration. If anyone can suggest a good source I'd be grateful.
Comment: What sentence are you referring to?
Comment: @ArkadiuszDrabczyk it's the following excerpt from the description of the parameters/ directories within the subdirectories of /sys/module: "This  directory contains one file for each module parameter, with each file containing the value  of  the  corre‐sponding  parameter. Some  of these files are writable, allowing the"
Answer: The only vaguely up-to-date documentation is the kernel documentation, Documentation for /proc/sys. I'm (slowly) working my way through it, trying to ensure it's complete, devoid of obsolete entries, and more understandable for administrators (after all, it's part of the administrator's guide); see the /proc/sys/kernel documentation for example. I do realise that even the "improved" documentation is still hard to understand.
Relevant settings are also supposed to be mentioned in manpages where they're relevant, i.e. close to the point of use.
If you have any specific questions, feel free to ask them here.


Is saying subhanallah when surprised from the sunnah?

Question: I have heard people saying subhanallah when they are surprised by something. Is this practice from the sunnah? If it is from the sunnah, then could you provide some evidence that would prove that it is from the sunnah?
Answer: Let us understand the meaning and intent behind using this word which will clarify your question. Let us focus on the first part of the word which comes from the root (س ب ح) which means to keep something afloat.

وَهُوَ الَّذِي خَلَقَ اللَّيْلَ وَالنَّهَارَ وَالشَّمْسَ وَالْقَمَرَ
ۖ كُلٌّ فِي فَلَكٍ يَسْبَحُونَ
And He it is Who has created the
night and the day, and the sun and the moon, each in an orbit
floating. Quran 21:33

The concept of keeping something afloat is used in glorifying Allah is to separate and place the Creator above the creation and to realise the imperfection of the Creation while appreciating the absolute perfection of the Creator and negating defects attributed to the creator. The common translation that you see for subhanAllah is Glory be to Allah which might be correct to some extent but it is not the exact translation. The closest translation would "Allah is above all imperfection". This can be realised by looking at the verses of Quran. Allah has used the word subhanAllah to negate imperfection attributed to him. Here is one such example from Surah Zumar verse 4, where Allah says he is free from the human imperfection of having children.

لَّوْ أَرَادَ اللَّهُ أَن يَتَّخِذَ وَلَدًا لَّاصْطَفَىٰ مِمَّا
يَخْلُقُ مَا يَشَاءُ ۚ سُبْحَانَهُ  هُوَ اللَّهُ الْوَاحِدُ
الْقَهَّارُ
Had Allâh willed to take a son (or offspring), He could have chosen
whom He willed out of those whom He created. But glory be to Him!
(He is above such things). He is Allâh, the One, the Irresistible.
Quran 39:4

The word 'tasbeeh' means the act of saying subhanAllah just as tahmeed means the act of saying alhamdulillah and takbir means act of saying AllahuAkbar
When one does tasbeeh, they negate any flaw and affirm all perfection in Allah.
Hence somebody might be surprised when they see something extraordinarily beautiful and they might say subhanAllah, which basically means that, even though the creation is looking astonishing, it still has imperfection and the one who created has absolute perfection.
Hope this clarifies.
Answer: Assalamu Alaikum brother or sister,
I think your question is answered here. Kindly refer to the following link.
https://islamqa.org/hanafi/hadithanswers/119684/saying-subhanallah-or-allahu-akbar-when-suprised/
Comment: See [Are link-only answers acceptable here?](https://islam.meta.stackexchange.com/questions/1185/)


Missing columns on WFS (GeoServer/MongoDB)

Question: We are currently checking up on GeoServer over MongoDB on our dev-environment. We are having some difficulties: we have a collection, containing different documents which answer to the same structure ("schema-like"). When querying a WFS service from GeoServer - some of the columns are missing.  We discovered that if one of the "columns" on one of the documents contains null value - the whole column does not appear on the query response.
Is there some configuration we are missing on the GeoServer to return null values on WFS response?
Even if one instance of an attribute value equals null, the whole column is missing. I don't see how DescribeFeatureType may help as many Q&aA already suggested over the web.
Answer: I had a similar problem, when my data contained nulls geoserver did not load the data at all. I could only resolve this by replacing nulls with "null" (convert to String) before loading it to mongodb.
Comment: I did the same, but was afraid of problems when querying it. Decided to change the db to postgre for meanwhile till there be a more elegant solution


Standard Deviation shows that a price series is riskier but annualized volatility computed with the log of returns shows the opposite

Question: I apologize if this is not a smart question, but it seems contradictory that the standard deviations of two price series show that series A is riskier, but when I plot the annualized volatilities (using the log returns), series B seems riskier.
Is it normal?
In the volatility plot below, the pink series is the one with the lowest standard deviation for its prices (30.00 vs 47.4 for the blue one)
Answer: It's not really a contradiction. Computing the standard deviation of the returns rather than the prices discards information about the scale of the prices.
Take a price series $X_t$ and define the returns:
$$r_t = \log\left(\frac{X_t}{X_{t-1}}\right)$$
Then, any rescaling $Y_t = a X_t$ has the same returns, for any $a \neq 0$:
$$\log\left(\frac{aX_t}{aX_{t-1}}\right) = \log\left(\frac{X_t}{X_{t-1}}\right) = r_t$$
The standard deviation of the returns of $X_t$ and of $Y_t$ are therefore identical.
However, if you compare the standard deviation of the prices, if $a > 1$ then $Y_t$ will have a greater standard deviation, and if $a < 1$, it will be smaller.
More generally, for any two price series, if the first has smaller standard deviation for returns, the second could have larger, smaller, or the same standard deviation for prices, depending on the relative scale of prices.
In a financial context, the variance of the returns is typically the one that is considered, for a number of reasons.
Comment: Oh yes! thank you! the standard deviation of returns is indeed higher for the series that appears to have a higher volatility.


Why is my 7D so loud?

Question: I upgraded from my XTI with the 28-105 USM lens to the 7d with the 28-135 (130 maybe) USM IS lens.  I'm just getting it unboxed and getting familiar with some of the buttons, etc - but i've noticed that the camera seems exceptionally loud while firing off photos, and the lens seems loud while autofocusing.  That may just be a case of "that's the way it is," but shouldn't a newer, more advanced camera be quieter? Or is that just me showing the noob-factor?  Thanks
Comment: As you get higher-performing and larger equipment, it will make more noise. In some cameras, such as your 7D, you can slow it down to reduce noise (see the answer by @dpollitt). Your lens is supposed to be pretty quiet. Try to compare it with another 28-135 to benchmark.
Answer: In addition to @Guffa 's great answer, the Canon 7D does have two silent shooting modes. If you are in a situation that you are concerned about the noise that your camera is producing - that is exactly why they now have these modes. You do tradeoff performance in either speed of the shots or AF - but if you just need to take a quiet shot in a church for example it is a great alternative.
You have two modes, Mode 1 and Mode 2. Mode 1 leaves the shutter curtain open while you shoot continuously. Mode 2 is for single shot and just lets you decide when to reopen the shutter. Try them out, I think this will resolve your concern about any additional noise, as they are considerably quieter options then the standard modes.
Answer: A newer, more advanced camera isn't neccesarily more quiet, because the sound level is not so high on the priority list. Simply put, quiet cameras doesn't sell better. (Well, at least not compared to other features.) Actually, more advanced might mean that it gets louder.
If the sensor is larger, then there is also a larger mirror, so flipping up the mirror makes more noise. Also, if the delay from pressing the button until the image is captured has been cut, the mirror has to move faster, which makes it louder.
If the auto focus is faster (which it often is on a newer camera), it generally makes more noise simply because the motor has to do more work to move the lens elements faster. Also, if the lens has larger lens elements (to allow a larger aperture), then there is also more mass for the focus motor to move.
Comment: True that larger sensors ==> larger mirror and shutter, which have to cover more distance and are usually louder. But Rebel to 7D is still APS-C. So in the OP's case, that particular reason doesn't hold. Other things, auto-focus, faster shots per second, etc still do.
Comment: But there are USM lens in canon lineup which are silent and fast right ?
Comment: @PatFarrell: Yes, I expected that they may have the same sensor size, but I tried to make the answer more general, and not just about two specific camera models. :)
Answer: The max shutter speed on the 7D is 1/8000", while on the XTi it's 1/4000". That means that the shutter itself moves twice as fast across the sensor. It's possible that the mirror also moves faster on the 7D than it does on the XTi. Both lenses should be fairly quiet as they both have USM motors, but the image stabilizer in your new lens may contribute a small amount of additional noise.
The Canon 5D and 6D have "silent" modes which actually slow down the mirror and thus reduce noise somewhat. The 7D takes a different approach -- it's "silent shooting" modes function only during live view, i.e. when you're using the display instead of the viewfinder.
Comment: As far as I know, shutter speeds higher than the sync speed are not necessarily a function of the real speed of the shutter curtains, as actually they are achieved by closing the curtains before they are completely opened.
Comparing sync speeds is a more accurate comparison imho.
Comment: Just checked.. and according to wikipedia, the sync of 7D is 1/250 while the XTi is 1/200 so, yes, the 7D seems to be faster also when compared by sync speeds.
Comment: Great point, @MarcoMp. It may not quite be true that the shutter has to move twice as fast, but it does have to be faster unless the 7D's minimum distance between first and second shutter is 1/2 that of the XTi.
Answer: The sound you here is louder because the Canon EOS 7D is built tougher than the XTi. Its shutter is rated for more usage, faster shutter-speeds, faster continuous drive. Plus, most of this applies to the mirror mechanism too. A faster moving mirror gives you a shorter black-out-time which is highly desirable. This tougher mirror and shutter makes more noise which is what you hear with every shot.
You can use one of the quiet modes to slow things down and you will hear the difference. Things move slower, so they make less noise.
Your former lens is very quiet, I have one of those. I have seen your new lens but do not recall if it was louder or not. This may be simply mechanical differences as well.
Answer: I would suspect the reason is purely because the mirror moves much faster, thus it makes more noise when it stops.
The 7D can fire 8fps.  So the mirror is designed to be raised and lowered 8 times per second, with enough time in between to give the camera a reasonable chance to focus. This means that the time to raise and lower the mirror has to be much faster than 1/8th of a second.

Why is my 7D so loud?


Upper Triangular and Diagonal Matrices

Question: I'm trying to understand the difference between Upper Triangular and Diagonal Matrices for square matrices. There is a theorem that says every matrix can be made into an upper triangular matrix. Now if my matrix as the same number of eigenvectors as its dimension then I can make a Diagonal matrix by changing the basis to the eigenspace. So in this case, why will I ever prefer to make a matrix Upper Triangular(and not diagonal)  when I can make it diagonal?
Comment: Sometimes we are interested in bases which are orthonormal. Even if a matrix is diagonalisable in other bases, it may not be diagonalisable in an orthonormal basis.
Comment: Why would you change the matrix in the first place? What's your intention? Do you want to solve a linear system of equations or is it the characteristic matrix of a linear dynamical system? As it stands, this question is a good candidate for closure becasue of lack of context
Answer: Perhaps that you are missing the fact that every diagonal matrix is upper triangular too. So, if a matrix is diagonalizable, it is, by definition, similar to a diagonal matrix. Otherwise, it is not similar to a diagonal matrix, but it is still similar to an upper triangular one (at least over an algebraically closed field, such as $\mathbb C$).
Comment: I meant why will I ever prefer to make a matrix Upper Triangular(and not diagonal) when I can make it purely diagonal?
Comment: For no reason that I can imagine, other than the fact that sometimes a matrix is similar to a triangular one, but not to a diagonal one.

Upper Triangular and Diagonal Matrices


Controller isn't syncing to ps4

Question: I used my ps4 controller on my pc via bluetooth, I now disabled bluetooth on my pc and I am trying to hook the controller up to my ps4 now, I searched it up on google and it said to plug in the controller and press the ps button but that did not work, whenever i turn the controller on it just flashes light blue and eventually turns off what should I do?
Answer: You can try with a hard reset
The process to hard-reset PS4 controller is way too easy. All

You need is first turn off your console. The Reset button is located in a tiny hole at the back of the controller near the L2 button.
Using a paperclip, press and hold the Reset button for a few seconds. This should be enough to reset your controller.
The next step is to once again pair your controller with your device.

Simply connect the controller using the USB cable provided and then turn on your PS4 and proceed with the pairing procedure. If the connection fails, it's because the controller is not detected by the console. This might be due to the respective USB cable. The PS4 controllers are somewhat peculiar here. It's best to use an original Sony Micro USB cable. If you do not have one, you should try different Micro USB cables.
Now, press the PlayStation button on the controller to log into the PS4. The light bar should turn blue indicating the DualShock 4 has paired with the console.

Controller isn't syncing to ps4


If pseudorandom functions (PRFs) are deterministic in nature, how can encryption schemes using PRF be CPA secure?

Question: I am new to crytography. Can anybody tell me what I might be missing here?
Answer: The common way is to use a PRF for encryption is the CTR mode which is introduced by Whitfield Diffie and Martin Hellman in 1979;

Privacy and Authentication: An Introduction to Cryptography as an invited paper on Proceedings of the IEEE, 67 (1979), pp. 397–427.

This is a must-read paper that provides insight into the cryptography during 1970s. CTR mode doesn't need a PRP it can be work with a PRF and actually have better security bounds with the PFF( PRF-PRP switching lemma). To use the CTR mode with a PRF;

Choose a uniform random key on a key $k$

Choose a uniform random nonce ( counter-based are ok)

Generate the keystream $s_i$ as
$$s_i = PRF(key,nonce,i)$$

Encrypt the plaintext bit $p_i$ as $$c_i = p_i \oplus s_i$$

Like everything in cryptography, the CTR mode has advantages and disadvantages and the golden rule never uses an $(IV,key)$ pair again.
A well-known example is the ChaCha20 stream cipher based on the presumed ChaCha20 PRF.
CTR mode is CPA secure. To show the CPA security we need to play the Ind-CPA game.

Set the security parameter $1^n$
Call $Gen(1^n)$ to generate a key $k$
Provide $1^n$ to the adversary and Oracle Access to $E_k(\cdot)$
The adversary outputs the message $m_1$ and $m_2$ of the same length
Uniformly select a bit $b$ and send the ciphertext $c = E_k(m_b)$.
Adversary continue to using the oracle
Adversary outputcal_ $b'$
If $b=b'$ then output 1, else output 0.

Then, a scheme $\pi$ ( here CTR) is said to have Ind-CPA if
$$\Pr\left[ \operatorname{PrivK}^{CPA}_{\mathcal{A},\pi}\right] \leq \frac{1}{2} + \operatorname{negl}(n)$$
The proof is long to write here. See the Theorem 3.33 on the 3rd edition of Introduction to Modern Cryptography by Jonathan Katz and Yehuda Lindell
CTR mode is malleable, i.e. it cannot achieve CCA security. For this either use it together with a MAC like HMAC or use it in Authenticated Encryption mode fashion.

If pseudorandom functions (PRFs) are deterministic in nature, how can encryption schemes using PRF be CPA secure?

Yes, they are deterministic, however, the way we use them for encryption and decryption is probabilistic encryption. This is achieved even with the fixed key by using an IV/nonce per message. This is the sole reason that the advantage of the adversary is negligible.
Answer: Typically by using the secret key as input to the PRF.
Actually many stream ciphers are somewhat based on the fact that a PRF can be used to extend a key into a longer stream, the keystream, and then that keystream is XORed with the plaintext, à la OTP.
The deterministic nature of the PRF becomes a feature as it allows to easily recover the same keystream if you know the secret key, thus allowing for decryption by XORing the ciphertext with that same keystream to recover the initial plaintext.
Regarding CPA security
It is important to realize that a deterministic encryption scheme cannot be IND-CPA secure.
So a PRF being deterministic can seem like a bad thing there, but the "usual" workaround is to add randomness to the ciphertext by using a so-called "initialization vector". The initialization vector (IV) is basically a salt which will bring randomness to the process, so that 2 encryption of the same plaintext won't produce the same ciphertext. The IV should usually be a nonce, but only as long as we are reusing the same key.
Answer: It's true that PRF on its own is deterministic (think of standalone block cipher). This is why you add randomness (in a form of IV or nonce) to an encryption mode to make it IND-CPA.
Answer: You may be misunderstanding what "random" and "pseudorandom" mean. The words "random" and "pseudorandom" do not describe the functions themselves but the probability distribution from which the functions are chosen.
Technically, we don't have any definition of a "random" or "pseudorandom" function. What we have is either a "random" distribution of functions or a "pseudorandom" distribution of functions. Informally, a "pseudorandom" distribution of functions from $A$ to $B$ is defined as indistinguishable, by any polynomial-time algorithm, from a random distribution of functions from $A$ to $B$.
Mathematically, there's no such thing a "random", "deterministic", or "pseudorandom" function. But we still use those terms and they're understood implicitly.

How can encryption schemes using PRF be CPA secure?

In short, if an encryption scheme is secure using a random distribution of functions, then it's also secure using a "pseudorandom" distribution of functions, because the two are indistinguishable. Any algorithm that can break the scheme with a pseudorandom distribution, can be converted into an algorithm that can distinguish between the random and pseudorandom distributions.


How do you use the command 'watch'?

Question: I want to know exactly what the command watch is and how it is used to watch files and folders. How do you operate it from a command-line terminal?
Comment: welcome to AU! [..:: AskUbuntu Tour ::..](http://askubuntu.com/about)
Answer: From man watch

watch - execute a program periodically, showing output fullscreen

Say you want to monitor your network device status, you can use in terminal,
watch -n 2 nmcli dev

It will give you output as below which will be updated in every 2 seconds (as I used -n 2)
Every 2.0s: nmcli dev                                       Sat Jan 18 23:09:35 2014

DEVICE     TYPE              STATE
eth0       802-3-ethernet    connected
eth1       802-11-wireless   unavailable

If you want to keep watch on the changes of your files folders in a directory, use
watch -n 5 ls /path/to/directory

It will show you the list of files and folders in that directory which will be updated in every 5 seconds.
Comment: Even you can use `watch -d ls /path/to/directory`. It will update the list in every 2 seconds by default.
Answer: If you are referring to the command watch, it basically run a command every so often, by default every 2 seconds, and shows the output fullscreen.
For a fairly lengthy example, open terminal, and enter:
sleep 5; echo "hello world" >> ~/newfile.txt

This will wait 5 seconds, and then output "hello world" to the text file ~/newfile.txt
Don't execute it, but open a new - Ctrl+Shift+T.
Enter this, and run it:
watch -n 2.5 ls ~

This will tell watch to run the command ls ~ (which lists the contents of the home directory ~), every 2.5 seconds -n 2.5.
Go back to the tab with the sleep.., and run that command, then switch back to the tab with the watch command in. You should see the newfile.txt ventually appear in the output.
For more info, view the manual page for watch with:
man watch

How do you use the command 'watch'?


Fresh install on local won't let me log in

Question: I downloaded 1.8 version and installed it on my localhost, when i was done with install, i tried logging into backend. But it won't let me login, neither it gives me any error but refresh the admin page, i tried giving it wrong password and it prompted about invalid username and password. If so, why isn't my password and login working whereas there is no message of invalid login or password. just same admin page reloads?
Comment: Don't use `localhost` as base url. Use 127.0.0.1 or a virtual host.
Answer: This has happened to me before when using a URL without a FQDN, for example magedev. I had to change it to magedev.local in order to get Magento working correctly. Not using the FQDN also caused Magento to not install the database fully (all of the tables were there but some of the core data was missing).
Another solution, if you are sure that you are using a FQDN and Magento has installed itself correctly, is to try clearing all of your domain cookies. I've ran into an issue before with them getting "stuck" for lack of a better term and not allowing me to log in.
Answer: Instead of using localhost I used 127.0.0.1 This solved the issue.
Answer: Open the File : app\code\core\Mage\Core\Model\Session\Abstract... and check the code in
 $cookieParams = array(
        'lifetime' => $cookie->getLifetime(),
        'path'     => $cookie->getPath(),
        'domain'   => $cookie->getConfigDomain(),
        'secure'   => $cookie->isSecure(),
       'httponly' => $cookie->getHttponly()
    );

Comment the last three array parameters( domain, secure, httponly)and then try to login
If the issue is the same then comment the
if (isset($cookieParams['domain'])) {
            $cookieParams['domain'] = $cookie->getDomain();
        }

        call_user_func_array('session_set_cookie_params', $cookieParams);

        if (!empty($sessionName)) {
            $this->setSessionName($sessionName);
        }

and try to login .. surly it will work for you. :)
Comment: Why you need to change core file?
Comment: Generally, it seems like browser is not storing the cookies as domain name is not specified. Instead of commenting, you can try by using IP such as htp://127.0.0.1/magento in place of localhost/magento. I personally like to use localhost/magento way so I comment that.
Comment: @MagnetoBoy The first trick worked, why wasn't it working before?
Comment: Editing a core file should never be the correct answer.


How to partition a problem into smaller understandable portions?

Question: I'm not sure if it's possible to give general advice on this topic, but please try. It's hard to explain my case because it's too complex to explain. And that's exactly the problem.
I seem to constantly stumble on a situation where I try to design some part of my project, but it has so many things to take into consideration that I'm unable to get a grasp of it.
Are there any general tips or advice on how to look at my system in smaller pieces at a time? How to find smaller portions that could be designed separately on their own?
Comment: Added tag "decomposition". That, and factoring, are formal names for what you're trying to do. Searching on those terms might give you some places to start.
Answer: Create a glossary.
In other words, identify the terms that are meaningful to the project domain — not from the programmer's point of view, but from a user's, who is familiar with the subject matter.
Then define the terms as precisely and discretely as you can.  A good definition in this form can serve as a kind of pseudocode.
Since you have not identified even the domain of your problem, I'll choose a random example.  In a civilian personnel system, you might have terms like:

billet: a term of service (from start date to end date) at a particular grade and step
employee: a series of billets associated with a particular SSN
grade and step: row and column in the federal general schedule

And so on.  This isn't to identify functional units, as it sounds like you are trying to do, but it's a good preparatory step before doing so, so that you can express your functional steps in well-defined terms.
Comment: Not really what I was looking for, but still a very good advice.
Answer: It's useful to approach problem decomposition both top-down and bottom-up.
If you're having trouble splitting a big problem into two or more smaller problems, try to think of the smallest possible problems that will need to be solved.  Once those are handled, you may start to see ways to combine them into larger problems as you approach your original large problem.
Answer: Your key goals are:

High cohesion: Code (methods, fields, classes) within one piece/module/partition should interact intensively; it should make sense for these elements to know about each other. If you find that some of them don't interact much with the rest, they probably belong somwhere else or should form their own partition. If you find code outside interacting intensively with the partition and knowing too much about its inner workings, it probably belongs inside. The typical example is found in OO code written in procedural style, with "dumb" data objects and "manager" code that operates on them but should really be part of the data objects.
Loose coupling: Interaction between pieces/modules/partitions should only happen through narrow, well-defined, well-documented APIs. Try to identify such APIs and see what code is needed to implement them and what code will use them.
Comment: I kind of knew this already, but I don't know much about OO so I haven't really figured these out yet.
Answer: When I find myself copying and pasting chunks of code with minimal adjustments I realize that's a "partition" and then create a class, method, function, or whatever.
Actually, the whole object oriented approach is what it's all about.  Try thinking of your application as tangible things that do stuff.  Write pseudo code describing what the things are and what they do, I find lots of "partitions" this way.
Answer: Here's a try, kind of wild guess.
People usually underestimate how long it will take them to do the work. If your project is large, then most likely you'll need several people to work on it, so you can try planning with that in mind. Now a person can be expected to hold just one area in the head, so you'll need to explain to him exactly what kind of task he's supposed to do.
So I'd say you should try to write a job description that should encompass as much as possible for one person to seriously concentrate on. Repeat, until you have broken your project into parts you wanted to. As a benefit, you're ready to assemble your team. But if you find out the parts are small, maybe you'll still be able to do it yourself.


32 vs 64 bit...or, what exactly does 'processing information' mean

Question: I am having trouble understanding the difference between a 32 bit processor and 64 bit processor. I know that a 32 bit processor can access 32 bits at a time while a 64 bit processor can access 64 bits at a time. But what exactly does it mean to access a certain number of bits at one time?
Comment: This is too vague and ambiguous
Answer: I guess the real answer is it's complicated.  Metaphor is the only thing besides dedicated study that'll give you a basic idea.  Wallyk is on the right track.
A few things drive a processor.  One is how many operations it can do per second (measured in Hertz).  While architecture prevents a simple answer, a 1Ghz single-core processor performs 1,000,000,000 operations per second.  Roughly.  While it's possible to get a more concrete answer, it wouldn't clarify this case.
A processor is also other stuff, like a memory controller (in i7), ALU and FPU, and other specialized circuitry, which is what makes even that a hard question to answer.
For your intents and purposes though, every processor has registers.  Registers are like scratch space (faster than memory) for a processor to store small amounts of data while it works on it.  These are backed up by L1 and L2 (sometimes L3) caches, that are also ridiculously fast.  Basically, 64-bit refers to the size of the scratch space (and by proxy, the pipe that connects the register to the cache, as data is loaded in and out all at once).
Bigger scratch space means more can be done without reading in new information from cache or memory.  However, just because it can be done doesn't mean it always will.  A program generally has to be compiled with 64-bit support to take advantage of the speed-up, and even then you usually won't see a difference unless you're manipulating data larger than 32 bits can store.  That's more a question for a systems programmer though.
A processor also needs to keep tabs on what's in memory (as in, what's in use and what's not.)  It does this using a special register.  The reason why a 32-bit processor can't normally address more than 4GB of RAM has to do with the size of this register.  While processor extensions such as PAE allow 32-bit operating systems on 32-bit processors to address as much as 64 Gigabytes of RAM, most OS's don't generally support it.
TL;DR, 64-bit processors give the possibility with correct programming to perform operations on larger chunks of data at once, and address more memory.  Other then that, there's not a huge difference.
EDIT:  Lest people get the wrong idea, by "operations" I'm not specifically referring to THE operations (addition, multiplication, etc.).  My bad, I was focusing on answering the question rather than giving a full introduction to microprocessor architecture.
Comment: From a programmer's perspective, that's exactly what it means.  Before more complicated things like optimizing instructions or considering whether or not data is already in cache or has to be fetched from memory, Hertz specifies how many operations are performed every second, even if that operation isn't completed.
Some operations take longer (division/multiplication/modulus are noteable, as they are built successively off of add/subtract operations).

Perhaps you'd like to enlighten me with an answer/clarification, rather than just a downvote and condemnation?  Isn't this a place for answers?
Comment: Awesome explanation. I am here because apple just launched iPhone5S with 64 bit processor, so was wondering is it that big thing.
Comment: @emcee Just curious, you say "32-bit processor can't normally address more than 4GB of RAM". What is the RAM limitation on 64-bit?
Answer: Basically it means being able to do operations on numbers of such size (adding them for example). Though there is more differences between 32bit and 64bit architectures than this.
Answer: It's not a very precise expression, but I take it to mean the length of memory addresses. For example, 32 bit means 4 GiB (232 bytes) is available to programs.
(For a lark, check out the IBM s390 architecture which is 31 bit.)
Also, it's not always the maximum amount of data that the CPU can read or operate on at a time. For example, the 64-bit AMD/Intel processors have a series of on-chip caches that can pull data from main memory in large chunks. They also have 128-bit SSE registers.
Answer: I notice you tagged memory, so I'm going with that answer:
In a 32bit processor, the processor can only use 32 bits to address memory. This means there is 2^32 unique combinations, therefore, the processor can only address 2^32 bytes. (4Gb)
In a 64bit processor, the processor can (in theory) use 64 bits to address memory, or 2^64 bytes of addressable memory. I believe that amounts to 16 Exo Bytes, which is a huge amount that is almost to the point of counting the amount of molecules in your machine. In practice though, most CPUs on the line today only let you address 42 bits of physical memory and 48 bits of virtual memory due to current day hardware constraints.
Comment: The 32-bits is not about the address bus.  There are lots of 32-bit machines with 36-bit address buses (PAE and PSE-36 on the Intel architectures, for example) out there.
Comment: Yea, but it's kinda irrelevant. I guess I should've pointed out a 32bit processor can have more or less than 32 addressable bits of memory
Answer: The Wikipedia entry for 64-bit shines some nice light on the topic
Comment: This may theoretically answer the question, but [it would be preferable](//meta.stackoverflow.com/q/8259) to include the essential parts of the answer here for future users, and provide the link for reference.
Answer: It's a measure of processing power.  Rather like a vehicle which can carry 4 passengers, or 12, for approximately the same amount of energy.
For example, 32 bits holds 4 bytes, or 4 ordinary characters, and 64 bits is 8 bytes and—for romance languages—eight characters.  Those can be manipulated at once for many kinds of operations for the corresponding architectural data width.
Yet another way of looking at it is how big an integer can an architecture directly work with.  For each of these widths, the corresponding range is
8 bits:  0 to 255 / -128 to 127
16 bits: 0 to 65,535 / -32768 to 32767
32 bits:  0 to 4,294,967,295 / -2,147,483,648 to 2,147,483,647
64 bits:  0 to 18,446,744,073,709,551,615 / -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807
Comment: That's not true at all. 32bit processors are not necessarily less powerful than 64bit.
Comment: Of course.  It's no more indicative of overall performance than a particular engine's displacement.


Semi detached house meaning

Question: Can the phrase semi detached house mean that a house is attached to other houses from both sides? Our English teacher told us that this is true, however on Wikipedia or on the Cambridge dictionary it is described as attached to a different house on only one side.
Thanks for help.
Comment: Surrounded by or attached to? Semi-detached means that it's attached to another house on one side but it might have other neighbors that don't attach to it.
Answer: In Britain, a semi-detached house always means one of a pair, usually with left/right symmetry, and not attached to others. Houses joined in a row are, oddly, called 'terraced'.
Comment: ..and the houses that are at the ends of a terrace are described as "end of terrace" rather than being "semi-detached" (despite the fact that they are only attached on one side).
Comment: In recent years there has been a design called Q type where four properties are arranged in a square block with one on each corner, so each property has two neighbours.
Comment: yeah a detached house has no neighbours attached, a semi detached could be called a semi-terrace as well, wonder why they chose semi-detached :)

Semi detached house meaning


How to add a second SFTP user with only view permissions

Question: I want to add a second SFTP user that can only view a couple of folders/files in a home folder. I already added a group sftp_users for the normal users but now I am searching for a solution to add a read only user for the same folder.
Answer: One solution might be:

Set a new group (e.g. sftp_users_ro)
Give the new sftp user the new group
set the following permissions to the folder: 775

The user and group which owner the folder will have read/write/execute permission in this folder.
The new sftp user will have read/execute permissions to the folder (without write permission)
See this Q&A for more info
What is meaning of 755 permissions in Samba Share
Comment: Thanks for your answer! Can you help me with the exact commands that I need to use?

Thanks in advance!
Answer: You can use ACLs (Access control lists). You can grant read access to an user with:
  setfacl -m u:lisa:r file

However, your sftp server needs to support, so check that out before trying. Also, there're some clients which don't support Linux ACLs (I might be wrong but I think WinSCP still doesn't support ACLs).


What Does Buying an Insurgent from Warstock Require?

Question: So I'm planning on buying an Insurgent from GTA online's war-stock, but I'm concerned because I don"t have a bunker or anything.
Will I still be able to use the insurgent even if I don't have a bunker / hanger / high end apartment / not a CEO / not a president / no lockup?
Answer: You can buy the Insurgent without owning any property, it's a Pegasus vehicle you can ask for, by calling Pegasus on the phone.
Source
Answer: There's 3 Insurgent versions, each of them will require a different place to save it:
Insurgent Covered
This will be unlocked after completing the Humane Labs Raid on PS3 and Xbox 360, you can buy it anytime on the PS4, Xbox One and PC versions.
It can be saved on your usual Garage.

Insurgent Pick-up/Armored
The unlock requisites are the same as the normal insurgent.
This is a Pegasus vehicle, so you will have to pay GTA$100 every time that you want to request and use it.

Insurgent Pick-up Custom
You will need a Mobile Operations Center to get a Pick-up Custom.
On the vehicle workshop you can convert an Pick-up into an Pick-up Custom for GTA$202.500, and after that you should be able to save it in your usual Garage.


Where do we find the number of rakats in prayers in the hadith literature?

Question: We are aware of the number of rakats that are there in each salat. How did we get these numbers ? Are they mentioned in any hadith ? Also, the number of rakats that are farz and those that are wajib.. where are all these mentioned ?
Answer: We got the number of Rakat of Salat from authentic Ahadeeth.  The number of Rak'at for both Fard and Sunah Salat (I believe that is what you mean by Wajib) were perserved in the Authentic Ahadeeth as well as the Practice of those who followed the way of the Prophet (Peace and blessings be upon him) and the order

صلوا كما رأيتموني أصلي
Pray as you have seen me pray

The Ahadeeth which are narrated, are found in different books of Hadith and not only in one, the number of Rak'at for the fard Salat are:
Fajr

صَلاَةُ الصُّبْحِ رَكْعَتَانِ
There are two rak'ahs of the dawn prayer (i.e. the prescribed
rak'ahs).

سنن أبي داود (Abi Dawood)
Zuhr, Asr, Maghrib, and Isha'

حدثنا يعقوب قال حدثنا أبي عن ابن إسحاق قال حدثني صالح بن كيسان عن عروة
بن الزبير عن عائشة زوج النبي صلى الله عليه وسلم قال قالت كان أول ما
افترض على رسول الله صلى الله عليه وسلم الصلاة ركعتان ركعتان إلا المغرب
فإنها كانت ثلاثا ثم أتم الله الظهر والعصر والعشاء الآخرة أربعا في
الحضر وأقر الصلاة على فرضها الأول في السفر
Among that which was obligated on the Prophet (صلى الله عليه وسلم) was
Salat which was two Rak'at two Rak'at  except for Maghrib which was
three, and then Allah made Zuhr Asr and Isha' four while one is not
Traveling, and made it the same as it was obligated the first time
while Traveling (meaning Two Rak'at)

مسند الإمام أحمد (Ahmed hadith 25806)
Comment: thanks.. was there a mention of which rakats are sunnat-e-muaqqida (obligatory rak'ats) and which are not in the hadith literature ?
Comment: sunnat-e-muaqqida is term used by scholars after Prophet Muhammad (PBUH) to distinguish between nafl prayers that he usually performed or encouraged, and the ones he did no (sunnat-e-ghair muaqqida). The only rakats that are obligatory are termed as "farz"
Comment: couldn't verify both references given in this answer.
Answer: The messenger PBUH said "pray like you saw me pray".
This is the best way to preserve the way praying should be done.
If the description of praying was transcribed then it would have been easy to alter it and modify it by modifying it in some books.
All the details of praying was preserved from generation to generation through practical education. It is not always a good idea to write down everything.
Answer: the correct hadith is  "pray like you saw me pray".  meaning there shouldn't be a "narration" but rather a sunnah that a generation will teach the next, just like bukhari learned how to pray from his mom probably just like you and me - not from a book -
the point of the question is to realize that we dont need the hadith to learn how to pray-
Answer: an nisa: 102:   And when you are among them and lead them in prayer, let a group of them stand [in prayer] with you and let them carry their arms. And when they have prostrated, let them be [in position] behind you and have the other group come forward which has not [yet] prayed and let them pray with you, taking precaution and carrying their arms. Those who disbelieve wish that you would neglect your weapons and your baggage so they could come down upon you in one [single] attack. But there is no blame upon you, if you are troubled by rain or are ill, for putting down your arms, but take precaution. Indeed, Allah has prepared for the disbelievers a humiliating punishment.
From the above aya it is evident that every namaz have 2 fard rakat. Allah commands us to perform full namaz when you are not in fear. Aya showing that during the war they did the half salat means one rakat by one group and another group perform one rakat. This is the strongest evidence for rakat of namaz for every salat. Question arise that how can you perform maghrib salat half when you are in the state of fear. How is two rakat is jahri and two rakat is sari. If performing half salat 2 rakat it means you do one rakat jahri and one rakat sarri but we are not doing that, we just pray two rakat jahari and skip the sarri, which is not right. May Allah guid us and show us the right path. ameen


Print only part (fraction) of a model

Question: I've made a 9H-printing model tonight, and only a little part of it failed (because a support dropped off). I want to reprint only that little part.
How can I do that in Cura? How can I tell Cura to generate a gcode file so only that little part (inside the transparent cube below) will be printed?

I've placed the model upside-down on the Cura plate to "cut off" what was well printed. I've made a simple 3D cube model in Blender and placed it so it intersect with the part I want to print (I've set the "mesh type" of that cube to "don't support overlaps" for that). I've tried using "Mesh fixes: disable Union Overlapping Volumes" and the "Merge meshes" option, but the merge aligns the cube origin and the model origin (which I don't want).
What's the proper way to do such partial printing?
Comment: Btw, i'm not sure that I've used the "replacement-parts" properly, because it's a replacement part for the printed model, not for the printer (but keyword description is lacking)
Answer: The latest version of Ultimaker Cura can do that (version 3.6).
I have built models made of different material in the same model.
How to do this is:

Select your CUBE and select the icon "Per Model Setting" in left side menu.
choice "Normal model", select the following settings: Top/bottom thickness, wall thickness and infill percentage
Very Important: all above settings must be set to 0!
Select the model you desire to print and select the icon "Per Model Setting" in left side menu
choice "Modify settings for overlap with other model" and select the following settings: Top/bottom thickness, wall thickness and infill percentage
Select the desired infill percentage and the wall top/bottom thickness for the portion you want print
slice the model

Note: If you need to print supports, then in step 2 select "Modify settings for infill of other models" (instead of "Normal Model"), and in step 6 also select "Add Support" and any other support related parameters you may need. However, Cura needs at least one "Normal Model" to slice, so to fool it you need to also another Cube as "Normal Model" with the parameters of step 4 somewhere else in your build plate (it won't really print).
Comment: As far as I can work out, this also suppresses the supports, so fails for models which need them. Or this there something I've missed?
Comment: This works perfectly even in Cura 4.8
The only I had to do was to apply step 3 also to Top layers and Bottom layers settings. Just setting the thickness didn§t work and the cube still included top/bottom layers. Setting these to 0 as well fixed it.
Comment: In Cura 4.8, the toolbar on the left doesn't have names to the icons (anymore?) - could you modify the answer and describe where to click in terms of "2nd from bottom", etc.?
Answer: The most recent versions of Cura cannot do that for you. This is a removed feature (or better said: not ported from the old application to the new application), so installing an older version of Cura may work for you.
Alternatively there are many more pieces of (free) software that can do that for you. E.g. MeshMixer or the Slic3r application can do that for you. This video shows a demonstration how to do that.
Answer: On Tinkercad, you can import your stl and add "subtraction" cubes, and merge them with the parts you don't want printed.
Answer: I don't know if this helps but
download blender 3d, install
expoert your models as stl
import as stl file
enter into edit mode with tab key
and delete everything else
export as stl (maybe would have to set the scale to 100)
Comment: Hi, welcome to the 3D Printing SE! Please edit your answer and put proper punctuation or a bullet list (preferred) in your answer with the steps involved as the current answer is probably a valid answer but not very clear. While you're at it remove the typing errors :)
Comment: Indeed, that's how I proceed for splitting the model.
Answer: What you can also try is to separate the part from the rest of the model within your CAD software. In FreeCAD for example, you can use the mesh design workbench to cut the small part away from the rest, then you slice this small piece and print it.

Print only part (fraction) of a model


How does a FC layer work in a typical CNN

Question: I am new to CNNs and NNs. I am reading this blog: CNN and I am confused about this part: What confuses me is the operation that will be performed on an input vector/matrix. Will we be using a typical ANN equation: "O = W.T * input"?. And then a sigmoid on top of it?
Answer: Yes, essentially a typical CNN consists of two parts:

The convolution and pooling layers, whose goals are to extract features from the images. These are the first layers in the network.
The final layer(s), which are usually Fully Connected NNs, whose goal is to classify those features.

The latter do have a typical equation (i.e. $f(W^T \cdot X + b)$), where $f$ is an activation function. Usually in the context of CNNs, $f$ is a ReLU, except for the activation function of the final layer, which is selected according to the nature of the problem. The most common cases are:

Sigmoid activation functions work for binary classification problems.
Softmax activation functions work practically for both binary and multi-class classification problem.
For regression problems, the final layer has no activation.

One final note I'd like to make is that before entering the first FC layer, the output of the previous layer is flattened. By this I mean that the (typically 3) dimensions of that tensor are layed out into one large dimension.
For example a tensor with a shape of $(5, 5, 32)$, when flattened would become $(5 \cdot 5 \cdot 32) = (800)$.
Answer: Basically, yes. But in order to pass input from a convolutional, or max pooling layer to a fully-connected one, you need to "flatten" the input tensor. That is, either to flatten the tensor/multi-dimensional array from the convolutional layer or to use something like Global Average Pooling that will reduce the tensor to a vector.
You can check code snippets in different frameworks, that will help you understand the process.
Also, should be noted that fully connected layers are used not only as the last layer that outputs class probabilities in a CNN, check for example VGG networks, they have 2-3 fully connected layers at the end.
And the last remark, to get class scores you usually (not always!) use Softmax, not simple sigmoid. Softmax ensures that the sum of the values in your output vector is equal to 1.


What does HTTP/1.1 302 mean exactly?

Question: Some article I read once said that it means jumping (from one URI to another), but I detected this "302" even when there was actually no jumping at all!
Comment: Pay close attention: http://example.com http://www.example.com and http://www.example.com/ are logically-distinct, and a site wishing to be accessed via a single URL may redirect from one to another in order to achieve this. Of course, 302 redirects are a poor choice for this... but you may well have seen similarly subtle variations.
Comment: There might be some good information on this [here in the wc3.org documentation](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3.3).
Answer: A 302 redirect means that the page was temporarily moved, while a 301 means that it was permanently moved.
301s are good for SEO value, while 302s aren't because 301s instruct clients to forget the value of the original URL, while the 302 keeps the value of the original and can thus potentially reduce the value by creating two, logically-distinct URLs that each produce the same content (search engines view them as distinct duplicates rather than a single resource with two names).
Answer: This question was asked a long ago, while the RFC 2616 was still hanging around. Some answers to this question are based in such document, which is no longer relevant nowadays. Quoting Mark Nottingham who, at the time of writing, co-chairs the IETF HTTP and QUIC Working Groups:

Don't use RFC2616. Delete it from your hard drives, bookmarks, and burn (or responsibly recycle) any copies that are printed out.

The old RFC 2616 has been supplanted by the following documents that, together, define the HTTP/1.1 protocol:

RFC 7230: Message Syntax and Routing
RFC 7231: Semantics and Content
RFC 7232: Conditional Requests
RFC 7233: Range Requests
RFC 7234: Caching
RFC 7235: Authentication

And, as of June 2022, a new set of RFCs obsoleted the documents listed above:

RFC 9110: HTTP Semantics
RFC 9111: HTTP Caching
RFC 9112: HTTP/1.1

So I aim to provide an answer based in the RFC 9110, which is the current reference for the HTTP semantics.
The 302 status code
A response with 302 is a common way of performing URL redirection. Along with the 302 status code, the response should include a Location header with a different URI. Such header will be parsed by the user agent and then perform the redirection:

Web browsers may change from POST to GET in the subsequent request. If this behavior is undesired, the 307 (Temporary Redirect) status code can be used instead.
This is how the 302 status code is defined in the RFC 9110:

6.4.3.  302 Found
The 302 (Found) status code indicates that the target resource
resides temporarily under a different URI.  Since the redirection
might be altered on occasion, the client ought to continue to use the
target URI for future requests.
The server SHOULD generate a Location header field in the response
containing a URI reference for the different URI.  The user agent MAY
use the Location field value for automatic redirection.  The server's
response content usually contains a short hypertext note with a
hyperlink to the different URI(s).
Note: For historical reasons, a user agent MAY change the
request method from POST to GET for the subsequent request.  If
this behavior is undesired, the 307 (Temporary Redirect) status
code can be used instead.

According to MDN web docs from Mozilla, a typical use case for [302]302] is:

The Web page is temporarily not available for reasons that have not been unforeseen. That way, search engines don't update their links.

Other status codes for redirection
The RFC 9110 defines the following status codes for redirection (some of these status codes were originally defined in other RFCs, but have all been consolidated in the RFC 9110):

301: Moved Permanently
302: Found
307: Temporary Redirect
308: Permanent Redirect

Refer to this answer for further details.
Comment: well my pain of two days is over thx to you (`Location` header was the thing that helped me). It turns out I was calling a service with `http` and they moved to `https`, all I got in response was `302`, as soon as I read `Location` header here, I saw the `http/https` difference. Thank you!
Comment: I've got the same reason on this error. My Javascript pointed to the wrong https location and so the redirection failed. Thank you for the comment.
Answer: A simple way of looking at HTTP 301 vs. 302 redirects is:
Suppose you have a bookmark to "http://sample.com/sample". You use a browser to go there.
A 302 redirect to a different URL at this point would mean that you should keep your bookmark to "http://sample.com/sample". This is because the destination URL may change in the future.
A 301 redirect to a different URL would mean that your bookmark should change to point to the new URL as it is a permanent redirect.
Answer: From RFC 2616 (the Hypertext Transfer Protocol Specification):

10.3.3 302 Found

   The requested resource resides temporarily under a different URI.
   Since the redirection might be altered on occasion, the client SHOULD
   continue to use the Request-URI for future requests.  This response
   is only cacheable if indicated by a Cache-Control or Expires header
   field.

   The temporary URI SHOULD be given by the Location field in the
   response. Unless the request method was HEAD, the entity of the
   response SHOULD contain a short hypertext note with a hyperlink to
   the new URI(s).

Source:
http://www.ietf.org/rfc/rfc2616.txt
Comment: RFC2616 is now obsolete and absolutely should not be followed any more.
Answer: From Wikipedia:

The HTTP response status code 302
  Found is the most common way of
  performing a redirection. It is an
  example of industrial practice
  contradicting the standard.
Answer: As per the http status code definitions a 302 indicates a (temporary) redirect.
"The requested resource resides temporarily under a different URI"
Answer: 302 is a response indicating change of resource location - "Found".
The url where the resource should be now located should be in the response 'Location' header.
The "jump" should be done by the requesting client (make a new request to the resource url in the response Location header field).
Answer: In the term of SEO , 301 and 302 both are good it is depend on situation,
If only one version can be returned (i.e., the other redirects to it), that's great! This behavior is beneficial because it reduces duplicate content. In the particular case of redirects to trailing slash URLs, our search results will likely show the version of the URL with the 200 response code (most often the trailing slash URL) -- regardless of whether the redirect was a 301 or 302.
Answer: HTTP code 302 is for redirection see http://en.wikipedia.org/wiki/HTTP_302.
It tells the browse reading a page to go somewhere else and load another page. Its usage is very common.
Answer: According to RFC 1945/Hypertext Transfer Protocol - HTTP / 1.0:
   302 Moved Temporarily

   The requested resource resides temporarily under a different URL.
   Since the redirection may be altered on occasion, the client should
   continue to use the Request-URI for future requests.

   The URL must be given by the Location field in the response. Unless
   it was a HEAD request, the Entity-Body of the response should
   contain a short note with a hyperlink to the new URI(s).

   If the 302 status code is received in response to a request using
   the POST method, the user agent must not automatically redirect the
   request unless it can be confirmed by the user, since this might
   change the conditions under which the request was issued.

       Note: When automatically redirecting a POST request after
       receiving a 302 status code, some existing user agents will
       erroneously change it into a GET request.

Answer:
The code 302 indicates a temporary redirection.
One of the most notable features that differentiate it from a 301 redirect is that, in the case of 302 redirects, the strength of the SEO is not transferred to a new URL.
This is because this redirection has been designed to be used when there is a need to redirect content to a page that will not be the definitive one. Thus, once the redirection is eliminated, the original page will not have lost its positioning in the Google search engine.

EXAMPLE:- Although it is not very common that we find ourselves in need of a 302 redirect, this option can be very useful in some cases. These are the most frequent cases:

When we realize that there is some inappropriate content on a page. While we solve the problem, we can redirect the user to another page that may be of interest.
In the event that an attack on our website requires the restoration
of any of the pages, this redirect can help us minimize the
incidence.

A redirect 302 is a code that tells visitors of a specific URL that the page has been moved temporarily, directing them directly to the new location.

In other words, redirect 302 is activated when Google robots or other search engines request to load a specific page. At that moment, thanks to this redirection, the server returns an automatic response indicating a new URL.
In this way errors and annoyances are avoided both to search engines
and users, guaranteeing smooth navigation.

For More details Refer this Article.
Answer: A 302 status code is HTTP response status code indicating that the requested resource has been temporarily moved to a different URI. Since the location or current redirection directive might be changed in the future, a client that receives a 302 Found response code should continue to use the original URI for future requests.
An HTTP response with this status code will additionally provide a URL in the header field Location. This is an invitation to the user agent (e.g. a web browser) to make a second, otherwise identical, request to the new URL specified in the location field. The end result is a redirection to the new URL.
Answer: For anyone who might be curious about the naming, I'm just going to add that it's probably called "Found" because the main resource(e.g., a private web page) the user intends to receive is not available at that moment(e.g., the user has not proved their identity yet), so instead the server has found a new resource that the user can receive(which is a login page in the most common use case).
Also it's "getting lost and found" in the hide-and-seek manner, meaning a lost resource under a 302 status is only lost temporarily, it is not supposed to be lost forever(unless a player has some bad intentions;)).
Answer: First lets take a scenario how 301 and 302 works

301 --> Permanently moved

Imagine there is some resource like --> http://hashcodehub.com/user , now in future we are changing the resouce name to user- info --> now the url should be  http://hashcodehub.com/user-info   --> but the user is still trying to access the same URL --> http://hashcodehub.com/user  --> here from the backend we can redirect the user to the new url and send the status code as 301 --> which is used for permanently moved.
Above I have explained how 301 Works
Lets understand how 302 will be used in real life

302 --> Temporary redirection --> here the complete url does not need to be changed but for some reason we are redirecting to resource at different locations. Here in the location header field we will give the value of the new resource url browser will again make the request to the resource url in the response location header field.

302 can be used just in case if there is something not appropriate content on our page .While we solve that issue we can redirect all our used to some temporary url and fix the issue.

It can also be used if there is some attach on the website and some pages requires restoration in that case also we can redirect the user to the different resource.

The redirect 302 serves, for example, to have several versions of a homepage in different languages.The main one can be in English; but if the visitors come from other countries then this system automatically redirects them to page in their language.
Answer: 302 : this status code occurs when a resource or page you're attempting to load has been temporarily moved to a different location -- via a 302 redirect.
Answer: I know 302 have some use cases, which I think it is quite appropriate to mean temporary redirection, compared to http -> https which is permanent.

google uses 302 to redirect their services to the versions in the language/country that corresponds to you.

cdn (e.g. unpkg.com used by npm) uses 302 to redirect the file to its current/exact version, which will change in the future.

When an e-commerce website has a seasonal promotion it wants to show during that period but back to the original page other times.

What does HTTP/1.1 302 mean exactly?


How important is Bankroll Management in Texas Hold'em Poker, and why?

Question: How important is Bankroll Management in Texas Hold'em Poker, and why?
Comment: yyyyyy, bankroll managment in poker is not connected to the position in hand, this is 2 other seperate things
Comment: possible duplicate of [How much important in Poker Texas Hold'em is "Dealer Position Offset"?](http://boardgames.stackexchange.com/questions/107/how-much-important-in-poker-texas-holdem-is-dealer-position-offset)
Answer: The bankroll is your safe haven. The bankroll is what makes you different from a gambler, betting, bet again, breaks and puts more money in the game.
The bankroll is a fundamental part of you being a poker player. Treat it with due importance.
The bankroll should be large. It's more than you think you need. It is much larger than you want it. The truth is that you need a lot.
Why you need a lot? Because of something called a variance.
You know that poker is a game of skill, but in the short term, luck plays a great importance. Even the best players end up having to go through hard times. This is part of the game and every player should be able to handle it.
The fact that your bankroll vary up and down over the course of the game is known as variance. The more aggressive style, the greater the variability. And the more you play a game of high variance (as MTT or 6-max), the greater the ups and downs will meet your bankroll.
There is no escaping the variance. Even if you are prudent and cautious, your bankroll will experience ups and downs.
When in high, it's just joy, but the low that you need a good bankroll. You need a box that allows you to resist the bad times without breaking. Because if you break, will not be able to enjoy the sound stage, which will certainly come back.
The bankroll should always be calculated in relation to buy-ins or stakes of the games you want to play.
A bankroll of $ 1000 can be big or little ... depends on the buy-in. If you're playing $ 5 SNG's (Sit and Go) tournament, this is a pretty good bankroll. Have to play $ 50 SNGs, it is little.
A bankroll of $ 2000 is big enough for you to face without fear NL cash tables 0.10 to 0.20. But the same bankroll can not stand the jolt of the NL tables 1-2.
There are methods to calculate the bankroll according to your ROI, ie its return on investment. I do not advise a beginner to use this method. To know your ROI and you need a good time and a lot of hands in poker tournaments or played (even many). Moreover, the game changes, changing tables, opponents change. Your ROI will not be the same as six months ago, it will fluctuate a lot over time.
So for those just starting out, I suggest being guided by the amount of buy-ins. It is simpler and is guaranteed.
As I said above, in relation to the bankroll, you better be cautious. Here are my recommendations:
Cash games

6-Max: 100 buy-ins

Down to level 60 with buy-ins

Full Ring: 80 buy-ins

Down to level 55 with buy-ins
Tournaments

Sit and Go: 50 buy-ins

Level down to 30 buy-ins

MTT: 100 buy-ins

Down to level 60 with buy-ins

These numbers mean the minimum number of buy-ins that you must have to a certain level and when you should go down a level.
For example, if you want to play SNG tournaments of $ 2, your bankroll should be $ 100. If your bankroll drops to $ 60 or less, switch to the $ 1 SNG.
If you want to play $ 10 SNG, the bankroll should be $ 500. The bankroll has dropped below $ 300? Change to the $ 5 SNG. No need to take into account the rake calculation.
In cash games, is the same thing with just one more detail: if you play with full stack, the value of each buy-in is the sum of 100 big blinds. If you are a shortstacker each buy-in is worth 20 big blinds.
So if you want to play 6-max 0.10-0.20, your bankroll should be $ 2000. If your bankroll drops below $ 1200, go to the games of 0.05-0.10.
If you are entering a shortstacker with 20% of the buy-in, your bankroll at 6-max from 010 to 0.20 to be $ 400. Where to stay under $ 240, get off of level.
Comment: your cash game recommendations seem to be rather conservative to me. otherwise great answer!
Comment: great explanation. The important part of bankroll management is that 'playing scared' is going to cost you money in the long run. The important thing to consider when choosing a size of your bankroll is that you should be able to go broke at a table without it hurting you.
Comment: I play with 50 buy-ins (of 100 big blinds), comfortably (cash games, 6-max).  Otherwise, great advice.
Comment: Great post. I would add that the need of bankroll depends largely on how important is the money to you. For pro/semi-pro the guidelines are pretty much along my experiences however recreational player can get by with much less.


Urethane or not rough pine walls

Question: Converting a garage into a living space using sawn pine walls for battan board look.  Want to leave the natural look but not sure what will happen to the wood. Do I have to use a water based urethane with a spray or can I leave it natural.  I have approx 500 sq ft. Any suggestions including urethane (not to amber) would be appreciated.
Comment: @dandavis Additionally, after using oil poly then apply a layer or two or water poly to avoid gunk buildup. Most useful for handrails as they get touched a lot.
Comment: water based poly is non yellowing, oil-based adds amber richness.
Answer: I'm guessing the pine is being installed on the interior of the garage? Although it can (and commonly is) used as an exterior wall. Either location Board and Battan walls are rustic and natural.
If used as interior walls they can be left unsealed. Rough Pine will eventually become less bright with age. This can be prevented by applying a sealer to protect the wood. A urethane will work, but if used on rough lumber it may not look aesthetically appealing with any sheen, but matte or flat (this is a personal call).
A water based floor sealer will be he easiest to work with. There are also deck sealers that can be applied (Flod brand gives good results as does Thompson). All will dry clear to leave wood grain viewable, but protected.
It will be easiest to apply whatever you ultimately choose before installing the B+B pine. Several coats all sides is ideal.
The same principals should be used if boards will go on exterior wall. Only you must install a moisture barrier (30 # felt paper or Tyvek) under the boars first.
Answer: You can leave them alone, or you can coat them.
If you want "the natural look" leave them alone.
Any sort of varnish on rough-sawn boards is going to look very out of place.

Urethane or not rough pine walls


Can anyone identify this plant growing in a garden in North Cornwall, England?

Question: This over 1m tall, rigid upright plant is growing in a patch of bare earth in my Cornish  garden. No sign of flower buds yet. It has elongated, fine toothed, unstalked hairless leaves in opposite pairs growing up the slightly furry unridged stem, about 3 or 4cm apart. Pairs of branches grow out at on opposite sides at the position of the stem leaves, symmetrically, all the way up to the top. Looks a bit like Great Willowherb, but isn't. Have also ruled out Caper Spurge. The plant has put out a stolon and a new plant is now growing from it. Can anyone identify it please?
Comment: Welcome! And thank you for a well-phrased, detailed question! If you want to learn more about how the site works, I recommend you take the [tour] and browse through the [help].
Comment: I'm torn (probably incorrectly) between a willowherb (of which there are umpteen species and varietes) and a buddleia. Please upload a photo of the flowers as soon as they appear. Are there other similar plants growing nearby in the wild?
Answer: The leaves look a bit like buddleia  but they are usually more silvery, slightly serrated and slightly hairy, although I imagine they vary by variety. The ability to grow very rapidly in unexpected places also fits.