Different background or wallpaper per workspace Ubuntu 12.04

I am using ubuntu 12.04 with unity 2d. I want to change the wallpaper per workspace, i came across few gconf editor related tutorials but is it possible in any other way? Does unity have it built in or I will have to hack it from these tutorials?  I want it to work on both unity2d and Unity3d.


Placeholder text for Tag Input is cut off

I went to task a question on Arqade and notices that where you type the tags, the place holder telling you to type tags there has been cut off       OS: Windows 10 64-bit  Browser: Version 68.0.3440.106 (Official Build) (64-bit)  14/09/2018 9:03am AEST - also it appears that the resized image generation for uploaded images are not working but recall seeing this reported already


I know that $\cos x \leq (\sin x)/x \leq 1/(\cos x)$, but I need to prove this and I don't know how to do that. I've seen diagrams used to show the relationship, but can it be done without?


I want to compute the following integral to show that  $$ \int_0^\infty \left(\frac{1}{x}\right)^{\ln(x)}\,\mathrm{d}x=\mathrm{e}^{\frac{1}{4}}\sqrt{\pi}.$$ I have no idea where the $\sqrt{\pi}$ comes from.     Since the indefinite integral can't be evaluated with elementary functions I'm stuck.   I am just curious.


Rscript Path Problem for exec() implementation R code in php

I am trying to run a code of R in PHP, Here are my code : index.php         <title>PHP and R Integration Sample</title>
     <?php       // Execute the R script within PHP code       // Generates output as test.png image.       exec("Rscript sample.R");     ?>
      sample.R x <- rnorm(6,0,1) png(filename="test.png", width=500, height=500) hist(x, col="red") dev.off()  After that I found out that I got Apache Error like this : 'Rscript' is not recognized as an internal or external command, operable program or batch file.  I tried as the comments in this link , and then I updated my code : index.php         <title>PHP and R Integration Sample</title>
     <?php       // Execute the R script within PHP code       // Generates output as test.png image.       exec("C:\Program Files\R\R-4.0.3\bin\Rscript sample.R");     ?>
      After that update I got this message in apache : 'C:\Program' is not recognized as an internal or external command, operable program or batch file.  Anyone please tell me if I came wrong with interpreting the comments on the link I mentioned before. Please help me to implement R code in PHP, advise me for the best use case. Appreciate any answer.


can i use it for animals in the following sentece?  1- I have a dog named Don. It is a very good dog.  I know most people would use "he" instead of "it" in the following context and my grammar book says when we want to personified an animal we can use "he" or "they". But my question is, if I used "it" in the above, would that be grammatical?


Pre fill multiple paragraphs while adding node

I want to prefill multiple paragraphs when user click on "add node" for specific content type. What would be a good way to do this ?


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

How can I block specific telephone numbers on my iPhone? I don't want to get call from specific numbers. if anyone call to me from the blocked number, he should receive a message that "this number does not exist" or "this number is busy" always.


Official way to ask jQuery wait for all images to load before executing something

In jQuery when you do this:  $(function() {    alert("DOM is loaded, but images not necessarily all loaded"); });   It waits for the DOM to load and executes your code. If all the images are not loaded then it still executes the code. This is obviously what we want if we're initializing any DOM stuff such as showing or hiding elements or attaching events.  Let's say though that I want some animation and I don't want it running until all the images are loaded. Is there an official way in jQuery to do this?  The best way I have is to use <body onload="finished()">, but I don't really want to do that unless I have to.  Note: There is a  in Internet Explorer which actually does wait for all images to load before executing code inside $function() { }. So if you're using that platform you'll get the behavior I'm looking for instead of the correct behavior described above.


Someone asked a guy about something and I think the answer would be true or false, or yes or no, but the guy said, "That's track." What does it mean?


Is Souma Yukihara the 9th seat after defeating Akira Hayama?

I know that the first shokugeki between Souma and Eizan is not for 9th seat but for not Destroying Polar Star Dorm.   There is another shokugeki battle of Souma in Azami Administration Arc vs Akira Hayama.  On Chapter 190 - 191, Souma defeated Hayama. Does it reflect that yukihara now holds 9th seat of elite ten?


Trying to get the spacing right after an expanded sequence

I've defined  \newcommand{\foo}[1]{\textbf{#1}} \newcommand{\bar}{\foo{Bar}}   Now, when I compile  \bar tender --- tend your \bar.   I would like to get     Bar tender - tend your Bar.   but what I actually get is     Bartender - tend your Bar.   It seems that if I use \foo{Bar} directly, I get what I want.  How can I get the output I expect by changing the command rather than the invocation? I'd rather not use \xspace unless absolutely necessary.


What short story had a protagonist who was an orphan from a race of mimics?

With some catastrophe in his background, he arrives on a hot frontier world (requiring a survival suit?) populated by humans, to live with a kind, morally strong woman, who perhaps owns a bar (... or spacecraft repair shop?  I forget).    The kick is that his people cannot choose who they mimic, and do so unconsciously.  E.g., his shuttle was late and the woman's feet have become burnt through her boots from waiting for it; he doesn't realize he is copying her pained way of walking until someone rebukes him for it.  The tension ratchets up as the boy realizes there is a really nasty fellow populating their frontier community.  And a blind girl.  And he thinks he has begun to mimic someone but he can't yet tell who.


Add named colors after xcolor package clash

I created my LaTeX document using the xcolor package loaded like this  \usepackage[usenames, dvipsnames, svgnames, table]{xcolor}   Now I'm trying to put the document in the journal format and I get a package clash for xcolor so I ended up commenting the line above. The problem now is that all the colored names I use are no longer available. Is there a way to solve this issue before digging in color names and redefining the colors?


My USA Passport expires in April 2017 and I would like to renew but can't send my current passport due to imminent travel. Is it possible to keep you old passport while your new passport is being processed?  Can I apply at a passport facility?


Why can AB people receive blood from A, B or O?

AB people don't have agglutinins anti A or anti B so it might seem they can receive any type of blood. But if the donator is A for example, it's own blood will have agglutinins anti B that will agglutinate the AB blood. So why can AB people receive blood from non AB people?


Can somebody please give me good tips about how to write a high quality philosophy essay?

I am quite well read, and I understand the philosophy papers I read quite well. But I am a very sloppy writer. Whatever I write comes back with commentaries degrading my papers. What should I do to fix this problem?  I am a junior college student  The other question does not correspond to the details of my question  Thanks in advance!


How can I convert a DOM element to a jQuery element?

I am creating an element with document.createElement(). Now how can I pass it to a function that only takes a Jquery object?  $("#id")    I can not use it, as the element has not been rendered in the page yet.


What are the effects of adopting a patron deity later on?

I have a D&D 3.5e cleric with the Time and Travel bonus domains and no specific patron deity (bonus domains based on personal beliefs and inclinations). This cleric meets all of the requirements for becoming a Radiant Servant of Pelor except Pelor is not his patron deity yet (though his personal beliefs could align with those of clerics of Pelor rather nicely). If my cleric adopts Pelor as a patron deity now, what would that mean? And what would that mean for his current bonus domains?


java htmlunit button click doesnt work in for loop return NullPointerException

for(int i=0;i<=5;i++){             HtmlPage currentPage = (HtmlPage)client.getPage("http:// http://testsite.com ");             HtmlForm form = (HtmlForm) currentPage.getElementById("kelimeAraID");             HtmlButton button = (HtmlButton) form.getElementsByTagName("button").get(0);             HtmlTextInput kullaniciAdi= form.getInputByName("kelime");             kullaniciAdi.setText(arrayList.get(i));             HtmlPage sayfa2= button.click();             HtmlTableRow tr=(HtmlTableRow)sayfa2.getFirstByXPath("//*[@id=\"hor-minimalist-a\"]/tbody/tr[1]");             System.out.println(arrayList.get(i)+":"+tr.asText()); /*line:95*/             client.closeAllWindows();         }   Exception in thread "main" java.lang.NullPointerException     at htmlunit.HtmlUnit.main(HtmlUnit.java:95)


Best approach to store and match multiple data set against another set

I am developing a match making system where a user has certain data associated with his profile information. he has set of preferences to match against other users in the system. I am in search for better approach to save data and apply search. I can explain with an example: I have an education field in the profile. I can set in preference, multiple education either in 1) single column as comma separated values or in 2) multiple rows . This value in education can be matched aginst other user's education in profile data.   Which method should be the better one from the above scenario in terms of speed, performance, stability?  Is there any other good approach.  I have more than 20 fields like this to match and expecting over 100k user profiles in the system.


I am confused with both the C# version and .NET framework version. In other words, I want to know the relationship with C# version and .NET framework. E.g: which is C# version in .NET framework 3.0?


Prove the inequality by induction: $3^n > n^3$ for $n\ge4$

Prove the inequality by induction:  $3^n > n^3\ $ for $\ n \geq 4$  Edit:  1) Base case: $n=4$, $3^4>4^3, 81>64$   2) Assume true for n=k: so $3^k>k^3$ 3) Consider $(k+1)^3$, $(k+1)^3 = k^3 + 3k^2 +3k + 1 < k^3 + k^3 + k^3$, i.e. $(k+1)^3 < 3k^3$  For $k \geq 1$, $3(3^k) \geq 3(k^3)$, therefore $\ 3^{k+1}>3k^3>(k+1)^3$  And nowhere has the fact that $k \geq 4$ been used.., so I don't think this a complete, or at all a proof by induction of that inequality


Can anyone help me with next step? I'm already at this step, how should I change this to solve the problem when $a_n$ is grater than $1$?


Relationship between SVD and PCA. How to use SVD to perform PCA?

Principal component analysis (PCA) is usually explained via an eigen-decomposition of the covariance matrix. However, it can also be performed via singular value decomposition (SVD) of the data matrix $\mathbf X$. How does it work? What is the connection between these two approaches? What is the relationship between SVD and PCA?  Or in other words, how to use SVD of the data matrix to perform dimensionality reduction?


Restore database from backup file of different version / edition

I read that it's possible to restore a database in SQL Server as long as you're restoring from an older version to a newer version, for backwards compatibility reasons.  Does anyone know off hand if you can restore a database from a *.bak file for different editions of SQL Server?  We are moving a very large database via FTP that will take a couple days, so we'd rather only do this once. If nobody responds by the time we transfer the database via FTP, we will obviously try this out and see if it works by testing, and answer our own question.  Below is a query to get version details of SQL Server.  The productversion is in the format {major revision}.{minor revision}.{release revision}.{build number}.  In my case, the {release revision} has a value of 5500 for the source and 5512 for the target.  So that looks okay. However, the edition is different.  Query:  SELECT    SERVERPROPERTY('productversion'),    SERVERPROPERTY('productlevel'),    SERVERPROPERTY('edition')   Source database:  10.0.5500.0 SP3 Developer Edition (64-bit)   Target database:  10.0.5512.0 SP3 Enterprise Edition (64-bit)


I have been struggling with this all day-long and can't find a suitable method yet. I defined my arrays as follows:       public String month()     {         return birth.substring(3, 5);      } public int beers()     {     return nbBeer;     }   Then I put this in my public class      static int julyBeer(Personne[] perso, int nbElem)                 {                     int i;                     int k = 0;                     for(i=0; i < nbElem; i++)                         if(perso[i].month() == "07" && perso[i].beers() >= 1)                             k++;                     return k;              public static void main (String[] args){               Personne[] pers = { new Personne("10/07/1999", 3), new     Personne("19/02/1993", 2), new Personne("22/10/1988", 5), new         Personne("10/06/1994", 4),  new Personne("02/07/1990", 2)};  int nbElem = pers.length;     int beerMin = 1;  System.out.printf("Beer in July: %d", julyBeer(pers, nbElem));                 }     }   And the outcome is:  Beer in July: 0, and it's supposed to return 2.


Prove that $\sqrt{3}+ \sqrt{5}+ \sqrt{7}$ is irrational

How can I prove that $\sqrt{3}+ \sqrt{5}+ \sqrt{7}$ is irrational?   I know that $\sqrt{3}, \sqrt{5}$ and $\sqrt{7}$ are all irrational and that $\sqrt{3}+\sqrt{5}$, $\sqrt{3}+\sqrt{7}$, $\sqrt{5}+\sqrt{7}$ are all irrational, too. But how can I prove that $\sqrt{3}+ \sqrt{5}+ \sqrt{7}$ is irrational?


Is 512 bits a more secure hashing than 256 bits?

I know that 512 bit hashing is more secure, but I don't really know why. I hope someone can help me to better understand it in more detail.


How to avoid ISOTrigger: System.LimitException: Too many SOQL queries: 101

I received the following error:     Error: Invalid Data.    Review all error messages below to correct your data.   Apex trigger ISOTrigger caused an unexpected exception, contact your administrator: ISOTrigger: System.LimitException: Too many SOQL queries: 101   In the debug log I've found the following:  15:11:56.0 (762902111)|SOQL_EXECUTE_BEGIN|[94]|Aggregations:0|SELECT Id, OwnerId, IsRecurrence, RecurrenceActivityId FROM Task WHERE (IsClosed = FALSE AND (IsRecurrence = TRUE OR RecurrenceActivityId = '') AND AccountId = :tmpVar1) 15:11:56.0 (762942801)|EXCEPTION_THROWN|[94]|System.LimitException: Too many SOQL queries: 101 15:11:56.0 (763220286)|FATAL_ERROR|System.LimitException: Too many SOQL queries: 101  Class.AccountHandler.beforeUpdate: line 94, column 1 Class.TriggerFactory.execute: line 95, column 1 Class.TriggerFactory.createHandler: line 29, column 1 Trigger.AccountTrigger: line 3, column 1  15:11:56.0 (763234604)|FATAL_ERROR|System.LimitException: Too many SOQL queries: 101   Here is the code in method beforeUpdate and AccountHandler class:  public void beforeUpdate(SObject oldSo, SObject so) {     for(SObject bu :Trigger.new) {        Account a = (Account) bu;         List<Task> tasksFromDatabase = new List<Task> ([SELECT Id, OwnerId, IsRecurrence, RecurrenceActivityId FROM Task WHERE IsClosed=false AND (IsRecurrence = true OR RecurrenceActivityId = '') AND AccountId = :a.Id]);         String agentName = a.Agents__c;        String recruiterName = a.Recruiter__c;//TO DO ::: delete, not used         if(agentName != null) {            List<ISOs__c>isoName = [SELECT Name, Recruiter_ID_num__c, Active__c FROM ISOs__c WHERE Id IN (SELECT ISO_Company__c FROM Agent__c WHERE Id = :agentName)];            if(isoName.size() > 0) {                if(isoName[0].Active__c == false) {                    a.ISO_Name__c.addError('The selected agent is linked to an inactive Iso');                }             a.ISO_Name__c = isoName[0].Name;            a.ISO_recruiter_id__c = IsoName[0].Recruiter_ID_num__c;            }        } else if(agentName == null) {            a.ISO_Name__c = '';            a.ISO_recruiter_id__c = '';        }         for(SObject sob :Trigger.new) {            Account ab = (Account) sob;            Account oldAB = (Account)Trigger.oldMap.get(ab.id);            if (ab.Status__c != null && oldAB.Status__c!=null) {                       if(ab.Status__c != oldAB.Status__c) {                       statusmail mail = new statusmail();                    mail.setAccountInfo(ab);                    mail.SendAccountEmail();                                if(ab.Agents__c != null)                        mail.sendAgentEmail();                    if(ab.Recruiter__c != null)                        mail.sendRecruiterEmail();                }            }        }            } }   Please advise how to avoid this error?


Can I play my Minecraft worlds from my Switch on Pocket Edition?

I have a Nintendo Switch Minecraft world with my friends and got Minecraft Pocket Edition to play on the go. I signed in to the same account but there is no sync old worlds button on the mobile app. I couldn't find how to do it anywhere online either. Does anyone know how to transfer Switch worlds to PE or tell me if it's even possible, please?


how to evaluate this definite integral $\int_0^\infty\frac{\sin^2(x)}{x^2}dx$?

For $\int_{0}^{\infty}\frac{\sin^2(x)}{x^2}dx$. I considered using residue theorem. But since the function inside is holomorphic except for a removable singularity at the origin. So whatever contour I take, the integral would always be zero. Is there a way that we can get away with the situation and apply residue theorem to do the work?


I was doing my report, and I face to some problem with typewriter font; it was not adjusted to the text width. I don't find any related answer or topic.  Here's my MWE:  \documentclass[12pt,a4paper]{article}  \usepackage[spanish,es-noshorthands]{babel} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{mathptmx}  \usepackage[title]{appendix}  \usepackage{pdflscape}  \begin{document}  \section{New Story}  A written line  \section{Another}  \begin{itemize} \item Blah blah blah blah blah blah blah blah blah blah blah  blah blah \texttt{RegistroSismico.xls}, blah blah. Blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah. \end{itemize}  Blah blah blah blah blah blah blah blah blah blah blah  blah blah \texttt{RegistroSismico.xls}, blah blah. Blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah. Blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah. Blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah  \end{document}


Received an email saying someone has hacked my email account

I received an email saying that someone has hacked my email over 6 months ago and they say that through it they have infected my operating system with a virus. They say they have access to all my accounts, browsing history, photos, files on my computer, they also said that they have taken screenshots through the camera on my device.  Is this at all possible? I do have a computer that I use occasionally but mainly go through my iPad or iPhone.


Create a list inside a tuple inside a list of all numbers paired with an integer

I have a list like this:  [(0, 1), (0, 2), (0, 3), (1, 4), (1, 6), (1, 7), (1, 9)]   That I need to convert to a tuple that looks like this:  [(0, [1, 2, 3]), (1, [4, 6, 7, 9])]   This is the code I have:  friends = open(file_name).read().splitlines() network = [] friends = [tuple(int(y) for y in x.split(' ')) for x in friends] return friends


Is there a maximum size limit for valid housing?

I'm having an issue with my house after 1.2 and after researching any changes that may have been made My house is still invalid. It's all made out of stone and I've never had an issue like this before.  My houses before 1.2 have been much bigger and much smaller but were always valid    Is there a size limit to how large a house can be?  I tried adding a row of stone from where the corner torch above the door is to the other side but still said not valid.  EDIT:  It seems I did reach some size maximum in the previous picture, but the one below shows that its suitable and the guide moved in.


ever since updating my mac to high sierra my kernel_task has been using way too much RAM up to 1gb (i have 4 gb of RAM).  Any solutions on how to resolve this?


How does one interpret the last two symbols/letters "E4" in an arithmetic mean?

In SPPS, how does one interpret the last two symbols/letters 'E4' in an arithmetic mean? For example, mean monthly family income is shown as 3.79E4. What does E4 symbolise? How can we interpret it?


JAVA | Thread.sleep() error / Nullpointer

I am sorry I am beginner in java. For my little adventure game that I am working on, I want to add an delay in my gameLoop actully for testing my graphics.   The problem is I have an loop where the things get printet/paintet on screen (call it how u want :D). When I do that usual I have no problems, but when I add a Thread.sleep (with throws or try&catch) I get an NullPointerExeption somewhere in my program wich has nothing to do with that part here is my code:  GUI CLASS:  package xxx.yyy.zzz;  import java.awt.Graphics;  import javax.swing.JFrame; import javax.swing.JPanel;  public class GUI extends JPanel {  private JFrame frame; private Control ctr;  final int objectSize = 10;  public GUI() {     frame = new JFrame();     frame.setVisible(true);     frame.setSize(800,500);     frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);     frame.setLocationRelativeTo(null);     frame.add(this);     ctr = new Control(this); }  public static void main(String[] args) {     new GUI(); }  public void paintComponent(Graphics g) {     super.paintComponent(g);     for(int x = 0; x < ctr.getScreenSizeX(); x = x + objectSize) {         for(int y = 0; y < ctr.getScreenSizeY(); y = y + objectSize) {             g.setColor(ctr.getScreen(x/objectSize, y/objectSize));             g.drawRect(x, y, objectSize, objectSize);             g.fillRect(x, y, objectSize, objectSize);         }     }    } }   CONTROL CLASS:  package xxx.yyy.zzz;  import java.awt.Color;  public class Control {  private GUI gui; private Level l1;  private Color[][] screen; private Player player;  private final int screenSizeX = 400; private final int screenSizeY = 300;  public Control(GUI pGUI) {     gui = pGUI;     l1 = new Level(400, 30, true);     screen = new Color[screenSizeX][screenSizeY];     player = new Player(Color.WHITE);      gameLoop(); }  private void gameLoop() {      print(l1);      for(int i = 0; i < 100; i++) {         player.move(1);         print(l1);          try {             Thread.sleep(100);                      //here is my problem!         } catch (InterruptedException e) {             // TODO Auto-generated catch block             e.printStackTrace();         }     }  }  private void print(Level pL) {     if(pL.getSizeX() > 40 || pL.getSizeX() > 40) {         for(int x = 0; x < 40; x++) {             for(int y = 0; y < 30; y++) {                 screen[x][y] = pL.getObjectColor(x + (player.getX() - 10),  y);             }         }     }      else {         for(int x = 0; x < 40; x++) {             for(int y = 0; y < 30; y++) {                 screen[x][y] = pL.getObjectColor(x, y);             }         }     }     gui.repaint(); }  public Color getScreen(int x, int y) {     return screen[x][y]; }  public int getScreenSizeX() {     return screenSizeX; }  public int getScreenSizeY() {     return screenSizeY; }  }   I censored my package xD  Thank you for your replies, sorry I am not familiar with game programming and programming beginner!  EDIT: My Error Log:  Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException  at com.zeptosi.snogg.GUI.paintComponent(GUI.java:31) ...


wpf detects if another software is opened

I have a WPF program that needs to detect if another software is opened or not. If it is opened, my program will connect to it automatically:  private void Window_Loaded(object sender, RoutedEventArgs e) {     if(!DataModel.IsConnected)     {       connect();     } }   However, in this way it can only build connection when that software is opened before I run the WPF window. If I want the WPF program can always detect if the software is open - even if the software is opened after I run the WPF window.


Alphabetically display the items in itemize

I am wondering whether it is possible to display the items alphabetically regardless of the order we type on the backend? For example I am using itemize as follows:  \begin{itemize}     \item ISDYNSTP:  Is dynamic time step used?     \item ISCDCA:     \item MVAR     \item IS2TL_ \end{itemize}   But I want to display the items in the alphabetical order. I don't know whether it is possible or not. I have like hundreds of itemize items. Actually I am trying to create a glossary for the different parameters.


Separatedness of morphisms from separated scheme

A scheme $X$ is separated if the canonical morphism $X\rightarrow\operatorname{Spec}\mathbb{Z}$ is separated.  Is it true that if $X$ is separated, then every morphism $X\rightarrow Y$ is separated?   Apologies if this is obviously true or false; being new to schemes I have little intuition how to prove such a thing or how to construct a counterexample.


What are the "Bad Things," if any, associated with the declined flag count?

Premise  There should be an FAQ that addresses the consequences (if any) of a high "declined flag" count or a low helpful:declined ratio.  Analysis  There are a LOT of questions on meta surrounding flags--way too many to link meaningfully here. However, most of them boil down to a few things:   A policy of "flag stuff, and let the moderators decide." Questions about why flags are accepted, declined, applied, or counted.   Assuming that #1 is the de facto policy, it seems to me that a lot of the reluctance of users to make constructive use of the flagging system for reducing comment noise has to do with the mystery surrounding the utility value of the "declined flag count."  This counter (whatever it's called internally; I don't know) gets incremented whenever a flag is declined. This counter outlives the comments and posts that feed it, so it never goes down. Perhaps that's all as-designed.  The real issue is that the utility of this metric is not formally defined anywhere. From a psychological standpoint, I--and probably many other people--tend to assume that:   A high declined flag count is a Bad Thing. A low helpful:declined ratio is a Bad Thing.   Note that "Bad Thing" is deliberately undefined here. It may be one or more of:   social standing perceived reputation flag weight moderator disapproval likelihood of penalty downvotes likelihood of future flags being declined without regard to merit fear of the unknown X-factor involved   Whatever the reason, I think the solution is really simple: an FAQ answer that explains what impact this counter has and why it's tracked, and takes the time to address the potential "Bad Things" as thoroughly as possible whenever they're raised as concerns.  Reformulation into Q&A Format  This is really a four-part question, but the issues are too interrelated to merit asking them as separate questions. The central question is:     What is the utility of the declined flag count?   The sub-questions are:   Is a high declined flag count a Bad Thing? Is a low helpful:declined ratio a Bad Thing? If the count doesn't affect anything, why is it tracked? How will the count affect the user's experience within the Stack Overflow community?


Show $\lim \limits_{n \to \infty} \frac{a_{n+1}}{a_n} = \|f\|_{\infty}$ for $f \in L^{\infty}$

I have a question that I need help with getting started (possibly I would be back for more help).     I have a measure space $(X,A,\mu)$ that is finite, and $f \in L^{\infty}(\mu)$. Also, defined is $a_n = \int_X\,|f|^n\,d\mu$. I need to show that the limit is: $$\lim_{n\to\infty}\,\frac{a_{n+1}}{a_n} = \|f\|_{\infty} .$$   I am stuck on getting started, anybody have any suggestions?  thanks much


Software is installed, but "which" returns "not found"

I'm trying to work with the statistical package R. R is already installed. sudo apt-get install r-base-dev returns: "r-base-dev is already the newest version (3.4.3-1xenial0). 0 upgraded, 0 newly installed, 0 to remove and 23 not upgraded." However, which R gives me "R not found".  Now, how can I locate R? Is it really installed?  (Ubuntu 16.04)


How to upload image with a specific row [id] with form AJAX PHP

I am writing a code for image upload and want to implement AJAX for real time preview. As I have to upload an images with a specific row[id] and  image file to upload in respective directory eg (images/).  My code is only working when inserting data in database with this code below.  function add() { var valid = validate(); if(valid) {     $.ajax({         url: "add.php",         type: "POST",         data:  {image:$("#add-image").val(),fname:$("#add-fname").val(),image_text:$("#add-image_text").val(),address:$("#address").val(),price:$("#price").val(),contact:$("#contact").val()},         success: function(data){ getresult("getresult.php"); }        });     } }   My problem is I am trying to insert image file to specific folder and into database with id,fname,image_text,etc...How do I go about changing this{image:$("#add-image").val(), so that i can upload into database to folder target.  Please help me out and provide solution.  Below is the code -  <form name="frmToy" method="post" action="" id="frmToy">
     Name
     <input type="text" name="image" id="add-image" class="demoInputBox">

     Name
     <input type="text" name="fname" id="add-fname" class="demoInputBox">

     image_text
     <input type="text" name="image_text" id="add-image_text" class="demoInputBox">

     address
     <input type="text" name="address" id="address" class="demoInputBox">

     Price
     <input type="text" name="price" id="price" class="demoInputBox">

     Contacts
     <input type="text" name="contact" id="contact" class="demoInputBox">

     <input type="button" name="submit" id="btnAddAction" value="Add" onClick="add();" />
     </form>   My script   function getresult(url) {     $.ajax({     url: url,     type: "POST",     data:  {rowcount:$("#rowcount").val(),image:$("#image").val(),fname:$("#fname").val(),image_text:$("#image_text").val()},     success: function(data){ $("#toys-grid").html(data); $('#add-form').hide();}    }); } getresult("getresult.php"); function add() { var valid = validate(); if(valid) {     $.ajax({         url: "add.php",         type: "POST",         data:  {image:$("#add-image").val(),fname:$("#add-fname").val(),image_text:$("#add-image_text").val(),address:$("#address").val(),price:$("#price").val(),contact:$("#contact").val()},         success: function(data){ getresult("getresult.php"); }        });     } }   Add.php  require_once("dbcontroller.php"); $db_handle = new DBController(); $result = mysql_query("INSERT INTO cls_vehicles(fname, image_text, address,  price, contact) VALUES('".$_POST["fname"]."','".$_POST["image_text"]."', '".$_POST["address"]."','".$_POST["price"]."','".$_POST["contact"]."')");


Javascript false comparison even if the numbers are equal

i have this javascript code : var a = 0.1 var b = 0.7 var c = 0.8 console.log(a + b); if (a + b == c) console.log("OK")  does not give the result as it should the output is 0.7999999999999999 instead of 0.8 and never comes to the if statement what is the problem here?


Using dd command to clone entire Linux install

Can I use dd command to clone my entire Ubuntu install along with grub into external hard drive and use it for portability?


Error while reading strings and integers from a file

So I'm a C++ programmer and i'm learning Java, I've had several issues while reading int and strings, since after the int in Java it doesn't ignore the \n, like it would be in c++ with the cin.ignore, but, that's why I decided to use the Integer.parseInt...   Although, that's not my real problem, my real problem comes later, in the second while loop, that it never ends, even though it reads the end character *, it just won't end.  This is the file content:  CircumsTest 25 150754 UnitedPhase UP 18852 John C 12345678A Marcal B 23456789B * ComunismT CT 6969 Laura D 22233300T Alex M 22355567I * *   And the code, nomCandidat is just a string Name which will indicate me the name of the Candidate and in case there are no more to read, it will be an * to end.   public static void llegirCircumscripcio(Circumscripcio c) throws FileNotFoundException {     File file = new File("ProcesElectoral.txt");     Scanner sc = new Scanner(file);      String nomCircumscripcio = sc.nextLine();     int nEscons = Integer.parseInt(sc.nextLine());     int votsValids = Integer.parseInt(sc.nextLine());      String nomPartit, siglesPartit; int votsPartit;     String nomCandidat, dniCandidat;     c = new Circumscripcio(nomCircumscripcio,nEscons,votsValids);      nomPartit = sc.nextLine();     while(nomPartit != "*"){         siglesPartit = sc.nextLine();         votsPartit = Integer.parseInt(sc.nextLine());         Partit p = new Partit(siglesPartit,nomPartit,votsPartit);          nomCandidat = sc.nextLine();         while(nomCandidat != "*"){             System.out.println(nomCandidat);             dniCandidat = sc.nextLine();             p.afegirCandidat(new Candidat(nomCandidat,dniCandidat));             nomCandidat = sc.nextLine();         }         System.out.println("arribo");         p.mostrarPartit();         c.afegirPartit(p);         nomPartit = sc.nextLine();     }     sc.close();  } public static void main(String[] args) throws FileNotFoundException {     Circumscripcio c = new Circumscripcio();     llegirCircumscripcio(c);     c.mostrarCircumscripcio();     // TODO code application logic here }   Thanks for your help.


Why do we have no enzyme to digest cellulose?

As we know, cellulose is the most abundant polysaccharide in nature. Why don't we have an enzyme to digest cellulose?


Can anyone help me solve following indefinite integral? I've been trying to work this out for quite some time now. Not a math major myself and the last time I did any undergrad college level calculus was back in 2013. Hence it might seem easy for a lot of you but please do help. I'm trying to brush up my calculus again. The question is  Solve $$f(x) = \int e^{x^n}\, dx $$


I recently installed Visual Studio Code editor. I downloaded the 32bit .deb package. Installed and run normally, but when i tried to save a file in my project folder, it returns permission denied. So, i re-run code with  sudo code .   and it returns  It is recommended to start vscode as a normal user. To run as root, you must specify an alternate user data directory with the --user-data-dir argument.   I looked for how to specify an alternate user data directory with the --user-data-dir argument but I didn't find much.  So, how do I run Visual Studio Code as root in Ubuntu 16.04?  edit: I would prefer a solution that avoids changing directory permissions.   edit2: project directory: /var/www/project (I'm using Apache with vhost)


Integrating $\sin(x)/x$, how to treat the pole at the origin?

I want to use residue theory to integrate   $$\int_{-\infty}^{\infty}\frac{\sin(x)}{x}dx$$  What would be a good contour to use?   I plan to take the imaginary part of this integral:  $$\int \frac {e^{iz}}{z} dz$$  The integrand has a simple pole at the origin, so that is a bit problematic.  So, I thought of choosing an upper semicircular contour, with a small semicircular indent going over the origin.  The estimate over the big semicircle is easy to give and the integral on it goes to zero, as the radius $R$ grows to infinity.  The integration over the two half lines are the desired integrals.  And the integration should be set equal to zero, since this choice of contour avoids the pole at the origin, and by Cauchy's Theorem, the integration of an analytic function over a closed contour is just zero.  Now the only trouble is evaluating the integral over the small semicircular indent, call it $C_{\epsilon}$.  Parametrizing, we have that $z= \epsilon e^{i\theta}$ for $\pi \ge \theta \ge 0$.  Then the contour integral is (after a bit of simplification):  $$\int_{\pi}^0  e^{\large i\epsilon e^{i\theta}}i d\theta$$  $$=-i\int_0^{\pi}  e^{\large i\epsilon e^{i\theta}} d\theta$$  I'm not sure how to evaluate this integral, so any hints or comments are welcome.  Also, if you think a completely different approach would be better, please feel free to comment.  Thanks,


"Would you have a resume I can refer to?" or "Do you have a resume I can refer to?" I want to ask someone for their resume, but I'm confused between would and do? Which one is correct and what's the difference between the two?


How do I get new player skins in Minecraft PE?


I've been very interested in mathematics for a while now and, after being inspired by reading Feynman's biography, would also like to learn about physics.  My mathematics background is fairly extensive.  I've taken courses through calc BC, the basics of multivariable calculus and a fair amount of linear algebra, with plans to take statistics next year.  My physics background is okay, in that I know what many of the individual symbols mean, but have never seen them put together in such a way that they yield all the wonderful results we see today.  Could anyone recommend a good place to start that makes use of this math background without being incomprehensible to my fledgeling physics knowledge and a freely available online textbook to accompany the former?  Thank you very much!


Compact Metric Spaces & Triangle Inequality Theorem

Let X be a metric space, p ∈ X, and let K ⊂ X be compact. Show that there exist x0, x1 ∈ K such that d(x0, p) ≤ d(x, p), ∀ x ∈ K, d(x1, p) ≥ d(x, p), ∀ x ∈ K.  I know that I have to show the distance function is contunous and since its domain is compact, the range of a contunous function is compact. Thus, it has a minimum and maximum because it's closed. But not sure how to construct the proof.


Octave 4.0.0 Package dependencies cannot be resolved

trying to install GNU Octave on Ubuntu 14.04. I've tried following the solution in  and ran the command sudo apt-get build-dep octave , but I still get the same list of errors:  The following packages have unmet dependencies:  octave: Depends: libgcc1 (>= 1:4.1.1) but 1:4.9.1-0ubuntu1 is to be installed     Depends: libglpk36 (>= 4.51) but 4.52.1-2build1 is to be installed     Depends: liboctave3 (= 4.0.0-3ubuntu2~octave~trusty1) but 4.0.0-3ubuntu2~octave~trusty1 is to be installed     Depends: libgl1-mesa-glide3 but it is not going to be installed     Depends: libportaudio2 (>= 19+svn20101113) but 19+svn20140130-1 is to be installed     Depends: libqt4-network (>= 4:4.5.3) but 4:4.8.5+git192-g085f851+dfsg-2ubuntu4.1 is to be installed     Depends: libqt4-opengl (>= 4:4.5.3) but 4:4.8.5+git192-g085f851+dfsg-2ubuntu4.1 is to be installed     Depends: libqtcore4 (>= 4:4.7.0~beta1) but 4:4.8.5+git192-g085f851+dfsg-2ubuntu4.1 is to be installed     Depends: libqtgui4 (>= 4:4.8.0) but 4:4.8.5+git192-g085f851+dfsg-2ubuntu4.1 is to be installed     Depends: libstdc++6 (>= 4.6) but 4.8.4-2ubuntu1~14.04 is to be installed     Depends: octave-common (= 4.0.0-3ubuntu2~octave~trusty1) but 4.0.0-3ubuntu2~octave~trusty1 is to be installed   Does that mean I need to run sudo apt-get install <package> to every one of the packages that are listed in the error detail?  Thanks  This is the output of apt-cache policy octave libgcc1 :  octave:   Installed: (none)   Candidate: 4.0.0-3ubuntu2~octave~trusty1   Version table:      4.0.0-3ubuntu2~octave~trusty1 0         500 http://ppa.launchpad.net/octave/stable/ubuntu/ trusty/main amd64 Packages      3.8.1-1ubuntu1 0         500 http://au.archive.ubuntu.com/ubuntu/ trusty/universe amd64 Packages libgcc1:   Installed: 1:4.9.1-0ubuntu1   Candidate: 1:4.9.1-0ubuntu1   Version table:  *** 1:4.9.1-0ubuntu1 0         500 http://au.archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages         100 /var/lib/dpkg/status      1:4.9-20140406-0ubuntu1 0         500 http://au.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages


How to prove that $f(f(x))=-x$ implies that $f$ is not continuous?

I am trying to prove that: Given an $f:\mathbb{R} \rightarrow \mathbb{R}$, if $f(f(x))=-x$ then  $f$ is not continuous?  any help?  Thank you!


Subspaces of $\ell^{2}$ and $\ell^{\infty}$ which are not closed?

Are there any examples of subspaces  of $\ell^{2}$ and $\ell^{\infty}$ which are not closed?


How to put tikzpicture nicely between paragraphs?

I want to put my tikzpicture nicely between paragraphs. How do I do that? I do not want  to put it in a picture environment because than there is extra space underneath.  \documentclass[11pt,a4paper,addpoints]{exam} \unframedsolutions %\printanswers \usepackage{tikz} \usepackage{graphicx} \usepackage{geometry} \usepackage{calc}  \newgeometry{left=2cm,top=2cm,right=2cm,bottom=2cm}  \begin{document} \begin{questions}   Line above tikzpicture.  \begin{tikzpicture}[rounded corners=5mm] \path node[rectangle,draw=green,fill=green!8,inner sep=.70cm] {\parbox{\textwidth-1.4cm-\fboxrule}{  \question[2] What is the first question? \begin{solutionorlines}[4cm] This box is smaller than when the solutions are not printed. How do I make this the same dimension as when answers are not printed? \end{solutionorlines} }}; \end{tikzpicture}  Line under tikzpicture. I don't want this. I want the tikzpicture between paragraphs.  \end{questions} \end{document}


I bought a used iPhone 4, got the carrier to unlock to use, but I still can't use because I don't have the previous owner's Apple ID or password. Is there any way to unlock to use?


Daily reputation is not counted correctly on profile page

As we all know, we can achieve an Epic and Legendary badges when we hit the daily reputation cap of 200 points per day for 50/150 times.  The question is - which points count here? Just the upvotes for our questions (+5) / answers (+10)? Or accepted answers (+15) as well?  Just a few minutes ago I got 200 points in total (counting accepted answers) and my  badge progress was increased from 56 to 57:    The thing is, when I click the badge details in my profile details, I can see that I scored today just 140/200 points (so only +5 and +10 were counted):    Is it a bug in UI or counting mechanism?


What's the default start and stop for python slicing index?

a = np.ramdon.rand(10)  # We can index a numpy array by [start:stop(:step)]  a[::1]  # returns [a[0], a[1], ..., a[9]] a[::-1]  # returns [a[9], a[8], ..., a[0]]   As shown in the above example, start and stop for both a[::1] and a[::-1] should be by default, since only the step arguments are given. For a[::1], I suppose the default start should be 0 and the default stop should be -1 (i.e., a[::1] is the same as a[0:-1:1]), but apparently this is not true for a[::-1], since a[0:-1:-1] returns an empty array. So what are the exact default setting for stop and start? I am so confused because all the documentations I ran into only mentioned that to reverse an array you can use ::-1 with no further explanation.


How to prove continuity of the retraction map in proof of Brouwer's fixed point theorem?

I was reading Allen Hatcher's proof of the Brouwer's fixed point theorem using the no retraction theorem. That is, we want to prove that every continuous $f: \mathbb{D}^n \to \mathbb{D}^n$ has a fixed point $f(x) = x$, by contradiction.  The no retraction theorem says there is no continuous $r: \mathbb{S}^{n-1} \to \mathbb{D}^n$ such that $r \mid_{\mathbb{S}^{n-1}}(y) = y$. i.e. $r$ restricted to $\mathbb{S}^{n-1}$ is the identity functon.  Suppose a continuous $f$ exists with no fixed point. Then, define $r(x)$ by the point on the line $tx + (1-t)f(x)$ intersecting $\mathbb{S}^{n-1}$. The book, and lecture notes that I looked up, say this is clearly continuous.  Question: How do we proof that $r(x)$ is continuous?


Can't install google chrome on Ubuntu 12.04

The termial say's package google-chrome-stable needs to be reinstalled but can't find it in the archives. What do I need to do? I keep getting errors.


What does the @ mean on the output of "ls" on OS X' terminal?

When doing an ls in a directory I get the following output:  drwxr-xr-x@ 12 xonic  staff    408 22 Jun 19:00 . drwxr-xr-x   9 xonic  staff    306 22 Jun 19:42 .. -rwxrwxrwx@  1 xonic  staff   6148 25 Mai 23:04 .DS_Store -rw-r--r--@  1 xonic  staff  17284 22 Jun 00:20 filmStrip.cpp -rw-r--r--@  1 xonic  staff   3843 21 Jun 21:20 filmStrip.h   I was wondering what the @ means.


Relocated items after macOS update to 11.3.1

After updating my macOS to 11.3.1 from 11.3, a directory named Relocated Items appeared on my desktop. A document in that directory explained a bit about what's going on. I will attach the text of the document below. so I viewed a diff between /etc/group and ~/Desktop/.../group.system_default and saw that the line containing _trustd:*:282:_trustd exists in group.system_default but not in /etc/group. Another odd thing I realized is the 'Date modified' on the file on group.system_default is 1. Jan 2020. This computer and the install are both from 2021. Can somebody explain what is going on? I am not sure which of the files came with the macos-update and which I suposedly modified in the previous version. I also don't understand what _trustd:*:282:_trustd means. Document in Relocated Items Directory  During the last macOS upgrade or file migration, some of your files couldn’t be moved to their new locations. This folder contains these files. Configuration files These configuration files were modified or customised by you, by another user or by an app. The modifications may be incompatible with the recent macOS upgrade. The modified files are in the Configuration folder, organised in subfolders named after their original locations. To restore any of the custom configurations, compare your modifications with the configuration changes made during the macOS upgrade and combine them when possible. Configuration files with the suffix "system_default" were edited or customised but the changes were allowed to remain installed. The system_default version of the file is provided to demonstrate what the Apple-supplied version of this file would look like. It is recommended you compare the two and evaluate whether you wish to integrate any changes Apple may have made to the default version.


How are new Stack Exchange sites opened?

I don't know how new Stack Exchange sites get opened. I've found some of the new SE sites to be very useless. There are many different and important subjects that are not being addressed by any SE site. I strongly suggest creating a new SE site about unscientific psychology. I have come across many questions that are related to human problems that I would like to ask on an SE site.  How do new SE sites get opened up? Is there a place for voting up new SE sites?


certain applications looks tiny on high def screen

On my Lenovo yoga laptop with Ubuntu 18, I installed notepad++. And it looks really tiny. I'm not sure why it only happens with this app. Is there a way to change settings for a single app only?


I am in creative mode and I want to respawn at my house. I tried the /kill command and it said "killed Steve" but I'm still in the void.  Can you help? I am very frustrated and aggravated at this point. I created a big house and I want to get back to it but can't figure out how.


Terminal Ubuntu 20.04 beginner question on how to go further .. thanks for the assistance

Downloaded Ubuntu from the Microsoft store and when I click on the GUI I get the terminal. Followed before all the questions so I have (name)@ (computername):~$ I did all the updates through sudo apt update and that worked fine. Which command do I use to get to the Ubuntu desktop? Thanks for the assistance...


Evaluating the integral $\mathop{\lim}\limits_{n \to \infty} \int_{-1}^{1} f(t)\cos^{2}(nt) \ dt $

Given that $f\colon [-1,1] \to \mathbb{R}$ is a continuous function such that $ \int_{-1}^{1} f(t) \ dt =1$, how do I evaluate the limit of this integral: $$\lim_{n \to \infty} \int_{-1}^{1} f(t) \cos^{2}{nt} \,dt$$   What I did was to write $\cos^{2}{nt} = \frac{1+\cos{2nt}}{2}$ and substitute it in the integral so that I can make use of the given hypothesis of $\int_{-1}^{1} f(t) \ dt =1$. So the integral becomes,   \begin{align*} \int_{-1}^{1} f(t)\cos^{2}{nt} \ dt = \int_{-1}^{1} f(t) \biggl[\frac{1+\cos{2nt}}{2}\biggr] \ dt  &  \\  \hspace{3cm} = \frac{1}{2}\int_{-1}^{1}f(t) \ dt + \int_{-1}^{1} \frac{f(t)\cos{2nt}}{2} \ dt \end{align*}  But I don't really know how I can evaluate the second integral and also I can't realize as to why that integral condition on $f$ has been assumed. Moreover without assuming that condition on $f$ is it possible to evaluate this integral? If yes, then what would the answer be?


Do I need to adjust the oven temperature in a roast duck recipe if I want to put more than one duck in the oven at a time.   I suspect I should keep the same temperature but keep them in longer.  Should I cover each duck in foil individually or together?  Does it matter if they are on the same pan?


On the iOS version for a tablet is there a way to password protect the multiplayer game so that other people on the same wifi network can not access the world?


Difference in the direction of propagation of em wave

How are kx-wt and kx+wt in terms of the direction of the wave. I have been stuck at this or an hour, still can not find a definitive answer.


Proof strategy involving first order logic for existential quantification at very beginning

I have the following problem from the book "How to Prove it" by Daniel J.Velleman.  Prove that $$ \exists z\in \mathbb{R} \forall x \in \mathbb{R}^+ \left[\exists y \in \mathbb{R} (y-x=y/x) \leftrightarrow x \neq z \right]. $$  I have no idea how to deal with the existential quantifier at the beginning. I tried to negate it, but the rest is too complicated. Do you have strategic hints how to proceed? Allowed is first-order logic.  EDIT  Based and the response, I would propose the following proof and kindly ask the community to check if it is correct.  Proof: Let $z=1$, and let x be some arbitrary real number.   $(\rightarrow)$ Suppose $\exists y \in \mathbb{R} (y-x=y/x)$ and choose $y_0$ to be some real number such that $(y_0-x=y_0/x)$. Suppose $x=z$. Since $x=z$ and $z=1$, $x=1$. However, plugging $x=1$ into $y_0-x=y_0/x$ yields a contradiction, and thus, $x\neq z$. Hence, $\exists y \in \mathbb{R} (y-x=y/x) \rightarrow x \neq z$. Since $x$ was arbitrary, it follows that $\forall x \in \mathbb{R}^+ \left[\exists y \in \mathbb{R} (y-x=y/x) \rightarrow x \neq z \right]$. ($\leftarrow$) Suppose $x \neq z$. Since $z=1$, $x \neq 1$. Let $y_0=\frac{x^2}{x-1}$, which is defined because $x \neq 1$. Plugging into the equation $y_0-x=y_0/x$, we can verify that the equation holds for this particular value $y_0$. Hence, $x \neq z \rightarrow \exists y \in \mathbb{R} (y-x=y/x)$. Since x was arbitrary, it follows that $\forall x \in \mathbb{R}^+ \left[\exists y \in \mathbb{R} (y-x=y/x) \leftarrow x \neq z \right]$.   Therefore, the theorem follows.


How to turn off the display via the command line?

Is there a way to turn off the display (enter power saving mode) using a command?  For example, when the computer is inactive for a specific interval, the screen turns off to conserve energy. Is there a way to manually turn off the screen, yet keep the computer running normally?  This is a notebook, so there's no 'power-off' button on the monitor itself.


How to find all the solutions to cos$(z)=0$

How would you go about finding all the solutions to $\cos(z)=0$, where $z\in \mathbb{C}$?  I have $$\cos(z)=0 \implies (e^{iz})^2=-1 \implies \text{Log}(e^{iz})=\text{Log}(e^{i\pi(1/2+2k)})\qquad\text{ where }k\in \mathbb{Z}$$  $$\implies ie^{-y}x=i\pi(1/2+2k)$$  $$\implies z= e^{y}\pi(1/2+2k)+iy \qquad\forall k\in \mathbb{Z}\;\text{ and }\;\forall y\in \mathbb{R}$$  Is this correct?  Thanks!  EDIT:  $e^{2iz}=e^{i\pi(1+2k)} \Rightarrow z=\pi/2+k\pi$ where $k\in \mathbb{Z}$


If the Earth is constantly accelerating at 9.8m/s^2, according to General Relativity, won't Earth's speed be constantly increasing towards infinity?

As per Einstein's Theory of General Relativity, I understand that 'the Earth's ground is accelerating towards us at 9.8m/s^2. This is why we're falling towards the center of the Earth, as GR doesn't accept gravity as a force'. So, if a car is supposed to accelerate constantly, at one point of time, it would reach its top speed. Won't the same happen with Earth, as the top speed will be the speed of light? Thank you.


How do I turn off equation auto numbering

I have an equation like this:     \begin{align}       P(A \cup B) = \sum_{\omega \in A \cup B} P(\omega) = \sum_{\omega \in A} P(\omega) + \sum_{\omega \in B} P(\omega)       = P(A) + P(B)     \end{align}   For some reason, LaTeX is automatically labeling the equation. How do I turn that off? Secondly how do I write something in LaTeX on this site. I tried enclosing in '$' but it doesn't work.


Problem: For what integer $a$ does $x^2-x+a$ divide $x^{13}+x+90=P(x)$?  I am struck at this one. I can't think of a good method (using little computations) to do this.  Of course, we could divide $P(x)$ by $x^2-x+a$ and equate the remainder to $0$ or factor out $x^2-x+a$ and use the remainder theorem (But this may not work as we would get an equation with surds and all and 13 degree terms.)  I also tried with the following form:  $x^{13}+x+90=(x^2-x+a)Q(x)$  By differentiating in two different ways I got the following,  $13x^2+1=(2x-1)Q(x)+(x^2-x+a)Q'(x)$  $\frac{(13x^2+1)(x^2-x+a)-(2x-1)(x^{13}+x+90)}{(x^2-x+a)^2}=Q'(x)$  I think we can solve for $Q(x)$ from the last two equations and finish the problem(or do we get an identity?, I haven't tried as it is becoming very cumbersome).   So, can anyone help me find an elegant solution (will less computations)?   Thanks.


I am planning to write some device drivers and I need to get the Linux kernel source. My Linux kernel version is 3.2.0-23-generic-pae and I downloaded the image from . In many of the articles I have read, it tells me that I need to have the entire kernel tree to start inserting new modules.   Is it enough if I download this image and paste it into the usr/src/ folder or do I have to do something else?


why isn't conservation of energy just a definition?

I am new to theoretical physics. When I was reading the proof of conservation of energy, I found that the proof was a little bit trivial and everything seems to just be a definition.   The potential energy is derived from $W=\int_c {\bf F} \, \mathrm{d}{\bf r} =\varphi(b) - \varphi(a)$ where curve $c$ starts at $a$ and ends at $b$, and $\varphi$ is the "antiderivative" of the force field ${\bf F}$, given the field is conservative. The potential energy is defined as $U(x) = -\varphi(x)$.  The kinetic energy (Newtonian), by Newton's first law, is defined as $W=\int_0^t {\bf F} \, \mathrm{d}x=\int_0^t m{\bf v} \, \mathrm{d}v=\frac{1}{2}mv^2$.   Note that in the definition, both kinetic and potential energy are derived from the definition of work, but they're just viewed differently. One is viewed as a line integral, the other is viewed as a function of velocity. However, since both are derived from work simply with a different sign, their sum is 0 for sure, I didn't see any need to do a proof. Why is a law of universe just a definition? I think it should be based on observations, but the "proof" has really made me confused, because physics is not like math and we can't "invent" laws.


What is the acceptable similarity in a mathematics PhD dissertation when checking by Turnitin?

I have checked the originality of my PhD thesis in mathematics using . The similarity was 31%. Is this percentage acceptable by most committees?


I catch a lot of grief about this from family and friends, so I figured I'd settle the score once and for all.  In verbal context (though not written), I tend to use the phrase     ... yesterday night...   rather than last night. Is this grammatically correct, regardless of how uncommon it might be?


Trouble importing Feature Classes into Feature Datasets

I'm sure there must be a simple reason for this but I can't seem to be able to import a shp file or a feature class from another file or sde geodatabase into a Feature Dataset without getting an error.  The feature classes come in fine if I don't don't try to import them into a Feature Dataset.  The feature dataset definitely has the same projection as the feature classes I'm trying to import so I don't think that's the problem.  The Error I get is ERROR 000210 and just says Failed to convert and cannot create output and Failed to execute (CopyFeatures).    Any ideas what I may be doing wrong here.  Seems like something so simple.  I'm trying to use the Feature Datasets to better organize my data which I think is there purpose.   Update:  So as you can see below, Jason helped me find the answer.   As suggested by Matt below, I added a new Idea to the ArcGIS Ideas site.  Here is the link to that, so please promote this up if you agree a better error message is needed here:


I installed Virtualbox on Ubuntu 20LTS, I have some questions you may help me solve. I am trying to run a Ubuntu VM from an USB as a disk About Users & Groups: which groups needs the user to have permission to? After a research I made up this list: vboxusers fuse sudo disk dip adm plugdev netdev virtualbox-ext-pack & MOK Do I need to install the virtualbox-ext-pack?? when I install this package it requires me to go through a process of rebooting and adding some passwords. Is this process really need it in order to run a VM from an USB as a disk?? Thanks!!


How do I fix Intent.getExtras()' on a null object reference?

I want to populate a list view based on grid item click. If user clicks the first grid item I want to show the list view according to it. I have used a pre populate SQLite database here.  What I tried is , to get item click id in first activity and pass it to DB Class. This is what I'm getting when debugging the programme.   Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.os.Bundle android.content.Intent.getExtras()' on a null object reference         at com.example.sra.hellosrilanka.DBAccess.getQuotes(DBAccess.java:51)         at com.example.sra.hellosrilanka.ContactView.onCreate(ContactView.java:29)   DBAccess Class:  public class DBAccess extends Activity { private SQLiteOpenHelper openHelper; private SQLiteDatabase database; private static DBAccess instance; String passedVar=null;  public DBAccess(Context context) {      this.openHelper =new HelloDatabase(context); }  public static DBAccess getInstance(Context context) {     if (instance == null) {         instance = new DBAccess(context);     }     return instance; }  public void open() {     this.database = openHelper.getWritableDatabase(); }  public void close() {     if (database != null) {         this.database.close();     } }    public List<String> getQuotes() {     List<String> list = new ArrayList<>();     Integer value;      Bundle extras = getIntent().getExtras();     String a = extras.getString("ID_EXTRA");       if(extras != null)     {         Cursor cursor = database.rawQuery("SELECT org_name FROM org_name WHERE category_id = \""+ a +"\"" , null);        /* Cursor cursor = database.rawQuery("SELECT org_name FROM org_name WHERE category_id="+a, null);*/        /*Cursor cursor = database.rawQuery("SELECT org_name FROM org_name WHERE category_id='ID_EXTRA'", null);*/         cursor.moveToFirst();         while (!cursor.isAfterLast()) {             list.add(cursor.getString(0));             cursor.moveToNext();             cursor.close();         }     }    /*  if (passedVar != null) {       }*/      return list; }}   Contact View Class:  public class ContactView extends Activity { private ListView listView;  @Override protected void onCreate(Bundle savedInstanceState) {      super.onCreate(savedInstanceState);     setContentView(R.layout.list_view);       this.listView = (ListView) findViewById(R.id.listView);     DBAccess databaseAccess =  DBAccess.getInstance(this);     databaseAccess.open();     List<String> quotes = databaseAccess.getQuotes();     databaseAccess.close();      ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, quotes);     this.listView.setAdapter(adapter);  }   }  Main activity class  public class MainActivity extends AppCompatActivity {  GridView grid; Toolbar toolbar; private ListView listView;  String [] result; Context context; @Override protected void onCreate(Bundle savedInstanceState) {      super.onCreate(savedInstanceState);     setContentView(R.layout.activity_main);      grid = (GridView) findViewById(R.id.grid);      toolbar=(Toolbar)findViewById(R.id.toolBar);    setSupportActionBar(toolbar);     grid.setAdapter(new CustomAdapter(this));             grid.setOnItemClickListener(new AdapterView.OnItemClickListener() {                 @Override                 public void onItemClick(AdapterView<?> parent, View v, int position, long id) {                     /*Intent intent=new Intent(MainActivity.this,ContactView.class);                     intent.putExtra("catid", id);                     startActivity(intent);*/                      Intent i=new Intent(MainActivity.this ,ContactView.class);                     i.putExtra("ID_EXTRA",String.valueOf(id));                     startActivity(i);                  }                 });}}


Is it possible to have a career in academia and not be confident in their field of research?

I thought getting a PhD in my mechanical engineering field would lead in gaining confidence in the field. However, it became other way round. I am far less confident on my skills and knowledge than I was when I started my PhD. I am well published in my research field, I have decent theoretical knowledge about my field. However, I am not confident. I often hesitate with my answer, even though I know I am right. I get afraid before starting a new project and technique even though I am sure that I can acquire new skillsets easily. Self doubts is a recurring theme during all research endeavors. When I feel low confidence, I also start to regret my decisions to be in academia and pursue masters and PhD. Does anyone else get this feeling? How to cope up? Can I find a place in academia with this issue?


How do I change my bibliography to another language?

I'm encountering a problem when using Overleaf. I've used \usepackage[dutch]{babel} and my table of contents and header of my bibliography is all Dutch, which is great. However, my bibliography itself, is in English.  For example when I quote a chapter in a book, the bibliography says chapter 582 or first edition, whereas it should say hoofdstuk (Dutch for chapter) 582 and first editie (Dutch for edition).   I've tried \bibliography{bib.bib}{dutch} , but that did not work.


Rewrite recipient mail queued in postfix

I want to rewrite the recipient adress of a mail queued in a hold queue.  Is it possible to rewrite the mail by hand with the mail id in the postfix queue ?  Maybe a command like this :  postrewrite -I ETGH12DD newrecipient@domain.com  Thanks for yours answers.


Recommended F-Stop for older Canon 35mm F/2

I have a few year old Canon 35mm F/2 lens (). I've been shooting wide-open, but I realize that doesn't make for the sharpest photos. What would you say would get me the sharpest photos without bringing the f-stop down too low?


Sum of a Sequence of Odd Numbers that are Squared

What is the sum of all the numbers in the sequence $1^2 + 3^2 + 5^2 + 7^2 + 9^2 + \ldots + k^2$. Note that all the numbers being squared in the sequence are all odd numbers.  This is what I have done so far (sorry if the images are an inconvenience, but this was the clearest way to display my working out):     I am a little stuck on what to do next and how to obtain $\frac{n (4n^2 - 1)}{3}$ as the final result as this is what I am meant to end up with. It would be really appreciated if anyone could make suggestions towards completing and improving my method. Thanks! :)


Integral asked on MIT bee qualifier 2012 $\int\frac{x-1}{(x+1)\sqrt{x^3+x^2+x}}\,dx$

I have been trying to solve this one but I have no clue, I put it into wolfram and the result is absurd, considering this one is taken from MIT bee qualifier 2012, this is the integral: $$\int\frac{x-1}{(x+1)\sqrt{x^3+x^2+x}} \, dx$$


package pack;  import java.util.Scanner;  public class Calculator {       public static void main(String args[]){         Scanner scan = new Scanner(System.in);         String cont = "Yes";          while(cont == "Yes" || cont == "yes" ){             System.out.print("Enter a Number: ");             int x = scan.nextInt();             System.out.print("Enter another Number: ");             int y = scan.nextInt();              int diff = x - y;             int sum = x + y;             int prod = x * y;             int quot = x / y;              System.out.println("The Sum is: " + sum);             System.out.println("The Diffrence is: " + diff);             System.out.println("The Product is: " + prod);             System.out.println("The quotient is: " + quot);              System.out.print("Enter Yes to Continue: ");             cont = scan.next();             System.out.println(cont);          }      }    }   This entire code works, but the while loop doesn't repeat. The cont = scan.next(); is catching the string. The output looks like this:  [  Enter a Number: 5  Enter another Number: 6  The Sum is: 11  The Diffrence is: -1  The Product is: 30  The quotient is: 0  Enter Yes to Continue: Yes  Yes  ]   Then the program terminates without any problems. All I need it to get the while loop to repeat. Thanks for the help!


Punctuation for sentence ending in quotation marks and a Question mark that is part of a title

What is the correct punctuation for a sentence which has quotations with a question mark as part of the title and the title is the end of the sentence?    Dr. Spencer Johnson discussed the principle in his book "Who Moved My Cheese?".   Does a period go at the end of the sentence, as shown here or not?


If two subsequences converge to the same limit, is that sufficient to say that a limit exists for the sequence?

Specifically, I've proven that for a sequence $x_n$, the subsequences $x_{2n}$ and $x_{2n-1}$ converge to L. Is that sufficient to say that $x_n$ converges to L?


how to redirect t o a page with jquery $.ajax

this is simple question. i want to redirect to another page after success in ajax. my code is   if (page != 'Theatres') {     $('.hexagon').removeClass('active');     $(this).addClass('active');     $.ajax({         url: '{{ url("dashboard/user/set-home-page-preference") }}',         data: {             'page': page         },         type: 'GET',         success: function(data) {             alert(data);         }     }); }   i want to redirect to a page after the alert data.


What happens if a character casts Fireball in an enclosed space?

Recently I had a Warlock character who woke up trapped in a wooden coffin with no knowledge of how he got there. It wouldn't move when he tried to roll around in it, and there wasn't room to try to break out manually (a la Kill Bill).  In a panic since he is claustrophobic, he quickly casts Fireball targeted on himself to try to bust out. However, the coffin happened to have been formed around where he fell asleep, in the middle of Leomund's Tiny Hut, surrounded by sleeping party members.  Which of the following should happen?   My character takes damage and the coffin remains in tact. My character takes the damage and the coffin breaks open. My character takes the damage, the coffin breaks open, and the rest of the party get to have a Dex save to take reduced damage. My character takes the damage, the coffin breaks open, and the rest of the party auto-fail the Dex save since they were asleep.


Determine all positive integers $(a,n)$ such that $(a-1)!+1=a^n$

I’m in trouble with this problem.  The following is what I have done until now. First of all $a$ must be prime because if $(a-1)!+1=a^n$ then is true also that $ (a-1)!\equiv -1\pmod{a}$ and so, by Wilson’s theorem $a$ is prime.  $(1,n)$ is not a solution.  Consider $a\neq1$ and $n=1$: we then have $(a-2)!=1$ and so when $n=1$ the solutions are $(2,1)$ and $(3,1)$.   Consider $n=2$. We then have  $$ (a-2)!=a+1 $$ $a=5$ is a solution but $a=7$ is not and in particolar $5!>8$ and, due to the rapid explosion of the factorial we do not have other solution when $n=2$.  Consider now $n>2$. We could write by hypothesis $$ (a-1)!=(a-1)(a-2)!=a^n-1=(a-1)(a^{n-1}+...+a+1) $$ By Wilson theorem we could write: $$ (a-2)!=ak+1 $$ for some integer k and so simplifying: $$ k=a^{n-2}+...+a+1 $$ Now because $a$ is prime (and $a>3$) it is odd and so if $n$ is even (odd) $k$ is a sum of a odd (even) number of odd addends and so it is odd (even).  If $k$ is even we have that $ak+1$ is odd, but $ak+1=(a-2)!$ and $(a-2)!$ is even, thus we must have $k$ odd and so $n$ must be a even integers.   I do not know if for $n>2$ even there are other solutions, I can’t go further.  Thanks for any advice!


In my koma-document, loading the package roboto for using the Roboto font as sans-serif messes up the indentation of the ToC.  Do you know what causes this misbehavior, and how I could fix it?    \documentclass{scrbook}     %\usepackage{roboto}\renewcommand{\contentsname}{Contents with roboto}%% <== uncomment to see the effet of `roboto` package \begin{document}     \tableofcontents     \part{Part1}         \chapter{Chap1}             \section{Sec1}             \section{Sec2}             \section{Sec3}         \chapter{Chap2}             \section{Sec1}             \section{Sec2}             \section{Sec3}         \chapter{Chap3}             \section{Sec1}             \section{Sec2}             \section{Sec3}                       \end{document}


Deleting files from Remote FTP-Server older than X days (only ftp, curl or lftp)

I have similar situation descibed here:  and I see this is not answered fully yet so I would like to register the new one.  My files are having a names containing date and time when they had been generated:     xxx.yyy.z.aaa_01_20160313102903_DUMP01.dmp and are uploaded to remote FTP server. Position of the date and time (e.g. 20160313102903) in the file name is static. Of course time stamps of those files are also valid.  My goal is to delete files older than X days using a script which should run in cron on a linux machine where I can use only curl or lftp.   I can't use any other protocol except ftp to access FTP server (no sftp, no ssh) I can't use date command with "X days ago" syntax as that linux machine is running BusyBox v1.20.2 which doesn't understand human date references I can't create a temporary subfolders at that FTP server   I have been searching scripts which should lead me to the solution but because I'm linux noob I'm progressing very slowly and so far I have found only:   I'm able to list the date of X days ago: date -d "@$(($(date +%s) - 86400 * $XDays))" I'm able to list all the files from FTP server: curl * --user MyUser@[FTP_IP]:[MyUserPassword] --list-only"   Real script, instead of obvious steps describing what that script should do, like:   Get the list of files using the --list-only option of curl Parse the list for the files you want to delete Use the --quote or --request option to send a rm or DELE command with the selected filenames   is very welcome.


scoping in node.js with asynchronous functions

I understand the principles of asynchronous functions, but something is not clear to me: Scoping in asynchronous functions.  Example:      var path = "/my/folder/to/public/data";     http.createServer(function(request, response){             /* some malicious code is executed, however */             path = "/my/folder/to/private/data"     });      /* go on, go on, go on, wait here because of an synchronous function. */     /* while code execution is here, the callback-function of the server is called. */      fs.readFile(path+"myfile.txt", function(err, content){             console.log(content);     });   So, this is only an example. But how does it behave with the scopes/vars?


Why are "join" and "meet" named as they are?

In the context of partially ordered sets, why are the words for supremum and infimum "join" and "meet"? I find the nomenclature puzzling, especially since the English words "join" and "meet" are synonyms, but denote opposite concepts when talking about posets.  Does anyone know how these concepts got these names?


Prove that a regular map is not an isomorphism

Problem: Let $X$ be an algebraic curve defined by $y^2= x^3$ and $f(t) =(t^2, t^3)$ the regular map $\mathbb{A}^1 \to X$. Prove that $f$ is not an isomorphism. What are the rational functions in $t$ that correspond to the functions in the local ring of the point $(0,0)$?   My attempt: I tried to construct the inverse as $P(x) + Q(x)y$ with $P(x), Q(x)$ polynomials, because every regular function on $X$ can be written uniquely in this form, but I have trouble constructing the inverse. By writing $x= t^2$ and $y= t^3$ and composing the two functions I got $P(t^2) + Q(t^2)t^3$ and I think I should prove that this last expression is not equal to $t$ for no $P$ or $Q$, but I’m stuck. For the last question, I wrote the local ring $O_x= \left\{ \frac{P_1(x) + Q_1(x)y}{P_2(x)} \right\}$, with $P_2$ having a nonzero constant term. How do I express now the rational functions in $t$ corresponding to that?


Can all site-specific badge images be shown on all profile pages?

For example, here are top five accounts in each site (this picture was taken when I was in Biology SE).    As you can see, all the badges are DNA, while Academia's badges should be hats, so on.  What do you think?


I am new to Android programming and I try to learn it and take sample sample applications on the git * ub site, I have tried to resolve some errors in the application and after compiling the application is able to run, but the problem that arises when I open the details from the application post, the error is like this      java.lang.RuntimeException: Unable to start activity ComponentInfo{com.app.newsagni/com.app.newsagni.ActivityPostDetails}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.TextView.setText(java.lang.CharSequence)' on a null object reference     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2490)     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2550)     at android.app.ActivityThread.access$1100(ActivityThread.java:154)     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1401)     at android.os.Handler.dispatchMessage(Handler.java:102)     at android.os.Looper.loop(Looper.java:157)     at android.app.ActivityThread.main(ActivityThread.java:5615)     at java.lang.reflect.Method.invoke(Native Method)     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:774)     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:652) Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.TextView.setText(java.lang.CharSequence)' on a null object reference     at com.app.newsagni.ActivityPostDetails.displayPostData(ActivityPostDetails.java:190)     at com.app.newsagni.ActivityPostDetails.onCreate(ActivityPostDetails.java:98)     at android.app.Activity.performCreate(Activity.java:6362)     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2443)     ... 9 more   The following listings from  ActivityPostDetails.java   activity_post_details.xml   Can you help me overcome this error


I made a login and register form in windows form using C#. Could somebody modify my code in a way to prevent a mysql injection attack?  What else do I need to add in the code?   //MySql Connection         try         {             string myConnection = "datasource=localhost;port=3306;username=root;password=ally123;";             MySqlConnection myConn = new MySqlConnection(myConnection);              MySqlCommand selectCommand = new MySqlCommand("select * from justinsdatabase.login where username='" + this.txtBoxUser.Text + "' and password='" + this.txtBoxPw.Text + "';", myConn);               MySqlDataReader myReader;             myConn.Open();             myReader = selectCommand.ExecuteReader();             int count = 0;             while (myReader.Read())             {                 count = count + 1;             }             if (count == 1)             {                 MessageBox.Show("Login sucessful.");                 Close();                 MainMenu menu = new MainMenu();                 Hide();                 menu.Show();             }             else if (count > 1)             {                 MessageBox.Show("Duplicate username/password.");             }             else             {                 MessageBox.Show("Username or password is incorrect.");                 myConn.Close();             }         }         catch (Exception ex)         {             MessageBox.Show(ex.Message);         }         //End MySQL Connection


I am creating ArrayList l1 and passing l1 reference to the method foo. As we know that Java doesn't support Pass-By-Reference but here its giving different results.  See the below code  public static void main(String[] args) {     List l1 = new ArrayList(Arrays.asList(4,6,7,8));     System.out.println("Printing list before method calling:"+ l1);     foo(l1);     System.out.println("Printing list after method calling:"+l1); }  public static void foo(List l2) {     l2.add("done"); // adding elements to l2 not l1     l2.add("blah"); }   Output:  Printing list before method calling:[4, 6, 7, 8] Printing list after method calling:[4, 6, 7, 8, done, blah]


I would like to create an empty (objects and data) sandbox with the same license and features than my prod org to test new implementations.  I know that we can use and new dev org. However, this will have more features than our prod org (like connect, service cloud, etc.). We don't want to use a feature that then, is not available in our prod org.  Is there any way to achieve this? Someone already ask this on 2013 (). But three years later something must have changed  Any thoughts?


I have to write a dissertation about a charity named "St Anthony's trust".  I was puzzled about the title. Do you think that I should write    "Community-supported agriculture. St Anthony's trust" or  "Community-supported agriculture. The St Anthony's Trust"?    Sorry for my bad English but I have been started to write in this language.


After voting to close, delete and reopen, I can't cast a close vote

When the OP posted , the contents looked like "AAAA AAAA AAAAAAAAA". Obviously, no-one was going to understand this, so we downvoted and voted to close. After closure, I immediately voted to delete the question. A few seconds later, the OP updated the question. I voted to re-open, and a few minutes later, the question was re-opened.  I've just reviewed the Q&A, and it's garbage:   The question is unclear (the fiddle doesn't match the question's code). The only answer was was invalidated after the question was updated again (it pointed to a typo). The invalid answer was accepted with the  "My problem was somewhere else but I did learn that JSFiddle needs the tag table. thanks" (note: has nothing to do with the question).   For these reasons, I decided to cast a close vote, which summoned the following screen:   As you can see, there are no pending close votes, but the screen still shows that I have already cast a close vote. This looks like a bug (possibly caused by my previous delete vote?).


How to always show "Library" in the Finder its "Go"-Menu without holding a modifier key?

I often use the "Library" folder in my home folder ~/. The Library folder there (~/Library/) is shown (unhidden), and that is not the question.  I would like to also always show the menu point "Library" in the Finder menu under the word "Go". Normally it only shows when I hold the Option ⌥ key the menu is open. I tried to assign "Library" to the shortcut for "Downloads" and gave Downloads another shortcut, like it worked for "Save As…". But it only shows up then holding down the Option ⌥ key.  How to always show the "Library" menu point under the Finder "Go" menu, without holding down a key?  In the screenshot I am holding down the Option ⌥ key:


Python, methods cause strange error in functions

When I run my program, it gave an error as usual. When I looked back at the code, I found the error a bit strange. I put print in the code to analyze a variable and I saw something that was total nonsense. Somehow a variable lost a value but in the code it doesn't change! I will share a sample code but same story here:  def f(a):     a.remove(1)     return a  list1 = [1, 2, 3] print(f(list1)) print(list1)   in the first print you would expect an output as:     [2,3]   and in second print you would expect:     [1,2,3]   as it didn't change in the main code. Well it turns out the output is like this:   [2, 3] [2, 3]    In my program, I went nuts trying to solve it. I debugged it and I saw that the variable changes in a function similar to f(). I thought that since in a function the program would run in scope level, it wouldn't influence a global variable like list1. So is this a bug in python or should I avoid using methods in functions?  By the way, I solved the problem by editing like:  def f(a):     x = list(a)     x.remove(1)     return x  list1 = [1,2,3] print(f(list1)) print(list1)   for some reason x=a wasn't enough so I used x=list(a)


I want to make the curtain looks like its giving the cube a way to pass through the curtain i made from a plane My question is, how and what step should i take to make the curtain that way?


New 14.04 LTS Install Extremely Slow Overall

I am new to Ubuntu.  I have a DINOSAUR machine that was not being used, and thought it would be a learning experience to wipe it clean and try a Linux-based OS.  14.04 LTS was installed on a completely clean hard drive (DoD wipe specifications).  Ubuntu OS boots just fine, but ALL operations are extremely slow to react to user inputs.  Computer specs:       14.04 LTS 32-bit OS; 512MB (495.2 MiB reporting) PC2700 DDR 333MHz RAM; Intel® Pentium(R) 4 CPU 2.40GHz; VGA Video: Radeon 9000 Series R200 (RV250 4966) x86/MMX/SSE2 TCL DRI2; 60 GB Hard Drive (58.4 GB reporting); 8PE667U Gigabyte Motherboard, BIOS: Award v6 Oct2002   Thus far, only diagnostic action was to generate 'system.html' with a report of all  components.  Some of the blocks are highlighted in red, but I am not experienced enough to interpret the results and take corrective action.  Is there a way to share the file with this community to help expedite a potential solution?


ubuntu not updating neither installing anything (Package system is broken)

Check if you are using third party repositories. If so disable them, since they are a common source of problems. Furthermore run the following command in a Terminal: apt-get install -f Transaction failed: The package system is broken  The following packages have unmet dependencies:  gdm3: Depends: libaudit1 (>= 1:2.2.1) but 1:2.8.2-1ubuntu1 is installed       Depends: libgdm1 (= 3.28.3-0ubuntu18.04.4) but 3.28.3-0ubuntu18.04.4 is installed       Depends: libwrap0 (>= 7.6-4~) but 7.6.q-27 is installed       Depends: gir1.2-gdm-1.0 (= 3.28.3-0ubuntu18.04.4) but 3.28.3-0ubuntu18.04.3 is installed       Depends: bash (>= 4.3) but 4.4.18-2ubuntu1.2 is installed       Depends: x-terminal-emulator but it is a virtual package       Depends: x11-common (>= 1:7.6+11) but 1:7.7+19ubuntu7.1 is installed gir1.2-mutter-2: Depends: libmutter-2-0 (= 3.28.4-0ubuntu18.04.1) but 3.28.3-2~ubuntu18.04.2 is installed gnome-shell: Depends: libgjs0-libmozjs-52-0 but it is a virtual package              Depends: gir1.2-mutter-2 (>= 3.28.4-0ubuntu18.04.1) but 3.28.4-0ubuntu18.04.1 is installed              Depends: gnome-shell-common (= 3.28.4-0ubuntu18.04.1) but 3.28.3-0ubuntu0.18.04.4 is installed              Depends: mutter (>= 3.28.4-0ubuntu18.04.1) but 3.28.3-2~ubuntu18.04.2 is installed libgl1: Depends: libc6 (>= 2.14) but 2.27-3ubuntu1 is installed         Depends: libglvnd0 (= 1.0.0-2ubuntu2.3) but 1.0.0-2ubuntu2.2 is installed         Depends: libglx0 (= 1.0.0-2ubuntu2.3) but 1.0.0-2ubuntu2.2 is installed policykit-1: Depends: libc6 (>= 2.7) but 2.27-3ubuntu1 is installed              Depends: libglib2.0-0 (>= 2.37.3) but 2.56.4-0ubuntu0.18.04.4 is installed              Depends: libpolkit-agent-1-0 (= 0.105-20ubuntu0.18.04.5) but 0.105-20ubuntu0.18.04.4 is installed              Depends: libpolkit-backend-1-0 (= 0.105-20ubuntu0.18.04.5) but 0.105-20ubuntu0.18.04.4 is installed              Depends: libpolkit-gobject-1-0 (= 0.105-20ubuntu0.18.04.5) but 0.105-20ubuntu0.18.04.4 is installed


I am a level 6 bard playing a campaign in 5e. I have the ability "song of rest"      Beginning at 2nd level, you can use soothing music or oration to help revitalize your wounded allies during a short rest. If you or any friendly creature who can hear your performance regain hit points at the end of the short rest, each of those creatures regains an extra 1d6 hit points (PHB pg 54).   Does this work if they use a potion during the rest? How long is this ability active? What about if a cleric is using a mass heal spell, Or a paladin's Lay on hands? It does say when they regain health points. So can this potentially give them multiple cases of life gain? Or only with the use of Hit Dice?  Song of rest with potion (+1d6) song of rest with hit dice (+1d6) song of rest with mass cure wounds (+1d6)


Where/how to put functions in a header vs C++ source file

Someone asked a question similar to mine here:    Why do you just declare a function inside a .h file but not the definition, and then write the whole definition in a .cpp file later? What's the point? Why don't you just put the whole function inside a class inside the header file instead of just declaring it? It seems repetetive and pointless.  How do I structure a program to use the header files and other .cpp files without piling functions, classes, and variables into the main file? Could I get an example of a simple program using a .h file and maybe a couple of .cpp files?


How is uniqueness of MAC addresses enforced?

Again and again I read that devices are uniquely identified by their MAC addresses. But how are MAC addresses determined? (And do they tell us anything about the device which they represent?)


What is the collective name for the digits before and after decimal point?


ubuntu install failed detect the available gpus and deal with any system changes. dell 5820 i9

I have a new Dell 5820 i9 workstation. I am trying to load ubuntu-20.04.1-desktop-amd64.iso with USB drive. The installation fails at:  ubuntu install failed detect the available gpus and deal with any system changes  a Radeon Pro WX 5100 card is used. Any help would be great.


Hi everyone am just a beginner on latex, can anyone please show me, how to put a picture on the top right or top left and on bottom left and bottom right only thanks.


OEM license activation for Windows 10 Home VirtualBox guest, on Ubuntu host

Context Three years ago my company got me a Lenovo T550 with Windows 10 Home installed on it (my understanding is that this is called "OEM"). I immediately erased everything to install Ubuntu on it. Unfortunately from now on I will need to use Windows 10 a few times a week for legacy reasons, but my main work is still on Ubuntu, so I am thinking of running Windows 10 within VirtualBox within Ubuntu. Lenovo recommendation Lenovo told me that my Windows Home license is somehow linked to my hardware (firmware?) and that Windows will automatically find this out. They pointed me to :  The installation of Microsoft Windows Server 2008,2008 R2 SP1, 2012, and 2012 R2 from Lenovo OEM media to such a virtual machine will fail until the virtual BIOS has been updated to include this information. setVMBIOS.exe performs this function for servers using Microsoft Hyper-V technology. Consult your hypervisor vendor for information on how to perform this function on other hypervisors. [...] The fix resolves this issue by adding Lenovo information to the virtual BIOS.  Note: That page does not mention Windows 10 Home, but I guess the same applies? VirtualBox How to apply Lenovo's recommendation to VirtualBox? (5.2.18) Right now I have out-of-the-box VirtualBox and the VM I created yesterday with standard settings does not activate:   Windows is not activated. Windows reported that no product key was found on your device. Error code: 0xC004F213


Are there alternatives to Calabi-Yau spaces describing dimensions in superstring theory? If yes, what are they? If no, why?


Creating a new variable by combining 2 field values

In my theme’s preprocess node function i’m trying to create a new variable by combining 2 existing fields, both of which are text strings.  pseudo code is this:   $teachers_name = $firstname + $lastname;  When looking at a print out of the Teacher object using Devel, i see the field first name is an array, structured like this…  field_first_name     und         0             safe_value ‘Lisa’   but so far it’s not working at all. i’m not accessing the variables correctly.   function myTheme_preprocess_node(&$variables){     if($variables['type']=='teacher') {         $variables['teachers_name'] = $variables['field_first_name’][‘und’][0]    [‘safe_value’];     }   how can i access the text string of field 'first name'? thanks!


how to change value of parameter recursive under folder

under /etc/sysconfig/network-scripts ,  we have network configuration files as   ifcfg-conf1 ifcfg-conf2  . . .   is it possible to change all parameters - PEERDNS to no , if value is yes  expected results on all ifcfg-xxxx files  PEERDNS=no    wrong  ifcfg-xxxx files configuration   PEERDNS=yes   the reason for this change is because /etc/resolve.conf changed after reboot so we need to change all PEERDNS variables to no


conditional expectation of brownian motion

Let $(B_t)_{t\geq 0}$ be a standard Brownian motion in $\mathbb{R}^d$. It is intuitive that, for fixed $s<t<u$  $$\mathbb{E}[B_t\mid \sigma(B_s,B_u)]=B_s+\frac{t-s}{u-s}(B_u-B_s).$$  However, I cannot think of a way to show this rigorously.   If first attempted to take $A\in\sigma(B_s,B_u)$ and show that $\mathbb{E}[1_A B_t]=\mathbb{E}[1_A(B_s+\frac{t-s}{u-s}(B_u-B_s))]$. But I cannot manage to show this equality.   I'd be very thankful for any ideas and suggestions on how to tackle this problem.


There seems to be a macro for typesetting the acronym LaTeX, but I cannot think of manual to look it up or search term that would return relevant results.  How can I typeset the word LaTeX as it usually appears in LaTeX documentation - with the vertically staggered letters?  I know this is going to be a duplicate, but cannot help it :(


The PC is Windows. I wanted the ubuntu environment, I put the ubuntu iso file on the USB. After that, if I try to restart and start ubuntu, I get an error like the following.  The details of the error are the two statements below. (initramfs) Unable to find a medium containing a live file system[figure ex.)  135.392108] usb 3-4: device descriptor ewad / all, error -110I   tried variously, but it was useless. (I tried BIOS etc. but it was useless.What I want to do is to have Ubuntu portable on the USB. However, I want to prevent any Windows from being broken. I do not know the meaning of 2.0 / 3.0 on the USB drive side and socket side. The one that I use is USB 3.0. Ubuntu version is 18.04.2. The iso. file was loaded with Universal-USB-installer. I tried both UEFI and LEGACY mode with BOOT on the BIOS screen, but it was useless. PC is VersaPro made by NEC. I did it with both Universal USB installer and rufus, but it was useless. md5sum, I did not check it.


Where can I find a standalone installer for Windows 7 Service Pack 1?

I've searched everywhere and can't find a standalone MSI or EXE for Windows 7 Service Pack 1.    Does it exist somewhere?


How to compute PCA scores from eigendecomposition of the covariance matrix?

Given a data matrix $\mathbf X$ of $12 \times 7$ size with samples in rows and variables in columns, I have calculated centered data $\mathbf X_c$ by subtracting column means, and then computed covariance matrix as $\frac{1}{N-1} \mathbf X_c^\top \mathbf X_c$.  The dimensions of this covariance matrix are $7 \times 7$. After that I have calculated the eigenvalue decomposition, obtaining eigenvector matrix $\mathbf V$ with eigenvectors in columns.  Now I want to know about projections (i.e. principal component scores in PCA): is it $\mathbf{V}^\top \mathbf{X}_c$ or $\mathbf{X}_c \mathbf{V}$?  mean_matrix = X - repmat(mean(X),size(X,1),1); covariance = (transpose(mean_matrix) * mean_matrix)/(12-1);  [V,D] = eig(covariance); [e,i] = sort(diag(D), 'descend'); V_sorted = V(:,i);


Sometimes the symbol := is used to denote a definition. For example, X:=Y+Z means that X is defined to be Y+Z.  When using LaTeX, can I just use $:=$, or do I need to do something special?


Why should "theirs" not have an apostrophe?

What is the reasoning by which people decided not to use ’s to indicate the possession of pronouns?  For example, one might write   It is Jack's dog. The dog is Jack's.   But not   It is their dog. The dog is their's.   Why does using a pronoun not follow the same apostrophe-s pattern as used for the noun it replaces?


How can I revert to a recently saved game in borderlands 2?

Yesterday I finished the normal game by killing Jack.  Today I started borderlands 2 and selected my character. I was given three choices: "Normal," "True Vault Hunter" and "Cancel."  I selected "Normal," assuming I'd resume my game where I left off yesterday. Instead, I was dumped into a second playthrough. Our friend clap trap was digging around and guided me to his home. NOTE: I did not inadvertently select "True Vault Hunter." I selected "Normal" and was PLACED into a True Vault Hunter game.  I quit the game as soon as I was able, and was forced to save it. Resuming that "Normal" game placed me into the "True Vault Hunter" game. (They are one and the same.)  My local save data is the same data steam has on its cloud.  Is there any way I can revert my saved game back to the point where it was previously?  I'm playing a Steam copy of Borderlands 2 for PC if that matters.


What are the differences between deep learning and neural networks?

I am just starting out ML and was just reading through Deep Learning and Neural Networks. I know that they both are based on imitating the data processing function of the human brain and create similar patterns the brain used for decision making but how do these two differ primarily in their operation as well as their performance?


Why can't Discovery's Data Core be separated from the ship?

In the most recent episode S02E12 of Star Trek: Discovery,      USS Discovery faced the entire fleet of Section 31 which was after Sphere's data.   As Sphere's data doesn't allow itself to be deleted from the system,      Pike reached a decision to destroy the ship itself.   My question is: Why can't they simply remove the data core and destroy it? Why destroy a super expensive ship with unique Spore Drive?


Any examples of life forms on Earth that could have survived on Mars or Moon?

Do we know of any living forms on Earth that could continue to live on Mars?


When Ubuntu Desktop provides the set-up option, "Erase disk and install Ubuntu", what does that mean?

This question is fairly self-explanatory when installing Ubuntu directly onto a computer as the primary operating system. The difficulty arises when installing Ubuntu onto a VM like VirtualBox. The option and its warning could leave the user confused as to what actually would occur. The concern, of course, is in losing the underlying operation system and data. I think I know that it is okay to go ahead with this option, but Ubuntu could add in a little caveat to clear the air.


How can I encrypt the password with PHP? - MySQL

I can create a database with this query   $dbh->exec("CREATE DATABASE `$db` CHARACTER SET utf8 COLLATE utf8_bin;              CREATE USER '$user'@'%' IDENTIFIED BY '$pass';              GRANT USAGE ON *.* TO '$db'@'localhost' IDENTIFIED BY PASSWORD '*3D3B92F242033365AE5BC6A8E6FC3E1679F4140A';              GRANT ALL PRIVILEGES ON `$username\_$dbusername`.* TO '$user'@'localhost';")    But encrypted passwords are contained in the query:  '*3D3B92F242033365AE5BC6A8E6FC3E1679F4140A'   decryption version:  test1234   This automatically encrypted by MySQL and how can I encrypt the test1234 with PHP?  Full Version  $user='abc_dbuser'; $db="abc_dbname"; $pass='test1234'; $dbusername="dbname"; $username=get_current_user();      try {         $dbh = new PDO("mysql:host=$host", $root, $root_password);         $dbh->exec("CREATE DATABASE `$db` CHARACTER SET utf8 COLLATE utf8_bin;                     CREATE USER '$user'@'%' IDENTIFIED BY '$pass';                      GRANT USAGE ON *.* TO '$db'@'localhost' IDENTIFIED BY PASSWORD '*3D3B92F242033365AE5BC6A8E6FC3E1679F4140A';                     GRANT ALL PRIVILEGES ON `$username\_$dbusername`.* TO '$user'@'localhost';                     ")          or die(print_r($dbh->errorInfo(), true));


How to get ip address using javascript or jQuery?

I need to show IP address in page footer in static site is it possible to get IP address using JavaScript or jQuery...  I tried this but it is giving same value in all computers  <script> var myip; function ip_callback(o) {     myip = o.host; } </script> <script src="https://smart-ip.net/geoip-json?callback=ip_callback"></script> <script>alert(myip);</script>


Can an unbounded function have a finite integral?

I am wondering whether there exists a function such that:  $$\lim_{x \rightarrow a}f(x)=\infty$$  at some point $a$ on the real axis but yet,  $$\int_{-\infty}^{+\infty}\left|f(x)\right|\ dx<\infty$$  Does the fact that a function is unbounded imply that it has no finite integral?


I became target of mass downvote after I deleted one of the questions I asked (revenge downvoting for not upvoting the answer?) and now I can't ask any question again. What can I do now?