body1
stringlengths 20
4.1k
| body2
stringlengths 23
4.09k
|
---|---|
Just installed Kubuntu 16.04 last night, only to have it not include my Windows partition in GRUB. So I ran BootRepair and what happens next? My Windows partition comes back, but I now have duplicate menu items for it AND Kubuntu in GRUB. Typing sudo update-grub in the terminal didn't help as much as I thought it would either, tried that both before AND after running BootRepair. | After today's update, Ubuntu asked me to replace some files and I blindly accepted. After I restarted PC after the update, I saw duplicate entries in the grub menu: Here's the image of the grub customizer. Apparently, Grub Customizer can not save edited information. Is there a way to remove duplicates from Ubuntu 12.04 grub menu and set Windows 7 on first position? |
I want to show that if $f$ is integrable on the interval $[0,1]$ then $\lim_{n\to\infty} \frac{1}{n}\sum_{k=1}^n f\left(\frac{k}{n}\right)=\int_0^1f$. I am using the definition of integrability in the sense of Riemann-Stieltjes: $$\forall\epsilon>0:\exists P:\forall Q\geq P:\left|S(Q_n,f,I)-\int_0^1f\right|<\epsilon$$ Where $P$ and $Q$ are partitions of $[0,1]$. I thought about using the definition for the partitions: $$Q_n=\left(0,\frac1n,\frac2n,\cdots,\frac{n-1}n,1\right)$$ $$c_k=\frac kn$$ Then we have: $$\left|S(Q_n,f,I)-\int_0^1f\right|=\left|\frac1n\sum_{k=1}^nf\left(\frac kn\right)-\int_0^1f\right|$$ The problem is that I don't know how I can show that this tends to zero since a $P$ appears in the definition of integral and I don't know what to do with it. | I need to prove that if $f$ is Riemann integrable $[0,1]$ then $$\lim\limits_{n\rightarrow\infty} \frac{1}{n}\sum f\left(\frac{k}{n}\right)= \int\limits_{0}^{1} f(x)dx$$ My idea is to recognize the right side defining the limit as a Riemann sum and use the uniform continuity. I am not sure what to do next Thanks |
\begin{align} \mathcal{L}_{\lambda} = u_{1}(h) - u_{1}(h^{*}) + T \geq 0 \text{(foc$\lambda$)}, \label{eqn:foca1}\\ \mathcal{L}_{T} = -1 + \lambda = 0 \Leftrightarrow \lambda = 1 \text{(focT)} ,\label{eqn:focb1}\\ \mathcal{L}_{h} =- u'_{2}(h) + \lambda u'_{1}(h) = 0 \Leftrightarrow \lambda = \frac{u'_{2}(h)}{u'_{1}(h)} \text{(foch)}.\label{eqn:focc1}\\ \lambda \geq 0 \text{(nn)}, \label{eqn:focd1}\\ \lambda \mathcal{L}_{\lambda} = \lambda [u_{1}(h) - u_{1}(h^{*}) + T] = 0 \text{(cs$\lambda$)} .\label{eqn:foce1} \end{align} I want to have foc$\lambda$, \text{(focT)}, etc, as an equation number on the other sides if that makes sense? | When I have equations, as in \begin{equation} ... \end{equation} Can I arbitrarily assign the numbers to the equations? Instead of the usual order (1), (2), (3), ..., I'd like something like (1), (2.1), (2.2), (2.3), (3.1), (3.2), (4), ... |
I have a two-year-old system is badly in need of a repave. At startup there are messages about missing DLLs, and Firefox and a few other apps no longer work. I'd like to hook up an external disk, have everything copied to it, reinstall XP, reinstall the apps, and grab all the data back from the backup. Is there a good way to do this? | I have a friend who wants to sell their computer, but obviously all personal information and software that it is on it needs to be removed before doing so. Usually I would format and reinstall it, but I cannot easily get hold of the required XP DVDs and I'm not 100% sure the serial number is stuck on the case as usual so getting hold of it will probably require more effort than I'm prepared to spend. So, what's the best and quickest way to remove and uninstall everything from the PC without reinstalling it? Thanks. EDITS: I'm looking to remove things like Internet History and all installed programs, too. I know how to remove the history and each individual program, but that could take hours. The machine is not branded and therefore there is no website I can go to download recovery software. There is no recovery partition on the computer and I'm not aware of any recovery DVDs for it either. I can only assume it was installed from a retail copy, and therefore there is no way to recover it to factory settings. It needs to have XP installed, not any distribution of Linux. Like most average people, the person getting the computer will not understand what to do with a computer that doesn't have Windows installed, and software like Office does not work on Linux either. Buying another licence is not really an option either. She has just brought a laptop to replace the computer, so buying another licence for a computer that she's getting rid of doesn't really make sense. Thanks for all the help so far! |
I am just wondering if I could take screenshot of a remote website by just giving url to javascript code. This is done in many bookmarking sites. I wonder if that is done through some virtual browser which render the html code, executes the onload javascript and once loaded the screenshot is taken. | Is it possible to to take a screenshot of a webpage with JavaScript and then submit that back to the server? I'm not so concerned with browser security issues. etc. as the implementation would be for . But is it possible? |
In Avengers: Infinity War, why was Red Skull where the Soul Stone was with the knowledge of the Soul Stone? | Does anyone know who else is in the soul stone? And if anyone has used its power before? What happens to Red Skull after the soul stone was taken from Vormir? |
In reading a postulate on angular-momentum coupling, the author made this statement: In Q.M, the angular momentum cannot be complete aligned with the $z$-axis, otherwise its $x$ and $y$-components would be zero and be known simultaneously. I don't fully understand this statement. Is there a better way to gain insight into this statement? | This is the excerpt from my book, Arthur Beiser's Concepts of Modern Physics: An atom with a certain value of $\displaystyle{m_l}$ will assume the corresponding orientation of its angular momentum $\mathbf{L}$ relative to an external magnetic field if it finds itself in such a field. However, we note that $\mathbf{L}$ can never be aligned exactly parallel or anti-parallel to $\mathbf{B}$ because $L_z$ is always smaller than $\sqrt{l(l + 1)\hbar}$ of the total angular momentum. Why can't $\mathbf{L}$ be parallel to the applied magnetic field? I am not getting the reason showed by the author. Can anyone help me conceive the reason stated above? |
Currently I have a code like this The School array represents the School and each element in the array represents a classroom At the moment I want to store the Class teachers name in the array and if there is no class teacher assigned yet, that particular array element has "empty" import java.util.*; public class Main { public static void main(String[] args) { String[] school = new String[8]; initialise(school); } private static void initialise( String schoolRef[] ) { for (int x = 0; x < schoolRef.length; x++ ) schoolRef[x] = "empty"; System.out.println(Arrays.toString(schoolRef)); } } Output of this is [empty, empty, empty, empty, empty, empty, empty, empty] However now I want to create a Class called School and a Class called Classroom I want to use an array of Classroom objects School.java import java.util.Arrays; public class School { private Room[] rooms; public static void initialise(Room[] schoolRef) { for (int x = 0; x < schoolRef.length; x++) { schoolRef[x].setName("empty"); System.out.println(Arrays.toString(schoolRef)); } } } Room.java public class Room { public String getName() { return name; } public void setName(String name) { this.name = name; } private String name; } Main.java public class Main { public static void main(String[] args) { Room[] rooms = new Room[8]; School.initialise(rooms); } } However when I run the Main method I get a NullPointerException. I want to create an array of Classroom objects instead of writing everything in one Class and I'm not sure what I am doing wrong in my approach. Appreciate any help.Thanks | What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them? What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely? |
I try to learn javascript and therefore I tried the following code: function repeat(n, action) { for (var i = 0; i < n; i++) { action(); } } function benchmark() { var start = [], end = [], timings = []; repeat(1000, function() { start.push(Date.now()); // Repeat something end.push(Date.now()); }); for (var i = 0; i < end.length; i++) { timings[i] = end[i] - start[i]; } return timings; } My Question now: Why can I access start and end in my callback? As I understood the scope changed from benchmark to repeat. Is the callback a closure or is a closure onle a defined named function in another function? Thanks! | How would you explain JavaScript closures to someone with a knowledge of the concepts they consist of (for example functions, variables and the like), but does not understand closures themselves? I have seen given on Wikipedia, but unfortunately it did not help. |
I got a small doubt here. While we are generating any new application we used to deliver them as jar files. Now my question is are we able to decompile these jar files...? if yes how can I avoid that...? Please let me know, thanks in advance. | How do I lock compiled Java classes to prevent decompilation? I know this must be very well discussed topic on the Internet, but I could not come to any conclusion after referring them. Many people do suggest obfuscator, but they just do renaming of classes, methods, and fields with tough-to-remember character sequences but what about sensitive constant values? For example, you have developed the encryption and decryption component based on a password based encryption technique. Now in this case, any average Java person can use to decompile the class file and easily retrieve the password value (defined as constant) as well as and in turn can decrypt the data by writing small independent program! Or should such sensitive components be built in native code (for example, VC++) and call them via ? |
I have written sql query Select * from Products WHERE Products.Category=="Fruits"; the returned answer is 1-Banana 2-Mango 3-Apple 4-Oranges 5-Grapes now i want to select fruit at index 3rd only that is Apple using sql indexes the problem arises every where how should i select the element at 3rd place using its index in sql query? | I'm interested in learning some (ideally) database agnostic ways of selecting the nth row from a database table. It would also be interesting to see how this can be achieved using the native functionality of the following databases: SQL Server MySQL PostgreSQL SQLite Oracle I am currently doing something like the following in SQL Server 2005, but I'd be interested in seeing other's more agnostic approaches: WITH Ordered AS ( SELECT ROW_NUMBER() OVER (ORDER BY OrderID) AS RowNumber, OrderID, OrderDate FROM Orders) SELECT * FROM Ordered WHERE RowNumber = 1000000 Credit for the above SQL: Update: See regarding the SQL standard. Troels, have you got any links we can cite? |
I have a Venezuelan passport. I am flying from US to Bogota, Colombia and will be changing flights in Toronto. I will not be leaving the airport and my layover in Toronto is for 2 hours. I have a L1 visa for the US. My passport is from Venezuela. Airline: Air Canada. Thank you. | I'm passing through Canada, on my way to somewhere else. I'm staying only a short time. Is there a website, or some other way of find out out if I need a visa? |
I have been doing personal study in Classical Mechanics and reading Newton's Laws. While thinking about them I had a question I haven't been able to answer. It comes from the interactions of Newton's 1st and 3rd laws. First law In an inertial frame of reference, an object either remains at rest or continues to move at a constant velocity, unless acted upon by a force. Third law When one body exerts a force on a second body, the second body simultaneously exerts a force equal in magnitude and opposite in direction on the first body. So here's the problem: An object is in a certain state (at rest or in motion with zero acceleration) and an external force is applied to that object. By the 1st Law the object should experience a change of state. But then by the 3rd Law a reactive force, of equal magnitude and opposite direction, would be applied on the object and now the sum of the forces would be zero (the object's state doesn't change at all). By this reasoning it would be impossible for an object to experience a state change because these forces would be in constant opposition. But objects do experience state changes so where is the mistake in this reasoning? Thank you for any help! | Given Newton's third law, why is there motion at all? Should not all forces even themselves out, so nothing moves at all? When I push a table using my finger, the table applies the same force onto my finger like my finger does on the table just with an opposing direction, nothing happens except that I feel the opposing force. But why can I push a box on a table by applying force ($F=ma$) on one side, obviously outbalancing the force the box has on my finger and at the same time outbalancing the friction the box has on the table? I obviously have the greater mass and acceleration as for example the matchbox on the table and thusly I can move it, but shouldn't the third law prevent that from even happening? Shouldn't the matchbox just accommodate to said force and applying the same force to me in opposing direction? |
Is there an API in the C++ (or STL) to fetch the parent process id? if not then what could be the portable code to do so? I understand there linux api such as getppid can do the job on unix platforms but what is equivalent of the same on windows? Thanks! | I'm currently passing the pid on the command line to the child, but is there a way to do this in the Win32 API? Alternatively, can someone alleviate my fear that the pid I'm passing might belong to another process after some time if the parent has died? |
When I try to add 2 figures and to add text between them, after compiling the text, I get the results: texts above and the two figures below... I expected to have first figure and text after and after the text another figure and after the last figure another text. Why it separate them in shape of two text and after the text two figures ? first part: The output results that shown in \autoref*{capacitors_voltages} help us to bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb \begin{figure}[!h] \centering \includegraphics[width=0.9 \textwidth]{figures/CAP_voltgs} \caption{capacitor waveforms.} \label{capacitors_voltages} \end{figure} From \autoref*{ACcurrents} we can see aaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa \begin{figure}[!h] \centering \includegraphics[width=0.9 \textwidth]{figures/currents} \caption{AC side currents} \label{ACcurrents} \end{figure} second part: So, in this code part it behave exactly as I expected: The number of SMs usually depends on the application,it is very common of using letter N to indicate the number of SMs in each ARM and 2N to whole phase. \begin{figure}[!h] \centering \includegraphics[width=0.9\textwidth]{figures/Three_MMC_Phase2} \caption{General one and three phase of modular multilevel converter (a) and (b) respectively} \label{figures/Three_MMC_Phase2} \end{figure} The fundamental construction of SM composed from capacitor, IGBTs (S1,S2) and their corresponding free-wheel diodes.\\ The two most common SM configurations found in literature are the Half-Bridge (HB) and Full-Bridge (FB) SM, as illustrated in \autoref*{figures/HB_FB}. The FB-SM version of the MMC has twice as much semiconductor devices than the HB version, which results in higher losses, but confers certain advantages as well \cite{6864817}, \cite{6631955}. \begin{figure}[!h] \centering \includegraphics[width=0.9\textwidth]{figures/HB_FB} \caption{Converter configuration submodules: (a) half-bridge and (b) full-bridge} \label{figures/HB_FB} \end{figure} For the present analysis, and throughout the Thesis in general, the MMC under study is considered to be based on HB-SMs. Considering submodule structure , is a simple half bridge with a capacitor bank, as shown in \autoref*{figures/HB_FB}. Each phase leg of the converter has 2 ARMs, each one constituted by a number of series connected submodules. So what wrong with the first part ? | Is there any package or a method to force LaTeX to keep floating environments like table and figure closer to where they are declared? |
So I was playing Mass Effect 3 online yesterday’s and everything was fine. I tried playing again today and there is a lock on the side of the Team settings in the quick match menu. Does anyone know how to fix this? | Ever since I started playing Mass Effect 3 Multiplayer, the privacy setting in mission settings is locked. I own the legendary or best edition so if there was a code in there I missed it. Is there something I have to do or get a certain amount of characters to level 20? |
I am dynamically creating input elements using jquery, but when I try to access the dynamically created element values, I'm getting either empty or undefined or . I tried many ways to get the values, but It is failing. Could someone help me getting this done. Here is the code $(document).ready(function() { var count = 0; var jsondata = []; var selectedField; $('.add').click(function() { count = count + 1; jQuery('<div/>', { id: 'form-wrapper' + count, class: 'form-wrapper' + count, title: 'now this div has a title!' }).appendTo('.wrapper0'); $('.form-wrapper' + count).append("<label>FieldName</label> <input type='text' placeholder='label' id='label" + count + "'></input> <select class='select" + count + "'><option>Select</option><option value='textbox'>Textbox</option><option value='textarea'>TextArea</option><option value='checkbox'>Checkbox</option><option value='radio'>Radio</option><option value='date'>Date</option> </select><input type='text' id='commavalues" + count + "' disabled placeholder='Enter comma(,) seperated values'></input><input type='checkbox' id='required" + count + "'>Required</input><button class='delete'>Delete</button> <br><br>"); $('.delete').click(function(e) { ($(this).parent().remove()); }); $('.select' + count).change(function() { selectedField = $(this).children('option:selected').val(); if (selectedField == 'checkbox' || selectedField == 'radio') { $('#commavalues' + count).prop('disabled', false); flag = 1; } else { flag = 0; $('#commavalues' + count).prop('disabled', true); } }); item = {}; var label = $('#label' + count).val(); var required = $('#required' + count).is(":checked"); var label_type = selectedField; var options = $('#commavalues' + count).val(); console.log(label); console.log(required); console.log(label_type); console.log(options); item["label"] = label; item["label_type"] = label_type; item["options"] = options; item["required"] = required; jsondata.push(item); }); $('.save').click(function() { console.log(jsondata); }); }); body { background-color: #ECEFF1; margin: 50px 0; padding: 0; text-align: center; } button { position: relative; margin-left: 0px; } <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <div class="wrapper0"> <div class="form-wrapper"> <label>FieldName</label> <input type="text" placeholder="label" class="label0"></input> <select class="select0"> <option>Select</option> <option value="textbox">Textbox</option> <option value="textarea">TextArea</option> <option value="checkbox">Checkbox</option> <option value="radio">Radio</option> <option value="date">Date</option> </select> <input type="text" class="commavalues0" disabled placeholder="Enter comma(,) seperated values"></input> <input type="checkbox" class="required0">Required</input> <br><br> </div> </div> <button class="add">Add</button> <button class="save">Save</button> I am trying to display in JSON format when I click save button, and If i click the delete button the data associated to that input fields are to be deleted also. | I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off. This happens on page ready and works just fine. The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound. I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option. |
Let $E$ be a field and $F \subseteq E$ a subfield of $E$ and let $p(x), q(x) \in F[x]$ two polynomials with coefficients in $F$. Show that if $p(x)$ divides $q(x)$ on $E$ $(= \exists h(x) \in E[x]$ t.q. $q(x) = p(x) · h(x)$), then $p(x)$ divides $q(x)$ on $F$ $(= \exists h(x) \in F[x]$ t.q. $q(x) = p(x)·h(x)$). I tried to do the following : by an euclidian division on $F[x]$ $$q(x) =p(x) ·b(x) +r(x) $$ and by the given supposition : $$q(x) = p(x)·h(x)$$ Since, $p(x) ·b(x) +r(x) \in E[x]$, $$p(x)·h(x) = p(x) ·b(x) +r(x)$$ $$\iff p(x) [b(x)-h(x)]+r(x)=0$$ Then I don't know how to show $r(x) = 0$ to finish the proof. I thought of saying that since the remainder and the quotient are unique then $r(x)=0$ and $b(x)=h(x)$ but I feel there is something I am doing wrong... Maybe, I could say that $r(x) = p(x)[h(x)-b(x)]$. If $r\ne0$, then $h-b\ne0$, and so $\deg(p(h-b))\ge \deg(p) > \deg(r)$. Thus, $r(x)=0$. | I would like to verify the validity of the following line of thought: Let $K \subset E$ be a field extension. Let $K[x]$ be the polynomial ring over $x$ and denote $K(x)$ its field of quotients (the rational functions over $K$). Now assume $f(x)=g(x)h(x)$ with $f(x),g(x) \in K[x]$ and $h(x) \in E[x]$ and all $f$, $g$, $h$ are different than zero. Then $\frac{f(x)}{g(x)} = h(x)$ in $E(x)$. So $h(x) \in K(x)$. But $h(x)$ is a polynomial, so $h(x) \in K[x]$. Is there any other simpler argument than that? Added: Let me be more specific. Let $x^p - a \in K[x]$, with $p$ being prime and $char(K)=p$. Let $b$ be the unique root of $x^p - a$ in its splitting field $K(b)$. Then $x^p - a=(x-b)^p \in K(b)[x].$ Let $m_b(x) \in K[x]$ be the minimal polynomial of $b$ over $K$. Then $m_b(x)$ divides $(x-b)^p$ and so $m_b(x)=(x-b)^l$ and $l$ is the smallest positive integer for which $(x-b)^l \in K[x]$. Let $p = lq+r$ where $0 \ge <l$. Then $x^p-a=(m_b(x))^q (x-b)^r$. Can i conclude that $(x-b)^r \in K[x]$ and so $r=0$ by the minimality of $l$? Thanks. |
I'm a begginer and I don't know how to deal with this task : *This class is intended to be instantiated with a src character string as a parameter of its constructor. It must then: *-> Determine the type of file to which src corresponds (among: image, video, security plan [.mps]), using the extension *-> Check if the file corresponding to src exists. *-> If the file does not exist, the src member variable of File is initialized with a path to a file by default, depending on the type *(if the desired file was an image, src will contain the path to an "Error" image, ditto for videos and mps). In File.h : class File{ private: string src; string type; public: string description; File(); File(string src); ~File(); bool exists(); }; In File.cpp: File::File(string src):src(src){} bool File::exists(){} The thing is that I don't know how to check the file's exention from a string :/ . | Given a string "filename.conf", how to I verify the extension part? I need a cross platform solution. |
public class llearning1 { public static void main(String[] args) { String text = "is"; String x = "what is good"; String y[] = x.split(" "); for (String temp: y) { if (temp == text) { System.out.println("found"); } else { System.out.println("nothing"); } } } } output: expected : code should display "found" but it is displaying "nothing" | I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug. Is == bad? When should it and should it not be used? What's the difference? |
I have a batch file located in several folders and in this file I need to replace the old subst T: . command for net use because the units (drives) have different properties in windows 7. However, I have only found that net use only allows for absolute paths such as: net use T: \\path\to\folder I cannot work with absolute paths, but net use T: . is not allowed (it throws an error). Is there a way to execute the net use command from a folder so that it uses the current .bat directory? I think the best solution for me it would be to be able to get the absolute qualified path (\path\to\folder) with a batch command. (%cd% and chdir variables do not work in this case). Questions about getting the current directory or folder name are not useful since the net usecommand does not allow paths such as x:\path\to\folder | Is it possible to get the current folder name (not current directory path) by using a DOS command? If so, how? The closest I got was this but it doesn't do it: for /f "delims=\" %%a in ("%CD%") do set CURR=%%a echo.DIR: %CURR% note: the above attempt was me attempting to tokenize the string and get the last token set as the CURR variable. |
I need to compute this primitive : $$ \int \frac{e^{3 x}}{x^3} dx$$ but I don't know how to proceed. I tried an integration by part and get $$ \int \frac{e^{3x}}{x} dx$$ but then I am stuck... Is there no way else than making a McLaurin development ? Thanks | I made up some integrals to do for fun, and I had a real problem with this one. I've since found out that there's no solution in terms of elementary functions, but when I attempt to integrate it, I end up with infinite values. Could somebody point out where I go wrong? So, I'm trying to determine: $$ \int{\frac{e^x}{x}} \, dx $$ Integrate by parts, where $u = 1/x$, and $v \, ' = e^x$. Then $u \, ' = - 1/x^2$, and $v=e^x$. So, $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} + \int{\frac{e^x}{x^2}} \, dx$$ Integrate by parts again, $u = 1/x^2$, $v \, ' = e^x$, so that $u \, ' = -2/x^3$ and $v=e^x$. So, $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} + \frac{e^x}{x^2} + 2\int{\frac{e^x}{x^3}} \, dx$$ Repeat this process ad infinitum to get, $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} + \frac{e^x}{x^2} + 2 \left( \frac{e^x}{x^3} + 3 \left( \frac{e^x}{x^4} + 4 \left( \frac{e^x}{x^5} + \, \cdots \right) \right) \right) $$ Expanding this gives, $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} + \frac{e^x}{x^2} + \frac{2e^x}{x^3} + \frac{6 e^x}{x^4} + \frac{24 e^x}{x^5} + \cdots $$ And factoring that gives, $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} \left( 1 + \frac{1}{x} + \frac{2}{x^2} + \frac{6}{x^3} + \frac{24}{x^4} + \cdots \right) $$ Now, considering the series itself, the ratio between the $n^{th}$ term and the $(n-1)^{th}$ term = $\Large \frac{n}{x}$. Eventually, $n$ will be larger than $x$, so the ratio between successive terms will be positive, so (assuming $x$ is positive), the series diverges, meaning (and I'm sure everybody will cringe upon seeing notation used like this), that: $$\int{\frac{e^x}{x}} \, dx = \frac{e^x}{x} \left( \infty \right) = \infty $$ |
Did Esther handed her bag to you before she left? Did Esther hand her bag to you before she left? Did Esther hands her bag to you before she left? Which of the three is grammatical? | I didn't go to party. I didn't went to party. |
Let $(X,S,\mu)$ is a measure space and $\mu(X)<\infty$. Define $d(f,g)=\int\frac{|f-g|}{1+|f-g|}d\mu$ is a metric on the space of measurable functions. My work- symmetry, let's show $d(f,g)=d(g,f)$ $d(f,g)=\int\frac{|f-g|}{1+|f-g|}d\mu$ and $d(g,f)=\int\frac{|g-f|}{1+|g-f|}d\mu$ It's obvious that, $d(f,g)=d(g,f)$ My concern is triangular inequality, What want to show is, $d(f,h)\leq d(f,g)+d(g,h)$ so the right hand side becomes, $\int\frac{|f-g|}{1+|f-g|}d\mu+\int\frac{|g-h|}{1+|g-h|}d\mu= \int\frac{|f-g|}{1+|f-g|}+\frac{|g-h|}{1+|g-h|}d\mu$ I don't think simplification of right side will give the result easily. Can someone give me a hints. Thank you in advance | I'm working in the following exercise: Suppose $(X, \mathcal A, \mu)$ is a finite measure space and suppose $\mathcal F$ is the set of all $\mathcal A$-measurable functions $f: X \rightarrow \mathbb R$. For $f, g \in \mathcal F$, let $$d(f, g)=\int_X\frac{|f-g|}{1+|f-g|}d\mu.$$ Show that: $d(f, g)=0$ if and only if $f=g$ almost everywhere. $d(f, g)=d(g, f)$ $d(f, g)\leq d(f, h)+d(h, g)$ If $f_n$ is a sequence in $\mathcal F$ and if $f \in \mathcal F$ then $d(f_n, f)\rightarrow 0$ if and only if for every $\delta>0$ the following holds: $$\lim_{n\rightarrow\infty}\mu(\{x \in X: |f_n(x)-f(x)|\geq\delta\})=0.$$ If $f_n$ is a Cauchy sequence on $\mathcal F$ then there exists $f \in \mathcal F$ such that $d(f_n, f)\rightarrow 0$. i.e., I must show that this thing is a complete pseudometric space. I have already done 1. 2. 3. 4., but I'm stuck on 5. I don't know which $f$ should the $f_n$ converge to. |
please refer the following code.in there am sending username and password.email has sent to the gmail.but it is in spam folder.it happens only in gmail. Here is my code $to = $email; $subject = ' Web Site| login Details'; // Give the email a subject $message = ' Thanks for signing up! Your account has been created, you can login with the following credentials. ------------------------ Username: '.$uname.' Password: '.$upass.' Web Builder login: '.$ulink.' ------------------------ '; $headers .= 'From:[email protected]' . "\r\n"; $headers .= 'Bcc: [email protected]' ."\r\n"; $headers .= 'Bcc: [email protected]' ."\r\n"; mail($to, $subject, $message, $headers); | This is a tricky one and I've always relied on techniques, such as permission-based emails (i.e. only sending to people you have permission to send to) and not using blatantly spamish terminology. Of late, some of the emails I send out programmatically have started being shuffled into people's spam folder automatically and I'm wondering what I can do about it. This is despite the fact that these particular emails are not ones that humans would mark as spam, specifically, they are emails that contain license keys that people have paid good money for, so I don't think they're going to consider them spam I figure this is a big topic in which I am essentially an ignorant simpleton. |
I have a supposedly trivial question and I'm having a hard time finding an answer. How can I determine the directories where fontspec is looking for OTF files? I want to edit FontAwesome.otf with fontforge following these instructions: On an Ubuntu 14.10 machine with TeX Live 2014 installed I edited this font and saved a duplicate in the following directories because I found copies or links to FontAwesome.otf. /usr/share/texlive/texmf-dist/fonts/opentype/public /usr/share/texmf/fonts/opentype/public /usr/share/texlive/texmf-dist/fonts/opentype/public After editing the corresponding cls file XeLaTeX and LuaLaTeX still can't find the new font. I installed the FontAwesome package by sudo apt-get install fonts-font-awesome. The FontAwesome TeX package was downloaded automatically. I don't know whether this downloaded another copy of the font. | Ubuntu desktop with 12.04 is about to crash. Installed 13.04 on a new machine, want to transfer Book Antiqua font from old machine to the new one. How do I find it on the old machine? My /usr directory is empty. My fonts.conf file has these lines: <!-- Font directory list --> <dir>/usr/share/fonts</dir> <dir>/usr/x11R6/lib/X11/fonts</dir> <dir>/usr/local/share/fonts</dir> <dir>~/.fonts</dir> Don't know what this means, but my /usr directory has nothing in it. |
Is there a Java library for producing LaTeX output from Java? I want a methos, where the argument will be the String and the output will be PDF. | I want to render math formulas in my Java GUI application. I am looking for a library made for computer use, not web use, which can render TeX. I have already tried jLatexMath, but it's very slow when I use it in my application. If there are any other/better, could you point me in the right direction? |
On Tatooine after the Jawa traders are attacked Luke mentions that it must have been sand people who had done it. Ben Kenobi corrects him by saying that they were only made to think it was sand people and mentions the accuracy of the laser blasts saying, "only Imperial storm troopers are so precise." Yet, in several scenes after this it appears as though the storm troopers are terrible shots. For example, the scene where Luke and Leia are gearing up to swing to the other side of a chasm in the Death Star, they're being shot at by several storm troopers, all of whom miss Luke and Leia (while Leia manages to take out a couple of them). There's also the scene where Han charges into a large group of troopers, again, all of whom miss him as he runs away. If they're as highly trained as we're led to believe, then episode 4 would have been the last movie in the series due to the storm troopers dusting off all the heroes. So was the accuracy they showed during the attack on the jawa traders just a fluke or were those small group of troopers just the best shots of all the storm troopers in the whole galaxy? In summary, are there examples in the non-movie canon that shows how accurate storm troopers really are? It seems like they were made bumbling for the movie to make the heroes look better, as is often the case in films. | In the Star Wars films we consistently witness just how poor soldiers stormtroopers are. They show very sub-par marksmanship, crappy house searching tactics, and are easily fooled and defeated by Ewoks and Rebels. That being said, I remember reading a character guide that defined stormtroopers as the very best of the best (best marksman, above average intelligence, etc.). So, in the realm of the Expanded Universe, does the mold that the movies set continue to hold true or are they just the exceptions to the rule? |
I am trying to evalute this integral: $$ \int_{A} x^{m} y^{n} z^{p}(1-x-y-z)^{q}|d x \wedge d y \wedge d z| $$ A=R3 , x , y and z are positive and x+y+z<=1 I used the change of values u=x+y+z , v=(z+y)/u and $\omega$=z/(y+z) which gave me x=u(1-v) y=vu(1-$\omega$) and z=uv$\omega$ The det of the matrix of the change of variables is: u^2*v However, I am struggling to find the boundries for u, v and $\omega$ and carrying the calculation. Any help would be appreciated. | Let $A =$ {$(x,y,z) \in \mathbb{R}^3 |$ $x,y,z \geq 0$ and $x+y+z \leq 1$}. Compute the integral $$\int_{A} x^m y^n z^p (1-x-y-z)^q dx dy dz$$ using new variables $u = x+y+z$, $v=\frac{y+z}{x+y+z}$, $w=\frac{z}{y+z}$. Also, although it was not stated in the problem, I'm assuming that $m,n,p,q \in \mathbb{Z}$. Since $f(x,y,z)=(x+y+z, \frac{y+z}{x+y+z}, \frac{z}{y+z}) = (u,v,w)$, $f^{-1}(u,v,w) = (u(1-v), uv(1-w), uvw)$ Thus J $= \begin{vmatrix} 1-v & -u & 0\\ v(1-w) & u(1-w) & -uv\\ vw & uw & uv\\ \end{vmatrix} = u^2v$ Skipping the part where I find the new limits of integration, and skipping some algebraic simplification we have: $$\int_{A} x^m y^n z^p (1-x-y-z)^q dx dy dz$$ $$= \int_{0}^1 \int_{0}^1 \int_{0}^1 u^{m+n+p+2}(1-u)^q v^{n+p+1}(1-v)^mw^p(1-w)^n du dv dw$$ However, I have no idea where to go from here. Any help would be much appreciated. |
I am playing with the code struct A { char a[20000]; A() { a[0] = 'A'; } ~A() {} }; struct B : A { char a[20000]; B() { a[0] = 'B'; } ~B() {} }; int main() { A *pA = new A; A *pB = new B; delete pA; delete pB; return 0; } Some people wrote () that it should cause a memory leak but it doesn't. I used g++, then valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes --verbose --log-file=valgrind-out.txt and get HEAP SUMMARY: in use at exit: 0 bytes in 0 blocks total heap usage: 3 allocs, 3 frees, 132,704 bytes allocated All heap blocks were freed -- no leaks are possible I know that some old compilers had problems when they try to free memory in similar situations but it looks like that the modern C++ can free memory seamlessly in this case. So I am curios how is it possible? Maybe delete uses information provided by OS for a given allocated memory block? EDIT. It is still unclear for me what exactly can cause the UB for delete *pB if we have empty destructors and constructors. An answer for a question () shows that there are no any UB. | I have a solid understanding of most OOP theory but the one thing that confuses me a lot is virtual destructors. I thought that the destructor always gets called no matter what and for every object in the chain. When are you meant to make them virtual and why? |
Is there a way to reorder labels in Gmail? There is one specific label I need to access more than the others and I would like it at the top. I'm using Airmail 2 as my local IMAP client connected to my email running on Google Apps for Work. | I want to sort the labels in my own order instead of the default abc order, so that, for example, the label named bills should come up first. Any way to do that? |
A followup to the issue I was having yesterday, so I've successfully created a schedule job to delete AS records every hour. global class sharedeletebatch Implements Database.batchable<sobject> { global final string query; global sharedeletebatch(string q){ query=q; } global Database.QueryLocator start(Database.BatchableContext BC){ return Database.getQueryLocator(query); } global void execute(Database.BatchableContext BC,List<SObject> scope){ delete scope; } global void finish(Database.BatchableContext BC){ } } global class deleteaccountsharebatch implements Schedulable { global void execute(SchedulableContext SC) { string str='select id from AccountShare where lastmodifiedbyid =\'0050P000007Kfy2\' limit 5000'; sharedeletebatch bdt=new sharedeletebatch(str); Database.executeBatch(bdt); system.debug(bdt); } } then I run this in anonymous window. deleteaccountsharebatch m = new deleteaccountsharebatch(); String sch = '0 0 * * * ?'; String jobID = system.schedule('Hourly Job', sch, m); The problem I'm having is that it keeps giving me "[REQUEST_RUNNING_TOO_LONG] Your request was running for too long, and has been stopped." error no matter how small I make the limit of the query. So is that even the issue? Is there any other option or approach to mass delete a bunch of records on a schedule? I had no success with data loader either, similar 'been 10 min time out' error. | Been doing tests in sandbox in which I've created about a million accountshares that I need to get rid of for testing. I'm trying data loader in bulk api mode to export than delete but I keep getting: InvalidBatch : Failed to process query: QUERY_TIMEOUT: Your query request was running for too long. Trying again later.; Not sure if I should be waiting longer? Any other options or dataloader configurations I should be looking at? EDIT I've been trying with batch apex jobs yet still having issues. Script string str='select id from AccountShare where lastmodifiedbyid =\'0050P000007Kfy2\' limit 10000'; sharedeletebatch bdt=new sharedeletebatch(str); Database.executeBatch(bdt); system.debug(bdt); Batch global class sharedeletebatch Implements Database.batchable<sobject> { global final string query; global sharedeletebatch(string q){ query=q; } global Database.QueryLocator start(Database.BatchableContext BC){ return Database.getQueryLocator(query); } global void execute(Database.BatchableContext BC,List<SObject> scope){ delete scope; } global void finish(Database.BatchableContext BC){ } } First error: [REQUEST_RUNNING_TOO_LONG] Your request was running for too long, and has been stopped. |
This limit question is an eye opener for me.where is the problem in attachment .guide | This problem comes from our text book. Evaluate $$ \lim\limits_{x \to 0}\frac{2^x-1-x}{x^2} $$ without using either L'Hopital's rule or Taylor series. The picture below shows the solution given by the text book. Many of the people who responded to this question say that the limit diverges. But according to the solution (see the attached image) given by the text book the limit is $ \frac{(\ln2)^2}{2} $. Is there an error in the solution given in the attached image? Note: This problem ( and the solution) comes from Cengage, a long time favourite of the students preparing for IIT JEE Exam (IITs are India's most prestigious engineering institutes.) It is suprising that no student/teacher has found this mistake all these days. However, once posted on Stackexchange, the fallacy was resolved in a very short time. Thanks to all the people who responded to this problem. Now the mistake in the book's solution is found. |
Inspired by I was wondering why the Half Blood Prince left his book as a class copy. One would think that it was precious to him, since he invested so much in it. He made up potions and spells up by his own. I would expect him to keep it to himself. Both, because of the personal value of it, and to prevent others to (as happened at last) use his work (misguided and/or against him). Is there any canon explanation why his book was left as class copy? | Advanced Potion-Making (by Libatius Borage!) was used for sixth year Potions classes. Canon does not make clear whether it was also used for seventh year Potions, so I'm going to presume it was only the sixth years' textbook. Slughorn passes out two battered copies of Advanced Potion-Making to Harry and Ron, and Harry ends up with Snape's old textbook, as we know. A few relevant passages from Half-Blood Prince and Deathly Hallows: Harry bent low to retrieve the book and, as he did so, he saw something scribbled along the bottom of the back cover in the same small, cramped handwriting as the instructions that had won him his bottle of Felix Felicis, now safely hidden inside a pair of socks in his trunk upstairs. This Book is the Property of the Half-Blood Prince Half-Blood Prince - page 183 - Bloomsbury - chapter nine, The Half-Blood Prince ‘SECTUMSEMPRA!’ bellowed Harry from the floor, waving his wand wildly. Blood spurted from Malfoy’s face and chest as though he had been slashed with an invisible sword. He staggered backwards and collapsed on to the waterlogged floor with a great splash, his wand falling from his limp right hand. Half-Blood Prince - page 489 - Bloomsbury - chapter twenty-four, Sectumsempra ‘You dare use my own spells against me, Potter? It was I who invented them – I, the Half-Blood Prince! And you’d turn my inventions on me, like your filthy father, would you? I don’t think so ... no!’ Half-Blood Prince - page 563 - Bloomsbury - chapter twenty-eight, The Flight of the Prince ‘Snape?’ shouted Harry. ‘You didn’t say –’ ‘He lost his hood during the chase. Sectumsempra was always a speciality of Snape’s. I wish I could say I’d paid him back in kind, but it was all I could do to keep George on the broom after he was injured, he was losing so much blood.’ Deathly Hallows - page 66 - Bloomsbury - chapter five, Fallen Warrior There is no question Snape is the Half-Blood Prince, or that Harry got hold of Snape's former textbook; as well as useful potion-making information, it also contained rather questionable (Levicorpus) and downright dangerous original spells (Sectumsempra). Not only did Snape have the opportunity to secure his copy of Advanced Potions Making at the end of his sixth year, I'm guessing he had all of his seventh year to destroy, hide, or keep the book as well. Also, he had at least five years as Hogwarts' known Potions master to ensure the book was kept away from the students. As Potions master, Snape would have had access to all inventory relating to the Potions classes, including Hogwarts' copies of any potions textbooks. It would seem likely, while arranging or cleaning his classroom and stores, Snape would have come across his old textbook at some point. I personally think he would've recognized it. So, to ensure the book didn't fall into students' hands: Why didn't Snape keep or secure his copy of Advanced Potion-Making? (Or did Snape want a student to find it for boastful personal reasons, just as Tom Riddle used the diary Horcrux to take credit for the Basilisk and being the Heir of Slytherin?) |
I know if we delete any post or answer it is not deleted permanently, Suppose for example post which is deleted including my answer but still the post is visible to users having 10K+ reputations. Questions : 1) Is it possible to delete that answer permanently from SO? 2) Is there a way to raise request to SO people to clean my account (which means delete all deleted answers or Posts on my account permanently from SO)? | I can see my deleted answers. Will they ever be purged from the system, either manually or automatically? Does this kind of "deleted post cleanup" occur periodically, or will all deleted answers typically remain in the system until the end of time? |
Is it just me, or is there a general non-constructive attitude, rather than constructive criticism on Stack Overflow? I am having difficulty aligning my internal compass. I understand that certain questions need to be thrown out, and I understand that certain questions are fitting for certain Stack Exchange sites. I understand that the sites ore community moderated, and that a general "average" of community members' persona's will be reflected. My issue is with the fact that, in my opinion, some users are a bit trigger happy with the down vote button, or are just downright rude, without providing any feedback to the user in question. This is in my opinion much more non-constructive to the site than a Q that is slightly off topic, or not worded correctly. When did the down vote become a feel good weapon? I see this regularly where questions not deserving of down votes (in my opinion), get down voted by a what seems like a factor, because a trigger happy user down voted the Q, rather than tried to fix it. And now a bunch of users exercise their down vote button, because someone else did, and they can also do it. I know we cant possibly moderate each down vote before it is applied, and I understand an "average" will be the outcome, but it seems like the good guys, interested in actually contributing in a constructive manner, are outweighed by the, in my opinion, non constructive guys. Its almost like the perceived anonymity of down voting, is being exploited. I attempted to flag one such post, and the moderator replied with (We can't say why people vote the way they do). I understand that the community moderation is the power of these sites. But is it being abused? Situations are created where legitimate questions, that may have been genuinely helpful to other users, are being "played" with by people exercising their privileges instead of their contribution. (Again, the above all in my personal opinion) From personal experience, I can attest to the fact that this behavior is demoralizing, to say the least. I am personally trying hard to contribute. Not for rep, but to give something back as SO has really been helpful to me on multiple occasions. An example, but not specifically aimed at for the above, is provided in the link below this post. The original question, although broad, could be answered or "nudged in the right direction" in my personal opinion. The original question was aggressively acted upon, which I understand needs to happen in some cases. In this case, I feel the original poster, instead of being chased away with a broom, could have been pointed or helped, even if not on SO. I indicated in a comment that this might have to be moved to a different site, like programming, if its not fitting for SO. I attempted to use the community wiki option, and created a new Q&A, which I thought would go to the wiki, and not as a new question. I again, indicated that SO might not be the right place, and that I was making an "attempt" to contribute. Instead of constructive behavior, I experienced more non constructive criticism, than what I would care for when trying to contribute. As I said, maybe its just me. I guess my question revolves around determining if its just me seeing things. (10k only) | There is a distinct decline in the level of civility on all the sites here. Some of this is due to new users coming in and posting spam and other nonsense, but the off-topic and downvote buttons are doing a pretty good job of keeping this under control. Unfortunately, a lot of this is coming from more experienced users, and the site's built-in moderation system does not (and probably cannot) handle this very well. Folks are rushing to pound new users down with "this belongs on meta!", "this is off topic", "this is a duplicate!" and "read the Help!". (Which is correct, but should be done nicer) All this, of course, is accompanied by a flurry of downvotes. This is not very welcoming to new users who don't know about meta, the Help, or what counts as off-topic. Now I am not proposing that we just allow off-topic, meta, or duplicate questions. However, I think we could be gentler in the way we express these sorts of things. Explain what meta and the FAQ are and provide useful links. Just using please and thank-you when asking folks to read the FAQ or post something on meta would be an improvement. I also think we could rein in the downvoting a bit. Not that we shouldn't vote stuff down, but unless a new user's post is clearly spam, voting it down to -1 or -2 should be sufficient to send a message without piling on. I like Stack Exchange and I want it to become a resource for everyone, not just an elitist site for high-rep users on the sites. |
I'm working on a nice problem in measure theory. Given $\mathbb{R}$ with its standard Lebesgue measure on its $\sigma$-algebra and a Lebesgue integrable function $f: \mathbb{R} \rightarrow \mathbb{C}$, what could we say about the limit $$\lim_{t\rightarrow 0} \int |f(x)-f(x+t)|d\lambda(x)$$ Of course with continuous functions, this limit is always equal to zero. But I can see some difficulties arrising quickly. Maybe one can force this integral to be nonzero somewhere when taking a suitable limit for $t$. Certainly when trying to make this into a rigorous proof (that the limit is equal to zero), I did not see a clear way to get this result. I'm not looking for a complete solution but any hints would be appreciated! | I am having a hard time with the following real analysis qual problem. Any help would be awesome. Suppose that $f \in L^p(\mathbb{R})$, where $1\leq p< + \infty$. Let $T_r(f)(t)=f(t−r)$. Show that $\lim_{r \to 0} \|T_rf−f\|_{L_p} =0$, that is $$ \lim_{r\to 0} \left( \int_{\mathbb R} |f(t-r) - f(t)|^p \mathrm d t\right)^{1/p} =0.$$ |
I have a DXF (layout) which is to be spatially adjusted to a point shapefile that has correct X Y cords. When I add both as vector layers to Qgis, point shapefile is right on place but dxf shows a single line. I assume it needs rotation. Vector bender, Vector transformation, Affine Transformation, DXFtoshapeconverter, I tried it all but nothing works. I need help in understanding the process in such cases, where first I need to rotate the layer to match XY plane of the target layer and then georeference. | I have got myself a dxf which is built with units in the wrong scale. How do I upscale that in QGIS? Note it does open in QGIS, just in the wrong map units and location. |
I know that you need axiom of choice to prove Banach–Tarski paradox. But what happens with paradox when we remove axiom of choice? Does theorem become false? Or is there just no proof of it without axiom of choice? | Is it possible to prove the infamous Banach-Tarski theorem without using the Axiom of Choice? I have never seen a proof which refutes this claim. |
Which metrizable topological spaces $(X,\tau)$ posses the following property: Every compatible metric (i.e one which induces the same topology $\tau$) is complete. Compact metrizable spaces satisfy this. Are there any non-compact examples? Note: It turns out that if you impose additional structure the answer is yes. In particular, if $M$ is a smooth manifold, and every Riemannian metric on $M$ is complete, then $M$ must be compact. Reference: Nomizu, Katsumi, and Hideki Ozeki. "The existence of complete Riemannian metrics." Proceedings of the American Mathematical Society 12.6 (1961): 889-891. | I have seen that completeness is not a topological property like compactness or connectedness. I have seen some examples also showing that there are two equivalent metrics one of which is complete and the other one is incomplete. I want to know some general result. Consider any metric space $(X,d)$. Let $d$ be complete. Does there exist an equivalent metric $d'$ in $X$ which is incomplete? When $d$ is compact, such $d'$ does not exist (Since compactness implies completeness). So answer me when $d$ is noncompact. |
Let $A$ be an $n \times n$ matrix. We know that $A^{23} = 0$. What are the eigenvalues of $A$? I think it's just $0$, but I'm not sure. How should I do this problem? | I need to prove that: if a linear operator $\phi : V \rightarrow V$ on a vector space is nilpotent, then its only eigenvalue is $0$. I know how to prove that this for a nilpotent matrix, but I'm not sure in the case of an operator. How would I be able to relate $\phi$ to a matrix? Note: A nilpotent operator $\phi$ has been defined as an operator that satisfies $\phi^{n} = 0$ for some $n \geq 1$. |
After getting an inbox notification in the app, clicking on the notification de-highlights it in the app but does not acknowledge the notification on the site itself. Should it do so? | My phone alerts me that I have a new message in my Stack Overflow inbox. After I read the new message in the Android app it shows 0 unread messages. The next time I visit the main site on my notebook the new (December 2013) Top Bar says that I have one unread message: the message that I read on my phone. Even if I shut down my browser and wait a few minutes (to give the Android app time to "sync", or whatever), the new message indicator in the new Top Bar doesn't go away until I click it. I don't recall this happening with the older top bar, so perhaps the new Top Bar and the Android app need to get better acquainted. |
$\Bbb{C} \otimes_{\Bbb{R}} \Bbb{C}$ and $\Bbb{C} \otimes_{\Bbb{C}} \Bbb{C}$ are not isomorphic as $\Bbb{R}$-vector spaces. Clearly each tensor product is both a left and right $R$-module. But how do I show that they're not isomorphic? I'm trying to argue as in other examples, so in $M = \Bbb{C} \otimes_{\Bbb{C}} \Bbb{C}$, there's the simple tensor $(-1)\otimes i = (i^2) \otimes i = i \otimes(-1)$. But those two simple tensors are not equal in $N = \Bbb{C} \otimes_{\Bbb{R}} \Bbb{C}$. I'm not sure how to show that. Let $\phi : M \to N$ be an isomorphism. Then $\phi((-1)\otimes i)$ must equal $\phi (i \otimes (-1))$. | Are $\mathbb{C} \otimes _\mathbb{R} \mathbb{C}$ and $\mathbb{C} \otimes _\mathbb{C} \mathbb{C}$ isomorphic as $\mathbb{R}$-vector spaces? I am having a very hard time at digesting tensor products and I do not know how to "compare" tensor products over different rings. My hunch is that they are not isomorphic. It is easy to see that $\mathbb{C} \otimes _\mathbb{R} \mathbb{C}$ is an $\mathbb{R}$-vector space of dimension $4$. I suspect that $\mathbb{C} \otimes _\mathbb{C} \mathbb{C}$ is also an $\mathbb{R}$-vector space but of lower dimension, but I have no idea how to show this or if indeed this intuition is correct. Thank you. |
Let a,b be Natural numbers where a > 1. Also p is a prime number. If $ax^2 + bx + c = p$ for two distinct integer values of x, then prove that $ax^2 + bx + c \neq 2p$ for any integral values of x. So this seems to be a pretty straightforward question and I got the final expression that is $p= a (x-y)(x-z)$ where y and z are roots of equations $ax^2 + bx + c - p$, so I got p has three factors while a prime number can only have 2 factors. But I couldn’t understand what would happen if $x-y = x-z = 1$. So essentially I need to try and prove that $y \neq z$. Thank you. | We had received some questions on Quadratic equations, But I wasnt able to do one. Here it goes: Let $a,b$ be natural numbers $a>1$. Also, $p$ is a prime number. If $ax^2+bx+c=p$ for 2 distinct integral values of $x$. Then the number of integral roots of the equation $ax^2+bx+c=2p$ is ? Well I know the answer is $0$, But I am not able to get it properly. |
Is there easy way of having a rounded bevel on text… ie like so… It was painful to model this on the text and when I added a bevel I got all sorts of bad geometry and had to rebuild it etc, like so… so just wondering if there was an easy way I was missing? Thanks in advance. | How can I make a bevel, like in the "Gibson," for my personal inscription? Is there an automatic method to do so? |
I created a model for two different datasets that have different scales. When checking which one performed better, I am struggling with figuring out the best methodology. My top choices right now are R^2, RMSE, and variance. However, R^2 seems to be the only option that works best in my opinion because it doesn't seem to take into account the scale of the data but wondering if there are options such as normalizing the numbers etc. Below is a sample situation: Date Group Actual_Values Predicted_Values 2020-04-24 A 0.181 0.140 2020-04-27 A 0.190 0.127 2020-04-28 A 0.188 0.126 2020-04-29 A 0.188 0.123 2020-04-30 A 0.185 0.122 2020-05-01 A 0.178 0.124 2020-05-04 A 0.182 0.118 2020-05-05 A 0.180 0.120 2020-05-06 A 0.178 0.120 2020-05-07 A 0.180 0.121 2020-05-08 A 0.184 0.124 2020-04-24 B 86.24 86.25 2020-04-27 B 94.00 86.65 2020-04-28 B 98.44 86.88 2020-04-29 B 107.3 87.05 2020-04-30 B 94.26 87.27 2020-05-01 B 96.71 87.42 2020-05-04 B 92.28 87.59 2020-05-05 B 90.97 87.73 2020-05-06 B 87.47 87.80 2020-05-07 B 88.93 87.90 2020-05-08 B 92.41 87.93 From this dataset I tested the following code: library(ModelMetrics) with_rmse<- historical_results %>% group_by(Group) %>% summarise( RMSE = rmse(Predicted_Values, Actual_Values) ,R2 = cor(Predicted_Values, Actual_Values)^2 ,variance = abs(var(Predicted_Values, Actual_Values)) ) Group RMSE R2 variance A 0.05929241 0.02067078 3.548883e-06 B 8.461625 0.02991999 0.5624356 So for example, the above results like 8.4 for RMSE may actually be good but looks bad just because the original values were higher than A. Any help would be great, thanks! | I created a model for two different datasets that have different scales. When checking which one performed better, I am struggling with figuring out the best methodology. My top choices right now are R^2, RMSE, and variance. However, R^2 seems to be the only option that works best in my opinion because it doesn't seem to take into account the scale of the data but wondering if there are options such as normalizing the numbers etc. Below is a sample situation: Date Group Actual_Values Predicted_Values 2020-04-24 A 0.181 0.140 2020-04-27 A 0.190 0.127 2020-04-28 A 0.188 0.126 2020-04-29 A 0.188 0.123 2020-04-30 A 0.185 0.122 2020-05-01 A 0.178 0.124 2020-05-04 A 0.182 0.118 2020-05-05 A 0.180 0.120 2020-05-06 A 0.178 0.120 2020-05-07 A 0.180 0.121 2020-05-08 A 0.184 0.124 2020-04-24 B 86.24 86.25 2020-04-27 B 94.00 86.65 2020-04-28 B 98.44 86.88 2020-04-29 B 107.3 87.05 2020-04-30 B 94.26 87.27 2020-05-01 B 96.71 87.42 2020-05-04 B 92.28 87.59 2020-05-05 B 90.97 87.73 2020-05-06 B 87.47 87.80 2020-05-07 B 88.93 87.90 2020-05-08 B 92.41 87.93 From this dataset I tested the following code: library(ModelMetrics) with_rmse<- historical_results %>% group_by(Group) %>% summarise( RMSE = rmse(Predicted_Values, Actual_Values) ,R2 = cor(Predicted_Values, Actual_Values)^2 ,variance = abs(var(Predicted_Values, Actual_Values)) ) Group RMSE R2 variance A 0.05929241 0.02067078 3.548883e-06 B 8.461625 0.02991999 0.5624356 So for example, the above results like 8.4 for RMSE may actually be good but looks bad just because the original values were higher than A. Any help would be great, thanks! This is just an example - disregard the bad R2 :) |
I want to change the url structure for custom post type post type --> movies This url structure sitename.com/movies/post-name need to change sitename.com/custom-taxonomy/movies/post-name /%customtaxonomy%/%customposttype%/%postname%/ | I am having trouble working with WordPress rewrite rules, and could use some help. I have a custom post type called _shows_. All shows have a single custom taxonomy category _show-category_. A _show_ will never have more than one _show-category_. I would like my urls to route in this manner: www.mysite.com/shows/ => archive-shows.php www.mysite.com/shows/%category%/ => taxonomy-show-category.php www.mysite.com/shows/%category%/%postname%/ => single-shows.php So as a real world example, lets say we have a _show-category_ "Foo" and a _show_ post titled "Bar" that has "Foo" as it's _show-category_. I would expect my WordPress app to look like this: www.mysite.com/shows/foo/ => shows all posts under the foo category www.mysite.com/shows/foo/bar => shows the indivual post I try to avoid plugins when possible, but am open to any solution. |
I am one of those people who likes seeing what badges and accomplishments users (especially new users) have done. I am also one of those people who uses the iOS app for SE because it is easier. However, unfortunately I can't combine these two things! So I think we should! In short, please can we allow users to see other users' badges while on the app? | When viewing a user's profile from the iOS app, it would be nice to be able to see what badges they have, instead of just the counts. |
im getting a problem, i have alienware m14xr2 with i7 cpu, using linux (right now im using ubuntu 18.04) also manjaro, i have a problem on heavy load my notebook is shutting down due to overheating because when the temp is for example 90c my fans are running at 4200 rpm and is not sufficient to reduce the temp and when my notebook get 105c shutdown. in windows this not happen because the fan at that temp run at like 7200 rpm, my fan is 10.4CFM, i check my fan speed using lm-sensors and i8kmod module for dell in linux and the max speed is only 4200 I try to manipulate it manually using fan control and i8kmod trying to set the fan speed to 7200 rpm but it don't take my settings. I already try with other board, and with new thermal paste but the same, in windows this not happens, windows is handling the fan and cpu temperature fine. Thanks. | How can I control the computer's fan speed? On Windows there is a wonderful program called . |
It is often said that variables should be double quoted when used. In the following example I want to have the command echo "You can't see me" in a variable and run it in such a way that the output is You can't see me. This is the end goal. $ cmd="echo \"You can't see me\"" $ echo "$cmd" echo "You can't see me" $ $cmd "You can't see me" $ "$cmd" echo "You can't see me": command not found So $cmd ran and it included double quotes which I did not want to have, and following the recommendation of double quoting the variables led to an error. Does the recommendation have exceptions despite the fact that resources say that they always should be used? I know how I can get the result that I want by running eval "$cmd" (or without the double quotes), or by an appropriate transformation on the output after running $cmd (without double quotes), but how do I avoid this issue? | $ ls -l /tmp/test/my\ dir/ total 0 I was wondering why the following ways to run the above command fail or succeed? $ abc='ls -l "/tmp/test/my dir"' $ $abc ls: cannot access '"/tmp/test/my': No such file or directory ls: cannot access 'dir"': No such file or directory $ "$abc" bash: ls -l "/tmp/test/my dir": No such file or directory $ bash -c $abc 'my dir' $ bash -c "$abc" total 0 $ eval $abc total 0 $ eval "$abc" total 0 |
Show that for any k∈N, if $2^{3k-1} +5\cdot3^k$ is divisible by 11 then, $2^{3^{(k+2)-1}} +5\cdot3^{k+2}$ is divisible by 11. Base Case: k = 2 $\implies2^{3*2-1} +\cdot3^2 =77$ Since 77 is divisible by 11, the base case holds true I.H: Assume it is true for $2^{3x-1} +5\cdot3^x$,x∈N Then; for k=x+1 $$\implies 2^{3(x+1)-1} +5\cdot3^{x+1}$$ $$\implies 2^{3x-1}\cdot2^3 +5\cdot(3^x\cdot3^1)$$ $$\implies 2^{3x-1}\cdot8 +15\cdot3^x$$ How do i proceed from what i have so far, also what variable do i use since k is already been used? | Question: Part a: Prove that for any $ b\in \Bbb N,$ if $ 2^{3b -1} + 5 . 3^{b}$ is divisible by $ 11$, then $ 2^{3(b+2) -1} + 5 . 3^{b+2}$ is divisible by $11$. Part b: Is statement 1 or statement 2 true? Explain answer. For any odd number $a\in \Bbb N $, $ 2^{3a -1} + 5 . 3^{a}$ is divisible by $ 11$ For any even number $a\in \Bbb N $, $ 2^{3a -1} + 5 . 3^{a}$ is divisible by $ 11$ My attempt: Part a: I am not sure what the base case should be. Induction hypothesis: Assume $ 2^{3k -1} + 5 . 3^{k}$ is divisible by $ 11$, for some $k$ natural number. I am not sure how to prove true for $ 2^{3(k+2) -1} + 5 . 3^{k+2}$. Part b: Would statement 2 be correct since the expression is divisible by $11$ when $ a=2$ |
Below is my code. I set the object to null, still my print statement can print the property name correctly. Can anyone tell me what's happening? public class MyClass { String name; public String getName() { return name; } public void setName(String s) { name = s; } public static void main(String args[]) { MyClass obj = new MyClass(); obj.changeName(obj); System.out.println("Name = " + obj.getName()); } public MyClass() { name = "A"; } public void changeName(MyClass obj) { obj.setName("B"); obj = null; } } Output is: Name = B | I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation? |
I am going to Venice in the next weeks and specially during the night I would like to have these 2 kind of results if possible with my camera. Can you recommend me the settings i would need to use for these kind of pictures at nigh? | Can you suggest me what kind of settings would I need to make these kind of pictures. The scenario will be just like the pictures: Outdoors, lights on the streets, and maybe very small rivers with houses and lights on each side. Just like Venice or Brugge in Belgium. |
I noticed this when fiddling around on one of my questions. Steps to reproduce: Go to a question (this one), and use the T (10k only) shortcut to open the tag editor. Add any tag (although the one is preferred), click "Save Edits", let it give you the error, then cancel it. Watch your hat fall off! I also did this on post, and accidentally pulled Anita's hairdo off. With apologies to Anita, can we fix that? | It seems like there is a bug that is causing a duplicate hat to appear when I expand info, like pressing "(more)" on a suggested edit. This bug does not seem to be specific to the suggested edits review queue though, as others have reported seeing this bug in other places, like code snippet expansion. Steps to repro: Put on a hat. Navigate to one of your own suggested edits. (You can just also open the Suggested Edits review queue and go to a random suggestion, but there is no guarantee any of those users will be wearing a hat.) Click the "(more)" button to expand the top box. What should happen: Hat should shift down with the rest of the content. What happens: All the content shifts down, but a duplicate hat remains in the initial place. Before expansion: After expansion with duplicate hat: |
I learned quite a bit from the question I watched the first 3 episodes of TOS on netflix but just couldn't get into it. Does TOS get better or is it likely that I wouldn't enjoy the rest of the series? I enjoyed the 2009 movie quite a bit though. I've been thinking about giving TNG a try. However I don't have too much time to devote to these things. I've also heard good things about The Wrath of Khan though as well. My main questions: Would I be confused or be missing quite a bit if I watched The Wrath of Khan first? Does it even make sense to start with The Wrath of Khan given that I didn't enjoy the first few episodes of TOS? Would I be lost if I started watching TNG after that? | I don't know anything about Star Trek except for the fact that it's about spaceships. In the person only wanted to watch the TV series. I want to watch every movie and TV series there is about Star Trek but I don't know where to start. I found this page on which is about a time line. Do I need to watch it in this order? Are the movies and TV series related? |
I used wget within bash to download a bunch of files from a parameterized URL. My URL file looked something like this: http://www.example.com/Home/Sales?lrsn=48726 http://www.example.com/Home/Sales?lrsn=48727 http://www.example.com/Home/Sales?lrsn=48728 ...and so on I ran this wget command to fetch all the files into my directory: wget -i urlfile.txt The resulting set of files-- when I do an ls in my directory-- has names like this: 'Sales?lrsn=48726' 'Sales?lrsn=48727' 'Sales?lrsn=48728' My problem is that I cannot figure out how to use wildcards with those files. E.g., if I type ls 'Sales*8', I would expect it to list 'Sales?lrsn=48728' (and any other matches). Instead, I get "No such file or directory". Questions: What do I need to do to use wildcards with the files that my wget operation created? Simple example would be how to match using ls. How would one even create such files to reproduce this. I.e., I tried touch 'text.txt' and touch "'test.txt'" and other variations, but I can't seem to make a file that lists as 'test.txt' (starting and ending single-quotes). Is there a simple way to provide a naming convention for downloads using the wget -i input mode? (I'm pretty sure the answer to this is "No," but... figured I'd ask.) | I just noticed that on one of my machines (running Debian Sid) whenever I type ls any file name with spaces has single quotes surrounding it. I immediately checked my aliases, only to find them intact. wyatt@debian630:~/testdir$ ls 'test 1.txt' test1.txt wyatt@debian630:~/testdir$ alias alias ls='ls --color=auto' alias wget='wget --content-disposition' wyatt@debian630:~/testdir$ Another test, with files containing single quotes in their names (also answering a request by jimmij): wyatt@debian630:~/testdir$ ls 'test 1.txt' test1.txt 'thishasasinglequotehere'\''.txt' wyatt@debian630:~/testdir$ touch "'test 1.txt'" wyatt@debian630:~/testdir$ ls ''\''test 1.txt'\''' test1.txt 'test 1.txt' 'thishasasinglequotehere'\''.txt' update with new coreutils-8.26 output (which is admittedly much less confusing, but still irritating to have by default). Thanks to Pádraig Brady for this printout: $ ls "'test 1.txt'" test1.txt 'test 1.txt' "thishasasinglequotehere'.txt" $ ls -N 'test 1.txt' test1.txt test 1.txt thishasasinglequotehere'.txt Why is this happening? How do I stop it properly? To be clear, I myself set ls to automatically color output. It just never put quotes around things before. I'm running bash and coreutils 8.25. Any way to fix this without a recompile? EDIT: Appears the coreutils developers to break with the convention and make this the global default. UPDATE - October 2017 - Debian Sid has re-enabled the shell escape quoting by default. And at the bottom of the reply chain to the previous bug report, "the change was intentional and will remain." I thought this had already been settled, but apparently it was just reverted so that the "stable" Debian branch could keep its "feature freeze" while getting the other fixes, etc. from the newer version. So that's a shame (in my opinion). UPDATE: April 2019: Just found a that was caused by this change to ls. When you're confusing developers and generating false bug reports, I think it might be time to re-evaluate your changes. Update: Android toybox ls is now doing something similar to this but with backslashes instead of quotes. Using the -q option makes spaces render as 'question mark characters' (I have not checked what they are, since they're obviously not spaces), so the only fix I have found so far without rooting the device in question is to add this to a script and source it when launching a shell. This function makes ls use columns if in a terminal and otherwise print one-per-line, while tricking ls into printing spaces verbatim because it's running through a pipe. ls() { # only way I can stop ls from escaping with backslashes if [ -t 1 ]; then /system/bin/ls -C $@ |cat else /system/bin/ls $@ |cat fi } |
Let $u\in\mathcal{C}^2(\Omega)\cap\mathcal{C}^0(\overline{\Omega})$ be a classical solution of $\Delta u=u^3-u$ on a bounded domain $\Omega\subset\mathbb{R}^2$. Assume that $u=0$ on $\partial\Omega$. Then it holds that $|u|\leq 1$ on $\Omega$. Does someone know how to prove that? | Let us consider that $u\in C^2(\Omega)\cap C^0(\Omega)$ and satisfying the following equation . $\Delta u=u^3-u , x\in\Omega$ and $u=0 $ in $\partial \Omega$ $\Omega \subset \mathbb R^n$ and bounded . I need hints to find out what possible value $u$ can take ? Thank you for ur hints in advance . |
Good evening lovely StackExchange forum! First of all sorry if this question has been asked already, I didn't find an appropriate answer searching through the internet on my own and got confused a lot. I've met someone who doesn't have an European passport.. and of course I fell in love with her and want to meet her again. She luckily decided the same. She entered the Schengen Area on the 03.10 and left on 12.12.2018, so she stayed for 71 days and her 180 days period ends on the 31.03 if I am counting correctly. So my question is, could she use those leftover 19 days to "extend" her upcoming new tourist visa? Like arriving the 13.03, using the 19 days and then start the new 90/180 days period. If yes, does she has to stay 1 day out of the Schengen Area and reenter, or what would you suggest to take care about/ how to do it? Thanks a lot for any answer in advance, you will help in the name of love haha Trebuh The edit: Hello, I still don't find an appropriate answer on my own or I seem to not understand the other answers properly, I am not a native speaker and got problems with the level of explanation of some of the answers. Also it would be very nice if you answer my actual question, as the 180 day period never ends / there is no single 180- day period doesn't help me, it confuses me as I find different opinions about that. I was simply asking if the given case is possible and if yes, if she has to leave the Schengen room for a day. The question is really easy. Thank you. | I have searched the web a lot and could not find an answer that fits my situation. Here are two links that are quite contradictory: My situation: I've visited Portugal in December 2012 for 29 days on a Schengen visa valid from December 1st, 2012 to February 1st, 2013 for research purposes (I am a Ph.D. student). I want to visit Sweden from February 10th, 2013 to May 10th, 2013 (89 days). I have applied for a Schengen visa again (for research). How will the 90/180 rule work in my situation? |
I bought the iPhone 6 gold 64 gb three months ago from USA. But now I'm resident in India. Is there any way to transfer the warranty in India of my phone? | I'm about to travel to the US, where iPods / AirPods / iPhone are much cheaper than in my country. I wonder if Apple's warranty is international, and/or what warranty coverage exists when I return to my country. Where can I understand what Apple Warranty covers in the US when products leave the US? |
In this problem I have integrated the expression |f'(x) | to get $f(x)$<$x/2$ but after that how to proceed with the problem is clueless.Kindly help. | Let $f:\Bbb R \to \Bbb R$ be differentiable on $\Bbb R$ and $|f'(x)| \leq \frac {1}2$ for all $x\in \Bbb R$. Let $a \in \Bbb R$ and define $x_1 = a, x_{n+1} = f(x_n)$ for all $n \in \Bbb N$. Show that $\{x_n\}$ is a Cauchy sequence. And show that $\exists x \in \Bbb R$ such that $f(x) = x$. |
When a user wants to delete their question, don't let them click delete, then make them read this long message asking them to think it over when they actually can't delete it, since it has answers by others. IOW, I think it's a bug that the system goes so far as to put up a sort of a warning (red button means warning in my book!) urging that users think it over when they don't actually have a choice, as they actually can't delete it, since it has answers by others. Note: I'm not urging that a particular question be deleted and not seeking moderator action; note that I'm tagging this bug, not support. | So I tried deleting a question, my question. I'm not a mod, but I have reputation above 10k. I received this message after hitting delete, asking me to make sure I wanted to: But after clicking Delete Question, I saw this: It turns out that because the question has answers, I'm prohibited from deleting it. If I can't actually delete this question at all, could it just tell me immediately, and only show me the warning if I can actually delete it? This is akin to the following analogy. You see a flyer in your local paper stating there's a new burger shop opening. Great, you think to yourself, and rush over to get yourself some burgers. On your way into the parking lot, you see a huge banner proclaiming one of their newest burgers. You see some employees walk in and out of the restaurant, with T-Shirt with pictures of burgers on them. Great, you think to yourself, and walk in. You get in line, and after what seems like ages, you finally make it to the front. You look up at the menu. You see that they also sell sandwiches. No, you tell yourself, I'm looking for burgers. You see that they also sell burritos! No, you tell yourself, I'm looking for burgers. Then you see that they sell burgers. Great! You pick out a burger, then tell the employee at the register, "Sir, I'd like to get a regular burger please." Immediately, the employee looks up, with a quizzical look on his face, saying "Sir? We don't sell burgers here.". It's the same situation. I've come to that prompt so that I can delete a question. After repeated messages and windows letting me know the consequences of deleting, what will happen after I have it deleted, I am told that the option of having it deleted by my own hand never existed in the first place. |
I have multiple shapefiles each with many polygons. I am used to the attribute table listing them all in rows and columns. In this case, all attribute tables show me the attributes of a single polygon which I can select from a list on the left (see screenshot). How do I change my attribute table to the standard view? My QGIS version is 3.14 | How does one change the Attribute table view on QGIS 3? An initial answer says to use the Switch to Table view button but I can't seem to find this button. |
I have to following problem $$\max_{x}x^TAx+b^Tx\quad \mathrm{s.t.}\quad x^Tx\leq c,$$ where $A$ is real, symmetric and positive semi-definite. Firstly I tried to solve the problem with the KKT, but that didn't lead to any good results for arbitrary matrices. So now I argue in the following way Since $x^TAx \leq \lambda_{max}x^Tx$, I get $x^TAx+b^Tx\leq \lambda_{max}x^Tx + b^Tx$ and with the constraint $x^Tx\leq c$ this leads to $$x^TAx+b^Tx\leq \lambda_{max}x^Tx + b^Tx \leq \lambda_{max}c+b^Tx$$ So my solution would be $$x=\sqrt{c}v_{max},$$ where $v_{max}$ is the unit-eigenvector corresponding to the largest eigenvalue $\lambda_{max}$ of $A$. The thing that confuses me about this solution is that the solution does not depend on $b$ at all, so I am sure it is not correct... | Consider the $n$-dimensional quadratically constrained quadratic optimization problem $$\begin{array}{ll} \text{maximize} & \frac12 x^T A x + b^T x\\ \text{subject to} & \| x \|_2 \le 1\end{array}$$ where $A$ is a symmetric $n\times n$ matrix that may be indefinite. Given the symmetry of the constraint, is there a nice closed-form solution, perhaps in terms of the eigendecomposition of $A$? |
Three shooters shoot at the same target, each of them shoots just once. The three of them respectively hit the target with a probability of 60%, 70%, and 80%. What is the probability that the shooters will hit the target a) at least once b) at least twice I have an approach to this but I'm not sure if there's just a formula for this type of thing. For part (a) I was thinking of simply adding the probability of all of the valid scenarios. For instance $$[P(A)*(1-P(B))*(1-P(C))]+[(1-P(A))*P(B)*(1-P(C))]+...$$ and so on until I cover all scenarios in which "at least one" hits. Is there a simpler way? (i assume this would also apply to part b) | Three shooters shoot at the same target, each of them shoots just once. The first one hits the target with a probability of $70\%$, the second one with a probability of $80\%$, and the third one with a probability of $90\%$. What is the probability that the shooters will hit the target a) at least once? b) at least twice? I don't understand well this problem. If each shooter shoots at the target once, how can each of them shoot at it twice? Do you know how to solve this problem? |
My code is: a = {"a1","a2","a3"} b = a b[1] = "b1" print(a[1]) I can't understand why the result is "b1" instead of "a1". The same is: a = {"a1","a2","a3"} b = a c = b b[1] = "b1" c[2] = "c2" print(a[1]) print(a[2]) print(a[3]) The result will be: "b1" "c2" "a3". Can I copy variables in another way? | Recently I wrote a bit of Lua code something like: local a = {} for i = 1, n do local copy = a -- alter the values in the copy end Obviously, that wasn't what I wanted to do since variables hold references to an anonymous table not the values of the table themselves in Lua. This is clearly laid out in , but I'd forgotten about it. So the question is what should I write instead of copy = a to get a copy of the values in a? |
I have Stack Exchange app version 1.0.83 (observed before on 1.0.62). My mobile is Micromax Canvas Spark and Android version is 5.0 Lollipop. There is a problem with the application. It stops working if the device is rotated from portrait to landscape when a post is being submitted. Steps to reproduce: Write anything on the title and body, then click the preview button and rotate your mobile phone. The app is fantastic otherwise. Is it a problem with the app or with my android? | App version: 1.0.52 When you edit a question and rotate the screen while the "Getting preview" or "Posting edit" dialog is showing the app will crash. 12-25 21:38:07.033 E/AndroidRuntime(4768): FATAL EXCEPTION: main 12-25 21:38:07.033 E/AndroidRuntime(4768): Process: com.stackexchange.marvin, PID: 4768 12-25 21:38:07.033 E/AndroidRuntime(4768): java.lang.IllegalArgumentException: View=com.android.internal.policy.impl.PhoneWindow$DecorView{42440ba0 V.E..... R......D 0,0-684,192} not attached to window manager 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.view.WindowManagerGlobal.findViewLocked(WindowManagerGlobal.java:370) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.view.WindowManagerGlobal.removeView(WindowManagerGlobal.java:299) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.view.WindowManagerImpl.removeViewImmediate(WindowManagerImpl.java:84) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.app.Dialog.dismissDialog(Dialog.java:329) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.app.Dialog.dismiss(Dialog.java:312) 12-25 21:38:07.033 E/AndroidRuntime(4768): at com.stackexchange.marvin.core.OperationThatCanFail$1.onPostExecute(OperationThatCanFail.java:81) 12-25 21:38:07.033 E/AndroidRuntime(4768): at com.stackexchange.marvin.core.OperationThatCanFail$1.onPostExecute(OperationThatCanFail.java:67) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.os.AsyncTask.finish(AsyncTask.java:632) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.os.AsyncTask.access$600(AsyncTask.java:177) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:645) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.os.Handler.dispatchMessage(Handler.java:102) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.os.Looper.loop(Looper.java:136) 12-25 21:38:07.033 E/AndroidRuntime(4768): at android.app.ActivityThread.main(ActivityThread.java:5097) 12-25 21:38:07.033 E/AndroidRuntime(4768): at java.lang.reflect.Method.invokeNative(Native Method) 12-25 21:38:07.033 E/AndroidRuntime(4768): at java.lang.reflect.Method.invoke(Method.java:515) 12-25 21:38:07.033 E/AndroidRuntime(4768): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785) 12-25 21:38:07.033 E/AndroidRuntime(4768): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601) 12-25 21:38:07.033 E/AndroidRuntime(4768): at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132) 12-25 21:38:07.033 E/AndroidRuntime(4768): at dalvik.system.NativeStart.main(Native Method) 12-25 21:38:07.035 W/ActivityManager(27384): Force finishing activity com.stackexchange.marvin/.ui.AskOrEditQuestionActivity |
Im attempting to perform an if statement at a certain time but can't get it to execute when it is that time. I am running the program when it reaches that time and nothing happens. import os import datetime now = datetime.datetime.now() if now.hour == 20 and now.minute == 46: print ("REBOOTING") os.system("shutdown -t 0 -r -f") | I'm looking for a library in Python which will provide at and cron like functionality. I'd quite like have a pure Python solution, rather than relying on tools installed on the box; this way I run on machines with no cron. For those unfamiliar with cron: you can schedule tasks based upon an expression like: 0 2 * * 7 /usr/bin/run-backup # run the backups at 0200 on Every Sunday 0 9-17/2 * * 1-5 /usr/bin/purge-temps # run the purge temps command, every 2 hours between 9am and 5pm on Mondays to Fridays. The cron time expression syntax is less important, but I would like to have something with this sort of flexibility. If there isn't something that does this for me out-the-box, any suggestions for the building blocks to make something like this would be gratefully received. Edit I'm not interested in launching processes, just "jobs" also written in Python - python functions. By necessity I think this would be a different thread, but not in a different process. To this end, I'm looking for the expressivity of the cron time expression, but in Python. Cron has been around for years, but I'm trying to be as portable as possible. I cannot rely on its presence. |
I am trying to update the packages on Ubuntu 12.04 LTS, which is running on a flash drive. I tried in the command: sudo apt-get update and receive the following error: W: Duplicate sources.list entry cdrom://Ubuntu 12.04.3 LTS _Precise Pangolin_ - Release amd64 (20130820.1)/ precise/main i386 Packages (/var/lib/apt/lists/Ubuntu%2012.04.3%20LTS%20%5fPrecise%20Pangolin%5f%20-%20Release%20amd64%20(20130820.1)_dists_precise_main_binary-i386_Packages) W: Duplicate sources.list entry cdrom://Ubuntu 12.04.3 LTS _Precise Pangolin_ - Release amd64 (20130820.1)/ precise/restricted i386 Packages (/var/lib/apt/lists/Ubuntu%2012.04.3%20LTS%20%5fPrecise%20Pangolin%5f%20-%20Release%20amd64%20(20130820.1)_dists_precise_restricted_binary-i386_Packages)' How can I fix this problem so the system can update packages correctly? | Every time I try to do some update (sudo apt-get update) it says: Reading package lists ... ready W: Duplicate sources.list entry http://archive.canonical.com/ubuntu/ need /partner amd64 Packages (/var/lib/apt/lists/archive.canonical.com_ubuntu_dists_precise_partner_binary-amd64_Packages) W: Duplicate sources.list entry http://archive.canonical.com/ubuntu/ need /partner i386 Packages (/var/lib/apt/lists/archive.canonical.com_ubuntu_dists_precise_partner_binary-i386_Packages) W: You have to run apt-get update to correct these problems sources.list: ls /etc/apt/sources.list.d/ as requested: milton@milton-HuronRiver-Platform:~$ ls /etc/apt/sources.list.d/ emesene-team-emesene-stable-precise.list precise-partner.list precise-partner.list.save upubuntu-com-chat-precise.list upubuntu-com-chat-precise.list.save |
I have a WordPress site and for a very complicated reason I have to set some post type's template to empty file. Nothing. Which means I have a URL on my site (let's say: example.com/postype/the-best-post/) which displays nothing (it doesn't only display nothing it's also really empty, like if you view the source, no code at all). So is it bad for my site? And if it is do i have another alternative that would make it alright (some way to say to Google robots. I'm letting you know that this is a empty page and you have no reason to index it so don't punish me please?!) Note: This is isn't a duplicate of webmasters.stackexchange.com/questions/106931/… because it's about pages with html, just with no content and this is about pages with no html at all. | How do search engines see empty pages? Is it a good thing or a bad thing for a website to have pages with no content? |
i have seen newton's third law as every action has equal and opposite reactions and they act on different bodies, my concern is is it only when both the bodies are at rest as while standing on water i m giving a force mg to water and the water should give me back mg keeping me in equilibrium,where m i going wrong. i understand that its the normal reaction of water that should balance my weight to keep myself in equilibrium but my concern is why the normal reaction is not equal to mg,i understand it very well that as my foot presses water,the water yields,but my query is why all these things happen. | I try to stand on water surface but I just drown. A book resting on the table because of the W(gravitational Force) and normal force of the table acting on the book oppositely in equal magnitude being canceled out. When it comes to a fluid (air, water, oil etc) If I put my two feet on the surface I will simply drown. Why that? See, the weight of my body is acting on the surface and according to the third law at that instant there will be an equal and opposite force acting on me from the surface. So should not I be able to stand? If you are about to say that fluid molecules have surface tension and they are not steady then I would like to say the little portion of weight of any point of my body that pushes the tiny fluid molecule, that tiny part should cancel that little amount of weight. By this each and every point of my body (along with my Centre of gravity) part should have a net 0 force which should make stand on the fluid surface theoretically. But in practical case it doesn't happen. Why that? I can stand on frozen Lake but can't stand when it is not frozen. |
I am passing a file path to a method. An example is the following: The method-- def example(image): code not shown The call to the method-- example("resources/1.png") In this, I want to remove the "resources/" part using the example method and simply return "1.png". How can I do that? | How to get the filename without the extension from a path in Python? For instance, if I had "/path/to/some/file.txt", I would want "file". |
What's the difference between "a" and "the" in the following sentence? This is a/the story of a little girl in a wheelchair called Susan who laughs, sings, flies and swings – just like every other little girl. | The single sentence: The novel tells the story of a salesman. Can I say: The novel tells a story of a salesman? I chose a story, but the answer is the story. |
I just got to the US, normally I use my ESTA but this time I asked and was granted the B1B2 visa. When I got to the airport in customs the officer was chatting with me, didn't stamp my passport. So I got home went to see my I 94 and says I can only stay the 90. What can I do to stay the 6 months? I do have the B1 B2 visa but it's like the officer didn't count it or saw it. What can I do | My dilemma is that I was admitted to the US under my B2 visa on October 27 2017, my passport was stamped with a end of stay of April 26, 2018. (see first picture). I then went to Iceland for 10 days and when I re-entered my passport was stamped again, but this time it was stamped with 'WT' not 'B2'. The departure date on this stamp was April 6, 2018 (he only gave me 90 days as he admitted me under the VWP and not my B2 visa). (see second picture) My issue now is that my ESTA will expire at the start of March but I plan to stay in the US until mid April. Am I allowed to stay? Do I need to extend my ESTA or is my B2 visa enough? Can I depart on April 26th like my first stamp says, or do I have to depart before April 6th? I hope this makes sense. Please help. Thank you. |
I have a PHP function that gets passed a date in the format MM/DD/YYYY I need to then convert this so that it can be added to a MySQL field that is of type date How would I go about doing this in PHP? | I have a datetime column in MySQL. How can I convert it to the display as mm/dd/yy H:M (AM/PM) using PHP? |
My Delphi Firemonkey MacOS app makes documents with a .4MD extension. How can I get my app to launch when the user double clicks on Finder documents with a .4MD extension? The seemingly duplicate question on Stackoverflow has an answer with a dead link to Apple's documentation. This article has answers for Delphi XE2: | I would like to associate the last installed version of my Mac OS X application with a certain type of file. A little experimentation shows that the info.plist file seems to be read and interpreted by the operating system when launching the application, not when dragging the application bundle to the disk. does not say much on that topic. Is there any way, using a simple .dmg image as installation medium, to make sure the system associates that particular file type with my newly installed app without having to launch it first? I should clarify that I want this to be done automatically during the installation (I don't want my users to have to do it themselves). |
It seems like the legendary/set drop rates have gone crazy since: The auction houses closed and The Reaper of Souls update. seem way out of date now. Does anyone have some solid numbers on how they have changed? | Just wondering what the drop rates were for Set / Legendary items, or is it totally random? I imagine they would increase for later acts in Inferno. My monk is comfortable in Act 3 in Inferno, but I've only found one set item, so MF will increase chances for them? |
I tried to make this GUI program which take input from the user by text field and should return it with uppercase convertion: import javax.swing.*; import java.awt.*; import java.awt.event.*; public class gui { JTextField textField; JFrame frame; JButton button; public static void main(String args[]) { gui tr = new gui(); tr.go(); } public void go() { JFrame frame = new JFrame(); JTextField textField = new JTextField("Type here); JButton button = new JButton("Send"); button.addActionListener(new buttonListener()); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.getContentPane().add(BorderLayout.CENTER, textField); frame.getContentPane().add(BorderLayout.SOUTH, button); frame.setSize(300, 300); frame.setVisible(true); } class buttonListener implements ActionListener { public void actionPerformed(ActionEvent event) { String txt; txt = textField.getText(); txt = txt.toUpperCase(); textField.setText(txt); } } } The file respond by null pointer exception. Ive tried to add exception handler, and to change the program based on instances Ive seen online. please explain to me my mistake. Thank you. | What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them? What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely? |
I am new to blender scripting. so, If I have two scenes open, one being the master scene with VSE only, and other scene with animation. Is there a way to link their play-heads so that if I move current frame on VSE, it moves on animation scene as well ? This important for in-context changes during animation, when multiple scenes are composited. I have been trying to replicate functionality of After Effects in Blender. Or is there a better way to do this? | Is it possible to add driver to Scene.current_frame so that one scene's current frame can drive other scene's? If not is there a way to link them continuously? Thanks. |
Here I get a querystring depending upon the value from the command shell_exec(). I am receiving a value the querystring but shell_exec() is not working. I am using a webcam connected to Raspberry pi 3 so the command in shell_exec() is to turn the webcam ON an OFF. $output=shell_exec('sudo /etc/init.d/motion start') code: <?php $status=$_GET['status']; if($status == 'on') { $output=shell_exec('sudo /etc/init.d/motion start'); } if($status == 'off') { $output=shell_exec('sudo /etc/init.d/motion start'); } How do I solve the execution issue? | I need to run something as sudo without a password, so I used visudo and added this to my sudoers file: MYUSERNAME ALL = NOPASSWD: /path/to/my/program Then I tried it out: $ sudo /path/to/my/program [sudo] password for MYUSERNAME: Why does it ask for a password? How can I run/use commands as root with a non-root user, without asking for a password? |
My ESTA visa is valid and my passport has not expired but my travel location is different from the first time. Should I update the travel information? | My ESTA is valid until Jan 2016. I am holding an Australian passport valid until 2017. I already made one trip to USA in May 2014. I will travel from Australia to USA in Sep 2015. I have updated the new address where I will stay during the second visit on the web site of US Custom Border Protection. However I am still concerned about the flight details (airlines, flight number etc...) which I could not update. Why not, or how do I, or need I not? |
I started doing LaTeX less than one week ago, so I am completely fresh to the game. To be quick: I am running Windows 8 (probably not relevant), my LaTeX sits on MikTeX 2.9 but I am using Winedt 9 as editor. I want to learn how to make a bibliography for my upcoming thesis. I am using the biblatex package, and I have also loaded the biber package. In the preamble, I use the commands \usepackage[backend=biber]{biblatex} and \addbibresource{biblatex-examples.bib}, which is the "default" bibliography that came with the biblatex package (located in a directory under MikteX 2.9/bibtex/etx.) In the document, I use the command \cite{aristotle1968} and at before I end the document, I use \printbibliography. I can LaTeX this with some warnings, but I doesn't BibTeX. It gives me the following error messages: I found no \citation commands---while reading file test.aux I found no \bibdata command---while reading file test.aux I found no \bibstyle command---while reading file test.aux (There were 3 error messages) What is wrong? I saw a guy who had the exact same problem here: But the solution that worked for him, that is specifying the [backend=biber] in the preamble, does not work for me. Please, help... I have already googled this for three full days and read tons of suggestions... | Running the minimal example \documentclass{article} \usepackage{filecontents} \begin{filecontents*}{\jobname.bib} @ARTICLE{example, author = {Other, Anthony Norman}, title = {Some things I did}, year = {2014}, journal = {J.~Irrep. Res.}, volume = {1}, number = {1}, pages = {1-10} } \end{filecontents*} \usepackage[backend=biber]{biblatex} \addbibresource{\jobname.bib} \begin{document} Hello\cite{example}. \printbibliography \end{document} I get the warning There were undefined references. I have read and know that I need to run: LaTeX Biber LaTeX However, my editor is only set up to run BibTeX. How do I go about setting up my editor/IDE to be able to run Biber, and how do I run the LaTeX/Biber/LaTeX cycle? Answers (sorted alphabetically by editor name) Answer guidelines Each answer should be for one editor. If the editor is cross-platform, if possible give a single answer with notes covering the minor platform variations. Please edit the question to include new answers in the 'link list' Each answer should be 'stand alone', i.e. don't say 'It's almost the same as editor Y but ...' for the editor part Instructions for 'build tools' such as arara or latexmk are welcome but should explain how to set up the editor in question as not all editors allow simple addition of arbitrary tools |
Let $D = \{z\in\mathbb C \vert\vert {z}\vert \lt 1\}$ be the open unit disc in the complex plane, and let $f(z)$ be the following power series of the complex variable $z$: $$f(z)=z+z^2+z^4+\cdots+z^{2^n}+\cdots.$$ By considering the limit $\lim_{x\to 1^{-}} f(x) $ as $0\lt x \lt 1 $ approaches $1$ from the left. How to show that there does not ecist a holomorphic function $g(z)$ defined on a neighborhood $U$ of $z=1$ such that $f(z)=g(z)$ for all $z\in U\cap D$ And how to deal with the limit $\lim_{x\to 1^{-}} f(x) $ as $0\lt x \lt 1 $ | Another Qual question here, For the function $$\sum_{n=0}^\infty z^{2^n}$$, Prove the following: i) $f$ converges to a function analytic in the open unit disk $D$, ii) $f(z) =z+f(z^2)$ and iii) $f(z)$ can not be analytically continued past any point on the unit circle. I can even see (ii) very easily, but I can not see how can I prove rigorously (i) and (iii). Help please. |
I'm looking for a movie that I saw as a child in the 80s. It was a post-apocalyptic world with a group of survivors. They were in a deserted area. Once they entered a tunnel where the floor was covered in water. And here water amazons / sirens appeared that tried to drag them down. Could you help me identify this movie? Edit: I think it was an American movie. The group entered the tunnel in a Mad Max-like car. If I remember correctly, there was an African-American guy also in the group. The set was deserted / rocky. | I am trying to identify a sci-fi movie from the 80's or 90's, with the following parameters: Setting: Scenes of a red desert planet Culture: Either people roam fairly solo and try to acquire resources to survive, or you live in a weird society where if a stranger is captured he needs to play in a game of fight to the death. Mobility: One foil character has a giant battle-bot-looking tank as his form of transportation through the desert. Protagonist has a car that has a plastic half bubble on top to look out from. Robot: The protagonist runs around in the beginning of the film with a female robot/android whose face is melted off after it has acid touch its face.(This scene happens next to the protagonist's rover) Love interest: Somehow protagonist comes across female protagonist in desert. She smells really bad and is hungry. They sleep outside, and he tells her to sleep away from him. He uses a thermal blanket(the first I ever saw in my life). She wakes up next to him, smelling horrible. He bathes her in some water hole they find(as if water were not scarce and they could just waste water.) Pupa monsters: Scene where they are in a building and they are trying to get out. They come across a room that is white, in which multiple giant, white, snot, pupa are hanging securely from the ceiling. Through curiosity, they disturb them, and now they have to get out of that room fast. Boss Antagonist: Pervert bionic man, that is actually attached to a giant robotic arm, as only form of movement. He is in black and has a pale bald head as his most human looking part. |
In my LaTeX file, the name of the image appeared. May I know how can I remove it? Thank you very much. My code is as follows: \documentclass[12pt,a4paper]{report} %%%%%%%% \usepackage{geometry} \usepackage{graphicx} %%%%%%%%%%% %%%%%%%%%%%% \begin{document} %%% \begin{figure}[h] \includegraphics{Albert Einstein.jpg} \caption{Relationship between graphs} \label{fig1} \end{figure} \end{document} | I am writing a LaTeX document with the apacite and graphicx package. The issue is when I include an image either using figure with an enclosed \includegraphics or \includegraphics by itself it shows the image with the file name to the side. For example: -------------- | | | BOX 1 | --------------- Error1.jpg I do not want it to write Error1.jpg. Would show the image but it seems I do not have enough rep. This is an example tex file to show the error (with Windows XP, using Miktex 2.8). \documentclass[man]{apa} \usepackage{apacite} \usepackage{graphicx} \usepackage[utf8]{inputenc} \usepackage[english]{babel} \begin{document} \includegraphics{Example Error1.jpg} \begin{figure}[htb] \includegraphics{Example Error1.jpg} \caption{This is the caption of the figure.} \label{fig:fig2} \end{figure} \end{document} |
Several years ago (4-5?), I read a story online that I believe was still being actively being published in a serial format. The principle idea, as I recall, was that an artificial intelligence determined that it could essentially prevent people from dying altogether by suffusing everything with nanomachines (or something to that effect). The end result was that, years after the fact, a group of people made a sport of trying to kill themselves in increasingly inventive ways, with an ultimate goal of finding a loophole that allows them to die before the AI can prevent it. I think one of the main characters was the oldest woman on Earth prior to everyone becoming immortal, but that may be a different story. I can't recall what the name of it was, and every attempt to google anything with 'AI' in the search just gives a bunch of current news articles. Thanks for the help! | I think I read this online in the last ten years, so after 2005 or so. In the story, everyone is online, I think 24/7. People are jaded and always looking for new experiences. The protagonist (or at least narrator) is a woman, I want to say in her 30s (or at least appears as that age), who is considered to be an expert in the area of torture ceremonies. I want to say that her appearance is of her being scarred and twisted by her experiences, although I don't know if that had to do with her meatspace body, or was simply how she portrayed herself. The only other bit of plot that sticks out in my head was that early in the story, someone (it was a male, and she was thinking of him as being incredibly young) challenges her with a scenario to prove himself, and she was idly commenting how he went for horrific disfiguring torture too early, and tried to compensate by going directly to rape, but that she found his efforts banal. |
So i used the blender tutorial on youtube for creating and animating abstract waves. from blend master. and although those were helpfull, it didn't show me how to animate them actually moving around, like what im trying to do. I assume maybe the partical system is used for this? but im not sure. is there a tutorial on how to do this? or does anyone know how? I haven't done much so far to even make this, as i have no idea where to start. i did make a simple abstract wave, but thats about it. An im using blender render. | I can't figure out how to use Blender to make beam moves, like an energy beam. Any tutorials or advice? From the Title: Solar beam Hyper beam |
From what I remember their was a war between two different groups of people. The winners put the losers in a labyrinth that was constantly trying to kill them (although I think that was a mistake). One of the labyrinth people escapes and by orders goes to each individual world to reestablish a connection network(?). One the first one he comes across a crazy old man who fails a lot, who turns out to be one of the peoples who entrapped the labyrinth people. One world is nothing but forests that has elves and humans, another is and underground world where the people there bring back the dead, and another is nothing but oceans where their is a race of ultimate evil dragon/snake/eel things. What is the name of this series? | I'm trying to identify fantasy book series I encountered some time ago. Here are things I remember: it was a fantasy setting but with some s-f elements; with many worlds and possibility to travel between them; resembling setting a little, the two main races were non-human and probably hostile to each other, a labyrinth (?), which somehow played an important role in the plot, a protagonist was some kind of emissary and was sent on a mission to another worlds time period: 80s - 90s Does anyone know what it is the name of the series? |
I was wondering what cocoa framework (Swift) to use to pull up a list of contacts for a person (if they allow access) and then if they click on one of them, to open up messages to send a message to that friend with a link to the app. I know Apple provides the contacts framework, but how to send the message itself? | Does anybody know if it's possible, and how, to programmatically send a SMS from the iPhone, with the official SDK / Cocoa Touch? |
Lat $x < y < z$. Suppose $f : (x, z) \rightarrow \mathbb{R}$ is continuous and differentiable at every point of $(x, z)$ \ ${y}$, and that $f'$ has a limit at $y$. Prove that $f$ is differentiable at $y$ and that $f'(y) = \lim_{x \to y} f'(x)$. How will we go about showing differentiability and the limit in this case? Firstly, I'm unsure what is meant by the fact that "$f'$ has a limit at $y$" and how is that relevant? Moreover, am I allow to use the mean-value theorem or does that require differentiability at y? | Let $f$ be a real-valued function continuous on $[a,b]$ and differentiable on $(a,b)$. Suppose that $\lim_{x\rightarrow a}f'(x)$ exists. Then, prove that $f$ is differentiable at $a$ and $f'(a)=\lim_{x\rightarrow a}f'(x)$. It seems like an easy example, but a little bit tricky. I'm not sure which theorems should be used in here. ============================================================== Using @David Mitra's advice and @Pete L. Clark's notes I tried to solve this proof. I want to know my proof is correct or not. By MVT, for $h>0$ and $c_h \in (a,a+h)$ $$\frac{f(a+h)-f(a)}{h}=f'(c_h)$$ and $\lim_{h \rightarrow 0^+}c_h=a$. Then $$\lim_{h \rightarrow 0^+}\frac{f(a+h)-f(a)}{h}=\lim_{h \rightarrow 0^+}f'(c_h)=\lim_{h \rightarrow 0^+}f'(a)$$ But that's enough? I think I should show something more, but don't know what it is. |
When I compile a tex document, the compilation process usually leaves some temporary files, like .aux and .log. I have got a small document that can be compiled in just one single run - can I tell the compiler to remove all the remnant temporary files? | If I create just a basic hello.tex file an compile it using pdflatex hello.tex The pdflatex program is creating a plethora of file which is a little annoying. Currently it writes all those files about which I really don't care: hello.aux, hello.log, hello.nav, hello.out, hello.snm, hello.toc Is there a way to tell pdflatex to only write hello.pdf if the build is successful ? If not, can I specify the output directory of those files ? Maybe I could just write them in /tmp. |
How do you unfavorite a question on stackoverflow. It seems as though once you favorite a question, then it either has the 1 in the start or the 2 in the star but not back to its original state, which is nothing in the start; or favorited. Thanks! | What does bookmarking a question mean? How do you bookmark a question? Do users get updates on their bookmarked questions? Are my bookmarks publicly visible? How do you see your own bookmarks? How do you see other users' bookmarks? How do you see which users have bookmarked a particular question? What impact does the bookmark system have on the voting system? Can I "un-bookmark" a question? Can I search within my bookmarks? |
Does anyone know of a near-comprehensive list of grammar rules? (Specifically those which a poor writer of English might violate.) The most amusing candidate I've found was but that doesn't count ;) | Before marking this post duplicate or voting to get it closed (the reason for which I simply don't get just because it is a grammar forum after all! If I am seeking recommendation for a book that means I will be coming back someday to the same site for my doubts also provided I get a not so harsh reply!), please read this and help this MBA aspirant. A little about myself and my research so far. I am a very critical reader of English Grammar and the kind of person who aims at perfection. Currently, I am keen on taking on English grammar again after a certain gap. Well, I am aiming for MBA, so preparing for entrance exams for the same. I bought the religiously followed Wren and Martin and started studying it chapter by chapter. I was surprised when I read the pronouns chapter. I studied all the rules given and then started practising but it came as surprise when I found when many of the attempted questions were wrong. The reason simply being the rules for those specific sentences were not given. For example: We scored as many goals as they/them? According to me, the answer should be they, but it's them according to the solution manual. Worse still, the solution manual offers no explanation for this. So after a chat with my teachers I was suggested to follow the blogs of grammarians and look for any rules for the sentences that have contradictory answers! I did so and was clarified by post of pronouns, Rule 5. Then I saw a book by the same author. I was momentarily happy. It was Momentarily because the reviews on Amazon were too bad about this book. After reading a couple of forums about the book I found a common statement saying that no grammar book is exhaustive. So, it's okay for me to have more than one. And my simple question is what will be a good and almost exhaustive (if not fully exhaustive) book of English grammar to help get through the subtle usages of English in my management entrances which is crisp and to the point and yet covers all important rules and syntax, and most importantly having practice tests at the end with solutions and explanations? |
I've been stuck on this question for a good while now, and I think I need some pointers. $(1+x)^n = nC_0 + nC_1x + nC_2x^2 ... + nC_{n-1}x^{n-1} + nCnx^n$ where n greater than or equal to 1 I'm at the point where I replace n with k+1 and solve, but no matter what I do I cannot get the sides of the equation to look the same. | I'm trying to prove binomial theorem by induction, but I'm a little stuck. I would look at online resources as this problem has been done many times, but the version I am trying to prove the binomial theorem in a different form. $$(1 + x)^n = \sum_{k = 0}^{n} \binom{n}{k} x^k$$ I'm mostly confused as to how I can make the left side be equivalent to a summation, any help is appreciated. Try to hint me along! |
I made an unallocated partition in windows, then I want to give more space to my ubuntu (Which has about 19gig right now). So, I have the following in my GParted app: Then when I right click on partition /dev/sda6 and click on resize/move , there is no space left to add: Any idea? | Previously, I have installed Windows 7 on my 320 GB laptop with three partitions 173, 84 and 63 GB each. The 63 GB partition was where the Windows was installed. The rest were for file containers. Now I changed my OS to Ubuntu 12.04 LTS. I installed Ubuntu by replacing the entire Windows 7 on the 63 GB partition. The rest of the partitions remain as an NTFS Windows partition and I can still access them both (the 173 and 84 GB partitions). Now I want to change the two partitions of Windows into an Ubuntu format partitions plus most importantly, I want to extend the 63 GB partition to more than a 100 GB because at the moment I am running out of disk space. Whenever I try to install any application, especially using wine, it always complains for a shortage of disk space. How do I do the extending activity before I entirely format my laptop again and lose all the important files on my partitions? |
Consider the following example: CREATE TEMPORARY TABLE testing ( names TEXT[] ); INSERT INTO testing VALUES ('{toplevel1}'), ('{toplevel1.sub1, toplevel2.sub2}'), ('{toplevel1.sub1.sub2, toplevel2.sub2}'), ('{toplevel1.sub1.sub3, toplevel2.sub2}'), ('{toplevel1.sub1.sub3.sub3, toplevel2.sub2}'), ('{toplevel2.sub1}') ; SELECT * FROM testing WHERE 'toplevel1.%' ILIKE ANY(names); I want to write a select where "any" element of an array matches a pattern. But I can't figure out a way to do it. In the example I've given, using the ILIKE operator can't work because it checks if the RHS matches the LHS. For this case I would need a similar operator but which checks if the LHS matches the RHS. update: I'm currently fiddling around with something like this without much success: SELECT * FROM testing WHERE names ILIKE ANY (ARRAY(SELECT unnest(names) || '%')); | I'm trying to match a string pattern to any string in an array: SELECT 'abc' LIKE ANY('{"abc","def"}') -- TRUE -- BUT SELECT 'ab%' LIKE ANY('{"abc","def"}') -- FALSE, I expect TRUE What is wrong with the second query? |
I opened xdiganose and it told me to go to in order to download and install the wireless driver. I followed the instructions for Ubuntu and it aborted the installation saying something about an unsupported device (I should've saved the output, I'm using a late 2011 13" Macbook Pro.) Now when I try sudo apt-get install firmware-b43-installer I get this: Reading package lists... Done Building dependency tree Reading state information... Done firmware-b43-installer is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 338 not upgraded. What do I do? | I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible. What are the steps to install Broadcom wireless drivers for a BCM43xx card? I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc. lspci -vnn | grep Network showed: Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b] iwconfig showed: lo no wireless extensions. eth0 no wireless extensions. NOTE: Answer below is updated every time new information is added and confirmed working. |
Here is an inequality (let's call it - "$A(n)$") that has to be proved: $$ (n+1)^n < n^{n+1} \text{ for } n\ge3. $$ I'll skip the first two steps of induction and move right to the induction step (step #3) in order not to waste time. Assume that $n = k+1$. I get: $$ (k+2)^{k+1} < (k+1)^{k+2} $$ From here: $$ (k+2)^k(k+2) < (k+1)^k(k+1)^2 $$ and that is where i'm stuck. I've found, that the inequality $A(n)$ (by dividing it by $n^n$) can be expressed as: $$ (1+1/n)^n < n. $$ Here again I substitute $n = k+1$ and get: $$ (1+1/(k+1))^{k+1} < k+1. $$ Stuck here as well... On the forum I've found ways to prove the inequality by Binomial theorem and other approaches, but how to prove this with math induction ? It would be great if answers included comments on every step, that is done to find the solution... | I'm struggling around my homework. I hope someone will point me the right direction for solving following examples: Prove that $n^{n+1} > (n + 1)^n$ for $n > 2$; Prove that $(1 + x)^n \ge 1 + nx$; $x \in\Bbb R$; $n \in\Bbb N$; Prove that $(2n)! < 2^{2n}(n!)^2$; $n \ge 1$; Prove that $2^n > n$: Thank you a lot. |
I need to have the date. The format of the time should be 2017-01-18T07:34:35Z I have tried this but it does not work: import datetime i = datetime.datetime.now() date = %i.year "-" %i.month "-" %i.day "T" %i.hour ":" %i.minute ":" %i.second "Z" | What is the module/method used to get the current time? |
I just started a roleplaying site that hosts my play-by-post game of Prometheus and want to attract players. The sites I've found that allow game advertisements want to be paid, they don't even allow me to put a little link anywhere without a constant fee. I want to get a bunch of players together to play a fantasy/sci-fi game and I have nowhere to advertise it... How can I promote my game online without being charged for it? | I'd really like to learn how to play pen-and-paper RPGs. I know that it takes a few players to actually sit down and play, but I'm not at all sure where to find more gamers. How do I find existing groups to join? Or, are there any resources online that may help me find existing RPG groups or players? |
I'm sure this has been asked many times before, but anything would be helpful. I'm looking to upgrade from a standard point-and-shoot to a higher quality camera before a safari vacation. I was leaning more towards dslr than mirorless, but am overwhelmed by determining mm v. zoom factor. I'm mildly intimidated by breaking the think while trying to change lenses, but I want to make sure I will be able to get good quality photos of wildlife that might be further in the distance, as well as something that will be able to shoot quickly. I was leaning toward the Nikon D3300. Any suggestions? | I am going on a Safari and am ready to upgrade from a P&S to either a DSLR or a mirrorless. I love taking pictures and travel a lot (for fun) so expect to use this camera in multiple settings. I have a few months to learn how to use the camera before my trip. My top DSLR choice is the Nikon D5100 and for compact system and thinking Sony NEX 5 or NEX 7. I am also open to other models. My top priorities are (1) picture quality (for safari and general travels) and (2) weight / size (less of a factor but definitely a concern). |
Subsets and Splits