I'm trying to create a roughness file (derived from topography) in the ASCII format for a European raster dataset. This dataset is from the EEA. I've already made an ASCII grid file of the raster data as a whole (euroascii.asc) using the command: gdal_translate -of AAIGrid ~/elevation3x3/elevation3x3.tif euroascii.asc The roughness file has to be continuous (AKA 0.1, 0.2, 0.3, and so on), and has to account for every value that is already in the euroascii.asc file. There is a command that is meant to do just this (I think), but I've tried it in the QGIS Python Console and it doesn't work. This is what I've done in the QGIS Python Console, taken direct from the manual: import processing # this gets no errors or anything out And also: from qgis import processing for alg in QgsApplication.processingRegistry().algorithms():         print(alg.id(), &quot;-&gt;&quot;, alg.displayName()  To test whether this has any effect, I tried the code from  processing.runalg('gdalogr:roughness', EEAdata, 1, compute_edges=F, roughnessFile) Which gets the error: AttributeError: module 'qgis.processing' has no attribute 'runalg' I'm only using QGIS Hannover, with no access to ArcGIS or any other commercial software. I'm also running this on Ubuntu 18.04.
I try to create a common extent for rasters in QGIS 2.99. Here is my script:  import processing  processing.runalg("script:unifyextentandresolution",                   "/qgis_data/rasters/Image2.tif;                   /qgis_data/rasters/Image1.tif",                  -9999,"/qgis_data/rasters",True)   However, processing.runalg is being used for QGIS 2.99. I need it for QGIS 2.99
In my Computer science class I was given a problem where I have to simulate a bouncing ball using "real physics". I have been trying to find a equation that will simulate the height of the bounce given a gravity and an arbitrary mass. And I will need to calculate the next bounce and it's height. A lot of the equations I've found require a time. But I don't really care about a time, all I want is to get the next height after the previous bounce until it finally hits height of 0 or close to it. I haven't taken a physics class since high school( 5 years ago) and that was basic physics. Moderators accepting answers on user's behalf after a certain time period I think it would be cool if a question would eventually open up to moderators to accept answers on the user's behalf, once a time period has passed. The asking user would get the rep score for the accept.  I know I've seen questions successfully answered with lots of upvotes and no accepted answer that sit there for months unaccepted. This would give superusers a little more functionality and would tie up a lot of loose ends.  What do you think? I moved a database from SQL Server 2005 to SQL Server 2012. Is there any way of restoring all the logins on the new server? Just a curiosity. I just saw a video where pi was being calculated by the series  $$1-(1/3)+(1/5)-(1/7)+...$$  My question is how can $\pi$ be irrational if we can calculate it using rational numbers? How do I beat Uprising on Legendary difficulty? The achievement "Distinguished Service" requires that you beat Uprising on the regular gamemode on Legendary difficulty.  This means we can't pick our usual huge DPS heroes like Bastion and Orisa, and are stuck with Torbjorn, Reinhardt, Mercy, and Tracer.  The phases are as follows:   Hack all 3 terminals Defend the Payload until it's ready Escort the Payload until the gate Destroy all 4 Orisas.   So I ask this after having failed Uprising on Legendary dozens of times.   How do I beat Uprising on all 4 phases?   Specifically asking for the latter 3 phases.    Defending the payload is hard when it gets to the Bastions that drop in because Reinhardt's shield gets melted very quickly and Torbjorn has little to no DPS.  Tracer must be relied on but it seems there is no way to stop the perfect aim of Bastion as strafing around does nothing.  If and when we actually do manage to defend it, we're stuck on escorting, which is even harder thanks to the tank mode Bastions.  And finally, even if we do make it to the final fight, which has only happened once, the fight is so tough that even if we slowly inch ourselves closer to the end we run out of time.  The previous question I asked was different because Uprising (All Heroes) allows you to pick any 4 heroes to form your squad, but the original gamemode will not let you pick. Also, the achievement requires you to play the original mode -- Uprising (All Heroes) on Legendary does not reward players with the achievement. Closed form for the sequence defined by $a_0=1$ and $a_{n+1} = a_n + a_n^{-1}$ Today, we had a math class, where we had to show, that $a_{100} &gt; 14$ for  $$a_0 = 1;\qquad a_{n+1} = a_n + a_n^{-1}$$  Apart from this task, I asked myself: Is there a closed form for this sequence? Since I didn't find an answer by myself, can somebody tell me, whether such a closed form exists, and if yes what it is? Why do we need to use int main and not void main in C++? I'm having a heck of a time trying to disable the option  "Check for updates Automatically"  I ran composer to see what plist was being modified and it looks like ~/Library/Preferences/com.oracle.javadeployment.plist  &lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"    "http://www.apple.com/DTDs/PropertyList-1.0.dtd"&gt; &lt;plist version="1.0"&gt; &lt;dict&gt;     &lt;key&gt;/com/oracle/javadeployment/&lt;/key&gt;     &lt;dict&gt;         &lt;key&gt;deployment.macosx.check.update&lt;/key&gt;         &lt;string&gt;false&lt;/string&gt; &lt;/dict&gt; &lt;/dict&gt; &lt;/plist&gt;   So I experimented with changing that value to true or false and it would not effect the checkbox under the Java Control Panel > Update > Check for Updates Automatically  Your assistance would be much appreciated.  Initially I was looking @ /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin Why Are Ethernet/RJ45 Sockets Magnetically Coupled? As the title says really, why do ethernet sockets need to be mag-coupled? I have a basic understanding of electronics, but mostly, I can't figure out the right search terms to google this properly. Oneboxing a Stack Exchange post using HTTPS does not work When you post a link from Stack Exchange into the chatbox using HTTPS, the link does not onebox. However, if you change the link to HTTP, it works. See the screenshot below:    HTTPS URLs should onebox, too. I used the jQuery Form plugin for asynchronous form submission. For forms that contain files, it copies the form to a hidden iframe, submits it, and copies back the iframe's contents. The problem is that I can't figure out how to find what HTTP status code was returned by the server. For example, if the server returns 404, the data from the iframe will be copied as normal and treated as a regular response.  I've tried poking around in the iframe objects looking for some sort of status_code attribute, but haven't been able to find anything like that.    The $.ajax() function can't be used, because it does not support uploading files. The only way to asynchronously upload files that I know of is using the hidden iframe method. How to know if Mac OS X machine is being remotely viewed? Low Voltage AC Smoothing Capacitor Calculation I have a 9V AC source which will have a max load of 100mA.  I'm trying to figure the value of a smoothing capacitor with less than a 10% ripple.  I don't have a scope or else I'd just try a bunch out.  I'm just a hobbyist, but I'm trying to understand this.  Since I'm not sure if I'm doing this right, I'll just step through what I've done so far.  First I found this formula: $$V_{ripple}={V_p \over R_LC} \times \Delta T$$  I'm using 60Hz 9VAC that is full wave rectified and I want a 10% ripple so:  $$(9V \times .1)={9V \over R_LC} \times {1 \over 60Hz}$$  I'm calculating my resistive load with Ohm's law. $$R = {9V \over .1A} \quad R = 90 \Omega$$  So plugging that in I get: $$.9V={9V \over 90\Omega \; C} \times {1 \over 60Hz}$$  If I solve for C (admittedly using wolfram alpha), I get: $$C={1\over 540}F \quad C=1851 \mu f$$  1850µf seems pretty high to me...  And if I lower the ripple percent it get crazy high.  Is this the right way to find this?  Or did I screw up somewhere?  Also, my circuit has the capacitor between the full bridge rectifier's positive and negative outputs.  I've only seen this type of smoothing circuit, but maybe my circuit needs to change? How does Windows know whether it has internet access or if a Wi-Fi connection requires in-browser authentication? In Windows 7, the notification area networking icon will show an error indicator if there is no internet access , and the error icon goes away once there is a successful connection to the internet . Sometimes, if the WiFi connection requires an in-browser authentication step, like on many guest networks in hotels or universities, then the following pop-up bubble appears, saying as much:    How does Windows know whether or not it has a successful internet connection? Presumably it is checking some online Microsoft service to see whether it has a successful connection, gets redirected to some other page, or doesn't get any response at all, but I haven't seen anywhere that this process or the services used are documented. Can anybody explain how this works? I would prefer answers that refer to facts, rather than just guessing, but if you have a really good guess, then go for it.     This question was a .   Read the May 16th, 2011  for more details or  Question of the Week. How to prove $\cos\left(\pi\over7\right)-\cos\left({2\pi}\over7\right)+\cos\left({3\pi}\over7\right)=\cos\left({\pi}\over3 \right)$ Is there an easy way to prove the identity?     $$\cos \left ( \frac{\pi}{7} \right ) - \cos \left ( \frac{2\pi}{7} \right ) + \cos \left ( \frac{3\pi}{7} \right ) = \cos \left (\frac{\pi}{3} \right )$$   While solving one , I am stuck, which looks obvious but without any feasible way to approach.   Few observations, not sure if it would help $$ \begin{align} \dfrac{\dfrac{\pi}{7}+\dfrac{3\pi}{7}}{2} &amp;= \dfrac{2\pi}{7}\\\\ \dfrac{\pi}{7} + \dfrac{3\pi}{7} + \dfrac{2\pi}{7} &amp;= \pi - \dfrac{\pi}{7} \end{align} $$ "How" vs. "that" in "You know how we have pizza on Thursdays, right?" From time to time I hear sentences like this:      You know how we have pizza on Thursdays, right?   Here, how doesn't mean exactly how those guys eat pizza, it is something like "that" in this context.   So what is the difference between using how, that or just skipping the conjunction? How can I SSH with a remote server so I can browse files and edit them? I have a username and password to use. I want the QED symbol to be 1 line lower at the end of proof Just as my title says, I would prefer to have my qed symbol to be 1 line lower than the last line of my proof. By default its on the same line and aligned to the right.   How can I achieve this?  EDIT: See below code for an example:  \documentclass[11pt,a4paper]{article} \usepackage[margin=3cm]{geometry} \usepackage[english]{babel} \usepackage{amsmath, amsthm} \begin{document}  \begin{proof}     Hello there good chap! I'll put in another line here just to be sure its clear what I mean. \end{proof}    \end{document} Why are SO participants so unfriendly? Prevent gedit from creating files with the '~' (tilde) suffix I have observed that in gedit if I edit a file, another file is created in the same directory (the one with the same filename and a tilde '~' suffix). The extra file remains even if I close gedit.  I understand the need for a temp file (eg. in case of a crash), but vim for example deletes the extra file it creates, when I close it.  Is there a way to do the same with gedit? Some configuration perhaps?