Are Christian images of Jesus sacrilege?

Question: If Islam prohibits depicting prophets, and consider Jesus a prophet (although not the biggest one), are all these images of Jesus in Christian hands some kind of sacrilege?
Comment: I am not sure I get the question. Can somebody rephrase or explain the question?
Answer: The use of images, statues, or any visual representation of prophets or religious figures, including Jesus (peace be upon him), is generally discouraged or prohibited. This is because Islam emphasizes the unity and oneness of God, and views the creation of images as potentially leading to idolatry or the worship of created objects.
Therefore, while Islamic tradition recognizes and respects the figure of Jesus as a prophet and messenger of God, Muslims do not typically use images or representations of him for worship or religious purposes.
As for the question of whether Christian images of Jesus are considered sacrilege in Islam, this would depend on the context and purpose of the images. If the images are being used for worship or veneration of Jesus as a divine figure, then from an Islamic perspective, this would be considered sacrilegious or even shirk (associating partners with God).
However, if the images are being used in a non-religious context, such as for artistic or educational purposes, and are not being venerated or worshipped, then they may not be considered sacrilegious in Islam.
It's important to note that Islamic teachings emphasize respect for the beliefs and practices of others, and condemn any form of disrespect, insult, or intolerance towards individuals or communities based on their religious beliefs.
To find out more about this please follow the link:
https://www.islamiqate.com/274/how-do-muslims-refer-to-jesus-christ
Answer:
روى أحمد وأبو داود عن أبي هريرة ، عن النبي صَلَّى اللَّهُ عَلَيْهِ
  وَسَلَّمَ قال: "لَيْسَ بَيْني وَبَيْنَ عيسى نَبِيٌّ وإنَّهُ نازِلٌ
  فَإذا رَأَيْتُموهُ فاعْرِفوهُ: رَجُلٌ مَرْبوعٌ إلى الحُمْرَةِ
  والبَياضِ، يَنزِلُ بَيْنَ مُمَصَّرَتَينِ، كَأنَّ رَأسَهُ يَقْطُرُ وإنْ
  لَم يَصُبْهُ بَلَلٌ، فَيُقاتِلُ النّاسَ عَلى الإسْلامِ، فَيَدُقُّ
  الصَّليبَ، وَيَقْتُلُ الخِنْزيرَ، وَيَضَعُ الجِزْيَةَ، ويُهْلِكُ
  اللَّهُ في زَمانِهِ المِلَلَ كُلَّها إلاّ الإسْلامَ، وَيُهْلِكَ
  المَسيحَ الدَّجَّالَ ، فَيَمْكُثُ في الأرْضِ أرْبَعينَ سَنَةً ثُمَّ
  يُتَوَفَّى فَيُصَلّي عَلَيهِ المُسْلِمونَ"
Translation: Ahmad and Abu-Dawood narrated from Abi-Horaira that the
  Prophet (blessing and peace be upon him) said: "There is no prophet
  between me and Eisa and he (Eisa) will descend so when you (people)
  see it then know him: (He is) a man (who is) average to reddish and
  light (skin) color. He will descend in two yellow clothes. His head
  looks like as if it drips even when it is not wet. So he will fight
  people for Islam, so he will break crosses, kill pigs and stop the
  Jezyah (money that non-Muslims pay) and Allah in his (Eisa's) time
  will make all religions and sect perish except Islam, and He will make
  Al-Maseeh Al-Daggaal (a man who will be able to do paranormals and
  will claim he is god) perish, and he (Eisa) will stay in the earth for
  fourty years then he will die and Muslims will pray (Janaza prayer)
  upon him"

So, in this hadith Jesus is depicted as average reddish and light color. I think it is not wrong for Christians to depict Jesus Christ, but with the reference from the Ten Commandments imagery may still be prohibited.
Comment: that is hadith, not quran. and it seems, hadith contradicts about color of jesus. lets [ask the question](http://islam.stackexchange.com/questions/12106/color-of-jesus-hadith-contradicts) and see what others opine.


Z axis not moving on Prusa i3v 8"

Question: I have a Maker Farm Prusa i3v 8" i just finished building.  Initially when i first homed it, it ran fine, it even ran a test g code for movement.  The problem is now the Z axis wont move anymore.  First i checked for physical issues such as binding or nuts coming out of traps, everything's OK there.  In Pronterface i can move x & y no problem, but Z will not move, there is no noise from the steppers.  Also unusual is the the Z axis is not on the endstop, its resting on its own in a spot (the hotend is about 2mm off the bed).  I ordered some new end stop switches to try on my Z axis....any thoughts?  I'll update after switch install.
Comment: Can you check for loose connections? No noise at all from the motor usually means it's not turning on. Can you move the Z by hand, or is the motor locked?
Comment: Does it move at all? E.g. with a faulty end-stop it only moves in one direction. Please follow up the advice below on checking the end-stop trigger state (with M119 gcode as mentioned below).
Answer: If you are using Repetier the code to test the endstops is m119 I think. If your z stop is triggered, you may have to invert it in the config.h file. I had this same issue for days before i figured out the control board was reading the switch as normal close instead of normal open. Hope that helps!
Answer: Try sending a motion command manually, such as G1 X20 Z10, to eliminate any bugginess from the software interface as a reason for the Z not moving properly when commanded to. Next you could check the park location in Pronterface, perhaps the extruder head is sitting there waiting for the next command.

Z axis not moving on Prusa i3v 8"


Guest account files lost, how to recover?

Question: We were working on writing a paper while logged into an Ubuntu guest account. The paper was saved in the guest account's home directory. The computer froze, so we restarted. Ubuntu purged the files. Is it possible to recover?
Comment: FYI: When you spawn an Ubuntu guest account it creates a temporary home directory under /tmp. The default Ubuntu setting is to empty /tmp at boot time.
Comment: A 'guest' account? Were you running from a LiveCD by any chance? I ask, because during installation to a hard drive, Ubuntu should ask you for the name you want to use when you log-in.
Comment: No.  A friend of mine was working on his paper using a guest account
Comment: Hmmm, I'm  using Kubuntu 8.04 LTS, a little outdated perhaps, but there's no sign of a guest account. The latest Ubuntu may be different. Are you saying that the paper *was* saved, but was later purged by the system? I don't think *I* have any suggestions, but it will be good to describe as much of the problem as possible before someone more familiar with a later version of Ubuntu comes along.
Comment: Have you checked the `lost+found` directory?
Comment: This explains a *lot*. So you shouldn't use the guest account for anything you want to be permanent from one boot to another. I wonder if *I* have a guest account.
Comment: @andol: that's very good to know.
@thuvaraka: so this means there's no way to recover the file.

As a side note: I guess you should tell people using guests account that they should use online services when creating documents with such accounts (Google Docs or so).
Comment: By the way, shouldn't this kind of question be moved to superuser?
Answer: It is not true that there is no way to recover them. It is true that there is no particularly reliable way to recover them. And with all the time that has passed, it is quite unlikely they could be recovered now; I'm really posting this answer for others who experience similar situations in the future.
When a file is deleted, such as files purged from /tmp, the data is not immediately destroyed, and it can persist for an extended time, and it can sometimes be recovered. See https://help.ubuntu.com/community/DataRecovery for information about data recovery in the context of Ubuntu.
Continuing to use your computer after you have deleted files that you want to recover significantly decreases the chance that recovery will be possible. So please do heed this warning (from DataRecovery):

You should NOT write to the failed device, as it can worsen a hardware
  failure, and overwrite existant data in case of lost files.
Shut down the affected machine as soon as possible, and restart it
  from a LiveCD or LiveUSB. Be certain that the "live" cd does not
  automatically mount any partition or swap space.

In other words, stop using the Ubuntu system immediately, and only boot into either (1) a different system installed on the computer, or (2) better, a live CD/DVD or live USB flash drive.
(Thanks to Joseph Kern for pointing out the importance of emphasizing the need to stop using the system if there is to be good chance of recovering deleted files.)
Comment: You should add that they need to stop using the computer **right now** if they want a chance at recovery.
Answer: The first thing to do is to stop using the filesystem immediately, as every write will reduce the chance of recovering files.
I would recommend looking at using ExtUndelete as I have heard good things about it. I noticed that is it now packaged for Oneiric so booting a liveCD and installing it should not be an issue.
Answer: first of all the GUEST account of Ubuntu is NOT like Windows Guest account. Every time you use a guest account the Ubuntu creates a temporary user in the /tmp directory.ALL THE WORK DONE IN THIS ACCOUNT IS DELETED as soon AS THIS Account is LOGGED of.
You should visit this link https://help.ubuntu.com/community/DataRecovery for further details
Answer: Based on the clarification given by andol, since all the files were located in /tmp which was purged, there is no way to recover them.
Comment: Not technically true. /tmp is not formatted on reboot. Recovery is still possible through testdisk, foremost, etc. It just depends on how much time you can spend on recovery.


2000 Honda Civic Ex 1.6l Coupe - AC doesn't engage

Question: The compressor and dryer have been replaced, PAG 46 oil 5 oz added, vacuumed an hour, pressure has no change at -30 psi for another hour after stop, vacuumed 45 minutes again, added R-134A in 2 cans. The clutch didn't engage at all, using paper clip for the relay (pins 30+87) to force compressor on while adding refrigerant, which was working because I felt frozen cold on the low pressure line. However, it still doesn't work with the relay(new) and the pressure on both side is about 85 and 90 psi when using paper clip to force it engaged. Too little difference between the low and high lines. Please help for any possible reasons!
Comment: 23oz should work OK.  Are you sure the the clutch actually engages?  Relay failures are super common on this era Honda.
Comment: Honda Civic needs 23 oz of R134a, I added 2 cans with line purging, which should be the right amount.
Comment: Now using paper clip can force the clutch engaged but no cold air coming out any more. Is that too much refrigerant or not enough?
Comment: Have you checked the clutch on the compressor - - you say you force the relay closed - have you got a supply there and does it get to the compressor?
Comment: The clutch surely engages when I use paper clip to connect port 30 to 87 instead of using relay but there's no cooling air coming out. The relay works when exchanges with one for condenser fan. These two relays look same. Any more idea? Thanks much!
Comment: I thought it was a relay problem but I bought a new one with the same result.
Answer: If clutch is engaging(forced)and hi and low side pressures are similar the most likely explanation is that the TX valve has failed.
Pressure variation yesterday to today will be brought about by change in ambient temperature.
Comment: I have had the expansion valve coming with the new compressor but it seems very difficult to replace it because it's inside of the cabin. Anyway, Possibly I will have to try. By the way, based on other readings, if there's a clog the high side pressure would be too high and the low side too low; if the low side is unexpectedly too high and the high side too low (this is the case), there's a problem with the compressor. Is this correct? Thanks much for the help!
Comment: The pressures are 65 and 70 psi this morning compared to 85 and 90 yesterday. Does it mean leaking somewhere? Please help!
Comment: Is it possible to blow up the compressor by adding Freon too fast?
Comment: The low pressure line was freezing cold while adding the second half can by forcing the compressor on. After the second can added, it doesn't work any more, which is really weird.


Prerequisite skills to learn SharePoint Designer 2010

Question: If any ASP.NET novice developer (or any other programmer) needs to learn and explore SharePoint Designer, what prerequisite skills are required to learn and to be an expert in SharePoint Designer?
Answer: It very much depends on what you want to use SPD for. As it can be used for as different things as:

Workflows
Business Connectivity Services
Content types
Lists
List views
Ribbon buttons
Pages
Advanced web parts
Page Layouts
Master Pages

If you want to be an expert on all then you need to learn (in somewhat prioritised order):

SharePoint from an enduser point of view
HTML/CSS
JavaScript
XML/XSLT
SharePoint client side development
SharePoint server side development
SharePoint administration
InfoPath
Answer: Install the SharePoint
From the Central Administration create a site and play with the sites. Cover content, search, sites, communities, themes, master pages, page layouts etc.
The basic point here is, you will get a broader picture of What SharePoint and how it works. This will be a very good starting point since you're novice in ASP.NET/SharePoint
After couple of days, download SharePoint Designer 2010 and start practising most of things (as mentioned by Per) Workflows, Business Connectivity Services, Content types, Lists, List views, Ribbon buttons Pages, Advanced web parts, Page Layouts, Master Pages.


Why can one bend glass fiber?

Question: Why can one bend glass fibers without breaking it, whereas glasses one comes across in real life is usually solid?
Is there also a good high-school level explanation of this?
Comment: I think it depends a lot on how the glass is formed.   http://en.wikipedia.org/wiki/Prince_Rupert's_Drop http://www.youtube.com/watch?v=6V2eCFsDkK0
Answer: In addition to the question of bend radius - there is also an effect of surface scratches.
Most materials are very strong - they fail because a surface flaw allows a stress concentration - ie a crack to form. glass fibre has a very smooth surface because of the way it is made and can be put under high stress without cracking.
You can show this with a thick glass rod (or you could before we were banned from doing anything interesting by 'safety'). Clean the surface with acid, or heating and annealing,  so any defects are removed  you can then bend the rod like rubber. But touch the bent part with a metal ruler to create scratches and it will shatter
Comment: D'oh! I've never see this demo, and now and want to. Bad.
Comment: @dmckee: me too.  Maybe when I'm back in the classroom...
Comment: Thanks, I will try this. Nevertheless, do you have a video link for it.
Comment: @dmckee Surely there would be a way the demo could be done safely perhaps in a thick walled perspex cylinder. It might take some fairly painstaking engineering to work out how to do it repeatably, safely and in a reasonably automated way so that it would be quick to set up, though .
Comment: Neat example - will be in my LEFM lectures next year!
Answer: The critical parameter for materials under stress is the strain, defined in a general way{*} as the fraction change some length over that same length:
$$ \lambda = \frac{\Delta l}{l} $$
So take a given a fiber of diameter $d$, and bent around a radius of curvature $r$, the strain of either the inside or outside edge is:
$$ \lambda = \frac{((r \pm d) - r) \theta}{r \theta} = \pm \frac{d}{r} $$
Now you need only look up the breaking strain for the glass in question.

{*} Or fractional change in volume over volume, or displacement as a fraction of length, or... It really depends on the details of the situation you're trying to measure, but the above definition will work for tension and compression.
Answer: Having spent a great deal of time working with "normal" glass (one of my many hobbies), I can assure you that, in fact, all glasses can be bent. When cutting large sheets of glass, I always see the sheet bend before it breaks. Every now and then you have to strike it twice; the first time you bend it, it fails to break. Fiber optics differ from the usual glass partly in that it is very thin and so bends much more easily. After you've cut a few thousand pieces of glass you come to recognize differences between different compositions. Some glasses feel very smooth when they bend, others, like the stained art glass shown below, are rather ragged and difficult to bend. (And all breaks or cuts in glass begin with a bend.)
To get a more familiar metaphor, think about wood. It doesn't surprise you when a slat of wood that is 1mm in thickness is bent in a circle. Now imagine doing the same thing with a much thicker piece of wood. You can't do it with the thicker wood because it's too thick.
In addition, regular glass differs from fiber optic glass in that fiber optic glass is very pure and this makes it very strong. In the art glass community, thin glass rods is called "stringer". Let me see if I can find some photos of cold stringer being bent.

Okay, I found some clear stringer. I put it on a sheet of stained glass supported by two pennies. I took two photos, before and after pressing the stringer in the middle. You can see the bending. Straight:

Bent:

Comment: I should add that the stringer shown above is Bullseye 1.5mm clear stringer: http://www.bullseyeglass.com/products/accessory-glass/rods-stringer.html and the background glass is either an old style no longer sold or is: http://www.bullseyeglass.com/products/sheet-glass/streakies/white-deep-royal-purple-cranberry-pink-3-color-mix-single-rolled-3-mm-fusible-10x10-in.html
Comment: Hmmm. It seems likely that the 1.5mm stringer is probably Uroboros system 90 clear 1.5mm, a type that isn't sold anymore that I could find.
Answer: See the difference between optical fibre and a normal glass, comprises of two things.
First one its too thin having a dia. of 125 micron and the other thing is the coating which is used to increase the strength of fibre and make it bend resistant.But there is a also a limit upto which you can bend the fibre and crossing that limit will result in breaking of the fibre.
Answer: Anyone ever see video of a normal drinking glass being targeted by soundwaves at very slow speed? If so, then you will know already how flexible even dirty glass is. In the video, as the sound gets closer to the harmonic resonate frequency of the glass, it warps the glass ever further. Once the resonate frequency is matched, the glass breaks.
Fiber is just a whole lot thinner, also a whole lot cleaner and pure than drinking glasses are. This two combination of size and purity equals flexibility and strength, allowing the fiber to be put through all kinds of torture before reaching the failure point.
When I was a fiber optic technician/installer, the was amazed at how thin and flexible the fiber was. In outside plant, we had fiber lines in bundles, without the benefit of the shielding you see in patch cords. The fiber was basically bare, only a  color coded cladding was inside the cable, similar to the color codes of copper wires (blue orange green brown), we installed the "break out" kit, giving each fiber a sheath before having to polish the fiber ends using micron sand paper and a scope.
Either way, I put fiber optic cable in my "magic file" of things that defy logic.

Why can one bend glass fiber?


How can I hide the text under the desktop icons?

Question: I want to display the desktop icons without the text. I only have the Home and Trash icons on the desktop. Any sugestions?
Answer: Open gconf-editor, and go to apps>nautilus>preferences and change the desktop font to 0 (eg. change it from Sans 10 to Sans 0), then there's no text visible.
Comment: With this solution, technically it is still there, it is only reduced to an invisible font-size. Is there no solution where it is really removed?
Answer: As of at least 14.04 the gconf schema of apps > nautilus > preferences no longer exists. The new, recommended, method is to use dconf to change the font size to 0.
The key is located under org.gnome.nautilus.desktop and called font. You can edit it with dconf editor (in the dconf-tools or dconf-editor packages). Or by using gsettings from the CLI:
gsettings set org.gnome.nautilus.desktop font "Ubuntu 0"

To revert the changes make the key empty, either from the dconf-editor gui or with gsettings from the CLI:
gsettings set org.gnome.nautilus.desktop font ""

The default value appears to be Ubuntu 11, even though the key is blank.


Can anyone identify this flowering plant that mysteriously appeared among several 'weeds' in a pot?

Question: My photograph shows the flower, and a few leaves, of a plant that mysteriously turned up in a pot that had previously housed other plants. Originally I saw it as a weed, but decided to 'wait and see'. It eventually reached a height of approximately 18", at which time the first flower appeared, followed by the second one. No noticeable flower-perfume. Don't know whether the plant is annual or perennial. Some of the lower leaves are red -- could be pre-autumn colouration [?].
Answer: It seems to be Leycesteria formosa, a deciduous shrub with the common name pheasant berry or himalayan honeysuckle. It's not uncommon for it to pop up on its own https://www.gardenersworld.com/plants/leycesteria-formosa/


Phonegap alarm clock application

Question: I am developing an alarm clock application with jquery mobile and phonegap. When user click SET ALARM button I am adding alarm time to HTML5 localStorage and I am calling a recursive function with setTimout. In recursive function ı am comparing now and user set alarm time. It is woring great. But this scenario is valid on application runs everytime. How can ı do my application works background?  User shouldn't close my application anytime when user set alarm.
Answer: Consider using localNotification plugin.

Phonegap alarm clock application


Additive vs Linear Secret Sharing

Question: I'm a beginner in the cryptography domain. Can anyone help me understand Additive Secret Sharing and Linear Secret Sharing? Are there any sources or references to understand their difference and how they work?
Comment: Can you point to where you read about them? To me, they are two different names for the same thing.
Comment: @GeoffroyCouteau it is mentioned that to reconstruct the secret in additive secret sharing we need all the shares of the n participants however in linear secret sharing we can reconstruct the secret by combining only k shares from n participants ( k < n)
Answer: Based on your answer to my comment, additive secret sharing refers to the following scheme:

$\mathsf{Share}(x):$ on input $x \in \mathcal{G}$, sample $x_1, \cdots, x_{n-1}$ uniformly at random from $\mathcal{G}$, and set $x_n \gets x -\sum_{i=1}^{n-1} x_i$.
$\mathsf{Reconstruct}(x_1, \cdots, x_n):$ output $x \gets \sum_{i=1}^{n} x_i$.

Above, $\mathcal{G}$ is some group, and $n$ is the number of parties. This scheme is an $(n-1)$ out of $n$ secret sharing scheme (i.e. if $n-1$ parties reveal their shares, no information on $x$ is leaked, whereas $x$ can be reconstructed given all shares).
Linear secret sharing, on the other hand, refers to any secret sharing scheme which is linearly homomorphic. That is, fix any threshold secret sharing scheme $(\mathsf{Share}, \mathsf{Reconstruct})$, and let $k$ be its threshold (i.e the parameter such that, if $k$ or more parties combine their shares, they can reconstruct, but $k-1$ shares reveal no information). Then the scheme is said to be linear (over some group $\mathcal{G}$) if, given $(x_1, \cdots, x_n) \gets \mathsf{Share}(x)$ and $(y_1, \cdots, y_n) \gets \mathsf{Share}(y)$ (for any two inputs $x,y$), then $(x_1+y_1, \cdots, x_n+y_n)$ form valid shares of $x+y$, i.e. $\mathsf{Reconstruct}((x_i+y_i)_{i \in S}) = x+y$, where $S$ is any subset of $\{1, \cdots, n\}$ of size $|S| \geq t$.
From the above, it follows that the additive secret sharing scheme (over any group) is a special case of linear secret sharing with threshold $k=n$. Another common type of linear secret sharing (with an arbitrary threshold) is Shamir's construction using polynomial interpolation.

Additive vs Linear Secret Sharing


Why can not a woman have relations with her slave?

Question: I have been studying slavery in Islam, I have a question on rights of woman master with her slave, if a man can have sex with his slave why a woman cannot have with her slave?
Answer: Because Allah has described which sexual relations are permissible and which are not.

والذين هم لفروجهم حافظون إلا على أزواجهم أو ما ملكت أيمانهم فإنهم غير ملومين فمن ابتغى وراء ذلك فأولئك هم العادون
And they who guard their private parts. Except from their wives or those their right hands possess (concubines), for indeed, they will not be blamed. But whoever seeks beyond that, then those are the transgressors.
— Quran 23:5-7

This verse is (grammatically) addressed to men and allows for sexual intimacy between:

A man with his female wife. And hence a woman with her husband.

A man with his female slave. And hence a female slave with her master.

Everything else is forbidden as it falls under "whoever seeks beyond that". Hence sexual relationship between a slave man and his female owner will be forbidden.
Arguing that the permission also applies to a female owner with a male slave requires analogy, and such an analogy is invalidated by Ijma'. Analogies like this can not supersede Ijma' and especially the Sahaba knew better how to interpret and apply the Quran.

أجمع علماء المسلمين من الصحابة والتابعين، ولم يختلف في ذلك من بعدهم من الفقهاء: أن المرأة لا يحل لها أن يطأها من تملكه
The Ulema of the Muslims from the Sahaba and the Tabieen have a consensus on this, and none after them from the jurists have differed on this: That it is not permissible for a woman to have intercourse with her slave
— al-Istidhkaar - Ibn 'Abd al-Barr


MVC5 & HTML5: How to upload file from popup and return messages

Question: I trying to upload a file from popup window, validate the file on the server and send the message back to client. This message must appear in the same popup window where upload control is. ( not on the parent page)
Im using Kendo window for popup & Kendo upload control.
I'm trying to synchronously upload a file using upload control. The upload control resides in popup window. I have attached javascript "Success" event to the upload control however Success event never gets fired.
Issues:
1.  Action method is returning JSON message, however Javascript Success event never gets fired on client so I could not handle the response message. (does it only get fired for async operation?)
2.  Other option is, I can add the message in ModelState and return Upload View instead of JSON, however when view is returned, the upload view doesn't appear as popup instead it appear as a page and also URL changes.
3.  How do I configure OK button so that it won't close the popup  window.
Is asynchronous upload the only option I have here?
NOTE: I am not using asynchronous option because as Telerik reported here that IE doesn't report the progress bar and in turn selected file doesn't get uploaded to the server every time.  So I am thinking even if I disable progress bar upload will still have issue. But I couldn't find any details on this issue. If Kendo Upload gurrantees that if i disable progress bar, it will upload every file in IE 10,11 then i might consider using async option.
4. On that note how do i disable progress bar?
This is Index Page ( Parent Page)
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
 }

<button type="button" id="btnUploads">Show Window</button>

@(Html.Kendo().Window()
 .Name("uploadwindow")
 .Title("Select the file to upload")
 .Draggable()
 .Resizable()
 .Width(600)
 .Modal(true)
 .Visible(false)
 .LoadContentFrom("Upload", "FileUpload")
)

Popup Window
@using (Html.BeginForm("Upload", "FileUpload", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
    @(Html.Kendo().Upload()
        .Name("file")
        .Multiple(false)
        .Events(x => x.Success("onSuccess"))
    )
    <button type="submit">Ok</button>
}

FileUpload.js
function onSuccess(e) {
    //my custom method to show message
    ShowMessage(e.response.message);
}

MVC Controller
public class FileUploadController : Controller
{
    public ActionResult Index()
    {
        return View();
    }

    public ActionResult Upload()
    {
        return View();
    }

    [HttpPost]
    public ActionResult Upload(HttpPostedFileBase file)
    {
        return Json(new { message = "This is from server" }, "text/plain");

        //Option 2
        // if i return View here then it does not appear as popup instead it renders as page

        //ModelState.AddModelError("Some error");
        //return View();
    }
}

Answer: In onSuccess function, instead of directly showing the message as e.response.message try the following:

parser the JSON obtained as $.parseJSON(e.XMLHttpRequest.responseText) and assign it to a variable.
Call ShowMessage() with the parsed response.
function onSuccess(e) {
var msg = $.parseJSON(e.XMLHTTPRequest.responseText);
ShowMessage(msg);
}
Comment: if you read my question, it says OnSuccess event does not get fire at all with synchronous upload.
Answer: I had the same problem, it is resolved by using inline java script function for .Event of Kendo FileUpload :
@using (Html.BeginForm("Upload", "FileUpload", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
@(Html.Kendo().Upload()
    .Name("file")
    .Multiple(false)
    .Events(x => x.Success(@<text>function(e) { /*your event handler code*/ )}</text>))
)
<button type="submit">Ok</button>
}


How to access to the 'Session' of an EJB?

Question: How to get the session object of an EJB session-bean like session object in JSP(web layer)?
Because I want to add an attribute to the session and use it later in its process.
Regards
Answer: In the web layer you get the session with
<code>request.getSession()
</code>
This returns the session object tied to this request. Here you can store session specific attributes you can reuse on subsequent requests.
In the EJB layes you have completely different session objects which have nothing to do with the session above. There are Stateless Session Beans and Stateful Session Beans. Stateful session beans can also keep state over multiple requests however they are very tricky to work with and are only useful for a very limited set of use-cases. Stateless Session Beans do not keep (outside detectable) state between calls, so are useless to store attribtes you want to reuse later, unless you store them in a persistence layer or a cache.
In most cases the easiest to work is to keep the conversation state in the request session object and pass the attribute you want to reuse later from the web layer to a stateless service bean as a parameter.


Casting the spell Sickening Radiance over a building

Question: If Sickening Radiance were cast over a house and covered the entire building, how much effect would it have on the people inside if every entrance were closed? I'd say it goes through windows, but would it be reasonable for it to go through the cracks in doors?
Answer: Depends how many cracks it has

A spell's effect expands in straight lines from the point of origin. If no unblocked straight line extends from the point of origin to a location within the area of effect, that location isn't included in the spell's area. To block one of these imaginary lines, an obstruction must provide total cover.

Which Sickening Radiance modifies with:

The light spreads around corners, ...

So glass will block the effect but any cracks in windows, gaps under doors, chimneys, ventilation ducts etc. will let the light in.
Answer:
Dim, greenish light spreads within a 30-foot radius sphere centered on
  a point you choose within range.

Light comes through windows.
It seems this is magical light and somehow it's also a bit weird because it spreads around corners.
Spreading round corners is also rather light-like in that reflected light is likely to do that.
Nothing is said about cracks but they're kind of "obviously" not corners.
The way I'd interpret this is to say the effect spreads like light would do through glass and small openings like cracks.
Coming down a chimney and back out seems like it'd complicate things so I'd say no to that and a ray propagates "round" one corner unless the opening is large.
I'd also probably give someone "struck" by a narrow band of light coming underneath a door less damage.
Comment: Have you looked at the rules for how cover works with AOE spells? Windows with no gaps count as total cover and total cover blocks AOEs from entering. Doesn't matter if it is described as light or not. If you fix that flaw, I think your answer will be much better.
Comment: Are you saying that the spell would pass through a closed window (with no other gaps)?
Comment: Does light come through your window?
Comment: Yes. It's light. Magical green nasty light.
Comment: Thing is though,  I think it matters how a spell is described. It's no less valid than other parts of the rules.  I'm also pretty confident the rules are  intended to be used with loose interpretation.  Which rather invalidates looking for an absolute answer on many things.
Comment: Let us [continue this discussion in chat](https://chat.stackexchange.com/rooms/76971/discussion-between-rubiksmoose-and-andy).
Comment: *visible* light.


Nodejs: websocket routing based on URL without port proxying

Question: I am trying to do a game in html5 with serverside logic in node.js and that uses raw websockets (not Socket.IO, I need binary data). I wish to have multiple "rooms", thus multiple websocket servers, all having separate URLs. Currently, I only found a way to have each websocket server attached to a specific port, and then proxy the upgrade requests(not entirely sure how it works) to the right port based on the url.
It works on my computer. The problem is that when I try to submit it to a PaaS provider (AppFog), the code fails because they don't permit opening any ports other than the provided http port.
Here is a pretty cleared up version of my code:
<code>//start web server (basic static express server) on 8080
//    ...

//start game server and listen to port 9000
//   I use the ws module for websockets
// I plan to have a couple of these "game servers"
//    ...

//open the proxy server.

var httpProxy= require('http-proxy');

var webProxyServer = httpProxy.createServer(function (req, res, proxy){

   // I need http requests to be redirected to the "game servers"

   if(req.url.substring(0, "/room1".length) === "/room1") // if starts with "/room1"

      proxy.proxyRequest(req, res, {
         host: 'localhost',
         port: 9000
      });

   else

      proxy.proxyRequest(req, res, {
         host: 'localhost',
         port: 8080
      });

}

webProxyServer.on('upgrade', function (req, socket, head) {

   //redirecting logic goes here

   if(req.url=="/room1/"){

      webProxyServer.proxy.proxyWebSocketRequest(req, socket, head, {
         host: 'localhost',
         port: 9000
      })
   }

});

webProxyServer.listen(8000);  //the "outside port".
</code>
My question: is it somehow possible to open websocket servers without listening to any specific ports, and to manually attach sockets to them so I don't need to open any ports other than the basic http port? I know Socket.IO somehow does it. Maybe there is a way to listen to the upgrade event of a http server and pass the socket to the right websocket server?
I am pretty new to server-side stuff, so extra info here and there would be welcome.
Answer: Unfortunately, Appfog does not support websockets.
Feature Roadmap page - bottom of page:    shows websockets as something coming soon (i.e. they don't support it).


Data augmentation or weighted loss function for imbalanced classes?

Question: I have a CNN image classification problem with imbalanced classes. I could balance the dataset using data augmentation (Replication, mirror, etc.) on the minority classes. Also, imbalance could be handled using a weighted loss function that gives more importance to the minority classes. Is any of these methods preferred over the other and if so, why?
Answer: I've tried both minority (random) oversampling and class weighting to solve the problem of imbalance in the past and none proved to be better than the other (which is logical). The reason why I'd suggest class weights is that it has a much less training time than the over-sampling, as the number of examples is much fewer.
I've never tried under-sampling, as it seems counter-intuitive due to the fact that CNNs benefit greatly from a larger dataset.
To be honest, I haven't thought of augmenting just the minority classes to balance them and in my opinion, given the right choice of augmentors, it could outperform both random over-sampling and class weighting.
However, by doing this you are missing on an important thing that could boost the performance of your CNN, augmenting the majority class. By augmenting just the minority classes, you would be missing out on a large number of training images that would have been generated by augmenting the majority class ones.
If I were to guess I'd say that class weighting would provide the best results, of the scenarios discussed, given you performed data augmentation on the whole dataset.
Answer: You could try with a combination or Oversampling + Undersampling (i.e. replication and removal or certain "less useful" data points; applying SMOTE(and or any of its variants) + bagging...). You could also apply an ImageGenerator to increase your sample size while balancing the classes.
Comment: I've never seen SMOTE (or any of its variants) being performed on images. Also under-sampling seems counter-intuitive when working with CNNs.


Arduino AVR Programing

Question: In the Arduino IDE, what exactly happens when you choose the 'upload with programmer' option to program via a AVR programmer instead of the USB cable? Does it upload just your program, or does it include the bootloader too? If i previously uploaded the bootloader will it still be there, or does it get overridden? Does it set the fusebits during this process?
Comment: http://electronics.stackexchange.com/questions/3279/arduino-bootloader
Answer: These answers apply to only the general case - I haven't used the Arduino IDE.

Does it upload just your program or does it include the bootloader too?

Just your program - bootloader will be overwritten unless someone made an effort to relocate where the image will be programmed in flash.  The Arduino IDE may do this but if you find that after you used the 'upload with programmer' option you can't talk to the board any other way, then the programer may have wiped out the bootloader.
Generally fusebits are not set during normal programming.  You have to specify that option.  Again, the Arduino IDE may have its own tricks, but generally you have to explicitly request the fuse bits be programmed.
Comment: This was kinda what I was thinking. I was thinking that I couldn't program via USB because the bootloader may have been overwritten, but I bricked the controller before I was able to test further. A loose wire interupped the programming, and the controller stopped responding to the programmer, which is why I asked about the fuse bits.
Answer: the usb interface on an arduino gets you at the avr serial port, where you need a bootloader, etc.  Using the ISP interface or whatever they call it (I think it is SPI) you can take over the chip and reload the bootloader (might have fuse limitations).  I assume that depends on the binary you are loading and where it wants to load.
The bootloader protocol is often referred to some standard protocol (within the avr world), but if you actually look at the bootloader source (quite easy to read and follow) you find that most of the bootloaders barely support that protocol and each incarnation has its own features.  I find it easier to just look at the protocol used by the bootloader and not spend much time outside that.
As far as the other programming interfaces the xmega has an interesting interface, pdi which is not hard to use, and there is the spi interface the other smaller avr devices uses.  both are documented with the chips themselves.

Arduino AVR Programing


population statistics and deviation from mean

Question: Suppose $X \sim N (50, 20.5)$ represents a population. If $X_1, X_2, …, X_n$ is a random sample from this population, find $n$ such that $\mathbb{P}(X_1 + X_2 + … + X_n > 2000) = 0.95 $
Comment: Welcome to Math.SE! This question is missing context or other details: Please improve the question by providing additional context, which ideally includes your thoughts on the problem and any attempts you have made to solve it. This information helps others identify where you have difficulties and helps them write answers appropriate to your experience level.
Answer: We assume that $20.5$ is the standard deviation of our normals. The random variable $W=X_1+X_2+\cdots +X_n$ is then normal, mean $50n$, standard deviation $20.5\sqrt{n}$.
The probability that $W\gt 2000$ is equal to the probability that $Z\gt \frac{2000-50n}{20.5\sqrt{n}}$, where $Z$ is standard normal.
Note that there is $5\%$ probability in the left tail of the standard normal if we take $z\approx -1.645$.
So we end up looking at the equation
$$\frac{2000-50n}{20.5\sqrt{n}}=-1.645.$$
This simplifies to (approximately)
$$50n-33.7225\sqrt{n}-2000=0.$$
We have reached  a quadratic equation in $\sqrt{n}$. Solve.
Answer: So, by the theorem on sums of normal distribution, if $Y_n = X_1 + X_2 + ... +X_n$ then we have that $Y_n \sim N(50n, 20.5n)$ (I can show you a proof for this if you'd like but hopefully you could do this on your own? Or at least your teacher/professor told you this)
Let $Z \sim N(0,1)$ then we have that $\mathbb{P} (Y_n >2000) = \mathbb{P} (Z > \frac{2000 -50n} { \sqrt{20.5n}}) = 1 - \mathbb{P} (Z \leqslant \frac{2000 -50n} { \sqrt{20.5n}})$ And we want this to be equal to $0.95$.
So we get (by looking up in normal tables) $\frac{2000 -50n} { \sqrt{20.5n}} = \Phi ^{-1}(1- 0.95)  = \Phi^{-1} (0.05) \approx -1.645$
And now we have the equation $2000 - 50n = -1.645\sqrt{20.5n}$ (note n need not be an integer, we will just round up to the nearest integer for our final solution)
I just chucked this equation into Wolfram Alpha to solve it, but if you wanted to you would square both sides of the equation and solve the quadratic you get, and you check which root really is a solution to the equation (the only positive one I imagine though I don't actually know) and we get n = 40.9533, so we round up and get n = 41 as our solution.
As a quick sanity check we note tat $Y_{41} \sim N(2050, 840.5)$ then our standard deviation is $\sqrt{20.5*41} \approx 28.9$ and then $\mathbb{P} (Y_{41} (= X_1 + X_2 + ... + X_{41}) > 2000) = 1 -  \mathbb{P} (Y_{41} \leqslant 2000) \approx 1 - \mathbb{P} (Z \leqslant \frac{2000 - 2050}  {28.9}) = 1 - \mathbb{P} (Z \leqslant -1.725) >0.95$
So we are correct, and $n = 41$ is the answer.
Comment: Just FYI, I took the convention that the second argument was the variance not standard deviation, if this isn't the convention you're using then all of the above is basically totally wrong.


Do black hat hackers or even hacktivists use penetration testing tools?

Question: I was reading digital forensics as part of my curriculum and came across some tools used for hacking (ethical hacking aka pentration testing). There is a bunch of tools out there. I was wondering if the bad guys actually use such tools or do they make their own stuff based on specific purpose ?
Comment: If you strip out all the extra words, you just asked "do hackers use pre-made hacking tools?"
Comment: Yes but then there may have been  confusion as to which hackers ? Like the really bad guys or ethical ones.
Comment: This exploration will be relevant: https://security.stackexchange.com/questions/34400/what-is-the-distinguishing-point-between-a-script-kiddie-and-a-hacker
Comment: Thanks man. I really appreciate it
Comment: @sweetpoision10 how are the tools you use in any way relevant to the ethics you apply, especially if you're in a group of people who do not concern themselves with ethics?
Comment: "I" was attacked with partial success using metasploit a few years ago - (that's a yes). After patching the vuln, I considrered raising a bug report against the metasploit module that partially failed.
Answer: Hacking tools are available and used by everyone, good and bad. In fact, releasing these tools to the good guys is helpful so they can develop protections against them in real attacks.
Of course, there are also custom/specific purpose tools that are NOT widely available as well.
Answer: Yes, Black Hats use ready-made tools.
The reason for this is simple. These tools had a lot of effort put into them to fulfill a wide variety of tasks very well. Sure, any hacker could write their own HTTPS proxy, but Burp does that already and does it probably a lot better in a fraction of the time it would take a hacker to write even a simple proxy.
Regarding custom tools, most "custom made" tools are actually "proof-of-concept" tools, meaning that they make use of some newly discovered vulnerability. These tools have very low code maturity, usually require a lot of patching to get them to run on a different system and are generally made to run once.
You can compare this to some shell script that people write to do stuff once, versus a shell script that is distributed with some widely popular tool. These two scripts vary wildly in code quality, but if you only need to run it once, it doesn't matter.
Answer: A lot of them are opensource, you can grab the latest version of Metasploit and extend its modules for example, so yes, even bad guys use the tools good guys use, even on Defcon you see the top white hats and the gray / dark hats.
But in order to be really good at this as I've seen in most of the articles I've read about security, most of the good tools are not open source and are private, owned by their coders and sometimes shared among those who share good knowledge of a specific expertise on private forums and some others techniques are not even taught to common people or known by them because you have to develope certain level of knowledge to even try to attempt to perform this bleeding edge techniques.
Lets put it like this, a penetration tester might script out a whole pentest with opensource tools just to verify common vulnerabilities and make a report and make the day right?
But there are other peeps that take a while to stay a while and tinker even further to do some crazy stuff making their own tools to do stuff that for obvious reasons is not out there freely.
Good jobs take effort, time and money.
Answer: Criminals, and even government cyber armies use what works. Period. If a pre-made tool works, then why invent a new one?
This is very well recorded. I did a search for "chinese army metasploit" and these are some of the results:

https://www.zdnet.com/article/metasploit-popular-hacking-and-security-tool-gets-long-awaited-update/
https://www.wired.com/2014/12/fbi-metasploit-tor/
https://books.google.co.uk/books?id=3bzPDwAAQBAJ&pg=PA59&lpg=PA59&dq=chinese+army+%22metasploit%22&source=bl&ots=phTclT2HSW&sig=ACfU3U0hRLRXzVv_keE7KZ-3hlLtdU2x3g&hl=en&sa=X&ved=2ahUKEwii6K2OrNHnAhXXShUIHd2EDxEQ6AEwEHoECAoQAQ#v=onepage&q=chinese%20army%20%22metasploit%22&f=false
https://www.ft.com/content/d81e30de-00e4-11e6-99cb-83242733f755


Are Keep outs with height (3d keep outs) essentially keep In?

Question: I have a translucent "keep out" box in my IDX file (NX) that sits on top of my PCBA. Does that mean the EE is only allowed to place components only within said box?
Answer: It can serve multiple uses. The first normally being a check that 2 components 3d models are not intersecting.
Take a common mode choke. The size on the pcb for the footprint may be smaller than the component
Other things are enclosure design. If your board is meant to slide in some slots then you may add a ceiling to the pcb to ensure nothing will scrape or hit.
And finally it can be for planning. If things wrap around one another say with a folded sheet heatink you might extend the 3d constraint to leave enough room to both fit the piece and be able to tighten the screws.


YA fiction novel about a boy who discovered the power of runes as seen in Norse mythology

Question: I'm looking for a book I read as a teen, it was about a boy (his sister became a main character as well) (modern day) who discovered the power of runes as seen in Norse mythology.
Comment: I think it was "The Runestone Saga". Thanks anyway!
Comment: @CaseyLeigh If you've found your answer you can answer your own question with that it is!
Comment: Casey, please feel free to post your own answer, taking whatever you wish from mine. Or you can accept an answer by clicking on the checkmark by the voting buttons as per the [tour].
Comment: This is very terse can you remember anything else that happens in the book you could [edit] in? Also when we're you a teen?
Comment: This description fits hundreds of books and is a trope  (https://tvtropes.org/pmwiki/pmwiki.php/Main/InstantRunes). You need to be much more specific
Comment: It really is a very bare question... we only really have the answer because Casey provided it. Maybe we ought to ask ourselves if this will be of use to anyone.
Answer: Casey indicated in the comments that they believe the book to be from The Runestone Saga, by Chris Humphreys. The first book, The Fetch, published in 2006, has Sky and his cousin finding Norwegian runes belonging to their grandfather.

In the attic, in an old sea chest, secreted away, are a mysterious journal and a set of runes: 24 stones that will change Sky's life forever.
When Sky and his cousin Kristin find their Norwegian grandfather's runes, Sky feels like the wait is over, like he can now release the breath he wasn't even aware he'd been holding. But when he lays out the stones in a runecast they find in Sigurd's journal, he is catapulted into a world filled with more possibilities and more danger than he ever imagined.

The Kirkus Review of the book provides a bit more detail about the supernatural and time travel aspects of the book.

A boy is drawn into the violent past of his grandfather and Viking ancestors. Sky's not looking forward to a summer with his estranged cousin Kristin, until they find Grandfather Sigurd's runes in an old chest in the attic. Runecasting leads Sky to animal shapeshifting, dangerous haunts and visions of going a-Viking with his berserker forefather, Bjorn. Sky and Kristin run off to Norway on a mysterious quest, where they discover that Sigurd is neither so dead, nor so benevolent, as they'd originally suspected. Sky's lessons in unexpectedly potent violence lead him to some hard decisions. The cousins slog through overwritten prose (though some historical Viking scenes are brought beautifully to life with language reminiscent of Anglo-Saxon alliterative rhythms). Despite pacing, a compelling adventure that asks hard questions of its characters.


integrating mod-spdy with mod-mono

Question: Google is working on a new application level protocol for the web SPDY and there is an apache module mod-SPDY for it. My question is that is it possible to integrate mod-spdy with apache's mono module (for opening .net pages) so that pages written in .net can load over SPDY.
        If so, how do I go about doing it?
Answer: mod_spdy had been put on hold for a while but is now under active development. Please give it another try: http://code.google.com/p/mod-spdy/wiki/GettingStarted
Answer: mod_spdy is dead code.  It was written back when SPDY was at version 1 and won't work with recent versions of Chrome: http://japhr.blogspot.com/2011/04/dont-bother-with-modspdy.html.
So unfortunately, if you want to use mono with SPDY, you will need to pursue alternatives (e.g. writing your own library for mono).

integrating mod-spdy with mod-mono


Why did Peter dedicate his first book to those who are 'strangers'? (1Peter1.1) Was Peter different to the other apostles, and aware of it?

Question: Does the linguistic trope 'strangers' hold implications regarding inner nature of certain biblical characters? If Jesus blessed Peter could he have opened Peter's eyes to his (base) nature in need of redemption, as implied by 'strangers'? (ie of the line of Cain)
Answer: My answer is going to be short and to the point. Peter is addressing believers, chiefly Jewish Christians, scattered throughout five Roman provinces of Asia Minor. These Christians were being persecuted.
Peter called them "strangers" (parepidemois, sojourners) because earth is but their temporary home; their permanent abode is heaven. The term "scattered" suggest they were clustered in little church groups here and there.
Notice at verse 2 the believers are "elect" (eklektois, chosen) according to the foreknowledge of God the Father through sanctification of the Holy Spirit.
Comment: Thanks for that - I was expecting this answer...but what if one looks a little deeper at Peters character, and the duality of the way Jesus viewed him..?


LWC how to save variables on server side, can I use session?

Question: I want to save variable on server side (not in database).
In Visualforce page we use Apex Controller and we can use session, can I use session in Lightning Web Components?
Comment: Hi Alexandr, in lightning aura or web component the state has to be maintained on client side; as all calls are static by design storing variable on server side is not possible. I am afraid that session may not be used for this type of caching. What are you trying to achieve in your use case?
Comment: Thank you for answer, I want to save custom object without store in database. If
 user fills special field - I insert it to database, it will one dml operation.

Look! Maybe I can create session with public REST Api ?
Answer: So, you want to store data not in a table(Dirty object) on server side.
Had it been client-side, I would have recommended, cookies for <4KB, or Local Storage for up to 5MB storage.
But you want to store in server-side, so that its browser and device-independent as data is fetched from the server.
I would look into Session Platform Cache.
You can set and retrieve value in APEX and pass it on client side
<code>// Add a value to the cache
DateTime dt = DateTime.parse('06/16/2015 11:46 AM');
Cache.Session.put('ns1.partition1.orderDate', dt);
if (Cache.Session.contains('ns1.partition1.orderDate')) {
    DateTime cachedDt = (DateTime)Cache.Session.get('ns1.partition1.orderDate');
}
</code>
Retrive Value back:
<code>// Get a cached value
Object obj = Cache.Session.get('ns1.partition1.orderDate');
// Cast return value to a specific data type
DateTime dt2 = (DateTime)obj;
</code>
Answer: I would recommend using session cookies to have items in the browser.
https://www.allaboutcookies.org/cookies/session-cookies-used-for.html
There is a good answer on SFSE already:
https://salesforce.stackexchange.com/a/270327/55914


Atmospheric pressure on a giant mountain

Question: I have this dnd campaign set in a world where the only continent is a giant mountain with a mesa on top. I've made it "big enough for the top to be as large as Europe", but never went into details with my players.
I was thinking, is there a way I could solve the problem posed by the atmospheric pressure changing dramatically as you go higher and higher on the mountain? Is it the only way to say "because magic world"?
Comment: Huge updrafts of oxygen rich air maybe?
Comment: For more inspiration, see [Plateau](http://larryniven.net/humans.shtml) .
Answer: Turn the problem around, or ignore it
No there is no problem that the air gets thinner as you go up the mountain, because if everyone lived there and evolved there, then those are the conditions they have been adapted to.
There might be a slight problem in going down the mountain though where the air pressure increases. Ordinary air can become toxic under the wrong circumstances when it comes to pressures.
But in any case, unless this aspect of physics is important to your world I would say: ignore it all together. Just assume that the atmosphere is right for humanoids to survive both being at the mesa and being at sea level, and that that the evolution of humanoids and mammals and whatnot is adapted to all these atmospheric conditions. Only consider this if it is important to your world, your storytelling and the game-play. Otherwise just do some hand-waving and say "This does not affect them, because the Game-Master says so".
Comment: What about people living on the coast climbing up the mountain? Wouldn't they have some trouble with altitude sickness?
Comment: Reminds me of one of Larry Niven's worlds.  Only the high plateau was inhabitable, everywhere else had lethal pressure.
Answer: If you want to attempt to explain it:
Lots of atmosphere!
Increase the world's atmosphere to the point where pressure on top of the mountain is normal. Problem: now the pressure at the foot of the mountain would be at crushing levels.
Big glass dome
Or a force field, or a magnetic field so strong it can (Warning! Incorrect science!) pull air molecules towards the mountain. Perhaps not...
Possible geo-stationary sattelite
Have a moon which is SOOOO big that it pulls the atmosphere into an egg-shaped shell around the world. This requires the moon to be geostationary (always above the same point) and to coincidentally always float above said mountain for some reason or another. (Let's not go into what would happen to all the water on the planet.)
Inverse earth?
The world might not be a planet! What if it is a big hollow sphere with the sun floating in the middle? Maybe the centre of gravity for the earth is off-centre due to one side of the sphere being really thick and heavy (there being a continent-sized mountain on it)? In this case the atmosphere would collect around the mountain and be thinner around other parts. Problem: no atmosphere on the other side.
Anti-Gravity!?!?
Maybe there is a moon or something that is a source of anti-gravity, pushing the atmosphere (by coincidence, of course) away? The result: Thin atmosphere on one side of the planet and think atmosphere on the other.
Weird shaped planet
Let me just draw a picture for this one:

Problem here is you're going to have a big ocean acting like a moat which surrounds your awesome mountain... Still, its plausible if not easy to explain.
Or ya know... "Because magic"
The explanation for anything which cannot be explained.
Comment: Any moon close enough to the planet to attract its atmosphere in the way you describe would almost certainly be inside the planet's Roche limit and would disintegrate due to tidal forces. The weird shaped planet would also be impractical because the planet should have achieved hydrostatic equilibrium and become a proper spheroid. I suspect that, even if some magic allowed it to retain this odd shape, the atmosphere would hug the surface, rather than create a sphere like in your illustration.
Comment: @ZacCrites you are completely right. Perhaps a combination of one of the above and "because magic" would make a slightly possible explanation.
Answer: If the mountain is small enough, this can be solved by climbing slowly, in order to trigger acclimatization to altitude: after few days, the human body can function normally in hight altitude.
Additional, human in this world could be stronger than human in our world, allowing quicker adaptation or higher maximal altitude.
Answer: Short answer : Or your mesa is empty from all sort of life (except some micro organism) and if your crew wants to go up there they will need to be well prepared. Or your mesa is populated but there must be some construction (or magical device) that allows life up there (e.g. something like domes over cities and tunnel that links them).
I think the reason you care about low atmospheric pressure in high altitude is because you want your mesa to be populated right ?
So there are several consequences to high altitude that are not really suitable for life.

The low atmospheric pressure : This is the most obvious, as you go higher, the pressure of the gas constituting the atmosphere are lower. Imagine a balloon poked with little tiny holes that you put underwater, fill the balloon with honey (for example) and press it. Under a certain pressure, depending of the surrounding pressure, the viscosity of honey and the diameter of the holes, the honey will poor into water. This is exactly how dioxygen goes through your lungs into your blood. The more the pressure of the honey (the air in your lungs) is, the more dioxygen will go into you blood. Furthermore there is a certain limit from which the process will reverse, and the pressure of your blood will be higher than the one in your lungs and so you will spit blood and drown. The same thing happen with plants. So to allow life you need to keep a pretty high gas pressure in lungs (with a magic high pressure bubble around the mouth or so).
The cold : The low atmospheric pressure leads to a temperature decrease. This is not good for life. But, in a standard atmosphere, there is an altitude where the temperature is increasing when you go higher. On the Earth for example, at 20 km high, the temperature is about -60°C and about +5°C at 50 km ! So, if your mountain is high enough (the Everest is under 10km high), temperature should not be a problem.
Solar radiation : Our atmosphere also protects us from bad solar radiation. UVs (really harmful for living cells) for example are mostly filtrated by the atmosphere (and all the ozone layer).

To allow life up there you need to solve all of this problems. Some people, animals or plants are fitted to live in high altitude (e.g high hematocrit level). But in really high mountain live is almost impossible (except maybe some micro organisms). I think a good solution to solve them all at once is to inspire from planet exploration/colonization, the problems are pretty much the same. So I would suggest a big dome (glass, energetic, magic, it's up to you) that protects cities/towns from radiation by filtrating the light, and with an inside atmosphere constituted with the outdoor air, compressed and heated. The connections between the towns could be made by tunnels or by well paid people that have suits to go outside.
Another solution could be to replaces those domes by (natural ?) hermetic caves.
Sources : FRAGILITÉ DES MILIEUX ET ÉCOSYSTÈMES
EN ALTITUDE (in French sorry), Interview MSG : la sentinelle météo de l'Europe (in French too, but with a really good introduction)
Answer: You did not mention how tall the mountain is, but if the mesa is significantly wider than it is tall, there are some factors that could make things more feasible.
First, something that large could actually offset the center gravity of the planet. As air will fall towards that new center of gravity it should help a bit, with the odd side effect of the air being a bit thinner on the other side of the world.
Second, remember that planetary gravity always pulls planets into a roughly spherical shape. That's part of the definition of a planet, that it has enough gravity to do so. Rock will bend under many miles of its own weight. It is likely that if such a geological feature were created, it would quickly settle into a different shape. At the edges it might appear only to be a raised mesa, but the outskirts would have actually been pushed lower, possibly well below sea level. Then while the edges of the mesa might be raised, the center would inevitably be pulled down. So as you travel inward from the edge your altitude is gradually lowered, even if it's too gradual to discern visually.
If however you want the mountain to be hundreds of kilometers tall, and of consistent altitude on the mesa, I think the only other feasible solution is that the planet, as Aric Fowler suggested, has much more atmosphere than earth.  Consider Venus for some inspiration in this case. At the surface the pressure is 92 times Earth's atmospheres and the temperature is a broiling 462°C, but 50 km up the atmosphere is about the same pressure as Earth's and the temperature is 75°C.


Drop down list in menu disappears before able to click

Question: UPDATE: The solution Rohit Azad gave worked, thanks so much.
I've had quite a search through forums looking for a solution for this, but since I don't know coding I'm not sure what applies to me and what doesn't. So, apologies if this is an often solved problem, but I'll greatly appreciate your help!
After much trial and error, I've managed to get a drop down list of pages on my navigation bar; however, when I go to click on a sub-page, the entire menu disappears. I've read through other similar problems where there has been an issue with a margin that's too big, but I think my margins are set to '0'.
The blog is at: http://swirlstwirlsblog.blogspot.com.au/
I haven't got content in the sub pages but there are there and linked in the html/javascript widget.
I've also looked at it in Chrome, Mozilla, and Safari and it's the same issue.
I'm also not sure if this is a javascript, css, or html problem, so please be kind in your responses--I'm only new!
Thanks so much to anyone able to help me on this.
Here's the script I used in the Widget:

Home

Sparkles

Friendship

Humour

About

Us

Contributors

Advertising

Privacy

Contact

And here's the html code I put in the template:

#jsddm {
margin: 0;
padding: 15px;
z-index:1000000000;
position:relative;
}

#jsddm li {
float: left;
list-style: none;
font: 12px Tahoma, Arial;
}

#jsddm li a {
display: block;
white-space: nowrap;
margin:1px 3px;
padding: 5px 10px;
border-right: 1px color: eeeeee;
text-shadow: #ffffff 0 1px 0;
color: #363636;
font-size: 15px;
font-family: crushed;
text-decoration: none;
vertical-align: middle;
}

#jsddm li a:hover {
background: #C8C8C8;
}

#jsddm li ul {
margin: 0;
padding: 0;
position: absolute;
visibility: hidden;
border-top: 1px solid white;
}

#jsddm li ul li {
float: none;
display: inline;
}

#jsddm li ul li a {
width: auto;
background: #ffffff;
}

#jsddm li ul li a:hover {
background: #eeeeee;

}

Answer: ...
Hi now define z-index your #jsddm li ul as like this
#jsddm li ul{
z-index:1;
}

Result is


Is an irrational number odd or even?

Question: My sister just asked this question to me: "Is an irrational number odd or even?" I told her that decimals are not odd or even and that does imply that not recurring and non repeating decimals will also not be odd or even. But I want a rigorous math proof for this. Can someone help me with this proof? Also, can I do this proof by contradiction?
Comment: Similar questions: "Is a brick in the wall male or female?" "Is my left shoe wise or stupid?" The classes 'odd' and 'even' simply do not apply to fractions or irrational numbers, same as 'male' and 'female' do not apply to bricks or 'wise' and 'stupid' do not apply to shoes. Only whole numbers are [partitioned](https://en.wikipedia.org/wiki/Partition_of_a_set) into subsets of odd and even numbers; numbers outside the whole numbers set are not covered by the two classes, so the question has no answer (or the answer is: *neither*).
Comment: Hey. You are correct in that it does not make sense to talk about if a decimal number is odd or even. Only the whole numbers $\ldots,-3,-2,-1,0,1,2,\ldots$ can be odd or even. Decimal numbers like $2.71$ or $0.333333\ldots$ are neither odd nor even. You cannot prove this: It is by definition of the terms odd and even that they only apply to whole numbers.
Comment: Related: [Can decimal numbers be considered "even" or "odd"?](http://math.stackexchange.com/questions/92451/can-decimal-numbers-be-considered-even-or-odd)
Comment: The concept of even/odd is defined only on the integers.  So you are welcome to define an irrational number as even or odd if you want to.  For example we could declare an irrational as even if its integer part is even.  No harm done as far as I can tell.
Comment: The question seems to imply that the answer is the same for all irrational numbers, that all irrationals have the same parity. This makes no sense; if $\pi$ is even then $\pi+1$ is odd.
Comment: @GregoryGrant "No harm done as far as I can tell." That the sum of two "even" (in that sense) numbers may not be "even", very much seems like some harm done.
Comment: Irrationals are definitely odd numbers for most of the people.
Comment: The answer to the question in the title is 'no'.
Comment: I have seen an extension of oddness and evenness to include irrational numbers. Odd is simply defined as 'not even,' where even refers to whole numbers divisible by 2. Under this definition, all irrational numbers are odd.
Comment: @CiaPan, you should talk to the French. To them `la brique` is definitely female :-)
Comment: Can i do this by contradiction?
Comment: @MichaelAlbanese Agree. So post your answer as an answer.
Comment: As others have said, you cannot "prove" a definition; but you can use proof-like steps (induction and deduction) to _motivate_ a definition, as in celtschk's answer.
Comment: @paxdiablo I don't need to talk to the French, nouns in my language have grammatical genders, too (and a brick is female) :) If you look closer, also some English nouns have it, altough they don't display it in declension, just in pronouns: a dog is generally 'he' while a cat and a dove is 'she'. Also ships (esp. sailing ships) are female, possibly with an exception of navy ones. But I meant rather a biological sex here (and I'm sure you know it and your comment is kind of joke, not a misunderstanding). Anyway this is not a place for a discussion like this, so I suggest EOT. :)
Comment: it's like asking if you have stopped beating your wife.
Comment: You might find the *answer* of @JDH to *[this related question](http://math.stackexchange.com/questions/49034/is-infinity-an-odd-or-even-number)* about extensions of the concepts of even/odd numbers interesting.
Comment: @CiaPan But how to decide if question has or hasn't an answer? I mean I can say "every triangle has radius 8". This statement is false or meaningless? "Radius" is defined for circles. So can we say that there is a category error and the "statement" is meaningless?
Comment: @user599310 Just use the definition. There is a definition of an even number, whose prerequisite is 'a number is integer'. If you _have_ a definition of a radius of a triangle, just use it. Otherwise the question is meaningless.
Comment: @CiaPan So is the function $f(x)=x^{2}$ an even number? How do we answer such questions? True, false, meaningless (undefined terms)? Because I can say that this function is not a member of the set "even numbers" so the above statement is false or I can say that even number is defined for integers so the above sentence is not a statement.
Answer: Definition.

Let $n\in \mathbb{Z}$ be an integer. $n$ is called even if ...

According to the definition only integers are even or odd. It is not something that you have to prove.
Answer: The original concept of even and odd is defined on integers. However, one can ask: Is there a natural extension to all real numbers? And if so, what would be the evenness or oddness of irrational numbers?
Now, what would we demand of such an extension? Well, the most important demand is, of course, that integers are even under the extended definition if and only if they are even under the normal definition (that is, also our new definition should for example give us that $2$ is even and $5$ is odd).
Let's therefore try a few properties of even/odd integers:

An number is even if can be written as $2x$.
In the real numbers, every number can be written as $2x$. Thus this definition does not work.
A number is even if it is twice an integer.
This of course works on the real numbers (and makes all non-integers odd). But it seems to be an odd extension; it's certainly not very useful.
The sum of two even or two odd numbers is even, the sum of an even and an odd number is odd; 1 is odd.
Since $1=\frac12+\frac12$, $\frac12$ could be neither even nor odd. This definitiion could probably be made work by making three types of numbers: even, odd or neither. But there are many ways this could be done; the most natural one would be to declare all non-integers as neither even nor odd; but that's where we started anyway. For rational numbers, it would also work if a number is even if for the maximally cancelled form the numerator is even, and odd if both numerator and denominator are odd. But that definition has no natural extension to irrational numbers (except, again, all being neither even nor odd).
Adding $1$ to an even number gives an odd number, and vice versa.
Again, this gives not an unique definition. The most natural definition would be to use a rounding function $\mathbb R\to\mathbb Z$ (like rounding to nearest, rounding up, rounding down, or rounding towards zero) and defining $x$ to be even if $r(x)$ is even. However, which rounding function to choose?

So there are ways to extend even/odd to reals, however you'll definitely have to give up some properties of even/odd numbers, and it is not clear which of those that are possible should be chosen, especially given that the resulting definitions are not too useful anyway. None of them really capture the concept of even and odd numbers.
Comment: "It seems to be an odd extension" - I see what you did there.
Comment: +1 for this answer: If I were a young person asking the question, I would be dissatisfied with the answer "it's defined that way".
Comment: One could call an algebraic number even/odd if the constant term of its minimal polynomial is even/odd. Does anything useful come from this definition?
Answer: One useful approach to generalize odd and even numbers to the irrational numbers is to quantify the "amount of evenness" of a number. We will see that $12$ is "twice as even" as $6$. Then, instead of asking whether an irrational number is odd or even, ask how even it is.
First, start with Patrick Da Silva's answer to the linked question. He explains the basics much better than I could.
Still with me? Good! Now the challenge is to extend the 2-adic valuation $\nu_2$ from the rational numbers to the real numbers. This can indeed be done, and it gives us simple answers for some irrational numbers. For example, $\nu_2(\sqrt 2)=\frac12$. In this sense you could say that $\sqrt 2$ is "half even", although that's not standard terminology!
Sadly, there isn't a unique extension of $\nu_2$ to all real numbers. I can't tell you what $\nu_2(\pi)$ is, because it depends on the extension. Nonetheless, the mere fact that an extension exists turns out to be useful. For example:

Monsky's theorem. It is not possible to dissect a square into an odd number of triangles of equal area.

That sounds like a classical result of ancient Greek geometry, right? Nope, it was proved in 1970 using the existence of an extension of $\nu_2$ to the real numbers! The proof hinges on an elaborate coloring of the plane that, at its core, and in layman's terms, does what you want: it calls irrational numbers odd or even.
Comment: This is a wonderful answer!
Comment: My solution was to use the sgn(ν₂(x)): positive is even, zero is odd, negative I called uneven. This is backward-compatible with the familiar rules for integers, and applies to any number for which you can devise a canonical prime factorization. It obviously includes the rationals, and also includes any integer roots of rationals. The results of some operations on unevens cannot be categorized without more information; ν₂ is enough except when adding numbers of equal ν₂. (It also gave a nice definition of a "totally irrational" number: the multiplicity of each prime factor is less than one.)
Answer: What you need first and foremost is not a proof but a definition.
Normally, one will say something like: one calls an integer even if it is divisible by $2$, and odd otherwise.
Then, being "even" and "odd" is a property of integers, and it makes no sense to ask it for other numbers. It also makes no sense to ask if a circle is even.
Now, you might have a different defintion of "even" and "odd" that makes sense for more numbers and the answer changes.
For example, if you extend the defintion as given above directly to the real numbers, then every number is even: in the real numbers every number is divisible by $2$, since $2X =a$ has a (real) solution for every $a$.
Comment: What type of number is $n$?
Comment: What is your **definition** for odd and even?
Comment: Do what by contradiction?
Comment: @user599310 I suppose you could, but then it is not odd either. If you say a circle is not an even integer then everybody will agree.
Comment: Can i do this by contradiction?
Comment: I mean prove this that irrationals are neither odd nor even by contradiction
Comment: We say that a number is odd if it of the form 2n+1 and even if it is of the form 2n
Comment: Couldn't we say that a circle is not a number therefore is not even?
Comment: Thanks for the answer. I have asked this question in other forums and I got mixed answers with others saying it is non-sense and others saying is false. I have asked a question [Philosophy SE](https://philosophy.stackexchange.com/questions/73965/how-to-contradict-a-general-statement) and I would be grateful if you can solve my misunderstanding. Thanks in advance.
Answer: An irrational number only makes sense if we look at numbers beyond the rationals. In any extension of the rationals we will find the number $\frac 12$. And then any number is divisible by $2$.
We could say, in this context, that every number is even. The problem with this is that the concept simply ceases to be useful when used in that way. So we don't use it like that, and retain it for contexts where divisibility by $2$ makes a difference.
Comment: Great answer (and much better expressed than mine).
Answer: I guess that the original "motivation" for the odd/even distinction in human culture was to know if a number of things (like apples or stones) could be divided between two people in a fair way without having to cut or break a remainder one. And also to known if things could be paired: three women and three men was fine, but one woman and two men meant conflict!
The above distinction makes sense with natural numbers... But what motivation would we have to define odd/even for the rational or irrational for example? Any rational divided by two results in a rational, e.g. 1.5 / 2 = 0.75. If we accept cut or broken things, then we don't care about remainders!
Answer: Here is one more perspective. Think of the congruence mod 2 relation $x \equiv y$, defined as "$x\equiv y$ if and only if $x-y$ is an integer multiple of $2$". (This is usually denoted $x \equiv y \pmod 2$, but I will omit the parenthesis because there will be no chance of confusion.)
It is not hard to verify that this is an equivalence relation: it is reflexive, symmetric, and transitive. The relation is well-defined over any subset of the real numbers, including, of course, the integers $\mathbb Z$. There are only two equivalence classes of $\mathbb{Z}$ modulo the "$\equiv$" relation: the even integers $[0] = \{0 + 2n: n \in \mathbb{Z}\}$ and the odd integers $[1] = \{1 + 2n: n \in \mathbb{Z}\}$.
Similarly, we can define the equivalence classes of the reals $\mathbb{R}$ modulo the "$\equiv$" relation. Here there are many more equivalence classes: except the odds $[1]$ and the evens $[0]$, there are also the equivalence classes $[0.5] =\{0.5 + 2n: n \in \mathbb Z\}$ and $[\sqrt{2}]=\{\sqrt{2} + 2n: n \in \mathbb{Z}\}$, for example. In fact there is a distinct equivalence class $[x] = \{x + 2n: n \in \mathbb{Z}\}$ for every $x \in [0, 2)$.
So in that sense, an irrational number, or in fact any number which is not an integer, is neither odd nor even, because it does not belong to either of the equivalence classes $[0]$ and $[1]$. This is because if $x$ is not an integer, then $x-0$ and $x-1$ are not integers either, and, therefore, neither of them is an integer multiple of $2$.
Answer: All odd numbers on the pascal triangle are in a Sierpinski triangle, which is  a fractal.

The binomial coefficient $\binom{n}{k}$ is defined for integers, but it can be extended to any real number.
$$\binom{\alpha }{k}= \frac{\alpha ^{\underline{k}}}{k!} $$
Another way is by using the Gamma function:
$$\binom{\alpha }{k}=\frac{\Gamma \left ( \alpha +1 \right )}{\Gamma \left ( k +1 \right )*\Gamma \left ( \alpha-k+1 \right )}$$
The thing with the Sierpinski triangle, is that since it is a fractal, it has infinite detail, if you zoom in.
So the concept of being odd can be extended to all numbers  $\binom{n}{k}$ whose coordinates (n,k) fall in the Sierpinski triangle, in the sense that they share a property of odd numbers.
I don't know if the white triangles (made of even numbers on the pascal triangle) also contain odd numbers for non integer coordinates, but if they do, and also conform a fractal, the same concept apply.
Answer: Closely related to other answers but might be good for the purpose. By contradiction:
<code>For a given irrational a, assume it is odd.
a/2 is also irrational; call it b
2b is obviously even since odd + odd = even
so a is even.
So all irrationals are even,
which shows they cannot be split into two categories at least.
All rationals can be expressed as the product of two irrationals
(which is  just saying that a rational divided by an irrational is irrational)
so all rationals are even too.
</code>
∴ 1 is even
Answer: An even number is any integer that is divisible by 2 so the equations for any even number is:
 $N_E=2n:   n\in\Bbb Z$
An odd number is any integer that is not divisible by 2 so the equation for any odd number is:
$N_O=2n-1:  n\in\Bbb Z$
And if you put any integer (replaced by n shown on the equations above) to the equations shown above, none of the equations will give an irrational value so therefore an irrational number is not even and not odd, they are simply IRRATIONAL NUMBERS .

Is an irrational number odd or even?


How do you deal with being behind on a task?

Question: I have a question for you guys. Say, you're given a task as an item in a product backlog. Say, you have a deliverable that's due the following day. If you're behind on the task compared to when you made your estimates, what do you do about it? Does it make you anxious knowing your behind schedule? How do you deal with this? Do you tell the scrum master or the product owner?
Answer:
Yes, it makes me anxious. But I am usually both behind and anxious anyway.
That's what daily standups are for -- so the team doesn't discover a week later that you're a week behind.
Answer: I would usually relay that information to the scrum master during the daily scrum meeting. As soon as you know you're behind you should inform the scrum master so he can either get someone to help you (maybe someone else is ahead of schedule and has bandwidth to help), determine whether overtime is needed, or if it's an impediment outside of your team's control then the backlog item needs to be deferred he can provide rationale to stakeholders.
Comment: Working overtime should really only be a last resort for if the feature is actually _needed_ at the end of that sprint (say, due to a bad promise from marketing).  Otherwise your velocity is going to get screwed up and create the expectation that this higher number of story points is normal.


Scripting in GRASS

Question: Can anyone suggest me web-links to learn scripting in GRASS GIS (its utilities, examples etc.) other than those available in GRASS official Wiki/Sites?
Comment: what kinds of things are you interested in doing in your scripts? are you thinking of basic scripts to automate and recall actions, or more complex programs?
Comment: Currently I am thinking of implementing basic repetitive tasks like performing supervised classification on different groups/subgroups in a mapset. But I am interested to know about complex implementation scenarios as well.
Comment: What kind of examples are you looking for? e.g. shell, bash, or python scripts?
Comment: I am mainly looking for shell/bash scripts. If it's important I use GRASS in Ubuntu 11.04.
Answer: You can get some Grass shell examples on GRASS lists.
Try to run a search on shell or bash script. Looking at users script online is a good approach to understand how it works.
You will find few snippets on that page and also links to references (on the bottom of the page). See also Appendix 2 of that online ressource by M. Neteler. Some others examples are also available on GRASS book.
From what I know the GRASS wiki is probably one of the best resource to learn GRASS scripting.

Scripting in GRASS


Integrate Redmine with PHPStorm

Question: I recently started using PHPStorm and wonder if there is any way to integrate full issue / bug / time tracking in Redmine with PHPStorm?
Answer: To enable integration with an issue tracking system

Access the Servers dialog box. Do one of the following:
  Open the Project Settings. Below the Tasks node, click Servers.
  In the Open Task dialog box, click settings.
  On the main menu, choose Tools | Tasks&Contexts | Configure Servers
  In the Servers dialog box, specify the following:
  The URL address of your issue tracking server.
  Your account credentials on the server in question. These credentials will be different for the different issue tracking systems.
  Specify whether you want to access the server via proxy and specify the proxy settings.
  To allow access to the specified server for other members of your team, select the Share URL check box.
  To check whether the specified settings ensure successful connection to the server, click the Test button.
Configure synchronization between PhpStorm and your issue tracking system. To do so, open the Project Settings, and click Tasks. In the Tasks page, configure interaction between PhpStorm and your tracker. Do one of the following:
To have PhpStorm synchronize with the issue tracking system in the background on a regular basis, select the Enable issue cache check box and specify the synchronization frequency and the cache size.

Taken from here: http://www.jetbrains.com/phpstorm/webhelp/enabling-integration-with-an-issue-tracking-system.html
Another one here: http://saiteneffekt.de/2012/04/integrate-redmine-into-phpstormintellij-on-mac-os-x/
Comment: If you copy pasted some text, please wrap it in block quotes using the Ctrl-Q keyboard shortcut or the appropriate editor button.
Comment: thanx for the warn

Integrate Redmine with PHPStorm


How to move a document library with item level permissions from one site collection to other site collection?

Question: I have a document library with item level permissions. how to export the complete document library with item level permissions from one site collection to another site collection?
Comment: is this one time only situation or will it occur occasionally? If 1st, did you consider sharegate 3rd party application? It is free for 30 days while lasts trial. client can be installed on any PC.
Comment: Be carefull using the 30 trial version from ShareGate, as it is a trial version and will exclude some files randomly. (Otherwise nobody would purchase a license)
Answer: The fastest way is to use export/import of the document library, like the following:

Use Central Administration to export a site, list, or document library
  in SharePoint Server
You can use Central Administration to export a site, list, or document
  library. You can only export one site, list, or document library at a
  time.
To export a site, list, or document library by using Central
  Administration

Verify that the user account that is performing this procedure is a
  member of the Farm Administrators group.
Start Central Administration.
In Central Administration, on the home page, click Backup and
  Restore.
On the Backup and Restore page, in the Granular Backup section,
  click Export a site or list.
On the Site or List Export page, in the Site Collection section,
  select the site collection from the Site Collection list, and then
  select the site from the Site list.
If you are exporting a site, skip this step, Select the list or
  document library from the List list.
In the File Location section, in the Filename box, type the UNC path
  of the shared folder and the file to which you want to export the
  list or document library. The file name must use the .cmp extension.
If the file already exists and you want to use this file, select the
  Overwrite existing files check box. Otherwise, specify a different
  file name.
If you want to export all the security and permissions settings with
  the list or library, in the Export Full Security section, select the
  Export full security check box.
If you want to specify which version of the list or library to
  export, select one of the following versions from the Export
  versions list:

All Versions
Last Major
Current Version
Last Major and Last Minor

When you have specified the settings that you want, click Start
  Export.
You can view the status of all backup jobs at the top of the
  Granular Backup Job Status page. You can view the status of the
  current backup job in the Content Export section of the page. The
  status page updates every 30 seconds automatically. You can manually
  update the status details by clicking Refresh. Backup and recovery
  are Timer service jobs. Therefore, it may take several seconds for
  the backup to start.

If you receive any errors, you can review them in the Failure Message
  column of the Backup and Restore Job Status page. You can also find
  more details in the .export.log file at the UNC path that
  you specified in step 6.

Reference: Use Central Administration to export a site, list, or document library in SharePoint Server
Comment: will this export the item level permissions as well? do it need to perform any additional steps to bring the item level permissions to destination location? Destination is within the farm and web application but a different site collection.
Comment: It should. But to be sure, make a PoC in your test environment


In the teardown event during an NUnit test how can I get to the attribute applied to the method that was just tested?

Question: I have a test method that is run. When the method generates an exception I want to know what the name of the test was and the exception content.
In the teardown for the test I want to get access to this information. How would I get access to it from the [TearDown] attributed method?
Answer: You can access text context objects in test tear down method
[TearDown]
public void TestTearDown()
{
  // inc. class name
  var fullNameOfTheMethod = NUnit.Framework.TestContext.CurrentContext.Test.FullName;
  // method name only
  var methodName = NUnit.Framework.TestContext.CurrentContext.Test.Name;
  // the state of the test execution
  var state = NUnit.Framework.TestContext.CurrentContext.Result.State; // TestState enum
}

I don't know which version was first to support it, but mine is 24.
Comment: In Nunit 3.0 State is now called Outcome so that last line would be
`var state = NUnit.Framework.TestContext.CurrentContext.Result.Outcome;`
Answer: I don't think there's a good way built in to nunit, but it's not a hard problem to resolve.  Just wrap your tests in a try/catch block, catch any exceptions, and save them (and the test name) to a private member variable in your test class.  Then you've got access from your TearDown method.
Not particularly elegant, but it works.
Comment: Using `try-catch` in unit tests is generally not a good idea.
Answer: Another solution would be to use a template method and run all tests using this method. For example:
// template method
void Execute(Action test)
{
    try
    {
        test();
    }
    catch (Exception e)
    {
        // handle exception here
        throw;
    }
}

[Test]
public void Test()
{
    Execute(() =>
        {
            // your test here
        });
}

This pattern is particularly useful when your test uses some resources that must be initialized before test and disposed after test (e.g. temporary file). In that case, you can use a type parameter in test delegate.
Another advantage is that you can easily let the test run on different thread, using different culture etc.
Disadvantage is clear: it forces you to use lambda method in every test.
Answer: OPTION 1: I don't think you can. Or rather, I don't know that you can. How I approach this need is to use a try/catch on the specific tests, do what I want with the exception and then throw again within the catch block so that the test could fail.
try{
    // do something that can potentially throw;
}
catch(Exception ex){
    // do something interesting with the ex;
    throw;
}

OPTION 2: If you've not gone too far along, you may want to use xUnit which has a different exception expectation model and may provide some of the control you are looking for.
Comment: Using `try-catch` in unit tests is generally not a good idea.


Set an application page as home page in a team site

Question: I would like to set an application page as a home page in a team site sharepoint 2013 it's possible?
I would like to do that in the feature activated event.
Comment: Why would you want to do that, seems like an unusual requirement?
Answer: We cannot set page (http://[servername]/[projectname]/_layouts/Pages/Summary/Default.aspx) to website welcome page because this page not the part of our current site.
You can set a page to web site welcome page that has the part of our current website. To do this you have to go Site Actions->Site Settings-> Welcome Page (under Look and Feel), set your page as welcome page that has the part of our site. For this you have enabled publishing feature on site.
You can also check:
Use an application page as the default/welcome page
Possible to have the default landing page of my Sharepoint Site be an applicaiton page?


Example of steady Ricci soliton whith indefinite or nonpositive Ricci curvature

Question: I am looking for example of steady Ricci soliton with indefinite or nonpositive Ricci curvature.
Any help will be appreciated.
Thanks!
Answer: I have found doing some calculation that the metric:

$$g(t)=\frac{dx^2+dy^2}{e^{-4t}-x^2-y^2}$$

satisfies $\frac{dg(t)}{dt}=-2Ric(t)$
Where

$$\frac{dg(t)}{dt}=\frac{4e^{-4t}(dx^2+dy^2)}{(e^{-4t}-x^2-y^2)^2}\ {\rm and}
\ Ric(t)=\frac{-2e^{-4t}( dx^2+dy^2)}{(e^{-4t}-x^2-y^2)^2}$$

this should be a solution to the Ricci flow on $R^2$.
Furthermore, with some other calculation, I found that this metric $g(t)$ is the only solution within the family: $g_{\lambda}(t)=\frac{dx^2+dy^2}{e^{-4\lambda t}-x^{2 \lambda}-y^{2 \lambda}}$, in fact, the only solution to the Ricci flow is only for $\lambda=1$.
Said this, my analysis has been to see the behavior in time for $g(t)$ and $Ric(t)$, when $t$ tends to $\infty$ and $- \infty$, but I want that
the metric $g(t)$  remain positive.
a) Then for $t \rightarrow \infty$, to ensure that $g(t)$ is positive, I fixed $x=0$ and $y=0$ and I get $g(t)$ tends to $\infty$ and $Ric(t)$ tends to $-2$
b) While for $t \rightarrow - \infty$  I get $g(t)$ tends to $0$ and $Ric(t)$ tends again to $-2$.
For $t=0$,
I get $g_0= \frac{dx^2+dy^2}{1-x^2-y^2}$ and with a simple calculations, I found that the 1-parameter family of diffeomorfism is $\phi_t=(e^{2t}x, e^{2t}y)$.
Considering $r^2=(x^2+y^2)$, the Scalar curvature, for $t=0$, is
$R=\frac{-4}{1-r^2}$.
Now If I make an analysis of singularities (always for $(1-r^2)>0$), I found that if $r$ tends to $1-$, $g_0$ tends to $\infty$ and $R$ tends $- \infty$.
This soliton should be a steady soliton, it has negative curvature and it is not bunded from below.
Comment: There is a small error in your post, the given solution is not on R^2, it is only defined on the unit disk or a subset thereof. It also doesn't make sense to take t to infinity (what is the underlying space?). Usually steady solitons are defined for all time, it is not the case here since the metric is not complete. Any complete steady soliton has nonnegative scalar curvature. (theorem of Bing-Long Chen)