How to install two versions of software under Windows 10?

I have two versions of software, one is an old beta version,  one a new distributable version. I need both as they each include specific capabilities. However, the old version refuses to install when a newer version is pre-installed, the newer one auto-deletes the old version upon install. This all in a Windows 10 environment. The software is specific purpose software to fit hearing aids (PhonakTarget).  edit: To emphasize the difference with the previous question I'll elaborate on the situation:  The thing is both software packages use one and the same local database and it would be great when both versions can access that data base. This makes a virtual machine a lesser favorable option. I may be able to work around it (copy the database to the VM or the reverse) but that will increase the chance of making human errors. Best would be to find a solution such that both versions can run on the same Windows install. They do not need to run simultaneously, however.   Stuff I tried but did not work:   installing both versions in a different folder resulted in the same behaviors as detailed above; generating another user in Windows didn't help, because both users have access to the same C:/ components.    Hence, I am stuck. Two options provided under this  I tried above, and generating a virtual disk has the drawback of the split local databases. There is no database on a server or anything; all must be dealt with locally due to safety restrictions in my company (laptops can't access the intranet).


Feasibility of Raspberry Pi 4 render farm

With the recent release of the raspberry pi 4, you can now get a model with 4 gigs of ram as opposed to the old 1 gig and quad core 1.5ghz processor as opposed to a quad core 1.2ghz processor.  I've never tried building a render farm before but at $55 per 4gig pi model, I'm curious what those of you with actual experience think about its feasibility as an affordable farm node (since you could buy 15 of these for the cost of one good gpu not to mention the cost of the rest of the pc to house the gpu).  I seem to recall reading that ram is the biggest concern when rendering large scenes (where insufficient ram causes blender to crash).  So as I write this I suppose there is more than one question:   (the original question) Is the Pi 4 a legitimate contender for a low cost farm node given the new specs? More generally, I have no basis of reference for how complex a scene would need to be to exceed 4 gigs - Can someone provide some insight into this as a realistic or unrealistic challenge?   Thanks in advance for any input!


I want to clip a shapefile in QGis (las palmas) but I get an error:  global name 'features' is not defined See log for more details; what do I do wrong?


Should a toggle button show its current state or the state to which it will change?

I have a quick question about buttons that toggle between two states. (Think Play/Pause, or Shuffle/Regular Play.) As the title says, should the toggle show it's current state or the state to which it will transition?  I think people are used to the Play/Pause convention. But the Shuffle/Regular play might be more confusing if you show the transition state instead of current. For example, the built-in music player on the Xbox 360 does it this way: when it's in shuffle mode, it shows the icon for direct play and vice versa and it always confuses me (am I in shuffle mode or straight play).  I see it this way: Play/Pause is more like action as in begin playing or pause playing. Yes behind the scenes it is a state transition but to the user, there is an action. Whereas Shuffle/Straight Play is an option and it's best to show the current state (and possibly have only one icon and change button to show that the option is enabled/disabled). Thoughts?


How do I get rid of OneDrive completely?

First, I've tried  which is using gpedit.msc Second, I've tried  which is using SysWOW64\OneDriveSetup.exe to uninstall, and deleting of some left over registry keys.  I've rebooted.  And still every time I open explorer, I've got this big p.o.s. banner that makes me absolutely hate even using windows.    How do I get rid of this and OneDrive completely?


How can I rotate the text in a td and keep it center?

I would like to do something like   but I'm not able to do it.  I know how to rotate the text with :  -webkit-transform: rotate(-90deg); -moz-transform: rotate(-90deg); -ms-transform: rotate(-90deg); -o-transform: rotate(-90deg); transform: rotate(-90deg); filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3);   But I don't know how to keep it aligned in the center of the cell.  Could you help me?


Why should I use POST etc methods instead of URL parameters?

We can accomplish the same thing by doing:  localhost:3000/endpoint?var1=val1&var2=val2   That we can do by using POST with a JSON body.  So why should anyone use PUT/POST/PATCH if they can get the same goals by using url params? Even with auth, instead of header, you can send the information of the auth token back and forth by using a parameter?


If we have to evaluate $[(-2)^\frac{3}{8}]^\frac{8}{3}$ would the answer be -2 or 2? My teacher says that in this case the exponents can't be multiplied as they are not natural numbers. Then how do we simplify it solving one bracket in a step?


How can I prove the inequality about integration of complex-valued function

Let $f(x):R\to C$ be a function from real number to complex value. And let we use the defination that if $f(x)=g(x)+i\cdot h(x)$, then $\int_{[a,b]}f(x)dx := \int_{[a,b]}g(x)dx + i\cdot\int_{[a,b]}h(x)dx$. How can I prove the inequality:  $$\left\lvert \int_{[a,b]}f(x)dx\right\rvert \le \int_{[a,b]}\left\lvert f(x)\right\rvert dx$$


Query not going through due to PDO prepare converting my int into string (I think)

So i am filtering my content using the following function:   $queryAll = 'SELECT * FROM :tbl WHERE :column BETWEEN :year AND :endyear';     $queryAll_exec = $pdo->prepare($queryAll);     $results = $queryAll_exec->execute(         array(             ':tbl'=>$tbl,             ':column'=>$column,             ':year'=>$year,             ':endyear'=>$endyear          )         );   Then i check the $result var to see if the query went through and send the object back to the page to call for a fetch there. The problem is, my query is not even going through, I tried checking if it was a mistype on my Query and tested on PHPMyAdmin with the correct values and it does go through. I think it may be a problem with php sending my INTs as strings on the BETWEEN operator.   This is a little bit more of my code for better context:  function getMoviesByFilter($filter,$tbl){     $pdo = Database::getInstance()->getConnection();     $year = '19'.$filter;       if($tbl =='tbl_movies'){         $column = 'movies_year';     }elseif($tbl=='tbl_series'){         $column = 'series_year';     }      $endyear = $year + 9;   This is where i call this function , the information does go through correctly, so I know this is not the issue.  if(isset($_GET['filter'])){         $filter = $_GET['filter'];          $tbl = 'tbl_movies';          if(isset($_GET['series'])){             $filter = $_GET['filter'];             $tbl = 'tbl_series';         }          $getMovies = getMoviesByFilter($filter,$tbl);      }     For anyone that find this answer, the workaround i used once i understood that you cannot bind tables and columns, I used this:   if($tbl =='tbl_movies'){         $queryAll = 'SELECT * FROM tbl_movies WHERE movies_year ';     }elseif($tbl=='tbl_series'){         $queryAll = 'SELECT * FROM tbl_series WHERE series_year ';     }     $endyear = $year + 9;      $queryAll .= 'BETWEEN :year AND :endyear';         $queryAll_exec = $pdo->prepare($queryAll);     $results = $queryAll_exec->execute(         array(             ':year'=>$year,             ':endyear'=>$endyear          )         );


! Package inputenc Error: Unicode char  (U+200B)?

\begin{description}   \item[Public : ] Dans les clouds publics,  \item[Privé : ] Dans les clouds privés,  \end{description}   I don't know why I got the error mentioned in the question knowing that I worked with this syntax before.  How can I solve this ?


Why when I try to delete .. from directory I receive error:  rm: refusing to remove '.' or '..' directory: skipping '..'   And before you ask why I want to do this: Just because.


How should I install HPLIP binary/proprietary plugin/driver for my HP printer or printer+scanner?

Let's assume that one has some modern HP printer and/or scanner which is  supported by HPLIP package from official repository. Or supported by newer version of HPLIP package (see  about installation).  From official documentation () it is known that device needs proprietary/binary driver or plugin.  How should one install such plugin?


Does redshift need an active internet connection to work?

It seems redshift doesn't run without an active internet connection. If so, is there some way it could be run when there's no connection to the Internet?


Verifying how the sum $\sum_{k=0}^n (-1)^k\binom{n}{k}$ works

I'm a little bit confused. This is a very easy question but I'm solving lots of exercises and I want to be crystal clear about that.  I want to verify how this sum works.  $$\sum_{k=0}^n (-1)^k\binom{n}{k}$$  Let's take $n=2$. So we will have  $$(-1)^0\binom{2}{0}+(-1)^1\binom{2}{1}+(-1)^2\binom{2}{2}=2-2=0$$ Is that true ?  Thank you


root login password when I never set it?

Sorry for too many duplicate questions about this. But I don't think any of the answers to these kind of question has the solution for me.  As some users might have asked, how to set root login password when I never set it at installation?  I'm new to ubuntu, and although I used it mainly just for browsing and writing documents, I never use it beyond the standard user wall. Now I'm going to use it to learn develop ruby. My friend helps me over email with the terminal commands sequence needed to set up ruby and rails and whatsoever needed on my ubuntu.  But when I run the first command apt-get update, the OS tells me that it can't lock something something, and finally hinted "are you a root?" Just FYI, this ubuntu is a clean installation on virtual machine, and I just set one account name with one password at the installation. I never get asked about a root password.  I googled about how to run a command as root, and I found that I need to use the sudo command. But when I add the sudo prefix before the apt-get update command, I get asked for root password. I used my first and only account password, and it didn't work.  from what I've read on the internet, I get this conclusion and confusion:   the first user you created on the installation IS a default admin. -- but why I can't use administrator command, and have to requiring sudo? can't I just make my account at the same level as root account? you need to go into recovery mode to reset the root password. -- but the recovery mode is hard to access using virtual machine boot (pressing shift at just THE right time). is there any other way to change the root password?   Thank you for your helps.


Is there a better word for "Enabledness"?

I just ran across the phrase "button enabledness" in a technical design, but that doesn't look right. Is it a valid word? Is there a better way to express "the state of whether or not something is enabled" (even if it doesn't derive from enabled)?


I am having some difficulty with recent software updates and this is not the first time.  By pressing the shift key on startup I can (usually) get the grub menu but when I choose "advanced options" it only shows 2 options: 3.13.0-24 and 3.13.0-24 (recovery mode) whereas I understood it should show previous kernel versions.  I already stick to only LTS versions of Ubuntu. What is a safe way to accept updates in future please? How can I install only the most tested updates? I would like to be able to easily roll them back if they cause problems. In other words I am looking for the Linux equivalent of making a Windows system restore point.  Maybe I should never accept updates but wait until the next LTS version and then upgrade?


How to create a reference/bibliography in LaTeX?

I'm new to LaTeX and I was given a rather complex template to use, I'm having trouble to add a reference/bibliography. I'm using Windows 8.1, Miktex for 64 bit and TexStudio. I have the following line in the template preamble:  \usepackage[backend=bibtex,natbib=true,sorting=none,sortcites]{biblatex} \addbibresource{references.bib}   I've read people use EITHER bibtex or biblatex to add bibliography to a document, whatever those are, but this line includes both bibtex and biblatex. I've created a reference.bib file in the same directory as the main.tex file. The template also has following line near the end and it's giving me "empty bibliography" error.  \printbibliography[heading=bibliography,title={Ном зүй}]   Also, whenever I build the file I get the following warning:  Using fall-back Bibtex(8) backend:(biblatex) functionality maybe reduced/unavailable.   in the blx-bibtex.def file.  And here is my references.bib file's content, it's just a dummy value, I'm not even sure if its syntax is correct  @BOOK{DUMMY:1, AUTHOR="John Doe", TITLE="The Book without Title", PUBLISHER="Dummy Publisher", YEAR="2100", }


This is partly a continuation of  question, since that one was already closed, but my question is about a specific problem encountered the last time I cooked scallops.  I got the pan up to a reasonable temperature and put the scallops in, and as they were cooking, TONS of water came out of the scallops and filled the pan.  I poured it out, continued cooking, and more water came out.  Several iterations later, I thought they were done, but they were still very raw inside, so we ended up tossing the batch (it definitely wasn't sushi grade).  Where did all the liquid come from, and is there any way to avoid that the next time?


Can we construct a function that has uncountable many jump discontinuities?

I know that Dirichlet function has uncountable many discontinuities. I think they are removable, because the discontinuities can be removed by redefining the function values of the rational numbers as 0.  So Dirichlet function is a function that has uncountable many removable discontinuities, then my question is can we construct a function with uncountable  many jump discontinuities? If not, how do we prove it is impossible? Thank you.  An odd but similar question is can we have a function that has uncountable many infinite discontinuities?


I've looked at dozens of other questions and references on the web - and by all my calculations, my setup should work, but it doesn't.  I have nginx installation with php-fpm.  If I try to access a .php file, it runs correctly and I get the correct results.  I got this in my config file:  location ~ \.php$ {     try_files $uri =404;     fastcgi_pass unix:/var/run/php5-fpm.sock;     include fastcgi_params;     fastcgi_param SCRIPT_FILENAME  $document_root$fastcgi_script_name; }   Now, I want to setup my web app so that /somedir/file automatically executes /somdir/file.php while still displaying /somdir/file in the browser's address bar.  So I modified my config to contain the following:  location / {     try_files $uri $uri/ $uri.php?query_string }   This kind of works, that is, the server does access the .php file.  Yet, instead of executing it using the existing location ~ \.php$ block above, it simply spits the php source code as the download into the browser.  If I append the .php manually to the requested URL, then the php is executed.  It feels as if once the server matches try_files to $uri.php, it then does not do another pass at locations to see that what it needs to do with the php files.  I tried putting the php block above and below the location /, but it makes no difference.  How can I get the php to be executed?


Why is energy quantized but mass is not?

According to Einstein's mass energy equivalence equation, $$ E = mc^2$$ where $m$ is the rest mass and $c$ is speed of light. According to Planck's equation, $$ E=hv$$ If Planck's equation suggests that energy can only come in discrete packets, and if mass is equivalent to energy, then wouldn't this mean mass only comes in discrete packets? I saw this  and I found one answer discussing my question, however it was downvoted with no explanation on why it's wrong. The accepted answer's give evidence for why it should be the case that mass is continuous, however, there are a few 'downvoted' answers which suggest the idea I said before and have been downvoted. So, I'm trying to understand why exactly those answers are wrong. Edit: The answer where I saw it in , see answer by user "howyoudoin" and by user "hhh",


package subfig adds overwriting label in list of figures

As said above, this MWE  \documentclass{book} \usepackage{lipsum} \usepackage{subfig} % this breaks list of figures with overwriting labels  \begin{document}  \mainmatter \lipsum \begin{figure}   \caption[Short caption for list of figures]{Long caption} \end{figure}  \backmatter \listoffigures  \end{document}   when compiled with pdflatex, produces the following problem:    whereas without subfig package everything is fine.  Any clue? Thanks in advance.


Why are lines missing when using multicolumn?

Lines are missing between healthy and total column  \documentclass{article} \usepackage[table]{xcolor} \usepackage{multirow} \usepackage{makecell} \begin{document} \begin{table} \centering \begin{tabular}{|c|c|cc|c|c|}  \hline & & \multicolumn{2}{c}{BMI} & \\  \multirow{-2.5}{*}{\makecell{Activity level}} &  \multirow{-2.5}{*}{\makecell{Resting heart rate}} &  {Unhealthy} & {Healthy} & \multirow{-2.5}{*}{\makecell{Total}} \\ \hline Inactive & Normal   & 9  & 13 & 22\\           & Abnormal & 16 & \cellcolor{pink}8 & 24\\ Active   & Normal   & 3  & 28 & 31 \\           & Abnormal & \cellcolor{gray}6 & \cellcolor{gray}17 & 23 \\  \hline Total    &          & 34 & 56 & \textbf{100} \\  \hline \end{tabular}   \end{table} \end{document}


Vertical Circular motion - Tension and velocity

I read through the question  which is quite similar to my questions. But I still have some doubts in the answers -   "The particle will complete the circle when at the highest point if the string doesn't slack at the highest point when θ=π." - Is it because if the rope slacks, then the mg component will pull it inwards and so the particle will not move as a circle? When we talk about conditions for the bob to oscillate (u <= sqrt(2gR)), why do we say that velocity must be equal to zero before tension is equal to zero? And likewise for conditions for leaving the circle, why should tension be zero and velocity not 0? What really is meant by leaving the circle? Is it like following a different parabolic path for some time? Please illustrate.


Miktex amsfont problem: \scriptfont is undefined

Today, After updating Miktex system, I have trouble with error \scriptfont is undefined. So I tried to reinstall Miktex 2.9.4813 (32 bit version). Everything OK, but again after updating, problem is back. I see, that this update related for example file fontspec, amsmath and so on. Does anyone have a similar problem as me?  Texlipse Console:  running: C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\xelatex.exe -synctex=1 -     interaction=nonstopmode --src-specials main.tex --enable-write18  xelatex.exe> This is XeTeX, Version 3.1415926-2.5-0.9999.3 (MiKTeX 2.9) ... xelatex.exe> ! \textfont 173 is undefined (character ???). xelatex.exe> l.126           \item $V_{OH}(3.3V)>V_{IH}(5V)$ xelatex.exe>                                                , xelatex.exe> ! \textfont 53 is undefined (character ???). xelatex.exe> l.126           \item $V_{OH}(3.3V)>V_{IH}(5V)$ xelatex.exe>                                                , xelatex.exe> [395] xelatex.exe> ! \textfont 117 is undefined (character ???). xelatex.exe> l.127           \item $V_{OL}(3.3V)<V_{IL}(5V)$ xelatex.exe>                                                . xelatex.exe> ! \textfont 176 is undefined (character ???). xelatex.exe> l.127           \item $V_{OL}(3.3V)<V_{IL}(5V)$ xelatex.exe>                                                . xelatex.exe> <use  "../src/CES/img/level_shifting_MOSFET.pdf" > xelatex.exe> ! \textfont 100 is undefined (character ???). xelatex.exe> l.153         $V_{OH}(3.3V)<V_{IH}(5V)$ ... xelatex.exe>  xelatex.exe> ! \textfont 52 is undefined (character ???). xelatex.exe> l.153         $V_{OH}(3.3V)<V_{IH}(5V)$ ... xelatex.exe>  xelatex.exe> ! \scriptscriptfont 108 is undefined (character ???). xelatex.exe> l.153 ...tÃm $$V_{GS_{th_{max}}}<V_{OH_{min}}.$$   MWE:    I came to the conclusion that the problem is with the font in mathematical environment.   \documentclass{book}                                 \usepackage[log-declarations=false]{xparse}   \usepackage{xltxtra}   \usepackage{fontspec}      \setmainfont[Mapping=tex-text,Numbers={OldStyle,Proportional}]{Calibri}      \setsansfont[Mapping=tex-text,Numbers={OldStyle,Proportional}]{Candara}     \setmonofont[Numbers=OldStyle]{Consolas}   \usepackage{ifthen}                       \usepackage{amsmath, amsthm, amssymb, amsfonts, amsbsy}   \usepackage{accents}                      \usepackage{unicode-math}        \setmathfont{Cambria Math}    \begin{document}    \chapter{Chapter 1}   \section{Section 1}      $b_{i,j}$ \end{document}     I see another suspicious warning:   Couldn't open font map file "kanjix.map"    This warning came after the update.   Same difficulties are discussed in this


I have this enumeration  Public Enum Applications     Unknown = 0     AA = 1     BB = 2     CC = 3   End Enum   Private Const CALLING_APP As Applications= Applications.CC   CALLING_APP.ToString() is giving me "3". But I want "CC" - what am I doing wrong?


I am looking for a way to have LaTeX render strings of more than one letter as upright (in math mode).  For example, I want it to render   $Hom$ as $\mathrm{Hom}$, $apple$ as $\mathrm{apple}$, $apple + orange$ as $\mathrm{apple} + \mathrm{orange}$,   while rendering   $a$ and $a + o$ as normal.   The answers at  are close to what I want, but they fail the last example.


How do I get linked Google spreadsheets to auto-update when 'I am not looking'

My question is similar to this one, for which no answer has yet been posted.   I am filling one Google Spreadsheet with Zapier which creates new rows of data. I then use ImportRange to take that some data from that sheet into another, where it is processed and generates text that I use to send out emails or SMS.  This 2nd sheet is read by Zapier in order to send the email or SMS.  The problem is that the 2nd sheet does not automatically update when I am not logged in an making changes.  i.e. importrange() is not updating 'when I am not looking'.  I have both sheets set to refresh every minute and Zapier 'reads them' once every 5 mins (writing to the first sheet, only reading from the second").  I have tried any scripts, although I have tried using the Now() function and concatenate() functions in order to amend the data pulled in by importrange() - which did not fix the problem.  The second sheet is a bit complex and takes time to load.


What is the logic behind the expression cat > foo << "wordofchoice"

I know the > and >> operators, > puts something into a file by deleting the old content, >> appends something onto the end of the file's content.   When I only use   cat > foo   I am able to write several lines into foo interactively until I hit ctrl+z, than it ends.   Now, if I add the append operator in the reverse order with some word of my choice  cat > foo << "wordofchoice"   I can do the same as in the first case, but this time a > prompt appears at the beginning of each line and I can not end the interactive input by ctrl+z but by typing "wordofchoice" (without the double quote signs).  Why is it so, what is the logic behind this expression, the << operator does not seem to have its meaning of appending something in here.


ArcGIS Javascript Viewer with ArcGIS Server

I'm certain this question must have been asked/answered, but I just can't find it.    I'm running ArcGIS Server and want to build a basic viewer that points to my locally hosted services.  I'm not interested in doing anything with ArcGIS.com; however all the examples hosted at esri illustrate interfacing with ArcGIS.com.    How can I point to my local map?  Alternatively, can you point me to where I can find the answer (as I'm certain this must have been asked already)


Passing a variable value from a JSP to a Servlet

I am passing a variable value which is gained with in JSP page to a servlet page. I used sessions. But it gives the following NullPointerException.  java.lang.NullPointerException     com.google.api.client.http.GenericUrl.appendParam(GenericUrl.java:599)     com.google.api.client.http.GenericUrl.addQueryParams(GenericUrl.java:582)     com.google.api.client.http.UriTemplate.expand(UriTemplate.java:346)     com.google.api.client.http.UriTemplate.expand(UriTemplate.java:259)     com.google.api.client.googleapis.services.AbstractGoogleClientRequest.buildHttpRequestUrl(AbstractGoogleClientRequest.java:266)     com.google.api.client.googleapis.services.AbstractGoogleClientRequest.buildHttpRequest(AbstractGoogleClientRequest.java:301)     com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419)     com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)     com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)     com.translator.api.TranslatorApi.getTranslate(TranslatorApi.java:66)     control.TextTranslation.doPost(TextTranslation.java:47)     javax.servlet.http.HttpServlet.service(HttpServlet.java:650)     javax.servlet.http.HttpServlet.service(HttpServlet.java:731)     org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)   imageExtract.jsp

             <%             String extracted = (String) request.getAttribute("extractedText");             session.setAttribute("text", extracted);              %>                 <textarea maxlength="200" class=" form-control " name="msg" rows="20" id="Extract-textarea" ><%=extracted %> </textarea>

   TextTranslate.java  protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {      PrintWriter out = response.getWriter();     String language = "ES";     HttpSession extractedText = request.getSession();     String imageName = (String) extractedText.getAttribute("extractedText");     System.out.println("this is so stupid");     System.out.println("This is "+imageName);     TranslatorApi translation = new TranslatorApi();      String outputText =   translation.getTranslate(imageName, language);     System.out.println("Second"+outputText);     request.setAttribute("outputText", outputText);     RequestDispatcher sndValue = request.getRequestDispatcher("/translation.jsp");     sndValue.forward(request, response);  }   The problem is that the session value is not passed to the servlet, which gives a NullpointerException. Why might this be happening?


Using a required argument as a default for an optional one in \newcommand

I'd like to create a new subsection command with the same calling structure like the original one, but I have no idea on how to handle the case when the optional argument is omitted. Basically I want to have newsubsection[Short Title]{Long Title} to call subsection[#1]{#2} and newsubsection{Title} to call subsection{#1}.  I've read  posted here around two years ago, but it seems to have been much more complicated (more than one opt-argument) and I'm too much of a TeX-newbie to transfer the solutions to my problem.  Also, I already tried lots of weird combinations like \newcommand{\subsect}[2][#1]{\par\nolinenumbers\subsection[#1]{#2}\linenumbers} (failed attempt to use the syntax from the \wbalTwo-example ), but none of them were resulting in anything remotely working.


iPad still makes faint noise even though silent mode is turned on

I use an iPad pro 3rd gen 12.9 wifi 256 GB.  I turned on silent mode from the Control Centre and even turned off system volume from settings.  I also turned off the volume of music or video  But, still, faint noise leaks from my iPad's speaker when I play video or music on this condition  How can I turn off the sound perfectly, or is it a flaw of the iPad?  If it is, how can I solve this problem?


time of all guest session login in Ubuntu 14.04

It seems that someone has been using my laptop running Ubuntu 14.04 through the guest session login. I will disable but I would like to know if is it there any possibility to check the date and time of all guest session logins. Is it possible to verify that?


What is the sum of all the Fibonacci numbers from 1 to infinity.

Today I believe I had found the sum of all the Fibonacci numbers are from $1$ to infinity, meaning I had found $F$ for the equation $F = 1+1+2+3+5+8+13+21+\cdots$ I believe the answer is $-3$, however, I don't know if I am correct or not. So I'm asking if someone can show how $F = -3$.


Reading more precision values into vector

I am trying to parse a string line which has comma separated values in and keep in the Vector. The challenge is that i m unable to retain the precision values after certain position. Below is the code which i am trying.     string name = "1, 0, -23.5346 -412.13647, 0, 11.2, 0.4, -2233.12345, 0, 0, 0, 567.46436, 0, 0, 1.654321, 0.1232"      stringstream ss(name);     vector<string> result;     int cc=0;      while (ss.good ()) {             string val;             getline (ss, val, ',');             cout <<"value for "<<cc<< " is "<<std::stod(val)<<endl;             result.push_back(val);             cout <<"cc "<< cc;              cc++;      }       The output i received is   value for 1 is 1 value for 2 is 0 value for 3 is -23.5346 value for 4 is -412.136 value for 5 is 0 value for 6 is 11.2 value for 7 is 0.4 value for 8 is -2233.12 value for 9 is 0 value for 10 is 0 value for 11 is 0 value for 12 is 567.464 value for 13 is 0 value for 14 is 0 value for 15 is 1.65432 value for 16 is 0.1232   In the above code, I am unable to retrain the precision values, for example instead of -412.13647, the value -412.136 is stored. How can i Resolve this issue?


Suggesting an edit on a 0-question but listed tag without the tag creation privilege triggers a server error

I tried to suggest an edit on  where I added the tag c, which at that time existed (as in: was mentioned in  and offered as a completion), but had 0 questions. I do not have the privilege to create tags.  When I pressed the “Save Edits” button, the only feedback I received was the popup ”An error occurred submitting the edit.“ (and, consistently, the suggestion did not get through). A look at the Chrome console showed that  302-redirected to  which returned a 500 error.  Removing the c tag from my  allowed it to go through.  This would only happen on a tag with 0 question but not yet deleted by the nightly cleanup script: for an unlisted tag, the client blocks the submission.


Can we have an unambiguous, official ruling on what the "not an answer" flag is for?

What does the not an answer flag mean? My interpretation is that this flag is intended for things which clearly are not answers. In other words, "this shouldn't exist, because it does not intend to answer the question". It's the difference between a value judgement ("how good is this answer?"), handled with voting, and a clear "this shouldn't exist (as an answer)". The latter is junk that either should have been something else (e.g. a comment, edit etc.) or is clearly worthless (e.g. spam). I think that downvoting is the mechanism for dealing with wrong answers, answers that answer the wrong question, or irrelevant answers. This is important because a moderator may not always have the context to know whether an answer is helpful or not, or may just be wrong. In my opinion, a mod should not be authorised to make such a unilateral value judgement. Is this correct? Are there circumstances where making a value judgement for this flag is acceptable? I'd like a canonical ruling or community consensus to point to for reference for such flag declines. (Context: I am a moderator on . I have a repeated mod flag where the OP believes I should delete  because it doesn't answer his question. However, I believe it is a good faith answer, and I'm happy to watch it stand or fall on its merit. It requires me to understand the question to know whether the answer is or isn't sufficient. I think it is outside of my jurisdiction as a moderator/ to act.)


Backup during installation of ubuntu alongside windows

Is it necessary to create a backup before installing Ubuntu on Windows 7? If so, how do I do that in as little time as possible??


Is there any difference between knowledge and information?

I am confused about find difference between knowledge and information. Give me an example.


Block visibility role section is missing

I am doing development in drupal 8. All of a sudden, I see that block visibility role section is missing.  How can I bring the block visibility role section back?


Windows 10 Wi-Fi issue: "Can't connect to this network"

A little background - I have a Lenovo G50 which was running Windows 8.1 up until a few months back. Then came along the free upgrade to Windows 10. Microsoft updated the laptop OS to Windows 10, and all was fine in the first run.  But, as soon as I shut the laptop down, and powered it back up the next time, it just would not connect to the same Wi-Fi hotspot. This situation continues until today. Every time it's the same message - "Can't connect to this network".   The only way I got around this until now, was to manually reboot the Wi-Fi router, and as soon as the router would come back up, Windows 10 would instantly get connected. I have no idea how/why this worked, but while it did work fine up until sometime back, I can't keep doing this anymore. I share my apartment with a few other guys, and having to disrupt their Internet connectivity every single time I turn on my laptop - is not just a minor convenience anymore (not that they haven't voiced their concerns over this, anyway).  I looked at this  question, and tried to check my "advanced adapter options", but it all seemed correct (attaching pictures below).         All other devices [MacBook Air, MacBook Pro, iPhones, iPads, Windows 8.1 (running on a Dell and an HP)] connected to the same Wi-Fi hotspot in this apartment, work just fine.


friend AND inline method, what's the point ?

I see in a header that I didn't write myself the following:   class MonitorObjectString: public MonitorObject {    // some other declarations    friend inline bool operator==(MonitorObjectString& lhs, MonitorObjectString& rhs) { return(lhs.fVal==rhs.fVal); }   I can't understand why this method is declared as friend. I thought it would make sense if the function is defined in another place and needs to access the internal member of the class, but this is not the case here as it is inline and doesn't even need to have access to the members.  What do you think? Is the "friend" useless?


For set of positive measure $E$, $\alpha \in (0, 1)$, there is interval $I$ such that $m(E \cap I) > \alpha \, m(I)$

I am a graduate student at Iowa State University attempting to return after a five-year hiatus and take the Real/Complex Analysis qualifier on January 8 for potential reinstatement. Since the professors here are on hiatus, I hope you guys don't mind if I bombard the board with a few past questions from our quals here, like this one from Spring 2013:      Let $m$ denote Lebesgue measure on $\mathbb R$ and $M$ the $\sigma$-algebra of Lebesgue measurable subsets. Given $E \in M$ with $m(E) > 0$ and $\alpha \in (0, 1)$, prove that there is an interval $I$ such that $m(E \cap I) > \alpha \, m(I)$.   I've attempted to force the issue using the definition of outer measure but it doesn't seem to work. I've also attempted using the definition of Lebesgue measurability but that doesn't seem to work either - so I'm at a loss!   Thanks in advance!   -Darrin Rasberry


How does Java protect private, package-private, and protected variables?

I am new to Java programming and have a question that I have been curious about. Any help will be appreciated :)  How are private, package-private, protected, and public variables differentiated behind the scenes, so as to keep variables safe?  By safe I mean for example, how does it make sure that private variables are accessible only to methods inside the class?  I want to know what actually happens inside the computer/JVM. Does Java have a different memory space for each of these types? And if so what makes the different memory spaces inaccessible? After all it is still in the memory right?  Thank you in advance :-)


How to ensure 100% code coverage for isSandbox() method branches

I am using the isSandbox() method outlined in the article , to determine whether my current org. is a Sandbox. Sample code from the article: public Static Boolean isSandbox(){          String host = URL.getSalesforceBaseUrl().getHost();         String server = host.substring(0,host.indexOf('.'));          // It's easiest to check for 'my domain' sandboxes first          // even though that will be rare         if(server.contains('--'))             return true;          // tapp0 is a unique "non-cs" server so we check it now         if(server == 'tapp0')             return true;          // If server is 'cs' followed by a number it's a sandbox         if(server.length()>2){             if(server.substring(0,2)=='cs'){                 try{                     Integer.valueOf(server.substring(2,server.length()));                 }                 catch(exception e){                     //started with cs, but not followed by a number                     return false;                 }                  //cs followed by a number, that's a hit                 return true;             }         }          // If we made it here it's a production box         return false;     } }  My org. uses custom subdomain. When I attempt to create a unit test class for this method, it returns success at the first branch, i.e. if(server.contains('--'))     return true;  and skips the rest of the method. This is leading to only 33.33% code coverage. I'm looking for pointers on what strategy can I take here to ensure the whole method is tested? Thanks.


How can I add a custom search engine to Chrome (beta, stable...)?

Call me dumb, but, I don't see an obvious way to do this.   I want to add duckduckgo.com as the main search engine in Google Chrome for Android (beta, stable...)


I know I've seen this documented somewhere before, but what's the option to keep update-manager from prompting for updates except for LTS-to-LTS releases?


Marking someone elses question as answered

The question here:  was asked a long time ago (2009) and earlier this year a solution was given by the user D.A. However, the user (now inactive) that posted the question has not selected it (or any other) as the answer.  After looking at "similar questions" while typing this out (e.g. ) , I see that this discussion has come up before. The counter argument is, "That's what voting is for." Back to the c++ question, the first answer, with 4 votes, is that c++ does not permit the desired behavior. Down below (at zero votes until I voted for it) is D.A.'s answer. Clearly, that counter argument only makes sense regarding answers that happened to be submitted at around the same time period, and have had an equal opportunity to receive votes. I would have completely missed the answer if I hadn't spent the extra time to look at the likely-wrong answers. If the site is to be helpful to users (and not just zombie accounts) then it makes sense for these kinds of answers to be marked as accepted so that they will be seen. Voting, in this scenario, is inadequate.


I have some problems installing cinelerra on my Ubuntu.  How do I install it?


Add Custom Menu at Specific Location in the Header

Blender has a built in template for adding a custom menu to the main header (INFO_HT_header). This can be found by going into the text editor under templates->Python->UI Menu.  Can I relocate this custom menu to be inserted between "Window" and "Help" sub menus? If so, how?


Linux Mint reporting wrong core numbering?

I have the latest Mint installation on an Intel Atom D2550 CPU, which is a dual core processor. When Hyper Threading is enabled in BIOS lscpu reports 4 cores (0-3), which I can also see crunching away in System Monitor.  However, when I turn Hyper Threading off in BIOS lscpu reports:  CPU(s):                2 On-line CPU(s) list:   0,2   So the number of real cores is 2 (which is correct) but their numbering is 0,2 instead of the expected 0,1. The System Monitor also shows 2 cores but one being (always) inactive, like this:    When I list the processes by processor I get half of the processes on P0 and the rest on P2.  How can I report the correct Core/Processor numbers?


What I want to show is the following statement.  For every prime of the form $2^{4n}+1$, 7 is a primitive root.  What I get is that  $$7^{2^{k}}\equiv1\pmod{p}$$ $$7^{2^{k-1}}\equiv-1\equiv2^{4n}\pmod{p}$$ $$7^{2^{k-2}}\equiv(2^{n})^2\pmod{p}$$ Thus $(\frac{2^n}{p})=(\frac{7^{2^{k-2}}}{p})=1$.  I think that $7$ is important because $7$ is a primitive root but I don't know how to use $7$.


How to make this for loop run between 2 array value (value pair) and iterate through all the elements of that array

I want to run a for loop where its initialiser and condition are based on the values of an integer array. for eg:-  int[] array = [0,5,8,12..]      for(initialiser = array[0], condition < array[1], initialiser++)     {         //program condition is satisfied.         break;     }  in the first looop initialiser is array[0] and condition is array[1] in the second loop initialiser is array[1] and condition is array[2] and so on array lenght is not fixed.So far i am unable to make it work efficiently. This is what is have tried.             int idx = 0;             foreach (int id in oId)             {                 if (id != oId.Last())                 {                     for (int k = 1; k < oCnt; k++)                     {                         for (int j = id; j < oId[k]; j++)                         {                             //Logic condition is satisfied vId is an array here                         }                     }                     r[idx++] = vId[0];                 }                 if (id == oId.Last())                 {                     for (int j = oId.Last(); j < totalLength; j++)                     {                         //Logic condition is satisfied vId is an array here                     }                     r[idx++] = vId[0];                 }             }


Is there a reason that a proton has a positive charge while an electron has a negative charge?  Are these just names that were given to the charges or was there a reason for making a proton have a positive charge?


On the  says that  was opened 2014 years ago. Can this be fixed please?


How do I merge 2 VMware disks in to a single one?

I have installed an Ubuntu server on a VMWare workstation with a space of 20GB storage as seen below:    After the installation I've attached another 40GB worth storage to the existing Ubuntu server installation (seen below):    Now I want to add this 40GB to my / (root) directory it mean's  I want that my / directory became to 60G , like it will be resize from 20G to 60G (20G + 40G), i don't know what should i do, can any body help me ?  , my df -h result shows;  root@Userver:~# df -h Filesystem      Size  Used Avail Use% Mounted on /dev/sda1        18G  900M   16G   6% / udev            990M  4.0K  990M   1% /dev tmpfs           400M  308K  399M   1% /run none            5.0M     0  5.0M   0% /run/lock none            999M     0  999M   0% /run/shm none            100M     0  100M   0% /run/user root@Userver:~#   it must be 60G !  i have no graphic mode, then i can't use Gparted tools, i'm just have ssh access !


Javascript | Mongodb Substring Not Being Found in query using regex

I am using a substring value of "data" to search fields in the database having a substring "data" in them. I currently have two fields of that type. Running the code with hard-coding " /data/i " in the "title" field returns the result but when I insert the variable substring to the query for "title" it returns an empty array.     WORKS   router.post('/search',function(req,res){   let substring = req.body.substring;   console.log(substring);   substring = ('/'+substring+'/i');   console.log(String(substring));       data.find({title:/data/i},function(err,found){ //works here           if(err) console.log(err);         console.log(found);         });     });      Does Not Work   router.post('/search',function(req,res){   let substring = req.body.substring;   console.log(substring);   substring = ('/'+substring+'/i');   console.log(String(substring));       data.find({title:substring},function(err,found){ // doesnt work here          if(err) console.log(err);         console.log(found);         });     });


Both my husband and my sister are know-it-alls who try to do everything without knowledge or ability to do so.  My husband wants to remove my dogs sutures to save money.  My sister's motivations are often the same--to save money.  What is this person called?


Adding separate title in the Appendix environment

I would like to add the title of a document that is an appendix. How can I do it? If I run this code, the title is not displayed.   \documentclass[10 pt,a4paper,oneside,openany]{article} \begin{document} \title{Title\footnote{Disclaimer.}} \author{XX\thanks{University.}} \begin{appendix} \section{The game} \label{unilateral} blah \end{appendix} \end{document}


Purpose of '~/.cache' directory and when is it safe to delete?

What is the purpose of every user's ~/.cache directory?  Under which circumstances can it be deleted, when should one be careful about its contents?


I restarted my iPhone 6 running iOS 10 and the home button is broken, so I was using Assistive Touch. But at the first launch, Assistive Touch is disabled. On iOS 10, we have to "Press home button to unlock".  What can I do?


What is the lifetime of the arrow indirection operator (operator->) return value?

While a normal overload of the arrow operator typically returns a plain pointer, as  notes, it doesn't have to:     The overload of operator -> must either return a raw pointer, or return an object (by reference or by value) for which operator -> is in turn overloaded.   When the operator returns an object by value, what is the lifetime of that object?  Naively, I could imagine two different ways of it working. Either the returned object is lifetime preserved until the statement is complete, or the returned temporary is "discarded" immediately after the subsequent operator-> is called on it.    For example:  class A {     class A_sub {          A_sub(...);          int foo();     }      std::unique_ptr< A_sub > operator->() {         return std::make_unique< A_sub >(...);     } }  int main() {     A a;     int val = A->foo();     return val; }   When is the destructor for A_sub permitted to be called? Is it prior to the call to foo(), or is the returned unique_ptr lifetime preserved until foo() completes? (Does it depend on deep the drill down behavior goes?)  It seems to me that the "obvious" answer would be that all operator-> return values would be preserved until the ultimate completion of the statement (due to lifetime issues as demonstrated above), but I'm unsure if the C++ standard guarantees such ordering.


SQL query structure and PDO, does bad query structure allow SQLi possibility?

Okay so I have been web developing for a little while now and I have some questions regarding PDO and SQL injection. As we all know SQL injection is a horrible vulnerability that we all want to avoid to our basic capability. I understand that SQL injection is most commonly done by using ' in a data which breaks the query, such as the infamous:   ' or '1'='1   I sometimes get lazy and usually my PDO SQL queries end up like this:  SELECT * FROM users WHERE id = ?   (I'd then bind ? to the $_GET['id'] or something) Now notice I don't use ` or ' anywhere in the query, is SQL injection still possibly after prepared statements? What exactly does prepared statements stop? Thank you!


"Empty Bibliography" error when compiling Biblatex

So I have been banging my head against a brick wall literally all day. I have tried 3 different Latex editors (Texmaker, TeXstudio, and Texworks) all on top of MikTex. I have tried copying code from others as well as writing my own, with some extremely basic examples such as:   \documentclass{article}  \usepackage{lipsum}  \usepackage{biblatex} \addbibresource{sample.bib}  \begin{document} \lipsum[1] \cite{ref:123}  \printbibliography  \end{document}   Where my sample.bib looks like:  @book{ref:123, author = {456}, title = {855}, year = {2464}, }   and is saved in the same folder as the Tex file. Any suggestions on how to produce a bibliography would be greatly appreciated, I'm new to Latex!!  The latest:   When I BibTex the document I get this:


I'm going to install Linux on Lenovo B5400, which contains:   500GB Hybrid SSHD with a 8 GB SSD and 500 GB HDD   Designing partitions for my 2 Linux distros was quite easy before, when I had only HDD. I always had:   10GB for Linux distro (mounted as "/") 10GB for another distro (again "/"; for another distro; for testing purposes or to assure continuity when switching distros) 2GB for swap (used for both distros; no need to separate) 300GB+ for "/home" (used for both distros; different usernames eliminates possible conflicts)   It's simple, isn't it? I would like to keep this approach, but I know that SSD has its own specificity - it prefers to be read, continuous writing may affect its life span. I don't want to kill SSD in a year, so I would like to move some system partitions to HDD in order to protect SSD. As far as I know /tmp is one of often read&written locations. How much space it needs? What else should be placed on HDD?  Or: how to design partitions to achieve exactly the same effect and to keep SSD as safe as possible?  I'd be grateful for your help.


Which sentence is correct?     I will go to your office tomorrow.   I will come to your office tomorrow.   Sometimes I hear people use "come" and sometimes "go."


How can I turn off mirroring in sculpt mode?

So, I am extremely new to blender, I am going to say outright. I have tried to fix this, but i can't seem to find any option that would fix the problem. When I sculpt on an object, it directly mirrors it, even though i have not enabled the mirror function, let alone touch it. I have double checked to make sure mirror wasn't on and it wasn't. and so on and so forth. I pretty much haven't changed any options or anything. if you could help me figure this out, that would be nice.


Prove that $\lim_{n \to \infty} \sqrt[n]{a} = 1$ using only the basic properties of sequences

Prove that $\lim_{n \to \infty} \sqrt[n]a = 1$ using only the basic properties of sequences  I don't have an idea on how to tackle this problem - I thought about the Squeeze Theorem but I can't think of a sequence of n which approaches 1.  Could you give me some hints on how to solve this? If it is possible, please, choose the least sophisticated method to solve this as I am entirely new to Calculus.


Why does SHA-2 call for doing 10* padding in addition to appending the message length?

Appending the length of the message when padding of a SHA-2 message is sufficient to satisfy the Merkle-Damgård construction.  However the padding in SHA-2 also pads with 10* between the end of the message and the message length data.  I know that 10* padding lets one turn non-block-aligned length messages into block-aligned length messages in a reversible way.  However, because the padding already encodes the bit length of the original message, this 10* padding is redundant.  Using the bit length data we can already determine where the original message ends and 0* padding would be sufficient.  In fact, in "One Way Hash Functions and DES. Advances in Cryptology" in Crypto’89, Merkle uses 0* padding followed by the length.  So my question, why does SHA-2 call for doing 10* padding in addition to appending the message length?


Simple past tense agreement in noun clauses: "I heard you are the best..." vs. "I heard you were the best"

Supposing that the subject of the noun clause is, in fact, presently, and intrinsically, the best, would the correct sentence be:     I heard [that] you are the best man for the job.   or     I heard [that] you were the best man for the job.   or perhaps either?  The argument for the former is that "is" more accurately represents the time window during which the subject is the best, whereas the argument for the latter is that tense agreement between "heard" and "was" is aesthetically pleasing.  Perhaps also supporting the latter is that "was" does not contradict "is"—per Hedberg, 1990s: "I used to do drugs. I still do, but I used to, too."


You can say that you gifted someone something but is this usage correct?     I've been gifted a new phone by my friend


How to work around "Something wicked happened resolving" errors

after this string in terminal - sudo apt-get install apache2 - it gives me errors  Failed to fetch  1_1.5.2-1_amd64.deb Something wicked happened resolving 'archieve.ubuntu.com:http' (-5 - No adress associated with hostname)  What to do ???


I was using the Transparent BSDF node on a mesh, but even when I set it to full transparency there are some strange black areas that refuse to disappear. They change somewhat with the camera angle.      How do I get rid of these artifacts? I'm using Blender v2.79b.


Imgur image removal request being ignored... Stack Exchange help unanswered

I requested Imgur to remove a copyrighted image on the Imgur website which was originally posted on Math Stack Exchange.  This request has been ignored for a long time now. This image has been removed from the Math Stack Exchange question but is still existing in the link ... . Even the Stack Exchange help (contact form) has been unanswered yet. How to have this image removed?


This post shows a sequential computation of the sample covariance matrix:  Original $$\hat \Sigma_n = \frac{1}{1-n}\sum_{i=1}^n (X_i-\hat \mu_n)(X_i -\hat \mu_n)^\top$$ Sequential $$\hat \Sigma_n = \frac{n-2}{n-1} \Sigma_{n-1} + \frac{1}{n} \Delta_n\Delta_n^\top \quad \text{with} \quad \Delta_n = X_n - \hat \mu_{n-1}$$ How can this be extended to batch updates?


I want to be able to write text as 'raised to power' without mathmode. E.g. how can I write this without textmode?  $\text{Some text}^{change}$


What will happen if I close the terminal in the middle of an upgrading process?

Accidentally, I closed the terminal in the middle of the process of   sudo apt-get upgrade firefox   Is this dangerous? If any one has this experience then please share your problems and errors which you have got.


Installing Ubuntu 16.04 LTS on eMMC storage

I'm experiencing a problem installing Ubuntu on my new laptop. It originally had windows 10 Home version, but I wiped out the disk (eMMC) and tried to install the Ubuntu. However, I believe the storage type is not suitable for Ubuntu... I've lost Windows 10 and am unable to install any OS, which makes the laptop useless.  I want to install Ubuntu. The laptop I'm trying to install is  Acer Aspire One Cloudbook 14.


Automatically install package dependencies with terminal

I have a .deb file in my downloads folder than i need to install with a bunch of dependencies.  What is a command that will install the package with the dependencies.  I know this is probably a duplicate but i just want the command to install the package from the downloads folder and automaticly install dependencies, because i don't know much about the terminal


How could I store decimals in a collection c#?

I am trying to write a program that could catch user input of string type. Every time there is a space within this string, the program needs to get that part of the string and try to parse it to a decimal. The entries might be numbers that might be separated by a comma rather than just plain integers, that is why I would be using decimals instead of integers.  This is what I tried so far:  static void Main(string[] args) {     Console.WriteLine("C# Exercise!" + Environment.NewLine);     Console.WriteLine("Please enter two numbers seperated by space to start calculating: ");     string[] input = Console.ReadLine().Split(' ');     //Currently allows for more than one value... I am not necessarily looking for a solution to this problem however.     Console.WriteLine(Environment.NewLine + "Result: ");     //Create the collection of decimals:     decimal[] numbers = { };     numbers[0] = 1.0m;//<-- Results in a System.IndexOutOfRangeException     for (int i = 0; i < input.Length; i++)     {         Console.WriteLine(input[i]);//<-- This value needs to be converted to a decimal and be added to a collection of decimals     }     /*decimal numberOne = ?? //<-- First decimal in the collection of decimals     decimal numberTwo = ?? //<-- Second decimal in the collection of decimals     Console.WriteLine(SumTrippler.Calculate(numberOne, numberTwo));*/     Console.WriteLine(SumTrippler.Calculate(decimal.Parse("0.5"), (decimal)0.5));//<-- Irrelevant method     Console.ReadKey(); }   How could I get two decimals as user input from the user and process this data by passing it to the method at the bottom of my program?  Edit: Closing this question because you are trying to relate a question that adds a string to a list is not a solid reason. I am not trying to add a string to a list.


I think my CMS might force me to have URLs that look like these:   domain.com/products/new-products/ domain.com/products/used-products/   Instead of:   domain.com/new-products/ domain.com/used-products/   Assume that I was trying to optimize for "new products" and "used products". Will having the URLs my CMS might be forcing on me be bad for SEO? I could do something like this:   domain.com/products/new/ domain.com/products/used/   (but I don't think these are optimizing for "new products" and "used product" due to the ordering of the key words)


Find number of ring homomorphisms from $\mathbb Z_{12} \to \mathbb Z_{28}$.  This question has been asked before but I found the solution confusing.Please check whether my approach is valid.  A ring homomorphism satisfies $f(x+y)=f(x)+f(y);f(xy)=f(x)f(y)$  A ring homomorphism must first be a group homomorphism.  So $f$ will entirely depend upon its image on $[1]$.Now $o(f([1]))$ must divide both $12,28$.Hence $f([1])=0;f([1]=[7],f([1]=[14]$  But if we take $f([1])=[7] $ then it will fail to be ring homomorphism as $f[nm]=[7][nm]\neq [7m][7n]$  if we take $f([1])=[14] $ then it will fail to be ring homomorphism as $f[nm]=[14][nm]\neq [14m][14n]$  Thus only one available is $f([1])=[0]$ .Is it correct ?  Please help.


Formal version of "stuck in one's old ways"

I want to convey the meaning of "stuck in one's ways" or "stuck in one's old ways" in a formal way.  Consider the sentence:     The organizations are, for now, very much _______________.


How can I use the random function with variables that are words?

I'm creating a project where the person is supposed to respond and this randomizer is supposed to send a random response that would either be in the category of yes and no.


What about $Z[i]/\langle a+ib\rangle$ if $\gcd (a,b) \ne 1$?

We are to find number of elements and charecterisstic of $R =$ $Z[I]/\langle 2+2I \rangle$. Here $\gcd (2,2) \ne 1$ .So I can't say that it is isomorphic to $Z_8$ . By the fact that $Z[i]$ is ED I can say that $R$ has those elements which have norm $0$ to $7$.But then I have $0,1,i,-1,-i,1+i,1-i,\dots$ "so on ! Is it true? It seems horrible to me to find charecteristic from my observaation (not sure is true). So ,I need a hint , thanks for reading!


Is the Belters' accent based on any non-fiction accent?

When Belters in The Expanse speak English, they do so with a particular accent. It sounds vaguely familiar to me, but I cannot identify it. I'm not a native English speaker myself. Is that accent based on any non-fiction accent? Which one? Ideal answers would quote the artists involved, but lacking that, your opinion as a listener is welcome. I'm aware of  with a great answer about their language, but nothing about the accent.


What command does Unity use to launch a program

For work I need to use the IBM Lotus Notes e-mail client. I have installed it without much problem, but I'm having troubles in launching it when I start the pc. The problem is that I can't find how I can launch the client from the terminal, so I can't put it in the startup list.  As of right now, I start the client by searching in my Unity for 'Notes' and this brings up the client and I just press enter to start running it. Is there a way I can figure out which command Unity uses to start the client so I can add it to the startup list?


Humans, animals and birds all have two eyes. Why? In addition to why two instead of one, why aren't there more than two?


Four tasks in parallel... how do I do that?

I have a bunch of PNG images on a directory. I have an application called pngout that I run to compress these images. This application is called by a script I did. The problem is that this script does one at a time, something like this:  FILES=(./*.png) for f in  "${FILES[@]}" do         echo "Processing $f file..."         # take action on each file. $f store current file name         ./pngout -s0 $f R${f/\.\//} done   Processing just one file at a time, takes a lot of time. After running this app, I see that the CPU is just 10%. So I discovered that I can divide these files in 4 batches, put each batch in a directory and fire 4, from four terminal windows, four processes, so I have four instances of my script, at the same time, processing those images and the job takes 1/4 of the time.  The second problem is that I lost time dividing the images and batches and copying the script to four directories, open 4 terminal windows, bla bla...  How do that with one script, without having to divide anything?  I mean two things: first how do I from a bash script, fire a process to the background ? (just add & to the end?) Second: how do I stop sending tasks to the background after sending the fourth tasks and put the script to wait until the tasks end? I mean, just sending a new task to the background as one tasks end, keeping always 4 tasks in parallel? if I do not do that the loop will fire zillions of tasks to the background and the CPU will clog.


Is there a monoid structure on the set of paths of a graph?

Given a graph G, and the set of paths in G called PathG.  Is there a monoid structure on PathG? Will concatenation be the multiplication formula? even if it's not defined for some paths?  What about the identity?


I've just completed a fresh install of 18.04. An install of NVDIA drivers failed and now my resolution is 1024x768. I've attempted to go to a tty so I can install the drivers without the console running. However using CTl-ALT-F3 or F4 just bings me to a black screen with no prompt. I can get back to the GUI by using CTL-ALT-F2.   What can I do to get to a tty?


I'm new to developing web sites, and I've seen a lot of sites that use Google hosted libraries... Is there any advantage in using Google Hosted Libraries instead of local versions?


I have centos 6.4 64 bit and I accidently uninstalled my php-mysql extension, as a result my wordpress site is down.  I need to install php-mysql (note, I prefer to get mysqlnd, but first I just need to get mysql installed again)  I run yum install php-mysqlnd and I get the following errors:  Error: Package: php-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libcrypto.so.10(libcrypto.so.10)(64bit) Error: Package: php-cli-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libcrypto.so.10(libcrypto.so.10)(64bit) Error: Package: php-cli-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libssl.so.10(libssl.so.10)(64bit) Error: Package: php-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libcrypto.so.10(OPENSSL_1.0.1)(64bit) Error: Package: php-cli-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libcrypto.so.10(OPENSSL_1.0.1)(64bit) Error: Package: php-5.4.24-1.el6.remi.x86_64 (remi)        Requires: libssl.so.10(libssl.so.10)(64bit)   I have done some research and it seems it has to do with centos 6.4 shipping with the ssl 1.0 instead of 1.0.1 which is a dependency for mysqlnd.  So I tried to install the above libraries and it worked, but the errors keep appearing so I can't install mysqlnd so I can't use my website.  Any suggestions?


J2ME radio app error. NullPointerException

I am writing application in java for mobile devices. I am now trying to detect range of radio in phone. In Sun Java WirelessToolkit simulator it works, but on my Nokia 301 it show error java.lang.NullPointerException. I dont know where is the problem. Code:  package mobileapplication5; import javax.microedition.media.*; import javax.microedition.media.Control.*; import javax.microedition.amms.control.tuner.*; import java.util.Date; import javax.microedition.lcdui.Alert; import javax.microedition.lcdui.AlertType; import javax.microedition.lcdui.Display; import javax.microedition.lcdui.Form; import javax.microedition.midlet.*;  public class Midlet extends MIDlet {     public Player radioPlayer;     public TunerControl tunerControl;      public Form form;      public void startApp() {         Display display = Display.getDisplay(this);          form = new Form("Radio Test");         display.setCurrent(form);         try {             radioPlayer = Manager.createPlayer("capture://radio");             radioPlayer.realize();             tunerControl = (TunerControl)             radioPlayer.getControl("javax.microedition.amms.control.tuner.TunerControl");             tunerControl.setStereoMode(TunerControl.STEREO);              radioPlayer.start();              int maxFM = tunerControl.getMaxFreq("fm");             int minFM = tunerControl.getMinFreq("fm");             String tx = Integer.toString(maxFM);             tx = tx + " - " + Integer.toString(minFM);   form.append("SET FM: "+tx);          } catch (Exception ioe) {             form.append("initializeRadio ioe "+ioe);         }      }      public void pauseApp() {     }      public void destroyApp(boolean unconditional) {     } }   Thanks.


What are the home and net folders I see within finder?

While a similar question was raised , it doesn't seem to be a solid answer but more of a theory. In addition my case is a bit different as you will see below.    You will note that I have two home drives, one being a mount to a share on my NAS and the other in question being the one within localhost.  What value do the home and net drives within localhost serve other than being part of default *nix folder structure? Is this anything more than a local representation that exists by *nix default? Is it safe to eject these drives or is the OS using them in some fashion which may not be readily apparent?


Why do electromagnetic waves become weaker with distance?

From what I know, In electromagnetic waves, the components electric field and magnetic field generate each other i.e. magnetic field generated from moving electric charge generates another electric field and which also generates another magnetic field and so on thus, creating an electromagnetic field. So each of them gets weaker with distance which results in weaker EMF. Am I correct here?


Understanding shadow dom in Lightning web components

I'm looking at the shadow Dom in the lwc developer guide and found below  statements.   Shadow DOM is a web standard. To make development easier for component authors, the Lightning Web Components shadow DOM works a bit differently than the web standard.One difference is that the shadow DOM for a Lightning web component is created automatically. The component author doesn’t have to implement it (no need to use the attachShadow() or appendChild() methods). Also, a Lightning web component’s shadow DOM works even on platforms that don’t natively support shadow DOM, such as some web browsers. Since Lightning web components don’t use the native shadow DOM yet, you can’t view their shadow DOM in Chrome Developer Tools. Even if you enable Show user agent shadow DOM, you don’t see the shadow DOM.      My Question: Is shadow dom in lwc used just to encapsulate framework   methods? Also is there anything a developer need to keep in mind   while working with lwc in terms of shadow Dom?


I brought this up. - 0  I did bring this up. - 1  I did brought this up. - 2  Is it ever acceptable to use (2)? I have a vague memory from high school that the second tense is something rarely used to emphasize or exaggerate the idea, stronger than the previous 2 (in this order). Example:  Are you silly? Don't you remember? I did brought this up.  I also have a feeling this is a lesser known grammar fact that few people are aware of, so I am afraid that if I do use it, the larger public will frown.  That said, it's also possible that I am very wrong.  Please, input ideally from natives or C2 speakers. I consider myself very advanced, but I have, however, been having this doubt.   Thank you so much in advance!


Python 3: How can I remove time? I just want the number of days

Right now I have this code. I am intending to write code that calculates the number of days between today and January 1 of this year.  As you can see in the output below, it prints the number of days and the time.  How can I rewrite the code so that it says just '78', not '78 days, 21:04:08.256440'?  from datetime import datetime Now = datetime.now() StartDate = datetime.strptime(str(Now.year) +'-01-01', '%Y-%m-%d') NumberOfDays = (Now - StartDate)  print(NumberOfDays)   #Output: 78 days, 21:04:08.256440


How to create an Event Notification that runs a Job/procedure when mirroring state changes

I'm asking this question in the sequence of this one   Remus Rusanu exposes what it seems to be an optimal solution for my problem, but... I'm too immature to understand and make everything he says.  So far I think what I need to create a notification event for DATABASE_MIRRORING_STATE_CHANGE, am I correct?  how can I create this event notification to when its triggered inserts a line in a table, that stores a timestamp and an ID that comes from the notification.  so far I'm setting up one alert per ID, each one running a job like this(this example is  for ID = 1):      DECLARE @state AS varchar(50);     SELECT @state = mirroring_state_desc FROM SYS.database_mirroring WHERE mirroring_guid IS NOT NULL;     IF (@state IS null) SET @state = ' ';     INSERT INTO MirroringAlerts (DateTime, alertID, alertDesc, Sync, alertCreator) values (SYSDATETIME(), 1, 'Principal synchronized with W ', @state, @@SERVERNAME)   Basically I'm creating an internal log in this database:  CREATE TABLE [dbo].[MirroringAlerts](     [DateTime] [datetime] NOT NULL,     [alertID] [smallint] NOT NULL,     [alertDesc] [nchar](50) NOT NULL,     [Sync] [nchar](12) NOT NULL,     [alertCreator] [nchar](128) NULL ) ON [PRIMARY]   But this way...the alerts are not being triggered fast enough...so I'm loosing information...  Can you tell me how to program this behaviour with  for ?  Best Regards


So, I'm a total Java newb and I wanted to make an animation program but I wanted to do it my own way so I understand how it works, I know there may be other questions like this but I wanted to know the answer using the code I made, so here is my code, the problem is when I run this the box doesn't show up on the window and looking at my prints it stops right before i set the color. Can anyone help?  import java.awt.Color; import java.awt.Component; import java.awt.Graphics;  import javax.swing.JFrame; final public class main extends JFrame{     private int x = 20;     private int y = 20;      private boolean right = true;     private boolean left = false;     private boolean down = true;     private boolean up = false;      public static void main(String[] args){         JFrame JFrame = new JFrame("On My Own (kinda)");         JFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);           JFrame.setVisible(true);         JFrame.setLocation(375, 55);         JFrame.setSize(300, 300);         new main().Animate();     }      public void draw(){         System.out.println("2");         Graphics g = getGraphics();         System.out.println("3");         g.setColor(Color.BLACK);         System.out.println("4");         g.fillRect(x, y, 6, 6);         System.out.println("5");     }      public void Animate(){         System.out.println("1");         while(true){             //Game loop             if(x >= 283){                 right = false;                 left = true;             }             if(x <= 7){                 right = true;                 left = false;             }             if(y >= 259){                 up = true;                 down = false;             }             if(y <= 7){                 up = false;                 down = true;             }             if(up){                 y--;             }             if(down){                 y++;             }             if(left){                 x--;             }             if(right){                 x++;             }             try{                 Thread.sleep(10);             } catch (Exception exc){System.out.println("OOOPS");}             draw();         }     }  }   And this is what I get  1 Exception in thread "main" java.lang.NullPointerException     at main.draw(main.java:30)     at main.Animate(main.java:71)     at main.main(main.java:23) 2 3


Avoid en dashes from sticking out of the text body with microtype

When using microtype, en dashes seem to extend beyond the text body if they appear at the beginning or end of a line. How can I get around this?  MWE:  \documentclass{article}  \usepackage{mathpazo} \usepackage[activate={true,nocompatibility},final,tracking=true,kerning=true,factor=1100,stretch=10,shrink=10]{microtype}  \begin{document}  Hello, here is some text without a meaning. This text should show what a printed text will look like at this place. If you read this text, you will get no information. Really? Is there no information? Is there a difference between this text and some nonsense like “Huardest gef- burn”? Kjift – not at all! A blindinginng -- enter text here -- text like this gives you information about the selected font, how the letters are written and an impression of the look. This text should contain all letters of the alphabet and it should be written in of the original language. There is more text in this line until it happens and we need more -- this is important -- no need for special contents, but the length of words should match the language. This is the second paragraph. Hello, here is some text without a meaning. This text should show what a printed text will look like at this place. If you read this text, you will get no information. Really? Is there no information? Is there a difference between this text and some nonsense like “Huardest gefburn”? Kjift – not at all! A blind text like this gives you information about the selected font, how the letters are written and an impression of the look. This text should contain all letters of the alphabet and it should be written in of the original language. There is no need for special contents, but the length of words should match the language.  \end{document}     Palatino seems to make this problem even more visible.  Update after initial replies:  I don't want to get rid of protrusion at all. However, the dash looks really misplaced to my eye. I have tried the following but cannot find a way that actually shows any effect:  \SetProtrusion  { encoding = {T1,OT1},    family   = {ppl,pplx,pplj} }    {-- = {0,0}}


How can i wait on severals threads completed their code?

I want to count Words with several Threads and every thread has a "wordCount" variable. Now how can i wait till every thread is finished? At the end i should count every variable of each thread together and print it out?  How i create my Threads:  for (int i = 1; i <= THREADS_TO_USE; i++) {     long bytesToRead = splitManager();     new Thread(new CountWordsThread(file, bytesToRead, bytesCounted)).start(); }


i want to know what is intptr_t ? what means of (_t) ? is it the first word of (tree) or what?  for example in nginx web server , what is ngx_xx_t (_t) ?  what is diffrent between (ngx_xx_t ) and (ngx_xx_s) ? what is (_t) and (_s) ? (Abbreviation)


*/5 * * * * root ruby /opt/redmine/extra/svn/reposman.rb --redmine-host http://tracker.intranet.****.com.ar --scm Mercurial --svn-dir /opt/repos/hg --command "hg init" --owner www-data --url http://repos.****.com.ar/hg --key=1EV2OGLL2h >> /var/log/redmine_repos.log 2>&1 0 9 * * * root cd /opt/redmine && /usr/local/bin/rake redmine:send_reminders days=7 RAILS_ENV="production"   It is not being executed.  drwxr-xr-x  2 root root 4096 ene 11 16:54 . drwxr-xr-x 97 root root 4096 ene  9 20:19 .. -rw-r--r--  1 root root  510 ene 11 18:09 php5 -rw-r--r--  1 root root  102 feb  9  2013 .placeholder -rw-rw-rw-  1 root root  398 ene 11 19:00 redmine root@tracker:/etc/cron.d#    I had to execute the first line manually, and it succeeded. Any tips on why isn't it running? I copied it from a running Ubuntu 12.04 updated to 14.04.  My SO is Ubuntu 14.04 Server  I know it is not getting executed because the task it should make is not being done and also no log is created.  EDIT:  /etc/crontab:  # /etc/crontab: system-wide crontab # Unlike any other crontab you don't have to run the `crontab' # command to install the new version when you edit this file # and files in /etc/cron.d. These files also have username fields, # that none of the other crontabs do.  SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin  # m h dom mon dow user  command 17 *    * * *   root    cd / && run-parts --report /etc/cron.hourly 25 6    * * *   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily ) 47 6    * * 7   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly ) 52 6    1 * *   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly ) #   Ruby:   root@tracker:/etc# which ruby /usr/bin/ruby


Limit Involving a Product of a Sequence: $\lim _{x\to\infty }\left(1-\frac1{2^2}\right)\left(1-\frac1{3^2}\right)\dots\left(1-\frac1{x^2}\right)$

I am having trouble figuring out how to solve this limit.      $$\lim _{x\to \infty }\left(\left(1-\frac{1}{2^2}\right)\left(1-\frac{1}{3^2}\right)...\left(1-\frac{1}{x^2}\right)\right)$$   I understand that as '$x$' increases, the overall product becomes an even smaller number between $0$ and $1$  only because I tried plugging in numbers in hope to learn about the nature of the expression. But I can't seem to come to a pattern that will allow me to efficiently simplify it and solve the limit.   Help, anyone?


Web architecture for remotely executing python scripts

Task at hand : Host a web-server application, which upon request, executes python scripts which are reachable by the server Background: I have a collection of independent python scripts/projects, which when executed, generate a zip file of content. As the source code in these scripts are confidential, I need to host these scripts on a web-server. The idea would be that a separate desktop application is written which communicates with the web-server. A GET request for 1 would execute python project A, and a GET request for 2 would execute python project B. In each instance, the server would grab the output and send the ZIP file back to the originator of the request. Question: What hosting set-up would be considered fitting for this problem space? Do any of the amazon services check the boxes that would give me constant up-time with persistent storage? if not, is this what a Virtual Private Server is designed for? Considerations:  Needs to support Python 3.8 Each GET request would return a ZIP file of between 200KB and 1MB Approximately between 0-200 GET requests per day Between 1-200 Python Projects available to be executed. Each around ~5MB. Adding more python projects should be achievable with degree of ease While not a critical service, GET requests need to be allowable 24/7 - anywhere in the world. i.e. no long spin-up time. Self-hosting is not an option Storage of the python scripts should be safe from loss (but of-course other back-ups would be done)


Question about for loop and extracting parts of the name to use borg create command

I have a folder called sync which includes files like :   vzdump-lxc-101-2018_06_07-02_23_11.tar vzdump-lxc-101-2018_07_20-03_04_22.tar vzdump-lxc-101-2018_08_17-03_34_11.tar vzdump-lxc-101-2018_09_17-02_44_50.tar vzdump-lxc-101-2019_01_19-00_16_02.tar ... vzdump-lxc-104-2018_06_30-01_50_23.tar vzdump-lxc-104-2018_07_20-03_18_56.tar vzdump-lxc-104-2018_08_17-03_40_15.tar vzdump-lxc-104-2018_10_19-01_52_00.tar vzdump-lxc-104-2018_11_06-02_39_07.tar vzdump-lxc-104-2019_01_19-00_24_14.tar   Ranging from vzdump-lxc-100 to vzdump-lxc-1xx etc..  I'm trying to loop over all files in a given directory and do a borg create (...) /path/to/repo::vzdump-lxc-$ID-$year_$month_$day "$f" but I'm not sure how to cut the name to just these three points  I tested it with the following : for f in vzdump-lxc*; do borg create (...) /path/to/repo::srv01_lxc_"$f" "$f";done , but this gives me the full name which is too long including the leading vzdump-lxc, hour, minute, second and the extension maybe someone could lead me in the right direction.  I'm trying to achieve /path/to/repo::srv01_lxc_$id_$year_$month_$day  Cheers


In shell, check what /bin/sh is symlinked to

In Shell script, How can I check if /bin/sh is softlink'ed to dash or bash, I may have /bin/sh -> dash or /bin/sh -> bash


Items Unpinned from taskbar re-appear after reboot on Windows 10

I just had to have my laptop re-imaged and am getting it all configured again.  There were some items pinned to my taskbar from the image and when I unpin them, they come back after a reboot.  I have seen lots of comments about clearing out %AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar and removing HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband.  Also notes about c:\Users\Public\CompanyProfile (which does not exist for me).  None of these tricks have worked.  I even created a new users and am seeing the same problem on that account.  Another symptom I have is that when I default my browser to Firefox, it resets to IE after reboot.  I have checked and I cannot see any group policy that is driving this behavior.  I am out of ideas.   Installed programs to stick and items I place on my desktop do survive a reboot.  In looking around I tried a batch program to help and noticed that if I run these commands in DOS:   taskkill /f /im explorer.exe start explorer.exe   It resets the taskbar and file associations.


How can I force an older version of g++ if I have a newer version?

g++ --version on my home machine reads 7.4.0, but a server I frequently do work on shows 4.8.5. Their servers don't support -std=c++11 compiler flags yet my home machine does. The most recent flag it does support is -std=c++0x.  However, sometimes when I write code on my home machine, compile with -std=c++0x flag without error, I will get errors if I brought it over to the server's local computers. Interestingly, SSHing to their servers does not show issues.  I'm not entirely sure what to make of this, I'm thinking my local machine may be ignoring the -std=c++0x flag because I have a newer version. Is there a way to force a specific version?  If it makes any difference, I am using Windows 10 with LXSS (Ubuntu) and the server I am connecting to is using Redhat.


Query Activity for ORDER BY xxx DESC LIMIT

I'm trying to create a query activity in order to show, from a Data Extension, only the last 5 articles ids. I tried with the formula ORDER BY xxx DESC LIMIT 0,5 as in SQL but it is not working and it is returning this exception:     The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions, unless TOP or FOR XML is also specified   How can I use ORDER BY in a Data Extension?


Rearranging seats randomly, mean number of pairs swapping places?

We have 11 people sitting on 11 chairs. They then get up and rearrange themselves. I need to calculate the expected value/mean of the pairs who swapped places.   I haven't really got a good grasp on how to even approach this problem... counting the possible states seems far too complex.


Printing the character ⱱ (U+2C71 = labiodental flap)

I need to print the IPA symbol for the labiodental flap ⱱ (Unicode U+2C71) and it is not available in the tipa package for phonetic symbols. Is there a way I can use the Unicode hex in the input so I get the symbol as the output?


System of equations: $x^2+y=7, y^2+x=11$

Possible Duplicate:          During the flight from Moscow to Yerevan my neighbor gave me the following problem:  Solve the system:  $$\left\{\begin{array}{c}x^2+y=7 \\ y^2+x=11. \end{array}\right.$$  It is easy to find 1 of the 4 solutions. Is there a beautiful way to find the other three?


i am struggling with an error which i get when trying to compile my C++ Programm which is using templates and typenames. Here is the Code which i have problems with:   template <typename Key, size_t N = 10> class ADS_set { public: class Iterator; using key_type = Key; . . . private: std::pair<Iterator, bool> next_idx(Bucket &bkt, const_reference key, bool split);  }; // End of class template <typename Key, size_t N> std::pair<ADS_set<Key, N>::Iterator, bool> ADS_set<Key, N>::next_idx(Bucket &bkt, const_reference key, bool split) {   No, the problem lies on the definition of my next_idx Method. Somehow i do not define the template parameters of my std::pair correctly as far as I do understand. I would ask you if you could provide me a correct solution and an explanation why this was wrong so that i could possibly understand this better in the future!   The error(s) which i get do say the following:   ADS_set.h:428:42: error: type/value mismatch at argument 1 in template    parameter list for ‘template<class _T1, class _T2> struct std::pair’ std::pair<ADS_set<Key, N>::Iterator, bool> ADS_set<Key, N>::next_idx(Bucket &bkt, const_reference key, bool split) {                                       ^ ADS_set.h:428:42: note:   expected a type, got ‘ADS_set<Key, N>::Iterator’ ADS_set.h:428:44: error: prototype for ‘int ADS_set<Key,  N>::next_idx(ADS_set<Key, N>::Bucket&, ADS_set<Key, N>::const_reference, bool)’   does not match any in class ‘ADS_set<Key, N>’ std::pair<ADS_set<Key, N>::Iterator, bool> ADS_set<Key, N>::next_idx(Bucket &bkt, const_reference key, bool split) {   Thanks a lot for you help!


Show that $f(x) = -\ln(x)$ is convex (WITHOUT using second derivative!)

In the lecture notes for a course I'm taking, the definition of a convex function is given as follows:  "a function $f$ is convex if, for any $x_1$ and $x_2$, and for any $\alpha$ $\in$ [0,1], $\alpha f(x_1) + (1-\alpha)f(x_2) \ge f(\alpha x_1 + (1-\alpha ) x_2)$"   That is, if you draw a line segment between two points on the curve for this function, the function evaluated at any $x$ between $x_1$ and $x_2$ will be lower than the line segment.  Immediately after this definition is given, there is an exercise: "show that $f(x) = -\ln(x)$ is convex." Now, I happen to know that a function is convex if its second derivative is always greater than zero, so we can easily check the second derivative here to show that $-\ln(x)$ is convex (the second derivative is $\frac{1}{x^2}$, which is always greater than zero).  However, because of the way the exercise comes immediately after the "line segment" definition of convexity, without any mention of the second derivative test, I get the impression that it is possible to prove that $-\ln(x)$ is convex without using the second derivative test. I have attacked this problem many different ways, and I haven't been able to show convexity using only the line segment definition. Is this possible?


Let $D = \{(x,y)\in \mathbb{R}^2: x^2 + y^2 ≤ 1 \}$. Let $A \subset \mathrm{int}D$. Let $A$ be connected and compact and let $D \setminus A$ be connected. Let $f:A \longrightarrow A$ be a continuous function and let $g:D \longrightarrow D$ be also continuous function such that $g_{|A} = f$.$\\$ Does it imply that there exists $x \in \mathrm{int}D$ such that $g(x)=x$?


When to use a preceding slash in path names? (e.g. for the 'cd' command)

I am a novice user and I am trying to install Oracle Java. The process calls for me to access /usr/local/java, but here is the problem. I get as far as /usr/local, then this is the message I get:  leonard@leonard-MT6452:/usr/local$ dir bin  etc  games  include  java  lib  man  sbin  share  src  leonard@leonard-MT6452:/usr/local$ cd /java/ bash: cd: /java/: No such file or directory  leonard@leonard-MT6452:/usr/local$ rm -r ~/java rm: cannot remove ‘/home/leonard/java’: No such file or directory   Help?


sort each column(field) in a file separately

I am aware that it is possible to sort primarily by one field and secondarily by another field. For example:   $ echo -e "1 5\n1 4\n8 2\n1 9" | sort -k 1,1n -k 2,2n 1 4 1 5 1 9 8 2 $    However, am I correct that sort always keeps the lines intact, e.g. it is not possible to sort in a way that output would be following:  1 2 1 4 1 5 8 9   If this is not possible with sort, then what would be the correct tool for this?


I have an issue with Dynamic cast  with inheritance.   I have Shape which is a base class and Rectangle which is a deviated class.  In my Rectangle.h file, I have the following  class Rectangle: public Shape   In my main class, I create a vector of Shape class named record  std::vector<Shape> record;   In my Shape.h file, I have the virtual function computeArea().   virtual double computeArea();   My Rectangle.h file contains the function double computeArea()  I am trying to dynamic cast the Shape into Rectangle to compute the area  for(int i=0; i < record.size(); i++)     {         cout << record[i].getName() <<endl;         if(record[i].getName() == "Rectangle")         {             Rectangle& rectest = dynamic_cast<Rectangle&>(record[i]);             cout << rectest.computeArea() << endl;         }     }   However,I got this error "terminate called after throwing an instance of 'std::bad_cast' what():  std::bad_cast Aborted"  Any one know what could be the issue?  Thank you.


How to play sound when the counter is equal to zero?

I am fairly new to programming and really new to programming in Python. And I have made a countdown timer for fun to try to learn programming. It looks like this:  I need help with to play an audio file when the counter is at zero. For example, when the 1 min button has been pressed, it needs to play an audio file when it reaches zero. The same goes for the other buttons. I don't know how to play audio in Python, and how to connect in a way so it plays when the program meets the requirement of the counter = "00:00:00". Here is my entire code: import tkinter as tk def update(seconds):     global after     if seconds >= 0:         countdown.set(seconds_to_time(seconds))         after = root.after(1000, lambda: update(seconds - 1))     else:         root.after_cancel(after)  def seconds_to_time(seconds):     hours = seconds // 3600     seconds -= hours * 3600     minutes = seconds // 60     seconds -= minutes * 60     return f'{hours:02d}:{minutes:02d}:{seconds:02d}'  def stop():     try:         root.after_cancel(after)     except NameError:         pass  #GUI root = tk.Tk() root.title("Tequila timer")  #Load of background with the tequila bottle canvas = tk.Canvas(root, width=423, height=700) canvas.pack() Load = tk.PhotoImage(file="Flaske.png") canvas.create_image(211, 350, image=Load)  countdown = tk.StringVar() countdown.set("00:00:00")  #buttons btn_10sek = tk.Button(root, text="10 sekunder", width=10, height=5, command=lambda:  update(10)) btn_10sek_v = canvas.create_window(140, 300, window=btn_10sek)  btn_1min = tk.Button(root, text="1 min", width=10, height=5, command=lambda:  update(60)) btn_1min_v = canvas.create_window(283, 300, window=btn_1min)  btn_10min = tk.Button(root, text="10 min", width=10, height=5, command=lambda:  update(60 * 10)) bt1_10min_v = canvas.create_window(140, 425, window=btn_10min)  btn_1time = tk.Button(root, text="1 time", width=10, height=5, command=lambda:  update(3600)) bt1_1time_v = canvas.create_window(283, 425, window=btn_1time)  btn_2timer = tk.Button(root, text="2 timer", width=10, height=5, command=lambda:  update(7200)) bt1_2timer_v = canvas.create_window(140, 550, window=btn_2timer)  btn_stop = tk.Button(root, text="Stop tiden", width=10, height=5, command=stop) bt1_stop_v = canvas.create_window(283, 550, window=btn_stop)  btn_luk = tk.Button(root, text="Luk ned", width=12, height=3, command=root.quit) bt1_luk_v = canvas.create_window(211, 635, window=btn_luk)  #Display label = tk.Label(root, textvariable=countdown, width=9, font=("arial black", 40, "bold"), fg="red") label.pack() label_v = canvas.create_window(211, 165, window=label)  #Overskrift over = tk.Label(root, text="Tequila timer", font=("arial black", 40, "bold"), fg="red") over.pack() over_v = canvas.create_window(211, 30, window=over)  root.mainloop()  Update!!! I figured it out. I used the simpleaudio library and made a if statement that said seconds < 0. What this does is that when the counter is done with counting down to zero, it plays the audio file because seconds is now below 0. I added into my time_function which is called "update(seconds", so it looks like this: def update(seconds):     global after     if seconds >= 0:         countdown.set(seconds_to_time(seconds))         after = root.after(1000, lambda: update(seconds - 1))     else:         root.after_cancel(after)      if seconds < 0:         wave_obj = sa.WaveObject.from_wave_file("Te.wav")         play_obj = wave_obj.play()         play_obj.wait_done()


How do I know if my Ordered Logistic Regression is a good model?

I have a few questions about Ordered Logistic Regression Model (OLR). In general, how do I know if this is my model is good, and how do I enhance it?  Using this example from , if these are the outputs I am looking at:  ## R OUTPUTS ## Call: ## polr(formula = apply ~ pared + public + gpa, data = dat, Hess = TRUE)  ## Coefficients: ##          Value Std. Error t value ## pared   1.0477      0.266   3.942 ## public -0.0588      0.298  -0.197 ## gpa     0.6159      0.261   2.363 ##  ## Intercepts: ##                             Value  Std. Error t value ## unlikely|somewhat likely     2.204  0.780      2.827  ## somewhat likely|very likely  4.299  0.804      5.345  ##  ## Residual Deviance: 717.02  ## AIC: 727.02   ## R INPUT exp(cbind(OR = coef(m), ci))  ## R OUTPUT ##            OR  2.5 % 97.5 % ## pared  2.8511 1.6958  4.817 ## public 0.9429 0.5209  1.681 ## gpa    1.8514 1.1136  3.098   What can I do to enhance/improve my OLR model in R?  What output values should I be focusing on?  Does improving my OLR model mean looking at my P values and coefficients and removing the ones that are not statistically significant?   I am stuck as I don't really know what to do after I run the model.  Thank you.


subfigure placement incorrect with 4 figures

I am having an issue with latex placing my figures incorrectly. I have 4 related plots that I want to appear together as a single figure (with a,b,c,d sub-references).   \begin{center} \begin{figure}[h] \subfigure[All instances]{ \includegraphics[width=0.4\textwidth]{timeregression/graphs/bucketing/all_Q_time} \label{fig:q_time_all} } \subfigure[SAT instances]{ \includegraphics[width=0.4\textwidth]{timeregression/graphs/bucketing/all_sat_Q_time} \label{fig:q_time_sat} } \subfigure[UNSAT instances]{ \includegraphics[width=0.4\textwidth]{timeregression/graphs/bucketing/all_unsat_Q_time} \label{fig:q_time_unsat} } \subfigure[Uniform Random Sample]{ \includegraphics[width=0.4\textwidth]{timeregression/graphs/bucketing/sample_Q_time} \label{fig:q_time_sample} } \caption{Q metric plotted against time} \end{figure} \end{center}   This should display an even 4*4 grid of plots, each the same size. However what happens is that the top right plot is offset on the x-axis, such that the left hand side of it is in the middle of the space (i.e. roughly offset by 50% of its width)  Any suggestion of how to fix it?


How many operating systems are allowed to install a single computer?

I have already install windows 7 and ubuntu in my pc, but now I want to install windows server 2012 in same computer. Is it possible?