I know this is asked many times, but I couldn't exactly find what I need.  I want to get the server path and add image path to that. I did that   string mypath = Request.Url.GetLeftPart(UriPartial.Authority); string uploadPath = Path.Combine(mypath, "Upload/Images/"); Response.Write(uploadPath);   This printed http://localhost\Upload/Images/, why is there a \ in the middle of the path.  I fixed it by adding / to mypath like this  string mypath = Request.Url.GetLeftPart(UriPartial.Authority) + "/";   Is this the correct way? or is there is any better way to do this?


How can I view the complete Document file as well as the Large Files

In Mac HD Storage it shows 65 GB under Documents but the list in Large Files only shows a fraction of that. I need to delete files to get my Time Machine Backup running again. How can I do this if I can't see where the problem is?


Subgroup of an abelian group isomorphic to a given quotient group

STATEMENT: Let $H$ be a subgroup of a finite abelian group $G$. Show that $G$ has a subgroups that is isomorphic to $G/H$.  QUESTION: Could someone offer a proof using dual groups. I have found one use the fundamental theorem of finitely generated abelian groups, but I cannot seem to find on using dual groups.


Can there be conservation laws without a corresponding symmetry?

Noether's theorem implies that if there is a continuous symmetry in the Lagrangian of a system, this necessarily implies a corresponding conservation law. But does the theorem also imply the reverse? Is it possible for a system that obeys a conservation law to not have a corresponding symmetry in its Lagrangian?


Does a function $f$ converges at $+\infty$ if all $f(n+t)_{n\in\mathbb{N}}$ converge to the same limit?

It is well-known that, for any $T\in\mathbb{N}^*$, a sequence $(u_n)_{n\in\mathbb{N}}$ converges iff all sequences $(u_{Tn+r})_{n\in\mathbb{N}}$, for $0\leq r < T$, converge towards a common limit. I was wondering if this could be generalized to functions: Let $f:\mathbb{R}_+\to\mathbb{R}$ and $\ell\in\mathbb{R}$. Assume that for every $t\in[0,1)$, the sequence $(f(n+t))_{n\in\mathbb{N}}$ converges towards $\ell$. Does $f$ necessarily converges at $+\infty$? Of course, my intuition believes this result to be true, but I cannot manage to prove it, since the sequences $(f(n+t))_{n\in\mathbb{N}}$ for $t\in[0,1)$ could converge at very different rates…


What's the best way of counting the number of elements in a iterable (through iteration), without storing the elements in memory?  Right now, I'm just doing sum(1 for x in iterable). I was hoping to find something in itertools, but there doesn't seem to be anything.


I'm a beginner at LaTeX and I get a LaTeX error when I type this:  \begin{equation} {$k = \frac{\Delta U}{\Delta I} $} \end{equation}   Could someone tell me what to do?


javascript comparison, which one is correct and why?

Is there any Difference between   if(! (xyz === abc) ) { }   AND  if( xyz  !== abc ) { }   if both are same, which one should we prefer?


I'm currently studying for a theory exam in Abstract Algebra. One question is about first defining the concepts of even and odd permutations and then explain why these concepts are well-defined. So, I find this a bit difficult and I'm wondering if you guys can help me out?  Why are Even and Odd permutations well-defined?  Thank You


I used to be able to copy&paste (or type if I load respective keyboard layout) any kind of characters (eg. é ö ñ ß و 好) in my console/terminal.  Now I bought a new computer and it does not work any more, only English/ASCII characters (but in other programs, e.g. firefox, it still works).  Distribution: Ubuntu. Terminals tried: gnome-terminal, xterm, konsole.  I tried  but after reboot echo $LANG still gives C. I also tried setting Character encoding to Unicode(UTF-8) in the gnome-terminal Terminal-menu - without effect.  Question: How can I get a terminal that is able to deal with non-English characters?


Determining if file exists using c# and resolving UNC path

I am trying to write a function to determine if a file exists. The two methods prove to return inconsistent results (fileExists() seems to provide accurate results, compared to isFileFound(), that returns false positives - i would have expected an exception when trying to create the instance).   protected bool isFileFound(string path, string fileName)     {         System.IO.FileInfo fi = null;          bool found = false;         try         {             fi = new System.IO.FileInfo(path + fileName);             found = true;         }         catch (Exception e)         {             baselogger.Fatal(e.Message + " " + e.StackTrace + " \n" + path + fileName);         }          return found;     }      protected bool fileExists(string path, string pattern)     {         bool success = false;          try         {             success = File.Exists(path + pattern);         }         catch (Exception e)         {             baselogger.Warn(e.Message + " " + e.StackTrace + " " + e.Source);         }          return success;     }   Neither seems to be able to resolve a UNC path of the following syntax: \\abcserver\c$\xyzfolder\foo.bar  Any idea why the unc path is failing for these methods would be greatly appreciated.


how to return double datatype inside a function with 4 decimal places?

How to return double datatype with 4 decimals in a function in java ?     public static double fun(){     double d=2.5d;     String s=String.format("%.4f",d);     double ans=Double.parseDouble(s);     return(ans); }  actual output=2.5 expected output=2.5000


I have exported the PATH but once I switch to a different terminal or reboot Debian, $PATH is reset. Here are the steps I take:  ~$ vim scripts.sh  #!/bin/bash echo "Hello"   I save it as mybash.sh and chmod with 755. Then I move it to my /root/scripts directory.  Then:  ~$ export PATH=$PATH:~/root/scripts   and it works, but once I reboot Debian, close or switch into another terminal, mybash.sh cannot be called.   Why doesn't it store PATH permanently?


Why are red blood cells not attacked by NK cells?

All cells containing a nucleus present MHC-I, while some specialized cells present MHC-II in addition to that. Since erythrocytes lack any MHC why do natural killer cells not attack them?    It is my understanding that any cell which starts presenting foreign peptides on MHC-I will undergo apoptosis after Th finds them, or if they stop presenting anything at all, they will be eliminated by the NKs.  So what mechanism prevents erythrocytes from being destroyed by the immune system?


how dependency injection helps to develop application classes in java

I am new to "Springs framework" in java. I want to know clearly about Dependency Injection.   Regular Java Class:         public class TextEditor {           private SpellChecker spellChecker;           public TextEditor() {           spellChecker = new SpellChecker();             }       }   Java Class using Dependency Injection(Springs):      public class TextEditor {          private SpellChecker spellChecker;          public TextEditor(SpellChecker spellChecker) {          this.spellChecker = spellChecker;            }          }   How these two programs are different & what is the most usefulness that we have here through Dependency Injection?


What does "don't be taking nothing off no man" mean?

I'm reading Gone With The Wind.   When the son left his homeland for America, his father told him:     Remember who ye are and don't be taking nothing off no man.   I can't understand it at all; could someone explain it to me?


I seen games like Kingdom Clash Castle Story   being able to launch AppStore within their game without minimizing their game. The AppStore page will just slide in from bottom, show a game page, and players can download that game, key in their password, close the page and they are still in the game.  Is there a way to do this? I can only minimize my own app, and open the Appstore.  Please advise. Thanks


Why does Chrome not play certain flash videos like the ones on this site?    Clicking on the "Play" icon inside the video does nothing. Please suggest a fix for this. It works fine on Internet Explorer and Firefox.  My plugins:


Is it safe to use a get request for deleting a row from database?

So lets say in my index.php i have a table which has a delete link which takes you to delete.php?id=x and in delete.php:  $id=$_GET['id']; $query="delete * from table WHERE id=".$id; mysqli_query($conn,$query);   Is it safe to do like that? isn't it SQL injection friendly?


Maximum size of attachments in an outgoing email?

I am using Apex to send emails with attachments to users.  For incoming emails, I know the maximum size of the email, including the attachment, is 10 MB. Email which are above 10 MB are not processed by Email Services and  are rejected with an email response back to the sender.  However, I am having trouble determining the maximum size for outgoing emails.  I've heard there's a 3 MB limit but haven't seen this documented.    Can you all confirm an outgoing limit on email or attachment size? What happens when the limit is exceeded?  What kinds of errors would I see? Is there any way to send emails more than this limit without leveraging any appExchange tool? Any ways?   Thanks in advance.


How to modify user messages without hacking core user module?

When "themeing" modules, especially core modules, as far as I know it is a good idea to take the module specific tpl.php files, duplicate the ones you need, and modify them once they're in the relevant theme directory.  However, what if I want to modify a .inc file? Is it the same process as with tpl.php files, or is there a better workflow? Basically what I would like to do is change some of the user status messages found in user.admin.inc in the core Drupal 7 User module. I'm not sure if editing this file directly is a good idea. Thoughts?


I've been trying to prove that if $p \ge 5$ is a prime, then  $\sum_{k=1}^{p-1} \frac{(p-1)!}{k} \equiv 0 \pmod{p^2}$.  Unfortunately, I have no good ideas on how to start a proof. I worked out the sum for p=5 and p=7 to see if a pattern is noticeable, but I couldn't spot any useful patterns or properties. Just based on the $(p-1)!$ term I thought Wilson's theorem may be useful, but I was unable to see if this is truly the case. Can anyone please give me a hand with this proof? Thanks.


How many items can I REALLY hold in my bag in Pokemon Go?

In my bag, it says how many items I have out of 350. But currently it says    ITEMS 351 / 350   which is a bit odd, and seemed to suggest that 350 is not actually the limit. So I looked it up and Niantic's  says     Your Bag can hold an inventory of 500 items. You will not be able to gather new items from PokéStops when your Bag is over the 500 item limit.   So what is it? 350? 500? 350 plus some buffer amount?


I don't understand slicing with negative bounds in Python. How is this supposed to work?

I am a newbie to Python and have come across the following example in my book that is not explained very well. Here is my print out from the interpreter:  >>> s = 'spam' >>> s[:-1] 'spa'   Why does slicing with no beginning bound and a '-1' return every element except the last one? Is calling s[0:-1] logically the same as calling s[:-1]? They both return the same result. But I'm not sure what python is doing exactly. Any help would be greatly appreciated.


But you can't find anything while you're crying.   But you can't find anything when you're crying.   I'll tell you about it while Frank saddles the horse.   I'll tell you about it when Frank saddles the horse.     When should I use when, and when while? Are these sentences correct?


Can a player respond while a spell is resolving?

I cast  on my opponent, whose hand has two Mountain cards. Wistful Thinking resolves and my opponent draws a  and another Mountain.  Can my opponent cast Shock before discarding it?


Automatic italian decimal separation in $$

is there a way to set automaticly comma-decimal separator in latex in the "environment" $$ ? I mean having a 1,23 instead 1.23 by typing $1.23$. I tried to set by my own without any success, by inserting    \sisetup{output-decimal-marker={,}}.    But it didn't work. Any ideas? Thank you


In Fallout 4, is stealing from enemies disliked?

Sorry if it's a stupid question. I haven't even made the character yet so I thought I'd ask before I invest time. Say my companion is Curie and I'm a sneaky character hiding from a raider in power armor. Will I see, "Curie disliked that" if I pickpocket the power core? Or if I steal people's weapons before I fight them? Am I shoehorned to use Cait if I have the pickpocket perk?


How can i change the default name for the screenshots made by gnome-screenshot?

Gnome-screenshot 3.1.2 uses filenames like this one      Screenshot at 2011-07-31 12:13:04.png   making it rather easy to see when it was taken.  The problem is that it uses the colon ( : ) character - making it impossible to access such an image from Windows.  Considering I take most of my screenshots so I can send them to Windows users this has caused some problems.  Is there any way to change the default name that is used by the screenshot tool to replace the ":" with "." or "," ?


Package gnome tweak tool is not available. package 'gnome-tweak-tool' has no installation candidate

I can't find GNOME Tweak Tool in Ubuntu Software and it isn't found when I try to install it with APT  package 'gnome-tweak-tool' has no installation candidate   What should I do?


"Undefined" reference to class member in C++

While linking this code:  #include <map> using std::map; #include <string> using std::string; class C { public:     static void dump() {         for (const auto& e : data) {             string(e.first);         }     } private:     static map<string,map<string,string>> data; }; int main() {     C::dump(); }   ... I get this error:  /tmp/cc4W2iNa.o: In function `C::dump()': test.cpp:(.text._ZN1C4dumpEv[_ZN1C4dumpEv]+0x9): undefined reference to `C::data' collect2: error: ld returned 1 exit status   ... from g++ (GCC) 4.9.1. Am I doing anything wrong?


On my Samsung Galaxy S2 all answers appear as black box. Here is an example:    I am running Android 4.0.3


Let $ A $, $ B $ and $ C $ be sets. If $ A \cup B = A \cup C $ and $ A \cap B = A \cap C $, then show that $ B = C $.

I’m stuck on this one problem in my textbook regarding proofs in set theory. I’ve done the following so far:  Let $ x \in B $. As $ B \subseteq A \cup B $, we have $ x \in A \cup B $, so $ x \in A \cup C $ because $ A \cup B = A \cup C $. Hence, $ x \in (A \cup B) \cap (A \cup C) $, which yields $ x \in A \cup (B \cap C) $. Now, either $ x \in A $ or $ x \in B \cap C $. If $ x \in B \cap C $, then $ x \in C $ because $ B \cap C \subseteq C $, so $ B \subseteq C $.  This is only half of the proof, though, as I have to prove that $ C \subseteq B $ as well; and I also haven’t even considered the case $ x \in A $ for the last step in what I have so far. I’ve drawn many different Venn diagrams, and although I see why the statement is true, I just can’t formalize it. Any pointers, help or guidance is very much appreciated. Thanks!


How to get the complete Binary Data of a byte array on another String in Java

I Have used a byte Array like this:  byte[] fileContents =  Files.readAllBytes(path);     for(int i = 0 ,j = 1; i <fileContents.length ; i++)         FileContents += Integer.toBinaryString(fileContents[i]);          System.out.println(FileContents);   but when I run this on a File containing :  Ananay   it shows this:  java.lang.NullPointerException at java.lang.String.replace(String.java:2239) at UEX.<init>(UEX.java:21) at test.testEncryption(test.java:38) at __SHELL54.run(__SHELL54.java:5) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at bluej.runtime.ExecServer$3.run(ExecServer.java:743)   Thanks in advance.  (I prefer to use a String in this case even though it is not recommended)


Suppose there exist infinite subsets $X_1, . . , X_n$ of F such that f($x_1, . . , x_n$) = 0 for all ($x_1, .. , x_n$) ∈ $X_1 × · · · × X_n$.

Let f($t_1, . . . , t_n$) be a polynomial over a field F. Suppose there exist infinite subsets $X_1, . . . , X_n$ of F such that f($x_1, . . . , x_n$) = 0 for all ($x_1, . . . , x_n$) ∈ $X_1 × · · · × X_n$. Prove that f is the zero polynomial.  The related material is integral extensions, so I want to incorporate that area of maths to a solution.


Show that for any integer $x, ax\not\equiv1\pmod{a\cdot b}$ where $a,b$ are integers that $1<a$ and $1<b$

If $m$ is a natural number greater than $1$ and is not prime, then we know that $m=ab$, where $1<a<m$ and $1<b<m$. Show that there is no integer $x$ such that $ax≡1\pmod{m}$.   My thoughts:  What I think is $ax$ can only congruent to multiple of $a$ under mod $a\cdot b$ and since $a>1$ that means it could never congruent to $1$.  \begin{align} ax&\equiv y\pmod{a\cdot b}\tag*{Let $x\in\mathbb{Z}$, solve $y$}\\ y&=a(b\cdot k+x)\tag*{Case1: $ax<ab;k\in\mathbb{Z}$}\\ y&=a(x-b+b\cdot k)\tag*{Case2: $ax\ge ab;k\in\mathbb{Z}$}\\ y&\neq 1\tag*{Since $a>1$}\\ \end{align}  Is this idea correct, are there other approaches to prove this statement ?


Show that if a complex polynomial is such that all its zeros have negative real part, then the zeros of its derivative also have negative real part.

Let $P(z)$ be a complex polynomial whose zeros all have a negative real part. Show that the zeros of $P'(z)$ all have negative real part.  I've thought about factoring $P(z)$ into linear factors, or maybe induction. But I can't seem to get that to work.  It was also suggested that I try doing the "logarithmic derivative" after I factor. I.e., taking the derivative of $ln(P(z))$. But it's not clear to me how this helps, since logarithms over the complex plane don't necessarily "split" across multiplication; i.e., $Ln(zw) \neq Ln(z)+ Ln(w)$.  Any thoughts would be appreciated.  Thanks in advance.


"How to write a program in Pascal?" vs "I know how to write a program in Pascal"

Am I right that we use the same wording to ask a question and to to state something (not a question), when we use "how"?     How to write a program in Pascal?       I know how to write a program in Pascal.


I was learning SHM and I came across equation $k = mw^2$

I tried searching for proofs here and there but couldn't find.. Some people used $a= w^2 x$ to prove this.. But how do you prove that?


Let $G$ be a finite semigroup .Prove that there exist $x\in G $ such that $x^2=x$  How to approach this problem.i know i have to use that $G$ is finite set. but from where to start.  please  provide any hint where to start with ??


I never fully understood why the Lagrangian density (let's say for a scalar field) was restricted to have only first order derivatives of the field in time and space in QFT. One reason I can think of is to ensure locality. But that doesn't restrict one from having a finite number of higher-order derivatives of the field, does it? Thanks!


Minecraft Won't Let Me Break Any Blocks At All

I'm on minecraft, I made sure that my game mode is creative, so I don't need to hold to break blocks. Yet, I am unable to break ANYTHING. Not even DIRT. I can still place blocks, I just can't break them. Can't break any blocks in survival either..... I also cannot kill mobs. And I'm most definatly not in adventure mode! Please Help! It's been going on for weeks!


How do I split large numbers into groups of five digits?

I need to split a number of 27 digits into groups of 5 digits. I already had a look at siunitx, telprint and numprint. But these just allow me to generate groups of two or three digits. Is there any known way to do split the number into groups of 5?


Two trampolines - one renders - one does not. Why?

So I'm struggling with these two trampolines. For some reason, the big one renders - the small one does not. And I can not figure out why. Except for the size they should be exactly the same.


$5^{e}+6^{e} \equiv 0 \pmod {11}$ for all odd numbers $e$ and for no even numbers $e$

We wish to show that $5^{e}+6^{e} \equiv 0 ($mod$11)$ for all odd numbers $e$, but not for any even numbers $e$. This comes from Childs' book "A Concrete Introduction to Higher Algebra." I'm not too sure where to even start, so I would love to make a little headway and show some effort, but I'm genuinely stumped on this one. Haven't done hardly any proofs involving modular arithmetic. Can someone help me out, or at least provide a bit of a startup?


Is there an infinite connected topological space such that every space obtained by removing one point from it is totally disconnected?

The particular point topology on any set is connected, but on removing the particular point, the complement is discrete, and hence totally disconnected. Although this is not even $T^1$,  also has this property, and is a subspace of $\mathbb{R}^2$.   Is there an infinite connected topological space such that the complement of every point is totally disconnected? Or in other words, is there an infinite connected space such that every proper subset of at least two points is disconnected?


JavaScript: Get element's size if it's not explicitly defined via CSS

Is there any way I can get current html element dimensions (width/height) if they are not explicitly defined in CSS? Using just JavaScript? For example if I have image  var image = document.getElementsByClassName("top-image")[0];   And let's say I have click event. How can I get dimensions in the moment when event happened?


Giving access of a set of commands to a non-root user without sudo

I want to give non-sudo access to a non-root user on my machine, there is a user dns-manager, his only role is to run all the BIND commands(rndc, dnssec-keygen) etc.   Now everytime he has to run a command, he types,  sudo rndc reload   Is there a way I can get rid of this sudo, but only on a particular set of commands(and only for dns-manager)?


I know that $a(b)^{-1}  b(b+d)^{-1} + c(d)^{-1}  d(b+d)^{-1} = (a+c)(b+d)^{-1}$.  Can this identity help me to prove the inequality?


How can I compose a multipart/form-data request?

I'm trying to integrate Kraken.io into our org so I can have Salesforce queue up image optimization jobs that our employees upload. Kraken.io requires that the requests post a multipart/form-data body which contains a JSON parameter and the file. I'm porting code from C# where I could just write to the request stream, but in APEX with the HttpRequest class this doesn't seem to be possible. How can I go about creating a request that can do this?


Apache2: ReWrite rule behaving strangely

I have the following in my .htaccess file:  <Directory /home/eamorr/sites/example.com/www>                 Options Indexes FollowSymLinks MultiViews                 Options -Indexes                 AllowOverride all                 Order allow,deny                 allow from all                  RewriteEngine on                 RewriteRule ^([^/.]+)/?$ index.php?uname=$1 [R,L] </Directory>   When I go to ,  appears in the address bar!  But I want  to appear in the address bar!!!  (I need to parse the URL in javascript in index.php)


Maximum power transfer for unknown resistance

– Schematic created using   Hi,  I am trying to find out what should be the value of resistor connected across node 'ab' for maximum power transfer. So far I have tried working out by hand and I don't think I have got the right values. I have shorted out voltage source to find thevenin resistance and considered R1 parallel with (R2+R3) and (R4+R5). Can anyone please help me to find out equivalent thevenin circuit.


I was working on a project and I don't know how but the viewport started hiding things out of a camera range... I tried deleting the camera but it did not work.. here is how it looks like:  the archive:   EDIT: So, I think this is probably a glitch. I tried to open it with blender 2.8 and the problem just disappeared.. I cannot save it in 2.8 tho because I Still want to use it in 2.79b.


PHP + SQL Script - Protect against SQL Inject

I'm using unity to pass values to my php script with HTTP GET. I am new to php and just got my script to work, however, I would like to make sure I can protect against SQL Injection. Can someone please look this over and let me know what I need to change in order to protect it?  <?php  $servername = "localhost"; $username = "Test"; $password = "Test"; $dbname = "Test";  $userId = $_GET['userId'];  // Create connection $conn = new mysqli($servername, $username, $password, $dbname); // Check connection if ($conn->connect_error) {     die("Connection failed: " . $conn->connect_error); }   $sql = "SELECT rp FROM RP where userID = '$userId'"; $result = $conn->query($sql);  if ($result->num_rows > 0) {     // output data of each row     while($row = $result->fetch_assoc()) {         //echo "UserID: " . $row["userID"]. " - RP: " . $row["rp"]."
";     echo "RP: " . $row["rp"]."
";     } } else {     echo "0 results"; } $conn->close(); ?>


After a failed dual-boot install, only Ubuntu boots. How can I remove Ubuntu and boot in Windows again?

I'm new to Linux, I wanted to install Ubuntu and installed successfully with the Universal USB installer. My notebook has frozen and I was forced to shutdown.  When I started notebook again, it appeared to only boot Ubuntu.  I wanted to have both Windows and Ubuntu and to have possibility to select during the boot.  But unfortunately I can select only Ubuntu.  Now I would like to delete Ubuntu in order to recover all the information that I had on Windows.  I have tried and update-grub, but is not working, I don't have Internet connection.


, "Note that the operators are in time order...we can insert $T$ without changing anything". This I agree with. But then on the next paragraph he states "The time order operator $T$, moves all...where they annihilate...". How correct is this paragraph? Is equation (5.14) always valid? Is equation (5.14) the reason why the time-ordering symbol $T$ appears all over the place in QFT?  The equations I'm referring to are (braket package available?):   $$\langle f|i\rangle = \langle0|~a_{1'}(+\infty)a_{2'}(+\infty)a_{1}^\dagger(-\infty)a_{2}^\dagger(-\infty)~|0\rangle \tag{5.13} $$  and since time goes from right to left inside the braket we put the $T$-symbol  $$\langle f|i\rangle = \langle 0|T ~a_{1'}(+\infty)a_{2'}(+\infty)a_{1}^\dagger(-\infty)a_{2}^\dagger(-\infty)~|0\rangle \tag{5.14} $$   without changing anything.   After this, the $T$-symbol appears everywhere!


If you multiclass into two spell casting classes, what level of spells can you choose?

If you multiclassed into two different spell casting classes, would the level of spells you are allowed to choose depend on your total level of spell slots or the highest you could have from the specific class? I always though it was the former but Matt Mercer disagrees.   For example, if you were a wizard 3 cleric 2, would you be able to have level 1 or 2 wizard spells, and level 1 cleric spells, or up to level 3 of both.


Example of a non-isomorphic map from $D^{-1}R$-modules

Let's suppose $R$ is a ring and $D \subset R$ is a multiplicative subset.   If we look at these two $D^{-1}R$-modules:   $D^{-1}(\operatorname{Hom}_R(M,N))$ and $\operatorname{Hom}_{D^{-1}R}(D^{-1}M,D^{-1}N)$ and consider the naturally defined homomorphism from $D^{-1}\operatorname{Hom}_R(M,N)) \rightarrow$  $\operatorname{Hom}_{D^{-1}R}(D^{-1}M,D^{-1}N)$  is there an example of $R, D, M, N$, when the homomorphism is not an isomorphism?


Is there any alternative to using % (modulus) in C/C++?

I read somewhere once that the modulus operator is inefficient on small embedded devices like 8 bit micro-controllers that do not have integer division instruction. Perhaps someone can confirm this but I thought the difference is 5-10 time slower than with an integer division operation.  Is there another way to do this other than keeping a counter variable and manually overflowing to 0 at the mod point?  const int FIZZ = 6; for(int x = 0; x < MAXCOUNT; x++) {     if(!(x % FIZZ)) print("Fizz\n"); // slow on some systems }   vs:  The way I am currently doing it:  const int FIZZ = 6; int fizzcount = 1; for(int x = 1; x < MAXCOUNT; x++) {     if(fizzcount >= FIZZ)      {         print("Fizz\n");         fizzcount = 0;     } }


If $a = r \pmod b$ when $0 \le  r < b$, then $\gcd(a, b) = \gcd (b, r)$.  I do not understand why this is, can somebody explain?  I've also looked over this thread:  , but I still can't seem to see how that applies to $a = r \pmod b$.


An expression that is the opposite of Mortons's fork

Morton's fork is a situation where all outcomes are unpleasant. Is there an expression or term that describes a similar situation, but instead all outcomes are pleasurable/beneficial except only one choice can be made.   Crude example:  If you have the option of either riding a nice train to destination and the fly back on a private plane, or fly in a private plane to destination and then take the nice train back. In both circumstances everything would be the same, and neither would do you a disservice. *That is assuming that neither both are working at 100% and nothing happens, or if something happens it is equally as likely it will happen in both situations.


Validity of Schengen Visa after first visit

I have a valid Schengen visa which was used for a business trip to Sweden in Oct 2019. It's valid upto 1 year and is a type 'C' visa with multiple entries allowed.  Now, I want to visit Italy(maximum stay) and Switzerland in February 2020 for tourism purpose. Do I need to get fresh visa for this visit or will the old visa suffice.


How do I make an Bootable Ubuntu USB containing the the latest version of Ubuntu?  For completeness, how would I be able to do this on Ubuntu, Windows, OS X or another Linux distro?


yesterday I did a fresh install with ubuntu 17.10.   Then I did some playing around with themes and extensions. Then I did a reboot and after the reboot the gnome-bar became very ugly.   It should look like this:   (light transparency of the bar, calendar in center)  But instead it looks like this:     (No transparency, calendar at the right side, theme doesn't seem to apply)  How do I get back the nice gnome panel from the first screenshot?     additional notes:   After the reboot, that broke the bar, also a lot of extensions appeared. I couldn't remove them via extensions.gnome.org/local/, so I removed them via rm -r. For some reason those unwanted extensions come back, when I do sudo apt-get install --reinstall gnome-shell-extensions. I'd like to get rid of them permanently, but for now I'm fine.


I have a table contains tens, hundreds, or thousands numbers with or without decimal. I need those numbers to be aligned at ",", the decimal symbol (Indonesian). I try to use \newcommand\ph{$\phantom{1}$} but it doesn't work well. The number posisition didn't aligned at ",". Please help, thank you.  This is my MWE:       \documentclass[10pt,a4paper]{article}   \usepackage[utf8]{inputenc}   \usepackage[T1]{fontenc}   \usepackage{amsmath}   \usepackage{amsfonts}   \usepackage{amssymb}   \usepackage{graphicx}   \usepackage{multirow}   \newcommand\ph{$\phantom{1}$}    \begin{document}       \begin{table}[h]           \centering           \caption{Hasil Belajar Matematika}           \begin{tabular}{l|c|c|c|c}               \hline   \multirow{2}{*}{Statistik}& \multicolumn{2}{c|} {Eksperimen}&\multicolumn{2}{|c}{Kontrol}\\               \cline{2-5}               & {Pre-tes} &  Pos-tes  & Pre-tes   & Pos-tes   \\               \hline               Sampel          &   24      &    24     &        24 &  24   \\               Jumlah          &   928     &   1491    &   1184    &1585   \\                 Rata-rata       &   48,46   &    77,83  &    49,50  & 66,12 \\               Maksimum        &   75      &    100    &   70      &94     \\               Minimum         &   26      &    43     &   33      &35     \\                 Std. Deviasi    &   13,603  &    16,029 &   12,022  &15,066 \\               Varians         &   185,042 &    256,928&   144,522 &226,984\\               \hline           \end{tabular}       \end{table}   \end{document}


Is there a way to get all the location of an Annotation?

The only solution I know to get all the classes and examine whether they have a specific annotation.    for (Class clazz : classes){             clazz.isAnnotationPresent(SomeAnnotation.class);   }   I would like to use something like this:   List<Class> classesUsingAnnotation = SomeApi.getAllTargetTypeForAnnotation(SomeAnnotation.class)   Is there any API out there for this?


How do I open Internet Explorer on Windows 10?

I am running Windows 10 and need to be able to use Internet Explorer for some work, but I can't seem to locate it. I've already tried typing 'Internet Explorer' in Cortana search but it didn't work.  How can I open Internet Explorer on Windows 10?


It started after I updated my BIOS settings (virtualization and fast boot). I think I returned them back in place, although I might have changed something and forgot. But my system can't boot normally now for some reason and I don't know what's wrong and what should I check to fix it.  I only see GDM loading bar and then blinking of blank screen with occasional terminal on the startup. I managed to switch to another terminal before but it seems that now I can't even do that -- the login prompt is replaced with black screen again after 2 seconds.  I had a lot of pain setting up the system already, mainly because of the new nvidia card. But now I'm not sure what to check for.  The Secure Boot option is disabled, so that is not the problem.


Imaging new hard drive in Windows 7 laptop?

I'm upgrading my Windows 7 laptop to a new hard drive.  How can I clone or image the old hard drive over to the new hard drive, so that it looks like nothing has changed (other than the new hard drive) to my operating system and applications?  Can I use what is built into Windows 7 Backup or should I use something else?


Proving that the limit of a sequence lies within the range of the sequence.

If $a < x_{n} < b$ and $\lim_{n \rightarrow \infty}x_{n}=x$ then prove that $a \leq x \leq b$. I am taking two case where the sequence is monotonic and non-monotonic. If the sequence is increasing then it would converge to its supremum and if its decreasing then it will converge to its infimum, hence the limit being greater than $a$ and less than $b$. But I am not sure how to go on about the non-monotonic case.


Why do many equations need squared powers?

It seems that an equation factor must be “squared” as a convenient approximation to balance out some other series of factors invisibly . Might $E=mc^{1.95}$  work as well as $E=mc^2$? Might $A^2+B^2=C^2$ also work if all the factors used the same but different power and be even more accurate? Does anyone know of such a triangle that the current formula comes out to an even number.


Inheritance (IS-A) vs. Composition (HAS-A) Relationship in java

Inheritance (IS-A) vs. Composition (HAS-A) Relationship  please someone explaine what is Inheritance (IS-A & HAS)relationship in java


I've got serious problem with this stupid file manager. When copying files from internal HDD to removable drives on USB 2.0 ports, the speed skyrockets to 70MiB/s, while the theoretical speed of an USB 2.0 port is only 32MiB/s.  After the files "finish" copying, if I leave my portable drive there for a while, it will be okay. But if I unmount the volume immediately and unplug it from the USB port, the files become corrupted.  I wonder if Canonical ever tested such horrible feature before releasing their software to the public? For now, all I want is to disable that caching mechanism. I'm using Nautilus version 1:3.26.4-0ubuntu7.2 on 18.10.  P.S: if anyone is going to say it was because of the drive's internal caching machanism, I can tell you that this bug does not happen on Windows at all. I have to reboot into Windows only to copy big files to the portable HDD.


How to return only latest record on join

I'm joining tables. I only want to return one record from the joining table, based on a date field.  Here's a simplified fiddle of what I've done so far:   My tables:    CUSTOMER  | CustomerID | -------------- | 1          |     PURCHASE  | PurchaseID | CustomerID | ProductID | CreateDate | ArchiveFlag | ------------------------------------------------------------------ | 1          | 1          | 443       | 01-FEB-15  | F           | | 2          | 1          | 551       | 01-MAR-15  | F           | | 3          | 1          | 151       | 01-JAN-15  | F           | | 4          | 1          | 654       | 01-MAY-15  | T           | | 5          | 1          | 345       | 01-APR-15  | T           |   and here's the query itself:  select * from customer c join purchase p on c.customerid = p.customerid and p.archiveflag = 'F';   I only want to return the latest purchase that isn't archived (in this example, purchase ID 2) for each customer.  Ideal output:  | CustomerID | PurchaseID | CustomerID_2 | ProductID | CreateDate | ArchiveFlag | |-------------------------------------------------------------------------------- | 1          | 2          | 1            | 551       | 01-MAR-15  | F           |


Why do we need a Theory-Of-Everything (TOE)?

On the heels of some of the discussion about the recent , what are the key reasons why we need a TOE?  The obvious immediate response is that a TOE should give us a means of making predictions in quantum gravity, but what else might be motivating the need for a TOE.  Is it economical to continue the search?  If this question passes muster, I request respondents avoid the typical debate surrounding string theory in the popular press.  In that context, I think the appropriate question is whether a TOE should be able to solve its , or can one even formulate a consistent theory that can accomplish that task.


Not sure if I should use relative imports or add parent dir to sys.path

I have a package with the following hierarchy  my_package/__init__.py            script_a.py            scripts_dir/__init__.py                        script_b.py            my_package/__init__.py                       module_a.py                       module_b.py   module_a and module_b contain function and class definitions that I am using in script_a and script_b (which are stand alone scripts and contain a main)  When I import something from let's say module_a.py in my script_a.py everything is fine.  My problems are   I cannot figure out how to use relative imports to import something from module_a or module_b to script_b.py I am not sure if I am supposed to use relative imports or if it makes more sense to add my_package to sys.path and then use something like from my_package.module_a import the_funky_func I want to avoid having to call the interpreter with the -m argument   update  From the answers I have found so far in SO I have concluded that I have 3 options    write a setup to include the package to my PYTHONPATH so that all scripts regardless of where they are can call the modules use the -m argument when invoking the interpreter do some sys.path hack   Is there another option that I am not aware of?


I have a algorithm and from the post its time complexity is: $\sum_{k=1}^{n}k\binom nk= n 2^{n-1}$

I have a algorithm and from the post its time complexity is:  $$\sum_{k=1}^{n}k\binom nk= n  2^{n-1}$$  My question is, how to get the result $n2^{n-1}$ need some help . thanks


Spam Profiles are getting my goat. Could we have better tools for mods to deal with profile spam?

Super User got hit by another batch of spammers creating profiles. They've got accounts on other sites from what I've heard from other mods and from the comments here.  Last time it was streaming. Now it's  (as of december, looks like they're spamming scammy finance too). I have 160+ pages of users from that search, and a quick look suggests most of them are spammers. Comments from this post indicates it's network wide - and a quick check indicates Stack Overflow has a handful of these too, though not as many as we have.  While the powers at be have been taking action, both directly, and indirectly, it feels like between shared IPs and search, mods might be able to take a good chunk of these out if we can somehow have a way to delete accounts somewhat in bulk. You guys are awesome. But these... People keep doing it still, and it would be nice to see their works undone.  Unlike our streaming spammers, they've switched to phone numbers, presumably because Adam so kindly blocked links.    There's a few good suggestions at mitigating these - but ideally - I've heard from fellow mods that we want them gone.  They add to the broken window effect - which we can't do anything about due to sheer volume, and they probably poison our search engine results.  We can probably reduce the risk of oops by filtering by IPs (clearing everything on an IP lets me whack, 10, or so users at once, rather than clicking through 3-4 pages a user) and optionally selectively not deleting accounts that seem legit, we can probably clear out a bunch of these without really needing CM intervention. It does make it a little too easy, but these incidents, well kinda need a flamethrower's gentle warmth.  I'm cool with a no. I'm probably going through the usual channels in future. Would be nice to have something that lets mods deal with this effectively though.  Related:    - Actually goes into the impact of this  by a user - so clearly these are discoverable to an average user


Proving that $\sum\limits_{k=0}^{n} {{m+k} \choose{m}} = { m+n+1 \choose m+1 }$

I have to prove that:     $$\sum_{k=0}^{n} {{m+k} \choose{m}} = { m+n+1 \choose m+1 }$$   I tried to open up the right side with Pascal's definition that: $$ { n \choose k} = {n-1 \choose {k}} + {n-1 \choose {k-1}}$$  Here is what I came up with, and I am sure it is wrong because it does not equal the left side:  $$ {m+n+1 \choose m+1} = {m+n \choose m+1} + {m+n \choose m} = ... ={m+n \choose m+1} + {m+n-1 \choose m} + {m+n-2 \choose m-1} + ... + {m \choose m+1} = \sum_{k=0}^{n} {m+k \choose m+k-n+1 }  $$  Which, again, probably is wrong because it is not equal $\sum_{k=0}^{n} { m+k \choose m}$. Any help is appreciated


I was setting path for anaconda. an answer to a question  has the following solution. I searched for .bash_profile, but I can't seem to find it. How do I setup this file and get it to run on startup?


Understanding JavaScript function declaration syntax

After using JavaScript for a while, I came up with some questions.   The way to declare a function is:  var myFunction = function(param){//code here}   But there is also another way to declare a function which is  function myFunction(param){//some code}   What's the difference between the two methods to declare a function?  My second question is, I've understood that you can create an object from a function that's declared as:  function Person(name){this.name=name;}   And then, you can have another function declared like this:   function Speak(){console.log(this.name);}   How does the function Speak knows that it's related to the Person Object?


div with the id="(name)" can I use this or not?

Can I use id with "(" and ")" in jquery mobile ?  for example:  <div id="RSI(3,4)"> </div>   I have tried that id and want to access that element in js.  $("#RSI(3,4)").html("some text");   but it didn't worked.


error tex capacity exceeded log files added

I am having a hard time figuring out where the problem is with my code/workflow. I previously posted this question , but then the same problem came straight back. When I run it in tex, I get an error input limit exceeded. The exact log is pasted below:  This is pdfTeX, Version 3.14159265-2.6-1.40.17 (MiKTeX 2.9.6210 64-bit) (preloaded format=pdflatex 2017.1.26)  26 JAN 2017 20:45 entering extended mode **./master.tex (master.tex LaTeX2e <2016/03/31> patch level 3 Babel <3.9r> and hyphenation patterns for 75 language(s) loaded. ("C:\Program Files\MiKTeX 2.9\tex\latex\base\article.cls" Document Class: article 2014/09/29 v1.4h Standard LaTeX document class ("C:\Program Files\MiKTeX 2.9\tex\latex\base\size11.clo" File: size11.clo 2014/09/29 v1.4h Standard LaTeX file (size option) ) \c@part=\count79 \c@section=\count80 \c@subsection=\count81 \c@subsubsection=\count82 \c@paragraph=\count83 \c@subparagraph=\count84 \c@figure=\count85 \c@table=\count86 \abovecaptionskip=\skip41 \belowcaptionskip=\skip42 \bibindent=\dimen102 ) ("C:\Program Files\MiKTeX 2.9\tex\latex\apacite\apacite.sty" Package: apacite 2013/07/21 v6.03 APA citation \c@BibCnt=\count87 \bibleftmargin=\skip43 \bibindent=\skip44 \bibparsep=\skip45 \bibitemsep=\skip46 \biblabelsep=\skip47 ) No file master.aux. \openout1 = `master.aux'.  LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 5. LaTeX Font Info:    ... okay on input line 5. LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 5. LaTeX Font Info:    ... okay on input line 5. LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 5. LaTeX Font Info:    ... okay on input line 5. LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 5. LaTeX Font Info:    ... okay on input line 5. LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 5. LaTeX Font Info:    ... okay on input line 5. LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 5. LaTeX Font Info:    ... okay on input line 5. \c@maskedRefs=\count88 ("C:\Program Files\MiKTeX 2.9\tex\latex\apacite\english.apc" File: english.apc 2013/07/21 v6.03 apacite language file LaTeX Info: Redefining \BPBI on input line 129. LaTeX Info: Redefining \BHBI on input line 130. ) ! TeX capacity exceeded, sorry [input stack size=5000]. \AtBeginDocument #1->#1  l.5 \begin{document}  If you really absolutely need more capacity, you can ask a wizard to enlarge me.   Here is how much of TeX's memory you used:  641 strings out of 493333  7639 string characters out of 3139188  74825 words of memory out of 3000000  4254 multiletter control sequences out of 15000+200000  3940 words of font info for 15 fonts, out of 3000000 for 9000  1141 hyphenation exceptions out of 8191  5000i,0n,4998p,136b,36s stack positions out of 5000i,500n,10000p,200000b,50000s !  ==> Fatal error occurred, no output PDF file produced!   I previously posted this question and thought I solved it but am having the same problem again.   The latex code I am trying to execute is below:   \documentclass[11pt,twoside]{article} \usepackage{apacite} \nocite{*}  \begin{document}   % title page. Edit as needed for future publications.  \title{Research Proposal} \author{Teererai Marange \\ Department of Computer Science \\ University of Auckland\\ \texttt{t.marange@auckland.ac.nz}} \date{January 26, 2017} \maketitle % end title page.    % abstract goes here \newpage \begin{abstract} Abstract goes here  \end{abstract} \newpage   % table of contents  \tableofcontents \newpage   %begin introduction  \section {Introduction} Lorem Ipsum Doremifaso   %\cite{Nedakeyword} use to cite     %references our biliography. This must go whereever we use our bibtex references  \bibliography{references} \bibliographystyle{apacite}   \end{document}   and the bib file that I am using to build the bibliography is below:   @misc{wikipedia1,   title = "Scripting language",   author = "Wikipedia",   url = {http://en.wikipedia.org/wiki/Scripting_language},   year = 2014, }


Catch 22 on moving from old-style passwords and mysql_upgrade

I have an ancient MySQL database that I've kept running for a very long time, probably about 14 years. Apparently, I'd missed to run mysql_upgrade on it long ago, perhaps during the upgrade from 4.x to 5.x (and ever since). Now, after upgrading to 5.6.22 (from 5.5.x) yesterday, I can no longer log in, and I also can't seem to solve the issue. Apparently, old-style password hashes have been deprecated for over 10 years, but I have never seen any warnings saying so, until it stopped working just now.  The first symptom something was wrong was this:  mysqldump: Got error: 2049: Connection using old (pre-4.1.1) authentication protocol refused (client option 'secure_auth' enabled) when trying to connect   I get the same error using mysql -u root -p. I got past that by using the --skip-secure-auth option to the mysql command. After that, :  SET old_passwords = 0; UPDATE mysql.user SET plugin = 'mysql_native_password', Password = PASSWORD('DBA-chosen-password') WHERE (User, Host) = ('user1', 'localhost'); FLUSH PRIVILEGES;   This fails:  ERROR 1054 (42S22): Unknown column 'plugin' in 'field list'   The solution to that error appears to be to run mysql_upgrade, which updates the mysql.user table to add the plugin column. However, that also fails, with this wonderful error:  # mysql_upgrade -u root -p Enter password:  Looking for 'mysql' as: mysql Looking for 'mysqlcheck' as: mysqlcheck FATAL ERROR: Upgrade failed   My guess is that this is because there is no --skip-secure-auth option to mysql_upgrade, so it can't log in. I tried to disable secure-auth for the server, but if I did it correctly, it didn't help. (Possibly because mysql_upgrade that ships with 5.6.x uses it by default and doesn't allow you to disable it?)  Does anyone have a solution to this? I'm not above things like temporarily disabling passwords etc. while solving it; the server is only accessible from localhost, and I'm the only local user.


How can I read all answers on Quora without having to register?

Quora only shows its first answer on a question's page, the rest gets blurred out.  It then asks the user to register to read all the answers. I really do not like such bullying tactics and I hence will never register.  Yet before I blacklist Quora entirely from my Google searches, I wonder if there was a way to read all the answers without having to register.


Vlc - package dependencies cannot be resolved

I tried to install Vlc 2.2 in Ubuntu 14.04 LTS as it not available on Ubuntu Software Centre using following commands:  sudo add-apt-repository ppa:mc3man/trusty-media sudo apt-get update && sudo apt-get install vlc    But it showed errors:  Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation:  The following packages have unmet dependencies: vlc : Depends: vlc-nox (= 3.0.0~~git20150319+r59816+33~ubuntu14.04.1) but 2.1.6-0ubuntu14.04.1 is to be installed    Depends: libavcodec55 (>= 6:9.1-1) but it is not installable or             libavcodec-extra-55 (>= 6:10~~git20131218.b3189af~ubuntu14.04.1) but it is not installable    Depends: libavutil53 (>= 6:9.1-1) but it is not installable    Recommends: vlc-plugin-notify (= 3.0.0~~git20150319+r59816+33~ubuntu14.04.1) but it is not going to be installed    Recommends: vlc-plugin-samba (= 3.0.0~~git20150319+r59816+33~ubuntu14.04.1) but it is not going to be installed    Breaks: vlc-nox (< 2.2.0~pre2-2~) but 2.1.6-0ubuntu14.04.1 is to be installed vlc-nox : Depends: libvlccore7 (>= 2.1.0) but it is not going to be installed        Recommends: libdvdcss2 but it is not installable E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.   now even if I try to install it using Ubuntu Software Centre it shows me error that package dependencies cannot be resolved.  Please help. Thanks in advance.


Why it is popular to use stochastic gradient descent in neural networks rather than the BFGS algorithm?

I have made two solvers to implement neural networks, one is based on stochastic gradient descent (SGD) while the other is based on the BFGS (Broyden-Fletcher-Goldfarb-Shanno) algorithm.   I have read a lot of material and find it is common to use SGD rather BFGS, but I have found that BFGS performs better than SGD.   Can anyone can tell me why people prefer SGD to BFGS?


Is there any advantage to using pedal straps over clipless pedals?

Other than not having to buy special biking shoes, is there any clear advantage to using pedal straps over clipless (aka clip-in or step-in) pedals?


List related nodes through the same referenced node?

I have two node types: book, author.  There is a node reference field in book which references a single author.  On a book node, I would like to display a list of the same author's books, which I don't know how.  It seems to me the solution will involve EVA, contextual filter and relationships.  I can list all the author's books in an author node using EVA and contextual filter. But it uses author's node ID, which is in the url. I don't think I can pass the referenced author's Nid in a book's url. Or can I?  I'm only 5 days into drupal, and don't know a thing about relationships, can someone help me get my head around this? thanks in advance!  [D7]


Showing utf8_general_ci data (non-eng) on php

I have saved my data on MYSQL database using "utf8_general_ci". I wrote it on Bangla font. But when I am trying to show data using php it is showing "????..." instead of showing the charecters.  <?php  $con = mysqli_connect("localhost","appsaadr_edu","pass","appsaadr_edu");  $result = mysqli_query($con,"SELECT * FROM lnews ORDER BY id DESC");  echo "{\"news\":"; $arr = array();  while($rows = mysqli_fetch_array($result)){     $test['id'] = $rows['id'];     $test['title'] = $rows['title'];     $test['text'] = $rows['text'];     $test['time'] = $rows['time'];      array_push($arr,$test);  }  echo json_encode($arr); echo "}"; ?>   What to do now?


Difference between “little”, “few”, “a little” and “a few”

What are the differences among “little”, “few”, “a little” and “a few”?   Are “little” and “few” synonyms?


Prove by epsilon-delta that $\lim \limits_{x \to 1} x^3-4=-3$

I need to prove that $\lim \limits_{x \to 1} x^3-4=-3$ with epsilon-delta.  My work  $\forall \varepsilon > 0 ,\exists \space \delta > 0: 0<|x-1|< \delta \implies |x^3-4+3| < \varepsilon$  Working with the consequent:  $|x^3-4+3| <  \varepsilon \iff |x^3-1| < \varepsilon \iff |x-1||x^2+x+1| < \varepsilon$  Multiplying the antecedent by $|x^2+x+1|:$  $|x-1|< \delta$ $/\cdot |x^2+x+1| \iff  |x-1||x^2+x+1|< \delta |x^2+x+1|$  Here i found a relation but i don't know how to proceed, and i don't know if this way is the best way to prove this. Any hints?


Why is the speed of light defined as 299792458 m/s?

Why is the speed of light defined as $299792458$ $m/s$? Why did they choose that number and no other number?  Or phrased differently:  Why is a metre $1/299792458$ of the distance light travels in a sec in a vacuum?


How to Fix: Exception thrown: write access violation. _Left was 0xCCCCCCCC

i am making a program that checks 20 files for the word "NULL" and if it is not present the program puts there a predefined word/ sentence When trying to run my program through the debugger is throws the exception: "Exception thrown: write access violation. _Left was 0xCCCCCCCC."  The main problem is that in the "iosfwd" file at line 506 an exception is thrown. I tried to rearrange the code and tried different snippets from here and there.  #include <fstream> #include <string> #include <Windows.h> #include <iostream> using namespace std;  string ending = ".txt"; string name = "Prog";  int main() { ofstream os; ifstream is; string a, nouse; string Progs[20]; is.open("tempstring.txt"); getline(is, nouse); is.close(); cout << "UPDATING DATABASE.. DO NOT EXIT!" << endl; cout << "String Called" << endl; for (int count = 1; count < 20 + 1; count++) {     cout << count;     string fname1 = name + to_string(count) + ending;     is.open(fname1);     getline(is, Progs[count]);     is.close(); } cout << "done 1"; system("pause"); for (int count = 1; count < 20 + 1; count++) {     string fname2 = name + to_string(count) + ending;     if (Progs[count] == "NULL")     {         os.open(fname2);         os << nouse;         os.close();          os.open("tempdone.txt");         os << 1;         os.close();         Sleep(500);         cout << "SUCCESS" << endl;         system("pause");         exit(EXIT_SUCCESS);     } } cout << "done end" << endl; system("pause"); os.open("tempdone.txt"); os << 2; os.close(); exit(EXIT_FAILURE); }   Part of iosfwd:      static _CONSTEXPR17 void assign(char& _Left, const char& _Right) noexcept     {   // assign an element     _Left = _Right;     }   i expected the program to continue through the loop normally, but instead when i try to run the program without debugging it shows until "String Called", then displays 1234567891011121314151617181920, waits around 3 seconds and then exits with code "-1073741819"


Question about differential signals as input of an operational amplifier

I'm studying the circuits which are used to implement operational amplifiers. For example, I've studied the two stages amplifier (in which the first stage is a differential amplifier with differential to single ended transformation, the second stage is an inverter with active load), the telescopic cascode, and other circuits. Here a picture of these circuits:      I noticed that in all of these circuits the book I read always assumes a differential input, that is two (small) signals with the same DC value and amplitudes which are equal and opposite. As a consequence of the superposition principle and of the symmetry of these circuits, we can divide the circuit into two parts and all the nodes on the axis of symmetry become ac grounds. This simplifies the analysis, in particular it becomes easier to find the differential gain.  The question is: who says that, when I close these circuits with feedback, I will have at the inverting and at the non-inverting terminals a perfect differential input? It appears as if the book assumes that I will get for sure this situation. In other words, who says that, when I close the circuit with feedback, I get the same differential gain (if I close the circuit with feedback, in general I don't have two perfect differential signals, and as a consequence I am not allowed to divide by symmetry the circuit and to consider all the nodes on the axis of symmetry as ac grounds)?  For example, let us assume that I use one of these circuits to implement the classic inverting configuration:    You can see that the non-inverting terminal is fixed at ground, then it is impossible to have a differential input for the op-amp.  Thank you  Image added for the comment:


UK Visa Refusal Letter, email or attached with passport?

Dears,   I have applied for UK visitor visa, this is my second attempt. my first one was refused. HO sent me the refusal letter in an email and I received my passport later. But this time they sent me an email stating the visa application has been concluded and has been sent back to the Visa Application centre. Does this mean I have got the visa, or do they ever send the refusal letter with the passport?  I need this because I have to take the tickets as I have to travel on December 21st if I get the visa. your help is highly appreciated.  I applied in Germany.  Thanks!


How to expose the hue of a Color Ramp node inside a node group?

I'm making a material in which the color in the Color Ramp Slider changes the color of the fabric material. Because I'm using noise texture to generate patches of 2 different colors, I'm unable to connect the slider color to group input. I tried looking for solution to add driver and it didn't work as intended.  Update: Thanks to moderator for re-opening the thread. I have already seen the link provided by PGmath. The method in the link basically says "This is workaround" and it's bit on complex side. I don't mind playing with math modes to achieve the desired result. But that too doesn't seem to work in my case. The link explains how you can get node group that behaves like Colorramp. What I want is a node input for changing color hue. Anyways, thank you guys for helping out. Got a workaround fiddling with MIXRGB and Math node that achieves what I'm looking for. Below are the images of the result.  BTW, if you guys have been wondering I'm making a procedural Velvet Shader.


What causes this strange interaction between glossaries and amsmath?

MWE: greatly trimmed from a large document; XeLaTeX; full TeXLive2012 completely up-to-date:  \documentclass{memoir} \usepackage{fixltx2e} \usepackage{amsmath} \usepackage{mathspec} \usepackage{glossaries} \usepackage{lipsum} \begin{document} \lipsum[1] \end{document}   Fails with "! Package mathspec Error: 'amsmath' must be loaded earlier than `mathspec'."  Now, if I eliminate glossaries, or move it above mathspec in the file, things work. But it isn't very convenient to have to sort ones packages whenever anything gets a new dependency. And in any case, I do load amsmath before mathspec, don't I?  Really puzzled by this one. Any illumination would be most welcome.  (BTW, not strictly MWE, as it also fails with article.


How to enable boot messages to be printed on screen during boot up?

How to enable boot messages, kernel messages and other logs of various services to be printed on screen during boot up?


I am a financial noob. I wonder what are some intrinsic value of stocks. While purchasing a stock, I expect that the price of it will go up, and I'll sell it to gain the price difference. However, the price is determined by the mass, which also applies to currencies or such. If no one wants the stock tomorrow, its price will be zero. What, then, contributes to the price of stocks, other than the expectation for the price to grow?


I am trying to get the mime type of a file without extension using :      File file = new File("C:\\Users\\user\\Desktop\\a.txt");     File file1 = new File("C:\\Users\\user\\Desktop\\folder\\a");      MimetypesFileTypeMap mimeTypesMap = new MimetypesFileTypeMap();      // only by file name     String mimeType = mimeTypesMap.getContentType(file1);   The mime type of file a.txt is text/plain which is correct, But the mime type of file1 is application/octet-stream.  although they are the same file but one with and the other without extension, so what is the best and the correct way to get the mime types of files without extension?  I used a third party tool like Tika, but I don't want to use it since it is making a lot of conflict on my app.


What functionality do 'marks' offer in the El Capitan Terminal?

Since upgrading to OS X El Capitan, I've noticed a change in the Terminal: Executed lines show an opening bracket on the left, and a closing bracket on the right, as shown in this screenshot:    Similar questions have been asked here:          Some of the questions are referring to these brackets as marks, and the Terminal's Edit menu has a couple of entries related to marks, for example:   Edit > Marks > Mark as Prompt and Send Return Edit > Clear to Previous Mark Edit > Navigate > Jump to Previous Mark     Is there a summary of what these marks can be used for? I have not seen any reference to this new feature in any of the El Capitan feature overviews.


How to get ASCII value of a string in C#

I need to get the ASCII values for individual string in C#  Say for example I have an array  string[] ar =  new string{"1", "2", "3", "4", "5"};   I need to get the ASCII values of these individual array elements. Like for ar[0], ar[1]. I do not want to iterate through a loop  So I tried   Encoding.UTF8.GetBytes(ar[0])    and it returns   System.byte[]   How do i convert it to the original ASCII knowing that this return just a byte array.


Can sum of a rational number and its reciprocal be an integer?   My brother asked me this question and I was unable to answer it.   The only trivial solutions which I could think of are $1$ and $-1$.  As to what I tried, I am afraid not much. I have never tried to solve such a question, and if someone could point me in the right direction, maybe I could complete it on my own.  Please don't misunderstand my question.   I am looking for a rational number $r$ where $r + \frac{1}{r}$ is an integer.


I have been playing around with camera tracking and I'm happy enough with the tracking and alignment of the markers with the footage when viewed through the camera.    The problem is, when I am not looking through the camera I can see that the grid isn't aligned to the camera.    How do you correctly align the grid to this tracked camera? I have set a floor and two points for scale, also clicked setup tracking scene, but this just added cube and plane which were on the grid.


Strange modulation of radioactive decay rates with solar activity

Recently I found out this  about nuclear decay rates somehow showing seasonal variations with a high correlation with sun activity.   Has this been experimentally confirmed/disproved? An experiment using neutrinos from a fission reactor would be awesome, although probably a couple orders of magnitude below the required luminosity (at least to be comparable with solar sources) Could the standard model possibly allow neutrinos to modulate decay rates in this way? Or do we need new physics?   Link to the .  Another paper about this, but now the SuperKamiokande data is compared with data from Brookhaven:  They also propose a model of the effect called neutrino "resonant spin-flavor precession".


Will reformatting my hard drive fix bad sectors on it?

Assuming I'm not concerned with the data on it.


I'm trying to create a table that has some merged columns. But after I compile the file, the borders for those merged cells doesn't appear. I don't know how can I fix this. Any suggestions?!    Here is the code :  \begin{table}[h]  \centering  \caption{Query Q1}  \begin{tabular}{|c|c|c|c|}   \hline   \multicolumn{4}\textbf{Search Results} \\   \hline   1  & D7  & R  & \\   2  & D2  & R  & \\   3  & D3  & NR & \\   4  & D5  & R  & \\   5  & D1  & R  & \\   6  & D6  & NR & \\   7  & D12 & R  & \\   8  & D15 & NR & \\   9  & D21 & NR & \\   10 & D9  & R  & \\   \hline   \multicolumn{3}\textbf{Avg} & \\   \hline  \end{tabular} \end{table}


Condition on a matrix so that its determinant is $2$

Is the following statement true or false? There exists $A \in M_{3,3}(\mathbb{Z})$ with determinant $2$ such that $$A\begin{pmatrix}2\\1\\4\end{pmatrix} = \begin{pmatrix}4\\-8\\16\end{pmatrix}$$   I first thought of eigenvalues but it doesn't look like the second vector is a multiple of the first. What are the conditions on $A$ so that it's "true"? Or is it always false?


What is the need of exponential generating functions on combinatorial problems?

I've been introduced in my last lectures. And for the following problem:     Having 3 different types of books $a,b,c$ in how many ways can we take four different books putting them in a shelf such that the book $a$ can only be taken at most $1$ time, $b$ can be taken at most $3$ times and $c$ can only be taken at most $2$ times?   The ordinary generating function for this problem is:  $\quad \quad \quad \quad \quad \quad \quad $  Looking at the exponential generating function of the same problem, the only part of interest is the coefficient of $x^4$, which is:  $$\left(\frac{ab^3}{1!3!}+\frac{b^3c}{3!1!}+\frac{ab^2c}{1!2!1!}+\frac{b^2c^2}{2!2!}+\frac{abc^2}{1!1!2!}\right)$$ And then multiply it by $4!/4!$. But why do I need an exponential generating function? Isn't only needed to take the coefficient of $x^4$, divide each term of it by $a_1!a_2!\dots a_n!$ with $a_n=\text{power of a,b,c,}\dots$ and then multiply it by $4!4!$? It's not clear why such complication is needed.  By complication I mean to expand that generating function with the factorials, I could expand the ordinary generating function and then artificially add the factorials.


How to use shortcuts for tools instead of actions in Blender 2.8

I'm having some problem with the way blender handle the shortcuts. When I use a shortcut for a tool, like the extrusion one, for example, it immediately execute extrusion, instead of just selecting the tool.   I managed to bypass it by clicking in each option at the quick tools menu and reinserting the shortcuts, but apparently I have to do that for each blender mode. Is there a option I'm missing in the preferences or maybe a plugin to make Blender behave differently?


Anonymous and unregistered users with < 15 reputation (the amount required to earn the upvote privilege) will now see       feedback   on every post in the area that a logged in user would see "add comment":    When the post area is moused over, the area expands to:     Was this post useful to you? [Yes] [No]     once clicked it will say     sending feedback...   and eventually     Thank you for your feedback.   The goal is to offer the 90% of our traffic that is anonymous users a way to provide more meaningful feedback on posts rather than passively incrementing a view counter.  This click data is currently being evaluated to see what we can do with it. Ideas welcome!


Prove that if $\operatorname{gcd}(a, b)=1$ then $\operatorname{gcd}(a c, b)=\operatorname{gcd}(c, b).$      My Attempt. Assume $\operatorname{gcd}(a, b)=1,$ then $1|a$ and $1|b.$ Let $\operatorname{gcd}(c, b)=d$, that is $d|c$ and $d|b$ whenever an integer $d'|c$ and $d'|b$, we have $d'|d.$ We need to show $\operatorname{gcd}(ac, b)=d.$ Since $1|a$ and $d|c$, we get $d|ac.$ Now,....  How can I complete the proof? Can you help? Thanks...


I'm trying to create a PDF from a file test.tex:  \documentclass{article} \usepackage{fontspec} \setmainfont{Noto Color Emoji} \begin{document} 😺 🌍 \end{document}   Running the command:  lualatex test.tex   produces these log messages:  This is LuaTeX, Version 1.10.0 (TeX Live 2019/Arch Linux) restricted system commands enabled. (./test.tex LaTeX2e <2018-12-01>  luaotfload | main : initialization completed in 0.059 seconds (/usr/share/texmf-dist/tex/latex/base/article.cls Document Class: article 2018/09/03 v1.4i Standard LaTeX document class (/usr/share/texmf-dist/tex/latex/base/size10.clo)) (/usr/share/texmf-dist/tex/latex/fontspec/fontspec.sty (/usr/share/texmf-dist/tex/latex/l3packages/xparse/xparse.sty (/usr/share/texmf-dist/tex/latex/l3kernel/expl3.sty (/usr/share/texmf-dist/tex/latex/l3kernel/expl3-code.tex) (/usr/share/texmf-dist/tex/latex/l3kernel/l3pdfmode.def))) (/usr/share/texmf-dist/tex/latex/fontspec/fontspec-luatex.sty (/usr/share/texmf-dist/tex/latex/base/fontenc.sty (/usr/share/texmf-dist/tex/latex/base/tuenc.def)) (/usr/share/texmf-dist/tex/latex/fontspec/fontspec.cfg))) (./test.aux) [1{/var/ lib/texmf/fonts/map/pdftex/updmap/pdftex.map}] (./test.aux)) 410 words of node memory still in use:   3 hlist, 1 vlist, 1 rule, 2 glue, 3 kern, 1 glyph, 5 attribute, 48 glue_spec , 5 attribute_list, 1 write nodes   avail lists: 2:15,3:4,4:1,5:21,6:1,7:15,9:7 </usr/share/fonts/noto/NotoColorEmoji.ttf   and ends with this error message:  ! error:  (file /usr/share/fonts/noto/NotoColorEmoji.ttf) (ttf): loca table not found !  ==> Fatal error occurred, no output PDF file produced!   I've installed the font using  pacman -S noto-fonts-emoji   and there's indeed a file at  /usr/share/fonts/noto/NotoColorEmoji.ttf   How do I get this to compile?    I'm not tied to LuaLaTeX; if I can create the PDF with another rendering engine, I'll happily do so.


When will Stack Overflow support retina devices?  Please, please, please at least change the favicon to a high-res version.


I don't assume the Rule of Two was followed so strictly, since Sith are the bad guys, they would not always play by the rules... But it seems that it was Sidious's way to have only one apprentice at a time.  As shown in RotJ, the Emperor had no problem in letting Luke kill Vader... He even encouraged him to do so, so he would take his father's place at his side... He did the same when Anakin fought Dooku in Episode III...  Had things went differently, and Luke was turned to the dark side, would Sidious just kill Vader, so that it would only have two Sith at a time?  Is there any material that exposes the Emperor's ultimate intentions in his plan of bringing Luke to the dark side, regarding this matter of slaughtering Vader?


I need help with the following proof, which my professor added for practice (but not as homework). I am completely lost here.  Let $A$ be a nonempty subset of a metric space $X$. Define $d(\cdot ,A) : X \to [0,\infty)$ by  $$d(x,A) = \inf\{d(x,a) : a \in A\}.$$   Prove that $d(\cdot,A)$ is continuous.   Now there are some things that I do know.    The definition of continuous:Suppose X,Y are metric spaces, a ∈ X and f : X → Y. The function f is continuous at a if for every ε>0there is a δ>0such that if dX(a,x) < δ, then dY (f(a),f(x)) < ε.  If f is continuous at every point a ∈ X, then f is said to be continuous.  The following theorem:A function f : X → Y is continuous if and only if f−1(U) ⊂ X is open for every open set U ⊂ Y .


Word for people who don't make their deadline

What is the correct word to describe the people who have not finished their work after the deadline?   For the antonym, there is finisher, but I can't find *unfinisher in the dictionary.


Dual monitor won't work together (one screen blank)

I am using Ubuntu 14.04 kde plasma 5 - Dell xps laptop - graphics card nvidia GeForce GT 550m.  My two monitors won't work together! When I set the laptop screen as principal monitor, the external monitor is just blank. I can see the cursor, I can drag windows, but this is all I can do. And vice versa, the same thing happen when I set the external monitor as principal display!   I have tried several drivers (nouveau, proprietary...), I've tried to change settings in kde monitor settings and nvidia x server, I even tried to speak gently to my computer   Can you help me please?


Solve in integers $y^2 = x^3 + (x+4)^2$ $$y^2 = x^3 + (x+4)^2$$ $$y^2 = x^3 + x^2 + 8x + 16$$ $$y^2 - x^2 = x^3 + 8x + 16$$ $$(y+x)(y-x) = x^3 + 8(x+2)$$ How to I continue? I know I should get the form $(ax^b+c)(dy^e+f) = g$ and then factor the combinations but I'm not sure how to get there. Thanks so much for the help!


Can an update function common to more than one property reveal which property is using it?

I'd like to use the same update function for several properties but I will need to know which property calls this function like in this script exemple.  import bpy from bpy.types import Panel, PropertyGroup from bpy.props import BoolProperty, PointerProperty  def update_function(self, context):     #if firstProp use this function:     #   do this     #elif secondProp use this function:     #   do that   class MyCollectionProperty(PropertyGroup):      firstProp = BoolProperty(             name = "Fisrt",             default = False,             update = update_function,             )      secondProp = BoolProperty(             name = "Second",             default = False,             update = update_function,             )  class TestPanel(Panel):     bl_idname = "test_panel"     bl_label = "Test Panel"     bl_space_type = "VIEW_3D"     bl_region_type = "TOOLS"     bl_category = "category"      def draw(self, context):         myProps = context.window_manager.myProps         layout = self.layout          layout.prop(myProps, "firstProp")         layout.prop(myProps, "secondProp")  def register():     bpy.utils.register_module(__name__)     bpy.types.WindowManager.myProps = PointerProperty(type = MyCollectionProperty)  def unregister():     del bpy.types.WindowManager.myProps     bpy.utils.unregister_module(__name__)  if __name__ == "__main__":     register()   Is this possible or are we obliged to create a function per property?


Is there an international taxonomy of academic titles/ranks?

Looking at the  on Wikipedia shows that the same academic rank/title can mean quite different things in different countries. For instant, a "research assistant" in the US can stand for an undergrad student doing an internship, while in the UK it can stand for a postdoc. Similarly, the term "lecturer" might stand for a permanent position (e.g. in the UK) or for a teaching assistant position, open to graduate students.   However, when thinking about it, there are not so many kind of possible positions (permanent or not, with teaching or not, with research or not, with PhD supervision or not, with team responsibility or not, etc), and having a clear title could help a lot (for instance, in my case, I've been working in four different countries, with a different job title each time!).    Is there some kind of official taxonomy that one could refer to?  If not, who could be in charge to create it? (the EU, if only for intra-Europe mobility?)


A ring is never a direct sum of infinitely many non-zero left ideals?

Is it true or false that a ring is never a direct sum of infinitely many non-zero left ideals?  It should be false because we can make a direct product of infinite copies of $\Bbb{R}$, and every copy is a left ideal.   But it was written in a book I was doing. I don't understand the reasoning behind it.


Why does proton and electron attract each other?

Not that their charges are opposite! "+" & "-" are the signs we named them. By nature Why do they attract each other? And Why do they repel each other?


Is this an acceptable proof for If $d^{2}\mid a^{2}$ , then $d\mid a$?

Proof. We will prove the contrapositive. Suppose $d\nmid a$. By the division algorithm, $a = qd + r$ for some $q\geq 0 $ and $0<r<\lvert d \rvert$. Then, $a^{2} = (qd + r)^{2} = q^{2}d^{2} + 2qdr + r^{2} = d^{2}(q^{2} + \frac{2qr}{d}) + r^{2}$. Since $r < \lvert d \rvert$ ,$r^{2}< d^{2}$. Thus, there is a nonzero remainder, so $d^{2}\nmid a^{2}$. Hence if $d^{2}\mid a^{2}$, $d\mid a$. $\square$


Analytic properties of a function such that $f(x)-f(y)=f(x/y)$.

Suppose $f:(0,\infty)\rightarrow\mathbb{R}$ satisifies $f(x)-f(y)=f(x/y)$ for all $x,y\in (0,\infty)$ and $f(1)=0$.  What I need to do is prove that $f$ is continuous on $(0,\infty)$ if and only if $f$ is continuous at 1. One direction is trivial. What I'm having trouble with showing that if $f$ is continuous at 1 then $f$ is continuous on the entire interval.


I have a quick question about updating my references from Bibtex.  I am using TexStudio as my Latex editor.  I have to make changes to some of the references.  I put the changes in the "references.bib" file.  I then compile the Bibtex and the main document I'm working on.  Sometimes the changes show up, and sometimes they don't, and I haven't figured out why. I have even gone as far as trying to delete the references by changing the filename, but the original references still appear.  Here's what I put in my main document:   \newpage %Puts in References  \bibliographystyle{unsrt}  \bibliography{references}   My references.bib file shows all the changes I have made.  Any suggestions are appreciated!


How to insert table of contents based on chapters?

Verified, it does not have the answer in the linked post.  I would like to create table of contents based on chapters. When I insert command \tableofcontents almost at the top -- after opening document and making few definitions, as the result I get empty TOC (not desirable).  When I move it right before new chapter (as an experiment) and I get nothing -- i.e. no TOC at all (empty TOC has at least heading "Table of contents").  For example:  \tableofcontents   \begin{verse} some quote \end{verse}  \def\enddoc{}  \def\input#1{}  \include{intro1} \include{intro2}  \chapter{Program}    intro1 and intro2 are chapters written as separate files. This gives me empty TOC, when I move TOC before chapter "Program" TOC is not created.  I added usepackage with \usepackage{tocloft,calc} and \usepackage{titletoc}. No change at all?  What do I do wrong way?    Update  I found the culprit, but I don't know how to fix it. My entire document consists of several chapter (with bibliography), each chapter is written as separate file. The preamble is also saved as separate file.  What's important currently I can create each chapter as separate pdf (on its own) -- because each chapter includes preamble, not only the main .tex file.   In the main .tex file I have such line:  \def\input#1{}   I don't know what it does (my mistake, I should I added explanation in comment), but it allowed me to build entire document so far.   When I tested it on the stripped sample .tex, removing it allows TOC to be created correctly, but when I comment it in my main document (not just sample) the compilation fails right from the beginning. First separate chapter file includes preamble (so the inclusion is from the middle of .tex file really) and I get error:  Can be used only in preamble. \documentclass   So, is it possible to build TOC nevertheless, or should I drop this separation if I want to create TOC?


DSLRs often have the ability to store both a JPEG and a raw file.  Given that the  is the smaller filesize, and that JPEG+raw is going to store even more data than raw alone, it seems like you're just wasting space on your card and  if you store both.  Why bother storing both JPEG and raw in camera, instead of just a raw file?


Prob. 21, Sec. 17 in Munkres' TOPOLOGY, 2nd ed: Closure and complementation can result in at most 14 different sets

Here's Prob. 21 in Sec. 17 of the book Topology by James R. Munkres, 2nd edition:  Consider the collection of all subsets $A$ of the topological space $X$. The operations of closure $A \to \overline{A}$ and complementation $A \to X-A$ are functions from this collection to itself. (a) Show that, starting with a given set $A$, one can form no more than $14$ distinct sets by applying these two operations successively. (b) Find a subset $A$ of $\mathbb{R}$ (in its usual topology) for which the maximum of $14$ is obtained.  My effort: Based on the feedback I've had from the valued Mathematics Stack Exchange community, I would like to ammend my effort as follows: Let $\mathcal{P} (X)$ denote the power set (i.e. the collection of all the subsets ) of $X$, and let the functions $f \colon \mathcal{P} (X) \to \mathcal{P} (X) $, $g \colon \mathcal{P} (X) \to \mathcal{P} (X) $, and $i \colon \mathcal{P} (X) \to \mathcal{P} (X) $ be defined as follows: $$f(A) \colon= \overline{A} \ \ \ \mbox{ for all } \ \ \ A \in \mathcal{P} (A),$$ $$g(A) \colon= X - A \ \ \ \mbox{ for all } \ \ \ A \in \mathcal{P} (A),$$ and $$i(A) \colon= \mathrm{Int} (A) \ \ \ \mbox{ for all } \ \ \ A \in \mathcal{P} (X).$$ Then we have the following couple of results $$f(f(A)) = f(A), \ \ \ i(i(A) = i(A), \ \ \ \mbox{ and } \ \ \ g(g(A)) = A \ \ \ \mbox{ for all } \ A \in \mathcal{P}(X).$$ Moreover, we also have the following two relations: $$f(g(A)) = g(i(A)) \ \ \ \mbox{ and } \ \ \ g(f(A)) = i(g(A)) \ \ \ \mbox{ for all } \ A \in \mathcal{P} (X).$$ How do we show that $$f(g(f(g(f(g(f(g(A)))))))) = f(g(f(g(A))))$$ and  $$g(f(g(f(g(f(g(f(A)))))))) = g(f(g(f(A))))$$ for all $A \in \mathcal{P} (X)?$. Please also refer to  link.


How to pass paramters to a dynamically created apex class

is there a way to pass in parameters to a class when creating it dynamically using Type.forName(classname).newInstance().  global with sharing class ManagerBatch implements Database.Batchable<sObject>{          Boolean isIndependent = true;          global ILM_AddressSharingManagerBatch(Boolean indep) {                isIndependent = indep;         }     }     global with sharing class ILM_BatchController implements Database.Batchable<sObject>, Database.Stateful{      // implementation     global void finish(Database.BatchableContext BC) {        DMT_Batch_Setting__mdt batchSetting = (DMT_Batch_Setting__mdt)pq.dequeue();        String batchClassName = batchSetting.Batch_Class_Name__c;        Type batchType = Type.forName(batchClassName);        Database.Batchable<sObject> batchToExecute =                     (Database.Batchable<sObject>)batchType.newInstance();        Database.executeBatch(batchToExecute);             }         }     } }   I tried to create an abstract batch class and created a setIndependence method for it however i have a problem casting the type properly: source:()  public abstract class AbstractBatch  {     Boolean isIndepedent;     public AbstractBatch setindependence(Boolean indepedent)     {         isIndepedent = indepedent;         return this;     }  }   global with sharing class ILM_BatchController implements Database.Batchable<sObject>, Database.Stateful{      // implementation     global void finish(Database.BatchableContext BC) {        DMT_Batch_Setting__mdt batchSetting = (DMT_Batch_Setting__mdt)pq.dequeue();        String batchClassName = batchSetting.Batch_Class_Name__c;            (AbstractBatch) batchType = ((AbstractBatch)Type.forName(batchClassName)).setindependence(false);        Database.Batchable<sObject> batchToExecute =                     (Database.Batchable<sObject>)batchType.newInstance();        Database.executeBatch(batchToExecute);             }         }     } }      Error: incompatible type since system.type is never an instance of abstractBatch.


Theorems with hanging indentation, also working with itemize

I've been trying numerous ways to have a hanging indentation in my theorems. I'm using amsthm to define my own theorem styles.  What I want is the theorem to indent after line 1 like this:  Text before theorem. Theorem 1. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris pellentes     nibh dapibus sem pharetra, eu accumsan nibh pretium. Integer auctor ornare nibh.      Morbi magna neque, luctus maximus metus ut, fermentum aliquet odio. Ut bibendum.       - List item 1       - List item 2     Lectus sed nibh ultrices porta. Curabitur enim leo, imperdiet at mauris tempus. More text after theorem   with the source code of this looking like:  \documentclass{article} \usepackage{amsthm} \setlength\parindent{0pt} %\newtheoremstyle{mytheorem} .... %Theorem style here %\theoremstyle{mytheorem} \newtheorem{thm}{Theorem} \begin{document} Text before theorem. \begin{thm}  Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris pellentes nibh dapibus sem pharetra, eu accumsan nibh pretium. Integer auctor ornare nibh. Morbi magna neque, luctus maximus metus ut, fermentum aliquet odio. Ut bibendum. \begin{itemize} \item List item 1 \item List item 2 \end{itemize} Lectus sed nibh ultrices porta. Curabitur enim leo, imperdiet at mauris tempus. \end{thm} More text after theorem \end{document}   As mentioned I've tried numerous ways, but one (using \hangindent) doesn't work with itemize, others work for only one paragraph.  Is there a way to achieve what I want?


How do I resize an image using PIL and maintain its aspect ratio?

Is there an obvious way to do this that I'm missing?  I'm just trying to make thumbnails.


Making bibliography appear in ToC (BibLaTeX, Article class)

I'm having trouble getting my bibliography visible in my Table of Contents. I've googled and read especially , but still can't get this to work.   See below part of my preamble:  \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{biblatex} \usepackage{tocbibind} \bibliography{references.bib}   However, I still can't get the References to ToC.   Would anyone have any further tips?


I would like to modify Chrome's user agent stylesheet. I am not looking for how to override them with CSS. I want to modify the default values and add some new rules that would help me speed up my workflow and enhance my browsing experience.  Please also I am not looking for an extension that would do this job for me.


Why is a cellular structure necessary to satisfy the definition of alive?

I was looking at this image and reading through the Wikipedia page for viruses and it says that to satisfy the definition of "being alive" the organism must have a cellular structure, but it seems to me that if an organism has all these other factors without a cellular structure, it is still seemingly alive, no?  So why exactly does an organism need a cellular structure to be alive? What is the rationale for that criteria?


Two values, $x$ and $y$ are selected at random and independently of each other from the interval. What is the probability.   The only idea I have thought of is using BinomPdf, but I still don't know how to implement that into this.  This is a question I am solving on my own that I have discovered. If you send the answer and work it would not assist me cheating or anything malicious.


Convert whole library to new .HEIC format

Can the whole icloud library be converted from the non-optimised format to the new optimised format, or vise versa?  I have noticed that some of my photos have automatically be using the new format.


I used WolframAlpha to calculate a sum but it didn't show me the way :( Anybody has a hint or a solution for proving this sum? $$\sum_{n=0}^N\binom{2N-n}N2^n(n+1)=(1+2N)\binom{2N}N$$


Basel Problem approximation error bounded by $\mathcal O(1/x)$?

In  it is stated that $$ \sum_{n\geq1}\frac{1}{n^2}=\sum_{n\leq x}\frac1{n^2}+\mathcal O(1/x). $$ Is this statement true as $x\to\infty$? What I've done: If $x$ is fixed, then I think the answer is almost trivial, because we may set $C=\pi^2x/6$, so $$ \sum_{n=x}^\infty\frac1{n^2}\leq\sum_{n=1}^\infty\frac1{n^2}=\frac{\pi^2}{6}=\frac{C}{x}, $$ therefore $$ \sum_{n\geq1}\frac1{n^2}=\sum_{n\leq x}\frac{1}{n^2}+\sum_{n=x}^\infty\frac{1}{n^2}\leq\sum_{n\leq x}\frac{1}{n^2}+C/x=\sum_{n\leq x}\frac{1}{n^2}+\mathcal O(1/x). $$ But is there a constant independent of $x$ that makes this true?


I accidentally deleted a directory with rm -rf /media/directory   When using ls -lh /media  the space appears to be free, but when I use df or open the file manager nautilus or pantheon, it shows that the previously occupied space is still allocated. I googled this problem and some says that some process is still using these data, so it won't be freed till unmount, restart or killing the process itself. I did none of these still, is there any way to recover it?


How can I achieve more clarity in my photos of the moon?

I took this photo of the blood moon this morning and I am finding many of my photos, especially landscape photos, have a significant lack of clarity. I'm not looking for a photo critique because I know this particular photo is crap. I'm looking to identify my source of failure to nail a significantly clear photo.     Setup  Canon EOS 70D with a 100-300 telephoto lens (I'm sorry I don't know the exact model. It's from Canon but not one of their professional quality lenses.)   Aperture: f/5.6 Shutter: 1 sec. ISO: 1000 Focal Length: 300mm Metering mode: Spot White Balance: I manually set the WB to 5500 kelvin, it looked fine in live view. Focus Mode: Manual Drive: 2 sec timer delay   Mounted on a decently stable tripod  Process  I turn on live view, and square up the target in the display. I then set my focal length, focus in using live view, adjust the focus as sharp as possible and take the pic. I've noticed that in this case, the picture was incredibly grainy, which doesn't translate to the final photo, but wonder if it has anything to do with it.  This particular shoot I found it difficult to balance out the variables with a dark sky and a moving moon that starts blurring after 1-2 seconds of exposure, which is why I had the aperture wide open and the ISO cranked up.  I can't tell where I'm failing:  Equipment:  The 70d takes great photos but the telephoto is not great when it's totally zoomed in. My wallet doesn't hold enough cash for a motorized mount to track objects in the sky.  Circumstance: I've seen great photos of the moon with the use of a camera and a tripod, so I know this is possible. Although, I keep seeing pictures of this big gorgeous moon over the landscape, and when I use my wide-angle, the moon shows up as a dot. What the hell are people doing to get the moon so big?  Beginner skill level: I know this is the biggest culprit, but being the beginner, I'm unable to know where to adjust.


In a Twin Peaks  you can hear the following question: "So, Mr. Wheeler, what is it exactly you do do?". It seems to me quite weird. Is it correct? I suppose that the purpose of the second do isn't to emphasize something.


I'm trying to draw a bar diagram with 4 value groups each consisting of 5 bars. I think it's a scaling problem, so not all the groups were drawn. I already had a look at the documentation but I couldn't find the right config to make that happen...  \documentclass[tikz, border=10pt]{standalone}  \usepackage{pgfplots}  \pgfplotsset{compat=1.16, x tick label style={font=\tiny,align=center}, y tick label style={font=\tiny},% }  \begin{document} \begin{tikzpicture} \begin{axis}[% ybar,% enlargelimits=0.05,% title={title},% symbolic x coords={a,b,c,d},% xtick={data},% ylabel={y-label},% xlabel={},% xticklabels={ValueGroup 1,ValueGroup 2,ValueGroup 3,ValueGroup 4}, legend style={at={(0.5,-0.15)}, anchor=north,legend columns=-1}, ybar interval=0.7, ]  \addplot coordinates{(a,34) (b,36) (c,70) (d,65)}; \addplot coordinates{(a,45) (b,45) (c,43) (d,43)}; \addplot coordinates{(a,23) (b,32) (c,22) (d,20)}; \addplot coordinates{(a,76) (b,25) (c,35) (d,25)}; \addplot coordinates{(a,22) (b,12) (c,45) (d,34)};  \legend{\tiny{bar 1},\tiny{bar 2},\tiny{bar 3},\tiny{bar 4},\tiny{bar 5}} \end{axis}  \end{tikzpicture} \end{document}


How to filter out folder items in Windows search under Vista?

I want to search for files in an entire directory tree, but I don't want to see folders in the results. I want to see only files.  How can I exclude folders from showing up in the results under Windows Vista?


If/else with test on checkbox in SELENIUM IDE

I want to do an if/else test in SELENIUM IDE. If the checkbox is checked the test should run the IF-condition, whereas otherwise it should go into the ELSE. I tried several commands for the TARGET of the IF, but each time it chose the same way regardless of whether the condition pertained or not. So I need to know how to deal with the notation of SELENIUM IDE in this case. Hope anybody can help me by showing me how I can make the condition dependent on a checkbox..


If $\cos A+\cos B+\cos C=\frac{3}{2}$, prove $ABC$ is an equilateral triangle

If in $\Delta ABC$ $$\cos A+\cos B+\cos C=\frac{3}{2}$$prove that it is an equilateral triangle without using inequalities. I tried  using the cosine rule as follows:  $$\frac{b^2+c^2-a^2}{2bc}+\frac{a^2+c^2-b^2}{2ac}+\frac{a^2+b^2-c^2}{2ab}=\frac{3}{2}$$ $\implies$  $$a(b^2+c^2-a^2)+b(a^2+c^2-b^2)+c(a^2+b^2-c^2)=3abc$$ $\implies$  $$(a+b+c)(a^2+b^2+c^2)=2(a^3+b^3+c^3)+3abc$$   Any clues as to how I can take it from here?


Why do websites still display 404 pages instead of just another error page?

I was asked to design a 404 page but do we actually need to say 404? Even though most people understand what 404 means, do we need to explicitly tell users its a 404?   Why cant it just be an error page?     examples like these are really cool error pages. But they can get away without having the 404 in there. The context made it clear already. Why do websites still have it? When is it ok to break this rule?


WUBI installed Ubuntu not showing up at boot menu after Windows reinstallation

I recently installed 12.04 using WUBI installer in a separate partition. Because of some problem, I had to reinstall my Windows.   Now the problem is that my Windows has recovered, but Ubuntu is not showing up at the boot menu, even though the Ubuntu partition is intact.


Should I have a transit visa in Frankfurt?

I  have Syrian passport with USA visa. I will travel from USA to Lebanon but I have one stop in Frankfurt. I want to ask if I need visa to stay in the airport in Frankfurt until I have my next flight.


Let $A$ and $x$ be $n \times n$ and $n \times 1$ matrices, all entries real and strictly positive. Assume that $A^2 x = x$. Show that $A x = x$.

I am stuck for weeks with the following problem:     Let $A$ and $x$ be $n \times n$ and $n \times 1$ matrices, respectively, with all entries real and strictly positive. Assume that $A^2 x = x$. Show that $A x = x$.   This was on the first problem set on a course of linear algebra based on the book written by Hoffman & Kunze. We haven't seen eigenvalues and eigenvectors yet. So, while any solution that uses anything more advanced than the first 3 chapters of that book is welcome (it may incentivize me to study something!), it does not solve the problem.  Can anyone help? Thanks!  EDIT: My question was marked as a exact duplicate of a question by Igor Caetano Diniz. While that is the exact same question, that post has one wrong answer and one answer that has a theorem that I haven't studied yet. So it doesn't solve my problem.


I want to order the result of my query result and put it via Query activity into a data extension (DE has no primary key). The order by MAWE is pretty important for me.  select  count (SubscriberKey) AS amount, country, MAWE, variant  from Sendfinal1  group by country,MAWE,variant  order by MAWE,country   SF seems not to accept the order by:      Message: An error occurred while checking the query syntax. Errors: The ORDER   BY clause is invalid in views, inline functions, derived tables,   subqueries, and common table expressions, unless TOP, OFFSET or FOR   XML is also specified.   Is there a workaround for that?


How to select the right modulus to prove that there do not exist integers $a$ and $b$ such that $a^2+b^2=1234567$?

Example 19.2.6 Prove that there do not exist integers $a$ and $b$ such that $\left.a^{2}+b^{2}=1234567 \text { . [Problems IV, Question } 1\right]$ Solution The set of remainders modulo $4, R_{4},$ is $\{0,1,2,3\}$ and so working modulo 4 we have four possibilities to consider. From modular arithmetic,  \begin{array}{l} a \equiv 0 \bmod 4 \Rightarrow a^{2} \equiv 0 \bmod 4 \\ a \equiv 1 \bmod 4 \Rightarrow a^{2} \equiv 1 \bmod 4 \\ a \equiv 2 \bmod 4 \Rightarrow a^{2} \equiv 4 \equiv 0 \bmod 4 \\ a \equiv 3 \bmod 4 \Rightarrow a^{2} \equiv 9 \equiv 1 \bmod 4 \end{array}  Thus for any $a \in \mathbb{Z}, a^{2} \equiv 0$ or 1 mod $4 .$ Therefore given two integers $a$ and $b$, $a^{2}+b^{2} \equiv 0$ or 1 or 2 mod $4,$ i.e. $a^{2}+b^{2} \neq 3$ mod 4 Suppose now for contradiction that $a$ and $b$ are integers such that $a^{2}+b^{2}=1234567 .$ Then, since $1234567 \equiv 3$ mod $4,$ we have $a^{2}+b^{2} \equiv$ 3 mod 4 giving the required contradiction. Hence such integers cannot exist.  I understand the solution but I don't know how the author decided to start with modulo 4 instead of something else? What is it about the expression $a^2+b^2=1234567$ that would trigger us to select modulo 4 instead of something else. I tried to solve the question in a similar manner using modulo 2 but eventually got stuck. This leads me to believe that this question can only be solved using modulo 4. Is this true?