I've been at this one for a while:   A random variable $X$ follows the distribution $$f_X(x) = \begin{cases} Cx^2&,\quad -2\leq x \leq 1\\0&,\quad \text{Otherwise}\end{cases}$$and  $Y\triangleq X^2$.  Find E[Y] and Var[Y].  I calculated C = 1/3.   I've tried $\int_b^a yf(y) dy$ for E[Y] and a similar formula using $y^2$ instead of $y$. The integrals were executed piecewise.   I could use some help, as all of my attempts (variations on the above two strategies) have been dead wrong.  The similar question on the board does not appear to address the calculation of these variables.

I'm learning probability, specifically transformations of random variables, and need help to understand the solution to the following exercise:      Consider the continuous random variable $X$ with probability density function $$f(x) = \begin{cases} \frac{1}{3}x^2 \quad  -1 \leq x \leq 2, \\ 0 \quad \quad \text{elsewhere}. \end{cases}$$ Find the cumulative distribution function of the random variable $Y = X^2$.   The author gives the following solution:   For $0 \leq y \leq 1: F_Y(y) = P(Y \leq y) = P(X^2 \leq y) \stackrel{?}{=} P(-\sqrt y \leq X \leq \sqrt y) = \int_{-\sqrt y}^{\sqrt y}\frac{1}{3}x^2\, dx = \frac{2}{9}y\sqrt y.$  For $1 \leq y \leq 4: F_Y(y) = P(Y \leq y) = P(X^2 \leq y) \stackrel{?}{=} P(-1 \leq X \leq \sqrt y) = \int_{-1}^{\sqrt y}\frac{1}{3}x^2\, dx = \frac{1}{9} + \frac{1}{9}y\sqrt y.$  For $y > 4: F_{Y}(y) = 1.$    Previous to this exercise, I've managed to follow the solutions of two similar (obviously simpler) problems for a strictly increasing and strictly decreasing function of $X$, respectively. However in this problem, I don't understand the computations being done, specifically:    How does the three intervals $0 \leq y \leq 1$, $1 \leq y \leq 4$ and $y > 4$ are determined? In the two previous problems I've encountered, we only considered one interval which was identical to the interval where $f(x)$ was non-zero. In the case where $0 \leq y \leq 1$, why does $P(X^2 \leq y) = P(-\sqrt y \leq X \leq \sqrt y)$ and not $P(X \leq \sqrt y)$? I have put question marks above the equalities that I don't understand.   I think I have not understand the theory well enough. I'm looking for an answer that will make me understand the solution to this problem and possibly make the theory clearer.


Last month I was traveling to Japan with my husband and my brother in law for visit from USA. Immigration officers let my husband and my brother in law entry into the country,but they not let me in due absence of visa. My question is who’s responsible for this? Do airline for this?

OK, I will try and stick to the facts to explain this whole situation. I would really appreciate everyone's comments:   Me (Irish passport) my wife (Filipino passport) and 2 year old twins (Irish passports) all live in the UK. My wife has residence here. We are flying from Manchester to Doha. We're Planning to stay 3 weeks. As my wife had a UK residence stamp & EEA Family permit visa, we called the UK home office to just verify if she could travel to Qatar without a Visa. They informed us (recorded conversation) that my wife had the same entitlement to me as long as she was traveling with me. I understand now, that our calls should have been straight to the Qatar embassy in London to Verify. We just took it from the UK Home Office as being correct. We arrive at Manchester Airport. We asked the Qatar Airways check in staff to verify my wife's passport to confirm she is entitled to entry in the state of Qatar. Check-in staff confirmed everyone is OK with my wife's passport as we board our 8 hour flight to Doha with our 2 year old twins. We get to Doha and my wife is refused entry at immigration as they say she requires a visa. Calls are made by Qatar airways to Manchester Airport - Qatar airways admit full responsibility for allowing us to travel when we should not have been allowed to travel. We have to re-book flights at Doha - Qatar Airways just changed our return flight to get us back on the next available flight.  We had to pay to enter a lounge in Doha airport with our own money, just so we can give our children some rest and food. We return to Manchester 8 hours later. The twins' double buggy is missing (still missing to date). I understand my wife didn't have the correct Visa, as we were given false information by the UK home office. But, they should not have allowed us to board a plane with those checks being done. If I had known at Manchester airport, I could have made the journey myself with 1 of my children, and I could have processed the Visa for my wife at our hotel in Doha. But, because were not noticed and all allowed to board, I was never given this option. Are Qatar Airways at fault? Should all our flights be re-instated? Are we entitled to compensation? Should they reimburse our expenses?   This is currently being reviewed by the airline. It would be good to get comments and peoples thoughts.


I recently had an eye appointment, and the optometry student who saw me told me that, for my next pair of glasses, I should get lenses with "blue blocker" material.  There is some (scant) evidence that blue light from computer monitors causes macular degeneration over time.  Prescription lenses with blue blocker look ugly, IMO, so I opted not to get the blue blocker in my lenses.  At the same time, I don't want to lose my eyesight if I can avoid it.  Are there software solutions available in Ubuntu for turning off or substantially reducing blue light emitted from my monitor -- at the particular wavelengths that have been shown to harm eyes?

f.lux is software which adjusts temperature of your display according to time of the day. Is it possible to make f.lux work in Ubuntu 14.04? If so, maybe you can share your knowledge or point me to a guide.


First of all, what is the elementary methods for solution of integrals?Who decides this?For example, and $\displaystyle\sqrt{lnx}dx$ or $\displaystyle\int e^{sin(e^x)}dx$  When I try to solve these integrals and fail,then want wolfram to solve these,and I always get this   $$\text{(no result found in terms of standard mathematical functions)}$$  What is the "standard mathematical function", Can  $\left[\dfrac2{\sqrt \pi}\displaystyle\int^x_0 e^{t^2}dt\right]$ be a standard function?Why not?  What is the tiny line between standard and non-standard functions?Why we can't  solve these non-elementary integrals with elementary methods?Can we define or fidn all elementary methods?

In the past, I've come across statements  along the lines of "function $f(x)$ has no closed form integral", which I assume means that there is no combination of the operations:  addition/subtraction multiplication/division raising to powers and roots trigonometric functions exponential functions logarithmic functions  which when differentiated gives the function $f(x)$. I've heard this said about the function $f(x) = x^x$, for example. What sort of techniques are used to prove statements like this? What is this branch of mathematics called?  Merged with "" by : Sometimes we are told that some functions like $\dfrac{\sin(x)}{x}$ don't have an indefinite integral, or that it can't be expressed in term of other simple functions. I wonder how we can prove that kind of assertion?


The title is basically my question. Is Fashionable for views on all questions asked during Winter Bash on all sites or on just one site?  It has an explanation of:     get over 9,000 combined total views on all questions that you asked during Winter Bash   But that doesn't get me anywhere with what I am asking.

The Winter Bash is back and the hats are listed below.  As always, there are only two answers: one for the secret hats, and one for the regular hats. The secret hat list will be updated as we learn them.  Only edit the secret hat answer with definitive and correct triggers. This is not the place to post guesses.    If you'd like to discuss Winter Bash, hats or just have a question about the WB please come over to the .  Please keep the comments here clean. As always comments are not meant for discussion, conversation, "I just got hat X", etc use the  for that (the remaining meta mods will periodically clean the comments). I know you are excited you just got a secret hat, but please instead of posting a comment come over to the  and tell us all there.  Provided that "It's important to know your history... in more ways than one"  again this year, here are the hats from prior years:


No water comes out of my kitchen faucet when I turn it on. Every other water outlet in the house is working fine, and the kitchen faucet was working fine until the last time we used it (two days ago). There is no trickle, it just doesn't work. I turned to shut-off valves on and off completely but nothing happened.  It's a single handle faucet with a built in sprayer. I took off the handle and also looked under the sink to see if there is anything obviously wrong or broken but either there isn't or I don't understand enough to be able to tell.   I'm happy to take the faucet off to look deeper, but the problem is I don't know what to look for. I would love any advice about how to proceed before I call a plumber.

Yesterday, our kitchen faucet suddenly stopped working. Water pressure has always been fine, but now there is only a trickle. It's a single handle faucet and both the hot and cold will not work. I have a reverse osmosis water filter next to it that still works fine, and I know the shutoff valves are open. I cleaned the aerator and even took off the sprayer, and still very little water comes out from the hose, so I don't think it's a clogged sprayer.   Any suggestions?


I'm making a Discord bot in Python using discord.py. I'd like to set/modify a global variable from an async thread.  message = ""  @bot.command() async def test(ctx, msg):     message = msg   However this doesn't work. How can I achieve something that does this?

How can I create or use a global variable in a function?  If I create a global variable in one function, how can I use that global variable in another function? Do I need to store the global variable in a local variable of the function which needs its access?


It's well-known that $f'(x),f''(x)$ determine the monotonicity and the concavity of $f(x)$ respectively. Besides, we can see $f'(x)$ and $f''(x)$ from the graph of $f(x)$.  But how about $f'''(x)$ and other higher orderd derivative? What's its geometrical meaning on the graph of $f(x)$? Or, limited by our human-being's perception, we can't see high-orderd derivative?

(Originally  by AJAY.)  What is the geometric, physical, or other meaning of the third derivative of a function at a point?  If you have interesting things to say about the meaning of the first and second derivatives, please do so.


How do I install the  on Windows using TeX Live 2013? I am using pdflatex.

How do I install the  on Mac with MacTeX 2013 and Windows with TeX Live 2013? I am using pdflatex so   does not solve my problem.


Is there any field other than $\mathbb{F}_2$ which has $1+1=0$ ? My initial feeling was no but I don't know how to prove it. Can someone help ?

Is there any field of characteristic two that is not $\mathbb{Z}/2\mathbb{Z}$?  That is, if a field is of characteristic 2, then does this field have to be $\{0,1\}$?


The code is below -   for (let n = 1; n <= 100; n++) {   let output = "";   if (n % 3 == 0) output += "Fizz";   if (n % 5 == 0) output += "Buzz";   console.log(output || n); }   If I do not have let output = "" the code will not run.  Why is that statement required?

What is the scope of variables in javascript? Do they have the same scope inside as opposed to outside a function? Or does it even matter? Also, where are the variables stored if they are defined globally?


This question was featured on  and I haven't been able to find a proof. Can anyone help?

Possible Duplicate:          I once read that some mathematicians provided a very length proof of $1+1=2$.  Can you think of some way to extend mathematical rigor to present a long proof of that equation? I'm not asking for a proof, but rather for some outline what one would consider to make the derivation as long as possible.  EDIT: It seems the proof I heard about is a standard reference given here multiple times :) I stated that the proof itself is less useful than an outline for me as I know only "physics level maths". Can someone provide a short outline what's going on in the proof? Some outline I can look up section by section in Wikipedia to at least get a feel of what could be needed to make such a proof?


For a couple of months now the default Chrome web browser on my Android device has changed the way it displays tabs when thr Tabs icon is tapped. Previously it used to roll out all of my open tabs in mini windows that allowed me to preview the content of the webpage and also had the title of the tab at the top of the window.  Suddenly, however, this changed and at the moment whenever I tap the Tabs icon, I get a minimalistic, text-only list of the tabs:    According to some suggestions in different forums and articles, I tried to wait it out but nothing has changed for months now. I also tried clearing the cache, disabling the application and then enabling it again but nothing has helped.   Some sources say this was a bug in the Beta of a certain Chrome version but I am well past it, currently with Chrome 72.0.3626.96 and Android 8.0.0.  Any help would be appreciated.   Edit: Tabs are diaplayed the old way if I swipe down from the address bar on any tab, but this is not preferable to the normal single tap gesture. However, it is to show that the old way is still present but the functionality seems to be swapped.

I recently updated my Chrome for Android (currently on v68) and noticed that tapping on the box icon (next to address bar) gives a tab list instead of SystemUI type overview that Chrome used to give. See the two images below for comparison.  I know that I can get that same view by swiping downwards from the address bar but I'm habitual of getting it from that box icon.   So what can I do to get back that view from that box without reverting to a previous version of Chrome and without switching to an another browser (unless it is Chrome based)?


i install ubuntu few hour before, but i am unable to access hard drive. the message shown is given below- Error mounting /dev/sda6 at /media/jeetu/24386BED386BBD04: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000,dmask=0077,fmask=0177" "/dev/sda6" "/media/jeetu/24386BED386BBD04"' exited with non-zero exit status 14: The disk contains an unclean file system (0, 0). Metadata kept in Windows cache, refused to mount. Failed to mount '/dev/sda6': Operation not permitted The NTFS partition is in an unsafe state. Please resume and shutdown Windows fully (no hibernation or fast restarting), or mount the volume read-only with the 'ro' mount option.

Whenever I boot Ubuntu, I get a message that it cannot mount my windows partition, and I can choose to either wait, skip or manually mount.  When I try to enter my Windows partition through Nautilus I get a message saying that this partition is hibernated and that I need to enter the file system and properly close it, something I have done with no problem so I don't know why this happens.    Here's my partition table, if any more data is needed please let me know.     Device Boot      Start         End      Blocks   Id  System /dev/sda1            2048    20000767     9999360   83  Linux /dev/sda2        20002814   478001151   228999169    5  Extended /dev/sda3   *   478001152   622532607    72265728    7  HPFS/NTFS/exFAT /dev/sda4       622532608   625141759     1304576   82  Linux swap / Solaris /dev/sda5        20002816   478001151   228999168   83  Linux


In S07E07 "The Dragon and the Wolf" of Game of Thrones, while Jaime is preparing his troops to march to Winterfell, Cersei pulls him aside & tells him she means to double cross the rest. She has no intention of helping Dany & Jon.     Jaime says he made a promise to fight for the living & he intends to keep it & abandons Cersei. She calls it treason & nods to The Mountain to kill Jaime. He draws his sword & blocks Jaime's way.     Jaime calls out this bluff & walks away from her & The Mountain doesn't do anything. How did Mountain interpret Cersei intentions really. Cersei doesn't nod again for him to stop. He's supposed to be an undead mute.     Why didn't The Mountain enforce Cersei's order to kill Jaime?

Spoilers from the Season 7 finale of Game of Thrones, "The Dragon and the Wolf".  In one of the final scenes, Jaime and Cersei are discussing Jaime's future with them, at which point       Cersei nods her head, signaling the kill order for 'The Mountain', yet 'The Mountain' pulled out his sword but why didn't he kill Jaime?


I am sure this has something to do with my nodes... but I got the label to be transparent.. however.. it's making the actual object it's placed on transparent NOT the label itself.. I think. Please see picture.

I am trying to put a label over the transparent plastic bottle, but i was unable to do so, because when i build the bottle material(plastic) and mix it with the diffuse shader(using the label texture), the label gets faded. So the solution i found was to duplicate the bottle and scale a little bit and apply the label material on it. So it looks its the same material, but in reality its one material over the other. How can I make my plastic material be under my label material(image)? Here's how it looks:   Here's my material setting for the plastic bottle:   Thanks in advance.


When moderators delete a post, ordinary users .  When a question is dead or abandoned,  (RemoveDeadQuestions, RemoveAbandonedQuestions).  The Community♦ user has a ♦ and the capabilities of a moderator.  Does that mean that ordinary users cannot vote to undeleted such automatically deleted questions, or does this rule only apply to manually deleted questions by human moderators?

What circumstances can cause a question or answer to be deleted, and what does that actually mean?    How can a post be deleted? When can't I delete my own post? Can I still see my post even after it's deleted? Can I see a list of my deleted posts? How can I undelete one of my posts? What does deletion mean for a post? How do votes to delete work? What are the criteria for deletion? What else should I know about deleted posts? If I flag my question with a request to delete it, what will happen?       For more information, see the articles about  and  in the .


So I can do a Select Case in python with  if integer == 1:   case0() elif integer == 2:   case2() elif integer == 3:   case3() .... elif integer == N:   caseN()   Some times I use a list using the index as a selector.  selectCase = [case0(),case1(),case3(),...,caseN()] [N]   But this makes that each item in the list to be processed before selected right?  So I was wondering if there other ways to do this without spanning so much vertically to control what code is executed. Are there maybe ways to jump to parts of the code? Maybe I don't want to solve a function but just skip some lines.  Thanks

I want to write a function in Python that returns different fixed values based on the value of an input index.    In other languages I would use a switch or case statement, but Python does not appear to have a switch statement.  What are the recommended Python solutions in this scenario?


Is there a way to generate Javadoc comments in Eclipse? If so, what is it?

I have a large codebase without Javadoc, and I want to run a program to write a skeleton with the basic Javadoc information (e.g., for each method's parameter write @param...), so I just have to fill the gaps left.  Anyone know a good solution for this?  Edit:  JAutodoc is what I was looking for.  It has Ant tasks, an Eclipse plugin, and uses Velocity for the template definition.


I have an iPhone 4 with iOS 71. I can't install apps from app store because when tap on install button of any app then showing error message " you most be update your iso device 8.0 or later version and try again..."  What can I do to install Facebook etc.?

I have a 1st generation iPad and when I download apps it tells me “this requires iOS 6.0 or later” but when I go to update it tells me it's fully updated? Why is this happening, and is there any way I can fix it?


Is there any common method (usable in practice) for estimating the uplink capacity of switch based on known number of users connected to this switch and the maximum internet speed they are allowed.   This is an example topology:  core switch ==== aggregation switch ---- access switch 1 ---- 10 users                                   |----- access switch 2 ---- 30 users                                   |----- access switch 3 ---- 50 users   I want to find the needed capacity (or maximum traffic in the busiest hour) for the links between aggregation switch and access switches 1, 2 and 3. I know they will be allowed to have maximum internet speed of 50 Mbit/s and no transfer between users.  In the worst case they will all download at 50 Mbit/s, so 50 users * 50Mbits/s = 2500Mbit/s but this case will almost never happen as the traffic comes on bursts and it will be waste of resources.   So I need a general method, best practices or any guide for this job. All I find in the Internet is theory with almost scientific value, but no information how they do it in IPSs and telecommunication companies in practice.

This is a  about  Related:      I have a question regarding capacity planning. Can the Server Fault community please help with the following:   What kind of server do I need to handle some number of users? How many users can a server with some specifications handle? Will some server configuration be fast enough for my use case? I'm building a social networking site: what kind of hardware do I need? How much bandwidth do I need for some project? How much bandwidth will some number of users use in some application?


At 1 rep, a user can post, i.e. ask a question or post an answer to a question. They must earn sufficient rep to be able to comment.  Users with the association bonus get 100 points added, so a new user can post and comment.  Protected questions prevent users with only the association bonus from posting. They have to earn sufficient rep on that site. However, they are still allowed to comment, and post answers as comments, defeating the purpose of protecting the question.  Should protected questions block commenting with only the association bonus?

Questions are occasionally protected when they start attracting unwanted input -- because the question was on the Hot Network Questions list, because it hit Reddit, because it's about a hot-button topic that everybody wants to weigh in on... Protection allows a community to prevent some stuff that they would otherwise have to clean up later on a small number of volatile questions.  Currently you need 10 reputation earned on the local site to answer a protected question.  This proposal is to broaden the restriction to include comments.  Currently, anybody with 50 reputation can comment, so people with the association bonus but no local reputation can't answer but can comment.  That's kind of backwards; answers are first-class citizens, the stuff we want, and comments are meant to be disposable.  So if people in this group can't even answer, it's counter-intuitive that they should be able to comment.  This restriction should apply to comments on the question itself and on answers.  Further, questions that have gotten the kind of attention that leads to protection tend to attract more comments, sometimes .  For all practical purposes only moderators can remove comments or relocate them to chat; the community doesn't have the tools to do this effectively.  Note that this dovetails nicely with the general encouragement to take comment discussions to chat -- users with an association bonus can use chat, so this is a little more incentive to go there to discuss the question.  Perhaps the protection notice could even include a link to the site's main chat room.  Participants aren't turned away but redirected.  Most questions are not protected; people can participate normally on the vast majority of the questions on a site.  Protection is an exception, but when it's needed, there's usually a lot of action -- and in my experience on several sites, comments tend to be part of the problem.  The number of valuable comments that would be lost -- that is, requests for clarification or suggested improvements that nobody in the local community can offer -- seems small.  The number of...other...types of comments is much higher.


I got a new network card (Intel Wireless-AC 9260) for my Dell XPS 13 running Ubuntu 16.04. The problem is that the new network card is not working. The lshw command shows that it is unclaimed. The old network card is still working, when switching back.  I updated the kernel for the firmware and also tried a lot of other things suggested in other threads. What I notized is that when I use modinfo iwlwifi that the firmware of my card is not listed, but the files are in the lib/firmware folder. I do not know if this is the problem.  So I am glad for any help!  Also I post some command outputs requested in other threads in case they help.  uname -a:  Linux xxx-XPS-13-9360 4.4.0-174-generic #204-Ubuntu SMP Wed Jan 29 06:41:01 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux   sudo lshw -C network:  *-network UNCLAIMED             description: Network controller        product: Wireless-AC 9260        vendor: Intel Corporation        physical id: 0        bus info: pci@0000:3a:00.0        version: 29        width: 64 bits        clock: 33MHz        capabilities: pm msi pciexpress msix cap_list        configuration: latency=0        resources: memory:dc200000-dc203fff   modinfo iwlwifi:  filename:       /lib/modules/4.4.0-174-generic/kernel/drivers/net/wireless/iwlwifi/iwlwifi.ko license:        GPL author:         Copyright(c) 2003- 2015 Intel Corporation <ilw@linux.intel.com> description:    Intel(R) Wireless WiFi driver for Linux firmware:       iwlwifi-100-5.ucode firmware:       iwlwifi-1000-5.ucode firmware:       iwlwifi-135-6.ucode firmware:       iwlwifi-105-6.ucode firmware:       iwlwifi-2030-6.ucode firmware:       iwlwifi-2000-6.ucode firmware:       iwlwifi-5150-2.ucode firmware:       iwlwifi-5000-5.ucode firmware:       iwlwifi-6000g2b-6.ucode firmware:       iwlwifi-6000g2a-5.ucode firmware:       iwlwifi-6050-5.ucode firmware:       iwlwifi-6000-4.ucode firmware:       iwlwifi-7265D-13.ucode firmware:       iwlwifi-7265-13.ucode firmware:       iwlwifi-3160-13.ucode firmware:       iwlwifi-7260-13.ucode firmware:       iwlwifi-8000-13.ucode srcversion:     CB5AC244E1344F14798FC7E   ls /lib/firmware/ | grep 9260:  iwlwifi-9260-th-b0-jf-b0-33.ucode iwlwifi-9260-th-b0-jf-b0-34.ucode iwlwifi-9260-th-b0-jf-b0-38.ucode

since I bought my new laptop, with a wifi card Intel Wireless AC 9260, I cannot connect to any wireless network. When I choose the network to connect it tries to but at the end it displays a behavior like timeout connection. Any of you face a similar problem before? (Yes, I already did extensive searches looking for related problems but any solution worked).  Ps.: the wifi connection works fine in Windows.    Exit lspci  00:00.0 Host bridge: Intel Corporation Device 3ec2 (rev 07)     00:01.0 PCI bridge: Intel Corporation Sky Lake PCIe Controller (x16) (rev 07) 00:08.0 System peripheral: Intel Corporation Sky Lake Gaussian Mixture Model 00:14.0 USB controller: Intel Corporation Device a2af 00:14.2 Signal processing controller: Intel Corporation Device a2b1 00:16.0 Communication controller: Intel Corporation Device a2ba 00:17.0 SATA controller: Intel Corporation Device a282 00:1c.0 PCI bridge: Intel Corporation Device a290 (rev f0) 00:1c.6 PCI bridge: Intel Corporation Device a296 (rev f0) 00:1c.7 PCI bridge: Intel Corporation Device a297 (rev f0) 00:1d.0 PCI bridge: Intel Corporation Device a298 (rev f0) 00:1d.4 PCI bridge: Intel Corporation Device a29c (rev f0) 00:1f.0 ISA bridge: Intel Corporation Device a2c9 00:1f.2 Memory controller: Intel Corporation Device a2a1 00:1f.3 Audio device: Intel Corporation Device a2f0 00:1f.4 SMBus: Intel Corporation Device a2a3 01:00.0 VGA compatible controller: NVIDIA Corporation Device 1be0 (rev a1) 01:00.1 Audio device: NVIDIA Corporation Device 10f0 (rev a1) 6d:00.0 Ethernet controller: Qualcomm Atheros Device e0b1 (rev 10) 6e:00.0 SD Host controller: Realtek Semiconductor Co., Ltd. RTS5250 PCI Express Card Reader (rev 01) **70:00.0 Network controller: Intel Corporation Device 2526 (rev 29)**     EDIT 1:  output lspci -k  70:00.0 Network controller: Intel Corporation Device 2526 (rev 29) Subsystem: Intel Corporation Device 0014 Kernel driver in use: iwlwifi Kernel modules: iwlwifi   output uname -r  4.13.0-45-generic


I am asked to show that in a metric space the complement of any finite set is open. That means I have to show that finite set is closed. I just tried to cope up with this problem using closure definition but dont know whether my approach is correct or not.  I know that the union of $A$ and $A'$ (the set of all interior points of $A$) comes to be $A$ if I take $A'$ to be empty or $A'$ to be $A$, so that I get  (closure of $A$) $ = A$ and by using the statement (closure of $A$)$=A$ iff $A$ is closed, I get the proof done. My question is can I apply this definition here. Sorry if I am asking something weird. I am just asking whether or not should it is absolutely proper to use that specific definition, thats all. aso, I think my question has some additional questions about using the definition.

let $(X,d)$ be a metric space. How I can show that any finite subset of $X$ is closed.       Can a finite subset of $X$ be open ?     Definitions:   a set $F\subseteq X$ is closed (in$(X,d)$) if  $\bar F =F$. a set $U\subseteq X$ is open (in$(X,d)$) if  $U^o=U$


I'm not really that familiar with AC, I've just started talking about it in my classes. But from what I understand, one of its formulations is that it is possible to create a set made from choosing elements from a series (potentially infinite) of other sets.  Are we doing this in the Diagonal argument? We have a countably infinite number of sets (each with a real number) and we create a different one by choosing a digit from each of the subsets.  Is this correct? Or am I misunderstanding AC, making some other error?  EDIT: It seems that someone asked which axioms of ZF did the argument use and it got answered. My question then becomes: Why doesn't Cantor's Diagonal argument depend on the Axiom of Choice?

What ZF axioms does Cantor's diagonal argument require? Cantor's diagonal argument is often presented without reference to any of ZF axioms, so comes my question.  For this question, I will limit to the scope to uncountability of the set of real numbers.


I tried to search but couldn't find an answer to this. The problem seems to be very basic. I saw a question on SO and found that It's a duplicate of another question so decided to cast Close vote on it. While doing so I selected the reason as duplicate but I accidentally provided a wrong link. Now, when I click again, the dialog opens but there's no way to update the link. How should I do that?

I accidentally flagged  as a duplicate of , when I intended to flag it as a duplicate of . I am presented with the message "You have already flagged this post for moderator attention" whenever I try to replace the incorrect duplicate flag. Is there any way that I can fix this mistake, even though Stack Overflow is preventing me from fixing it?


I am trying to create a bulk action on recurring events. Isrecurrence2 field is not writable in the controller.  How to create recurring events in custom lightning pages.  The image is from my controller class. I want to set the field false intially.

Can anyone provide me sample apex code to create recurring event in salesforce.  I am using below code:  Event newEvent = new Event(); newEvent.OwnerId = '023170000004yO9AAI'; newEvent.Subject ='Test'; newEvent.WhatId = recordId; newEvent.IsRecurrence = true; newEvent.RecurrenceStartDateTime = System.today(); newEvent.RecurrenceEndDateOnly = System.today()+30; newEvent.RecurrenceType = 'RecursDaily'; newEvent.IsAllDayEvent =true; newEvent.DurationInMinutes =1440; newEvent.ActivityDate = yagyaPerformanceObj.Start_Date__c; insert newEvent;   I am using above code to create recurring event. My requirement is to create recurring event for 30 days which recurs daily. I am getting this error 'REQUIRED_FIELD_MISSING, Required fields are missing: [Recurrence Interval]: [Recurrence Interval]'  I don't know which field I am missing.


I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I have an equation like this:  $\cos(x) ^ {\sin(x)} = 1$  I thought I would solve it like this:  $\cos(x) ^ {\sin(x)} = 1$  $\sin(x) = \log_{\cos(x)}(1)$  $\sin(x) = 0 $  $x = 0+k\pi$  But I'm confused about the domain. I did $\log_{\cos(x)}(1)$ which should mean $(\cos(x)>0 \wedge \cos(x)\neq1)$  i.e $x\in(-\frac{\pi}{2}+2k\pi, 0+2k\pi) \cup (0+2k\pi, \frac{\pi}{2}+2k\pi)$ but then all the solutions of $x = 0+k\pi$ are invalidated. Is $\log_{\cos(x)}(1)$ always considered $0$ no matter the $x$?

Why must the base of a logarithm be a positive real number not equal to 1? and why must $x$ be positive?  Thanks.


On a button click, my page removes one form and replaces it with another using jQuery. When clicking submit on the second form, it does not execute the associated Javascript like it is supposed to.    Instead, it executes that /post route in Express, despite being overridden by the JavaScript. It's like the page does not know how to associate the form submission with the associate JS function, or something.  Here is what the HTML looks like once the first (working) form has been submitted and jQuery has done its magic:
    <form id="ex2"  method="post">

<input name="selected" type="radio" value="selected" /> Yes Please:

<input name="email" type="radio" value="yesemail" /> email:

            <button type="submit" class="btn btn-warning btn-lg text-center">Choose</button>

    </form>
   The JavaScript is unchanged the entire time. Here's the javascript for the second form submission:  $("#ex2").submit(function (e) {   //todo this code is never being executed   console.log("WAHOOO!!");   var formResult = $(this).serialize();   //client.publish('/foo', {text: 'channel2', form: formResult});   e.preventDefault();   return false; });   Hoe do I get the JavaScript to execut? It's a headscratcher.

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


I'm trying to make a page were you can see all the F1 drivers with there stats and there characteristics. With that last one I'm having some trouble...  Pilot.cs  public class Pilot {     public string SurName { get; set; }     public string FirstName { get; set; }     public TeamNames TeamName { get; set; }     public string Image { get; set; }     public int Podiums { get; set; }     public int Championships { get; set; }     public int GrandsPrix { get; set; }     public int Points { get; set; }     public Characteristic Characteristics { get; set; } }   PilotRepository.cs  public class PilotRepository {     protected static Pilot[] Pilots =     {         new Pilot         {             SurName = "Hamilton",             FirstName = "Lewis",             TeamName = TeamNames.Mercedes,             Image = "hamilton.jpg",             Podiums = 151,             Championships = 6,             GrandsPrix = 250,             Points = 3431,             Characteristics = Characteristic.WorldClass | Characteristic.Consistency | Characteristic.Veteran         },         new Pilot         {             SurName = "Bottas",             FirstName = "Valtteri",             TeamName = TeamNames.Mercedes,             Image = "bottas.jpg",             Podiums = 45,             Championships = 0,             GrandsPrix = 140,             Points = 1289,             Characteristics = Characteristic.WorldClass | Characteristic.Consistency | Characteristic.Veteran         }     };      public IEnumerable<Pilot> GetPilots()     {         return Pilots;     } }   Characteristic.cs  [Flags] public enum Characteristic {     [Display(Name = "World Class")]     WorldClass,     [Display(Name = "Future star")]     FutureStar,     [Display(Name = "Agressive driver")]     AgressiveDriver,     Consistency,     [Display(Name = "Crash master")]     CrashMaster,     Modest,     Veteran,     [Display(Name = "Epic battles")]     EpicBattles,     [Display(Name = "Early retirements")]     EarlyRetirements,     Overtaker,     Rookie,     [Display(Name = "Last of the pack")]     LastOfThePack }   Now when I show them in my views I only get the first and last one. Or in some cases I get totally different ones than the ones that I gave in. Anyone know what I'm missing here?

From time to time I see an enum like the following:  [Flags] public enum Options  {     None    = 0,     Option1 = 1,     Option2 = 2,     Option3 = 4,     Option4 = 8 }   I don't understand what exactly the [Flags] attribute does.  Anyone have a good explanation or example they could post?


I'm quite new to programming. I've recently made a simple snake game using python and pygame. Of course, I can play my game easily by running the .py script, but in wanting to share it with my less computer literate friends, I went on to try to figure out how to compile my code into a single .exe to make it easy for them.  I've tried py2exe and cx_Freeze, both giving me a dist or build directory with an .exe and several other files (dependencies). This does work, since I'm able to zip up the whole folder and distribute via .zip, but it's not ideal. I want to be able to wrap it all up in one file.   So I started googling 'how to compile python into a single exe'. However, unlike many of the programming problems I have tried googling before, I just can't get a straight, reliable answer. So far the most recent reliable answer I've tried gives me this setup.py script:  from distutils.core import setup import py2exe, sys, os  sys.argv.append('py2exe')  setup(         options = {'py2exe': {'bundle_files': 1, 'compressed': True}},         windows = ['snek.py'],         zipfile = None         )  # Python 3.4.4, py2exe 0.9.2.2; modules used: pygame, random   Still, it gives me a whole folder instead of a single .exe, which the program cannot run without.  So, I come to you, the all-knowing, the great, stackoverflow, with two questions.  Just in case I missed anything: how do you suggest I achieve my single .exe dream?  And: why the hell is this so difficult?

I thought I heard that  was able to do this, but I never figured it out.  Has anyone successfully done this?  Can I see your setup.py file, and what command line options you used?  Basically I'm thinking of it giving me a single executable file that does something like unzips itself to maybe /temp and runs.


I have a method, in my program which calls two other methods that both have a linear time complexity. I don't know for sure if this would cause the method to have a time complexity if O(2N).  I know that constants drop off of time complexity which would make the method's time complexity O(N), but I am just not 100% sure. Can someone please elaborate on what a method like this would have for a time complexity and how?

I'd prefer as little formal definition as possible and simple mathematics.


I've been a lurker (or consumer) of Stack Overflow for as long as I can think back (it definitely feels longer than the 12 years the site exists). During that time, I've often felt the impulse to add to what is already there. But apparently that will never happen. How will I ever earn the reputation that is needed for contributing if I may not contribute? And, duly noted, I will never gather the hubris to say "I've got a completely new question that was never asked before", and  beware much less will I claim to have an answer. No, I want to contribute in form of refinements, and the perfect way to do this would be comments. So tough luck, one less contributor, I guess I will stay consumer. Any thoughts? Bye

I am new to Stack Exchange.  Math and physics newsletters get to my inbox every Thursday, and every Thursday there are 5-day-old answers to questions as I read them for the first time.  Too often a question of interest  has already been closed because of the low quality of recent answers and comments.  I have no reputation, and to do almost anything requires more reputation than I have.  Nothing I have found in Help helps (however I noted one user submitted an "answer" because he said he did not have the reputation to comment.  I have started wondering if Joseph Heller is looking over my shoulder.  Any help, please?  Thank you to those who made useful suggestions.  The question, "How does a new user begin using Stack Overflow/Stack Exchange?," clearly expressed my difficulties.  I would close the question if I knew how.  Good night.


Well, what is the meaning of wave function? What does it represent? In Schrodinger's equation, we find the value of Ψ. But what is Ψ exactly? Max Born only gave an explanation of what $Ψ^2$ (the probability of particle with low mass enough to have an observable wavelength to be in a position in space). But no one knows what Ψ is.

The Schrödinger equation in non-relativistic quantum mechanics yields the time-evolution of the so-called wavefunction corresponding to the system concerned under the action of the associated Hamiltonian. And this wavefunction is, in general, complex, and its modulus squared yields the probabilities observed experimentally. Though, perhaps, this question has been asked many times, I am wondering if there is a direct physical interpretation - something that physically corresponds to - the wavefunction. Or is it just an intermediate calculational tool to arrive at the appropriate predictions for experimental outcomes, and nothing more? Of course, things like superposition and interference effects follow from the complex nature of the probability amplitude. So there must be something physical about it. What is it? Or are we not supposed to ask that question? Is it because the probability amplitude is complex that we have difficulty in relating it to something physical? Can we do quantum mechanics without complex numbers?


Question: Let $S$ be the set of stars in our galaxy. There is exactly the same number of subsets of stars in our galaxy as there are functions $f:S \to \{a,b\}$  .  My solution is; True.However, I'm confused with how to prove it. I know it can be proven by  using the formula of the number of elements in a subset and for the formula of the number of elements in a function and proving that both values are equal.   Can someone provide me with some feedback, please.

I am unable to understand this question. I have to say whether its true of false and then prove it but I can't proceed with the question unless I understand it.     Let $S$ be the set of stars in our galaxy. There is exactly the same   number of subsets of stars in our galaxy as there are functions   $f:S\rightarrow\{\alpha,\beta\}$


I often see comments like:     possible duplicate of XXXX May 27 '13 at 0:35   @abc Thanks, that's exactly what I was looking for.   The question is then left with 1 close vote.  When I review the question in the close queue, as the question has no answers etc and the “owner” has confirmed the “possible duplicate” is correct, I just vote to close as a duplicate without even checking if it is.   There must be a way to prompt the question owner to confirm the duplicate is correct and at least capture 1 close vote from the owner – maybe that vote should be binding, so that no one else need to close vote the given question.  Maybe there should me a message displayed only to the question owner at top of the question like.     This question may already have an answer here:   Grant the OP a binding close as duplicate vote in the new UI 3 answers   Does this fully answer your question? [Yes] / [No]   Perhaps, suggesting that the user can improve their question by providing additional details if they chose [No]. Maybe the question owner could also be given +2 rep in the same way as when they accept an answer.    I don't consider  to be a duplicate as I am asking a wider question,however some of its answers add to the discussion on this question.

Since the  to the close as duplicate mechanism it is a lot more visible to the OP that there is/might be a duplicate to their question. Empirically, I've noticed a lot more people agreeing, in the comments under their question, that their question is a dupe.   For instance, :        I'm aware that allowing  is  (back in the stone age) but now Stack Exchange is so much larger, and Stack Overflow is groaning under the weight of questions, I think this should be partially revisited.  Based on the principle that the simplest way to keep a site clean is to have as many people as possible nibbling away, I propose that the OP gets granted a binding close-as-duplicate vote.  It should simply be an additional line in the banner, which is . It might be something like this:     This question may already have an answer here:     "" 3 answers     Does this fully answer your question?  Yes / No   I'm not wedded to the Yes / No thing I just can't think of a better way at the moment.  Clicking on Yes would take the OP to the close as duplicate dialogue with that question highlighted. If there are multiple duplicate questions you'd need to ask the OP multiple times. A No could be used to track the relative success of the project, i.e.   Whether the question subsequently gets closed. Whether the question gets reopened again. How many times the OP actually clicks. How many times the OP disagrees with the analysis of the community.   Potentially, a No could be used to open a comment dialogue asking the OP to explain why they think their question is not a duplicate thereby stopping them simply putting "this is not a duplicate" in the question and formalising this process somewhat. Not sure about this idea...  I do not think this should be restricted by reputation, anyone should be able to close their own question as a duplicate. It gives people with lower reputation a more positive experience of the closing process and emphasises the importance of duplicate finding.  Most importantly, self-closes should not, initially, count towards the question ban. We can help new users learn how to use a lot more of the site than they might otherwise see and encourage them to search for duplicates more thoroughly. If the OP then goes on to do the same thing 10 times in a row then you can start using it toward the ban as they're obviously using the users as a personalised search service but at least the first 3-4 times this should not have any effect.  This question is, deliberately, only requesting 20% of the linked question (from 2009) and then only based on the new UI. The linked question asks for binding migration votes etc, which I do not want to see and I am not requesting a binding close-as-duplicate for the OP until someone else has already voted to close (though I think if the OP has 3k rep this might be allowable). This, I hope, addresses the concern's raised in the linked question and explains why this is not a duplicate of that question.


Is it right to say in an opinion essay, from an economical point of view? (with the final "al" in the word economical?)  Our English teacher claimed this to be wrong in class and that 70% of the students had this wrong in the essay. I wished to get this clarified from a native speaker because she insists that it is "economic" and not "economical"

What is the difference between "economic" and "economical"?


When I click a day column on reputation chart, events for a previous day are shown instead of events for the selected day. The column tooltip shows also previous day (the same for which events are shown), but shows total reputation for the selected day.    On the screenshot, you can see that I've clicked Jul 20, the tooltip shows July 19 and event list shows events for July 19 (30 total reputation, contrary to 90 total reputation for selected day - July 20).  Seen both on Stack Overflow and Super User.  Firefox 39.0 on Windows 8.1, if it matters.  I've seen this was reported 4 years ago already, but was fixed, so it looks like a regression.

So when we view reputation, there is graph view. However, it seems to be off by a day. Here's what I mean:   I'm sure 70 + 20 + 15 is not 15. Its 105, which is what we see below:   And 40 + 10 is NOT 105, unless you did  :)     Anyways 40 + 10 is 50:   So yeah. Did you do what that post on codegolf says? Devs better fix that :)


Consider a functions $f:\mathbb R\to \mathbb R$ such that  $f(f(x))=-x$ for all $x$.  It is shown in    ``f(f(x)) = − x, Windmills, and Beyond" by Martin Griffiths which appeared in Mathematics Magazine, Vol. 83, No. 1 (February 2010), pp. 15-23  that the set of discontinuities say $D_f$, must be at least countable. Can one obtain a good description of $D_f$? Can it be a Cantor set for example? It is known that $D_f$ is an $F_{\sigma}$ set. If  an $F_{\sigma}$ set is symmetric with respect to the origin and contains the origin, can it be equal to $D_f$ for such a ``windmill" function $f$?

I've been perusing the internet looking for interesting problems to solve. I found the following problem and have been going at it for the past 30 minutes with no success:     Find a function $f: \mathbb{R} \to \mathbb{R}$ satisfying $f(f(x)) = -x$ for all $x \in \mathbb{R}$.   I am also wondering, can we find $f$ so that is continuous?  I was thinking of letting $f$ be a periodic function, and adding half the period to x each time. I had no success with this, and am now thinking that such a function does not exist.  Source:


I have one line of html in a form on a JSP page like this:  <c:forEach var="entry" items="${set}">     <input type="checkbox" name="thing" value="${entry.key} ${entry.value}"> </c:forEach>   However, the space between the key and the value ${entry.key} ${entry.value} is lost when the form is submitted. I've tried using a \ before the , in that case both the \ and the  are still there when submitting.  It seems that Java EL does not preserve isolated spaces, is that right? If so, is there a valid workaround?  EDIT: This is so silly of me, many thanks to Cthulhu. But I still don't understand the behavior after adding a \. Why would that cause the space to show?

I'm really stumped on this one. I want to output a list and have the tag file take care of commas, singular versus plural, etc. but when I display the list it completely ignores whitespace so everythingrunstogetherlikethis. I tried using the HTML entities "thinsp", "ensp" and "emsp" (I can't use "nbsp", these have to be breaking), but they're all hideously wide on IE except thinsp which is way too skinny on everything else.  Edit:  won't work. The output from the tag has no spaces at all. Although any content in the JSP has normal spacing. Obviously I could just put everything in the JSP but this is code that goes on multiple JSPs, so tag files would make a lot of sense.


Why is standard deviation usually defined as sqrt(var(x)) and not simply as abs(X-u) while the latter is simpler to understand and both give same values?

In the definition of standard deviation, why do we have to square the difference from the mean to get the mean (E) and take the square root back at the end? Can't we just simply take the absolute value of the difference instead and get the expected value (mean) of those, and wouldn't that also show the variation of the data? The number is going to be different from square method (the absolute-value method will be smaller), but it should still show the spread of data. Anybody know why we take this square approach as a standard?  The definition of standard deviation:  $\sigma = \sqrt{E\left[\left(X - \mu\right)^2\right]}.$   Can't we just take the absolute value instead and still be a good measurement?  $\sigma = E\left[|X - \mu|\right]$


Is it OK to delete a question that didn't get much activity and post it again?  I've actually seen a user do this and gotten answer on third attempt.

I asked a question that has been marked as a duplicate. I read a lot of similar questions and explanations in advance but I couldn't find a solution. In the question that should answer my question the asker used a different (not working) approach. There is even an answer that would work for my case however I'd rather consider it as a workaround than a solution since I have seen examples using my approach.  So I would like your opinion in that case. Would it be ok to repost my question while explaining why other answers didn't help me? I edited my question but I think it's not getting any attention anymore. Naturally I will remove the old question.


Some easygoing sophomore undergrad level books will go well.

What are some interesting books for a sophomore undergrad about Atomic & Molecular Physics?


For Beta sites, it is not uncommon to get closed if they for example don't fullfill the desired activity criteria as explained in Stack Exchange blog post  (2012-04-24). My question is, can something like this happen to graduated Stack Exchange sites too, if for example their activity drops too much or does not grow fast enough? Are there other criteria or conditions that would make a graduated Stack Exchange site closable? If so, what are such close reasons? The only things apart from the (lack of) activity, which spontaneously comes to my mind, that could kick a graduated site out of its comfortable stable equilibrium is a drop in the quality of the content in the course of time, or that the site can no longer fulfill its mission as often stated in the "About" for some reason. But maybe there are other things I am not able to think of... If a graduated site is getting into serious problems, would Stack Exchange give them some timely warnings, such that people would have a fair chance of trying to solve the issues and avoid the site getting closed? Did something like this ever happen in the past?

I know that sites have two main stages once they leave Area 51: beta and graduated.  In order for a site to graduate from beta, it must meet a few requirements such as   A certain number of questions per day (10 I think) A certain number of users above a specific reputation level   However, I was wondering if a site that has graduated, Movies & TV for example, could be reduced back down to beta level if they drop below these requirements?


Practical, yet not code-related, questions about deep learning: where should they be posted? As far as I can tell, they should go either on  or on .

I'm currently working on many machine learning and computational algorithms, such as Singular Value Decomposition, Support Vector Machines, and others.  I'd like to ask questions about these topics, but I don't know which Stack Exchange website to use to post my questions.   Should I use ? Should I use ? Should I use ? Should I use ?   How do I tell?  What criteria do I use?


Having played chess on occasion I know the basic rules and moves to the game. However, it seems like a possibly wasted move when there are players who play a dominant game of chess and don't castle their king. Is castling a necessary move or is it more of a preference choice by the player?

I'm a chess beginner, and I was wondering: why was this movement introduced to chess, and why is it important to the game?


So I have my targets array which is a bunch of IP read from a file, now I am trying to cat a file that contains my IP and results from ssh command, ut because I am trying 3 different passwords on every target I will get 2 denials and one job scheduled result. So I figured, I will check if a job was scheduled for a particular result and I will print "$ip OK, if not then I will print "$ip failed" here is what I have : #!/bin/bash for ip in "${targets_array[@]}" do    cat "$output_file" | awk -v ip="$ip" '/$ip/&&/job/ {result="OK"} END {      !result?result="failed":result=result;}'  done   Pseudocode of what I am trying to do: 1.cat from output file line of the file where you can find desired ip and the word "job"  2.1. if you found it print append to a string variable "$ip OK" 2.2 if not found append to a string variable "$ip failed" 3. override output file with the result stored in the variable  but when I run it in debugging mode I see that the value was never passed to the awk script. How can I pass it? + awk -v ip= '/$ip/&&/job/ {result="OK"} END {      !result?result="failed":result=result;}'  the file I am cutting from: unwantedString 124.131.8010 Permission denied, please try again. unwantedString 125.124.90.134 Permission denied, please try again. unwantedString 145.120.100.8 Permission denied, please try again. unwantedString 145.101.100.158 Permission denied, please try again. unwantedString 124.131.80.2 Permission denied, please try again. unwantedString 125.124.90.134 job 32 at 2020-12-16 23:30 unwantedString 145.120.100.8 Permission denied, please try again. unwantedString 145.101.100.158 job 27 at 2020-12-16 23:30 unwantedString 124.131.8010 Permission denied, please try again. unwantedString 125.124.90.134 Permission denied, please try again. unwantedString 145.120.100.8 Permission denied, please try again. unwantedString 145.101.100.158 Permission denied, please try again.

Having the following in one of my shell functions:  function _process () {   awk -v l="$line" '   BEGIN {p=0}   /'"$1"'/ {p=1}   END{ if(p) print l >> "outfile.txt" }   ' }   , so when called as _process $arg, $arg gets passed as $1, and used as a search pattern. It works this way, because shell expands $1 in place of awk pattern! Also l can be used inside awk program, being declared with -v l="$line". All fine.  Is it possible in same manner give pattern to search as a variable?  Following will not work,  awk -v l="$line" -v search="$pattern" '   BEGIN {p=0}   /search/ {p=1}   END{ if(p) print l >> "outfile.txt" }   '   ,as awk will not interpret /search/ as a variable, but instead literally.


When a user votes to close a question as a duplicate an .  As soon as the question is closed, this comment is removed. (I am not sure what happens with the comment if the question is reopened or if the questions is never closed and the close votes are lost by "aging" or votes in the close-votes review queue. But I suppose that it is removed in these cases too.)  I think that this comment should be left there:   Some users might react to that comment explaining why, in their opinion, the question is not a duplicate. By removal of the comment the context of this discussion is lost.  If the question is reopened, it might be useful to keep the comment, so that the question is listed among linked questions. (Even if the choice as a duplicate was incorrect, it is probably still related to the other questions.) This would also help to keep the track of several closures of the same question (if it has been reopened).   (For the reasons I have mentioned above I usually post a link in a comment before casting vote to close; so that I know that comment with the link is not removed.)

A user just posted his question a second time here on meta after the first was closed as a duplicate. I wrote a comment on the second post, explaining that the answer to his question is in the linked duplicate and that he shouldn't circumvent the closure process by asking a second identical question.  When the second post was closed as a duplicate my comment was automatically deleted. As far as I understand this is a heuristic that removes obsolete comments, which it considers every comment that contains a link to one of the duplicates.  This heuristic is too aggressive and removes comments that go beyond "Duplicate here: link". I suggest that it should be changed to only remove the default duplicate comment, and not any comment that was edited by the owner nor any free-form comment that happens to include a link to the duplicate.  This also triggers for any comment that contains the word "duplicate" and link to any question, not only the question being chosen as duplicate, which makes this much worse.


i actually just started learning C++ and i was used to writing (var==0) like this in C but my C++ sir told me 0==var is more better way when i asked him why he told me you find out yourself so igoogled this thing but didnt find any info regarding this so im here to ask it anyone can help?

I noticed for a while now the following syntax in some of our code:  if( NULL == var){    //... }   or  if( 0 == var){   //... }   and similar things.  Can someone please explain why did the person who wrote this choose this notation instead of the common var == 0 way)?  Is it a matter of style, or does it somehow affect performance?


I'm writing a program for my school assignment using CardLayout() but I keep getting a null pointer error but I can't figure out why. Can someone please point out the error in my code. The code is incomplete but applet opens and displays buttons but not the card.  The error I get is when I press the Input button (so it's in the ActionListener):  Exception in thread "AWT-EventQueue-1" java.lang.NullPointerException     at BookCentre.actionPerformed(BookCentre.java:162)  //removed code since assignment is due in a week.

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Case I:   Here, a trajectory is placed stationary in the path of a planet's orbit. Now this trajectory has no mechanical energy to speak of. Now as the planet approaches the object the object comes under the influence of the planets gravitational field and moves towards it. Now what happens is, the object fall onto the planet and then I, standing on the planet's crust put a turbine down at exactly the point where the object's gonna fall, such that the object hits the turbine's blades and converts its K.E. to electrical energy which I store in a battery. Now my question is, where did this energy come from for the trajectory had none to speak of. Now you might say that the planet's in motion so it's the K.E. of the planet so consider Case II.  Case II   Two objects A and B are placed together in a vacuum such that their Gravitational Fields touch each other at a single point. In the beginning they had no mechanical energy to speak of, but as they enter each other's gravitational field they move and gain mechanical energy. Now after doing this I ask you the reader, have I created Energy out of nothing?  P.S. I am still in high school(1st year), so if this questions do seem childish do excuse me for my actions. Also try to explain your answers in a way I could easily understand them.  P.P.S. Is there an easier way to make diagrams besides Paint? I have been wasting a lot of time making diagrams.

I would like to know where gravity gets its energy to attract physical bodies?  I know that the law of conservation states that total energy of an isolated system cannot change. So gravity has to be getting its energy from somewhere, or else things like hydropower plants wouldn't be able to turn the power of the falling water into a spinning rotor.  Just to be clear, Lets create an example:  Lets say we have two objects with equal mass close to each other. So gravity does its job and it pulls each other closer, this gets turned into kinetic energy. This is where I'm lost. According to the law of conservation energy can't be created or destroyed and the kinetic energy comes from the gravitational pull so where does the gravitational pull gets its energy.  If that energy isn't being recycled from some where else then that means you have just created energy, therefore breaking the law of conservation.


I have old  laptop without working cd-rom and windows xp running. I need install Linux on it , some lightweight one, due of 512mb of RAM installed.  I have read  , but I havent another computer nearby, so I cant install Ubuntu via netboot/PXE.  Maybe there is another way to do this? And if so, what Linux distribution will be most suitable for such configuration(Pentium M 715 1.5 GHz, 512 MB RAM, 60 GB HDD)    thanx

Is it possible to boot a Toshiba Tecra A2 from a USB flash drive?  BIOS shows no boot option for USB. I haven't yet found any way to do it, but I might be missing some option.


Please pardon my english.  Here is my simple thought experiment.  In universe, there are two clocks A, B. B moved outward at the speed of light for 1 second at 00:00"   From clock A, I think it will say "00:01" and clock B will say "00:00". But, if the motion is relative, from clock B, the clock A probably moved outward at the speed of light so that after 1 second, clock B would say "00:01" and clock A would say "00:00". This contradicts the first guess.  I am sure I misunderstood the theory. Could someone help on this? Thanks.

Is this true or false: If A and B have clocks and are traveling at relative velocity to each other, then to B it APPEARS that A's clock moving slower, but A sees his own clock moving at normal speed.  Similarly, to A it APPEARS that B's clock is moving slower, but B sees his own clock moving at normal speed.  If the above is true, then both A seeing his own clock moving at normal speed and B seeing his own clock moving at normal speed means that in reality both clocks are moving at normal speed, and neither has slowed down, whereas the other person's clock APPEARING to move slowly is merely an illusion.   Now is this true or false: If A and B have clocks and are traveling at relative velocity to each other, then A sees his own clock move slowly (compared to the speed of the clock when A was at rest with respect to B) and B sees his own clock move slowly, so that in reality both clocks are moving slowly, but they still remain synchronized (since both are slow by the same amount)  If the above statement is not true, then why do muons decay slowly when moving fast? [it could only be possible if the muon saw its own clock as moving slowly. If we saw the muon's clock moving slowly, but the muon saw its own clock moving at the normal rate, then the muon would decay at the normal rate, and not slowly]  Can anyone please explain where I went wrong?


I am doing homework and I got stuck with my code.  The question is about two lists containing string letters in it as elements and  we want to know how many times the small text occurs in the long one.(with order)  Example:  long=['a','k','g','j','a','k','k','a','k','g']  small=['a','k','g']  then the answer should be 2 as it occurs twice(first and in the last part) As I tried:  def search(long,small):     words=[]     for k in range(len(long)):          for l in range(len(small)):                if long[k]==small[l]:                    words.append()                return(words)   First tried to write down the matches in the list and then divide the len of list to get the number. But unfortunatly this gives me the first match and i am not sure how to get all the matches. Hope you guys can help me.

This is a generalization of the "string contains substring" problem to (more) arbitrary types.  Given an sequence (such as a list or tuple), what's the best way of determining whether another sequence is inside it?   As a bonus, it should return the index of the element where the subsequence starts:  Example usage (Sequence in Sequence):  >>> seq_in_seq([5,6],  [4,'a',3,5,6]) 3 >>> seq_in_seq([5,7],  [4,'a',3,5,6]) -1 # or None, or whatever   So far, I just rely on brute force and it seems slow, ugly, and clumsy.


I'm using a loading screen in my winform application. So here I've    main form (frmBilling) splashscreen form (frmsplash) and a class splashWorker.cs   This is the splashWorker.cs  public class splashWorker     {        public event EventHandler<splashWorkerEventArgs> ProgressChanged;         public event EventHandler HardWorkDone;         public void DoHardWork()         {             for (int i = 1; i <= 100; i++)             {                 for (int j = 1; j <= 500000; j++)                 {                     Math.Pow(i, j);                 }                 this.OnProgressChanged(i);             }              this.OnHardWorkDone();         }          private void OnProgressChanged(int progress)         {             var handler = this.ProgressChanged;             if (handler != null)             {                 handler(this, new splashWorkerEventArgs(progress));             }         }          private void OnHardWorkDone()         {             var handler = this.HardWorkDone;             if (handler != null)             {                 handler(this, EventArgs.Empty);             }         }     }     public class splashWorkerEventArgs: EventArgs     {         public splashWorkerEventArgs(int progress)         {             this.Progress = progress;         }          public int Progress         {             get;             private set;         }     }   and now, This is the code in splash screen.(There is a progressBar(progressBar1) in this form.)   public partial class frm_splash : Form   {     private delegate void ProgressDelegate(int progress);      private ProgressDelegate del;     public frm_splash()     {         InitializeComponent();         this.progressBar1.Maximum = 100;         del = this.UpdateProgressInternal;     }     private void UpdateProgressInternal(int progress)     {         if (this.Handle == null)         {             return;         }          this.progressBar1.Value = progress;     }     public void UpdateProgress(int progress)     {         this.Invoke(del, progress);     } }   At last, this is the main form that I want to show after this splash screen loads.  public partial class frm_billingMain : Form {     private frm_splash splashScreen;     private bool done = false;              public frm_billingMain(string get_uid)     {         InitializeComponent();         this.Load += new EventHandler(HandleFormLoad);         this.splashScreen = new frm_splash();         c.uid = get_uid;     }     private void HandleFormLoad(object sender, EventArgs e)     {         this.Hide();          Thread thread = new Thread(new ThreadStart(this.ShowSplashScreen));         thread.Start();          splashWorker worker = new splashWorker();         worker.ProgressChanged += (o, ex) =>         {             this.splashScreen.UpdateProgress(ex.Progress);          };          worker.HardWorkDone += (o, ex) =>         {             done = true;             this.Show();         };          worker.DoHardWork();     }     private void ShowSplashScreen()     {         splashScreen.Show();         while (!done)         {             Application.DoEvents();         }         splashScreen.Close();         this.splashScreen.Dispose();     }   What is happens is , when I run the form , I'm getting an exception :     InvalidOperationException was unhandled.      "Cross-thread operation not valid: Control 'frm_splash' accessed from   a thread other than the thread it was created on."   This error was showing in ShowSplashScreen() in frm_Billingmain  private void ShowSplashScreen()         {             splashScreen.Show(); **//The exception is pointing here**             while (!done)             {                 Application.DoEvents();             }             splashScreen.Close();             this.splashScreen.Dispose();         }   I tried a lot to solve and nothing happens well. Any help will be appreciated.  Thanks.

I have a scenario. (Windows Forms, C#, .NET)   There is a main form which hosts some user control. The user control does some heavy data operation, such that if I directly call the UserControl_Load method the UI become nonresponsive for the duration for load method execution. To overcome this I load data on different thread (trying to change existing code as little as I can)   I used a background worker thread which will be loading the data and when done will notify the application that it has done its work.   Now came a real problem. All the UI (main form and its child usercontrols) was created on the primary main thread. In the LOAD method of the usercontrol I'm fetching data based on the values of some control (like textbox) on userControl.    The pseudocode would look like this:  CODE 1  UserContrl1_LoadDataMethod() {     if (textbox1.text == "MyName") // This gives exception     {         //Load data corresponding to "MyName".         //Populate a globale variable List<string> which will be binded to grid at some later stage.     } }   The Exception it gave was     Cross-thread operation not valid: Control accessed from a thread other than the thread it was created on.   To know more about this I did some googling and a suggestion came up like using the following code  CODE 2  UserContrl1_LoadDataMethod() {     if (InvokeRequired) // Line #1     {         this.Invoke(new MethodInvoker(UserContrl1_LoadDataMethod));         return;     }      if (textbox1.text == "MyName") // Now it wont give an exception     {     //Load data correspondin to "MyName"         //Populate a globale variable List<string> which will be binded to grid at some later stage     } }   BUT BUT BUT... it seems I'm back to square one. The Application again  become nonresponsive. It seems to be due to the execution of line #1 if condition. The loading task is again done by the parent thread and not the third that I spawned.  I don't know whether I perceived this right or wrong. I'm new to threading.  How do I resolve this and also what is the effect of execution of Line#1 if block?  The situation is this: I want to load data into a global variable based on the value of a control. I don't want to change the value of a control from the child thread. I'm not going to do it ever from a child thread.   So only accessing the value so that the corresponding data can be fetched from the database.


Hi guys,  I'm a bit stuck here.  The Select Tool doesn't seem to shrink or enlarge objects. I'm using Illustrator CS6. It only seems to just move it around.  Please help, thanks x

Why my selection tool doesn't rotate object? I selected the object and it doesn't work. How do I fix this?


Well, the title says it all:  Do you say "the lyrics of the song" or "the lyrics to the song"?   Is any of these wrong?  And why?

Do you remember the lyrics to the song?   Do you remember the lyrics of the song?      I'm more familiar with the second sentence using the "of". But what I don't know is, how would you interpret both of these sentences in the grammatical sense? Do both of these sentences express a relation between lyrics and songs?


I have a web document, https://example.com/page.html, where a javascript, like

As a webmaster in charge of a tiny site that has a forum, I regularly receive complains from users that both the internal search engine and that external searches (like when using Google) are totally polluted by my users' signatures (they're using long signatures and that's part of the forum's experience because signatures makes a lot of sense in my forum).  So basically I'm seeing two options as of now:   Rendering the signature as a picture and when a user click on the "signature picture" it gets taken to a page that contains the real signature (with the links in the signature etc.) and that page is set as being non-crawlable by search engine spiders).  This would consume some bandwidth and need some work (because I'd need an HTML renderer producing the picture etc.) but obviously it would solve the issue (there are tiny gotchas in that the signature wouldn't respect the font/color scheme of the users but my users are very creative with their signatures anyway, using custom fonts/colors/size etc. so it's not that much of an issue). Marking every part of the webpage that contains a signature as being non-crawlable.   However I'm not sure about the later: is this something that can be done?  Can you just mark specific parts of a webpage as being non-crawlable?


I'm having a tough time getting a handle on this one.    Background - I'm deployed, and have one Laptop with me running Kubuntu 13.10.    I need to do some recording, and would like to use Ubuntu Studio.  I was running a Live CD, but then started thinking about installing to a Flash drive, so, when I wanted to record, I just boot from the thumb drive and use that.  There seems to be some confusion... When I find articles, many are  centered around installing FROM a flash drive to a HD.  I came across a site - and a program called USB installer. It requires you have an ISO and a Flash drive - and it does the rest.    Did that, and when I booted from the drive, it came up with an  installer.  I'd like to install TO the flash drive - but - won't that leave a bunch  of install files ON the  flash drive I don't need?  Am I missing something?  Shouldn't I be running the install FROM the CD TO the Flash drive?  PS - I don't really care about saving anything to the flash drive - I'd  just like it to be 'updateable' and save settings.  Thanks in advance..

If you are hurrying to reply, System → Administration → StartUp Disk Creator -- no, that's not what I'm talking about.   I want to try Ubuntu 11.04's Unity without touching my existing Ubuntu install.  To do this, I need to install the nVidia drivers first (sigh).  To do this, I need changes to persist a reboot.  To do this, I need to really install Ubuntu on a USB key.  How do you do that?    What I tried   I tried to make a USB key from , then boot from it, then choose "Install Ubuntu." The installer refused to install to the installation media itself. I tried, from my installed copy of Ubuntu:  sudo kvm /dev/sdb --cdrom .cache/testdrive/iso/ubuntu_natty-desktop-i386.iso   ...but the installer didn't detect the disk properly.


I used the grid tool to create a grid of squares for a texture, but I'm seeing very clear fine lines rendering at the edges between some - not all - of the rows and columns.     Unfortunately, these lines also render in Chrome (haven't checked other browsers). The lines appear in different places depending on the size that I render the vector image, just as they change when I zoom in and out from the shape in illustrator. This feels like a sub-pixel rendering problem.  Is this a "necessary evil" when using vector? Or is there a solution?    I tried things that I thought might solve sub pixel rendering problems such as:   applying a very small CSS transform to the content.  applying a 0.1px CSS blur filter to the content.   But that doesn't get rid of or effect the lines in any way.

How can I align 2 paths perfectly? No matter what I do I get a little space (gap between the 2 paths I create, and they are straight lines not as I saw in other questions with pixel problems)  An example:    Between every triangle is a little space, like in the example. It isn't obvious and it doesn't bother, but if I use the image (as an SVG or something) it is really obvious.


I’ve recently been scouring my Finnish high school level textbooks and online physics forums for an answer to the following question: ”How is thermal radiation created on a molecular level?” or ”What thermal radiation actually is?” In some places I hear it being described as the motion of charged particles which leads to radiation, and in other places I’ve heard it being explained as the atoms getting excited by the heat. I’m not sure whether either of these are correct, whether they are synonymous nor whether they contradict one another. Help would be much appreciated, I am high school level in physics but would still like a ’deeper’ understanding on this subject. Thank you in advance.

By conservation of energy, the solid is left in a lower energy state following emission of a photon.  Clearly absorption and emission balance at thermal equilibrium, however, thermodynamic equilibrium is a statement of the mean behaviour of the system, not a statement that the internal energy is constant on arbitrarily short timescales.  The energy has to come from somewhere during emission, and go somewhere during absorption.  Energy in a solid can be stored as kinetic and potential energy of electrons and nuclei, either individually or in collective modes such as phonons and plasmons.  In thermal equilibrium energy will be stored more or less in various forms depending on the temperature and material.  However, even if most of the thermal energy in a particular solid at temperature $T$ is stored in the form of phonons, it could be that phonons primarily interact with light indirectly via electrons, e.g. a phonon excites an electron in a phonon-electron interaction, which can interact with light via the EM field.  Given that light is an EM field, it makes sense to me that it is emitted and absorbed by charged particles.  The electron-photon interaction is probably dominant for visible and ultraviolet light, given that metals are opaque, while semiconductors and insulators are transparent to (visible and UV) light with energy lower than their bandgap. However, once you get into energies in the IR and below, or X-rays and above, other mechanisms apparently take over.  For example, on the high-energy end of the spectrum I've heard that gamma rays can interact directly with nuclear degrees of freedom, which is reasonable considering that gamma rays are emitted during a lot of nuclear reactions.  A review of  might give clues to important light-matter interactions over a broad range of wavelengths.  Whether all of the these processes are involved in blackbody emission is a somewhat different question.  What physical processes mediate energy transfer during blackbody emission, and in which energy ranges are the various processes dominant?


I received a dataset containing some "XY" coordinates that are supposed to correspond to some locations in natural reserves/national parks in Costa Rica. I'm trying to use the proj4 package in R to try to convert these coordinates to lat/long (using the project(..., inverse = TRUE) command), but I cannot figure out which projection was used to get the XY coordinates, so I cannot invert the projection to get the lat/long. How can I guess which projection/coordinate system was used? A few points:   X,       Y 193087, 1056379 193587, 1056917 211524, 1032512 213201, 1032612

I have a Shapefile but its coordinate system is Unknown, and there is no *.prj file.   How can I identify it now?


I'm trying to prove the snake lemma for sheaves of abelian groups, namely:     If we have the following commutative diagram with exact rows:            Then we have an exact sequence:   $$0\to\text{ker}(f)\to\text{ker}(g)\to\text{ker}(h)\to\text{coker}(f)\to\text{coker}(g)\to\text{coker}(h)\to 0$$   The part $0\to\ker(f)\to\ker(g)\to\ker(h)$ is easily constructed from $i,j$ and it's easy to verify it is exact. Now let's call $\mathcal{F}'',\mathcal{G}'',\mathcal{H}''$ the presheaves defined by $U\mapsto \mathcal{F}'(U)/f(\mathcal{F}(U))$, $U\mapsto \mathcal{G}'(U)/g(\mathcal{G}(U))$ and $U\mapsto \mathcal{H}'(U)/h(\mathcal{H}(U))$, whose sheafifications are $\mathcal{F}''\to\text{coker}(f)$, $\mathcal{G}''\to\text{coker}(g)$ and $\mathcal{H}''\to\text{coker}(h)$ respectively. The presheaf morphisms $\mathcal{F}''\to\mathcal{G}''\to\mathcal{H}''$ are naturally induced by $i',j'$ and, using the universal property of sheafification, we get the following commutative diagram:        If I'm not mistaken, we can conclude $\text{coker}(g)\to\text{coker}(h)$ is an epimorphism directly by the fact that $\mathcal{G}'\to\mathcal{H}'$ is an epimorphism.   Now I'm stuck trying to proving that $\text{coker}(f)\to\text{coker}(g)\to\text{coker}(h)$ is exact and I have no idea how to build the connection map $\ker(h)\to\text{coker}(f)$.  Any ideas?

Suppose we have two short exact sequences in an abelian category $$0 \to A \mathrel{\overset{f}{\to}} B \mathrel{\overset{g}{\to}} C \to 0 $$ $$0 \to A' \mathrel{\overset{f'}{\to}} B' \mathrel{\overset{g'}{\to}} C' \to 0 $$ and morphisms $a : A \to A', b : B \to B', c : C \to C'$ making the obvious diagram commute. The snake lemma states that there is then an exact sequence $$0 \to \ker a \to \ker b \to \ker c \to \operatorname{coker} a \to \operatorname{coker} b \to \operatorname{coker} c \to 0$$ where the morphisms between the kernels are induced by $f$ and $g$ while the maps between the cokernels are induced by $f'$ and $g'$.  It is not hard to show that the morphisms induced by $f, g, f', g'$ exist, are unique, and that the sequence is exact at $\ker a, \ker b, \operatorname{coker} b, \operatorname{coker} c$. With the use of a somewhat large diagram shown , we can even construct the connecting morphism $d : \ker c \to \operatorname{coker} a$. However, I'm stuck showing exactness at $\ker c$ and $\operatorname{coker} a$. I thought Freyd might have had an element-free proof in his book, but it turns out he proves it by diagram chasing and invoking the Mitchell embedding theorem [pp. 98–99]. Is there a direct proof?


I read from  question how to obtain the median for a given dataset after calculating the product of the arrays.  However, in intend to find the product of each pair of corresponding cells that'll then be shown in a third column. The dataset I have is huge and I hope there is a faster way to do this than finding the product of each pair to add in the third cell.  Any help will be greatly appreciated.

I would like to multiply, row-by-row, two columns in an Excel sheet (in order to take the median of the resulting column).  1  3 2  5 4  2   Should become  3 10 8   How can I do that in a formula (i.e. without creating a separate column with the multiplication result)?


I am trying to get a tree like this using the tikz package  and the syntax for this, according to a manual, is \begin{tikzpicture}[mytree] \node (top) {DP} child {node {D\\the}} child {node {NP} child {node {Adj\\brown}} child {node {NP\\dog}}}; \end{tikzpicture}  However, just copying and pasting this code gives me  It seems that \\ is not recognized. Am I missing something here?

How can I insert a line break in a TikZ node? Simply putting \\ where I want the break doesn't work (see MWE).  Is there a way to make lines break automatically at some specified width?  And can I control the alignment of the text (left, right, centered, justified)?  \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node {First line\\second line}; \end{tikzpicture} \end{document}


When I run a latex file using Texmaker it generated extra files which are .aux, .log, .out, .bbl and .synctex.gz, how can i delete them so that my files will contain only .pdf and .tex.

Is there a way to make TeX delete files?   In my document a lot of auxiliary files are created and it would be wonderful to have them removed after their content has been used.


I have created one block by using view, which display author details on each node page,   Here is the link by which the block has been created,now i want to display total number of node  and total number of work viewed created by individual user on the same block which has been created above.    The way on this link is working fine for displaying all user but its not working after adding CONTEXTUAL FILTERS (nodes) Content: Nid | Aggregation setting by which this block will be able to display on each node.  Please suggest something.  Thanks

I created a view to show Users. These users can create nodes of the "Questions" content type.  The view has to render a table to show how many (the total number) Questions the user has created. Something like:  User +++ Questions created John --- 10 Ted  --- 4 Alf  --- 19


Knowing that we have the polynomial $f(x)=a(x-1)(x-2)\dots(x-101)$ with $1,2,\dots101$ it's roots , how do I determine the sum of the roots of $f'$? Yesterday on one of my posts I got an idea of explication but I didn't understand it . Is there a specific formula? Here you can find in the comments the answer , but I don't know how he got to it  ... is the one with the sum equals to 5100

I got this $$ f=a(x-1)(x-2)...(x-101) $$ knowing a and that $1 ,2 \ldots ,101$ are it's roots ... I need the roots of $f'$ , how should I do it ? More specifc how can I derivate a polynomial like that, is there a formula or something ?


I am an indian-citizen have got multiple visa for singapore valid upto April,2017. My daughter & son in law are staying there for last 4 yrs. I want to visit Singapore in Sept'16 at my daughter's placeand stay there for 30 days. Then from there I will visit to Thailand, stay there for 3-4 days only and want to come back from Thailand to my daughter's place again in Singapore. I will stay with my daughter for 30 days again and thereafter come back to my home land.  Please tell me whether it will be possible or not. Minm. how many days one has to move out from Singapore after 30 days and then again can re-enter for another 30 days stay.

I have multiple entry visit pass of Singapore valid for 2 year and normally they allow to stay for 30 days in a single visit. How many times I can do this if go out to my home country and come back again after 7 days? Is there any limitation on this ? Because it seems holder of the visit pass can stay in Singapore for more than 1.5 year if he/she use visit pass in this way.If we go by words it is multiple entry visa but, is it legal to do this or is it considered illegal?


Give a basis for  $(Col(A))\bot$ where $A$ is defined as follows:  $A =\begin{pmatrix}-1&3&1\\ 2&2&1\\0&8&3\end{pmatrix} -> \begin{pmatrix}1&0&1/8\\ 0&1&3/8\\0&0&0\end{pmatrix}$  My plan:   put matrix in a row reduced echelon form and create a basis for the nullspace:   $basis = \begin{pmatrix}-1\\-3\\8 \end{pmatrix}$   Then I wanted to find a vector that is orthogonal and has no 0 in it. I was thinking of $basis\bot = \begin{pmatrix}2\\2\\1 \end{pmatrix}$   this is apparently not a good way.  can someone help me and explain to me what steps I have to make. i choose for this one because $basis \cdot basis\bot = 0$  the given answer for this question is:$\begin{pmatrix}2\\1\\-1 \end{pmatrix}$   answer from the professor ( this question is an exam question):

I am trying to understand how to find the orthogonal complement of a subspace $M$ of a vector space $V$.   From my understanding, $M^\perp$ is also a subspace of $V$ where all its vectors are perpendicular (orthogonal) to the columns of $M$, which would mean that the dot product of those vectors with each column of $M$ is $0$.  However, how do I find the $M^\perp$ subspace, when $M = \{ \vec{x} \in \mathbb{R}:  2x_2 + 3x_1 = 0\}$? In general, if there's a general approach, how does one attempt to find $M^\perp$ of an arbitrary $M$?  From my understanding, in this case, $M$ is the set of vectors in a plane that satisfy that equation, where $x_1$ and $x_2$ should respectively be the first and second components of the vector $\vec{x}$.


I'm creating an array with nested arrays of arrays in which which all the elements are 1, such as:  [  [[1, 1], [1, 1]],    [[1, 1], [1, 1]]  ]   When I run the following code I expect to have changed only a single element to 555, leaving all others as 1.  mesh = [[[1] * 2] * 2] * 2 mesh[0][0][1] = 555 print(mesh)  # same as above but trying to access a different element mesh = [[[1] * 2] * 2] * 2 mesh[1][1][1] = 555 print(mesh)   So I want:  [[[1, 555], [1, 1]], [[1, 1], [1, 1]]] [[[1, 1], [1, 1]], [[1, 1], [1, 555]]]   Instead, I'm getting the following:  [[[1, 555], [1, 555]], [[1, 555], [1, 555]]] [[[1, 555], [1, 555]], [[1, 555], [1, 555]]]   So, not only does it not do what I expect, different code seems to produce the same output. Please explain why this is happening and, if possible, what code I should use instead. Thank you.

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


where is the type size_t  defined what are the other types like this , Is there a reference of the all the user defined  types and data structures in linux (gcc) . for example a reference guide on    sockaddr_in6   sockaddr_in  mm_struct  pci_dev   sk_buff    tq_struct   ...

I notice that modern C and C++ code seems to use size_t instead of int/unsigned int pretty much everywhere - from parameters for C string functions to the STL.  I am curious as to the reason for this and the benefits it brings.


Can I register a domain similar to my competitors and rank higher in google?  For example, my competitor uses competitorwebsite.com, can i use competitorwebsite.news and redirect it to my actual domain, so that i can come up in results for "competitorwebsite", "competitor website"?  I would like to mention that I DON'T want to mislead people to coming to my website.

What are the best ways to improve a site's position in the Google search results?


When I'm running games through Steam (for example Skyrim), I like to use my Razer USB headset and I would like to have devices such as Google Chrome or VLC etc. playing through my speakers at the same time.  Is there a way to set specific applications in Windows 7 to different output devices?   My current set-up allows everything through either the USB or through the speakers (setting them as default audio device),  I am running Windows 7 64 Ultimate and would love it if someone could come up with a solution for this speaker problem.

Anyone know how I can set for an application to output its audio to a specific device in Windows? I'm dealing with applications where it's not possible to go into their settings and choose which output device you want to use.


Is it possible to determine the calling method name "Eat Pizza" in PostError? I guess I could pass "EatPizza" as one of the arguments, but that would require changes each time the method name changes (unnecessary maintenance).  But then, I wasn't even able to find the method name "EatPizza" in the context of "EatPizza" (using stacktrace, getframe, getmethod).  public void EatPizza(Pizza p){     if(p==null){ //A arbitrary made up error         Utilities.PostError();     }     else{         p.Slices -= 1;     } }  ...  public void PostError(){     //Basically posting to database the name of the method     //Tried this, didn't work: (new StackTrace(true)).GetFrame(5).GetMethod().Name     //Is it possible to determine the calling method name "Eat Pizza" in this context? }   When I try different values (0 to StackTrace.FrameCount-1) in StackTrace.GetFrame, I get the following values, when I just want "EatPizza":  .ctor ThreadStart Main _nExecuteAssembly RunUsersAssemblyDebugInZone

When logging in C#, how can I learn the name of the method that called the current method? I know all about System.Reflection.MethodBase.GetCurrentMethod(), but I want to go one step beneath this in the stack trace. I've considered parsing the stack trace, but I am hoping to find a cleaner more explicit way, something like Assembly.GetCallingAssembly() but for methods.


The Lagrangian for the gravitational field in absence of matter is the following $$L=1/k\int dx^4 \sqrt g R,$$ where $k=\sqrt G$, $g$ is the determinant of the metric and $R$ the Ricci scalar. It's possible to fix a background metric like $\eta_{uv}$ and then study the perturbations $h_{uv}$ around it by $$g_{uv}=\eta_{uv}+kh_{uv}$$ The Lagrangian becomes $$L=L^{0}+kL^{1}+k^{2}L^{2}+.......$$ which can be interpreted as an effective field theory of self-interacting particles called gravitons. Now, given the transformation law of $h_{uv}$, how is it possible to say the entire Lagrangian is invariant, order by order, under local diffeomorphisms? Of course the symmetry is still there, but I was wondering if there is some kind of Spontaneus Symmetry Breaking associated with the perturbation field $h_{uv}$ and the diffeomorphisms group. The procedure resemble the SSB for the Higgs Boson, where the Lagrangian is $$L=\partial_{u}\phi\partial^{u}\phi - m^{2}\phi^{2}+\lambda\phi^{4}$$ This Lagrangian is invariant under parity in $\phi$, but after the redefinition around the vacuum $v$, the minimum of the potential, you deal with $\phi=v+\delta\phi$ and the Lagrangian in δϕ is no more parity invariant. Does this happen in the previous example after fixing a background?

I have read the following statement:      "The Einstein-Hilbert action can be seen as an effective field theory: setting $g_{\mu\nu}= \eta_{\mu\nu}+h_{\mu\nu}$, one gets a free Lagrangian for the field $h_{\mu\nu}$ plus interactions."   Now, how is it possible to define all the interaction terms?  EDIT: I ask apologize if my statement was appeared unclear: I have created a  which is more precise; please don't continue to consider seriously this one.