How do you access your "special vehicles" in GTA V?

Question: When I buy special vehicles (military vehicles) I get the message that they have been delivered, but they are not in my garage or my hanger. I bought the military humvee (don't know the name) but when I press right on the D-pad nothing pops when I'm in the garage. I bought the tank, but it did not show up in my hanger. But when I bought the attack helicopter it showed up on my helipad. Anyone understand this madness?
Comment: Odd, when I bought the tank, it did appear in my hangar (where planes appear). After your purchase you'll get a mail that says they got your order. You can only access your new vehicle after you received that mail, did you get said mail?
Comment: Yes, I have gotten a confirmation e-mail for each one.
Answer: Go into the hangar and it will ask if you want to change stored vehicles


How to decide whether a real life problem can be dealt with by computers?

Question: I get that complexity theory will be helpful to decide whether the resources at hand can deal with a mathematical function, but when presented with a non-purely mathematical problem - like building a robot that can cook, drive or make beds - how can we know whether it's feasible?
Comment: This sounds pretty broad and I'm not sure whether it will be answerable reasonable here.  Can you narrow it down?
Comment: @D.W.: an answer could always be limited to the concrete examples that I gave: cook, drive or make beds. The point is that the section reality--formalization, is in my view not covered by complexity classes, which cover formalization--computation.
Answer: The way we decide is we try to solve it and see if we are successful; or we look to see whether someone else has solved it (e.g., in the research literature).
Usually the question doesn't really make sense, as it is not well-defined what it means to "solve" or "deal with" a problem.  It's not like in mathematics, where it is a crisp black-and-white.  Instead, one may need to measure how well computer systems can address the problem, in what contexts they do or don't suffice, what their strengths and limitations may be, and so on.
Normally, the way we assess all of this is through experiments, not mathematics: we try techniques and evaluate how well they work empirically, and see what we can learn from that.
Answer: There are already robots (i.e. automated machines) that can cook - every factory in the food processing industry uses a production line to turn raw materials into its finished products. These machines are complex and expensive and only economically viable for large scale food production.
If by "cook" you mean "prepare a healthy and nutritious meal using fresh ingredients available in my kitchen that is not the same as any other meal we have had in the previous week" then that is a much more complex scenario, and is unlikely to be automated in the near future.
Similarly, there are already test vehicles which can drive themselves in a wide variety of situations, so this problem has effectively been solved at a technical level. Cruise control and semi-automated parking are already options for some standard cars, and we are likely to see more and more automation of everyday driving over the next ten to twenty years.
"Making beds" as a daily task has (in my part of the world) largely been superseded by the use of duvets. I only have to "make my bed" when I change the sheets and duvet cover, and the effort involved in that is hardly worth automating. In situations such as hospitals and hotels where beds have to be made and re-made frequently, the solution has been to change bed and mattress design to make the task simpler.
As you say, formal complexity theory has little or nothing to say about these problems, which have technological solutions constrained by market economics rather than computing power.


How can I block specific telephone numbers on my iPhone 4?

Question: How can I block specific telephone numbers on my iPhone? I don't want to get call from specific numbers. if anyone call to me from the blocked number, he should receive a message that "this number does not exist" or "this number is busy" always.
Comment: Well I have had a few phone in the past that block any individual number even UNKNOWN numbers. It should be standard on all phones. I would be harassing Apple about it and wanting my money back. That's what happens when you get an iPhone.
Comment: With the changes on iOS 7 and age of many call blocking questions, I'm going to point most of these at one simple how can I block calls question. http://apple.stackexchange.com/questions/34157/call-blocking-for-iphone
Answer: There are applications that do this if you have jailbroken your iPhone.  Without jailbreaking however there isn't a way to block a single or specific incoming number.  I've known people that have requested their provider to block a certain number and without a very good (usually legal) reason, they won't do it.
The best thing you can do is record 30 seconds of silence in garage band and then use that as a ringtone for that specific number.  Then at least the phone won't alert you.
Comment: I have a specific, audible ringtone that I use for those numbers that I wish to ignore, but silence is a great idea. I hadn't thought of that. The only downside to either solution is that the number has to be kept in the Address Book in order for it work.
Comment: +1 This is what I do. Yes, you have to add the number to the address book, but I have a group conveniently called: BlockedTards ;)
Comment: Can you please provide a link to an app that can block a number on a jailbroken phone please? As far as I know, that can *only* be handled at the carrier level.
Answer: If you want to block a specific number where they are given a msg, "Not Available, Blocked, etc" it is free, you DONT have to have any 'reason' except that you want them blocked. Any phone co. will do it (I'm 100% sure Verizon allows FREE blocking of up to 5 lines) I simply called Verizon n said block this #, they did, it expires after 3 months automatically, but you can simply renew it.
I'de LOVE to have an app that could simple send specific numbers straight to Vm (like iBlacklist) without jail breaking my iPhone ;(
Answer: Pay $20 and port your phone number to Google Voice.  Then Google can ignore calls from specific numbers.
Comment: GVoice is only available in the US.
Comment: This does work well, but I miss more calls through google voice as it sometimes sends the caller to google voice mail before the forwarded call rings my iPhone - not a huge deal, but might be a big drawback for some that call heavily and depend on always being able to pick up calls from people that don't know the real cell number.
Answer: Why don't you record your own message and have that respond to unwanted calls. Could be fun eg :  "All calls from this number are traced by the authorities as part of an ongoing investigation."  or  "Calls from your number are subject to $100 per minute surcharge. You have 5 seconds to hang up before charges commence."
Comment: :) how to do that?
Comment: You can't have a voicemail message that responds only to certain numbers.  So the problem with this solution is that everybody who gets the voicemail will hear this.  Not sure that my mother would want to hear this :)   That said, its not a bad solution in the short term if the pest that calls is doing it often.
Answer: The only thing you can do is call your provider and ask them to block the number for you.
There may be apps available in the app store that can do this though.
Comment: no apps available


How to calculate the RZERO value in MQ135 sensor, I have already burned it for 24 hours?

Question:
I've already burned it for 24 hours and it is now giving the constant value of 932.36,pls tell me how to calculate the RZERO value.
Comment: your question is not about the Arduino ... it is about calibrating a sensor ... try to find a website that deals with chemistry
Answer: From the datasheet here --->MQ135 datasheet, It is the value of Sensing resistor at 100 PPM of Ammonia(NH3) or from the graph in Fig. 3, you can use gases that has y intercept as 1 and appropriate concentration, i.e you need atleast some known parameter to get it. The legend in the graph is also not clear (as far as getting the values from the Log - Log graph, there are tutorials in youtube).
I'm also in need of solution to this, so far this is what I read on the internet... You need a chemistry lab to do it !!!


Do Traditionalists still exist?

Question: I was wondering if the philosophy of Traditionalism (a la Rene Guenon and followers) still had followers and thinkers writing? If so, who?
Comment: Welcome! Any chance I could persuade you to give a little more context here -- perhaps tell us a little bit more about the problem you are working on, maybe expand on what you have already found out so far? Just in passing, the headline might perhaps be more constructively-posed as 'which if any are the most significant living/still-writing students of Guenon?' rather than the somewhat unclear 'do traditionalists still exist?'
Answer: It would seem they must; there is still a functioning Traditionalist publishing house, which is active on Facebook and has more than 500 "friends", so it would definitely appear that there are new publications and active readers.

Do Traditionalists still exist?


Replace a complete YouTube video with updated version, without losing views or likes

Question: I have a few very popular videos with lots of views and likes, but after 10 years they're getting outdated and need upgrading.
I know there must be a way to replace the videos without losing views or likes. Everywhere I search it says it can't be done, but I know it CAN because the evidence is there on YouTube.
Case in point:

Search YouTube for 'Take On Me' by A-ha.
The video recently became only the second 80's music video to gain over a billion views, with the video being present on YouTube since 2010.
However, in Dec 2019, Aha replaced the video with a 4K version, which also featured a completely different introduction.
NO views were lost. How did they do that?

I've been hunting high and low for an answer but not found anything yet. Any ideas anyone?
Answer: So from what I've found, you cannot replace the video without losing comments and views. This is because each video uploaded gets a unique URL. There have been other music videos that have done the same thing you described. Those channels are so large though, they might have special privileges not available to the average user.
What most people do is add an annotation to the video with a link to the new video stating that the video has been updated. Making changes to the title to inform viewers of the status of the video helps as well.
Sorry, I know that's not the answer you were looking for.
Comment: Thanks for your answer, Unfortunately YouTube removed annotations a few years back. You can only add a link at the end of the video now. I've tried it on my videos, and shortened them as well, but it doesn't look good. I think this is something YouTube really needs to address. Thanks any way.
Answer: At the moment you could add a card at the beginning of your video linking to its new version.
Answer: I just need to insert a PowerPoint slide over a few frames of the video to cover up an error.
Idea for Future YouTube Design Solution:
There must be some way for YouTube to REUSE a URL of the old video and use it again for the replaced video. Vimeo, for example, just has a REPLACE button. So Replace would just reuse the old URL and delete the old video while keeping all of the analytics.
RonB_USA


How to test Wi-Fi connection's stability?

Question: How can I test the stability of a wireless connection for an specific time period, or test the stability of the connection in a rather longer time?
Answer: The simplest solution is probably to just start a ping and check for packet loss.

Start the command prompt by pressing Win + R and typing cmd + OK
Start a ping by entering the command ping -t 220.127.116.11

(This will ping Googles DNS server until you press Ctrl + C to cancel it)

If you loose connection to the internet, you will get error messages.

To really make sure that it is the Wi-Fi adapter that is failing, it would be better to ping your default gateway. (Probably 192.168.0.1 or 192.168.1.1)
Comment: Thanks. I didn't know you could use '-t' when using ping command.
Answer:
Answer to the original question

The answer is really simple. Try another computer, laptop etc. If you want to check whether the usb adapter works fine, plug it in another device.
Now for the internal adapter try rolling back on a previous version. It doesn't necessarily mean that it is not compatible with windows 10, it might mean that the drivers crash. Try different versions and check if any of them work.
Had this issue in the past on a brand new laptop, and when I rolled back the drivers, everything worked fine.
Edit: Have you considered whether this is a Router's issue and not your adapters'? Do other devices get disconnected as well?
Update: There are lots of things that can cause this issue.

If the problem is with your PC only, check your Firewall Settings, there might be something that's blocking your access. Try windows troubleshooting. You will be surprised how many times this helps, even though some consider it does nothing.
If the problem is with your WiFi try a different channel in the router's WiFi settings.

Do you get the same issues when you use an ethernet cable? If yes then there is something wrong with your router. It might even be your ISP's issue. There are tons of things that can be wrong.
Comment: I have tried uninstalling, rolling back and reinstalling drivers. I also tried installing windows 8's drivers in compatibility mode in windows 10. I have tried almost hundreds of different advice/tricks/solution I could find on the internet. I have given up on the internal adapter.
Comment: The USB adapter works fine on my computer but the problem as I mentioned it the possible connection drops which I don't know when could happen and therefor I don't know how to test.
Comment: @Log check my edit question
Comment: Thanks for your answer, I really appreciate your time.
You are answering and referring to the initial problem with the adapter/connection but as I mentioned in the title and the question before and after the edit I just want to test the stability of the connection in the current situation as I have given up on "fixing" it because I'm considering a clean OS Install and if it does not work switching to Linux Mint.
And again thanks for your answer and your time.
Comment: @Loga, since you accepted an answer, I tried to give you a general view on what is the root of the issue. You don't need to clean install your pc for that. After your exam (good luck btw) try spending a few hours checking. As I said it could be your router, and you might spend time formatting and reinstalling for something that isn't caused by your computer or OS.
Comment: @Loga, try using an ethernet cable. If this persists, check another device. If it keeps happening, then it is definitely your router
Comment: Thanks. I would absolutely try them.
Too bad my vote for your answer does not "count". This community needs more users like you. Cheers.
And again, thank you :-)
Answer: The following batch file will do a quick test and reset for you:
@echo off
Rem Microsoft Windows 10 ping test to gateway.
Rem Run batch file from an administrative command prompt.

cls
:starting
Rem Send one ping to the gateway.  Write the results to a file.
ping 192.168.1.1 -n 1 > pingtest.txt

Rem Search for unreachable in the file.
c:\windows\system32\findstr.exe "unreachable" pingtest.txt

Rem errorlevel 0 reset the adapter if 1 then wait 10 minutes and test again
if %errorlevel%==1 goto waiting

Rem unreachable was found reset the adapter.

Rem write the date and time the reset was done.
echo Reset date: %date% time: %time% >> resettimes.txt

Rem issue netsh interface show interface to find your adapter's name to reset
Rem my adapter is "wi-fi"

netsh interface set interface "wi-fi" disable
timeout /t  5
netsh interface set interface "wi-fi" enable
:waiting
echo "It is online waiting 10 minutes"
timeout /t  600
goto starting


Question on how bounties are awarded

Question: When a question owner accepted and upvoted an answer but the bounty was not awarded manually until 7 days + grace period, will the full amount of the bounty offered to the person who answered the question, or does he need 2 votes at minimum for his answer when the bounty is expiring?
Comment: It does, actually: _"f the bounty was started by the question owner, and the question owner accepts an answer posted during the bounty period, and the bounty expires without an explicit award then we assume the bounty owner liked the answer they accepted and award it the full bounty amount at the time of bounty expiration."_
Comment: @yivi To be fair, that Help Center article is a bit ambiguous when it comes to this issue and needs to be reworded, IMO. The part you quoted should _at least_ be moved above the paragraph that talks about "a minimum score of 2" as in the Meta.SE answer that Robert has linked to above.
Comment: https://stackoverflow.com/help/bounty
Comment: @yivi I have checked the wiki but that does not answered my question
Comment: Oh, then the minimum of 2 vote condition not applies in this case. Thanks @yivi
Comment: See also https://meta.stackexchange.com/questions/16065/how-does-the-bounty-system-work
Comment: @41686d6564 Yes, when following up the 3rd paragraph after the "minimum score of 2" rule, it makes a bit ambiguous to get the idea. Better if that can be moved up as the second paragraph. Sorry If I'm saying anything wrong but this is what I have gone through.
Answer: From How does the bounty system work?:

Approximately 24 hours after the end of the bounty period (once the grace period ends), if the bounty starter has not manually awarded the bounty, the bounty may be awarded automatically.
If the author offered the bounty, and accepted an answer that was posted after the bounty was started, that answer is awarded the full bounty.

So the number of votes on the answer wouldn't matter for the system to automatically award the full bounty, as long as the answer got accepted while the bounty was active.

Question on how bounties are awarded


Automatic legal document reviewing advice

Question: I am lawyer from SK. I also like programming and Maths. Which technology should i use for this task? Automatic legal document reviewing. I have a big data set of specific contracts in slovak. Now I want to build my model. Model will tell good/bad contract + bold probable errors based on data set. I don´t know much about NLP, so I´am just asking for advice. Which tech should I study for this task? Word2Vec, keywords extraction algos etc. Thank you guys for your time.
Answer: I am not a lawyer but I assume a contract is good if it is comprehensive and covers certain aspects extensively. An "easy" solution would be the following:

You could probably train a model which could classify a contract to which area it belongs (aka topic classification). If the probability of belonging with the rest of its the peer contracts is high then it could be a good contract.

Then again I am not sure how effective this would be and what pre-processing steps should be taken and would certainly need a big amount of labelled contracts. I would encourage you to dive into NLP and check the various NLP tasks that may leverage the process with your domain expertise.
Lastly, you could ask for help from a company like Lawgeex to make the NLP (or LLP I think they call it for Law Language abbreviation) stuff for you. But then again, not sure if companies like this could fit the Slovakian market. It would be cool for them to have Language Model that could fine tune in other languages!


Non-differentiability implies non-Lipschitz continuity

Question: In a simple one-dimensional framework, it is known that the differentiability of a function (with bounded derivative) on an interval implies its Lipschitz continuity on that interval. However, non-differentiability does not implies non-Lipschitz continuity as shown by the function $f:x\to |x|$. Still, there are functions that are not differentiable at a point and this argument is used to say that this same function is not Lipschitz-continuous at that point as, for example, $f:x\to \sqrt{x}$ at $x=0$ (we say that the slope of the function at that point is "vertical"). So my question is: is there a theorem telling us that for some functions (to be characterized), their non-differentiability implies their non-Lipschitz continuity? Or is this result obvious from the definition of Lipschitz continuity?
Comment: Differentiabilty on an interval does NOT imply Lipschitz continuity on that interval, because $ f'$ may be unbounded on that interval. (Use the MVT.)... For example $f(x)=1/x$ on the interval $(0,1).$....  A sharper example is $f(0)=0$ and $f(x)=x^2\sin (1/x^2)$ when $x\ne 0, $ which is differentiable for all real $x,$  but $f'$ is unbounded on any neighborhood of $0.$
Comment: What is Lipschitz continuity ? is it Uniform continuity?
Comment: @Salahamam_Fatima. A function f  is Lipschitz iff there exists $K>0$ such that for all $x,y\in dom(f)$ we have $|f(x)-f(y)|\leq K|x-y|.$
Comment: @DanielWainfleet you are right, I have added the boundedness argument.
Answer: It is worthwhile pointing out Rademacher's theorem, which states that a Lipschitz function is differentiable almost everywhere.
Also, and much more trivially, the derivative will be bounded.
Comment: Rademacher's theorem is primarily a theorem in several variables; it holds true for single variable functions too, but then the proof is much easier, being a standard result in integration theory.
Answer: The following is a consequence of MVT :

If $f$ is differentiable and if $f'$ is bounded $\implies f$ is Lipschitz.

But, $f$ is Lipschitz $ \implies$ $f$ is differentiable does not hold and a counterexample for this you've already given.
Coming to your main question: When can we say "non-differentiability $\implies$ non-Lipschitz continuity"?
Intuitively speaking, if $f$ is not differentiable then either $f$ is not smooth(in the sense that it has some sharp peaks) or $f$ has infinite slope at some point. In the latter case $f$ cannot be Lipschitz, whereas in the former case if the slope of the function is finite at each point of the domain the it must be Lipschitz.
This isn't an answer to your question, but it helps build some intuition towards the problem.


Remote sensing data for different scales

Question: I'm looking for different satellite data concerning different scales. The first one I'm looking for is remote data for soil sealing and water bodies at a scale of 1:30,000, could be generally everywhere. The other one I'm looking for is for data with Mapping of parks in urban areas and the sub-classes: lawn, bushes, trees, tree groups, water bodies, lane (sealed) and lane (unsealed) at a scale of 1:5000.
I was checking the page of USGS but it doesnt really provide a lot of satelitte data for the scales I am looking for. Could anybody recommend some descent pages where I can get this images without have to pay too high amounts to get the info?
Comment: What is your area of Interest?
Comment: No area of interest, I'm mainly looking for a general source. But if you have sources with data that is connected to a certain area it would be greatly appreciated.
Comment: This is very much an Area Specific Issue. If you are dealing with the US, then you'll find lots of sources on USGS's Earth Explorer. Outside of the US, you'll probably have to buy this data from Commercial providers. There isn't one Global source that provides this high resolution data free of cost.
Answer: As stated above, I'd try USGS Earth Explorer for data in the US. Your scales are pretty large. Especially 1:5000, for which you could look for 'Hi-Res Orthoimagery' with Earth Explorer. USDA NAIP imagery exists for almost everywhere in the US at 1 meter resolution. Historical imagery can be found on Earth Explorer as well. You could use the National Hydrography Dataset as well, for locating waterbodies (1:24000). National Land Cover Dataset may also be a resource you're interested in.
Hi res imagery may exist from your county, depending on where you are, so you might look in to that, though they sometimes charge you and don't make it publicly available.
You aren't looking for imagery with a specific scale of 1:30,000, it's just that you are trying to find imagery that has a spatial resolution that suits your needs. Check this page from ESRI and this page from NOAA. It's about what you need to get from the imagery and at what scale.
Earth Explorer allows you to select an area of interest. Then, click the 'data sets' tab, and choose the 'aerial imagery' drop down. you'll be given lots of options. Each option has a little info icon that can tell you more about the type of imagery. Choose some that you think will work and see if they are available for your area by clicking the 'results' tab. Like I said the NAIP JPG2000 might be of interest to you, as well as high the 'high resolution orthoimagery' tab. This is my first stop for general imagery.
Comment: Thank u very much, I was checking the USGS page but couldnt really find a map that provides my scale of 1:30,000. If u could provide me with certain links of mappings for this scale u'd definetly be my bounty man ;)
Answer: Satellite imagery is generally not labelled according to potential mapping scale, due to the indirect relationship between the two concepts.
WR Tobler's rule of thumb is "divide the denominator of the map scale by 1,000 to get the detectable size in meters. The resolution is one half of this amount." For your scales, that would mean 2.5m resolution imagery for 1:5000 and 15m resolution for 1:30000.
As for freely available data, only a few countries provide such 2m resolution data, while the 15m resolution data could be pansharpend Landsat data. It is generally western countries that provide high resolution data freely to their citizens (and sometimes to everyone). USA has lots of data easily available, while the European countries have more convoluted data access schemes.
If your area of interest is not in one of the western countries that provide the high resolution data, you'll have to get it from commercial providers, such as DigitalGlobe or Airbus D&S, with prices in the range of 10 euro to 16 usd per square kilometer.


Direct Mount with top and bottom swing?

Question: I want to buy a new frame that supports Direct Mount. Now I read that Bottom Swing is preferable for hardtails. At the same time, it was also mentioned that Bottom Swing is mounted higher onto the saddle tube than Top Swing. Are there two versions of Direct Mount to accomodate these few centimeters height difference, or do the top and bottom swing "Direct Mount" front derailleurs position their "Direct Mount" screws at different heights internally, so that I don't have to worry about compatibility?
Answer: "Top swing" versus "bottom swing" is defined by the position of the derailleur cage in relation to the clamp. There are indeed two completely different versions of direct mounts: high direct mount is for bottom swing derailleurs (since the derailleur is below the clamp), and low direct mount is for top swing. The two versions are not compatible.
Bottom swing is in general preferred unless there is a compelling reason to need the more compact size of a top swing; typically this is only the case on full-suspension bikes.
This is not to be confused with "top pull" and "bottom pull", which only reflects the direction of the cable entering the derailleur - from above or below. Both top pull and bottom pull (as well as dual pull which supports either) mechanisms can be found in both types of derailleur mounts.
Comment: There are most certainly front derailleurs that are convertible between top and bottom pull (both Shimano and Sram make many different models in both direct mount and clamp mount.)
Comment: Top pull and bottom pull are not the same as top swing and bottom swing - but that's a good point. I've updated the answer to reflect this.

Direct Mount with top and bottom swing?


2006 DTS rear suspension

Question: I have a 2006 DTS and the rear suspension rides very bumpy. If I push on the rear of the car it only goes down an inch or two before stopping. What's the matter?
Answer: One of two things is going on with your DTS. Since it has air bags in the back, either one of the bags has ruptured or the air compressor has quit working. An airbag is pretty straightforward, as it's just replacement. The compressor on the other hand, may not be. It could be that the fuse/relay which runs the compressor has blown. Or the compressor itself may have given up the ghost.

2006 DTS rear suspension


rails heroku query help PGError: ERROR: operator does not exist: integer ~~ unknown

Question: Im deploying a rails 3.2.8 with ruby 1.9.3 in heroku, locally the query shows all books as results or none, and in heroku it just shows the following error.
Started GET "/books/advanced_search?utf8=%E2%9C%93&title=elinor&author=&isbn=&commit=Search" for 18.104.22.168 at 2012-08-22 15:38:03 +0000

Parameters: {"utf8"=>"✓", "title"=>"elinor", "author"=>"", "isbn"=>"", "commit"=>"Search"}
Processing by BooksController#advanced_search as HTML
Rendered books/advanced_search.html.erb within layouts/application (24.0ms)
Completed 500 Internal Server Error in 25ms

ActionView::Template::Error (PGError: ERROR:  operator does not exist: integer ~~ unknown
LINE 1: ...tle LIKE '%elinor%' and author LIKE '%%' and isbn LIKE '%%')

HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.

Im trying to find books in my mini catalog via title which is an string, author which is a text and isbn which is an integer, by any one of them or by all.
Heres my query:
@books = Book.paginate(
      page: params[:page], per_page: 10,
      :conditions => ['
                    title like ? ||
                    author like ?  ||
                    isbn like ?',
          { :title => "%#{params[:title]}%",
            :author => "%#{params[:author]}%",
            :isbn => params[:isbn].to_i
          }
      ]
  )

Heres the model:
class Book < ActiveRecord::Base
  attr_accessible :author, :isbn, :title, :description
  has_many :reviews, dependent: :destroy
  has_many :ratings, dependent: :destroy

  validates :author,      presence: true
  validates :description, presence: true
  validates :isbn,        presence: true
  validates :title,       presence: true

end

Thank you all for your help!
Answer: As it turns out the error happened because DBs do not do like queries with integers!


Synchronize custom post type tags with WordPress default post type tags

Question: I am not very experienced developer and i have to solve one issue. My client wants to synchronize Ultimate member plugin tags (custom post type tags) with WordPress default posts tags. Actually ultimate member plugin tags and default posts tags will be same and he do not want to create these again. So he wants to use same taxonomy for both of these posts types (default and custom).
So according to my view if i will be able to use ultimate member plugin tags for default posts tags then all of my problem will be solved. So in this way default posts will ignore there own tags and instead of this will use ultimate member plugin tags as a taxonomy.
I am not sure that my idea is right or not but if someone will be able to guide me about this, i will really appreciate it.
Thank you!!
Comment: I think it's better to do the reverse and apply post tags to your custom post type, because otherwise you have to mess around with the default definitions. https://wordpress.stackexchange.com/a/106211/17923
Answer: register_taxonomy_for_object_type() will do what you want as long as the taxonomy and object (post_type) are already registered elsewhere. Very useful when dealing with a plugin's CPTs you need to add a taxonomy to.
add_action( 'init', 'add_tag_tax_to_posts');

function add_tag_tax_to_posts(){

  register_taxonomy_for_object_type( 'SLUG_OF_PLUGIN_TAG_TAX_HERE', 'post' );

}

Or to do the reverse, and add the default tags (post_tag) to the CPTs:
register_taxonomy_for_object_type( 'post_tag', 'SLUG_OF_PLUGIN_CPT_HERE' );
Comment: Thank you so much for your time and help Sir. I appreciate it.


Local storage vs AngularJS $cacheFactory

Question: I have a problem of storing a lot of client-side data, and I can't decide which way is better. Now I'm using AngularJS's cacheFactory, it works fine, but all data reloads with a new session. Is it worth to use local storage instead?
Comment: I ended up going with https://github.com/gsklee/ngStorage The Angular-way: No Getter 'n' Setter Bullshit!
Comment: Its worth noting that local storage is not secure
Comment: @mb21 ngStorage is dead, with outstanding crucial PR's
Comment: @Rodney it has no activity and critical issues.
Comment: Hello you can use webstorage then you can fetch data with a factory, http://www.w3schools.com/html/html5_webstorage.asp
Comment: Yes localstorage lets you store data without caring about the session. I will also recommend looking at https://parse.com/ for saving data in the cloud instead of a server.
Comment: @Blowsie: why do you say ngStorage is dead?
Answer: If your goal is to store client-side and persistent data, you can't use the $cacheFactory, which just caches the data for the current session.
One solution is to use the new local storage API. This awesome Angular module makes all the dirty job for you, and even falls back to cookies for old browsers!
Comment: @Rasalom I'm late to the party, but I looked at the source of the localstorage module and it does store objects without the need for you to json encode/decode them yourself (it does it for you). This feature may have been developed after this post, but I wanted to share for future readers.
Comment: Vote up for the local storage module mention. Saved me a lot of coding!
Comment: Please note that $cacheFactory does not cache the data for the current session, it caches the data in memory, so only as long as your angular application is alive. A page refresh, for example, kills it. @Blackhole could you update that please to avoid misleading people?
Comment: No, you should serialize your objects before to store them (and unserialize to read them), typically in JSON. But to store objects directly doesn't make a lot of sens, since all persistent storage is mandatory using files, and so linearized data.
Comment: The demo page you linked to actually doesn't work, there's an uncaught syntax error in console.
Comment: @CharlieS You can report the problem to the author of the module [on the bugtracker](https://github.com/grevory/angular-local-storage/issues). It should be repaired quickly!
Comment: Awesome, thanks. I didn't see a link to GitHub from the demo page.
Answer: An alternative solution is http://jmdobry.github.io/angular-cache/ which works well with ngResource and can also easily be configured to sync to localStorage, so requests don't need to be re-done after page refresh.
<code>$resource('my/kewl/url/:key', { key: '@key' }, {
  'get': { method: 'GET',
           cache: $angularCacheFactory('MyKewlResourceCache', {
                                          storageMode: 'localStorage' })
         }
});
</code>
Comment: I feel like this one is more powerful than the solution from the accepted answer. Thanks about the $resource don't see it in its official website
Answer: $cacheFactory seems to be clearly NOT your solution, because as Blackhole said, the cache will be cleared each time session expires. $cacheFactory is just a memcache implementation the Angular way.
angular-cache is just an helper API, basically it adds option to $cacheFactory and one of this option is to store cache into persistent storage (like localStorage).
So if you want to store data in persistent storage you can use use one of the module available like angular-local-storage or use $cookieStore but it will create cookies...
Comment: Again, $cacheFactory does not cache the data for the current session, it caches the data in memory, so only as long as your angular application is alive. A page refresh, for example, kills it. @user3305685 could you update that please to avoid misleading people?
Answer: Another angular module that does the job : https://github.com/jmdobry/angular-cache


Front Fork Or Seat Post Suspension

Question: I live in an area with brick roads. This means it's really bumpy and sometimes with small potholes that hurt when I dip into them. I'm looking to buy a new ebike but I can't afford anything expensive. Should I look for a front Fork suspension, or one with a seat post suspension? I don't know much about bikes. Is front Fork mostly for off road or does it absorb vibrations to my arms? It seems like a seat suspension would be ideal for me since it hurts my bum the most.  Thanks for any help!
Comment: Do try to go round the potholes as well - but that's hard with many small ones and traffic can make dodging them almost impossible. If you can't dodge holes, go over them with your weight on your feet. It's more secure than with the weight on your bum, and your legs make good suspension.
Comment: There's so my dips and holes it's hard to avoid. The side walks unfortunately don't continue all the time so the road is usually the only option. Weight on my feet is hard cause I have a bad left ankle that makes me have to peddle with my left heel.
Comment: Round here, riding on the sidewalk is illegal unless it's been designated for shared use, so I didn't even consider that (and shared paths are often in a worse condition than the roads anyway). Hard-edged potholes are harder on you and the bike than deeper but less vicious ones, if it's a matter of choosing. And for dodging them on roads with traffic, a handlebar-mounted mirror is helpful as it allows you to keep an eye on what's coming up behind without turning away from the road ahead. Some mirrors don't stay in position over rough roads, Zefal and Busch und Müller have been good for me.
Answer: Maybe both.
If you're worried about rough roads causing numb hands or sore wrists, front suspension is what will give the greatest benefit. For smaller, higher frequency, vibrations, the biggest tyres that will fit, run quite soft, will be more effective. Cobblestones could need both, though the brick paving in my street is fine with neither. I don't much like the short travel front suspension used on a lot of e-bikes and some hybrids, but this is where it's useful. With a motor you won't really notice the extra effort it demands compared to a rigid fork.
A suspension seat post doesn't help your arms, but it helps your backside, and back. These are easy to retrofit on most bikes - just match the seatpost diameter (perfectly) and length (roughly). I've fitted one to the back of my tandem, as the stoker can't see to anticipate small bumps or time them right if warned by the captain. Note that they're generally, even the simpler sort with a spring in a tube, adjustable for rider weight. Only the most basic have no adjustment at all - avoid those.
You note that your bum is uncomfortable. Skin discomfort (chafing) is often caused by a saddle that's too wide and soft, so it presses against you and moves. A bruise-like feeling can be caused by a saddle that's too hard, but also by one that's too soft - you sink into it and pressure builds up on tender parts rather than the sit bones. Saddle shape plays a part too. A (deeper) recess or a slot in the middle can be a big help, and some people get on better with a flatter saddle while others prefer a more curved top.
To make your neck and shoulders more comfortable on rough roads, both sorts of suspension, soft tyres (Silca's calculator is designed for efficiency but is good for comfort - but watch your minimum tyre pressure), and a fairly upright riding position all help.
Comment: Here's the tyre pressure calculator I mentioned: https://silca.cc/pages/sppc-form - note the warning at the bottom about the manufacturer's limits. It sounds, with the extra details, like you do need both, and big soft tyres
Comment: Wow this website is fantastic!  Thank you all so much for the replies!!  The detailed information from everyone is Very helpful to me!!
Answer: Before answering strictly the question, two very important criteria:

tires: large supple tires require less pressure at equal rolling resistance than narrow and rigid ones, and that can make a huge difference in comfort. Entry-level bikes often have rigid tires (only notable exception are Schwalbe Big Apple/Big Ben ranges). If you puncture protection is not a priority in your area, you can also compromise on that.
saddle: saddles are highly personal, so if you plan to use the bike on shortish rides/utility cycling, a saddle on the plush side can also make a big difference.

But that would deserve separate questions.
To answer the question now: seat post without hesitation, but not all of them. There's a common understanding that suspension needs to damp a vertical motion, but the shock that are coming from the saddle is actually a rotation around the front wheel axle: there's a vertical and an horizontal component. A good suspension seat post needs to damp an oblique motion, not a vertical one. It's then better to have a "parallelogram" design, such as the CaneCreek Thudbuster (given for reference, there are other brands that do that as well - Redshift, Suntour, XCM). Their price may seem high, but if you value comfort, it's a good investment. Very compliant carbon seat posts work also surprising well. I also noticed that such suspension also lower wrist pain, what would be logical if shocks are transmitted from the saddle through the back and arms. I recommend this article if you want to learn more about seat posts.
As you mention, front suspension are mostly useful offroad, and are not good at damping small and fast vibrations - especially the entry level ones. Also another point: good suspension need regular maintenance to keep their efficiency.
Comment: "front suspension are mostly useful offroad" - I've ridden rental hybrid bikes with front suspension that worked very respectable specifically for small vibrations. Pretty sure those were not expensive forks - coil forks with short travel and low rate, meaning they'd bottom out at any larger impact, and completely undampened or so it appeared. They would be quite useless for off-road but perfectly appropriate and useful specifically for cobbles etc.. -- What you're saying about shocks being "rotation around the front wheel axle" is confusing and seems dubious to me.
Comment: @leftaroundabout I added a link in the article that will clarify what I mean. I won't deny that with a rigid seat post, a front suspension is better than none, but my experience is that unless you are off-roading on technical stuff, I would choose the seat post over the suspension for comfort, all other things being equal. Also, the best suspended seatpost will still cost a fraction of a mid-range suspension, and requires less maintenance.
Comment: Wow this website is fantastic!  Thank you all so much for the replies!!  The detailed information from everyone is Very helpful to me!!  I'll start with a basic ebike, upgrade the seat post, then slowly when I get enough money, the others!  Thank you again!!
Answer: A suspension fork is likely not what you want here. They tend to be very well designed to deal with hard impacts of the front wheel (such as going off of a sudden drop or landing from a jump), but are poorly designed to deal with vibrations. They also tend to eat some of the power you would put into pedaling (the physics behind this are a bit complicated to explain, but the short version is that part of the energy goes into compressing the suspension a tiny bit), and require a nontrivial amount of routine maintenance.
A good suspension seat post is probably a worthwhile investment for you though, but the good ones are not cheap. 'Good' in this case generally means a parallelogram design (Redshift's Shockstop suspension seat-post is a good example of a very good design, I've ridden them before and can attest that they work excellently). Other designs generally only move parallel to the seatpost, which is decent for dealing with hard landings, but almost worthless for dealing with the type of things you're having issues with.
Aside from that, you may also want to consider:

A proper bike fit. If you're already looking at getting a new bike, spend a bit of extra money to go through a proper bike fitting. This sounds kind of stupid, but it actually can provide a huge improvement to comfort. Even just getting the saddle and handlebars in the right place for your body size and shape has a huge impact on how it feels to ride a bike.
A good saddle. Just like a proper fit, the saddle has a huge impact on how the bike rides. A lot of bikes come with either generic saddles that don't really fit anyone very well, or with oversized ones with excessive cushioning that are absolute crap for any kind of serious riding. Good saddles are not cheap, but if you can find one that works for you, it will be zero maintenance long-term and will likely significantly improve how you feel after a ride.
Better tires. Larger volume with lower pressure is generally preferable here, as well as less rigid tires when possible. Wider tires (which is how you get higher volume) also have a secondary benefit of handling better in poor (wet, muddy, icy, etc) conditions, so they may be worth investing in for other reasons as well. Better tires will almost always be less expensive than most of the other options here, though may not be as effective. Ask at your LBS and they can probably point you at some good tires to help here.
In addition to suspension seat posts, you can get suspension stems. These let the handlebars flex up and down enough to dampen vibrations, but unlike a suspension fork they don't generally require lots of maintenance and they also don't really eat too much out of your power output. Just like good suspension seat posts, these are generally not cheap though, and it may also be challenging to find one that isn't designed for a very hunched-over riding position.
A carbon-fiber seat-post and/or carbon-fiber handle bars may help significantly. Carbon-fiber parts flex and deform a more than aluminum or steel, so they actually can absorb a surprising amount of vibration before it gets to you. They're not cheap though.
Comment: It's not true at all that suspension forks are mainly for absorbing landings. (In fact, trials bikes do not have suspension despite the prevalence of massive drops >2m.) Nor do they seep much power, except when pedalling hard out of the saddle. What is true is that particularly strong air forks are maintenance-heavy (and have quite some stiction particularly when not serviced for a while), but for a budget coil fork that's not such an issue either.
Comment: Wow this website is fantastic!  Thank you all so much for the replies!!  The detailed information from everyone is Very helpful to me!! I'll look for an inexpensive bike without either and just upgrade the seatpost and then eventually the saddle from what I've read. Again thank you everyone!!
Comment: I support suspension stems, I added one to my bike which already had a reasonably expensive suspension fork, and it made a difference over the small rough stuff, like cobblestone (not sure if that is the right term, small stone combined for a pavement for example).
Answer: Probably neither.
Instead learn to stand up when expecting bumps. Your legs will comfortably take the force of the impact, and it makes you more stable on the bike as you can adjust your position to balance.
A good seat suspension will help, especially if you have long periods of riding over rough stuff and you don't want to stand for that long. But the simplest and cheapest solution is just to use your legs.
Comment: thank you for the reply!  This may sound kinda silly, but I have a bad left ankle that makes it hard for me to stand on my bike. I have to peddle my left side with my heel so I don't move my ankle too much.  I think I will go for the seat suspension. Thank you again!
Comment: @Marls IMO you should update your question to include this physiological detail since it precludes some of the obvious easy fixes like just standing up on the pedals.
Comment: I beg to disagree. On uneven ground, even just badly maintained tarmac, a combination of a seat post suspension and gel saddle *with springs* worked very well for me. The three different cushioning effects probably absorb different parts of the frequency spectrum; either one alone is not sufficient.
Comment: @Maris, ah that would change things!

Front Fork Or Seat Post Suspension


Finding median for even length array in ruby

Question: I cannot figure out why I cannot get the even length portion correct.
def median(array)
  array.sort!
  if array.length % 2 == 0                                            #if amount of array members is even
    (array[(array.length/2) + 1] + array[array.length/2]) / 2.to_f    #return average of the 2 middle array members
  else                                                                #if amount of array members is odd
    array[array.length/2.ceil]                                        #return middle number
  end
end

My attempt is for example, an array whose length is 6, and whose 3rd and 4th index value are 7 and 9.
array[6/3+1] + array [6/3]
(array[4] + array[3]) /2
9 + 7 / 2

I am receiving this error
Error!
median returns the correct median of an even-length array
expected: 5.5 got: 6.0 (compared using ==)

I have seen a shorter solution, but am most curious if I can make sense of the logic path I am trying to follow, thanks for playing along!
Solution I have seen:
def median(array)
  sorted = array.sort
  len = sorted.length
  return (sorted[(len - 1) / 2] + sorted[len / 2]) / 2.0
end

Answer: Arrays are zero-indexed. So if the length was 4, you need to be taking average of indices 1 and 2. Your current attempt would take average of indices 3 and 2 for a length of 4. So you just need to change one small thing (plus into minus):
(array[(array.length/2) - 1] + array[array.length/2]) / 2.to_f

For an even numbered Fixnum n, this is always true: ( n - 1 ) / 2 == ( n / 2 ) - 1, which means you have figured out a similar approach to the one you found. This is not too surprising, there are a limited number of ways to calculate medians efficiently.
Answer: Here is my solution to your whole problem.  you need use to -1 that's the reason "arr[(arr.length/2)-1]".  Also you can use 2.0 instead of 2.to_f.
#Write a method that finds the median of a given array of integers. If the array has an odd number of integers,
# return the middle item from the sorted array. If the array has an even number of integers,
# return the average of the middle two items from the sorted array.

def find_median(arr)
arr.sort!
  if arr.length.even?
       return (arr[arr.length/2] + arr[(arr.length/2)-1])/2.0
  else #else odd
       return arr[arr.length/2.0]
  end
end

puts find_median([2,3,4,9,7,8])


Datelist element in webform not working

Question: I was just going through webform configurations and I changed the date list element format from default to raw. After doing this Im not able to add any element of type dateform to my webform and also not able to open the element configurations also. The error i get when clicked on element tab (refer the attached image) is "The website encountered an unexpected error. Please try again later."
Answer: This is a bug. I created Issue #3029964: Datelist element in webform not working in the Webform's issue queue.  Please try the provided patch.
Comment: This issue has been fixed in the latest Webform 8.x-5.x dev release.

Datelist element in webform not working


Said al hamichya instead of birkas hamazon. What do I do?

Question: If one had 'pas habah bekisnin' thinking that he needs to make a mezonos followed by al hamichya, and after doing so discovers that he should have washed, said hamotzi and then birkas hamazon, what should be done now after he has said al hamichya?
Comment: Easiest solution - wash and eat another piece.
Comment: @DanF I think I recall reading that in SA.
Comment: @Ploni This wasn't anything I recall from SA. It's the most logical "general" halachic doubtful food-related answer that I've seen. It's almost on par with the common answer I get when I ask a rav, "What's the bracha for sushi?" (different answers from different people, on this.) Rabbis are sometimes embarrassed to just say, "I don't know" (BAD quality, IMO), so they answer, "Why don't you just wash and eat a piece of bread, then it's part of your meal?" I answer "because bread ruins my appetite for the sushi - that's why I don't do it."
Comment: IIRC, there's a story in Talmud in which one Rav made a declaration that "covered" all the points of Birkat HaMazon, preventing the others present from having a Zimun. In a related manner, some are careful not to pronounce Shem Hashem in Tzur MiShelo due to exactly this concern. Bracha Me'ayn Shalosh is intentionally constructed to mirror normal bentsching, so if the former cases are a concern, then the latter would certainly seem to fulfill your obligation to bentsch.
Comment: A quick Web search found me http://www.revach.net/halacha/tshuvos/msh210/1904 and http://www.dailyhalacha.com/m/halacha.aspx?id=847 , which have some citations.
Answer: There is much discussion about this topic by many Acharonim. Rabbi Braun discusses it here and more in detail in the Hebrew mareh mekomos on that halacha. The consensus is that one is not Yotzei and needs to bentch again as discussed in that source at length with many sources.
There is more debate about whether the obligation to repeat bentching remains Medooraisa or becomes Medarabun (meaning that one doesn't even fufill his Torah obligation with al hamichya. See there for sources.)*
The Rebbe in a letter to an individual who asked the same question states that the reason for the need to repeat bentching is because the 'ברכה מעין ג does not include ברית  ותורה. (See Rabbi Braun's discussion on this and his other reason he brings down.)

*See for example Sharei Tzion to the Mishnah Berurah Siman 168 note 71.


When atoms "move", do their electrons generate a net magnetic field relative to the motion?

Question: It seems to me that the atoms the make up all the matter on Earth, are always in motion.  The Earth rotates and it revolves around the sun. It also revolves around the Galactic center.  And, we are moving relative to the Andromeda Galaxy.  If all that movement is causing the electrons in the atoms of the world to generate weak magnetic fields, there must be some ambient, net magnetic field around us and around the Earth due to this motion.  If this could be measured, and all the know motions subtracted, would we see a residual magnetic field due to some absolute linear motion through the Universe?  Would that tell us anything about the nature of the Universe and our position in it?  Also, it's seems, this could be used as a navigation tool.
Comment: accelerating -not moving-  electrons emit EM radiation
Comment: @aK1974  I think we are both wrong ( I upticked) , he is talking of uniform  moving charges creating a magnetic field
Answer: The key thing you're missing is that all of the electrons in Earth are mixed in with a bunch of protons.  The earth as a whole would have to have an excess or deficiency of electrons for there to be an overall effect.  If you grab two clumps of earth you don't notice any attraction or repulsion, so you know at least the crust is mostly electrically neutral.
Comment: Consider adding for clarity that a moving positive charge will produce a magnetic field in the opposite direction to similarly moving negative charge.
Answer: An easy straightforward test for this idea is to use the fact that in your body, there are $7*10^{27}$, that is seven billion billion billion, atoms, give or take. They do move around inside your body, but the main point is that you personally are not magnetic because the overall magnetic field of all these atoms is zero.
You can extend that idea to moving bodies such as the moon, which moves very fast compared to a human, but still has no significant magnetic field due to its motion.
The magnetic field of the Earth is, relatively speaking, strong in that it will deflect a compass needle and contribute to the Northern / Southern lights, but that is because the iron atoms in the core of the Earth are moving inside the Earth and are lined up in the same direction, so in this case there is an overall magnetic field.
Comment: I believe that the OP original question is if neutral atoms that oscillate in a lattice produce EM waves due to the motion of the accelerated charges that are a sub-part of them, and if not, why not.
Comment: @AlbertAspect yes, and it is called black body radiation. But I think he is talking of moving charges generating magnetic fields, not em radiation


After $t$ hours, the hour hand was where the minute hand had been, and vice versa

Question:
On Saturday, Jimmy started painting his toy helicopter between 9:00 a.m. and 10:00 a.m. When he finished between 10:00 a.m. and  11:00 a.m. on the same morning, the hour hand was exactly where the minute hand had been when he started, and the minute hand was exactly where the hour hand had been where the hour hand had been when he started. Jimmy spent $t$ hours painting. Determine the value of $t$.

Let $h$ represent the initial position of the hour hand.
Let $m$ represent the initial position of the minute hand.
Note that in this solution position will be represented in "minutes". For example, if the hour hand was initially at $9$, its position would be $45$.
$$45\le h \le 50$$
$$50 \le m \le 55$$
$$\implies 0 \le (m-h) \le 10$$
Time can be represented as the number of minutes passed since 12 a.m. (for example 1 am = 60, 2 am = 120 etc.)
Then:
$$60(\frac{h}{5}) + m + t = 60 (\frac{m}{5}) + h$$
$$\implies 12 h + m + t = 12m + h$$
$$\implies t = 11 m - 11 h$$
$$\implies t = 11(m-h)$$
$$0 \le t \le 120$$
$$\implies 0 \le 11(m-h) \le 120$$
$$\implies 0 \le m -h \le \frac{120}{11}$$
That was as far as I got. Could someone point me on the right path to complete the above solution? (if possible). I am not simply looking for a solution but instead a way to complete the above solution. Any help is appreciated, thank you.
Answer: I'm not sure what you mean by "complete the above solution".  The above attempt is actually pretty far from actually finding out what $m$ and $h$ are.  However, you do get $t$ as a function of $m$ and $h$, which will be needed to compute the time elapsed.
To actually solve this problem, you have to make use of the fact that $m$ and $h$ encode the same information.  If I know the exact position of the hour hand, then I know the exact time because the minute hand's information is encoded in the position of the hour hand between the two integer hours.
At the beginning, we have
$$ \frac{h-45}{5} = \frac{m}{60} $$
Then, at the end, we have
$$ \frac{m-50}{5} = \frac{h}{60} $$
Now, it's just a matter of solving a system of two equations/unknowns: http://www.wolframalpha.com/input/?i=h-45+%3D+m%2F12,+m-50+%3D+h%2F12
Plugging in these values for $h$ and $m$ into $t = 11(m-h)$ yields approximately $t=$ 50.8 minutes, or $t = 0.846$ hours.


Base liner for stucco wall

Question: I need ideas how to cover this currently really ugly joint between my stucco wall (currently applying stucco, can see new layer) and the immediate surrounding currently done with paver stones and sand, which also needs to be redone. I was thinking something like exterior tiles, if there is such a thing, and just apply a sequence around the base of the stucco.
Answer: Here is what I will do since the shape is irregular which would mean lots of tiles cutting
Remove a quarter to half an inch of the dirt
Get a small bag of self leveling concrete
Mask with the tape the bricks to prevent concrete on them
Apply the self leveling concrete and fill the gaps

Base liner for stucco wall


Why am i getting an error: "buffsize musth be an integer" for mv shell command

Question: Why am i getting an error: "buffsize musth be an integer"
afer this line:
pid2 = subprocess.Popen(["mv"],glob.glob(os.path.basename(filename)+'[0-9]*'),folder);

It is a simply mv command with a blog shell expansion .
I want sth like mv filename[0-9]* folder
Answer: First of all, it's Python, so you don't need a semi-colon at the end of a line. Then, what you want is to supply one argument, i.e.
pid2 = subprocess.Popen(["mv"] +
                        glob.glob(os.path.basename(filename)+'[0-9]*') +
                        [folder])

Otherwise, you're specifying the result of glob.glob as the second argument (bufsize) of subprocess.Popen.
Also note that calling mv is unnecessary, Python already has the functionality to move files implemented in shutil.move:
for f in glob.glob(os.path.basename(filename)+'[0-9]*'):
    shutil.move(f, folder)

Answer: As its first argument, Popen() takes either a string, or a list of arguments. You are just passing ["mv"]; the glob.glob(...) and folder get interpreted as the second and the third arguments to subprocess.Popen(), which are bufsize and executable.
Try:
args = ["mv"] + [glob.glob(os.path.basename(filename)+'[0-9]*')] + [folder]
pid2 = subprocess.Popen(args)


Adjusted P-value from DESeq2

Question: What does the padj really mean? I believe it's a BH method, where it attempts to quantify the likelihood of a "false positive" but I am not sure. Also, what does it mean if the resulting calculations nearly all have the same padj values despite having different p-values?
Comment: It would help to see the data themselves (p-values and adjusted p-values), or at least a general idea of how many hypotheses and the part of the p-value spectrum. For high p-values FDRs ("adjusted p-values", https://en.wikipedia.org/wiki/False_discovery_rate) will be very similar as they will mostly indicate support for the null hypothesis, i.e. very high false discovery rates. I would suggest reading about DESeq2 stats (section "Multiple test correction"): https://hbctraining.github.io/DGE_workshop/lessons/05_DGE_DESeq2_analysis2.html
Answer: If we look at documentation of DESEQ2 and search "adjusted p-value", we find the section "Multiple test correction". In this section they discuss Benjamini-Hochberg ("BH") false discovery rate (FDR) correction procedures:

FDR/Benjamini-Hochberg: Benjamini and Hochberg (1995) defined the concept of FDR and created an algorithm to control the expected FDR below a specified level given a list of independent p-values. An interpretation of the BH method for controlling the FDR is implemented in DESeq2 in which we rank the genes by p-value, then multiply each ranked p-value by m/rank.

Earlier, they write:

m = total number of tests

They further add:

So what does FDR < 0.05 mean? By setting the FDR cutoff to < 0.05, we're saying that the proportion of false positives we expect amongst our differentially expressed genes is 5%. For example, if you call 500 genes as differentially expressed with an FDR cutoff of 0.05, you expect 25 of them to be false positives.

I would suggest reading Benjamini and Hochberg (1995) to learn more details if desired.

Adjusted P-value from DESeq2


Ignition wire for my 1964 Ford Thunderbird

Question: I have a 1964 Ford Thunderbird on my car stereo I only have one power wire I assume it does to the ignition can I run my new car stereo on just the ignition power or will I need to run a new wire from the battery
Answer: New car stereos usually have two power supplies -

The switched supply for the main sound functions etc
A permanent supply for the memory functions.

If your existing single supply is switched, then you will need to add another fused permanent supply for the memory.  You can take this direct from the battery or from the fuse box.
Answer: Presuming back in '64, car radios used mechanical memory; manually dial or tune into a station then push one of several numbered buttons to memorize the dialed position. Tune into other stations and push other buttons to memorize several stations instead having to repeatedly tune into a favorite station(s). 100% electronic radios use two power wires, one is switched power for the radio and wired into the ignition switch and the other is live all the time and used to keep stored radio presets in electronic memory alive. This is the second wire needed directly from either the battery or on any hot side of a fuse. Since radio memory uses very little power, a small gauge wire is more than sufficient for keep alive memory.


Ceiling fan wiring problem

Question: I took down my ceiling fan and there are 4 black wires together 3 white wires together and 1 white wire by itself. I want to connect and chandelier there to work by switch. The fan that was up before the fan always had power and the light worked by wall switch
Comment: Did you take a picture before you took the wires apart? Do you remember how it was connected?
Comment: are you talking about the little wires inside the fan, or the wires running through the ceiling?
Comment: This sounds like a switch loop.  Can you get us a photo or description of the inside of the switch box?
Answer: [Edit: I've installed two ceiling fans since writing this answer so I want to amend it.]
Your old ceiling fan will have the light socket circuit and the fan motor circuit separated so that, if one wishes, the two circuits can be separately operated by two wall switches. Modern fans will have a blue wire for one circuit and the other circuit will have a black wire, and both will have a white wire.
Your old ceiling fan must have black wires for both circuits. By wiring both of them with the black wire of the power source that is presumably is switched by the wall switch, both circuits are controlled by one wall switch. This is the normal way to wire a ceiling fan I believe.
So all you have to do is - after turning of electrical service to the room via the breaker box or just to the whole house to be safe - remove the ceiling fan and you'll be left with a hole in the ceiling and the power source wires. Connect the new chandelier to the power source wires - black to black and white to white - and ground the chandelier to the ground wire if there is one. Done. Very very easy. The switch will work the new light just fine assuming that it's not a "switch loop" and that the "1 white wire by itself" is one of the old ceiling fan wires or an old wire not part of the new electrical service.
[The original answer is bellow:]

In general, black wires connect with other black wires and white wires connect with other white wires. I'm not an electrician and I'm sure there are exceptions, but this is the general rule of thumb. Black is the "hot" wire and white is known as "neutral".
If the switch operating the light worked just fine before removing the light/fan, then it should work for your new chandelier light too.
You need to investigate as much as possible to try and find out what the loose white wire is and if it's connected to anything on the other end.
Was the "white wire by itself" connected to the ceiling fan/light, or was it loose in the junction box? It's possible that the ceiling fan and light used the white wire. Is it an old house? It could be old wire that has been superseded by new wiring by a previous homeowner and it's not needed now.
What I would do is I would try to identify what wires connect to what throughout the room. You can do this with a $3 test lamp that checks connectivity to outlets and such (turn power off if you haven't already!!).
If there's still confusion, I would do some trial and error. Connect the 4 black wires and 3 white wires to a lamp socket, and turn the power back on. Can the switch turn the test lamp on and off? If not then try adding the lone white wire to the circuit. Continue like this until it works.
This is what electrical work is all about! Problem solving, plus the willingness to work with electricity and a penchant for safety. If you're not comfortable with any of this then please hire a professional. Hope this helps! :)
Comment: Isn't white neutral and not necessarily ground per NEC code? Hopefully the OP has 3 separate wires: hot, neutral and a ground

Ceiling fan wiring problem


How to operate Android from PC

Question: Is there any way to completely use my android phone from my PC ? I got a damaged display and touch will not work for some parts of my phone. the phone is Sony Xperia J. My phone currently have a default lock screen (sliding from left to right) as that part of touch is not working, I cannot access my phone. Please help. Android Version is 4.2.
Comment: You might wish to check our [broken-screen tag-wiki](https://android.stackexchange.com/tags/broken-screen/info), which has quite a few useful hints for that situation. A detail needed in this context: Is USB debugging enabled on the device?
Answer: The following reply needs USB Debugging option to be activated on the target device.
You can easily operate your device with Vysor, it's an Extension for Goolge Chrome.

Refer to the link below for further details : How to fully control your android device from any computer
Comment: actually, I can't unlock my phone...
Comment: without device permission u can't operate any application in android.i think you can change your  display first that in under 1k that is better way for this problem .. other wise try some flashing method that is not sure for your device
Answer: You can install snapPEA on your PC, and also make sure USB Device drivers are working fine.
Using snapPea you can manage the apps, music, photos, and SMS messages on your Android phone from your PC. Its free for windows.

How to operate Android from PC


How to remove Taboola adware?

Question: I have factory-reset my mobile, and had already scanned with antivirus for adware, which it found but it couldn't remove. What should I do?
Comment: If a factory-reset wasn't able to cure it, it sits in the system. The only *trustable* way then is to flash a clean ROM, sorry.
Comment: While it's not really the same adware, consider [this question about wonderlandsads](http://android.stackexchange.com/questions/128957/removal-of-the-wonderlandads-com-pop-up-virus) that has same SpyHunter reference when searching for this adware.
Answer: The only method that is left if it the adware truly resides in your phone memory is to flash your phone with its original ROM.
You can also try full resetting it after removing your memory card, sometimes adware comes from the files which were saved on memory card.
Try out a full wipe, don't worry, you can get out of this problem.

How to remove Taboola adware?


Control relay from 2 circuits

Question: I have a relay that is controlling 220VAC input to a PSU. That PSU is controlling the relay coil at 5VDC so that when the PSU powers off the input is cut as well. Problem is how do I start it in the first place. I can wire up a small 4.5V battery with a button on the relay coil that when I press will allow power to the PSU and then the PSU will power the relay and everything will continue working as planned. I'm worried about combining 2 circuits like that, what I can do is I can put diodes on both the 5V from the PSU and the little battery circuit to not allow current from the other circuit to flow through but I'm wondering would it be a problem if I didn't? I'm not quite sure what will happen but I don't want to find out the hard way.
Answer:

simulate this circuit – Schematic created using CircuitLab
Figure 1. A latching mains power-on circuit.
The circuit of Figure 1 might do the trick.

A push to make switch energises the PSU.
A contact of the relay latches the power on.
A push to break switch unlatches the circuit to power down. Note that this may have to be held for several seconds if the power supply is slow to shut down - particularly when lightly loaded.

Control relay from 2 circuits


I need help with Path Constraint & Rigging

Question: Blender newbie here, started using Blender 2 days ago for a summer project of mine but I ran into an issue here. I've done rigging & animating for my model and when I play the animation without any path constraint it looks great. The problem is, whenever I try to 'Constraint Path', my Model and its Armature ends up facing different angles and my animation is completely ruined. Could really use some help! Thanks a lot in advance! Here is my blend file that I need help with. I know there are a lot of issues and I could really use some guidance!
Answer: Make sure your Path object and your Armature have the same orientation before pressing Ctrl + P and selecting Follow Path. Your NurbsPath.001 is rotated by 90° on the Z axis.
In your blend file, select the NurbsPath.001 and press Ctrl + A and select Rotation. It will fix the rotation issue.


How to send user password during registration?

Question: How to send user password during registration.
I have to send html email when user register in the site using rules module in drupal 7 and i have to send the username and user password in that mail.
i used [account:name] and [account:password] or [user:password] but i did not get the user password on my mail.
Comment: for sending password with mail you have to write some php code in body of the email you want to send through rules in php evaluations.
Answer: This doesn't answer the question, but it has to be said.
You should not e-mail users their password.
It's highly irresponsible to do so.
There are strong reasons for Drupals default behaviour.
People tend to re-use their passwords in lots of places, and e-mails are not a secure communications channel.
If your end user re-uses the password for their VPN tunnel, and login to their e-mail over an unencrypted channel, (no https for the e-mail, and no password on the local wifi for example), then you have just broadcasted that password for the world to see. And now you've facilitated the cyber attack on their workplace. There's probably a large number of both known and unknown ways to compromise the passwords as well. NSA are practically guaranteed to get it.
Don't do it.
Yes, it's the users fault for re-using their password and not requiring HTTPS to their mail and a strong password on the wifi, but you are the developer and need to know better.
Answer: This question may already have been answered:
Send user's password in mail
Email is not fully secure. It would seem problematic to send the user's password in this manner.


Calabi-Yau threefold with an automorphism of infinite order

Question: I am looking for a (hopefully simple) example of a Calabi-Yau threefold (projective, simply connected, with trivial canonical bundle) admitting an automorphism of infinite order.
Answer: A Schoen manifold $X$ is a generic complete intersection in $\mathbb{P}^2 \times \mathbb{P}^2 \times \mathbb{P}^1 $ of two hyper-surfaces of degree (3,0,1) and (0,3,1) respectively. Alternately, you can describe this Calabi-Yau threefold as the fiber product of two generic rational elliptic surfaces $X = S\times _{\mathbb{P}^1} S'$ where $S$ and $S'$ are hyper-surfaces in $\mathbb{P}^2\times \mathbb{P}^1$ of degree (3,1) and projection to $\mathbb{P}^1$ induces the elliptic fibration. The surface $S$ has an infinite automorphism given by fiberwise addition by a non-zero section $\sigma: \mathbb{P}^1 \to S$ and this induces an infinite automorphism on $X$.
Comment: More generally, there are lots of CY3s which admit elliptic fibrations and I would expect there to be lots of examples where the Mordell-Weil group of sections is infinite.
Comment: Certainly. My problem was to get an explicit construction — I guess the one you give is reasonably explicit.
Comment: For sure there are many examples of CY3s with elliptic fibration of positive MW rank. But typically these translations only give _birational_ automorphisms, not biregular ones.
Comment: (For clarity, my comment was in reference to Jim Bryan's comment, not to his answer.)
Comment: @abx I think that with a little bit of work, one can get extremely explicit with a Schoen manifold (writing down the equations  of $X$ and then writing the automorphism in terms of the variables). I haven't done it, but I would start by writing down the group law for a pencil of cubics. I don't know what you are trying to do, but I would be surprised if having explicit equations is any more useful than the more conception description in terms of translation by a section in the Abelian fibration.
Comment: I agree. Actually, what I needed is for instance to compute the action on the Picard group, and that can be done directly from the description as a fiber product.
Answer: Another nice example is by Oguiso and Truong, "Explicit Examples of rational and Calabi-Yau threefolds with primitive automorphisms of positive entropy".
Briefly, take $E$ to be an elliptic curve with an order $3$ automorphism $\tau$ and form the abelian variety $A = E \times E \times E$.  The quotient of $A$ by the diagonal action of $\tau$ is mildly singular, but it has only isolated singularities and it's easy to check/standard that there's a crepant resolution $X$ that's a CY3.
Then it's easy to get automorphisms of infinite order: $SL(3,\mathbb Z)$ acts on $X$ in an obvious way.  In fact, [OT] show that some of these automorphisms are "primitive", meaning they don't preserve any nontrivial fibration (unlike in the elliptically fibered examples).  This is done using the theory of dynamical degrees.
(Note that this obviously gives honest automorphisms, not just birational maps; there's nothing subtle to check on singular fibers, unlike what you usually run into looking at elliptically fibered examples, as Bort alludes in the comments above.)
Comment: Very useful, thanks!


What happens to Indrani?

Question: If being an Indra is just a post, what happens to Indrani(wife of Indra), after the current Indra's post is removed? Will she continue to be the wife of the next Indra too?
Answer:
Shachi (Sanskrit: शची; also known as Indrani (queen of Indra), Aindri,
  Mahendri, Pulomaja and Poulomi

It is said that unlike other goddesses, she possess an independent character of her own. Unlike most of the goddess wives who are known by their husband's name like Rudrani, Varuni (wife of Varun), Saranya (wife of Sun), Indra is probably the only god who is known to be after his wife's name as well; hence he was often referred as Shachipati—meaning master of shakti/power, or ShachiVat (possessor of Shachi).
According to the Rig Veda, Shachi is considered a most fortunate female for Indra granted her immortality. It is said that he chose her over all of the other goddesses because of Her magnetic attractions.

As per the Rig Veda, Indrani is considered to be the most fortunate
  female as Lord Indra was granted immortality. 'Among all females
  Indrani is the most fortunate; for her husband shall not at any future
  time die of old age'. Not everyone successively attains to the throne
  of Lord Indra. It is a perpetual office as Indra is immortal. Many
  kings and queens come and go, but by the very nature of Indra's
  immortality Indrani also continues as perpetual queen.

So there are two things we can conclude:

Indra granted her immortality.
Since Indra is immortal (and so is Indrani) they are bound to be together forever, also because they are husband & wife and we marry a person not the post he/she holds.

References 1 and 2
Comment: As for *Indra being known after His wife*, even Narayana is called LakshmiKaanta Shiva is called ParvatiVallabha et cetera. In fact all Gods are known by name of their consort. Like Shakti is called ShivaPriyaa, and Shiva is called Gauriisha, Lakshmi is called HariPriyaa and Narayana as RamaaKaanta.
Comment: Yes, Besides Sachi didn't marry with post but instead she did marry with person who is sitting on post. So post stay or loose she will be wife of person since people marry with person, not with any designation.

What happens to Indrani?


How to drag and drop mp3 songs in the playlist

Question: I am developing a mac desktop based application, Created some playlists using NSOutlineView. I know how to drag and drop in NSTableView, But i don't know how to drag and drop in the playlists according the attached image(like iTunes application) ,I am dragging some songs in the playlist 2.
Comment: Vineet Singh-- Any idea how to implement...???
Answer: At the time of selecting the songs from NSTableView, store the selected songs id in a Array. After that when the mouse reach in NSOutlineView the following delegate methods will call that time user can add into the playlist table...
-(NSDragOperation)outlineView:(NSOutlineView *)outlineView validateDrop:(id<NSDraggingInfo>)info proposedItem:(id)item proposedChildIndex:(NSInteger)index{
    return YES;
}

and
- (BOOL)outlineView:(NSOutlineView *)ov acceptDrop:(id <NSDraggingInfo>)info item:(id)item childIndex:(NSInteger)childIndex{
    return YES;
}


A character who teaches how to build wealth

Question: I am looking for a character name to design a personality of a guy who teaches how to build wealth. In the real world, they are financial advisors.
Comment: Mr. Make-it? Perhaps Mr. Monet?
Answer: I'd advise against giving your character a name that is blatantly related to his character, unless you are writing a comedy. Calling the rich man "Rich Dollarman" and the policeman "Jack Law" and so forth quickly sounds very lame. Just call him "Fred Miller" or "Bob Dalton" or some such ordinary sounding name.
Comment: Thanks Jay Its for the internet based game, so i thought direct name would be better, but i agree direct interpretations are lame. "bob" sounds interesting.
Comment: To make it more interesting I think you should name the character such that it is completely perpendicular.
Answer: When you're naming characters, one of the important things you'll need to remember is keeping the names consistent within your world.  If all of your characters are from India, then having someone named Bob will be kind of strange unless he's spent a lot of time outside of India.  Venkata or something similar might work better in that case.
Also, just because a character's parents may have given them one name, doesn't mean that they actually go by that name.  Just like in real life, you can have a character go by a nickname. Venkata might go by Vinnie when he's around friends.
And one more thing - don't make two character names too similar or you'll have people confusing them.  If you have a Bob and a Rob, people will have a hard time remembering which is which.
Other than that, like Jay says in his answer, just pick something normal.
Answer: Some names that came to mind:

Paige ("Pay")
Money (as a last name - Michelle Money is a real person so it's not
an unrealistic surname)
Rick (his nickname could be "Rich")
Dollarman (as a last name - one of the other answers had this)

Possible combos: Rick ("Rich") Money, Paige Money, Rick ("Rich") Dollarman, Michael Johnson (completely random but you could give him a money-related nickname).
Some people said not to name your characters directly but what if your character's name is the reason why they decided to get into 'wealth building' in the first place?  If a guy had the last name 'Money' it could motivate him to choose a career in a field related to finance.
Or, just have their nickname be something related to money.  If your character is a financial advisor, have someone give him a nickname related to his career.  You can call him "Wealth" or "Dollarman" or "Mr. Money" without it being his actual name.


Closed form of the perpendicular line passing through a point in general form

Question: Given a line described by the linear equation in the general form $ax + by + c = 0$, how do I compute the coefficients $a_1$, $b_1$, $c_1$ of a perpendicular line described by the linear equation in the general form $a_1x + b_1y + c_1 = 0$ passing through the point $(x1, y1)$, explaining the reasoning behind and without resorting to slope form? As a curiosity in exploring its potential, I tried to ask ChatGPT but it seems extremely biased in converting the original line equation to slope form and returning coefficients for that, which is what I want to avoid to not incur in a formulation that don't handle finding perpendicular lines to equations in the form $y = c$. Unfortunately most answers I found do it similarly or just answers using the slope form. Note: In the end, I found the formulation I was looking for but I'm interested in the reasoning behind.
Comment: Is it "resorting to slope form" if I directly suggest $a_1 = b$, $b_1 = -a$, and then compute $c_1$ from $c_1 = -(a_1 x_1 + b_1x_2)$? (These $a_1, b_1, c_1$ are not unique as they can be scaled by any non-zero number)
Comment: "I tried to ask ChatGPT": it can't even do basic calculations like those with the four operations. It tries to look for a match from something in its database so it doesn't understand maths, as can be seen from when it tries to explain its reasoning.
Comment: I fixed the intersection point naming, was better $(x1,y1)$
Comment: Yes, it was an attempt to understand its potentiality. Also it will do a lot of mistakes with signs and variable names. It gave me few hints, though. My reflection was that ChatGPT is biased in the same way people prefer to tell simple solutions that they understood, instead of searching for solid solutions that won't incur in singularities.
Comment: @peterwhy yes, that's the correct formulation. I edited the question to better clarify what I meant with "resorting to slope form". Basically most human answers I found returned the coefficients of a "slope form", which is not what I was interested.
Answer: $$ax+by+c=0$$
See e.g. Wikipedia: Line (geometry) for the different kinds of equations for a line: general form (as above), linear equation and parametric equation.
You don't want to use the standard form (slope-intercept equation). Let's use the parametric form (vector equation) therefore.
$$\left(^a_0\right)x+\left(^0_b\right)y+c=0\tag{1}$$
If the direction vector of a line is $\left(^{u_1}_{u_2}\right)$, the direction vector of its normal (the normal vector) is $\left(^{-u_2}_{\ \ \ u_1}\right)$. For a line perpendicular to line (1), we have therefore:
$$\left(^{-b}_{\ \ \ 0}\right)x+\left(^0_a\right)y+d=0$$
$$-bx+ay+d=0\tag{2}$$
Because line (2) must go through point $(x_1,y_1)$:
$$-bx_1+ay_1+d=0$$
$$d=bx_1-ay_1$$
Inserting into (2):
$$-bx+ay+bx_1-ay_1=0$$
$$bx-ay-bx_1+ay_1=0$$
$$a_1=b,\ b_1=-a,\ c_1=-bx_1+ay_1$$
For mathematics questions, we should better ask Wikipedia.
Answer: This answer will use vectors. The calculations can also be done without vectors,
but the language of vectors is convenient.
Note that if a vector with coordinates $(p,q)$ is perpendicular to a vector
with coordinates $(-q,p),$ which can be confirmed by taking the inner product
(aka dot product) of the two vectors.
Without resorting to the usual slope-intercept equations for lines
(which, as you point out, do not handle lines parallel to the $y$-axis),
we know that the line described by
$$ ax + by + c = 0 $$
is perpendicular to the vector with $(x, y)$ coordinates $(a, b).$
This can be seen because if $ ax + by + c = 0 $
then $ a(x - b) + b(y + a) + c = 0 ,$
that is, by moving in the direction of the vector $(-b,a)$ we stayed on the line,
but the vector $(-b,a)$ is perpendicular to the vector $(a,b).$
So we can always convert the equation of a line in this format to the coordinates of a vector perpendicular to the line by taking the coefficients of $x$ and $y$ in the equation as the $x$ and $y$ coordinates of the vector, and conversely we can use the $x$ and $y$ coordinates of a vector as the coefficients of $x$ and $y$ in an equation of this form to obtain the equation of a line perpendicular to the vector.
To get a line perpendicular to $ ax + by + c = 0 ,$
we therefore want a line parallel to the vector $(a,b),$
which is perpendicular to the vector $(-b,a).$
So we can take the coordinates of the vector $(-b,a)$ as the
coefficients of $x$ and $y$ in the equation of a perpendicular line:
$$ -bx + ay + c_1 = 0. $$
Any value of $c_1$ in this equation will produce a line perpendicular to our original line, but we need the particular line that passes through $(x_1,y_1),$ that is, the line such that
$$ -bx_1 + ay_1 + c_1 = 0. $$
Solving for $c_1,$ we have
$$ c_1 = bx_1 - ay_1. $$
So an equation of the line through the point $(x_1,y_1)$ perpendicular to the line
$ ax + by + c = 0 $ is
$$ -bx + ay + (bx_1 - ay_1) = 0. $$
This is "an" equation since we can get an equally good equation of the same line by multiplying all coefficients (including the constant term) by a single non-zero factor.


Are countries required to reveal intelligence when they use an intelligence to arrest a government official of another country?

Question: Are countries required to reveal intelligence when they use an intelligence to arrest a government official of another country? For example, if the U.S. arrest a Russian diplomat for spying, is the U.S. required to show the intelligence that proves the diplomat was a spy, or the U.S. can do whatever it wants? Is there any precedent that's similar that shows us what might happen in such a situation?
Comment: I'm voting to close this as too broad because there are about 200 different countries and there are lots and lots of rules that many either do or don't follow, that this can't be definitively answered in response to one question.
Answer: No. What a country does within its own borders is its own matter.
Under diplomatic conventions, diplomats have immunity from arrest or prosecution. However, diplomats can be expelled without the host country having to give a reason. So diplomats are not arrested for spying, they are just told to leave, and no reason is given. For example, following the poisoning of Skripal, multiple Russian diplomats were told to leave, and many UK diplomats were told to leave Russia. No evidence needed to be presented the countries just gave the embassy a list of names and the diplomats had to pack their bags.
A country's court system may have evidential rules that would require intelligence to be revealed in open court. Some countries have such rules, some don't, but this is an internal matter.


Baud rates applied to human communication

Question: The systems that I design always include large arrays of data acqusistion channels, implemented with an assortment of communication protocols, all running at different speeds. I have always wondered: Has anyone ever thought of or estimated the approximate "speed" of human speech and its comprehention? For example, 30-baud. Is the variability of human speech even quantifiable?
Thanks for considering my "goofy" question. Perhaps there might be a more appropriate forum within which to ask my question.
Answer: I think this has indeed been considered and a keyword to find related work would be the "entropy" of natural languages. See for instance this paper https://arxiv.org/pdf/1606.06996.pdf obtained on a search engine, I am sure many more exist.
(I am also of the opinion that, unfortunately, this question is indeed not really in scope for TCS.SE.)
Comment: Thank you, a3nm, for the reference you provided and your kind pharasing concerning the appropriateness of my question within this forum. Despite it not being in scope, I appreciate you taking the time to answer. The software that I engineer acquires and processes huge amounts of data. As mentioned, I've always wondered and compared that to how we humans exchange and process auditory information. Our human systems seem so slow and complex compared to those that (ironically) we have created to process the very (large) data sets that we create. Thanks again.


Is it possible to see changes that have been made by a user on blockchain?

Question: Is it possible to see every changes that have been made to the block chain from various accounts.In other words is it possible to see what changes have been done by a user to, say its location(a field in smart contract)?
Comment: I think you need to read more about blockchain. What you describe is just... the exact purpose of this tech.
Answer: You can see all the changes that are made to the blockchain from an ethereum address. A user can have as many addresses as they want.
If you know all their Ethereum addresses (and that's a big, bold if), then yes, it is possible to monitor them and see what they're up to.
Given that there is this concept of hierarchically deterministic wallets (HD wallets) and that it's quite trivial to have one with ETH, you can be 99.99% certain that you won't be able to track a user if he doesn't want you to.


How to access properties and methods of the non stable version of OpenLayers 3?

Question: How can I use objects, properties and methods of the OpenLayers 3 development version? For example, I want to use a property of ol.geom (ol.geom.translate) of the non stable version (3.4.0).
Answer: The version of OpenLayers that your webpage uses is based on whatever path you specify in the  tag.  So, just download which ever version you want to use and save it in an appropriate location, then set your OpenLayers  tag to point to it.
EDIT
To get the very latest - on the download page, follow the link to the GitHub code repository, where you can get the raw bleeding edge code.  You will need to build it yourself but this means you can customise the build to include only what you need (another advantage of OL3 vs OL2).
Comment: Thanks por responding, but the versions that are ready for download doens´t include some features that are in experimental mode in the OL3 API, only the stable ones. For example, ol.geom.translate ins not availabe in the stable versions.
Comment: You CAN get the "bleeding-edge" releases. See my edit above (for instance, at the time of writing, a quick glance showed the latest update was only 21 hours old).  The link you need is on the download page.
Comment: Now, your edit is exactly what I need. Thank you very much, MappaGnosis.


Does reishit hagez apply to chutz Laaretz sheep brought to eretz Yisrael

Question: There is a dispute in Tractate Chullin regarding whether Reishit Hagez (the commandment to give the first shearing of the flock to a Kohen) applies in the Diaspora like it does the Land of Israel. My question is, even according to the accepted custom of it not applying, what about cases where there is a sheep born in the Diaspora but brought into the Land of Israel and first sheared there?
Comment: And what if the sheep mostly live in America but just come to Israel for Yom Tov?
Comment: @DoubleAA please keep this in mind for Purim Torah. I suspect some posek tried to count how often the sheep visited Eretz Yisrael, but would somehow always fall asleep and be unable to finish the job. So he just gave them a blanket heter.
Answer: It's not about "is the sheep Israeli" or "was the sheep born in Israel." It's about at the moment you shear the sheep, is the sheep located in Israel.
(Okay we could nitpick about if the sheep is one side of the border and the person shearing it on the other ... save it for Purim Torah, folks.)
Rambam puts this in Chapter Ten of his Laws of Bikurim and Other Gifts to the Kohen.
In 10:1 he writes:

ואינה נוהגת אלא בארץ ישראל

It only applies in the land of Israel.

Not "to Israeli sheep", or "those born in Israel" or anything like that -- when you shear them, are you in Israel?
He drives home this point in 10:8; there is no obligation if the sheep belong to a non-Jew at the moment of shearing:

הלוקח גז צאנו של נוכרי--אף על פי שגזזן, פטור מראשית הגז.  לקח הצאן
לגיזתן, חייב--אף על פי שגדלה הגיזה ברשות הגוי, ואף על פי שחוזרין הצאן לגוי אחר הגיזה:  הואיל והגוזז ישראל והגיזות שלו--חייב, שאין החיוב אלא בשעת הגיזה.

One who buys the wool shorn from a non-Jew's flock, even if the Jew himself had done the shearing, it is exempt. If he bought the sheep for their wool, though all the wool grew when belonging to a non-Jew, and even if the shorn sheep would then return to the non-Jew: once the shearer is Jewish and the sheep shorn are his, he is obligated, as the obligation is only at the moment of the shearing.

It seems quite likely, therefore, that the same definition holds vis-a-vis Israel or not.


Undetectable shrines in Zelda BotW that are not heroic missions

Question: I'm trying to find all shrines in Zelda BotW and I was wondering if there is any shrine that is both unable to be detected by the Sheika sensor and is not a Heroic quest. I'm referring, for instance, to Tho Kayu Shrine, which is not part of any quest but only appears after you kill the Moldora and light four torches.
Comment: If I recall correctly, you can still access the Tho Kayu Shrine *without* killing the Molduga that guards it. Makes it more difficult, but still possible
Comment: @Wondercricket yes, you are correct, but I think you still have to light up the torches though
Answer: Saas Ko'sah Shrine qualify I think. I'm not aware of any quest for it, although if I remember correcly, there's a character that give a hint about it in a stable.
It is located

 in Hyrule Castle, dock access

and can be found by

 lighting the big brazier on the upper platform.
Comment: But isn't this shrine also detectable by the Sheikah Slate (which is part of the OPs question)?
Comment: Well it's buried (coming out of the ground when you trigger the action put in the spoiler tag) so I guess not, but I cannot check since it would need to start a new game and goes all the way to Hyrule castle.
Comment: The one at the Hebra Great Fossil (and another one with the same principle IIRC) doesn't detect either, until you break open the gate with a large-enough snowball. It technically doesn't have a shrine quest (although the Fossils Sidequest needs-ish it), so I guess it qualifies.
Comment: @EgorHans: That's funny, my recollection is that said shrine *did* set off my Sheikah sensor all the damn time, which was annoying as it took me a completely unreasonable number of attempts to get the door open.
Comment: I did play a new since then and confirm that the shrine doesn't sett the Sheikah Slate sensor off.