Can "literally" correctly describe something presented as not being literal?

Not that I expect to find English used correctly in spam email but I recently received a message with the following subject line:  This Literally “Scrubs” The Air In Your Home  I'm willing to accept the use of the quotation marks as scare quotes to indicate that the product doesn't actually scrub the air. But is Literally actually being used correctly since, assuming that the product works as implied, it would literally "scrub" the air even if it doesn't literally scrub it? If so, would the following subject line have the same meaning as the original and also be "correct?"  This "Literally" Scrubs The Air In Your Home  I admit that it might be best to avoid both of these lines but I like them more than the way "literally" is so often incorrectly used.


How to handle data imbalance in classification?

I am working on a text classification problem. My data is highly imbalanced. For example, one category has 700 documents while the other has 30. I have around 30 categories. I tried different classifiers and the performance is consistently poor.  What is the best way to tackle this issue? Thanks


Link:  What I'd like to do is make it so the text that appears on top in the dark green bar would appear vertically aligned to the image, and not this weird alignment that I can't figure how I've made... Here is the html:   @media screen and (max-width: 425px){   #message{font-size:10px;}   .shippingimage{display:none;} } .ShowHide {   overflow: hidden;   background-color: #2a4735;   color: white; } #left-showing {   overflow: hidden; } #right-showing {   float: right;   width: 30px;   text-align: center; } .ShowHide a {    color: white;    text-decoration: none; } .ShowHide a:hover {    text-decoration:underline; }

     X


Root folder on my Ubuntu 16.04 with an (X)

I formatted my notebook just now and I installed Ubuntu LTS 16:04, and the folder /root shows with a (X).  Question 1: Why?  Question 2: How to solve this problem?    Notebook-  Dell Vostro-14-5480 Memory-    4GB Processor- i3 HD-        500


Broken packages for MikTex in 18.04, trouble upgrading them?

When installing MikTex () I am getting the message:  The following packages have unmet dependencies.  miktex : Depends: libhunspell-1.3-0 (>= 1.3.3) but it is not installable           Depends: libicu55 (>= 55.1-1~) but it is not installable           Depends: libmpfr4 (>= 3.1.3) but it is not installable           Depends: libpng12-0 (>= 1.2.13-4) but it is not installable  E: Unable to correct problems, you have held broken packages.   I have tried:  sudo apt get upgrade && sudo apt get update   But still get the same message. Is it that the packages are not compatible with 18.04? Is there a way around this?


I have the problem that the shorting of authors in text citation is not working when I have two citations of the same first author. If I only cite one of the two, then it works properly. Does anyone know what's the reason for this behaviour and how I can change it? I want et al. all the time. Here I isolated the problem: \documentclass[12pt,twoside]{report}  \setlength{\headheight}{15pt}   \usepackage[ngerman]{babel} \usepackage[autostyle]{csquotes} \usepackage[babel]{microtype} \usepackage[   style=authoryear,    autocite=inline,    maxcitenames=2,    maxbibnames=99,    backend=biber, %--->führt (zeitweise?) zu fehler     dashed=false ]{biblatex} \DeclareFieldFormat{titlecase}{#1} % - titel bleibt unverändert ... auch better bibtex checken wenn was nicht stimmt (export) \addbibresource{references_promotion.bib}  %damit auch bei \citeyear, also ohne klammern der hyperref kommt \DeclareCiteCommand{\citeyear}     {}     {\bibhyperref{\printfield{year}}}     {\multicitedelim}     {}    % Doppelpunkt nach dem Jahr im Literaturverweis \renewcommand*{\postnotedelim}{\addcolon\space}  % Seitenangabe ohne automatischen Zusatz \DeclareFieldFormat{postnote}{#1} \DeclareFieldFormat{multipostnote}{#1}  \DefineBibliographyStrings{ngerman}{    andothers = {{et\,al\adddot}} }   \begin{document}  \textcite{claussEinsatz2013} \textcite{nidiekbe2019} \textcite{nidiekNachschlag2020a}  \printbibliography   \end{document}  Here is the bibtex: @article{claussEinsatz2013,   title = {Der Einsatz des iPads als Instrument in der Musiktherapie},   author = {Clauß, Tobias and Seideneck, Mario and Gatzsche, Gabriel},   date = {2013},   journaltitle = {Musiktherapeutische Umschau},   volume = {34},   pages = {362--369},   number = {4} }  @incollection{nidiekbe2019,   title = {be\_smart: Zur Bedeutung von Musik-Apps für die Teilhabe von Jugendlichen und jungen Erwachsenen mit komplexen Behinderungen an Kultureller Bildung},   booktitle = {Forschung zur Digitalisierung in der Kulturellen Bildung},   author = {Nidiek, Imke and Gerland, Juliane and Hülsken, Julia and Sieger, Marvin},   editor = {Jörissen, Benjamin and Kröner, Stephan and Unterberg, Lisa},   date = {2019},   pages = {37--48},   publisher = {kopaed},   location = {München},   langid = {german},   series = {Kulturelle Bildung und Digitalität \#1} }  @article{nidiekNachschlag2020a,   title = {Nachschlag zu Heft 1/2020. Mehr Teilhabe an Kultureller Bildung durch digitale Musikinstrumente},   author = {Nidiek, Imke and Gerland, Juliane and Hülsken, Julia},   date = {2020},   journaltitle = {Gemeinsam leben},   volume = {2},   pages = {123--128},   number = {2} }


HDIO get identity failed for dev/sdb invalid argument

This failure is on an external hard drive connected by USB.  However, it worked flawlessly for several days.    Then, one day when I tried to start Ubuntu there appeared a Debian splash screen with grub menu.  When I selected the appropriated boot item from menu screen goes black and the above mention error appeared and never finished the boot process.  Process hung there.    I have read and reread all the forum topics on this subject.  All I really find is discussion about it may be this and may be that, but no fixes.  Found one "work around" that did not work.    Someone must know what to do about this.  The suggestions about what it might be doesn't help.  System won't boot and even if the suggestions were accurate, still no mention of how to correct the problem.  Can anyone help?


How can I receive notifications about favorite questions?

I have read many questions about the topic. Apparently if I favorite a question, I should get notifications about it, but it's currently not the case. Apparently, there is a checkbox in the prefs tab of my profile about it. What I see is "Allow email notifications when I subscribe to questions or tags", which I have checked.  Unfortunately, I don't seem to understand how it works: I favorite questions, they get comments, edits, answers, and I am not notified in any way.  I saw info saying that this kind of feature is broken, but it was about a year ago. Certainly I've missed some stuff?  What am I doing wrong? How can I get updates about those questions I'm not involved in (without subscribing to individual RSS feeds)?


Change size of figure "removes" points in Matplotlib

I try to adjust the size of my figure. However, the moment I do that, by adding plt.figure(figsize=(10,5)) I don't see the dots anymore. The reason I want to change the size is mainly because of ylabel is not shown the way it is now.    import pandas as pd import matplotlib.pyplot as plt import numpy as np from sklearn import linear_model  # Check out the Data df = pd.read_csv("https://s3.amazonaws.com/codecademy-content/programs/data-science-path/linear_regression/honeyproduction.csv") # print(df.head()) # print(df.columns)  prod_per_year = df.groupby(['year']).totalprod.mean().reset_index() # print(prod_per_year)  X = prod_per_year['year'] X = X.values.reshape(-1, 1) y = prod_per_year['totalprod']  plt.scatter(X, y) plt.xlabel('Year') plt.ylabel('Total production') plt.show()  # Create and Fit a Linear Regression Model regr = linear_model.LinearRegression() regr.fit(X, y)  # Print out the slope (regr.coef_) and the intercept (regr.intercept_) print(regr.coef_) print(regr.intercept_)  y_predict = regr.predict(X) plt.figure(figsize=(10,5)) plt.plot(X, y_predict) plt.show()


"Occasionally, I receive requests that does not meet our requirements" - "does not" or "do not" should be used in this context?


Managing error with GPS routes (theoretical framework?)

I'm looking for the appropriate theoretical framework or speciality to help me deal with understanding how to deal with the errors that the GPS system has - especially when dealing with routes.  Fundamentally, I'm looking for the requirements on the data and any algorithms to use to be able to establish the length of a trail. The answer needs to be trustworthy.  A friend of mine was the race director of a race which was billed as 160km but the Garmin watches everybody has makes it more like 190km+. It caused quite some grief at the finish line, let me tell you!  So my friend went back to the course with various GPS devices in order to remap it and the results are interesting.  Using a handheld Garmin Oregon 300 she got 33.7km for one leg. For the same leg on a wrist watch Garmin Forerunner 310xt it came out to 38.3km.  When I got the data from the Oregon it was obvious that it was only recording data every 90 seconds or so. The Forerunner does it every couple of seconds.  When I plotted the data from the Oregon I could see that it got confused by some switchbacks and put a line straight through them and a curve was made a little less.  However, I muse that the difference in the recording frequency is much of the explanation. i.e. by recording every couple of seconds the Forerunner is closer to the real route. However, there will be an amount of error because of the way GPS works. If the points recorded are spread around the real route randomly (because of the error) then the total distance will be larger than the real route. (A wiggle line going either side of a straight line is longer than the straight line).  So, my questions: 1. Are there any techniques I can use on a single dataset to reduce the error in a valid way? 2. Does my theory about the difference in recording frequency hold water? 3. If I have multiple recordings of the same routes are there any valid techniques to combine them to get closer to the real route?  As I say, I don't really know what to search for to find any useful science about this. I'm looking for ways to establish just how long a given piece of trail is and it is very important to people. An extra 30km in a race is an extra 5+ hours we weren't expecting.  As requested here is some sample data:       Thanks for any advice you can give.


I've found an interesting floating point problem. I have to calculate several square roots in my code, and the expression is like this:  sqrt(1.0 - pow(pos,2))   where pos goes from -1.0 to 1.0 in a loop. The -1.0 is fine for pow, but when pos=1.0, I get an -nan. Doing some tests, using gcc 4.4.5 and icc 12.0, the output of   1.0 - pow(pos,2) = -1.33226763e-15   and   1.0 - pow(1.0,2) = 0   or  poss = 1.0 1.0 - pow(poss,2) = 0   Where clearly the first one is going to give problems, being negative. Anyone knows why pow is returning a number smaller than 0? The full offending code is below:  int main() {   double n_max = 10;   double a = -1.0;   double b = 1.0;   int divisions = int(5 * n_max);   assert (!(b == a));    double interval = b - a;   double delta_theta = interval / divisions;   double delta_thetaover2 = delta_theta / 2.0;   double pos = a;   //for (int i = 0; i < divisions - 1; i++) {    for (int i = 0; i < divisions+1; i++) {      cout<<sqrt(1.0 - pow(pos, 2)) <<setw(20)<<pos<<endl;       if(isnan(sqrt(1.0 - pow(pos, 2)))){       cout<<"Danger Will Robinson!"<<endl;       cout<< sqrt(1.0 - pow(pos,2))<<endl;       cout<<"pos "<<setprecision(9)<<pos<<endl;       cout<<"pow(pos,2) "<<setprecision(9)<<pow(pos, 2)<<endl;       cout<<"delta_theta "<<delta_theta<<endl;       cout<<"1 - pow "<< 1.0 - pow(pos,2)<<endl;       double poss = 1.0;       cout<<"1- poss "<<1.0 - pow(poss,2)<<endl;     }    pos += delta_theta;  }   return 0;  }


I have following simple html block:   By list   Then, I have following js-code:  $(document).ready(function() {     $('.show-list').click(function() {         console.log('qwe');     }); });   When I click on it - nothing happens. But when I paste this js-code to Google Chrome JS console, it works perfectly. JS works fine on my site, I can make other JQuery actions. I also tried to write $('.change_ordering.show-list') and $('span.change_ordering.show-list') and $('span.show-list'), but still no progress. What I'm missing?  EDIT: This element is not drowing by ajax. I don't understand why it's duplicate.


Could TeX.SE put on a showcase of scientific posters?

Could the people of the TeX.SE put on a showcase of scientific posters made with (La)TeX? I have seen other showcases on here,  for example. However, with a large number of people using (La)Tex for scientific publications (which often end up as posters), I think it would be valuable for such a thing to exist.


Is it possible to set an SSLProtocol in Apache for a single VirtualHost (poodle)?

I'm trying to test a patch for the  that involves disabling SSLv3 on my web server. In order to test this on a non-production environment first, I'm setting the SSLProtocol on a VirtualHost for a different test server. My config looks something like this:  <VirtualHost *:443>     SSLEngine On     SSLProtocol All -SSLv2 -SSLv3     ServerName test.mysite.com     # bunch of other stuff omitted </VirtualHost>   However even after restarting apache my test site is still claimed to be vulnerable. Is this expected to work? I'm wondering if I have to set it in the global ssl config or whether there's something else subtle that's causing the setting not to take and/or work.


Is it possible to access the alignment of the view from python? (e.g 'TOP', 'FRONT', 'RIGHT', etc.)  I looked in the api docs, but the closest I could find was .


So There is no simple group of order $2187$?

I have a group of order $2187=3^7$. I used Sylow's theorem and got Sylow 3-subgroup as my group. How do I continue?


How to understand the Bilinear mapping with an example

An efficient bilinear map is given by  $ e $: $G_{1}$ × $G_{1}$ → $G_{T} $.  How can i prove this equation with the help of an example.


It follows from Zorn's Lemma that every vector space $V$ has a basis (this means, a subset $B$ of $V$ that generate any $v \in V$ by means a finite linear combination, and such that $B$ is LI) . But, seems quite impossible to me to find a basis for $\mathbb{R}^{\infty}$; I have listened somewhere that is really impossible find an actual basis for this space, because of something that I don't remember.   There exist a concrete basis? There exists some reason for we never shall find one?


How do I convert a SMP server world into a Single-player compatable world?

I had a Minecraft world on Minefold.  I archived my Minecraft world just before Minefold closed about a year ago.  I'm trying now to open the world in my local Minecraft installation on OS X, but it doesn't show up in the worlds list.  To import it, I simply unzipped the archive from Minefold into my ~/Library/Application Support/minecraft/saves folder.  I'm running Minecraft 1.8, and I don't have any mods installed.  There's no error; the world just doesn't show up in my list of worlds after I click [Singleplayer] (or [Multiplayer]).  Now, the big clue is that the directory structures are different between my locally-created worlds and the world created on Minefold, but I can't figure out how to adapt the files to make them match:  This is a screenshot of my saves folder. I've circled in blue "local" and "minefold", which contain data files for the local and Minefold worlds, respectively.    I bracketed similar filenames in both worlds, but I'm flummoxed in that the Minefold version has three (3) sets of data files, whereas the local world has only one (1) set of files (even though I have visited Nether in the local world).  How do I load my old Minefold world locally?


I would like like to get the scroll position of a tbody in a lightning component, what's the supported way to do this?   cmp.find('myComponent').getElement().scrollTop is undefined. If I do this in pure javascript it works fine, but there's something funny going on in lightning. I thought reading the dom was acceptable. Thanks for any insights into this.

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1


Is there any way to identify if my server is HyperV VM or a physical machine

I want to know is there any way to detect that the current server i am using is physical box or Hyper V Virtual machine.  Is there any thing in windows that could tell me about it? Any setting, registry key in windows ? Or any script that could tell me that?  I do not have physical access to server, only can logon to server.


$\int_0^{\infty}\frac{\ln x}{x^2+a^2}\mathrm{d}x$ Evaluate Integral

Anyone remember the method for this? I think this should been done on the site $$\int_0^{\infty}\frac{\ln x}{x^2+a^2}\mathrm{d}x$$


Why does $x= \frac{1}{2}(z+\bar{z}) = \frac{1}{2}(z+\frac{r^{2}}{z})$ on the circle?

I some help computing   $$\int_{|z|=r} x \, dz$$  by noting that $x= \frac{1}{2}(z+\bar{z}) = \frac{1}{2}(z+\frac{r^{2}}{z})$ on the circle but I don't understand why this is true. Why does the complex conjugate of $z$ equal this on the circle?


Cant install win10 after Ubuntu 16.04 , gpt error

i have 16.04 installed. i used ubuntu live cd to allocate a new space by dividing root partition.  i put windows 10 usb, did legacy support option and it could see windows instalation.   then i chose my unallocated part from which gparted did in ubuntu live cd  this image shows before this allocation. devsda2 was divided 500 gb and 400 gb. other one is allocated.    but windows did no accept to install that drive.  there were 4 drives. 3 of them were like in the picture.  because it says the disk is gpt. cant do.  "Windows cannot be installed to this disk. The selected disk is of the GPT partition style".    So i make listdisk list part select that partition (it wwas partition 4 there in console but while installing windows screen , there was 3).  i wrote convert mbr inside that prtition but it said cant convert to mbr, only cdroms etc can cause. It was like this. So now i couldnot convert. i cant clean disk because i have ubuntu there.  are thre any ways?


Problems with single quotation mark while inserting

I am having a problem while uploading a string to MySQL database. Here's the things I use:   EditText for user input PHP file that receives string from the application and inserts into the database   The PHP file I use for communication:  <?php  $con = mysql_connect("SERVER","DB_NAME","PASS"); if (!$con)     {     die('Could not Connect:'. mysql_error());     } mysql_select_db("DB_NAME",$con);   mysql_query ("INSERT INTO table_name (id) VALUES('".$_REQUEST['st_Id']."')");  mysql_close($con); ?>   When I try to insert text into the EditText in android and that text includes a quotation marks the operation fails, otherwise the operation is working fine. I guess the problem in the PHP file while receiving the string but I have no idea how to solve it.  Any ideas?


Jamaica visa requirement for Indian citizen

Recently I found from  that a visa is not required to travel to Jamaica for an Indian citizen.   Does that mean I can travel directly to Jamaica with only my passport?  Can anyone clarify why a visa is not required for Indian citizens especially to some countries like Haiti, Nepal, Bhutan, Jamaica, Mauritius, and St. Kitts? Why are these countries allowing people without any visa?


Recursively Pass Template Template To a Template Template Function

It seems to me, that since in C++ we can pass a template template, then a function accepting a template template should be able to pass a (its) template template into itself. However this appears not to be the case.  template< typename PREVIOUS_TYPE_T, typename TYPE_T > struct Node {     typedef TYPE_T TYPE;     typedef PREVIOUS_TYPE_T PREVIOUS_TYPE;     PREVIOUS_TYPE_T* previous;     template< template< typename... > typename FUNCTOR_T, typename... CURRENT_ARGUMENTS_T >     void DoCall() {         previous->DoCall< FUNCTOR_T, TYPE_T, CURRENT_ARGUMENTS_T... >();     } };   Is there anyway to pass FUNCTOR_T above, or any work around to doing so?


For the magnitude of nF or µF capacitors, I hope I can build them on a PCB board. The capacitor is like a two metal layer and something between them.   Is this possible?   Not buying the capacitor, just design the capacitor on the PCB board. Double metal layers on the PCB board.


Can I change 64-bit Windows into 32-bit Windows without reinstalling?

I borrowed a Windows 7 disk from my friend and I thought it was 32bit but it turned out to be 64bit and I only have 2GB of RAM. Since I have some stuff that I would rather not install again because it took a long time, is there a way to make the 64bit Windows a 32bit Windows without reinstalling Windows?


Xubuntu 12.04: Use unity-greeter and set user background automatically

on a fresh Xubuntu 12.04 Installation i have set greeter-session=unity-greeter in    /etc/lightdm/lightdm.conf.   Also I have installed unity-greeter gnome-settings-daemon.  Now I want to change the behavior of unity-greeter to what it does in a vanilla Ubuntu: Change the wallpaper in the greeter to the user-wallpaper.


Could the Bruce Lee scene in "Once Upon a Time in Hollywood" have been imagined?

The infamous Bruce Lee scene with Cliff Booth is framed as a thought sequence as Cliff is fixing a roof antenna. Although presumably the scene was a flashback, the framing actually makes it indiscernible from an imagined scene i.e. a daydream.  The way I interpreted the scene was not "this is what I remember happening," but rather "this is what would probably would happen if I went back to working on movie sets, and it's why I'm fixing roof antennae instead of being on sets."   This certainly fits better with the hyper-unrealistic portrayal of Bruce Lee, since it's a hypothetical sequence.   My question is what, from the movie only (not Tarantino interviews or anything off-screen), indicates that this sequence was actually a flashback and not a dream sequence?  n.b. The scene directly preceding explains that Cliff would have trouble landing a job with this particular movie director for some reason. There are two interpretations of this with the Bruce Lee scene in context. One interpretation is "it's unlikely I would get that job because I dented the car sparring with Bruce Lee" while another is "it's unlikely I would get that job because if I did, I would probably do something like dent his car sparring with Bruce Lee." I don't feel that the movie definitively states which is the right interpretation.


Is it possible to change the linkage of Nether portals?

I have 3 portals that link together, but I want to remove at least the middle one.  Edit for clarification:    The portals I created are 1, 4 and 5, the others were spawned by the game as the "other end". I want to remove the link between 5 and 4 and create a link between 5 and (the yet non-existent) 6.  The goal is to be able to travel to 5 in the route: 1, 2, 6, 5. I don't really need 3 and 4 now.


As I have a broken laptop screen on a unit that does not show the BIOS or Ubuntu DVD installer on an external display, it's pretty difficult to complete the normal method of installation as I can't see what I'm doing, and I need to find and format the right partition, for example, which is waaay too risky to attempt while blind.  The unit in question uses Windows 7. Rumor has it that in the past there was something called Wubi, that allowed installation of Ubuntu from Windows. Does this still exist? If so, where can it be found? If not, is there an alternate way to install from within Windows?  EDIT  According to the  there exists a community-maintained version of Wubi. I've however edited the question to accommodate a general dialogue on how to install on laptops with broken displays who don't use their external display ports before advanced graphics drivers are activated.  Using Samsung NP-N350-JA04, Ubuntu 16.04 mini.iso


What is the meaning of the "at mark" @, also called "Klammeraffe", in LaTeX commands?

I have seen the "at symbol" on several occasions, used in connection with LaTeX macros, often as part of command names. Does this symbol have a special significance in LaTeX, or is it just a convenient special convention?  An example I found at this site is , like this :   begingroup\makeatletter\def\f@size{5}\check@mathfonts $$abc+xyz=44$$\endgroup   If the question has been asked before, a hint or a pointer will be very welcome. Thanks!


Using pagination with specific custom post type

Alright.. I've been looking alot on the internet in search of a solution for this.. so far i found nothing that could explain me how to solve it..   When i click on Page suivant from the navigation div all it does is redirecting me to home page instead of loading the same page and showing the next 12 post from 'bateaux' which has 18 posts in it.  <?php               $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;              $args = array(                 'post_type' => 'bateaux',                 'post_status' => 'publish',                 'orderby' => 'menu_order',                 'posts_per_page' => 12,                 'caller_get_posts' => 1,                 'paged' => $paged             );              query_posts($args);              while (have_posts()): the_post();              $attachment_id = get_field('image_supplementaire_1');              $image_attributes = wp_get_attachment_image_src( $attachment_id );            ?>
             <?php                  if ($attachment_id != NULL)                 {              ?>                 <a href="<?php echo add_query_arg( 'action', 'Consulter', the_permalink()); ?>" title="<?php the_field('titre'); ?>"><img alt="<?php the_field('titre'); ?>" src="<?php echo $image_attributes[0]; ?>" width="155px" height="133px" />             <?php                  }                 else                  {              ?>                 <a href="<?php echo add_query_arg( 'action', 'Consulter', the_permalink()); ?>" title="<?php the_field('titre'); ?>"><img alt="<?php the_field('titre'); ?>" src="<?php bloginfo( 'template_directory' ); ?>/Images/img_default.jpg" width="155px" height="133px" />             <?php                  }              ?>
<?php the_field('titre'); ?>

<?php the_field('prix'); ?>$
             <a href="<?php add_query_arg( 'action', 'Consulter', the_permalink()); ?>" class="details" title="Détails" >Détails
         <?php              endwhile;           ?>

<?php previous_posts_link('&laquo; Page pr&eacute;c&eacute;dente') ?>

<?php next_posts_link('Page suivante &raquo;') ?>

      <?php          wp_reset_query();      ?>   Any tips ?  Thks!


Multi Resolution graphic for ios 4 and ios 5

I have used cocos2d-x to develop a game for iPhone 4, iPhone 4s, iPhone 5 with different screen sizes (3.5 inch and 4 inch)  First, my resource are designed for iPhone 4 and iPhone 4s with 3.5 inch screen size.  So if I want to use for iPhone 5 with 4 inch screen size. what should I do?


Let x be a real number with $|x|<1$, and q be a real number. Show that the series $\sum_{n=1}^{\infty} n^{q}x^{n}$ is absolutely convergent, and that $\lim_{n\to\infty} n^qx^n=0$.  My attempt:   Let $c = n^q$   Then since, $$\sum_{i=m}^{n} (ca_i) = c(\sum_{i=m}^{n} a_i),$$ we can write  $$c\sum_{n=1}^{\infty} x^{n}$$ and by a Lemma concerning geometric series, if $|x|<1$ then $$\sum_{n=1}^{\infty} x^{n}$$ is  absolutely convergent. If it is absolutely convergent it is also conditionally convergent. Now I can use the zero test and we see that the limit of $x^n$ as n->infinity = 0.


How to add a checkbox to a panel header?

I'm trying to find out how to add a checkbox to a panel header so panel can be deacivated (as well as storing that checkbox value in some property). It may be quite obious task, but I didn't find any info about it in the docs so far.  Example of what I'm trying to achive is the "Gravity" panel, that can be turned off with the checkbox.    Any suggestions or leads? I would be grateful for any code examples with it.


Custom exception - checked or unchecked?

When creating a user defined exception What is the best practice, should the exception be created as checked or unchecked ?  I know unchecked/runtime exceptions need not be handled in the code.


Stackoverflow have come to the point (and way beyond) where all geeks and programmers out there would suffer a great deal if it went black tomorrow.  I don't doubt that Stackoverflow have a good backup regime, but a lot of things could happen.  It be great if Stackoverflow had some sort of db-dump feature to mitigate this. It doesn't haveto be a full dump. But a dump with the questions and accepted answers would be almost just as good. It would also be a great offline-search tool for places without internet..  Is this up for consideration?


Precision and accuracy while using double

I understand that when I am increasing precision I should get  more precise result. But that is not quite clear from this example where I have increased the precision, but I am not getting correct result:      #include <iostream> #include <iomanip> int main() {     using namespace std;     cout << setprecision(17);     double dValue;     dValue = 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1;     cout << dValue << endl; }   The output is 0.99999999999999989  Can someone explain me why is this happening ?


I have below list  l1 = [1,2,3,4,5,6,7,8,9]   I want to understand below  result :-  >>> l1 [4:8:-2]   Please explain result of above slicing.


Transfer from Washington National (DCA) to Dulles(IAD)

I'm worried about the time between my connection flights. I'll be flying from Rochester ROC to Washington DCA and then I'll have to change airport and go to IAD Dulles to grab my connection flight to London Heathrow on the 27th of December 2016.  So I'll be landing at 1:15pm in DCA and my flight to London is at 6pm from IAD.   What would be the easiest way to go to IAD airport ?   I'm really nervous to miss my flight and I could definitely use some advice from you guys  Cheers !


my old laptop is i3 2370m dual core 2.4ghz. in the laptop windows 7 os became slow.can i download linux on it.will it become fast with linux os. AND I don't know programming .how could i handle the linux operating systam ?


How find the function $f(f(x)+xy)=f(x)+xf(y),\forall x,y\in R$

Find all function $f:R\to R$ and such $$f(f(x)+xy)=f(x)+xf(y),\forall x,y\in R$$ Let $x=y=0$,then $$f(f(0))=f(0)$$


Is there a penalty for one's edit suggestion being rejected?

As mentioned in , approval of an edit suggestion gives the suggester +2 reputation.  If the suggestion is rejected, does it cost the suggester any rep?


Show that $g(re^{i\theta}) = \sqrt[n]{r}e^{i\frac{\theta}{n}}$ is holomorphic

Let $g:U \rightarrow \mathbb{C}$, be defined for every $r \in (0, \infty)$, and $\theta \in (0, 2\pi)$ as $g(re^{i\theta}) = \sqrt[n]{r}e^{i\frac{\theta}{n}}$.  I have to show that g is well defined and holomorphic without using the Cauchy-Riemann equations. I know that, as $U$ is simply connected, if the 1-Form $w = \frac {g(z)}{z^2+1}$ is holomorphic then it is also local exact (Goursat´s theorem), but I do not really know if this theorem works for this case, as the implication goes to the other direction that I want.  Thank you in advance


I'm trying to print values from the database, containing countrylist. One of the fields in this database is cyrilic. My PHP script looks like this:  include_once("db.php");  $query = mysql_query ("SELECT * FROM country"); $row = mysql_fetch_array($query);  do {     $id = strtolower($row["id"]);     $value = ($row["runame"]);     echo $id . " " . $value . '<br/>'; } while ($row = mysql_fetch_array ($query));   The output from this script looks like this:  ad ??????? ae ???????????? ???????? ??????? af ?????????? ag ??????? ? ??????? ai ????????   So, apparently I need to set UTF-8 for this PHP script... somehow... Does anyone know how to do this? Thank you for your time!


What were the consequences of Voldemort getting the prophecy?

Why was Dumbledore afraid that Voldemort will get the prophecy? Looking at the prophecy I can't see anything that would help Voldemort and give him new information that would be dangerous for the Order.  "The one with the power to vanquish the Dark Lord approaches... born to those who have thrice defied him, born as the seventh month dies... and the Dark Lord will mark him as his equal, but he will have power the Dark Lord knows not... and either must die at the hand of the other for neither can live while the other survives... the one with the power to vanquish the Dark Lord will be born as the seventh month dies...."  Voldemort only knew about the first part. I can't see anything in the second part that would have valuable information. So: Either there is some meaning in it that I didn't understand, or the rest of the prophecy really was useless, and I can't see why Dumbledore would put the Order in danger just to guard the prophecy. Dumbledore might have wanted to trick Voldemort into thinking the prophecy is important and make him waste his time by directing his efforts to the useless prophecy. If you can give me evidence for that it would be great.


Let $A$ be a commutative noetherian ring. Let $M, N$ be $A$-modules, and assume that $M$ is finite over $A$. Let $P$ be a flat $A$-module.  Is it true that there is an isomorphism $\operatorname{Hom}_A(M,N)\otimes_A P \cong \operatorname{Hom}_A(M,N\otimes_A P)$ ?  It appears that it holds at least locally (that is, when $P$ is free). Is it true in general? If so, is there a reference for this?  Thank you!


Alt+tab raises both left and right snapped windows

Recently I switched from Fedora to Ubuntu. I like to work with half windows (for example a terminal on the left side and a chrome on the right). But I have a small issue, when I have chrome maximized and try to raise a terminal on the right side of my screen, it also brings a terminal that is on the left side.   For example: Open windows: 2 terminals(1 left, 1 right), Google Chrome  When switching from Google Chrome to left terminal,  Desired result:   Actual result:   Any idea how I can stop this?


Is it true that $d(x,Y)=d(x,y_0)$ for some $y_0 \in Y$ when $Y$ is closed?

Is it true that if $Y \subset X$ is a closed set and $x \notin Y$ then $\exists$ an element $y_0 \in Y$ $s.t.$ $d(x,Y)=d(x,y_0)$ where $d(x,Y)= inf \{d(x,y) : y \in Y \}$ and $d: X \times X \to \mathbb R$ is a metric.   I was looking the proof of Riesz lemma and something like it came across in it. If the above is true then I will get some result in the proof.  Please someone help..  Thank you..


Can I set an app to ignore Do Not Disturb?

I have an app that informs me of critical events - for example, scheduled automated tasks failing.  But when I set my phone to Do Not Disturb, this app goes silent as well.  Is there a way I can set this particular app to play sounds even if my phone is on Do Not Disturb?


I want to check the disk usage with a readable size (option -h)  [root@iz2ze9wve43n2nyuvmsfx5z /]# du -sh ./* 2>/dev/null | sort -nr 914M    ./var 568K    ./tmp 523M    ./root 496K    ./run 156M    ./boot 37M ./etc 16K ./lost+found 4.0K    ./srv 4.0K    ./opt 4.0K    ./mnt 4.0K    ./media 4.0K    ./home 2.4G    ./usr 0   ./sys 0   ./sbin 0   ./proc 0   ./lib64 0   ./lib 0   ./dev 0   ./bin   It display 568K > 523M  How could I solve the problem?


How to remove unwanted tilt from bezier curve path

I'm trying to use an array and a curve modifier to create a simple track along a single bezier curve.    I've run into a small issue though when I try to have the path curve around a corner while also lowering elevation at the same time:      After the sloped turn completes and straightens out, the path becomes tilted despite all control handles having 0 tilt:    After this point, the tilting remains along the path unless I manually tilt in the opposite direction to offset but I don't like this since it seems incorrect and I don't know an exact number to use as a tilt offset.  Tilting doesn't occur if the turn is made while keeping the control handles at the same z-axis height:    How can I ensure the path is always facing straight up along the z-axis (unless I add tilt)?


a parallel notion to bicategory and 2category

How is called the general 2category which has as associator  arbitrary natural transformation rather than a natural isomorphism as for bicategory or idenity for 2category ? I know that this notion for a functor is called lax functor.


Do elves have surnames/family name? For instance what is the surname or famous elves like Galadriel, Arwen, Legolas, ...


We Don't NEED Quantum Gravity because Gravity isn't Even A Force!

Now, I understand the motivation for quantum gravity. I honestly want to work on a theory myself. However, gravity, according to General Relativity, is not a fundamental force of nature. To me, it's just a natural tendency, or an inertial tendency. (I call them this because of the equivalence between inertial mass and gravitational mass and inertia.) Inertia is one of these tendencies, the tendency to resist induced motion. Gravitation is just the natural tendency to follow a geodesic. Not a force. One could argue that It takes only a mass moving through space for inertia to take place, it takes two bodies for gravity to occur. However, this induced motion must have been caused by something else. Just as with the curvature of spacetime. Quantizing gravity is like quantizing inertia. I am aware that there is no "inertial radiation"; however the gravitational radiation needn't be quantized.  It's just ripples in spacetime. If spacetime were quantized, then I am assuming that it'd be a field, with a value for every point in spacetime. With a QFT, we could determine EVERYTHING- every moment time, every point in space- where a particle is, where it's not. This would not only violate the Heisenberg uncertainty principle, but it would be the reason for non-renormalizability of gravity. Infinite solutions that can't be neglected.  On the flip side, one could argue about the high energy situations such as the Planck epoch, where gravity may need extreme modification. Plus, gravity is a field, so it should be quantized. However, as stated by the renormalization issue, this probably wouldn't be true.  We have a theory for the quantum realm and the three fundamental forces of nature, and we have a theory for the two "great inertial tendencies"- inertia and gravitation.   The Question: Given the info provided above, do we really NEED a quantum gravitational theory, (save for the high energy scenarios)  P.s. What is wrong with putting QFT in curved spacetime? (which I am aware is one of the main needs of the theory, but we don't truly need a graviton, after all, all the fields in the standard model have the natural tendency to follow a geodesic, so this tendency should be added in anyways!)


What is the red and white circle that appears when I left click?

When I click with the left mouse button, a white and red circular scope-target-looking-pointer moves to the location of the click. I can't make any sense of it and would like to find it in the manual. What is it called?


When there are more variables than observations do shrinkage methods (such as Ridge and Lasso) always find a solution?

Assume we have $n$ observations and $p$ explanatory variables we want to model. To apply ridge regression, we choose a constraint parameter $\lambda \geq 0$ and estimate the coefficients $\beta_i$ which minimise: \begin{equation} \sum^{n}_{i=1} \left( y_i - \beta_o - \sum_{j=1}^p\beta_jx_{ij} \right) + \lambda \sum_{j=1}^p \beta_j^2 \end{equation} where $y_i$ are the observations and $x_{ij}$ are the variables. I am reading an Introduction to Statistical Learning, which says:  When λ = 0, the penalty term has no effect, and ridge regression will produce the least squares estimates  and (of ridge regression):  if p > n, then the least squares estimates do not even have a unique solution, whereas ridge regression can still perform well  My questions are the following:  Am I correct in saying that ridge regression (and lasso) fail when $p > n$ and $\lambda = 0$, due to being equivalent to least squares?  If so, is there a solution for all $\lambda > 0$ when $p > n$, particularly when $\lambda$ is very close to zero?  If there is a solution for all $\lambda > 0$ when $p>n$, is there some reason to be wary of applying shrinkage methods like this due to the closeness of the optimisation problem to least squares?


Towers of Hanoi - are there configurations of $n$ disks that are more than $2^n - 1$ moves apart?

This is an exercise from Chapter 1 of "Concrete Mathematics". It concerns the Towers of Hanoi.     Are there any starting and ending configurations of $n$ disks on three pegs that are more than $2^n - 1$ moves apart, under Lucas's original rules?   My initial guess is no, there are no starting and ending configurations of $n$ disks on three pegs that are more than $2^n - 1$ moves apart.  I will post an answer to this question with my attempt at a solution. I would like to confirm if my solution is correct and complete, or if there is a better approach.  Edit: I added to the answer a second method of solving this problem, based on the comments to the answer.


How do I create executable Java program?

I have programmed a Java Program in JCreator, everything is done, but I want to create an executable file from it, ie I dont want to have to run the program by loading the java classes and compiling then executing, but instead have it as a stand alone executable file.  What the quickest way to do this?


Is there anywhere you can get a super key for the keyboard?

Like, a physical key to swap the Windows Start key with the Ubuntu Super key? Is there anywhere I can buy such a thing, or have I gone to the wrong place and asked? :P


Difference between "We are married for 5 years" and "We have been married for 5 years"

What is the difference between...        We are married for 5 years.      We have been married for 5 years.


I am trying to prove a time series is stationary and I think I am misunderstanding something. My question is   $$\ X_t=U_1 sin(yt) + U_2cos(yt) $$ with $E[U_1]=E[U_2]=0$  and $E[U_1^2]=E[U_2^2]=\sigma^2$ and $y=(2 \pi w_0)$ is a constant.  it was pretty easy to show that the mean does not depend on t, but then my book gave me the autocovariance = $ \gamma (h)=\sigma^2 cos(yh)$ and I am struggling to reach this.   my thoughts... let $s=t+h$ $$cov(x_t, x_s) = E[(x_s - \mu_s)(x_t - \mu_t)]=E[x_s x_t] - 0 =E[x_s x_t]$$  so we need the expectation at two different time periods. I tried to  $$\ E[x_t x_s]=E[(U_1 sin(yt) + U_2cos(yt) )(U_1 sin(y(t+h)) + U_2cos(y(t+h)) )]$$  but after continuing with this line, nothing came of it. I don't think we need to use trigonometric identities, so can anyone point me in the right direction?


Does the Stack Exchange community support using bots on the community?

Recently I came across this user-  I don't really know if this is really a bot on the site, but it claims to be one (If it really is a bot how did it answer one question on Stack Overflow?).  Does the SE network approve of or support usage of bots on the website (for any reason... maybe collecting site data, etc.)?


For my thesis I'm modeling the identification of recreation areas.  Therefore, there has been a survey where people were asked to specify where they recreate. They had to indicate this place on a map and give a radius. Now I have to analyse which areas were most visited, and afterwards use the data to give a weighted rating with the travel distance.  So, I use QGIS to Buffer the data points by using the given radius. Now, I want to calculate for every point in the country how many times it was visited.  Any thoughts how to do this in QGIS?


How do I get slanted text (\sl) with a different font (Times New Roman)?

I came across the \sl command to slant certain fonts. With the default CMU Serif font, it looks nice. However, one of my professors uses Times New Roman to do his CV (in LaTeX), and I want to mimic that style. However, when I try to use \sl with Times New Roman (using setmainfont{Times New Roman}), it just uses the standard italics for TNR. Is there a specific command that I'm missing or some style that I need to add? If a picture would help, I can add one. Thanks!


Integration by parts: $\int e^{ax}\cos(bx)\,dx$

I need to evaluate the following function and then check my answer by taking the derivative: $$\int e^{ax}\cos(bx)\,dx$$ where $a$ is any real number and $b$ is any positive real number.    I know that you set $u=\cos(bx)$  and $dv=e^{ax} dx$, and the second time you need to integrate again you set $u=\sin(bx)$ and $dv=e^{ax}dx$ again.  It eventually simplifies down to $$\int e^{ax}\cos(bx)dx = \frac{1}{a}e^{ax}\cos(bx) + \frac{b}{a}\left(\frac{1}{a}e^{ax}\sin(bx) - \frac{b}{a}\int e^{ax}\cos(bx)\,dx\right).$$  Now I know to move the integral on the left side to the right side so that I can just divide by the constant to solve.  Here is my problem:  I know I need to solve the right side to be:  $$\frac{e^{ax}\left(a\cos(bx) + b\sin(bx)\right)}{a^2+b^2} + C.$$  To divide by the constant, I multiplied everything on the right side by  $$\frac{a^2}{b^2+1}.$$ but this leads me to get $b^2 + 1$ on the bottom instead of $a^2 + b^2$.  I will show what I am doing in detail:  After setting the initial integral equal to: $$\frac{1}{a}e^{ax}\cos(bx) + \frac{b}{a}\left(\frac{1}{a}e^{ax}\sin(bx) - \frac{b}{a}\int e^{ax}\cos(bx)\,dx\right) + C$$ I simplify: $$\int e^{ax}\cos(bx)\,dx = \frac{a^2}{b^2+1}\left(\frac{1}{a}e^{ax}\cos(bx) + \frac{b}{a}\left(\frac{1}{a}e^{ax}\sin(bx)\right)\right) + C$$  If this is already wrong, can someone point be in the right direction?    If I have not gone wrong yet, I can edit to show the rest of my work.


I swapped the caps lock and the esc key of the laptop keyboard using gnome tweaks but this do not effect the external keyboard. how to swap these keys for the external keyboard. I'm new to ubuntu so a detailed answer will of great help.


Can/should a user earn Populist over his accepted answer?

I just came across a question where a user posted two answers, one of which was accepted. Now, I'm not saying there's anything wrong — the answers are far and above outstanding; see them for yourself!    As of this writing, the unaccepted answer doesn't yet qualify for Populist, as it has less than 2 times the score of the accepted answer. However, considering that both answers were posted by the same user, I'm wondering: when the unaccepted answer does eventually reach double the score of the accepted answer, should the user earn a Populist badge?  Or has there been a case where a user did or did not earn Populist over his own accepted answer?  Note that I'm not so much concerned about badge gaming as simply curious if it makes sense to be a populist over yourself... whatever that means.


Trying to do the upgrade of kubuntu from 19.04 to 19.10 Non-LTS versions are allowed (Prompt=normal in /etc/update-manager/release-upgrades)  update-manager says my system is up to date. Running do-release-upgrade produces "No new release found"  do-release-upgrade -d shows: "Upgrades to the development release are only available from the latest supported release."  Any ideas why I can't upgrade?  Thanks, Rudolf


I have a input file delimited with commas (,). There are some fields enclosed in double quotes that are having a comma in them. Here is the sample row    123,"ABC, DEV 23",345,534.202,NAME   I need to remove all the comma's that are not occuring within the double quotes by a ~ So the output should be like:    123~"ABC, DEV 23"~345~534.202~NAME   I have tried this, but it gives me reverse output:  awk -F '"' -v OFS='' '{ for (i=0; i<= NF; ++i) gsub(",","~",$i) } 1' test.txt 123,ABC~ DEV 23,345,534.202,NAME


'const int' vs. 'int const' as function parameters in C++ and C

Consider:  int testfunc1 (const int a) {   return a; }  int testfunc2 (int const a) {   return a; }   Are these two functions the same in every aspect or is there a difference?  I'm interested in an answer for the C language, but if there is something interesting in the C++ language, I'd like to know as well.


Is there a way to create a table in Gimp?  Something like this for example:   I made this with one single field which I duplicated many times to arrange it at the specific points and want to create more tables with x rows and y columns  By the way I am using Gimp 2.8.10  -Edit: I know that you can import tables made with word etc. but it has to be created in Gimp because I need the Cells to be individual Layers (sorry did not mention this in first post)   -Edit: As mentioned before I need the cells to be separate layers, is there a way to achieve this for a grid of x rows and y columns? Except creating the layers manually.


Getting Stack Overflow like Title field on other Stack Exchange sites

When editing my network profile,  gives me the ability to set a Title field which gets displayed just below my name when someone views my profile page.     However, the same is not available on other Stack Exchange sites.     I tried by clicking the Save and copy changes to all public communities button when editing my profile on Stack Overflow but that didn't make the title appear on other sites.  Is there a way to get the title field added to other network sites? Is this something that can be configured by site mods?  How can I go about requesting this feature?


Help, linux beginner! How do I put ubuntu on usb and boot/install on a PC with blank harddrive?

I wonder if someone can help me? I am fairly new to trying to actually understand and use computers myself rather than just buying whatever Windows/Mac wants me to! You will get a giggle from my flawed attempts anyway :-)  I would like to start using Ubuntu on my PC, just got a new harddrive and did have a borrowed windows 7 disk as was planning to temporarily install it so i could get ubuntu. However I didn't have high enough spec hardware for win 7 (I think it is due to only 1gb ram, i do have 64 bit technology and a 1tb harddrive). I am quite happy to install 32 bit ubuntu and hear it is easier the use than 64 anyway.  So I have one other rubbish mini laptop (windows xp) which i am trying to use to get ubuntu onto a usb (laptop has no cd drive) so i can install it on the pc. First tried just downloading ubuntu 13.04 desktop onto a usb and trying to boot the pc from it which gave the message 'no operating system'. Then I tried this to create a bootable usb which sounded promising:  . However then it starting asking for my saucy desktop iso in order to install it onto the usb stick, can't really manage to find out what a saucy desktopp iso is, maybe a mirror image of an operating system, no idea why i would need that.  So in short, I'm lost. All I can think of is getting windows xp somewhere so i can get my pc to work and install ubuntu from the internet on that, or going to a friends house in the hope that creating a bootable cd is easier than creating a usb.  Sorry for my general ineptness and hope someone can help!


win32 GUI app that writes usage text to stdout when invoked as "app.exe --help"

How do I create a windows application that does the following:   it's a regular GUI app when invoked with no command line arguments specifying the optional "--help" command line argument causes the app to write usage text to stdout then terminate it must be a single executable.  No cheating by making a console app exec a 2nd executable. assume the main application code is written in C/C++ bonus points if no GUI window is created when "--help" is specified.  (i.e., no flicker from a short-lived window)   In my experience the standard visual studio template for console app has no GUI capability, and the normal win32 template does not send its stdout to the parent cmd shell.


How to implement a member function once for both non-const and const overloads?

Sometimes I find myself adding overloads that have the same implementation, with const in qualifier and return value being the only difference:  struct B {}; struct A {     const B& get(int key) const     {         if (auto i = map.find(key); i != map.end())             return i->second;         throw std::runtime_error{""};     }      B& get(int key)     {         if (auto i = map.find(key); i != map.end())             return i->second;         throw std::runtime_error{""};     }  private:     std::unordered_map<int, B> map; };   Is there an idiomatic way to write the implementation only once and get rid of copy-paste that is better than const_cast:  const B& get(int key) const {     return const_cast<A*>(this)->get(key); }   ?


If $a_1, \dots, a_n$ are all positive, show that $\prod_{k=1}^{n}(1+a_k) \leq \sum_{k=1}^{n+1}\frac{S^{k-1}}{(k-1)!}$, where $S = \sum_{k=1}^{n}a_k$

I am having difficulties in providing the following proof: If $a_1, \dots, a_n$ are all positive, show that: $$ \prod_{k=1}^{n}(1+a_k) \leq \sum_{k=1}^{n+1}\frac{S^{k-1}}{(k-1)!} $$ where $S = \sum_{k=1}^{n}a_k$


Is the concept of a Universal Set an example of Russell's paradox?

In my book on functional analysis it is defined that a Universal Set is the union of all sets.  Is "union" used in the same sense as "set containing all sets"?  In other words, is the "set of all unions of sets" equivalent to "set containing all sets"?


Is there a way this array of points of four elements fit in drawimage method?

I want to rotate a bitmap image constantly but the array of four elements of points that I created doesn't fit in this method. drawimage(image,points,srcrectangle,Graphicsunit).  I was reading microsft document about drawimage method and It says that it will work for 3 points(paralellogram). So I tried with 3 points, and It works as microsoft document says. But I need these four elements, perhaps I'm wrong , can someone just tell me how this method works?      public override void dibujar(Graphics area, Bitmap imagen)     {          radio = Math.Sqrt(Math.Pow(ancho, 2) + Math.Pow(largo, 2)) / 2;         Rectangle porcion = new Rectangle(indicex * ancho, indicey * largo, ancho, largo);          Point p1 = new Point(x + (int)(radio * Math.Sin(Math.PI * angulo / 180)), y+(int)(radio * Math.Cos(Math.PI * angulo / 180)));         Point p2 = new Point(x + ancho + (int)(radio * Math.Sin(Math.PI * (angulo-90) / 180)), y + (int)(radio * Math.Cos(Math.PI * (angulo - 90) / 180)));         Point p3 = new Point(x + (int)(radio * Math.Sin(Math.PI * (angulo - 180) / 180)), y - largo + (int)(radio * Math.Cos(Math.PI * (angulo - 180) / 180)));         Point p4 = new Point(x + ancho + (int)(radio * Math.Sin(Math.PI * (angulo - 270) / 180)), y - largo + (int)(radio * Math.Cos(Math.PI * (angulo - 270) / 180)));         Point[] points = {  p2, p3, p4 }; // Get all points in one array         area.DrawImage(imagen, points, porcion, GraphicsUnit.Pixel);         if (angulo == 0)         {             angulo = 360;         }         else         {             angulo--;         }         x += dx;      }   This method throw NotimplementedException when my array is of four elements


Generating a random alpha string in Java

I need to create a random string of letters, but have never used the random class before.   here is the spec: Create a small program that will ask the user to enter their name. Store the name in a string Print the name Ask the user to change their last name Manipulate the string to the new last name. Print the new name. Create an infinite loop that will change the string variable randomly.  See if your program will crash.  so far I have this  import java.util.Scanner; import java.util.Random;  public class StringNames {      public static void main(String[] args) {          System.out.println("Please enter a name");          Scanner myInput = new Scanner(System.in);         String firstName = new String();         firstName = myInput.next();          String lastName = new String();         lastName = myInput.next();          System.out.println(firstName + " " + lastName);          System.out.println("Please change your last name");         lastName = myInput.next();          System.out.println(firstName + " " + lastName);          for (;;) {          }     }  }   How can I create a random string of letters to change the last name to in the infinite loop? I am unsure how long the string has to be. The simpler the code the better. I am slow.  Thank you for your guidance


Priority of execution of hooks in different modules

Let's say that there is a contributed module installed in Drupal 7. It alters a SQL statement from the core. Now I have a custom module of my own which alters the same SQL statement in a different way. Now, depending on the alteration, I could have different SQL strings depending on which module hook applies before the other. For example, the first hook deletes a table "field" and the other adds the same table "field". If the first hooks executes earlier, the final SQL has the field added. If it is now the second hook which executes earlier, the extra field is added and later removed, so the SQL is completely different. How can I now the priority, any other conflicting issues and is there a way to override this apparent difficulty?


Cannot execute sudo command without correct password (Even though my account has no password). Why?

My account on my computer does not require a password, and I have admin privelages. As I understand it, so I'm trying to run sudo [...] and getting the following result when leaving the password field blank  user@computer:~$ sudo apt-get install jdk [sudo] password for user:  Sorry, try again. [sudo] password for user:  Sorry, try again. [sudo] password for user:  Sorry, try again. sudo: 3 incorrect password attempts   What do I need to do to run this successfully. Is there a default internal password I'm not aware of?  Running Ubuntu 14.04 LTS x32.  Thanks!


Induction: Show: $\frac{1}{2} \times \frac{3}{4} \times \frac{5}{6} \times ... \times \frac{2n-1}{2n} \leq \frac{1}{\sqrt{3n+1}}$

The question:  Show by using induction that: $\frac{1}{2} \times \frac{3}{4} \times \frac{5}{6} \times ... \times \frac{2n-1}{2n} \leq \frac{1}{\sqrt{3n+1}}$ for all $n$ $\in$ $Z_+$  My attempt at a solution:  first of we check the base case $n = 1$:  This gives us: $\frac{1}{2} \leq \frac{1}{\sqrt{3+1}} = \frac{1}{2}$ The base case works.  Now we assume that the statement is true for some $k = n$.  Then we have to prove that it also holds true for $k = n+1$.  This gives us:  $$\frac{1}{2} \times \frac{3}{4} \times ... \times \frac{2(n+1)-1}{2(n+1)} \leq \frac{1}{\sqrt{3(n+1)+1}}$$  If we then can prove that this holds true: $\frac{1}{\sqrt{3n+1}} \times \frac{2(n+1)-1}{2(n+1)} \leq \frac{1}{\sqrt{3(n+1)+1}}$ we have proven the that it holds true for all $n$ in $Z_+$  We start by writing the expression like this:  $$\frac{2(n+1)-1}{2(n+1)} \leq \frac{\sqrt{3n+1}}{\sqrt{3(n+1)+1}}$$  $(1):$  $$\frac{2(n+1)-1}{} \leq \frac{2(n+1)\sqrt{3n+1}}{\sqrt{3(n+1)+1}}$$  $(2):$  $$\frac{\sqrt{3(n+1)+1}(2(n+1)-1)}{} \leq \frac{2(n+1)\sqrt{3n+1}}{}$$  $(3):$  $$\frac{\sqrt{3n+4}(2n+1)}{} \leq \frac{(2n+2)\sqrt{3n+1}}{}$$  Please help me with how I continue from here? Have I had the wrong approach to this problem?  Thank you!


I'm using Leaflet map + GeoServer to display a map. I have a TIFF file and a DTED level 2 file.  I created a GeoTIFF store and layer that i'm showing in Leaflet, And I created a DTED store and layer in GeoServer.  I want now to display the altitude of each point from the DEM Layer, like so:  Latitude: 32.123 ,longitude: 12.112, Altitude: 12312 m   How do I get the altitude data from the store I created?  I tried using WCS protocol but I only get images.


Experimental proof of time-reversibility in microscopic classical physical laws

All the laws of classical mechanics are time-reversible. But the experiments that we carry out on systems, mostly measure macroscopic parameters which are time-irreversible. We know for a reason that due to the loss of information from coarse-graining the microscopic laws, the macroscopic laws (of thermodynamics) are time-irreversible.   My question is, can we directly carry out experiments that can validate time-reversibility of classical mechanical laws (without involving measurement of macroscopic parameters)?  Secondly, if this is not possible, have there been attempts to make time-irreversible microscopic laws that describe all the other results that classical mechanics predict?


Blender Cycles black areas on transparent material (Principled Shader)

I am trying create a transparent plastic material. I am not sure why I am getting black areas on the transparent material...    What should I do to fix this and/or what might be some good resources to learn about what causes this?  Thanks for any help.


How do you close apps in Android so they aren't taking up resources?

This may sound silly but it's a good point. In apps such as web browsers pressing the back key only navigates the browser back to the previous page. Pressing the home key makes an app disappear, but isn't it still running in the back ground? So for apps like web browsers where pressing the back key doesn't close them how do you close them when you want to change applications and not have an unused one taking resources?  Isn't it a bit rediculous that there's no built in way in android to exit an app?


How to create custom menu link wrapper function in Drupal 7?

As you know default wrapper for menu item in Drupal 7 can be modified via function theme_menu_link().  by overriding   theme_menu_link($variables) {}    function we can modify the rendered html output of menu link but it will change all of menu items that their #theme attribute is set to this function. for example in main menu, each item has menu_link__main_menu value in it's #theme attribute.  Now I want to create a custom wrapper function in my theme.  I searched and I found I must create a function with structure like  theme_menu_link($variables) {}   and also I must REGISTER the function name in my theme.  For registration, I used function theme_theme() {}  function theme_theme() {return array('custom_menu_item_wrapper' => array());}   ** theme is replaced by name of theme ** custom_menu_item_wrapper is the name of my function for wrapping operation  But I don't know, how should I define parameters in theme function registration because when custom_menu_item_wrapper($variables) function is called $variables is NULL


Inheritance and methods: error - cannot find symbol

I have three classes. Class Vehicle, class Truck and class Car. Class Truck and class Car extend from class Vehicle. class Vehicle has three fields:  protected String model; protected int year; protected int price;   Class Truck has one field:  private String color;    and the method:  public String getColor(){     return color;    }   Class Car has one field:  private boolean rusty;   I have an array called vehicles(which stores 30 objects) to store Truck objects as well as Car objects.  I have another class called VehicleDealer in which I have created the array and different methods including:   int VEHICLE_COUNTER= 0;  public void addTruck(String m, int y, int p,String c){     Vehicle truck1 = new Truck( m, y, p, c);     vehicles[VEHICLE_COUNTER] = truck1;      VEHICLE_COUNTER = VEHICLE_COUNTER + 1; }  public void addCar(String m, int y, int p,boolean r){     Vehicle car1 = new Car( m, y, p, r);     vehicles[VEHICLE_COUNTER] = car1;      VEHICLE_COUNTER = VEHICLE_COUNTER + 1; }   public String printAllVehiclesOfColor(String c){      String s = "";     for (int i=0; i < VEHICLE_COUNTER; i++) {          String x = vehicles[i].getColor();        if(x == c){            s += vehicles[i].printThis(i) + "\n"; }          }         return s; }    I have a main class which looks like this:  public class TestDealer{ public static void main(String[] args){      VehicleDealer dealer = new VehicleDealer();  dealer.addTruck("Ford", 2012, 55000, "Green"); dealer.addTruck("Ford", 2001, 23050, "Black"); dealer.addCar("BMW", 2010, 17000, false);  System.out.println(dealer.printAllVehiclesOfColor("Green"));      } }   In this line of code I get an error which says that cannot find symbol for getColor().  for (int i=0; i < VEHICLE_COUNTER; i++) {          String x = vehicles[i].getColor();<---------------        if(x == c){            s += vehicles[i].printThis(i) + "\n"; }          }   So I put the getColor() method in class Vehicle and then tried to compile the code but it did not work as I have not declared a color field in class Car. My question requires me to declare the color field in class Truck only.  What is wrong with my code? I am new to Java. Any help is appreciated. Thank you!!


Apache: PHP scripts not executing when running 7.0

NOTE: This is not a duplicate of, nor is the answer here:      On my local Apache webserver, and I have PHP 5.6 and 7.0 installed. When I run 7.0 the scripts are not executed (just raw text is displayed), but when I switch to PHP 5.6 everything is fine.  I've checked my httpd.conf when running 7.0, and it's correct:  LoadModule php7_module /usr/local/opt/php70/libexec/apache2/libphp7.so  Typing php --ini in terminal produces the following:  Configuration File (php.ini) Path: /usr/local/etc/php/7.0 Loaded Configuration File:         /usr/local/etc/php/7.0/php.ini Scan for additional .ini files in: /usr/local/etc/php/7.0/conf.d Additional .ini files parsed:      /usr/local/etc/php/7.0/conf.d/ext-mcrypt.ini   Which looks correct.   Typing apachectl -v produces:  Server version: Apache/2.4.18 (Unix) Server built:   Feb 20 2016 20:03:19   I feel like it's an issue with my Apache config.


Prove by induction for $\forall n\in \Bbb N_1 $ that $2^n \ge 1+n $.

Can someone please help me in this exercise?     $$2^n \ge 1+n $$   What I've done so far is prove for $n=1$. So:     $$2^1 \ge 1+1 $$   $$2 \ge 2 $$   Which is true   Now, I'm supposing that what I have to prove is for $n+1$:     $$2^{n+1} \ge 1+ (n+1)$$   But I don't know how to continue it.  Thank you for the help


How are classical optics phenomena explained in QED (Snell's law)?

How is the following classical optics phenomenon explained in quantum electrodynamics?   Reflection and Refraction   Are they simply due to photons being absorbed and re-emitted? How do we get to Snell's law, for example, in that case?  Split by request: See the other part of this question .


I'm tring to read from text file in hebrew but i get some jebrish...  this is my code:  try {         workFile =new File("tripShosWork.txt");         homeFile =new File("tripShosHome.txt");         BufferedReader homeBr =  new BufferedReader(new FileReader(homeFile));         BufferedReader workBr = new BufferedReader(new FileReader(workFile));         home = new String [98];         for (int i = 0; i < home.length; i++)              home[i] = homeBr.readLine();         work = new String [19];         for (int i = 0; i < work.length; i++) {             work[i] = workBr.readLine();          }     } catch (Exception e) {         e.printStackTrace();     }      System.out.println(Arrays.toString(work));     System.out.println(Arrays.toString(home));   i need your help!


base class by template, how to write constructor?

How to write constructor for class that base class name is from template? as I try to compile code below then i get this error  undefined reference to >IMU<ADXL>::IMU(int)   In function `_GLOBAL__sub_I_rdy'  >>>main.cpp<<< IMU<ADXL335> obj(8);  >>>IMU.h<<< template <class T> class IMU : public T {    public:    const int someMember=0;     IMU(int); };  >>>IMU.cpp<<< template <class T> IMU<T>::IMU(int x) // IMU constructor : T()         // base constructor , someMember(x) {  }  it should work as >>>main.cpp<<< IMU obj(8);  >>>IMU.h<<< class IMU : public ADXL {    public:    const int someMember=0;           IMU(int); };  >>>IMU.cpp<<< IMU::IMU(int x) // IMU constructor : ADXL()   // ADXL constructor , someMember(x) {  }


Let $B$ be the set of all the upper bounds of the non-empty bounded subset $A\subseteq\Bbb R$. Prove that $\inf B=\sup A$.   I divided it into two areas ($\inf B>\sup A$, $\inf B<\sup A$) and tried to show a contradiction. Is it the right approach? How can I prove it?


"Stack Overflow requires external JavaScript from another domain, which is blocked or failed to load."

Possible Duplicate:          I'm not sure if this is the right place to ask this, but since this morning when I opened StackOverflow that error appears on the top of the page.  I'm on FF and I'm not using any popup/code blocker. I've tried also with Google Chrome but the errors remains.  Anyone else with the same error? How to solve this?  Thanks in advance


Find the number of real roots of the derivative of $f(x)=(x-1)(x-2)(x-3)(x-4)(x-5)$

Find out the number of real roots of equation $f'(x) = 0$, where    $$f(x)=(x-1)(x-2)(x-3)(x-4)(x-5)$$    How can I differentiate this function without expanding it to the polynomial form. Am I underestimating some theory of equation concept associated with it? (I know the product rule approach and solving by simplifying but I want to know is there any other way to solve it)


In the UK students often say they are "studying" a topic (e.g., "I am studying computer science at University of X") but once in a while I also hear students say they are "reading" a topic (e.g., "I am reading sociology"). The latter I've only heard said in the context of social sciences.  Is there a difference between reading and studying a topic?


Why subtraction of a negative number from a positive number is addition? Eg: $a - (-b) = a + b$ When looking through the number scale I am unable to relate this, please kindly clarify ?


Why D/I is finite if I is a non-zero ideal of the ring of integers of a number field?

Let D be the ring of integers of a number field K. Let I be a non-zero ideal of D. Why D/I is finite?  Would you help me please? Thank you in advance.


How can I add/remove class on a second element with vanilla JS?

I’ve been through a LOT of stackoverflows but haven’t figured out how to accomplish this. What I’m looking to do is pretty simple, but I’m not good with plain ole Javascript.  Desire:    Mousing over #element1 adds .specialClass to #element2 Mousing out #element1 removes .specialClass from #element2   If I was able to use jQuery this is exactly what I’m looking to accomplish:  $(document).ready(function() {          $('#element1').hover(function(){              $('#element2').addClass('specialClass');         },          function(){             $('#element2').removeClass('specialClass');          }); });   I need this same functionality in a plain Javascript function. I know it seems like a job for CSS, but in my very particular instance, I need this to be JS.  ** THIS QUESTION IS NOT A DUPLICATE of  as that one uses onClick and I'm looking for mouse over/out. **


Prove a residue matrix $A$ (with coefficients in $\mathbb Z_n)$ has an inverse if and only if $\gcd(\det A,n) = 1$.   I've always done matrix arithmetic in a field $\mathbb F$ and that is what every Linear Algebra book has taught me to do.  However, I've started looking into Cryptography and here the term residue matrix come up.  Can someone prove the above result or tell me where to look it up ?  Where can I find books about Cryptography-related Linear Algebra ? I've studied several books on Linear Algebra, but they are all equal in the sense that the ring of interest is a field.  Normally a matrix $A$ (with coefficients in a field $\mathbb F$) has an inverse if and only if $\det A \neq 0$, and in this case $\det A$ is neccesarily invertible, since we are in a field. So the above result is a more general result than this.


I have a locked file. And I would like to figure out the process id that has this file locked. Is this possible on Windows using WinAPI or something?  Thanks very much!


Hook for number of items in Appearance > Menus > CustomPostType > View All

I wonder if this problem:   is caused by the fact that the parent page is on a different "query page" than its children, and WP reverts to a flat list.    To test this hypothesis, can you let me know if the number of items to show per page in Custom Post Type > View All can be controlled via a hook?


ssh with nautilus : connect to server1 and then server2

With a terminal I can do: ssh my_id@server1 and then ssh my_id@server2  (I first reach server1 and from it, reach server2. I need to do it because I can't directly access server2 (college policies)).  With Nautilus I can do: ssh://server1 but then there is no windows to write and so connect to ssh://server2 (talking about this window:  )  Any idea how to access server2 by accessing server1 first, with Nautilus ?


On questions about the integral of the logarithm of the Riemann zeta function II

With the help of  I know good approximations of the real part of the integral $$\int_0^1 \log \left(\zeta(x)\right)dx,$$ where $\zeta(x)$ denotes the Riemann zeta function (evaluated over real numbers).  See it as int log(zeta(x))dx, from x=0 to 1 or 15 digits of int log(zeta(x))dx, from x=0 to 1     Question. I'm curious to know if this constant $$\Re\int_0^1 \log \left(\zeta(x)\right)dx$$ is in the literature. Can you provide me the reference? Then answer this question as a reference request adding what is the article showing/defining the value of this real constant, and I am going to search and read such statement. Many thanks.   My problem here is that I can not find the numeric value of this constant in  The On-Line Encyclopedia of Integer Sequences or in Internet.


Is it possible to install 64 bit ubuntu desktop/server to a Compaq Mini 110?

I have a Compaq Mini 110. I can install 32bit version of Ubuntu desktop and it works fine. But when I try to install Ubuntu server 32Bit/64Bit or Desktop 64Bit, the screen freeze after choosing "Install ubuntu".  Is this because my device does not support 64Bit or 32 Bit server or something else?


There are G girl students and B boy students in a class that is about to graduate. You need to arrange them in a single row for the graduation. To give a better impression of diversity, you want to avoid having too many girls or too many boys seating consecutively. You decided to arrange the students in order to minimize the gender regularity. The gender regularity of an arrangement is the maximum number of students of the same gender (all girls or all boys) that appear consecutively. Given G and B, calculate the minimum gender regularity among all possible arrangements.  can someone give me the intuitive approach of solving this problem by using pigeon hole principle?  Link to problem


How to force a login on a specific page only?

I would like to create a page (with a specific url) which will always require/force the user to login with their credentials. This would need to work irrespective of whether they were already logged in or the permissions they have.  I have considered using one of the access modules such as Content Access, but the issue here is that if the user has already logged in previously, they will bypass the login screen. One way could be to use the Required Login module. But I am not sure how would I exclude all of the website except the one page? The only other option I can think of is to do this on content view via Rules. I have tried this, but there is a noticeable pause between when the page is loaded to when the logout begins; making this appear more like a hack as opposed to a streamlined solution.  Are there any better ways to achieve this?


Does deflecting a fireball with a looting sword give better drops?

I got 2 ghast tears after I thought I deflected a fireball back at the ghast (with my looting 3 sword).  But I was pretty close, so I might have just hit it. I'm not sure.  If I deflect a fireball with a looting sword and it kills the ghast, do I still get the looting bonus?


What are some alternatives to document.execCommand to select and copy text?

I have some code the uses the following lines: document.execCommand('selectAll', false, null); document.execCommand('copy', false, null);  And it works great. However, Mozilla has marked this command as obsolete. What is a better way of doing this, possibly with React or plain Javascript?


Prove that $\exists \{c_n\}$ monotonically increasing to $\infty$ such that $\sum_{i=1}^\infty a_nc_n$ coverges.

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.


Calculate the leading-order asymptotic behaviour (Laplace's Method)

thanks in advance!  Calculate the leading-order asymptotic behaviour of the integral $$I(x) = \int_{0}^{2\pi} (1+t^2) e^{x \cos t} dt \mbox{ as } x \mbox { tends to infinity}$$  So far I know there are two maximas at $0 \mbox{ and }2\pi$ so it can be assumed to be the integral  $$\int_{0}^{\epsilon} (1+t^2) e^{x \cos t} dt + \int_{2\pi-\epsilon}^{2\pi} (1+t^2) e^{x \cos t} dt$$ then using taylor expansions this can be transformed to: $$\int_{0}^{\epsilon} (1+t^2) e^{x (1-\frac{t^2}{2})} dt + \int_{2\pi-\epsilon}^{2\pi} (1+t^2) e^{x (1-\frac{1}{2}(t-2\pi)^2)} dt$$ but where do I go from here? How do I find the leading order term?


Error when creating table with more than 9 columns using {*} shortcut

I can't imagine that this hasn't been asked before, but googling doesn't help me find the answer.  Creating a table with 9 columns using the shortcut {*9{l}} works fine:  \documentclass{article} \begin{document} \begin{tabular}{*9{l}} \end{tabular} \end{document}   But when I get into double digits, I get an error:  \documentclass{article} \begin{document} \begin{tabular}{*10{l}} \end{tabular} \end{document}      ! LaTeX Error: Illegal character in array   arg.   How can I use the shortcut {*} with >9 columns?


Firefox Browser Hijacker "zapmeta.de" and "izito.de" on every google result, can't find a way to remove

First i noticed its coming from a nameless extension, i had to reset the browser cause i didn't find a way to uninstall it. Now it came back after at least one PC restart, so there must be malware installing it. The nameless extension is listed in add ons, but is not inside the extensions folder and a search for the ID from the troubleshooting information page didn't find any results. Where else could extensions be stored that are not in the folder/how do they hook onto firefox? I remember i had some weird ad software that i had no idea where it came from, sadly don't remember the name, but i thought it would be done by uninstalling that. I can't spot anything unusual now in programs or services. I appreciate any hints.


"These findings are critical [to inform/for informing] future research"

In this sentence, would you use "to inform" or "for informing"?     These findings are critical ______ future research   Likewise, would you use "to understand" or "for understanding" in the following?     These results provide a powerful framework _____ existing patterns.   This is a question that comes up a lot in science writing: when do you use the "to" vs. the "for" version of a verb? Is there a word for these two different uses?   And is there a rule for deciding which one is correct? They often get used interchangeably, but I can't find any hard rules for deciding between the two.   People often use the "to" version because it sounds less passive, but I find it more ambiguous and a bit clunky, but I can't find any actual sources to say which is correct.


Cant get an equation that does simple math to work properly in C#

The equation:  def defensefunction(attack, defense, damage):       dmg_def = (damage/attack)*(attack - (defense - (attack * 0.5)))      print(dmg_def)   The code above is written in python and works properly but in C# it's another story:  In C#:  public static double DefenseFunction(int attacker_damage, int attacker_attack, int defender_defense)           double var1 = (attacker_damage/attacker_attack);          double var2 = (attacker_attack- (defender_defense - (attacker_attack * 0.5)));          double dmg_def = var1 * var2;          return dmg_def;   There is a var1 and var2 because I tried to debug the code by splitting the equation.  What I found so far:   The equation in var 2 works properly (the value is equal to what i get on a Hand-Calculator). var 1 could either be working right or not (most of the number should be from 0.1 to 0.9, To.String() rounded the number so just show a 0 on the form). dmg_def gets printed as a 0 (It shouldn't be, for example: 0.8 * 173 != 0).   Things that maybe are relevant:  How the function gets called:  double dmg_from = Actor.DefenseFunction(_attacker.Damage, _attacker.Attack, _defender.Defense);   How i print the number on the form:  rtbMessages.Text += dmg_from.ToString() + Enviroment.NewLine;


Expected minimum distance from a point with varying density

I'm looking at how the expected minimum Euclidean distance between randomly uniform points and the origin changes as we increase the density of random points (points per unit square) around the origin. I have managed to come up with a relationship between the two described as such:  $$\text{Expected Min Distance} =\frac{1}{2\sqrt{\text{Density}}}$$  I came up with this by running some Monte Carlo simulations in R and fitting a curve manually (code below).   My question is: could I have derived this result theoretically rather than through experimentation?  #Stack Overflow example library(magrittr) library(ggplot2)   #--------- #FUNCTIONS #--------- #gen random points within a given radius and given density gen_circle_points <- function(radius, density) {   #round radius up then generate points in square with side length = 2*radius   c_radius <- ceiling(radius)   coords <- data.frame(     x = runif((2 * c_radius) ^ 2 * density, -c_radius, c_radius),     y = runif((2 * c_radius) ^ 2 * density, -c_radius, c_radius)   )   return(coords[sqrt(coords$x ^ 2 + coords$y ^ 2) <= radius, ])#filter in circle }  #Example plot plot(gen_circle_points(radius = 1,density = 200)) #200 points around origin points(0,0, col="red",pch=19) #colour origin     #return euclidean distances of points generated by gen_circle_points() calculate_distances <- function(circle_points) {   return(sqrt(circle_points$x ^ 2 + circle_points$y ^ 2)) }  #find the smallest distance from output of calculate_distances() calculate_min_value <- function(distances) {   return(min(distances)) }   #Try a range of values density_values <- c(1:100)  expected_min_from_density <- sapply(density_values, function(density) {   #simulate each density value 1000 times and take an average as estimate for   #expected minimum distance   sapply(1:1000, function(i) {     gen_circle_points(radius=1, density=density) %>%       calculate_distances() %>%       calculate_min_value()   }) %>% mean() })  results <- data.frame(density_values, expected_min_from_density)  #fit based off exploration theoretical_fit <- data.frame(density = density_values,                                fit = 1 / (sqrt(density_values) * 2))  #plot monte carlo (black) and fit (red dashed) ggplot(results, aes(x = density_values, y = expected_min_from_density)) +   geom_line() +    geom_line(     data = theoretical_fit,     aes(x = density, y = fit),     color = "red",     linetype = 2   )


How to execute a script periodically without using crontab?

How to execute a script periodically like crontab does but without using crontab?  Please note this that the executed script should not fire with another script and schedule it with 'sleep' command, what I expect to have same functionality as crontab but it should not be present in crontab list and should not be stop when terminal or session ended,   crontab exactly but without croning it.


I want to use gzip compression in Apache

I want to enable gzip compression for acethehimalaya.com. Can anybody please tell me what is the best way of achieving compression in an Apache Webserver?


I am in the process of getting rid of some old Apple products:   Late 2009 iMac iPad 2 (2012) iPhone 4 (2011)   I've reset my iPad 2 using the feature in the preferences, to erase all content and settings.  I also plan to format my Mac by doing a clean install of High Sierra.  Would the above processes be secure enough for me to then sell / give my products away? or could data still be recovered?


Why are there multiple loop devices for the same snap?

I used lsblk to check connected devices, when I found that there are a total of 3 loop devices for the same snap "core", with revision numbers.  loop1    7:1    0  81.6M  1 loop /snap/core/4110 loop2    7:2    0  81.7M  1 loop /snap/core/4017 loop0    7:0    0  81.3M  1 loop /snap/core/3887   On checking the mount directory of snaps, this is what I get:  drwxr-xr-x 24 root root 321 Jan 22 13:17 3887 drwxr-xr-x 24 root root 321 Feb  6 20:48 4017 drwxr-xr-x 24 root root 321 Feb 20 22:37 4110 lrwxrwxrwx  1 root root   4 Feb 23 19:31 current -> 4110   and snap list shows this:  core  16-2.31.1  4110  canonical  core   Why is snapd not removing the old versions of snap core? Is it a normal behavior, or is there any way to remove this if this is not supposed to happen? I'm using Ubuntu 16.04.


Make it possible to prevent voting on time-limited questions in meta without a historical lock

This may be a low use-case request and there may be a better way to manage it than this request but I'd like to see what the possibilities are to make it possible to avoid using the "historical lock" option with its default text on questions that aren't actually bad questions but that are designed to only be answerable for a specific period of time. For reference, here's the historical lock text:  This question and its answers are  because the question is off-topic but has historical significance. It is not currently accepting new answers or interactions.  This came up as an issue to me on M&TV Meta. We have a  where people nominate their favorite answers from the quarter and voting is open for a limited period of time, at which point our current solution is to use a historical lock to prevent future voting. This has a couple of downsides:  As seen in the lock explanation, it states that the question is off-topic, which it is not, and necessitates our mods to write a comment explaining that it is not a bad question.  The question leaves the recently active queue, making it very difficult to find without searching for it specifically. So, despite this question being answered as recently as January 16th, it is no longer in its proper place.   Is it possible to get a form of "lock" that prevents additional answers and votes but does not have these two side effects?


AdWords: unauthorised use of trademark in keywords

I recently identified 2 companies who are actively targeting ads through Google AdWords using our trademark (registered in the UK). I filed a complaint with Google, although they are not willing to remove these ads.     Please note that we will not be able to process this complaint for   your trademark * because you requested that we remove all   ads that are currently using your trademark as a keyword.       We do not investigate keyword complaints for trademarks, as described   at .   As a result, we won't be able to remove ads that are using your   trademark as a keyword.   If Google allow other competitive firms to leverage traffic through AdWords off the back of an established brand where does that leave us? Must we also use AdWords to outbid our competitors on our own company name?   I'd be interested to know of anyone who has experienced something similar. If Google won't do anything to police this then is litigation the only option available?  EDIT  It seems Google have recently changed their policy on this and are no longer arbitrating trademark disputes when used in keywords, only in ad copy. This can't be good for search quality!!?


I'm running Ubuntu 14.04 with the 3.19 kernel which should have OpenFS supported (since kernel 3.18). I've been  but am confused as to how to actually implement using it. It looks like it could be a really useful alternative to LVM in enabling changes to be written somewhere else whilst taking a backup of the original filesystem that is being overlayed?  Can someone give me the example mount commands to use (if possible) for the following cases:   With a raw disk image (created using dd if=/dev/zero of=$HOME/filestystem1.img bs=4096 count=1024000) to act as the overlaying filesystem, mount it over the top of my host's filesystem at $HOME/mount which should already contain some random files such as file1.txt and file2.txt. Once mounted I believe that I should still be able to see my already existing files and any files I now create will actually be stored inside the filesystem1.img file that I could possibly move to another system? Create another raw disk image and mount this one on top of the other one we just created. Do I do this as a second mount command that is executed after mount command we ran in the previous example, or can I possibly specify both mounts in one go?   I can't tell if OverlayFS is an actual filesystem I need to create on the disk images with mkfs -t xxx /path/to/raw/disk/image, or is a special mounting method and the raw disk images are actually using something like ext4, but they are mounted in a special way with mount -t OverlayFS? When I run:  cd /sbin ls mkfs*   I get the following which do not show an option to make an overlay filesystem.  mkfs      mkfs.cramfs  mkfs.ext3  mkfs.ext4dev  mkfs.minix  mkfs.ntfs mkfs.bfs  mkfs.ext2    mkfs.ext4  mkfs.fat      mkfs.msdos  mkfs.vfat


Hi, How to auto execute a php action page on every day at given time, i.e i want to execute a php script at 10:00 am everyday (In windows).?

How to auto execute a php action page on every day at given time, i.e i want to execute a php script at 10:00 am everyday (In windows).?  I want to take the given time from the database and the n i want to execute the php script at the specified time taken from the DB


"an error occurred while mounting /home/aljobory/drive"

When I start Ubuntu must be press s latter twice times to start system:     'an error occurred while mounting /home/aljobory/drive' press S to skip or m to recover


Confirmation about one simple inequality

Suppose A & B are sets of reals.Then is it true that inf{A+B}$\leq$inf{A}+inf{B}.I consider all the cases like A contains all positive and B contains all positive,then alternate positive and negative combinations, and it seems true to me.Is it true?


I have this code:  if($key == 'b306') {     $fieldType = 'date';   }   In my PHP Storm debugger, it says that key = 0 (integer). When I leave it as a ==, the code does pass into the if. Only if I change it to === does it skip it, as expected. Why? I thought that the difference between == and === is that === matches type and value, vs == only does value. But this shouldn't allow 0 to be equal to 'b306'.


What to do if reviewers reject a paper without understanding the content?

One of my friends submitted a paper to a reputable communications journal and received some reviews a week back. The paper was rejected, but the review comments were abysmal:    The language was so bad in one of them that it was difficult to understand what the reviewer was hinting at. Besides, the comments pertained to trivial things like naming of axes and there was no comment on (or understanding of) the overall work. The second of the three reviewers rejected the paper in one line saying it was impossible for him/her to understand what the paper aimed at. The third reviewer appreciated the paper and its results and made good suggestions for improving the results.   The editor-in-charge has rejected the paper since the vote was 2/3 in favour of that, but my friend feels hard done as he feels the two reviewers did not merit to review the work.   What recourse does an author have if his paper is rejected by a reputable journal, but the review comments indicate a serious lack of understanding of the paper's work? Should the author write his/her grievance to an editor higher in the hierarchy (an associate editor, for example)? Or is ditching the journal and submitting it to somewhere else the only solution?


Is it possible to pass two arguments in c?

I have written a C program where I declared a function reverse(int i). When I compile and run the program, it runs fine despite passing two arguments like this reverse((i++, i)). Why doesn't this cause a syntax error? reverse expects one argument.    #include <stdio.h>     void reverse(int i);     int main()     {              reverse(1);       }     void reverse(int i)     {             if (i > 5)                     return ;             printf("%d ", i);              return reverse((i++, i));     }


So I am making a website like a little mock up one as I have just started learning and the footer just won't stay at the bottom and it is killing me. When I load the page it starts at the bottom and then when I scroll down it stays in the same place and is stuck where it started and won't start at the bottom of the page.  #footer {     text-align: right;     padding: 10px;     background-color: #07889B;     position: absolute;     bottom: 0;     width: 1200px;   }


How can I break out of ssh when it locks?

I frequently ssh into my box at home from school, but usually when I change classes and my computer suspends, the pipe will be broken. However, ssh simply locks up - Ctrl+c, Ctrl+z and Ctrl+d have no effect.   It's annoying to have to restart my terminal, and even more annoying to have to close and re-create a new screen window.  So my question, is there an easy way to make ssh die properly (i.e. when the pipe fails "normally" it will exit with a message about a broken pipe)? Or do I have to figure out what the PID is and manually kill it?


Uniform convergence for sequences of functions

Please help me out with this problem:  Let $f_n(x) : [0,1] \to \mathbb R$ be a sequence of continuous functions convergent at every $x \in [0,1]$ to a continuous function $f: [0,1]  \to \mathbb R$ . Does $f_n$ converge uniformly to $f$?  My first solution: I read this example in  posted earlier and I think it works: Take a sequence $f_n:[0,1] \to \mathbb R$ such that $f_n$ increases linearly from $0$ to $1$ on the interval $\left[ 0,\frac{1}{n} \right]$, decreases linearly from $1$ to $0$ on the intreval $\left[ \frac{1}{n}, \frac{2}{n} \right]$, and is $0$ on $\left[ \frac{2}{n},1 \right]$. Then $f_{n} \to 0$ nonuniformly.  Is this answer true? Also, if anyone can give some examples of such function with detailed proof, I will very appreciative?


Listing files with given characters in their name

I want to list all the files, in directory I am currently in, with for example "a" in their name. I know that the first part of the command would be ls -l, but i do not know how to finish it.


how to access partitions made in windows in ubuntu installed in dual boot alongside windows?

I have installed ubuntu on my laptop alongside my windows 10(that i use primarily).  when ubuntu was installed, I noticed that grub was not booting into windows but was booting in ubuntu.  so i had to manually select windows boot loader by pressing f12 wile booting.  but when i booted into ubuntu i noticed that windows partitions were showing but were not accessible.  I want to use ubuntu for my college purposes so i will have to transfer many files between windows and ubuntu.  even if i could access one partition from my hdd is enough.  i didnt get any solution on the internet so far so i havent tried anything.  if you know what to do please help.


How to construct a $2\times2$ matrix $A$ such that $A^3=I$?

Construct a $2$ $\times$ $2$ matrix $A$ ($\neq$ $I$) with entries from $\mathbb{R}$ such that $A^3=I$.  First give me some hint. How to construct this kinds of matrices, is there any rule...


How do I Share a Wired DSL Connection as a hotspot?

I have a Wired DSL Connection in my laptop, and I want to share this creating a hotspot.  Ubuntu 12.04 Dell Inspiron 1545


What should I do when flagging if I don't see the destination site in the list?

Sometimes I want to flag a question on Stack Overflow because it belongs to  or , but I don't see those sites on the list provided when you click on:  It doesn't belong here > off topic  I usually see:


How could the land departure be recorded when re-entering the United States?

I found the  for recording a land departure. "A departure will be recorded if you depart via land and re-enter the United States prior to the expiration date stamped in your passport." I wonder how the land departure could be recorded when re-entering the United States. Does it require some evidence? Please let me know it if there is any person who experienced this.


Getting a "random" number from 0 - 1 depending on a number and a count

I have a question, all though I think its more Math than programming. So sorry if this is the wrong place to post this.  But I want to make a function in Javascript that can do the following:   the function has a seed parameter inside the function there is a loop. it has to return a number between 0 and 1 depending on the count and the seed.   so for an example if I have this:  var numbers = giveMeNumbers(3224425, 10);   Should give me 10 "random" numbers between 0 and 1. But it has to be the same numbers it returns EVERYTIME i run this function (with the same seed code ofcause)  function giveMeNumbers(seed, amount) {      var array = [];      for (var i=0;i<amount;i++)      {           var result = 0; //some cool calculation that always gives the same result           //example: though a bad example.          result = seed * i % 6;          //here I use i to calculate a number but the problem is that i dont want it to be systematic. i mean i only get increasing numbers etc.                         array.push(result);      }      return array; }   So all in all what I want is a non increasing (or systematic) numbers returned. A perfect result could be the numbers:  0.3345 0.8563 0.2234 0.8594 0.1231 etc.  So that there is no system or increment what so ever in the numbers.