body1
stringlengths
20
4.1k
body2
stringlengths
23
4.09k
Updated to show more current screenshot and clarified the question (Which tools? What are the steps?) I'm learning QGIS (1.8 "Lisboa" for Mac). On the QGIS Layer labeling Settings window there is a section called "Data defined settings": I believe the user's guide briefly describes its purpose: The advanced entries inside the Label tab allow you control the appearance of the labels using attributes stored in the layer. The entries beginning with Data defined allow you to set all the parameters for the labels using fields in the layer. But there are no instructions for using the Data defined entries and the Help file doesn't mention them at all. For example, I want the label color to be white for the darkest polygon colors in a choropleth map. Will the Data defined settings help me do this in QGIS? If so, how? (Cartographica, for example, allows a user to easily set individual label colors for each category in a choropleth scheme. I was expecting a similar function in QGIS.) One commenter suggested using the "Expression based label" tool. I don't know how to access the tool and there don't appear to be instructions in the user's guide. It isn't clear to me whether "Expression based labeling" supersedes "Data defined settings" or is meant to be used in conjunction with them. I'm in need of clear, step-by-step instructions.
I'm using QGIS 1.8. I'd like to customize label features on an existing shapefile using the new label engine and it's "data defined settings" option. I'd like to know what the attribute table field types should be for each of the settings: All 7 font options, all 2 buffer options, and all 6 position options. Should they all be numeric fields, or some text, or both? I want to create these fields in the attribute table correctly so that I can map them to the label field settings. I can't find information on the proper field types anywhere. Thanks for your thoughts.
I have an Acer chromebook c720 can I use this to play hearthstone on it? If so how do i go about that what should i install?
Can .exe and .msi files (Windows software) be installed in Ubuntu?
I have two polygons in PostGIS that have incongruities. One polygon (the yellow one) is legal county boundaries. The other polygon (blue) is essentially neighborhoods. 98% of the lines align perfectly. The other 2% don't align because the boundaries have changes but not been updated on the neighborhoods polygon. My question: Using either PostGIS (preferred) or QGIS, how can I "snap" the neighborhood boundaries to the county boundaries? I've tried: ST_Multi( ST_Intersection(neighborhoods.geom, county.geom) ) END AS geom EDIT: This query "worked" in that it prevented neighborhoods from bleeding into incorrect counties, but it just removes the area that causes the bleed creating blank spaces inbetween boundaries.
I am working with vector polygons that have derived from hand drawn areas from when mapping was carried out with tracing paper over paper maps. Therefore many of the polygons don't exactly line up to the boundaries on the ground. Another dataset of vector lines I have is accurate and so I have been manually snapping nodes of the polygons to the nodes of the lines. But this is a lengthy process. Here is a screenshot... The green line is the accurate dataset. You can see how the polygon boundaries (orange) are roughly correct. Bottom left I have started to edit the nodes, with the snapping options set up, and this works to manually move the nodes of the polygons to snap to the nodes of the line. (Yes, I could have enabled topographical editing to move both the polygon boundaries together, and I do do that). Is there a method for snapping multiple nodes of the polygon to the nodes of the lines, or is there perhaps a better method of doing this? Using Python perhaps? I am looking for something akin to the 'Enable tracing' function (which is great) but for moving polygon boundaries. I am aware that this may in places be a duplicate as there are many similar questions, but I haven't quite found anything that answers my particular situation? In particular I have looked at...
Google webmaster tools is reporting some/many 404 urls that don't exist on my site. The links are things such as domain.com/xyz/ However that doesn't exist, but domain.com/xyz/index.html does exist. The "linked from" pages all show proper links to the "/xyz/index.html". The page without index.html DOES 404, but why is google even trying these urls if they are not linked to? My real question, is there a way to have google stop attempting to load these pages, and ultimately remove these from the crawl errors report. Thanks.
Because of a former error in our ASP.Net application, created by my predecessor and undiscovered for a long time, thousands of wrong URLs where created dynamically. The normal user did not notice it, but Google followed these links and crawled itself through these incorrect URLs, creating more and more wrong links. To make it clearer, consider the url example.com/folder should create the link example.com/folder/subfolder but was creating example.com/subfolder instead. Because of bad url rewriting, this was accepted and by default showed the index page for any unknown url, creating more and more links like this. example.com/subfolder/subfolder/.... The problem is resolved by now, but now I have thousands of 404 errors listed in the Google Webmaster Tools, which got discovered 1 or 2 years ago, and more keep coming up. Unfortunately the links do not follow a common pattern that I could deny for crawling in the robots.txt. Is there anything I can do to stop google from trying out those very old links and remove the already listed 404s from Webmaster Tools?
Medical 3-Spring Aluminium Chart Holder Provides Strong 3-spring closure form medical histories.• As shown in the figure below.
I need to model a simple spiral shape. I imagine the best way to do this is with curves, but I am unsure how to create a perfect spiral shape with curves. What's the best/easiest way to make a spiral tube?
When you like level up does some of that score go in the tracking things? How do you get the field upgrade score and what do they do?
Firstly, how do you gain the score exactly? I know it shows in the bar on the side of the map, but I remember a match where I was lone-wolfing and still got a pretty high score in that bar. I suppose my other squad members were together, but do I also gain for their work? Also, does the score reset when I start a new game? I mean, I play support with the Offensive perk and it took me a long game of conquest to just unlock lvl-3 extra grenade. In the next match, that 'nade is gone. Don't I keep it forever?
How do I turn on autofocus? Using the Nikkor 50mm 1:1.8 lens. I've gone into the menu selection and have fooled around with the AF settings but camera is still not focusing automatically... When I click the info button, the MF button is not highlighted and I'm not sure how to get to it to see if that will do the trick. At a loss! Help!
I know my D40 doesn't have a motor in it to auto-focus lenses. What type of lens has the motor in it? How can I know which lenses will and will not work?
First off, I don't want to use rewrites. I'm trying to redirect any call (HTTP or HTTPS) to myserver to the secured fully qualified domain using https at https://myserver.fullyqualified.com. Here is my config # Redirect all http traffic to https <VirtualHost *:80> # line 545 Redirect / https://myserver.fullyqualified.com/ </VirtualHost> <VirtualHost *:443> # line 549 ServerName myserver.fullyqualified.com SSLEngine on SSLCertificateFile "conf/mycert.crt" SSLCertificateKeyFile "conf/mykey.key" </VirtualHost> <VirtualHost *:443> # line 555 ServerName myserver Redirect / https://myserver.fullyqualified.com/ </VirtualHost> This works fine for HTTP, I can call http://myserver and it redirects to https://myserver.fullyqualified.com just fine. However when I call https://myserver I get an error about the site not being secure, and it doesn't redirect to https://myserver.fullyqualified.com like I expect it to. In Chrome, the error says This server could not prove that it is myserver; its security certificate is from myserver.fullyqualified.com. This may be caused by a misconfiguration or an attacker intercepting your connection. This is the output of httpd -S *:80 MYSERVER.fullyqualified.com (C:/Apache24/conf/httpd.conf:545) *:443 is a NameVirtualHost default server myserver.fullyqualified.com (C:/Apache24/conf/httpd.conf:549) port 443 namevhost myserver.fullyqualified.com (C:/Apache24/conf/httpd.conf:549) port 443 namevhost myserver (C:/Apache24/conf/httpd.conf:555) ServerRoot: "C:/Apache24" Main DocumentRoot: "C:/Apache24/htdocs" Main ErrorLog: "C:/Apache24/logs/error.log" Mutex default: dir="C:/Apache24/logs/" mechanism=default Mutex rewrite-map: using_defaults Mutex ssl-stapling-refresh: using_defaults Mutex ssl-stapling: using_defaults Mutex proxy: using_defaults Mutex ssl-cache: using_defaults PidFile: "C:/Apache24/logs/httpd.pid" Define: DUMP_VHOSTS Define: DUMP_RUN_CFG Define: SRVROOT=c:/Apache24 How can I redirect HTTPS traffic to the full qualified domain name?
We're using setup with an nginx on one machine and (currently) one application server on apache in the back. For multiple domains we got ssl certs, but only for the domain itself. So without subdomain www. Everything works as expected, we do not use the anywhere. But we have customers who are typing this in by hand, resulting in a warning in the browser on the clientside. ..and a new seo guy insisting on working www subdomain WITH ssl. What am i looking for: A creative solution which does not require new certificates for 20+ domains. I already thought about getting certificates from let's encrypt for our www subdomain, then 301 to domain.tld.. but it's still in beta. Any ideas ?
I'm looking for an early 90s TV series in which aliens set up embassies on Earth. They were human-like, with a pale blue skin. Their ships were alive and grown rather than built. The story focused on their ambassador in the US and its relationship with a human (cop?) who discovered little by little they were not the benefactors they appeared to be. Oh, and they used nice smartphones with retractable screens. Well, I can't tell much more about it...
I’m looking for a TV show where an alien race comes to Earth and sets up big purple/pink cylindrical or cone shaped spaceships in various cities around the world. The Aliens are not hostile but actually created peace and eliminated hunger on Earth. I believe the aliens had some human features and were wise and calm the main actor had a phone with a pull out screen I believe the main actor worked for or with the aliens I believe that in the last episode some humans and aliens go into some kind of pods and perhaps leave Earth? one of the space ships was located in a major US city. Maybe Washington DC or another East Coast city Could someone please tell me what TV series this is? I have been searching everywhere and cannot find it. Thanks!
I tested the following code in gcc 4.8.3 and msvc v120. #include <iostream> using std::cout; void bar(int &x) { cout << "bar\n"; int y = x; // Crash here... } void foo(int *x) { cout << "foo\n"; bar(*x); // No crash here... } int main() { foo(0); return 0; } output: $ ./test foo bar Segmentation fault (core dumped) I expected that it would crash upon the *x, however it crashes when the int reference is dereferenced. It was compiled with the following g++ -O0 -std=c++11 -pedantic -o test test.cpp. Does anyone have an explanation for this behaviour? How is the reference initialized without dereferencing the null pointer?
I came across this code: void f(const std::string &s); And then a call: f( *((std::string*)NULL) ); And I was wondering what others think of this construction, it is used to signal that function f() should use some default value (which it computes) instead of some user provided value. I am not sure what to think of it, it looks weird but what do you think of this construction?
I have a new client whose site I will be re-building. I noticed on his site he has a badge from McAfee saying the site is secure. Below is an example: I have seen similar type badges by other companies as well on other sites. My question is this: Do these types of services increase conversion and trust for a site? In other words, these services claim that it will increase the trust for the consumer thus increase sales and interactions on your website. I am looking for studies that provide proof or results than just an opinion as an answer, preferably by a third party who does not offer the service. Edit is essentially the same but the answer there provide opinions vs documented studies (other than the ones the companies provide). I am looking for documented studies as an answer.
There are a number of services that will scan a website for vulnerabilities and allow the display of a trustmark image if the site passes their tests. This allegedly increases the level of trust a potential client feel toward the website and therefore makes them more likely to complete a purchase. McAfee claims it has studies which show significant increases in sales. Should I take their word for it? What sort of increase should I really expect, if any? Are these types of services worth the prices they charge?
my render output has a weird looking shape and color which is different from what I see in layout. the version I am using is 2.92. does anyone know what's wrong with it and how to fix it? this is what i got after hitting F12 button: this is what I see in layout:
Have Blender on about 4 machines rendering animations. Just spotted on one of the machines its rendering something different from the actual scene that I have setup. Top window shows a different set of layers objects to whats actually being rendered in the rendering window below. In my scene contents, layers objects 1-5 are not visible, but these are the ones that look like they are being rendered. The only thing I can assume is that perhaps it might be because I did not save the document before clicking render, but I would not have expected that behaviour (you dont need to save your word document before printing it). Can anyone confirm why this is happening?
Found this in an obfuscated malicious shell script, beginning with: ${!#}${*^} <<<... Could not find any reference to ${!#}, but when echo'd, it outputs -bash. Is this a secret referene to the running shell? Why there is an extra dash then? Thanks!
From the Advanced Bash-Scripting Guide, to get the last command-line argument: Or: lastarg=${!#} This is an indirect reference to the $# variable. Note that lastarg=${!$#} doesn't work.
Is there a particular way on how to handle errors if my FileInputStream cannot find the inputted file name in its directory? I'm just trying to make it so if my program can't find the file that was typed it'd print an error stating "file doesn't exist" EDIT: Left out info. Hoping to let users reinput the file name.
I have a java program which take path as argument. I want to check whether given path is existing or not before doing other validation. Eg: If i give a path D:\Log\Sample which is not not exist, it has to throw filenotfound exception. How can i do that?
From $$\Gamma(x)\Gamma(y)=\int_0^\infty e^{-t}t^{x-1} \left( \int_0^\infty e^{-t} s^{y-1} ds \right) dt,$$ use a change of variable $s=ut$ to show $$\Gamma(x)\Gamma(y)=\Gamma(x+y)\beta(x,y).$$ Let $s=ut$ so $ds = udt + tdu$ and then \begin{align*} \Gamma(x)\Gamma(y) &=\int_0^\infty e^{-t}t^{x-1} \left( \int_0^\infty e^{-s} s^{y-1} ds \right) dt \\ &= \int_0^\infty e^{-t} t^{x-1} \left( \int_0^{\infty} e^{-ut} (ut)^{y-1}(udt+tdu)\right)dt \\ &= \int_0^\infty e^{-t} t^{x-1} \left( \int_0^{\infty} (e^{-ut} u^y t^{y-1})dt+ \int_0^{\infty} (e^{-ut}u^{y-1}t^y)du\right)dt \\ \end{align*} My next thought was to use integration by parts, but that didn't pan out. Any suggestions? Note that Gamma Function for $x>0$ we define: $$\Gamma(x):=\int_0^\infty e^{-t}t^{x-1}dt.$$ And for the Beta Function for $x>0$, $y>0$, we define $$\beta(x,y):=\int_0^1 t^{x-1}(1-t)^{y-1}dt.$$
I'm trying to prove that for $p,q>0$, we have $$\int_0^1t^{p-1}(1-t)^{q-1}\,dt=\frac{\Gamma(p)\Gamma(q)}{\Gamma(p+q)}.$$ The hint given suggests that we express $\Gamma(p)\Gamma(q)$ as a double integral, then do a change of variables, but I've been unable thus far to express it as a double integral. Can anyone get me started or suggest an alternate approach? Note: This wasn't actually given to me as the $\Gamma$ function, just as a function $f$ satisfying $$f(p)=\int_0^\infty e^{-t}t^{p-1}\,dt$$ for all $p>0$, but I recognized that. This is in the context of an advanced calculus practice exam.
I have two line feature class like on the image below How can I split green line at intersect at particularly blue line?
How can I split all the lines in a feature class where they intersect with a second line feature. I have a roads feature and a rail feature. I want the lines in the rail feature to split where ever it crosses a road. I'm looking to do it all at once with an overlay analysis tool. Like the Split Line at Point tool, but using lines as the input. Too many to do it manually.
I am just wondering if there is any talk about adding notifications to the tab (like gmail) on stack overflow. It would come in handy as at the moment comments, notifications etc only appear if the page is reloaded.
I understand a few similar questions have been asked, but this is hopefully completely separate functionality. Say you have Facebook open in Tab 1 of your favorite browser (mine is Chrome). When someone posts on your wall, comments, adds you as a friend (the list goes on), you get a number in the title of the page(tab) saying Facebook(1), indicating some sort of activity. The same thing happens if you're ON the page itself, I presume there is a notification ticker of some sort. I already love the new logo which does show notifications but only when you refresh look at the page. I often find myself at work answering a question here and there and then I forget about it and do some actual work. 4 hours later, I click on my profile and BOOM, you have 8 comments, probably because you forgot to .Dispose() of an object or something :) If my Stack Overflow tab title showed something like (4) What's your favorite C# book? Or, for pinned tabs, a browser will also indicate the title changed: It would attract my attention to go and see who's complaining about my answer, if the OP needs more information or whether someone is just happy with my post. So rather than refreshing Stack Overflow on an hourly basis, could we automate this and make our lives easier? What do you think?
I have the following problem, with nested class(in this case a struct) namespace and return type class Example { struct Node { /* with all the methods it needs */ } Node * func(); } now I want to put the implementation of the func outside the class. So what I did is: Example::Node * Example::func() { return nullptr; } and it worked fine, until I made example template template<typename T> class Example {/* all the same here */} template <typename T> Example<T>::Node * Example<T>::func() { return nullptr; } where I got many errors. Then I tried template <typename T> Example::Node * Example<T>::func() { return nullptr; } Where I get the error: "use of class template requires template argument list" As far as I know Example<T>::func() is correct, because this means that function belongs to that namespace. But I'm not sure about the return type of my function. Any help?
In templates, where and why do I have to put typename and template on dependent names? What exactly are dependent names anyway? I have the following code: template <typename T, typename Tail> // Tail will be a UnionNode too. struct UnionNode : public Tail { // ... template<typename U> struct inUnion { // Q: where to add typename/template here? typedef Tail::inUnion<U> dummy; }; template< > struct inUnion<T> { }; }; template <typename T> // For the last node Tn. struct UnionNode<T, void> { // ... template<typename U> struct inUnion { char fail[ -2 + (sizeof(U)%2) ]; // Cannot be instantiated for any U }; template< > struct inUnion<T> { }; }; The problem I have is in the typedef Tail::inUnion<U> dummy line. I'm fairly certain that inUnion is a dependent name, and VC++ is quite right in choking on it. I also know that I should be able to add template somewhere to tell the compiler that inUnion is a template-id. But where exactly? And should it then assume that inUnion is a class template, i.e. inUnion<U> names a type and not a function?
I can not prove the following statement. Could you please help me? Thanks Prove that for each $a_k>0$ with $\sum_{k=1}^{\infty}a_k< \infty $ there exists a nondecreasing unbounded sequence $(b_k)^\infty_{k=1}$ such that $\sum_{k=1}^{\infty}b_k a_k< \infty $
Given a real positive sequence $\{a_n\}$ such that $\sum_{i=1}^n a_i$ converges. Prove that there exists a real sequence $\{c_n\}$ monotonically increasing to $\infty$ such that $\sum_{i=1}^\infty a_nc_n$ converges. What I have done: I have written $$\sum_{i=1}^{N+1}a_ic_i=c_{N+1}\sum_{i=1}^{N+1}a_i-\sum_{i=1}^N(c_{n+1}-c_n)S_n$$ and then try to prove the convergence by the Cauchy criterion. However my evaluation is still not good enough. I'm really stuck.
I've been working with this query to achieve the results I wanted, which I have. During this time I started using PDO and at first worked by just having one varibale to prepare inside the query. While testing, I ended up using two more variables inside the query but left them out of the prepared statement until I was finished. Now that I have the query completed, I went on and tried preparing the three variables as I did with the first one but an error was displayed when I ran the query: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '':cdrLastTable' ON a.id = b.`source_customer_billing_zone_' at line 2 I noticed the error was coming from one of the three prepared variables I needed for my query, but the thing is that the one that's failing is the only one placed before the WHERE clause. Excluding it from the prepared statement works fine. After reading and looking at exaples I could not find any with a variable before the WHERE clause so my question is: Can you prepare variables before the WHERE clause? If this is not possible, then what would be the point on using PDO for this query? I'm assuming that this issue does not relate to the query or any syntax error since removing the variable from the prepared statement just works, but I could be wrong as well. This is the query with all variables prepared (the one that gives off the error): $stmtOutgoing = $connAccounting->prepare("SELECT a.`zone` AS zone, init_time, a.`detail` AS sku, b.`source_external_subscriber_id`, count(*) AS llamadas, SUM((CEIL(b.`duration`))) AS duracion, SUM((b.`source_customer_cost`)/100) AS total, SUM((b.`source_customer_cost`)/100)/(SUM((CEIL(b.`duration`)))) AS precio FROM `billing`.billing_zones_history a INNER JOIN :cdrLastTable ON a.`id` = b.`source_customer_billing_zone_id` WHERE source_external_subscriber_id = :source_external_subscriber_id AND init_time >= :queryLastTstmp GROUP BY a.`detail` ORDER BY total desc"); $stmtOutgoing->execute(array('source_external_subscriber_id' => $source_external_subscriber_id, 'cdrLastTable' => $cdrLastTable, 'queryLastTstmp' => $queryLastTstmp)); You can see the error message points directly at :cdrLastTable right after the INNER JOIN, and effectively removing it like this: $stmtOutgoing = $connAccounting->prepare("SELECT a.`zone` AS zone, init_time, a.`detail` AS sku, b.`source_external_subscriber_id`, count(*) AS llamadas, SUM((CEIL(b.`duration`))) AS duracion, SUM((b.`source_customer_cost`)/100) AS total, SUM((b.`source_customer_cost`)/100)/(SUM((CEIL(b.`duration`)))) AS precio FROM `billing`.billing_zones_history a INNER JOIN $cdrLastTable ON a.`id` = b.`source_customer_billing_zone_id` WHERE source_external_subscriber_id = :source_external_subscriber_id AND init_time >= :queryLastTstmp GROUP BY a.`detail` ORDER BY total desc"); $stmtOutgoing->execute(array('source_external_subscriber_id' => $source_external_subscriber_id, 'queryLastTstmp' => $queryLastTstmp)); Makes the statement work. For some context: A new table is created each month, hence the need to store the name in a variable unlike the first table which has a 'static' name. The server is running 10.3.23-MariaDB and PHP 7.2.33. I have tried quoting the variable like this: ':cdrLastTable' but did not work. Thanks for the help!
Why can't I pass the table name to a prepared PDO statement? $stmt = $dbh->prepare('SELECT * FROM :table WHERE 1'); if ($stmt->execute(array(':table' => 'users'))) { var_dump($stmt->fetchAll()); } Is there another safe way to insert a table name into a SQL query? With safe, I mean that I don't want to do $sql = "SELECT * FROM $table WHERE 1"
I logged into data-explorer for the first time 9I have viewed others' queries but have not created one myself). When I log in with the StackExchange Open Id provider, I am shown as john.doe13574. This does not happen when I login to a new stackexchange site, my details are recogniozed and fetched from my profile. Is this an expected behaviour? Strangely, my picture is recognized correctly so the system "knows" me (I know the picture is from Gravatar, but the system knows what details to send to Gravatar)
I just tried to login to the Data Explorer and it gave me a jon.doe user. I used the same openid... How can I link this to my other accounts?
$1! + 2! + . . . + n! < (n + 1)!$ This question has left me stumped for quite some time. I am not sure how to approach it. (I am really bad at induction).
Use induction to prove the following: $1! + 2! + .... + n! < (n + 1)!$ Base case: $n = 1$ $1! < 2!$ true Inductive step: Assume that $1! + 2! + .... + k! \le (k + 1)!$ is true let $n = k + 1$ $1! + 2! + .... + (k + 1)! < (k + 2)!$ $1! + 2! + .... + k! + (k + 1)! < (k + 2)!$ $1! + 2! + .... + k! + (k + 1)! < (k + 2)!$ $(k + 1)! + (k + 1)! < (k + 2)!$ $2(k + 1)! < (k + 2)!$ $2(k + 1)(k)(k - 1).. < (k + 2)(k + 1)(k)(k - 1)....$ $2 < (k + 2)$ the right is always bigger for k are non negative integer.
I have no idea how to approach this. I'm supposed to use $f\in \mathbb{Q}[X]$ is irreducible $\iff \exists{a}\in\mathbb{Q}$ such that $f(X+a)$ is irreducible. I tried to use $a = 1 \in \mathbb{Q}$ so $\frac{(X + 1)^p-1}{X}=(X+1)^{p-1}+\cdots+ (X+1) + 1$ but I don't see how I can get from there to being able to use any other criterion.
Can someone give me a hint how to the irreducibility of $X^{p-1} + \cdots + X+1$, where $p$ is a prime, in $\mathbb{Z}[X]$ ? Our professor gave us already one, namely to substitute $X$ with $X+1$, but I couldn't make much of that.
Can someone come up with two topological spaces $X$ and $Y$ satisfying Both are Hausdorff, $X$ and $Y$ are not homeomorphic; however $X$ and $Y$ are “compactomorphic” in the sense that there is a proper map between them with a proper inverse. In other words, the spaces themselves are different, but the compact sets are the same. This would be trivial in the non-Hausdorff case, using the same finite set with the discrete and trivial topologies. However, the discrete topology is the only Hausdorff topology on a finite set.
Suppose that $\tau_1$ and $\tau_2$ are two topologies on a set $X$ with the property that $K\subset X$ is compact with respect to $\tau_1$ if and only if $K$ is compact with respect to $\tau_2$. Then is this enough information to determine whether $\tau_1 = \tau_2$? If not (which is suspect to be the case) is there a nice counterexample, and what is the minimum amount of extra information required for $\tau_1 = \tau_2$? I feel like there would be an issue regarding 'points at infinity.'
I have two monitors that I use for development. I would like to use sloppy focus for switching between windows. sloppy focus -- whatever you mouse is hovering over is in focus. I know it's available in ubuntu 10.04. How do you enable it?
Is there a way to set up "focus follows mouse" behavior in Unity?
I haven't noticed this before, so I don't know if this have always been like this or not. But at a new question () which are currently unanswered, there is some text at the bottom that reads Know someone who can answer? Share a link to this question via email, , , or . . I guess this is showing on new unanswered questions. At least I cant find it on any of my other questions. It is a tiny problem, but the , , , or . part doesn't look good.
The list has several empty strings in it for me right now:
Recently i came up with this solution for enums in php: class Enum implements Iterator { private $vars = array(); private $keys = array(); private $currentPosition = 0; public function __construct() { } public function current() { return $this->vars[$this->keys[$this->currentPosition]]; } public function key() { return $this->keys[$this->currentPosition]; } public function next() { $this->currentPosition++; } public function rewind() { $this->currentPosition = 0; $reflection = new ReflectionClass(get_class($this)); $this->vars = $reflection->getConstants(); $this->keys = array_keys($this->vars); } public function valid() { return $this->currentPosition < count($this->vars); } } Example: class ApplicationMode extends Enum { const production = 'production'; const development = 'development'; } class Application { public static function Run(ApplicationMode $mode) { if ($mode == ApplicationMode::production) { //run application in production mode } elseif ($mode == ApplicationMode::development) { //run application in development mode } } } Application::Run(ApplicationMode::production); foreach (new ApplicationMode as $mode) { Application::Run($mode); } it works just perfect, i got IDE hints, i can iterate through all my enums but i think i miss some enums features that can be useful. so my question is: what features can i add to make more use of enums or to make it more practical to use?
I know that PHP doesn't yet have native Enumerations. But I have become accustomed to them from the Java world. I would love to use enums as a way to give predefined values which IDEs' auto-completion features could understand. Constants do the trick, but there's the namespace collision problem and (or actually because) they're global. Arrays don't have the namespace problem, but they're too vague, they can be overwritten at runtime and IDEs rarely know how to autofill their keys without additional static analysis annotations or attributes. Are there any solutions/workarounds you commonly use? Does anyone recall whether the PHP guys have had any thoughts or decisions around enumerations?
I have run into something that looks like a bug in Windows. I have extracted a RAR archive onto my PC and the extracted folders cannot be deleted by any means! My OS's language is English with some culture aspects of it set to Greek. The character that seems to create the problem seems to be 'å'. Here is a screen-shot that displays the problem: Using DEL from the cmd doesn't seem to help. When I try to delete the folder from Explorer nothing happens. When I try to rename the folder from Explorer I get these weird messages : Seems like a part of Windows thinks it's a file, while another part of it thinks it's a folder. So, the question is: does anyone know what goes on here and any way to delete this thing? EDIT: As you can see, I have found a solution. But if someone could explain to me WHY Windows has problems with this character while it generally supports Unicode, let me know. I would like to understand the internals of it... (that's the only difference from the other question, I guess) Does NTFS support both Unicode and ASCII files names and that file used ASCII (for some reason)? Then if it used ASSCII, how on earth was the character displayed correctly in Explorer?
I'm trying to delete a folder in Windows 7 and get a perplexing error message: "Could not find this item: This is no longer located in G:\Graphics. Verify the item's location and try again. I can see the folder -- I can find it. I just can't delete it. I also get a second error message (sometimes) when I click on the folder: G:\Graphics 2009-11-17 refers to a location that is unavailable...this information might have been moved to a different location. I'm using Windows 7; this folder is on an external hard drive. I've emptied the folder (there were items in it); I've scanned that external hard drive for errors. Trying to rename the folder yields the same enigmatic error message. Is there a way to delete this folder?
As a beginner, I'm really confused about size_t. I can use int, float or other types. Why still declare size_t type. I don't feel its advantages. I've viewed some , but I still can't understand it.
In several C++ examples I see a use of the type size_t where I would have used a simple int. What's the difference, and why size_t should be better?
I have tried installing all the available updates and when I check again for updates it says the computer is up to date. How can I upgrade?
What are the different ways I can use to upgrade Ubuntu from one release to another?
I rejected a disaster area of an edit, and look what popped up: Congratulations! This was only a test, designed to make sure you were paying attention. You passed. How many more Easter Eggs are going to sneak up on me? :-)
I recently received this rather amusing message while reviewing a user's first post: Congratulations! This was only a test, designed to make sure you were paying attention. This post has already been removed, but thanks for taking time to leave feedback for the author. What is the purpose of this test? How does the audit work? What happens if I fail? Why was the system expecting me to negatively review a good post, or positively review a bad post? A review is obviously an audit. Should I report it? Do review audits count toward the Reviewer badge? Do robo-reviewers dream of electric sheep?
How do I solve the determinant of this matrix using python? there are how solve using the word x in python? p = np.array([[x, 1], [1, x]])
I read in the manual of Numpy that there is function det(M) that can calculate the determinant. However, I can't find the det() method in Numpy. By the way, I use Python 2.5. There should be no compatibility problems with Numpy.
This section of Introduction to Statistical Learning in R (page 19 in v6, statement 2.3) is motivating the difference between reducible and irreducible error (that is noted by $\epsilon$ and has mean zero). Consider a given estimate $\hat{f}$ and a set of predictors $X$, which yields the prediction $\hat{Y} = \hat{f}(X)$. Assume for a moment that both $\hat{f}$ and $\hat{X}$ are fixed. Then, it is easy to show that $E(Y - \hat{Y})^2 = E[f(X) + \epsilon - \hat{f}(X)]^2$ $= [f(X) - \hat{f}(X)]^2 + Var(\epsilon)$ I'm having trouble getting the intermediate steps here. I understand that the expectation of the error in prediction should involve the variance of $\epsilon$ but I'd like to understand the proof. I expanded to $E(Y - \hat{Y})^2 = E[f(X) - \hat{f}(X)]^2 + 2E(\epsilon)E[f(X) - \hat{f}(X)] + E(\epsilon)^2$ and I see that I have $E(\epsilon)$ and $E(\epsilon)^2$ terms that could lead to $Var(\epsilon)$, but I'm stuck trying to fit some of the basic expected value and variance manipulations to it.
On page 19 of the textbook (by James, Witten, Hastie and Tibshirani--it is freely downloadable on the web, and very good), the following is stated: Consider a given estimate $$\hat{Y} = \hat{f}(x)$$ Assume for a moment that both $$\hat{f}, X$$ are fixed. Then, it is easy to show that: $$\mathrm{E}(Y - \hat{Y})^2 = \mathrm{E}[f(X) + \epsilon - \hat{f}(X)]^2$$ $$ = [f(X) - \hat{f}(X)]^2 + \mathrm{Var}(\epsilon)$$ It is further explained that the first term represents the reducible error, and the second term represents the irreducible error. I am not fully understanding how the authors arrive at this answer. I worked through the calculations as follows: $$\mathrm{E}(Y - \hat{Y})^2 = \mathrm{E}[f(X) + \epsilon - \hat{f}(X)]^2$$ This simplifies to $[f(X) - \hat{f}(X) + \mathrm{E}[\epsilon]]^2 = [f(X) - \hat{f}(X)]^2$ assuming that $\mathrm{E}[\epsilon] = 0$. Where is the $\mathrm{Var}(x)$ indicated in the text coming from? Any suggestions would be greatly appreciated.
I'm sure this question has been asked many times, but having gone through all the different answers, I'm more confused than ever before. I'm traveling to India from USA (point of entry: Delhi). I have a 7 year old Sony VAIO laptop purchased in India that is now slightly damaged, so I want to take it with me and keep it at home. Someone there might repair it for a much cheaper price (as compared to in USA) and use it. Since my own laptop is damaged, I purchased a secondhand Dell laptop on eBay recently, and I want to take it with me for the duration of my stay in India. I am a university student in the US, and need this laptop for my thesis work. However, since this laptop was purchased here in US, I'm not sure if I'll be allowed to get it through in customs at India. I'll be returning only with this laptop (duration of stay: 5 weeks). The price of the laptop purchased at eBay is $199, and I have the invoice for this. I don't have an invoice for the Sony VAIO laptop. (It's been 7 years!) Other than this, I also have a Samsung phone and an iPad (both purchased in India), and an iPod purchased in USA. At the time of purchase, the iPad was about Rs 44000/$700–$800. It's a 3rd gen iPad, so as of now its valuation might be much lesser. Which items can I carry without running into customs hassles in India?
I will be landing at New Delhi airport. The worth of new laptop (Lenovo Yoga Idea Pad 13) is about $1000 and old one (Macbook Pro) is > 1 lakh INR. I want to leave the new laptop in India. I have a copy of bill with me but not the original bill. I want to know if I have risk of being charged with custom duty.
An arithmetic progression is $a+0b, a+1b, a+2b, ..., a+nb$ A geometric progression is $ab^0, ab^1, ab^2, ..., ab^n$. Multiplication is arithmetic, so why is a geometric progression not also an "arithmetic" progression? A line being extended be iteratively adding a constant length is a geometric construction, so why is an arithmetic progression not also a "geometric" progression?
Where does the name of these two famous types of sequences come from? The article of Wikipedia says that the geometric sequence is called like this because every term is the geometric mean of its two adjacent terms. Though it is true, it only reduces the question to: why is the geometric mean geometric (in opposition to the arithmetic mean). Continuing my investigation on , I was told that a square with the same area than a rectangle with sides $a$ and $b$ has their geometric mean $\sqrt{ab}$ for side. That's again totally true, but a square with same perimeter than this rectangle of sides $a$ and $b$ has their arithmetic mean $\frac{a+b}{2}$ for side! Thus, my question: Who coined these names? And why? Why is the geometric mean more geometric than the arithmetic mean?
As you can see in the title I need help with the following exercise: Find all entire function with $f(\frac{1}{n})=\frac{1}{n^2}$ I guess I have to use the identity theorem but I dont know how
I am completely stuck in the following problem: let f be holomorphic function on the unit disk $\{z:|z|\lt 1\}$ in the complex plane.which of the following is/are necessarily true? (a) if for each positive integer $n$ we have $f(\frac{1}{n})=\frac{1}{n^2}$,then $f(z)=z^2$ on the unit disc. (b) if for each positive integer $n$ we have $f(1-\frac{1}{n})=(1-\frac{1}{n})^2$,then $f(z)=z^2$ on the unit disc. (c) $f$ cannot satisfy $f(\frac{1}{n})=\frac{(-1)^n}{n}$ for each positive integer $n$ (d) $f$ cannot satisfy $f(\frac{1}{n})=\frac{1}{n+1}$ for each positive integer n what I thought in this problem is the following: in the first part,by identity theorem we can say that $f(z)=z^2,\forall$z in the unit disc. but,in the second part ,if we choose $g(z)=z^2$ then,$f(1-\frac{1}{n})=g(1-\frac{1}{n})$ but,the limit point ,i.e, $1$ is not in the unit disc.so,in this case,we cannot use identity theorem to conclude whether $f(z)=z^2$ on the unit disk or not .so,what procedure can we follow in this case???also,explain the options (c) and (d). please answer in detail.. thanks a lot...
I use a QWERTY English keyboard layout which I would like to assign some new characters for Turkish characters, such as hitting Alt+o at the same time should type ö. What free tool do you recommend to perform this keyboard mapping in Windows? PS: This was so simple in Fedora as the Turkish keyboard layout was overlaid on the default English keyboard, so I could continue typing without any hassle. Thanks.
On Linux, the Compose key is a great way to enter many symbols. E.g. em-dash — by pressing Compose then - - - ö by pressing Compose then : o Euro € by pressing Compose then C = (The Compose key function can be assigned to various keyboard keys, such as right/left Alt, right/left Windows key.) I really miss the Compose key when using Windows. I've looked but so far haven't found any way to get equivalent Compose key functionality on Windows. Does anyone know of how to do it?
Before I go into details here is my specs CPU: Intel(R) Core(TM) i5-9300H CPU @ 2.40GHz GPU: NVIDIA GeForce GTX 1650 GDDR5 @ 4GB (128bit) RAM: 8.00 GB (7.85 GB usable) Storage: 133 GB free out of 500 GB OS: Microsoft Windows 10 64 bit I'm trying to figure out why my Elgato HD60s is giving me dropped game performance. I belive the weakest part in my specs is the CPU, but according to a twitch streamer I know, he said that the elgato system uses the GPU when ran from an HDMI signal to the USB 3.0 port on my computer, however I'm only having issues when it is ran from the HDMI output on my gaming Laptop back into the same laptop through the USB port. I'm trying to set up an adequate game recording system where preferably, I can use OBS to record my games without worrying about bottlenecking my weak CPU or having to lower my settings to an unreasonable percent (I prefer at least being able to encode and record at 720p60 including having a logi tech c922 pro stream camera plugged in). Is there a setting I can change to make the entire elgato system work through my GPU since its the laptop's strongest resource? Or is this even possible according to my specs?
Before I go into details here is my specs CPU: Intel Core i5-9300H @ 2.40GHz GPU: NVIDIA GeForce GTX 1650 GDDR5 @ 4GB (128-bit) RAM: 8.00 GB (7.85 GB usable) Storage: 133 GB free out of 500 GB OS: Windows 10 64-bit I'm trying to figure out why my Elgato HD60s is giving me dropped game performance. I believe the weakest part in my specs is the CPU, but according to a twitch streamer I know, he said that the Elgato system uses the GPU when ran from an HDMI signal to the USB 3.0 port on my computer, however I'm only having issues when it is ran from the HDMI output on my gaming Laptop back into the same laptop through the USB port. I'm trying to set up an adequate game recording system where preferably I can use OBS to record my games without worrying about bottlenecking my weak CPU or having to lower my settings to an unreasonable percent (I prefer at least being able to encode and record at 720p60 including having a Logitech c922 Pro stream camera plugged in). Is there a setting I can change to make the entire Elgato system work through my GPU since its the laptop's strongest resource? Or is this even possible according to my specs? Even when OBS is closed and there is not recording going on. Simply having the Elgato plugged into the HDMI port on the laptop drops the FPS Until I unplug it entirely. However when it is not plugged into the HDMI port on the laptop and its plugged into the USB 3.0 port on the laptop as if it was going to record another device (Playstation or any console device) that doesn't drop the performance of the laptop. Only when the laptop is feeding its screen to the Elgato card is when it gives a performance drop.
What is the distribution (probability density function) of the difference of two Gammas with the same scale? The parameters of each Gamma would be positive integers. That is, I'd like to know the density function ($f$) of $Z=X-Y$, where $X\sim {\rm Gamma}(a_1,b_1)$ and $Y\sim {\rm Gamma}(a_2, b_1)$. Assume $c$, $d$ are the parameters of $f(Z)$, particularly, I want to know the relationships between $c$, $d$, and $a_1$, $a_2$, $b_1$.
Given two independent random variables $X\sim \mathrm{Gamma}(\alpha_X,\beta_X)$ and $Y\sim \mathrm{Gamma}(\alpha_Y,\beta_Y)$, what is the distribution of the difference, i.e. $D=X-Y$? If the result is not well-known, how would I go about deriving the result?
I want to try install xampp on Ubuntu 14.04, I download xampp-linux-x64-5.6.15-1-installer.run and try to run it with sudo ,but in between of unpacking it getting error . I lookup at path /opt/lamp some files getting copy but installation not getting complete, I try to see log in install duration with tail -f /usr/log/syslog but nothing reported. where is the problem? update according to comment I try df -h to see free space of my disk
Hi all im a noob on Ubuntu/Linux World, So i need some that give a full tutorial to How to install from apachefriends.org correctly on Ubuntu 11.10 + all beyond Ubuntu for 32 bit and also 64 bit Desktop Version.. and also i need this: Make a Folder on Your Home Folder and Linked to htdocs from Apache Web Server Make a GUI interface for Xmapp Start Xampp when Ubuntu Boot Up or Start Ubuntu (Note: i ask it for both X86 and X64 so people in the further can see the tutorials) New Data: What i did was i download from for now and i also what to say that I'm currently running Ubuntu 11.10 X64 bit for Dell Studio 1558 processor intel i3 i will let you know guys which solution was the best, and it is for a Desktop Version of Ubuntu 11.10 (Laptop 15 inch screen ^_^ ) not Server Ubuntu
I'm trying to create an application that requires user login. I've used SceneBuilder and FXML file for the interface. I now have to retrieve data from a SQLite database (I've named the table with the data as "Users"). When I run this program, it throws a NullPointerException (I already data stored on the table). How do I fix it? //P.S. I use IntelliJ edit the database from the IDE itself. package sample; import javafx.event.ActionEvent; import javafx.fxml.FXML; import javafx.fxml.FXMLLoader; import javafx.scene.Node; import javafx.scene.Parent; import javafx.scene.Scene; import javafx.scene.control.Label; import javafx.scene.control.TextField; import javafx.scene.text.Text; import javafx.stage.Stage; import java.io.IOException; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; public class Controller { @FXML TextField username; @FXML TextField password; @FXML Label warning; Connection c; PreparedStatement pst; ResultSet rs; public void loginButtonClicked() throws IOException { try { String query = "select * from Users where Username=? and Password=?"; pst = c.prepareStatement(query); pst.setString(1, username.getText()); pst.setString(2, password.getText()); rs = pst.executeQuery(); if (rs.next()) { warning.setText("Successful"); } else { warning.setText("Not Successful"); } } catch (Exception e) { System.err.println(e); } } public void cancelButtonClicked(ActionEvent event) throws IOException { System.out.println("User has cancelled login..."); ((Node)event.getSource()).getScene().getWindow().hide(); } }
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?
Let's say I have a listing website with thousands of pages. I don't want to make all those pages(items) crawlable by others, unless they search for those items. But, still I like to have all those pages indexed in google. Please note that those pages do exist, and it is not a broken link, just that there is no direct link to those pages unless one uses search function of the website. How can I achieve that? One things that comes to my mind is to create a complete sitemap with all pages included and submit it to google for indexing. would it work!? Or google would complain that it cannot follow a path of links from home page to those (unlinked) pages? Thanks
We use a on Stack Overflow, but I have mixed feelings about it. Web crawlers usually discover pages from links within the site and from other sites. Sitemaps supplement this data to allow crawlers that support Sitemaps to pick up all URLs in the Sitemap and learn about those URLs using the associated metadata. Using the Sitemap does not guarantee that web pages are included in search engines, but provides hints for web crawlers to do a better job of crawling your site. Based on our two years' experience with sitemaps, there's something fundamentally paradoxical about the sitemap: Sitemaps are intended for sites that are hard to crawl properly. If Google can't successfully crawl your site to find a link, but is able to find it in the sitemap it gives the sitemap link no weight and will not index it! That's the sitemap paradox -- if your site isn't being properly crawled (for whatever reason), using a sitemap will not help you! Google goes out of their way to make : "We cannot make any predictions or guarantees about when or if your URLs will be crawled or added to our index" "We don't guarantee that we'll crawl or index all of your URLs. For example, we won't crawl or index image URLs contained in your Sitemap." "submitting a Sitemap doesn't guarantee that all pages of your site will be crawled or included in our search results" Given that links found in sitemaps are merely recommendations, whereas links found on your own website proper are considered canonical ... it seems the only logical thing to do is avoid having a sitemap and make damn sure that Google and any other search engine can properly spider your site using the plain old standard web pages everyone else sees. By the time you have done that, and are getting spidered nice and thoroughly so Google can see that your own site links to these pages, and would be willing to crawl the links -- uh, why do we need a sitemap, again? The sitemap can be actively harmful, because it distracts you from ensuring that search engine spiders are able to successfully crawl your whole site. "Oh, it doesn't matter if the crawler can see it, we'll just slap those links in the sitemap!" Reality is quite the opposite in our experience. That seems more than a little ironic considering sitemaps were intended for sites that have a very deep collection of links or complex UI that may be hard to spider. In our experience, the sitemap does not help, because if Google can't find the link on your site proper, it won't index it from the sitemap anyway. We've seen this proven time and time again with Stack Overflow questions. Am I wrong? Do sitemaps make sense, and we're somehow just using them incorrectly?
Any thoughts as to that for which I had not accounted here? Looks like it returns 99.99999999999999 using ruby 2.3.1p112
Consider the following code: 0.1 + 0.2 == 0.3 -> false 0.1 + 0.2 -> 0.30000000000000004 Why do these inaccuracies happen?
I am trying to make my document such that when you click on section or subsection titles in the main body, it will take you back to the TOC. I have implemented this as such: \makeatletter \let\oldcontentsline\contentsline% \renewcommand\contentsline[4]{% \oldcontentsline{#1}{\smash{\raisebox{1em}{\hypertarget{toc#4}{}}}#2}{#3}{#4}}% \let\oldsection\section% \renewcommand\section[1]{% \oldsection[#1]{\protect\hyperlink{tocsection.\thesection}{#1}}}% \let\oldsubsection\subsection% \renewcommand\subsection[1]{% \oldsubsection[#1]{\protect\hyperlink{tocsubsection.\thesubsection}{#1}}}% \let\oldsubsubsection\subsubsection% \renewcommand\subsubsection[1]{% \oldsubsubsection[#1]{\protect\hyperlink{tocsubsection.\thesubsection}{#1}}}% \makeatother Although it works, at the top of my TOC I get this: I know it has something specific to do with the \renewcommand\section, because if I change that then it works fine. How can I go about fixing this?
I'd like the section headings in running text to link to their "line" in the Table of Contents so as to get "two-way" navigation, eg: a user looks in the Table of Contents for a section title, jumps there, reads a couple of lines, clicks on the section title again and gets taken to the section's entry in the Table of Contents once more. Any ideas? :) (Somewhat related to )
The command sudo apt-get update returns E: Malformed line 54 in source list /etc/apt/sources.list (dist parse) as output. Please help me to solve this issue. Here are lines 53 and 54 in the source list: deb-src http://security.ubuntu.com/ubuntu lucid-security multiverse deb http://archive.canonical.com/lucid partner
I have unistalled and reinstalled the Ubuntu Software Center as per info I found in a similar thread and I got the same response about line 91 or something like that. I just tried to upload a screen shot but since I'm new it won't allow me to. I also can not figure out how to cut and paste anything so I have to hand type what the error screen says, both when I attempt to open the software center and nothing happens, when I try to enter commands into the terminal to uninstall, reinstall, whatever I get the same following: COULD NOT INTITIALIZE THE PACKAGE INFORMATION An unresolvable problem occured while initializing the package information Please report t:his bug against the 'update-manager' package and include the following error message: 'E: Malformed line 91 in source list/etc/apt/sources.list (dist parse) E: The list of sources could not be read., E: The package list of status file could not be parsed or opened. How do I report bugs? What can be done about this. I have searched and everything everyone says to do leads me back to the same line error message. So, I don't know how to get to line 91 in the source list; to tell you what it says. Sorry, I'm really new to this. That is what I need is to find out how to get there and fix what it says. I would really like to NOT have to re partition my hard drive and start from scratch, so I'm really looking forward to getting this problem solved. I need to be able to install new software.
Is there a way to see a detailed report of how I collected my reputation on a specific site, grouped by the way of achievement? E.g. +100 from being a network user +450 from upvoted questions +300 from upvoted answers -80 from downvotes +45 from accepted answers -200 from bounties Ideally I would also like to be able to drop down each section to see the specific questions / answers.
If I am concerned that my reputation score is incorrect, how can I audit it, or get a report of a detailed breakdown of my reputation?
One of my players wants to play a (VGtM, p. 105) but wondered if he'd be able to use his racial ability, Radiant Soul, in an antimagic field. Would an antimagic field block the protector aasimar's Radiant Soul feature, or would he be unaffected?
Often confusion arises when the spell is used, an is worn, or the 's anti-magic ray is employed, whether a given character's ability will still function. The spell does give you some guidelines on how to adjudicate the effects of the loss of magic but says very little about how to determine what is affected. In short, how do I tell if an ability is magical?
I was wondering how i can make my own custom google search. Can i do something like this : <form action="http://www.google.com/search=q?+text input" method="get"> <input type="search"> <input type="submit"> </form>
Basically I have a website. I have a properly setup sitemap so I assume Google knows about all of my pages. And I've seen on some sites, the search form leads to a page with the shell of the original site but the results are clearly provided by Google. Similar to codinghorror.com's search, however his results aren't shown within his website's layout. Any idea what I'm talking about or how to achieve this?
I have a census tract shapefile for the state of South Dakota. I have providers plotted with a 40 mile radius buffer. I am trying to determine what percent of each census tract is covered by any part of the buffer. How can I do this?
I have a point shapefile of villages where data was collected in Northern Kenya. I created a buffer around those villages. The second vector layer contains polygons defining areas according to vegetation type. So for example, a forest might be surrounded by a narrow ring of woodland in an area which is mainly grassland. I'm trying to obtain a percentage of each vegetation type within the buffer per village. I'm using QGIS 1.7
I'm trying to find the distance to an object with my Android. I know the real size of object, also done some camera calibration with OpenCV to calculate focal length, camera matrix and distortion parameters as well. To easy up the question, it's assumed that the orientation is 0 degrees (can compute the angle of the android device when detecting the object) My previous method was using some sort of manual calibration: - Calculated the area in pixels at several known distances and saved both values (area and distance). Every time I see the object i compute a regression based on the area measured. But this method is obviously inaccurate. So based in the parameters I know that I mentioned above, what do you recommend as best method? Cheers
If I took a picture of a windmill on the horizon — given that I know the sensor size and the focal length of the lens and other factors to do with the shot — could I calculate how far away an object is from the photographer?
From the docs of : Throws: NullPointerException - if this collection contains one or more null elements and the specified collection does not support null elements (optional), or if the specified collection is null. But the code below does still throw a : public class TestSet { public static void main(String[] args) { Set set1 = new TreeSet(); set1.add("A"); set1.add("B"); Set set2 = new HashSet(); set2.add(null); set1.removeAll(set2); } } Can someone help me understand this behavior?
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 Ubuntu and I really want to watch anime from my computer on my TV 😢.
I have an ubuntu 14.04 box, Roku 3 and 50 inch TV and I want to cast my pc screen to the TV. The roku and pc are on the same network. Has anyone got a way to do this? Doesn't have to be a nice solution, just wondering if it's possible.
Generally we read or solve problems about charges in the same medium. I wonder what would happen if the two charges were placed in different mediums. eg.) One is placed in vaccum and other is placed in a dielectric. The concept would be that dielectric would get polarised due to the charges and net force of attraction or repulsion between the charges would decrease. But I cannot understand this from a mathematical point of view like will the permittivity of the mediums add or what? Please help me to understand this mathematically. Note: This is not a homework question. Also there seems a similar question on Stackexchange but the answer to it seemed unsatisfactory to me because the answer used a special case to explain the case and not a general one. Also there were a lot of comments questioning the answer. That's why decide to ask a new question.
I am given two charged particles of same charge at a distance of $r$. They initially apply force $F$. Now an infinite dielectric (of dielectric constant $4$) of width $\frac{r}{2}$ is introduced between the particles. What will be the new force? I find this problem confusing because I have only been told about forces when its either fully dielectric or fully vaccum given by Coulomb's law. How do we get forces when only partial space is dielectric?
I've used SO for a while as a reference, but never asked a question before. I'm currently in a college C++ class and also reading Programming: Principles and Practice by Bjarne Stroutstrup just for my own benifit, as I saw an answer to a question here that really recommended it. We're covering operators at the moment in my class, and I just can't seem to wrap my head around how the comma operator works in a statement. One example is a sample question for the online portion of the class that I keep getting wrong, even if I write a C program and use GDB to get the result. The question is: Assuming x==16 before the following expression, what is the value of the following expression (not necessarily the value of x)? x++, ++x, x+=x I'm not interested in the correct answer so much as how to get the correct answer. I've read through a couple answers to similar questions, such as this one , but it seems like I'm missing how this applies when there is actually no assigment operator. Is this the same as saying int y = (x++, ++x, x+=x); or int y = x++, ++x, x+=x; or neither? Could someone please explain how the comma operator works, specifically in relation to a statement without an assignment?
How does the comma operator work in C++? For instance, if I do: a = b, c; Does a end up equaling b or c? (Yes, I know this is easy to test - just documenting on here for someone to find the answer quickly.) Update: This question has exposed a nuance when using the comma operator. Just to document this: a = b, c; // a is set to the value of b! a = (b, c); // a is set to the value of c! This question was actually inspired by a typo in code. What was intended to be a = b; c = d; Turned into a = b, // <- Note comma typo! c = d;
Just trying out Linux for the first time. I am able to install Ubuntu 18.04 without any problem except for the fact that my screen keeps on spontaneously flickering. It starts to flicker as soon as the system boots up to the login screen (even before entering my password). Things tried: Changing between different drivers in the Software & Updates -> Additional Drivers option (nvidia-driver-396, nvidia-driver-390, nouveau) Boot with "nomodeset" Blacklist nouveau Updating kernel to 4.17.4 If there anything else I should try please let me know.
I have been trying to install Ubuntu on my new laptop: Dell XPS 15 (9570) Windows 10 Home 64bit English 8th Generation Intel(R) Core(TM) i7-8750H Processor (9M Cache, up to 4.1 GHz, 6 cores) 16GB, 2x8GB, DDR4, 2666MHz 256GB M.2 2280 PCIe Solid State Drive NVIDIA(R) GeForce(R) GTX 1050Ti with 4GB GDDR5 I began by trying to install Ubuntu 18.04 LTS using an 8GB USB drive. The first issue I ran into was getting frozen on the bootup screen on the fourth dot. After a couple tries, I plugged in my monitor (through HDMI) and it stopped getting stuck all of a sudden. Next, I tried to go through the installation and when I clicked on restart now, my computer froze and I had to shut it down manually and start it back up again. At this point I got to the login screen and logged in but after entering my password it got stuck on a purple screen with my mouse pointer (which was frozen). I was able to get into a shell at this point (with ctrl+alt+f4) and attempted to run sudo apt-get install nvidia-390 but this froze when it reached building initial module for 4.15.0-22-generic and upon reboot I had to run sudo dpkg --remove -a. I was unable to work around this so I attempted to install Ubuntu 16.04 which I could only do by adding acpi=off to the boot configuration (which by the way, I had a lot of trouble getting to since GRUB usually flashed in and then immediately disappeared and only occasionally would it stick around long enough for me to use). But when I try to boot up now, I never reach the screen with the five dots and instead immediately get stuck on a purple screen (with no mouse pointer). I reinstalled Ubuntu 18.04 and am back to being stuck on the log-in screen. What should I do?
Consider the following sentence as an example. I used some hair spray. What part of speech is hair? Intuitively, I want to say it's an adjective modifying spray since hair spray is two separate words and not a compound noun. Hair spray however, as paired nouns, is something that we've decided to call a thing suggesting it might be a noun or maybe some other part of speech as part of a noun cluster (if such a thing exists). A dictionary entry for hair does not describe hair as an adjective. I can think of several more examples like this: money order, pocket comb, tip money. Are money, pocket and tip adjectives or something else?
I read this recently in : At the end of the summit, the French and European officials had claimed a points victory over the Germans by getting them to agree more firmly to a target date of January 1st next year to entrust the European Central Bank (ECB) with the ultimate authority to supervise the euro zone’s 6,000-odd banks. "Points" is a plural, and I suppose it doesn't function as a noun in this sentence since it's following the article "a", so is it an adjective adorning "victory"?
I am not too much of a chat user, I must say. However, whenever I do use one, the aesthetic appeal is simply not there. There is barely any user interface, and it just generally does not look great. Also, Latex does not seem to be supported, which makes typing math equations extremely difficult to read. I think that with the new toolbar update going live, Stack Exchange is trying to make all of their sites look more appealing, but the chat rooms have never seemed to be updated for appeal. Are we going to see a change soon? Or is it because the chat rooms are not very popular? Here is a picture of a chat room in Math Stack Exchange:
It would be really nice to be able to use MathJaX (math formulas) in chat. Not specially for formulae, but for things like $V_{CC}$ in electronics chat would be very useful.
Suppose I live in the US and want to buy an ETF share traded in the US. I would already know how Chinese stock market performed by the time the US market is open because of the 12-hour difference. Let's say it's 1/21/2020 Tuesday in the morning Eastern Time, which is 1/21/2020 Tuesday evening time in China. If Chinese market gained (and suppose the top 50 stocks by market-cap gained) on 1/21/2020, would I gain if I buy an ETF (traded in the US) that tracks an index composed of top 50 Chinese stocks? If that's case, is this a 100% win situation? If not, why? Also, because Chinese market is already closed, why does the ETF price sticll change, if the underline index is not supposed to be changing? Thanks!!
For example: Because the NASDAQ: DAX is tracking the index INDEXDB: DAX should its trading value be completely flat when the market the markets are open in the US, but closed in Germany? I'm not seeing that artifact in any of the charts I can find.
After fixing the "System runs in low graphic mode"-error, the resolution of my screen changed to 640x480. Obviously, this is not my native resolution. I cannot set it to the native resolution (1366 x 768) for some reason, since there is no other resolution shown in the Monitor Settings. Arandr also does not show 1366x768 as a possible resolution. My laptop is a Samsung R519 with standard resolution 1366x768, with an Intel graphic card. Does anyone have an idea how to solve my problem? I hope I explained it clear enough (if there is some missing info, please let me know)
I have installed Ubuntu on my desktop, but my monitor don't pass more than 800x600 resolution. My monitor is good at 1360x768. How can I set resolution at 1380x768 ?
When I run: render_args = bpy.context.scene.render render_args.engine = 'BLENDER_RENDER' I get the following error: TypeError: bpy_struct: item.attr = val: enum "BLENDER_RENDER" not found in ('BLENDER_EEVEE', 'BLENDER_WORKBENCH', 'CYCLES') I am using Blender 2.91.0 Alpha. Why is 'BLENDER_RENDER' missing and how do I fix it?
Blender has just purged the entire game engine from 2.8. There is no "Game Engine" mode anymore and there isn't even a logic editor. I tried installing a GitHub Blender release with the game engine mode working but it failed to install because all the game code was gutted. Does this mean that Blender 2.8 is going to lose the game engine, or is the game engine just being redone for better compatibility and whatnot?
$(a)$ Let's say A person is pushing an object. Then the object will put a force on the person equal to the force the person is putting on the object (because of Newton's third law). Then the person should move backward because of the opposing force. But clearly, the person moves in the same direction as the object while the person pushes it. Is there something wrong with my reasoning? $(b)$ Let's say I am pushing against a wall with force $F$, then the wall will push me with force $F$ (because of newtons 3rd law). Because The wall is pushing me with force F, then I will (because of newtons 3rd law), push the wall with force $F$, this will add up with my previous force to $2F$. If I keep doing this indefinitely, then I can say that I am pushing this wall with a force of $\infty$ $N$ and the wall is pushing me with a force of $\infty$ $N$. That would mean I will get crushed and the wall will get destroyed. But clearly, that does not happen. Again, where am I using Newton's 3rd law in the wrong way?
My father explained to me how rockets work and he told me that Newton's Third Law of motion worked here. I asked him why it works and he didn't answer. I have wasted over a week thinking about this problem and now I am giving up. Can anyone explain why Newton's Third Law works? For reference, Newton's third law: To every action there is always opposed an equal reaction: or the mutual actions of two bodies upon each other are always equal, and directed to contrary parts.
What is it called when single letters are used as words in a sentence? I C A B. I C D B P! I see a Bee. I see the bee pee! F U N-E X? S I F X. F U N-E M? S I F M. OK I L F M N X! Have you any eggs? Yes I have eggs. Have you any Ham? Yes I have ham. OK. I will have ham and eggs. I have been looking for this, at a low level, for years.
IOU stands for I owe you and we pronounce each letter separately. But how do we classify that construction"? abbreviation: a shortened form of a word or phrase acronym: an abbreviation formed from the initial letters of other words and pronounced as a word Initialism: an abbreviation consisting of initial letters pronounced separately back-formation: a word that is formed from an existing word which looks as though it is a derivative, typically by removal of a suffix All definitions provided by Oxford Dictionaries Online It can't be an abbreviation because there is no shortening, clipping or back-formation. Take for example phone which is an abbreviation of telephone, or edit which is a back-formation of editorship and editor. I would argue that abbreviations are words that have been shortened, a faster way of writing or saying something. Another example would be Prof for professor. It can't be an acronym because we don't pronounce IOU as one word, whereas we do with NATO and RAM. It can't be an initialism because if it was, it should be written as IOY (I Owe You) Other examples that spring to mind is CU for see you and YRU for why are you, where initialism would dictate that the proper forms be SY and WAY. How do linguists define this structure? Is there a more specific term than abbreviation?
If someone has roads all the way around a hex in catan (six roads), and one road on each opposite end of that hex, is that a total of seven towards the longest road or eight. In other words do both roads on either end count or only one since it goes around in a circle?
If I have 6 roads that go all around a single hex tile, they are a continuous uninterrupted road (assuming none of my opponents interrupts it with their settlements/cities). But, can I continue this 6-piece road and create a 7-piece continuous road by building a road that goes out of this hex tile? Here's an image of what I'm talking about: Is this a valid 7-piece continuous road?
A snippet of regression code of a stock price data- forecast_col='Adj. Close' forecast_out=int(math.ceil(0.01*len(df))) df['label']=df[forecast_col].shift(-forecast_out) X=X[:-forecast_out+1] What is the meaning of X=X[:-forecast_out+1] ?
I need a good explanation (references are a plus) on Python's slice notation. To me, this notation needs a bit of picking up. It looks extremely powerful, but I haven't quite got my head around it.
I have to show that for every analytic function $f$ on $G \subseteq \mathbb{C}$ (Simply connected open set) such that $f(z) \neq 0, \forall z \in G$, then $\exists$ a function g analytic in $G$ such that $g^2 = f$. Also, I need to give an example of an open set $G$ which is not simply connected and an analytic function $f$ on $G$ with $f(z) \neq 0, \forall z \in G$ such that $f \neq g^2$ for every analytic function $g \in G$. I do not see how to approach this problem. If I get the first part, maybe the example will be easier.
$\psi(z) \neq 0$ is a holomorphic function on $D \subseteq \mathbb{C}$. Does there exist a holomorphic function $\varphi(z)$ on $D$ such that $\varphi^2(z) = \psi(z)$? Here $D$ can be a single-connected region or a multi-connected region. I think for single-connected region, it is true, but I can not prove.
I am new to programming and would appreciate some help. The slightest bit of insight would be highly appreciated. I have an issue with the following code. The program emulates a calculator but currently my main focus is on if and else if statements. The issue is that no matter what the user selects, the program will always add the two numbers i.e. 'number1' and 'number2' in the code import java.util.*; public class Input { private Scanner input; public Input() { input = new Scanner(System.in); } public void calculation() { double number1, number2, answer; String A, B, C, D, E; String option; A = "A"; B = "B"; C = "C"; D = "D"; E = "E"; //initialising the strings System.out.println("add - option A \t (if your option is A, insert 'A')"); System.out.println("multiply - option B"); System.out.println("subtract - option C"); System.out.println("divide - option D"); System.out.println("power - option E (1st number - 'X' & 2nd number - 'n' following X^n)"); System.out.println("Remember Java is case sensitive, therefore, inserting 'a' as 'A' won't work"); System.out.println(); System.out.println("Insert your first number: "); number1 = input.nextDouble(); System.out.println("Insert your second number: "); number2 = input.nextDouble(); System.out.println("Choosing option: "); option = input.next(); if(A == A) { answer = number1 + number2; System.out.println("Your answer is: " + answer); } else if(B == B) { answer = number1 * number2; System.out.println("Your answer is: " + answer); }else if(C == C) { answer = number1 - number2; System.out.println("Your answer is: " + answer); }else if(D == D) { answer = number1 / number2; System.out.println("Your answer is: " + answer); }else if(E == E) { answer = Math.pow(number1, number2); System.out.println("Your answer is: " + answer); }else { System.out.println("Choose a suitable option"); } } }
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’m trying to remember the name of a book I can only just remember. It was for older children, and was something about "the Wall", and north of it are ancient and scary otherworldly forces (but not A Song of Ice and Fire). I think a group of children, from a school on the border by the wall, end up being the heroes and the novel ends with a battle in the school.
I'm trying to remember a book set in an alternate England with a walled-off section that contains undead and other magical phenomenons, which can be controlled and dispelled by playing special musical bells. The owner of these bells is the main character's father, and is responsible for maintaining peace between the walled-off area and the rest of England. When he is captured by a powerful undead, the main character goes into the walled-off land to rescue him using her own set of bells.
Does anyone have information /can point out reliable source on Iceland Covid restrictions for tourist travelling to Iceland in July 2020 ?
Due to the outbreak of nCoV-19 (Novel Coronavirus) many Countries have imposed several entry restrictions. But these are quite confusing for a lot of people. Some countries allow transit through parts of China (like Shanghai) but some restrict transit even through Hong Kong/Macau. Philippines restricted passengers coming from Taiwan too, but I think that that was later changed. Where can one find a list of such restrictions for all the countries, ideally a source that is updated frequently
I had initial plans to travel to Spain and got my visa, but due to my partner's work schedule had to cancel the plan to Spain and am now planning to go to France. Will it be an issue if I do not go to Spain and straightaway go to France with the visa issued by Spain? Not sure of the practice. Thanks for your inputs.
In case, if I get a multiple-entry Schengen visa in one of the embassies in Ukraine, Kyiv - should my first trip be to the country which issued the visa? Any there any requirements of this sort? Does this condition vary depending on embassy which issued the visa? What are the possible consequences on not visiting that country first? Does it somehow depend on country where the embassy is (i.e. non-Schengen and not EU members)?
I'm confused by why there are so many separate sites for specific languages on here. Wouldn't it be better to just have one "Languages" Stack Exchange where you can indicate which language you're asking about with the tags? As it is, if I want to ask about ancient Greek dialects I have to post on the "Latin" Stack Exchange, and if I have a question about Ghandaran or Pali I have to go to the "Buddhism" one, and if I have a question about Klingon grammar I have to post on the Sci-fi and fantasy site (where it will most likely be closed as off-topic). As far as I know there's nowhere for me to ask about Toki or Ithkuil (although perhaps the Esperanto site might accept a question about these languages). Just wondering about the rationale for having so many separate sites. Is it possible to merge them all into one "Languages" site where any and every language would be on-topic?
There are a quite a few language learning related sites on the Stack Exchange network. I may have missed a few, but here they are: It would be nice to have a single language related site and use tags when asking questions about a specific language. Stack Overflow already does something similar for programming languages. Benefits Automatic support for minority or endangered languages. There are thousands of languages that will never have enough support to create their own SE site. Yet many have a core group of learners and researchers that would benefit from being able to ask and answer questions just by adding a new tag. Cross-language questions. Many languages are related to each other. A common site would make it easy to ask a question about something that covers two languages. Just add both language tags. Cut down on the proliferation of new SE sites. I don't know that having lots of sites is necessarily bad, but sometimes less is more. Better search engine results. I can't guarantee this one, but it seems likely. Stack Overflow is always near the top for programming language questions, but I rarely find SE language sites when I search for English or Chinese related questions. I suppose that everyone is too entrenched in their own communities now to change, but I thought I would suggest it anyway.
Is there a way to block a specific folder's files from showing up in the Unity search?
I sometimes browse erotic media files but I would like to avoid having them appear in files & folders / recent. How can I do that? The old "making .recently-used.xbel a folder" trick from 10.10 and older doesn't work any more. Plus I'd prefer to turn off tracking only temporarily. I also prefer not to use a separate user for this, as switching users sometimes isn't fast enough.
The truth potion (Veritaserum) is one of the most powerful potions that forces the drinker to speak truth. Then why didn't Ministry used it in any criminal cases instead of long discussions and proceedings? I know there are antidotes to the potion (Dumbledore tells Harry in the 6th book , "Slughorn might have been carrying antidote to veritaserum ever since I asked him about the memory"), but why don't keep criminals in custody until the effect of the antidote wears out and then make them drink veritaserum. Won't that result in perfect judgement?
Reading through the books once again, I came to ask myself: What "truth" is told whilst being affected by veritaserum? Is it the objective truth or what one believes to be true? Regardless of how the answer is I see many problems arising from this, but also some great ideas.
Is there any specific name for this type of question or statement? If I ask someone a yes/no type question "Have you lost your mind?" then either answer(yes or no) is degrading to the person replying. No - ok you never had it. Yes - could mean he has gone crazy. There could also be a statement made to a person, which if that person refutes he is shown in bad light or even if he agrees, it is bad for him. Is there any name for such device? Any examples of such devices(questions or statements) where I could read more of this type.
For example, if I ask someone "What does it feel like to be a gay Christian?" I'm suggesting that the person to whom I'm asking is gay and Christian, neither of which may be true.
I have been given an assignment where I need to check if a Booking Reference is valid. The Booking Reference has to be in the style of "ABC-1234". I need to use PHP to check the first three letters are either "ACT ABQ BDE". This is then followed by the "-". Then I need to check the numbers are in the following sequence, the first digit is either "1" or "2", and the following three digits are in the 0-9 range. This is the code I currently have to check this: if (isset($webdata['bookingreference'] )) { if (!preg_match("/^ [ACT] [ABQ] [BDE] - [(1),(2)]{5}[0-9]{6,}$/", $webdata['bookingreference'])) { $formerror['bookingreference'] = '<span class="warn" >Not valid on server: Invalid booking reference</span>'; $valid = FALSE; } However, when I test this, I always get the message it is valid no matter what the sequence is. Any help is much appreciated!!
I don't really understand regular expressions. Can you explain them to me in an easy-to-follow manner? If there are any online tools or books, could you also link to them?
I just wanted to know if there's anything built into the .net framework where I can easily return the delta between two numbers? I wrote code that does this but it sounds like something that should be in the framework already.
I need the perfect algorithm or C# function to calculate the difference (distance) between 2 decimal numbers. For example the difference between: 100 and 25 is 75 100 and -25 is 125 -100 and -115 is 15 -500 and 100 is 600 Is there a C# function or a very elegant algorithm to calculate this or I have to go and handle every case separately with ifs. If there is such a function or algorithm, which one is it?
Suppose $X_1,X_2,\cdots,X_n$ are iid uniform random variables on $[a,b]$, what is the distribution of $$Y_n=\frac{\max_{1\le i\le n}X_i+\min_{1\le i\le n}X_i}{2}?$$
Let $X_1,X_2, \ldots , X_n$ be independent and identically distributed Uniform random variables on the interval (0, a) for a > 0, each having a density function $f(x) = \frac{1}{a}$, $0<x<a$. Let $X_{(1)},X_{(2)}, \ldots , X_{(n)}$ denote the order statistics. The range of the data is defined as $R = X_{(n)}−X_{(1)}$ and the midrange is defined as $V = \frac{1}{2}(X_{(1)}+X_{(n)})$ Derive the joint distribution of $(R, V )$ and deduce the marginal distributions of $R$ and $V.$ Attempt: First I am attempting to generate the joint distribution of $(V,X_{(1)})$ and then integrate out the $X_{(1)}$. For the joint distribution of $(V,X_{(1)})$ I have: $$ f_{v,x_{(1)}}(v,x_{(1)})=2n(n-1)\int_{-\infty}^v [F(2v-x_{(1)})-F(x_{(1)})]^{n-2} f(2v-x_{(1)})f(x_{(1)}) \, dx_{(1)}$$ At this point I have no idea how to integrate out the $x_{(1)}$. Edit: I have located the joint distribution of the range and mid-range: $$ f_{r,v}(r,v) = n(n-1) \left[F\left(v+\frac{r}{2}\right) - \left(F\left(v-\frac{r}{2}\right)\right)\right]^{n-2} f\left(v-\frac r 2 \right) f(v+\frac{r}{2})$$ For each marginal distribution, I have to integrate out: $$ f_r(r) = \int_{-\infty}^\infty n(n-1)[F(v+\frac{r}{2})-(F(v-\frac{r}{2})]^{n-2}f(v-\frac{r}{2})f(v+\frac{r}{2}) \, dv$$ $$ f_v(v) = \int_0^{\infty}n(n-1)[F(v+\frac{r}{2})-(F(v-\frac{r}{2})]^{n-2}f(v-\frac{r}{2})f(v+\frac{r}{2}) \, dr$$
I'm currently unit testing .NET application with NUnit framework. Some of the methods we use involve getting X509Certificate2 object as input and checking if one or more properties match certain crateria. For example, method that check whether the thumbprint exists in a very specific list. Thus, I need a way to mock or fake the X509Certificate2 object so that I can control what the thumbprint field will return or what are the extentions list will contain. One way I can approach this is to create the special certificates and use them as resources in the tests project (hard coded or embedded resource). I'm searching for a different solution, if it's even possible. And suggestions will be greatly appreciated! Thanks in advance :)
can be quite a pain. I currently favor an to handle this, but something about just keeps feels weird. So, What is the best way you mock sealed classes? Java answers are more than welcome. In fact, I would anticipate that the Java community has been dealing with this longer and has a great deal to offer. But here are some of the .NET opinions:
A post that doesn't exist is shown on the "Top network posts" section on this . The title is called "6", and the URL of the post leads to this .
I discovered a strange, blank link in 's Top Network Posts: The above link and screenshot are of the user's Unix & Linux site profile, but this issue can be reproduced on any of the user's site profiles other than Meta Stack Exchange (as the blank post appears to be on this site, and posts from the same site are excluded). The link seems to go to , which features a really negative question ID (close to the lowest value that can be represented by a 32-bit signed integer, specifically -(2^31) + 1005), and lacks the title in the URL that is present in all of the other links. It leads to a 404 error. Going to the seems to go to an actual answer on a question migrated to this site, which happens to have a score of 13 (as of the time this was asked). Why is the question ID incorrect here? Based on the duplicates, it seems that this affects posts (both questions and answers) that were migrated from other sites: somehow, the question ID seems to be getting messed up. Update: It looks like the above linked user has deleted their account on this site, so the issue cannot be reproduced on the profile I originally reported. It can, however, be reproduced on . The errant link in that profile is , and the errant question ID seems to also be close to the lowest possible 32-bit signed integer, -(2^31) + 3412.
I was reading an article about the existence of exotic spheres in 7 dimensions, my initial instinct was that that was pure mathematics and most likely inapplicable to any natural sciences. Then I remembered string theory used 10 spatial dimensions, so, are there structures in string theory that are equivalent to exotic spheres? Does it imply that the metric of space-time becomes non-smoothable, despite being continuous?
Basically an exotic sphere is topologically a sphere, but doesn't look like a one. Or more accurately: homeomorphic but not diffeomorphic to the standard Euclidean n-sphere The first exotic spheres were constructed by John Milnor (1956) in dimension n = 7 as S3-bundles over S4. It looks like an SU(2) gauge field on S4? But I don't know more about this? I guess there is lots of expertise here. Could you give a physical interpretation of this 7 sphere? Just to make it more intuitive. Thank you!
I'm using the ieeeaccess.cls for IEEE Access journal but I get the following error, Missing number, treated as zero. \xdef My code is as follows, \documentclass{ieeeaccess} \usepackage{amsmath, amsfonts, amssymb, color, enumerate, amsthm, graphicx} \usepackage{tikz, subcaption, cite} \usepackage{color, xcolor, soul, bm, textcomp} \usepackage{marginnote} \PassOptionsToPackage{hyphens}{url}\usepackage{hyperref} \hypersetup{ colorlinks = true, %Colours links instead of ugly boxes urlcolor = blue, %Colour for external hyperlinks linkcolor = blue, %Colour of internal links citecolor = green %Colour of citations } \renewcommand{\qedsymbol}{$\blacksquare$} \usepackage[normalem]{ulem} \newtheorem{problem}{Problem} \newtheorem{theorem}{Theorem} \newtheorem{corollary}{Corollary} \newtheorem{assumption}{Assumption} \newtheorem{proposition}{Proposition} \newtheorem{lemma}{Lemma} \newtheorem{remark}{Remark} \newtheorem{definition}{Definition} \newtheorem{example}{Example} \usepackage{epsfig} \usepackage{psfrag} \DeclareMathOperator{\diag}{diag} \usepackage{tcolorbox} \usepackage{algorithm} \usepackage{algpseudocode} \allowdisplaybreaks \def\BibTeX{{\rm B\kern-.05em{\sc i\kern-.025em b}\kern-.08em T\kern-.1667em\lower.7ex\hbox{E}\kern-.125emX}} \def\endtheorem{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \def\endlemma{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \def\endproposition{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \def\endexample{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \def\endremark{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \def\enddefinition{\hspace*{\fill}~$\square$\par\endtrivlist\unskip} \begin{document} \history{Date of publication xxxx 00, 0000, date of current version xxxx 00, 0000.} \doi{10.1109/ACCESS.2017.DOI} \title{My title} \author{\uppercase{Mohammad}\authorrefmark{1}} \address[1]{Department of Electrical and Computer Engineering (e-mail: myemail@mydomain.edu)} \markboth {Author \headeretal: Preparation of Papers for IEEE TRANSACTIONS and JOURNALS} {Author \headeretal: Preparation of Papers for IEEE TRANSACTIONS and JOURNALS} \corresp{Corresponding author: Mohammad} \newcommand{\ty}{\color{yellow}} \newcommand{\tb}{\color{blue}} \newcommand{\tr}{\color{red}} \newcommand{\tg}{\color{green}} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{abstract} My abstract ... \end{abstract} \begin{keywords} My keywords ... \end{keywords} \titlepgskip=-15pt \maketitle \section{Introduction} \label{sec:introduction} \PARstart{T}{his} is my document. %\appendices %\input{Appendix} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \bibliographystyle{IEEEtran} \bibliography{IEEEabrv, refs} \EOD \end{document}
When I include a \usepackage{forest} all colored text title, section headings disappears with IEEE Access journal template How can I tackle this problem?
I am working in a project with both QGis and ArcGIS. I do mostly cosmetic work and digitalize with QGIS then transfer the shapefiles on ArcGIS. At work I am the only one to work on QGIS, the other members have ArcGIS, (not our choice, question of tight budget). This also mean I have no support, no one is familiar with the program. This worked fine as long as I was only transfering ready files to ArcGIS, but lately I worked for a short time on the files in ArcGIS (I projected the files and edited) and eventually I had to take back the files from ArcGIS and edit further with QGIS. When I send back those files in ArcGIS they are messed up. The edited shapefiles are right on QGIS (topology fine, TOC fine), but on ArcGIS I have "fantoms" polygons or objects (without any geometry) AND overlapping polygons: the old version of the edited polygon/object plus the new polygon/object. Though I have a column with unique IDs to help sort that out, some of the fantoms/old polygons get a "0" for ID some other the same ID as the original polygon. So I delete the mistakes in ArcGIS, the file is fine according to ArcGIS. I double check on QGIS, and surprise, I am now missing polygons there! This is becoming a big mess, and I am unable to understand where are my mistakes coming from so I can avoid them in the future. I also have problems with special signs (Swedish signs, ö, ä, å) translating in other signs or letters from on program to the other. I have made some reference excel table to join to the gibberish TOC, but when constantly editing, it is complicated to keep track of the newest version. Any other solution is welcome!
This tiny little script deletes all small features in all layers. This works fine but the size of .shp files are not reduced. Please tell me why... canvas = iface.mapCanvas() expr = QgsExpression("$length<100") for l in canvas.layers(): l.startEditing() it = l.getFeatures(QgsFeatureRequest(expr)) for ft in it: l.deleteFeature(ft.id()) l.commitChanges()
Is it a way to create a document in such a way that the numbering of the sections is independent of that of the chapters? e.g.: Chapter 1 section 1 section 2 Chapter 2 section 3 section 4 section 5 Chapter 3 section 6 section 7
Some document elements (e.g., figures in the book class) are numbered per chapter (figure 1.1, 1.2, 2.1, ...). How can I achieve continuous numbering (figure 1, 2, 3, ...)? And vice versa: Some document elements (e.g., figures in the article class) are numbered continuously. How can I achieve per-section numbering? \documentclass{book}% for "vice versa" variant, replace `book` with `article` \begin{document} \chapter{foo}% for "vice versa" variant, replace `\chapter` with `\section` \begin{figure} \centering \rule{1cm}{1cm}% placeholder for graphic \caption{A figure} \end{figure} \end{document} Bonus question: Is it possible to adjust the numbering of the sectioning headings themselves? Can I, e.g., switch from per-chapter to continuous numbering of sections in the book class?
I tried the following int number = ThreadLocalRandom.current().nextInt(1000, 9999 + 1); But it won't generate 4 digit numbers like 0004,0035 and so on... I searched for similar questions but none solved, they were different from what I need, if there's already an existing question please let me know. I need no genarate numbers like 1485 and 0180, not only numbers starting with 0.
How do you left pad an int with zeros when converting to a String in java? I'm basically looking to pad out integers up to 9999 with leading zeros (e.g. 1 = 0001).
As requested, I am asking the here. Is there a way to find a load on my web application server without a load / stress testing? I have deployed my application in the Apache Tomcat server. As per as I know, each web server have some limitations on serving a request, beyond which, performance degrades. e.g. If a server can handle 800 requests happily, concurrently, the more requests landing on the server will get delayed response, or may be dropped. I am looking for some alerting mechanism by which I will get to know that the load on my web server has crossed the threshold limit, and accordingly I will able to take the required actions like e.g. adding one more node behind load balancer to distribute the load.
This is a about Related: I have a question regarding capacity planning. Can the Server Fault community please help with the following: What kind of server do I need to handle some number of users? How many users can a server with some specifications handle? Will some server configuration be fast enough for my use case? I'm building a social networking site: what kind of hardware do I need? How much bandwidth do I need for some project? How much bandwidth will some number of users use in some application?
I wish to ping three local devices, every 5 min, without stopping, from a Raspberry Pi running Raspbian OS. When my Pi powers on, I want that to automatically start. I saw an about it, but not sure where to start.
I'd like to run a command at startup which pings a certain address every 10 minutes and writes the result to a file. I've figured out now how to do the pinging and file writing and the 10 min intervals: while true; do my-command-here; sleep 600; done My question is, can I put this in /etc/init.d/rc.local or should I be putting it in /etc/rc.local or somewhere else entirely? I'm specifically concerned because it's an infinite loop so I'm not sure if I could put it in one of these startup scripts. Some help would be appreciated. I'm using Ubuntu 12.04.5
This is actually a Lipschitz function, so thought I should show that it's a Cauchy sequence. I assumed that $f(x_n)=x_{n+1}$. Putting $x=x_{n-1}$ and $y=x_{n-2}$, we get $$|f(x_{n-1})-f(x_{n-2})| \le \frac 12 |x_{n-1} - x_{n-2}|$$ This gives us, $$|x_n - x_{n-1}| \le \frac 12 |x_{n-1} - x_{n-2}|$$ Which ultimately gives that $$|x_n - x_{n-1}| \le \frac{1}{2^{n-2}} |x_2-x_1|$$ Now, I don't know how to proceed from this.....
I'm interested in convergence of $f(x_n)=x_{n+1}$ and often hear this term referenced. What does it mean to be a contraction mapping in the context of the sequence of real numbers given by $f(x_n)=x_{n+1}$? And what does it tell us about such sequence? A search online gives the answer given by Wikipedia, that it is a function $f$ defined on a metric space $(M,d)$ from $M$ to itself with the property that for some real number $k \in [0,1)$, $$d(f(x),f(y)) \leq k d(x,y)$$ This definition is quite unhelpful because I barely know what a metric space is. I feel like this definition is to generalized, and I'm interested in in the specific case of recursively defined real sequences $f(x_n)=x_{n+1}$ that there should be a more specific answer to my question.
This is probably a very simple question but I am new to C# and can't figure out how to get the value of my enum? public enum Status { OK, Bad, } I want to display it as follows (hard coded at the moment): public Task<ResultData[]> GetResults() { var dummyData = new ResultData(); dummyData.Title = "title"; dummyData.Status = Status.OK; dummyData.Value = 5; var results = new ResultData[] { dummyData }; return Task.FromResult(results); } However this shows the status as 0 not OK. I want it to show OK in the array when I use this GetResults() method. I have tried Status.OK.ToString() as many other posts have suggested but I get the error that it cannot convert the string to the type Status. I have looked at other articles but cannot seem to figure out a simple way of doing this - can anyone assist? Thanks
Which is the preferred way to convert an Enum to a String in .NET 3.5? Enum.GetName Enum.Format ToString Why should I prefer one of these over the others? Does one perform better?
My original objective was to find the arc length of $\sin x$ on the interval $[0, 2\pi ]$. Of course the traditional way to calculate arc length is to use the formula: $$L = \int_a^b \sqrt{1 + (f'(x))^2} dx$$. And so obviously the formula becomes in this case: $$\int_{0}^{2\pi} \sqrt{1 + \cos^2 x} \ dx$$ But I am stuck here. Does anyone know of any analytical methods to anti-differentiate $\sqrt{1 + \cos^2 x}$, if any exist at all?
What is the length of a sine wave from $0$ to $2\pi$? Physically I would plot $$y=\sin(x),\quad 0\le x\le {2\pi}$$ and measure line length. I think part of the answer is to integrate this: $$ \int_0^{2\pi} \sqrt{ 1 + (\sin(x))^2} \ \rm{dx} $$ Any ideas?
My knowledge in vector space and quantum mechanics is weak and I am trying to understand and make sense of the question that I asked. It will be very helpful if someone could explain it to me in a conceptual and deeper sense.
In , why is it that a self-adjoint operator is linked to an observable? What makes it measureable? And why isn't a non-Hermitian operator linked to an observable? Also, what type of observables are we talking about here? Particles?
I've come to like starting all my sessions with a prompt $D$H$H$H$H$H$H$H$H$H $T$H$H$H $P $_ Is there a way to just save it so it does it itself?
How can I permanently change the contents of the command prompt under Windows 7? I know about the prompt command, and the , but I'm not sure where to save the custom prompt so that it's used every time. Old web pages say autoexec.bat, but that seems to be an uneditable dummy file under 7.
"Do you know why they act like that?" Do native speakers pronounce the "t" after the "c" and before the "l" in the sentence above? I'm under the impression that they don't do it and just say "ac like that." Is this just my impression?
when the phrase "Can't complain" is pronounced [ˈkænt kəmˈpleɪn] I think that the T is dropped in fast speech because of the alveolar plosives. Right? I read that when T comes before these letters: / s, f, n, l, p, k / it's silent. I know that in American English the T is held in "I can't do it" but above I'm talking about dropping it completely. I recorded myself: Does it sound okay?
I decided to dual boot Ubuntu 14.04 with Windows 8. Everything went right during the process (partitioning, installing, etc) but upon rebooting my laptop (my laptop is an HP Pavilion G6) it booted straight into Windows 8 with no GRUB menu to be seen. I attempted to use boot repair on Ubuntu and that failed; I also tried to change the boot order in the BIOS although I'm not really sure what I'm doing there so I don't know if I did it right or not. Some help would be brilliant as I'm not sure how to go about getting the GRUB menu back!
I have installed Ubuntu 15.10 alongside Windows 10 with UEFI. To install Ubuntu, I chose the option install alongside Windows 10 or something similar to this. Then I created a new partition for Ubuntu and installed it. After installation, the boot menu did not show up. Initially I thought Ubuntu has not been installed, but when I plugged in the USB drive and wanted to install Ubuntu I saw an option of reinstalling Ubuntu on my machine. So, I found out that Ubuntu is installed. Pressing F8 and F12 also does not help. Can anyone help me bring up the GRUB boot menu? In Windows, I also entered the command bcdedit /set {bootmgr} path \EFI\ubuntu\grubx64.efi in cmd, but still the boot menu does not show up. Reply (Himanshu) : Just boot in bios and, if you can, add boot option with name say ubuntu and path EFI/ubuntu/shimx64.efi. No need for live PCB or anything. Move the boot option to top. This is for dell GUI bios but I assume it works for all. Or you may want to see or , where you can enable Windows Boot Loader for one boot or forever as you wish, and boot Ubuntu from it. If you want now, you can use the installed Ubuntu terminal to use the commands update-grub to use GRUB instead. (Not enough reputation to answer properly btw.)
I coded my own website and uploaded to a host. Some days ago I realized that in front page suddenly redirects to an unknown websites, until 3-4 redirects. The redirects ends up at: http://59016823.g05.info/?p=NGNmN2JjNTYyNmIwMGE3YTU5MjgzNmNiOWNjOWMzNGF8MXxEaXJlY3RMaW5rfFRYbFBZbVoxWTJGMFpTQkNiMlI1VEdGNVpYST18MTAwMHw1OTAxNjgyMw==
This is a about Server Security - Responding to Breach Events (Hacking) See Also: Canonical Version I suspect that one or more of my servers is compromised by a hacker, virus, or other mechanism: What are my first steps? When I arrive on site should I disconnect the server, preserve "evidence", are there other initial considerations? How do I go about getting services back online? How do I prevent the same thing from happening immediately again? Are there best practices or methodologies for learning from this incident? If I wanted to put a Incident Response Plan together, where would I start? Should this be part of my Disaster Recovery or Business Continuity Planning? Original Version 2011.01.02 - I'm on my way into work at 9.30 p.m. on a Sunday because our server has been compromised somehow and was resulting in a attack on our provider. The servers access to the Internet has been shut down which means over 5-600 of our clients sites are now down. Now this could be an FTP hack, or some weakness in code somewhere. I'm not sure till I get there. How can I track this down quickly? We're in for a whole lot of litigation if I don't get the server back up ASAP. Any help is appreciated. We are running Open SUSE 11.0. 2011.01.03 - Thanks to everyone for your help. Luckily I WASN'T the only person responsible for this server, just the nearest. We managed to resolve this problem, although it may not apply to many others in a different situation. I'll detail what we did. We unplugged the server from the net. It was performing (attempting to perform) a Denial Of Service attack on another server in Indonesia, and the guilty party was also based there. We firstly tried to identify where on the server this was coming from, considering we have over 500 sites on the server, we expected to be moonlighting for some time. However, with SSH access still, we ran a command to find all files edited or created in the time the attacks started. Luckily, the offending file was created over the winter holidays which meant that not many other files were created on the server at that time. We were then able to identify the offending file which was inside the uploaded images folder within a website. After a short cigarette break we concluded that, due to the files location, it must have been uploaded via a file upload facility that was inadequetly secured. After some googling, we found that there was a security vulnerability that allowed files to be uploaded, within the ZenCart admin panel, for a picture for a record company. (The section that it never really even used), posting this form just uploaded any file, it did not check the extension of the file, and didn't even check to see if the user was logged in. This meant that any files could be uploaded, including a PHP file for the attack. We secured the vulnerability with ZenCart on the infected site, and removed the offending files. The job was done, and I was home for 2 a.m. The Moral - Always apply security patches for ZenCart, or any other CMS system for that matter. As when security updates are released, the whole world is made aware of the vulnerability. - Always do backups, and backup your backups. - Employ or arrange for someone that will be there in times like these. To prevent anyone from relying on a panicy post on Server Fault.
I have several "ArrayList" Like this: ArrayList<Integer> list1; ArrayList<Integer> list2; ArrayList<Integer> list3; list1: [0,1,2] list2: [22,12,23,24,53] list3: [21,43,21,7] I want to put all elements of all lists into one ArrayList like sumList [0,1,2,22,12,23,24,53,21,43,21,7] How is that to be done? thx u
Conditions: do not modify the original lists; JDK only, no external libraries. Bonus points for a one-liner or a JDK 1.3 version. Is there a simpler way than: List<String> newList = new ArrayList<String>(); newList.addAll(listOne); newList.addAll(listTwo);
Is it supposed to look differently in a list? Some examples: keyword keyword keyword ← this looks weird keyword keyword ← and this keyword keyword keyword ← this too
Looking at the following screenshot of , you'll notice a slight difference in padding of inline code inside normal paragraphs and that of code inside of lists: The same is true for inline code within comments appearing in my recent activity tab, e.g. whereas in the original comment the padding looks correct: Firebug said to me that there is a CSS rule for this: .comment-text code { padding: 1px 5px; } (as well as p code for normal paragraphs), but this isn't applied to inline code in lists, nor in the activity tab. I can imagine that this is done to save space within lists and the recent activity tab, but at least it doesn't look consistent.
Pi is infinite, but not random. 1/3rd for example is certain not to contain a 4, but i found my full birthday in Pi. Is there proof that every conceivable combination of numbers, such as all Natural numbers in order? I'm having a hard time imagining how all natural numbers could have something before and after them though so can it be proven that every finite numbercombination is found in Pi, such as every birthday of every person in chronological order and everyones creditcard pin and then some. Or is it likely/unlikely/impossible(or impossible to tell)? I'm asking out of my own curiosity.
I came across the : Which states: $\pi$ Pi Pi is an infinite, nonrepeating $($sic$)$ decimal - meaning that every possible number combination exists somewhere in pi. Converted into ASCII text, somewhere in that infinite string of digits is the name of every person you will ever love, the date, time and manner of your death, and the answers to all the great questions of the universe. Is this true? Does it make any sense ?
I have re-installed Ubuntu from 16.04LTS 64 bit to 14.04LTS 64 bit. I have lost the previous partitions (NTFS) and now, Ubuntu recognises everything as single partition. Can some one advice the recovery steps to get the old partition table?
I have a Toshiba satellite A-200 laptop with a Vista OS on it with 4 NTFS partitions (C:) Vista (D:) Entertainment (E:) Work (F:) Sources and I wanted to start using Ubuntu instead. So I tried it first from the live CD and everything was OK and all the partitions were shown and working and so I decided to install Ubuntu to replace Vista on the (C:) drive. After I did that I can no longer find my folders and files on the (D:), (E:), (F:) partitions and the only file system that is shown is one 198 GB although my HDD is 320 GB. I can't access the lost data on the remaining 120 GB which I hope is still there and not totally lost I am now working from the live CD but I am unable to install testdisk. Can I recover the Vista partitions by the product recovery CD to get my laptop back to the factory settings? Can I recover the NTFS partitions using a recovery program for Windows or will that make the problem worse? I need these data badly as I don't have a backup for them.
I need to find a combinatorial proof of this identity $$\sum_{k=0}^{n}(-1)^{k}\binom{n}{k}\binom{2n-2k}{n-1}=0.$$ I think inclusion exclusion is the best method here. But I"m having a really hard time coming up with a set to count. Permutations don't work here. A hint would be really nice. Thanks.
How do I prove the following identity: $$\sum_{k=0}^{n}(-1)^k\binom{n}{k}\binom{2n - 2k}{n - 1} = 0$$ I am trying to use inclusion-exclusion, and this will boil down to a sum like inclusion-exclusion, and the $\binom{2n-2k}{n-1}$ term wouldn't matter (it will be equivalent to set sizes). Is this a correct way to go?
Surface tension has really made me crazy! Surface tension occurs at the interface of air & water. It is a force per unit length tangential to the intersurface. But what actually causes it? One explanation is that there are very less no. of molecules on the interface, remaining far away from each other. Due to this, greater attractive force does exist which causes surface tension. Now, the question is why the density is low. Another explanation that my book also vaguely offers is the asymmetric downward force on the water interface. But question evidently arise, if the force is downward, how can it produce a tangential surface tension?? Now, what should be the answer to these mind-chocking questions? And are these explanations linked with each other( which I greatly believe)??
A text says: The surface tension of a liquid results from an imbalance of intermolecular attractive forces, the cohesive forces between molecules: A molecule in the bulk liquid experiences cohesive forces with other molecules in all directions. A molecule at the surface of a liquid experiences only net inward cohesive forces If this is the case: Why is surface tension considered or experienced as a force parallel to the interface while it is so obvious that it must be perpendicular to it?
How does the unix command line program know what file to read? For example: cat someFile | foo How does the program foo know which file to read, and which process is responsible for opening and reading the file from disk?
When I just used pipe in bash, I didn't think more about this. But when I read some C code example using system call pipe() together with fork(), I wonder how to understand pipes, including both anonymous pipes and named pipes. It is often heard that "everything in Linux/Unix is a file". I wonder if a pipe is actually a file so that one part it connects writes to the pipe file, and the other part reads from the pipe file? If yes, where is the pipe file for an anonymous pipe created? In /tmp, /dev, or ...? However, from examples of named pipes, I also learned that using pipes has space and time performance advantage over explicitly using temporary files, probably because there are no files involved in implementation of pipes. Also pipes seem not store data as files do. So I doubt a pipe is actually a file.