How to make a thread read the proper size of an array

I'm new to multithreading so I was trying to create a basic program that creates an array of size 1000 of random integers and create two threads, one that sorts the array ascendingly and the other sorts the array descendingly (without any concurrency control). So my problem is that the two threads does not read the proper size of the array and when I print out the array length it gives 2, so if I add another argument to the function indicating the size of the array(which is the regular fix) I won't be able to pass that extra argument to the thread created as it only takes 1 argument for the function . Here is what the code looks like :   #include<stdio.h> #include<pthread.h> #include<time.h>  void *Function1(int *arr[]){      int i,j,k;     int n = ( sizeof(arr) / sizeof(int)); printf("Size of array = %d\n", sizeof(arr)); printf("Size of int = %d\n", sizeof(int)); printf("no. of elements in array = %d\n", n);      for(i=0;i<n;i++){         for(j=0;j<n-i;j++){             if(arr[j]>arr[j+1]){                int tmp=arr[j];                 arr[j]=arr[j+1];                 arr[j+1]=tmp;             }         }      }     for(k=0; k<n; k++){         printf("a[%d] is %d  Thread#1 \n", k, arr[k]);    } }   void *Function2(int *arr[]){      int i,j,k;     int n = ( sizeof(arr) / sizeof(int)); printf("Size of array = %d\n", (int)sizeof(arr)); printf("Size of int = %d\n", sizeof(int)); printf("no. of elements in array = %d\n", n);     for (i = 0; i < n; i++){         for (j = i + 1; j < n; j++){             if (arr[i] < arr[j])             {                 int tmp = arr[i];                 arr[i] = arr[j];                 arr[j] = tmp;             }         }      }     for(k=0; k<n; k++){         printf("a[%d] is %d  Thread#2\n", k, arr[k]);    } }  int main(){  int i,j; int array[1000];     srand(time(NULL));     for(i=0; i<1000;i++){         array[i] = (rand() % 1000) +1;       }  pthread_t t1,t2; pthread_create(&t1, NULL, Function1, array); pthread_create(&t2, NULL, Function2, array); pthread_join(t1, NULL); pthread_join(t2, NULL); return 0; }   Here is what gets printed :  Size of array = 8 Size of array = 8 Size of int = 4 Size of int = 4 no. of elements in array = 2 no. of elements in array = 2 a[0] is 365  Thread#1  a[0] is 365  Thread#2 a[1] is 72  Thread#1  a[1] is 72  Thread#2


How remove the white spaces at start a paragraph

I have this latex and I want to remove the white spaces at start a paragraph (in all (red and blue circles marks) or in the paragraph is not next of chapter (blue circle mark) ). \documentclass{report}  \usepackage[utf8]{inputenc} \usepackage[spanish]{babel} \usepackage{verbatim} \usepackage{minted}  \usepackage{xcolor} \definecolor{lightgray}{rgb}{0.95, 0.95, 0.95}  \usepackage[xindy]{imakeidx} \makeindex[intoc]  \usepackage{caption} \captionsetup[figure]{labelformat=empty}  \title{A test \\ \large with tomatoes and potatoes.} \author{Miguel} \date{}  \begin{document} \pagenumbering{gobble} \maketitle  \shipout\null  \tableofcontents  \pagenumbering{arabic}  \chapter{potatos} Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.  \vspace{2em}  \section{tomatoes} Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.  \vspace{2em}  Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.  \vspace{2em}  \printindex  \end{document}


Do Trigger DMLs count on Batch Callouts?

Our instance has some triggers that fire before insert and before update on accounts, contacts, and leads.   In a test class, if I am creating test records will the insertion of new account records cause a DML to run and therefore error when trying to make a subsequent callout (You have uncommitted work pending) even if I am using @TestSetup to create those records?   The batch class calls another class which actually performs the callout (just an http request that returns a string)     Global Class FocusDomainBatch implements Database.Batchable<sObject>, Database.allowsCallouts {     global Database.querylocator start(Database.BatchableContext BC)     {         String query = 'Select id,name, First_user_sign_up_date__c, Total_Users__c, New_Users_In_Last_Month__c, Avg_Fvrt_Pro_Per_User__c, Users_with_zero_fvrts__c, Users_with_2_or_less_fvrts__c, Average_daily_queries__c, Average_monthly_queries__c, Total_current_month_queries__c, Total_Queries__c from Focus_Domain_Stats__c';         return Database.getQueryLocator(query);         }      global void execute(Database.BatchableContext BC, List<sObject> scope)     {         try         {            List <Focus_Domain_Stats__c> allDomains = scope;                      List <string> web = new List <string>();             for(Focus_Domain_Stats__c c : allDomains)            {                system.debug('FocusDomainBatch:execute for ' + c.Name);                web.add(c.name);            }              FocusAPI fi = new FocusAPI();//actually performs the callout            String Token = fi.getToken();//failing here            String stm = String.valueof(Date.today().toStartOfMonth())+' 00:00:00.000Z';            stm = stm.replace(' ', 'T');            List <String> dm = new List<String>();   Test Class:   @IsTest  Public Class TestFocusDomainBatch2 {     @testSetup static void setupTestData(){          //Setup Data          Lead ld = new Lead();         ld.lastName = 'kitagawa';         ld.email = 'justin.kitagawa@test.com';         ld.company = 'test';         ld.website = 'test.com';         ld.focus_user__c = TRUE;         ld.Focus_Sign_Up_Date__c = date.today();         insert ld;           Focus_Domain_Stats__c ds = new Focus_Domain_Stats__c();          ds.name = 'test.com';         insert ds;           Lead ld2 = new Lead();         ld2.lastName = 'kitagawa';         ld2.email = 'justin.kitagawa@test.com';         ld2.company = 'test';         ld2.website = 'test.com';         ld2.focus_user__c = TRUE;         ld2.Focus_Sign_Up_Date__c = date.today();         insert ld2;           Account acc = new Account();          acc.name = 'test';          acc.website = 'test.com';         acc.Focus_Domain_Stats__c = ds.id;         insert acc;          Contact ctc = new Contact();         ctc.lastName = 'kitagawa';         ctc.email = 'justin.kitagawa@test.com';         ctc.account = acc;         ctc.accountid = acc.id;         ctc.Focus_Sign_Up_Date__c = date.today();         insert ctc;           Contact ctc2 = new Contact();         ctc2.lastName = 'kitagawa2';         ctc2.email = 'justin.kitagawa2@test.com';         ctc2.account = acc;         ctc2.accountid = acc.id;         ctc2.Focus_Sign_Up_Date__c = date.today();         insert ctc2;          Focus_Product__c fp = new Focus_Product__c();          fp.Contact__c = ctc.id;          fp.Lead__c = ld.id;          fp.name = 'test product';         insert fp;     }      Static testMethod void TestFocusDomainBatch ()     {                     Test.StartTest();             //set mock                   Test.setMock(HttpCalloutMock.class, new MockHttpResponseGenerator1());              Database.executeBatch(new FocusDomainBatch());             Test.StopTest();            } }


Is it possible to connect a USB microphone to an Android phone or tablet?

Blue makes  that you can connect directly to an iPod or iPhone via the dock port. I would love to have the same capability to do something similar for an Android phone or tablet. This would be really useful for field recording. I know that some tablets have support for various USB accessories to be plugged in, but I don't know if the OS can handle a microphone. Is this possible using existing or near future (Ice Cream Sandwich) hardware/OS combinations?


Prove that $f$ defined by $f(x)=1$ if $x \in \mathbb{Q}$, $f(x)=0$ if $x \in \mathbb{R}\setminus \mathbb{Q}$, is not integrable

Prove that   $$f\left ( x \right )= \begin{cases} 1 & x \in \mathbb{Q}, \\  0 & x\in \mathbb{R}\setminus \mathbb{Q}. \end{cases}$$  is not integrable.  I came across this. I think that the function itself is not continuous? But I do not think that is a legitimate answer to this question.


Windows 8.1 Keeps Turning Off Automatic Updates

My OS keeps turning off automatic Windows updates without even logging off or restarting the computer.  Action center icon in the task bar warns me about choosing an option for Windows update as if I haven't chosen countless times already.  It started to get really annoying to keep choosing a Windows update option 5 - 10 times a day.   I really appreciate any help you can provide on this matter.  Things I have tried so far;   I have tried  suggested by . Unfortunately didn't help my case Tried following commands; reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 0 /f  and then sc config wuauserv start= auto as suggested . Googling. Tried few suggestions which didn't help my case.


Make simple icons larger without losing quality in Photoshop?

I couldn't find an answer to my question, probably because this is so basic.  How could I make a simple 2 colored flat icon 2 times larger in Photoshop (CC) without making it blurry?


Bolding Text String Not Working in ArcMap

I am using ArcMap 10.5 with an Advanced level license. I am wanting a portion of my text box to be bold. I clicked Insert --> Text. When I type <bol> it literally shows up on my text box as <bol>. I have searched everywhere for recommendations, tried adding quotation marks and nothing works.


Wanted: photoshop filter for free-hand glyph to simulate anti-aliasing

I want to draw a letterform free-hand, simulating an aliased character and I would like to then apply a filter so it looks like an anti-aliased character [ed. note: simulate sub-pixel rendering?].  I tried the various blur filters but the blur is too regular. Is there a filter that would make it look more like a real anti-aliased letterform?  edit : since you need it it here is an exemple of a letter I would like to make look like a rasterized anti-aliased letter :   link :


type of numbers that are not stored in a variable

I'm a Little confused about some numbers in C-Code. I have the following piece of Code  int k; float a = 0.04f;  for (k=0; k*a < 0.12; k++) {   * do something * }   in this case, what is the type of "0.12" ? double ? float ? it has never been declared anywhere. Anyways, in my program the Loop above is excuted 4 times, even though 3*0.04=0.12 < 0.12 is not true. Once I Exchange 0.12 with 0.12F (because I am globally restricted to float precision in all of the program), the Loop is now executed 3 times. I do not understand why, and what is happening here. Are there any proper Guidelines on how to write such statements to not get unexpected issues?  Another related issue is the following: in the Definition of variables, say  float b = 1/180 * 3.14159265359;   what exactly "is" "1" in this case ? and "180" ? Integers ? Are they converted to float numbers ? Is it okay to write it like that ? Or should it be "1.0f/180.0f*3.14159265359f;"   Last part of the question,  if i have a fuction   void testfunction(float a)   which does some things.  if I call the fuction with testfunction(40.0/6.0), how is that Division handled ? It seems that its calculated with double precision and then converted to a float. Why ?   That was a Long question, I hope someone can help me understand it.


tmux and control sequence character issue

I try to resize terminal window from command line on my MacOSX  I can resize the width and heigh of the terminal with following command(Control Sequence Introducer CSI)  printf '\e[8;100;200t' "resize to 200x100   but when I use tmux in my terminal, then the command(printf '\e[8;100;200t' ) is not longer working  Any suggestion would be apprecaited.  Here is my tmux config file:  bind r source-file ~/.tmux.conf \; display "Reloaded!"  #Reload with ctrl-r set-window-option -g mode-keys vi                       #copy-mode vim-like  set -g prefix `                                         #prefix from ctrl-b to ctrl-a unbind C-b                                              #allow ctrl-b for other things set -sg escape-time 1                                   #quicker responses bind ` send-prefix                                      #Pass on ctrl-a for other apps set -g base-index 1                                     #Numbering of windows setw -g pane-base-index 1                               #Numbering of Panes bind \ split-window -v                                  #Split panes horizontal bind v split-window -h                                  #Split panes vertically  unbind-key j bind-key j select-pane -D # Similar to 'C-w j' to navigate windows in Vim unbind-key k bind-key k select-pane -U unbind-key h bind-key h select-pane -L unbind-key l bind-key l select-pane -R  unbind-key Left  bind-key  Left resize-pane -L 10  unbind-key Right  bind-key  Right resize-pane -R 10  unbind-key Up  bind-key  Up resize-pane -U 10   unbind-key Down  bind-key  Down resize-pane -D 10   set -g window-status-current-style fg=red set -g default-command "reattach-to-user-namespace -l /bin/bash"


I have already weight painted and assigned geometry to the left half of my model. I would like to copy thee contents to the right half of the model. How do I this?


I studied the concepts of decidability, semi-decidability and undecidability. I know the practical consequences of semi-decidability of first order logic. What i dont understand are the profound reasons for which the First Order Logic is semi-decidable. That is , why can i verify the validity of a theorem in a finite number of steps, but if the formula is not a theorem the procedure proceed to infinity ? I searched a lot in this website and i found great answers to my question ( like ), but they seem too superficial to me...


How to split items in a list to create a string with characters in between?

i wrote a code to print a list of a number's prime factorization, and for example, if the user input was "18", it would output "[2, 3, 3]". how do i make it print in such a way that it follows this format: "18 = 2x3x3"?


Why are dividends seen as a good thing for investors?

Why are dividends generally seen as a good thing for investors?  For example, you can look at  where it states Broadcom (ticker: AVGO) plans to boost its quarterly dividend by 51%, a piece of good news for investors in a company whose shares have lagged behind the market this year.  How exactly is this good news for investors? When the company issues the dividend, won't the stock price drop by the proportional amount since the company is losing that much cash (the cash that they're giving out as dividends)? This should be neutral news as Investors aren't really making/losing any money from this?  If anything, this might be bad news, since it shows the company Broadcom has nothing they deem worth investing in.  Thanks.


Review Audit with no option to flag, downvote or comment

I came across a  for a Community Wiki post. It was (to me) obvious it was an audit. However, I did not have any options to do anything about the post. My options were to Skip, or to select No Action Needed. The former does nothing to prove I knew how to handle the post, the latter leads to a "You were naughty" message (I tried both). What I wanted to do but was not given the options for, was to flag, comment, or vote down. None of these options were available. This is most likely a bug due to this being a deleted CW post.   ran into this problem as well and managed to create a screenshot:    Added by DragonLord to avoid posting a non-answer to the question  I can reproduce this bug with a review audit item that was a spam post I had already flagged. While this isn't exactly the same as the issue originally described by the OP, I suspect this problem has the same root cause. Click image to view full size  I was able to downvote it, but , so this is a crude workaround at best. Can someone address this?


How to align a volumetric texture along curve?

I need a Cycles volumetric material that appears to flow along a curved path. Specifically, I would like to stretch a texture along the direction of motion to mimic streamlines in fluid flow. I seem to keep running into the same problem: texture coordinates don't bend.  I originally wanted to model the flow with a particle system affected by a Force Field. While the particles (and their Object Instances) can be made to rotate to point in the direction of motion, the Object Texture coordinates remain constant for the lifetime of the particles.  I also tried mimicking the appearance with a beveled Curve and ticking the "Use UV for mapping" option, but UV coordinates do not support volumetric textures. That is, all coordinates are zero for all locations along and within the Curve shape.  I'm willing to try any method at this point, but utilizing the Compositor could be a problem given the complexity of the scene.  Two potential solutions come to mind but I don't know how to implement them:   Perhaps I'm missing a setting that allows Instances to retain their rotated coordinates? Generating the UV coordinates of a Curve and using Drivers or some other method (Python? OSL?) to apply them to the volumetric texture to stretch it along the tangent of the Curve.   Any other methods that could work? Even methods restricted to 2 dimensions are welcome.  A couple of reference images:    The plume is made of multiple curves, each erupted from the volcano in a different direction.  This effect is likely created with Photoshop or GIMP. Focus your attention on the way the texture bends along each "streamer".   Here is an OpenGL render I did with a stretched cube using a Particle Instance modifier. The particles bend along a path controlled by a Force Field. The effect I'm hoping to achieve would have the texture stretched along the long axes of these thin objects.


Exact sequence of sheaves with non exact sequence of global sections

Let $X$ be some topological space. By $\mathcal{F}_i$ we denote some sheaves of abelian groups on $X$. The sequence of sheaves and morphisms  $$\mathcal{F}_1\longrightarrow \mathcal{F}_2\longrightarrow \mathcal{F}_3\longrightarrow... $$ is said to be exact if for each $x\in X$ the corresponding sequence of stalks $$(\mathcal{F}_1)_x\longrightarrow (\mathcal{F}_2)_x\longrightarrow (\mathcal{F}_3)_x\longrightarrow... $$ is exact. However if the sequence of sheaves is exact than the sequence of global sections is not necessarily exact! (The most famous example is the sequence of sheaves $$0\longrightarrow\mathbb{Z}\hookrightarrow \mathcal{O}\stackrel{\exp}{\longrightarrow} \mathcal{O}^*\longrightarrow0$$ considered as sheaves on $\mathbb{C}-\{0\}$, where $\mathcal{O}$ is a sheaf of holomorphic functions, $\mathcal{O}^*$ is a sheaf of holomorphic functions with no zeros).  So, could you give me some easy examples of such phenomenon ?


Windows 8 Asus laptop: Screen Brightness is auto-adjusting despite being disabled

I'm not sure if this is a problem being caused by Windows 8, the asus power-management programs, or what. Whenever my screen is displaying something darker, specifically the Steam client or in games/movies/other media, the screen dims, and when i go back to a brighter program like skype or firefox, it brightens.   I have disabled adaptive brightness multiple times, and it claims to be off. My power plan should have the screen remaining at 100% brightness all the time, and it doesn't put itself to sleep or anything. It's only when my screen attempts to display darker colors, it also dims.   It's becoming a problem in games with bright flashes because the entire screen will brighten and dim back and forth repeatedly.   Is there a setting I have missed?


How can I prove the formula for calculating successive entries in a given row of Pascal's triangle?

I've found in Wikipedia the formula for calculating an individual row in Pascal's Triangle: $$v_c = v_{c-1}\left(\frac{r-c}{c}\right).$$ where $r = \mathrm{row}+1$, $c$ is the column starting from $0$ on left and $v_0 = 1$.  Now, I've tried to do by hand and it works,  but I don't understand how to find this magic formula when I don't have access to Wikipedia...:)


What happened to the Death Eaters after the Battle of Hogwarts?  Were they pardoned?  Imprisoned?  Stripped of their positions at the Ministry?  Have they fled from Great Britain?


What is the relationship between $p$ values and Type I errors

In hypothesis testing we set an accepted level of Type I error probability $\alpha$ and observe whether a sample statistic is equally likely or less likely to be observed if the null hypothesis was true. The exact probability of observing a sample score or more extreme under the null is the $p$ value. More generally we reject if $\alpha>p$.   I am now wondering about the following. The $p$ value seems to give an exact estimate of the probability of falsely rejecting a true null hypothesis (if we decide to do so), which is akin to the Type I error definition. Since we know (estimate) the probability of observing the sample score (or more extreme values), $\alpha$ seems to be a maximum acceptable Type I error, whereas $p$ is exact. Put differently it appears to give the minimum $\alpha$ level under which we could still reject the null.   Is this correct?


Can anyone provide me with (or point me to) real life gravitational lensing data that I can plug in to the first equation on this page (the standard lensing equation):   together with the luminous mass and distance to the galaxy(s).  I've looked for papers online and have not found any simple data that can be readily plugged in to the equation (I am not familiar with the details of how exactly the lensing is measured and have gotten lost in the mountains of data in the papers).  Thanks


OpenOffice files open with Archive Manager by default

If I double click a .odt (OpenOffice Document) file that's on a 4TB MyBook USB drive plugged into my router it tries to open it in Archive Manager. I have to right click it, go to "open with..." and click OpenOffice.org Calc.  Can I change the default "Open with..." to OpenOffice Calc like in Windows, or is there something else I have to do to get it to open correctly?


I recently purchased a MacBook Pro 2020 13" (1.4 GHz, 8GB Ram, i5). For some reason, when I open Chrome and watch Twitch my computers fans turn on and go crazy. After opening Activity Monitor, I noticed that Google Chrome Helper (Renderer) uses around 50-80% of my CPU. Also, sometimes when I run code on my MacBook Pro, the fans turn on when the program is compiling/running but slow down a few minutes after terminating the program. Also, when watching Twice on Safari, the fans don't come on. However, around 50-60% of the CPU is still being used. Should I be concerned about the CPU usage (I am nervous because I only recently purchased the laptop)?


What happened to Cornelius Fudge after he resigned from his post of Minister for Magic?

Is there any reference to say where he went or what he did after leaving his post? What actually happened during his life from that point?


Install Fingerprint Driver 138a:0090 on Ubuntu 16.04 (ThinkPad T460s)

I'm about to config my new fantastic T460s with Ubuntu 16.04 (because of Skylake Kernel issue I've to chose such new version) I tried to use my fingerprint sensor which is 138a:0090 (lusb) Fingerprint Gui doesn't recognize the device which is no wonder, because it is not on the compatibility list of it. Do I've to wait for a driver or is there something I can do about this?  Thanks a lot :)


I downloaded a file called SOURCE_SVR_Linux_38037.tar.gz, how do I install it?  It's the package for splashtop.   I'm pretty new to Linux, so please explain with detail.


How can I get my Linux distribution name and version using the command line ?

I have Linux Mint Version 7.1 Rebecca. What do I need to write in the command line in order to find this information. I tried uname -a , but I got informations about my computer name, Kernel Version etc. but not the name itself.


Flight Cancellation information for an Avianca flight

I need to find information regarding an Avianca Flight from Baltra Island (Galapagos Islands) to Quito.  We had a stop in the Guayaquil Airport.  We were not to depart the plane but then they cancelled our flight to Quito with no help to change our flights as the Quito Airport was not accepting flights due to the unrest in the country.


I found out about this site on Facebook... or "at Facebook"?

Would this look natural:     StackExchange is a helluva site! I found out about this site at Facebook.    Or should we use the preposition on:     StackExchange is a helluva site! I found out about this site on Facebook.    Or are both okay?   (Inspired by a )


Relevance of Research Papers from another field for Grad Admission

I am a student of Indian nationality, currently pursuing my bachelor's in Electronics and Communication Engineering. I wish to pursue a Ph.D. and later a career in astronomy (with an inclination to Radio Astronomy) and have done relevant research internships and projects in the same. However, I have no publications in this area. Alongside this, I have worked on research in antenna engineering with a professor in my institute and we have published 2 papers in international conferences. My query is: for graduate admissions, will my research papers in antenna engineering have any value and consideration or are only research papers in Astronomy looked out for?


Question regarding copying and pasting on exams

On Wiley Plus, will students be able to copy and paste homework questions if not on a lock down browser? If so, can I detect that through any many means? I have been reprimanded before for not being critical on cheating, so I want to figure out any means I can use to minimize cheating among students. As a physics professor, I find it difficult for students to not look up their answers or have them not use a source like Chegg.


How do I lock a window to a specific workspace?  2 scenarios:   Launch application for first time, need it to be on specific workspace Everytime I undock and dock my windows they lose their workspace and all go to the main work space   Would like to be able to say "evolution" goes to #5 always.


How do you center a division with a form inside?

I'm learning HTML/CSS and trying to recreate google homepage. I'm having difficulties with centering my input searchbar. In my html I have:

     <form action="https://google.com/search">         <input class="searchbar" type="text" name="q">                       <input type="submit" value="Google Search">              <input type="submit" value="I'm Feeling Lucky">              </form>
  This is my css: .image {     text-align: center; }  form {     text-align: center;     width: 50%; }  .searchbar{     width: 400px;     height: 20px;     margin: 10px;     border-radius: 25px;     outline: none; }  div.c {     text-align: center; }  As you can see my image is centered. And I would like my div class="c" to be centered below the image but text-align:center; for div.c does not work. Another thing I noted is when I tried to round my corners using border-radius:25px; there is some bold black line that partially shows up around my searchbar. Anyone experienced this?


How can I find all rows that have at least one element in an array matching a pattern?

Consider the following example:  CREATE TEMPORARY TABLE testing (     names TEXT[] );  INSERT INTO testing VALUES     ('{toplevel1}'),     ('{toplevel1.sub1, toplevel2.sub2}'),     ('{toplevel1.sub1.sub2, toplevel2.sub2}'),     ('{toplevel1.sub1.sub3, toplevel2.sub2}'),     ('{toplevel1.sub1.sub3.sub3, toplevel2.sub2}'),     ('{toplevel2.sub1}') ;  SELECT * FROM testing WHERE 'toplevel1.%' ILIKE ANY(names);   I want to write a select where "any" element of an array matches a pattern. But I can't figure out a way to do it. In the example I've given, using the ILIKE operator can't work because it checks if the RHS matches the LHS. For this case I would need a similar operator but which checks if the LHS matches the RHS.  update: I'm currently fiddling around with something like this without much success:  SELECT * FROM testing WHERE names ILIKE ANY (ARRAY(SELECT unnest(names) || '%'));


How to draw a half circle for connections in `Tikz`

This is the block diagram I want to draw:  This is the block diagram I was able to produce:  Here is my MWE:  \documentclass[tikz,14pt,border=10pt]{standalone} %%%< \usepackage{verbatim} %%%> \usepackage{textcomp} \usetikzlibrary{shapes,arrows} \begin{document} % Definition of blocks: % Defining string as labels of certain blocks.     \tikzset{%         block/.style    = {draw, thick, rectangle, minimum height = 3em,             minimum width = 3em},         cross/.style={path picture={                  \draw[black]                 (path picture bounding box.south east) -- (path picture bounding box.north west) (path picture bounding box.south west) -- (path picture bounding box.north east);         }},         sum/.style      = {draw, circle, cross, node distance = 2cm, minimum size = 1.5em}, % Adder         input/.style    = {coordinate}, % Input         output/.style   = {coordinate}, % Output         dconnection/.style = {coordinate}     }     % Defining string as labels of certain blocks.      \begin{tikzpicture}[auto, thick, node distance=2cm, >=triangle 45]     \draw     node at (0,4) [input, name=input1] {}      node [sum, right of=input1] (suma1) {}     node at (4,4) [block] (k1) {$k_1$}     node at (5,4) [dconnection, name = d11]{}     node at (7,4) [block](G1) {$\frac{1}{s}$}     node at (9,4) [sum] (suma2) {}     node at (10,4) [dconnection, name = d12] {}     node at (11,4) [output](output1){}     node at (10,5) [dconnection, name = d13] {}     ;     % Joining blocks.      % Commands \draw with options like [->] must be written individually     \draw[->](input1) -- node[near start] {$r_1$}(suma1)     node[near end,above]{$+$}(suma1);     \draw[->](suma1) -- node {} (k1);     \draw[->](k1) -- node{}(d11) -- node{}(G1);     \draw[->](G1) -- node[near end, below]{$+$}(suma2);     \draw[->](suma2)--node[near end, above]{$y_1$}(output1);     \draw[->](d12) -- node[]{}(d13) -| node[near end, left]{$-$}(suma1);     % Second System     \draw     node at (0,1) [input, name=input2] {}      node [sum, right of=input2] (suma3) {}     node at (4,1) [block] (k2) {$k_2$}     node at (5.5,1) [dconnection, name = d21]{}     node at (7,1) [block](G2) {$\frac{1}{s+2}$}     node at (9,1) [sum] (suma4) {}     node at (10,1) [dconnection, name = d22] {}     node at (11,1) [output](output2){}     node at (10,0) [dconnection, name = d23] {}      ;        % Joining blocks.      % Commands \draw with options like [->] must be written individually     \draw[->](input2) -- node[near start] {$r_2$}(suma3)     node[near end,below]{$+$}(suma3);     \draw[->](suma3) -- node {} (k2);     \draw[->](k2) -- node{}(d21) -- node{}(G2);     \draw[->](G2) -- node[near end, above]{$+$}(suma4);     \draw[->](suma4)--node[near end, above]{$y_2$}(output2);     \draw[->](d22) -- node[]{}(d23) -| node[near end, left]{$-$}(suma3);     % connecting the two systems     \draw   node at (5.5,3) [dconnection, name =d31]{};     \draw[->](d21) -- node[]{}(d31) -| node[near end, above=2mm, left]{$+$}(suma2);     \draw   node at (5,2) [dconnection, name =d32]{};     \draw[->](d11) -- node[]{}(d32) -| node[near end, below=2mm, left]{$+$}(suma4);     \end{tikzpicture} \end{document}


Is there a penalty to interrupting training?

I have several dwellers who train high SPECIAL attributes, but are needed elsewhere at times (someone has to keep the lights on).  I have noticed that, most of the time (I haven't checked for all scenarios), training times resume back where I left them if the dweller was interrupted or made to work elsewhere; it is as if the system is tracking how much training has been done and getting the dweller back on track.  Is training investment wasted on a dweller if it is interrupted for significant amounts of time for other tasks (including death and exploration)?


I am writing a program to implement "quiz" in Java 8  import java.util.Scanner; import java.util.*;  class Question {     String question;     int no;     HashMap<Integer, String> options;     String correctanswer;      public static void q_no() {         System.out.println("enter a question no");         int num;         Scanner no = new Scanner(System.in);         num = no.nextInt();     }      public static void set_question(){         System.out.println("enter aquestion");         Scanner f = new Scanner(System.in);         String question = f.nextLine();      }   Here in setting options, I am getting errors in the while loop while implementing the program.      public void set_options() {         System.out.println("enter options");         int count = 1;         String q;         Scanner str = new Scanner(System.in);         while (count < 5) {             System.out.print("set option" + count);             q = str.nextLine();             options.put(count, q);             count++;         }     }      public void set_correctanswer() {         System.out.println("enter correct answer");         Scanner d = new Scanner(System.in);         String ans = d.nextLine();     }      public static void marks() {      }            }   Here you would write your questions to an ArrayList and display them in a second question.  class Quiz {     ArrayList<Question> list = new ArrayList<>();     public ArrayList<Question> adding(Question q){         list.add(q);         return list;     }     public void show() {         int g = list.size();         int count = 0;         while (count < g) {             list.get(count);         }     } }   In menu, if you choose 1 you get add questions or type 2 you could get a list of questions. I am still working on printing questions.  class Menu {     public static void main(String[] args) {         System.out.println("enter 1 for adding questions");         Scanner input = new Scanner(System.in);         int g;         g = input.nextInt();         if (g == 1) {             System.out.println("how many questions do you add");             int number;             Scanner b = new Scanner(System.in);             Quiz programming = new Quiz();             number = b.nextInt();             int count = 0;             while (count < number) {                 Question q1 = new Question();                 q1.q_no();                 q1.set_question();                 q1.set_options();                 q1.set_correctanswer();                 programming.adding(q1);             }          } else if(g == 2){             Quiz programming = new Quiz();             programming.show();         }      } }


I've seen people change the X, Y ans Z inputs in the mapping node all at once. How is that done? In  tutorial, Andrew Price does it at 7:44


How to calculate expected value in the following scenario

Here is the problem I'm working on: Your bank makes 1,000 loans for 180,000 for each loan.  The probability of default is 2%.  The loss per loan that defaults is 120,000.  The way your bank can give out loans and not lose money is by charging an interest rate. If you charge an interest rate of, say, 2% you would earn 3,600 for each loan that doesn't foreclose. At what percentage should you set the interest rate so that your expected profit totals 100,000. Hint: Create a sampling model with expected value 100 so that when multiplied by the 1,000 loans you get an expectation of 100,000. Corroborate your answer with a Monte Carlo simulation.  The first part of the question asks me to calculate the percentage to set the interest rate so that the bank's expected profit totals 100,000.  I'm really struggling with how to do this and was hoping someone in the community could get me going in the right direction.  For the Monte Carlo simulation, I am using RStudio and I created a model as follows:  library(dplyr) pool <- rep(c(0, 1), 1000 * c(1 - 0.02, 0.02)) loans <- data.frame(i = numeric(1000),                     p = numeric(1000),                     int = numeric(1000),                     def = numeric(1000),                     earn = numeric(1000)) for (i in 1:1000){   loans$i[i] <- i       loans$p[i] <- 180000   loans$def[i] <- sample(pool, 1, replace = TRUE)       loans$int <- 0.02   loans$earn[i] <- ifelse(loans$default[i] == 1, -120000, 3600) }   Can someone point me in the right direction on how to do the simulation.  I'm very good with R and just need some direction.


Any two sets $Y$, $Z$ have the same cardinality $\iff$ there are injective functions $f: Y \rightarrow Z$ and $g: Z \rightarrow Y$.

Let $X$ be a set and let $A \subseteq X$ be a subset of $X$. Asume that there is an injective function $f: X \rightarrow A$. Show that $A$ and $X$ have the same cardinality. Show that any two sets have the same cardinality $\iff$ there are injective functions $f: Y \rightarrow Z$ and $g: Z \rightarrow Y$.    Since $f: X \rightarrow A$ is injective, $\operatorname{card} X \leq \operatorname{card} A$. But since $A$ is a subset of $X$, we have the inclusion map $g: A \rightarrow X$, which is also injective. So $\operatorname{card} A \leq \operatorname{card} X \implies \operatorname{card} A= \operatorname{card} X$.   Similarly, we have $\operatorname{card} Y \leq \operatorname{card} Z$ and $\operatorname{card} Z \leq \operatorname{card} Y \implies \operatorname{card} Y = \operatorname{card} Z$.   I was just wondering if my answer was correct, because it is really short so I thought that I might be missing something...is it ok for me to assume that if we have an injective function $f: X \rightarrow Y$, then $\operatorname{card} X \leq \operatorname{card}$? Or is that what the question wants me to prove?   Thanks in advance


I installed Ubuntu 14.04 recently. During the installation I did not create a separate partition for my home folder. I also accidentally encrypted my home folder. When i did    sudo df   I got the result as  Filesystem                   Size  Used Avail Use% Mounted on /dev/mapper/ubuntu--vg-root  455G  181G  251G  42% / ....   Why does this have a funny name instead of a normal '/dev/sdx'?  Please explain to me what this is?


Is it safe to assume that $x=y$ for the equation $x^y=y^x$?

This thought came to me when I was thinking about exponents. Is the only solution for $x^y=y^z$ be $x=y$? How exactly would we prove there are no other numbers or how would we exactly solve this?


$VAR vs ${VAR} and to quote or not to quote

I can write  VAR=$VAR1 VAR=${VAR1} VAR="$VAR1" VAR="${VAR1}"   the end result to me all seems about the same. Why should I write one or the other? are any of these not portable/POSIX?


Why did Arya shortened her kill list so much in season 6? Or did she lie?

As per this  , Arya tells the Hound her kill list:  - Walder Frey  - Meryn Trant  - Tywin Lannister  - Melisandre  - Beric Dondarrion  - Thoros of Myr  - Ilyn Payne  - Gregor Clegane  - The Hound  - Cersei Lannister  - Joffrey Baratheon    As per this  at 2:10 Arya only says:  - Cersei Lannister  - Gregor Clegane  - Walder Frey    waif: "That is a short list. That can't be everyone you want to kill. Are you sure you are not forgetting someone?" Arya: "Which name would you like a girl to speak?"  Did Arya actually fail this test? Did the waif know Arya was lying about the length of her list and then started testing her by using the second person pronoun, you. And Arya did respond to you. Previously, Arya only talked about herself in the third person.  Or, had Arya's feelings actually changed? Realizing she was too blood thirsty, she had shortened her kill list even before going to Braavos?    And, what did Gregor Clegane ever do to House Stark? Why is he on the shortened kill list? Tywin did order him to raid the Riverlands in season 1, and House Tully is from the Riverlands, and Arya's mother is from House Tully... so is that why Arya hates the Mountain more than even Joffrey? Tywin? (Arya could not know that they are both dead)  Addendum Unlike her killing of Meryn Trant, I bet Arya now has "permission" to assassinate Cersei, the Mountain, and Walter Frey. After all, she was not whacked for saying those 3 are on the kill list.


Prove that if $a^2 + b^2 = c^2$, then 5 divides abc. a,b,c are positive integers.

My question is about proving that if $$a^2 + b^2 = c^2,$$ then 5 divides abc. a,b,c are positive integers.


Is there a notion of transpose for multidimensional arrays?

The definition of symmetric second order tensors (e.g. linear operators, bilinear forms) corresponds essentially to their matrix representations being symmetric matrices.  Question: Is there a notion of transpose for higher order multidimensional arrays (e.g. three- or four-dimensional arrays)?  A natural generalization of symmetric tensor for orders $>2$ would be to define a symmetric higher order tensor to be one whose multidimensional array representation is "symmetric".   However, such a definition would require there to exist some notion of transpose/adjoint for higher-dimensional multidimensional arrays (i.e. $>2$).  For example, can we make a correspondence between "symmetric" three-dimensional arrays and , the same way we have a correspondence between symmetric matrices and quadratic forms? Or between "symmetric" four-dimensional arrays and homogeneous quartic polynomials?  Wikipedia says that there is such a thing as the  over a vector space, which is a sub-algebra of the tensor algebra, and that the elements of this subalgebra (when the characteristic of the underlying field is zero, which is the only case that interests me) are called , which do in fact correspond naturally to homogeneous polynomials, e.g. symmetric third order tensors and cubic forms, symmetric fourth order tensors and quartic forms:      The space of symmetric tensors of order r on a finite-dimensional vector space is naturally isomorphic to the dual of the space of homogeneous polynomials of degree r on V.   However, in the same way that symmetric second order tensors naturally have symmetric matrix representations, do higher order symmetric tensors also naturally map to some type of multi-dimensional array which is invariant under some type of generalized transpose operation?


What is the effect of a path separator at the beginning of an environment variable?

I was reading  recommending setting the TZ variable in order to avoid unnecessary stat system calls in programs using localtime, and it uses the following syntax:  TZ=:/etc/localtime   The trick described in the document works, but it also works without the colon: TZ=/etc/localtime.  What might be the purpose of the : here?


"I chose the USA because I love speaking English and am good at it"is this correct?

"I chose the USA because I love speaking English and am good at it"  It's for a past event, should it be "I loved....and was good..." instead (even though it's still true today)?


What is the best practice for multiple button placement and emphasis?

Usually, we only have 2 buttons at the bottom of a form or a page that requires an action: Submit & Cancel.  This one is quite easy to style. However, what if we are dealing with multiple buttons at the bottom of a page? For example:   ← Back | Send Email | Booking Paid | Check-in Guest   I'm thinking of making "Back" just a link (not a button) and making "Send Email" / "Booking Paid" secondary buttons (light gray). Then I'd make "Check-in Guest" as the primary button (green).  I still feel that there's a better way of doing it or dealing with multiple buttons / actions. What do you think?


I'm looking for a javascript that can limit the number of lines (by line I mean some text ended by user pressing enter on the keyboard) the user is able to enter in textarea. I've found some solutions but they simply don't work or behave really weird. The best solution would be a jquery plugin that can do the work - something like , but it should be able to limit text line count not character count.


Now i got a register form that uploads a piece of info to my database table, but when i check for Æ Ø Å its messed up! this is my upload script:  <?php mysql_query("SET NAMES 'utf8'"); $con = mysqli_connect('localhost', 'root', '', 'errors'); if(isset($_POST['submit'])) {     session_start();     $fname = $_POST['fname'];     $username = $_POST['username'];     $password = $_POST['password'];     $email = $_POST['email'];     $about = $_POST['about'];     $date = $_POST['date'];     mysql_query("SET NAMES 'utf8'");     $sql = $con->query("INSERT INTO `usersystems` (`userid`, `fname`, `username`, `password`, `email`, `about`, `birth`) VALUES (NULL, '{$fname}', '{$username}', '{$password}', '{$email}', '{$about}', '{$date}');");     header('Location: login.php'); ?>   So now, how do i make it so the table actually allow those letters?


Let \begin{equation} A =  \begin{pmatrix} \lambda & 0\\ 0 & \frac{1}{\lambda}\\ \end{pmatrix} \end{equation} be a matrix in $SL_2(\mathbb{C}$). I am trying to prove that $SL_2(\mathbb{C})$ is generated by the matrices \begin{equation} \begin{pmatrix} 1 & z\\ 0 & 1\\ \end{pmatrix}, \begin{pmatrix} 1 & 0\\ z & 1\\ \end{pmatrix} \end{equation} for $z\in\mathbb{C}$. I have already handled all the cases expect for matrices like $A$. How can I write it as a product of matrices of this type? Any hints are appreciated.


Can't open menu in apps without a menu button or physical key

My device doesn't have a physical menu button, and the app that I'm using doesn't have one of the menu buttons that users can click (the three dots).  How can I open the app's menu without a menu button or key?


For static websites, I always made a Sitemap.xml file and submitted it to search engines like google, bing etc.  But now, I have made a website in Asp.net MVC which has 3 dynamic pages which yields content for the supplied id. For example there is a Store controller with Section action method that takes an id (like electronics) as parameter and shows the result for it.   Since the website is dynamic in nature, I am not sure whether I should make a sitemap or not. And if I should what should the sitemap have. In essence, How can i submit my site to search engines for indexing?  I tried checking Programmers and SO for sitemap and they don't have any. So does this mean i should leave it entirely on google bots to discover my site and index it. I just need to know the basic steps for a dynamic Asp.net MVC website


Behavior of holomorphic functions on the boundary of the unit disk

$\textbf{Problem.}$ Suppose $f$ is holomorphic on the unit disk $\mathbb{D}$. Show there are points $a_n\in \mathbb{D}$, $a\in \partial \mathbb{D}$, and $b\in \mathbb{C}$ such that $a_n\to a$ and $f(a_n)\to b$, as $n\to \infty.$   $\textbf{Attempt at a Solution:}$ First, if $f$ has an essential singularity at some point $a\in \partial\mathbb{D}$, I think the statement follows easily.  To contradiction suppose that the statement is false. That is, suppose that $f(a_n)\to \infty$ for all sequences $\{a_n\}$ in $\mathbb{D}$ where $a_n\to a$, $a\in \partial\mathbb{D}.$  Then $$\frac{1}{f(z)}\to 0, \hspace{1cm} \mbox{as} \hspace{1cm}|z|\to 1.$$  $\textbf{ Case 1}$: If $f$ is nowhere vanishing on $\mathbb{D}$, then $1/f(z)$ would be holomorphic in $\mathbb{D}$ and can be extended continuously on $\bar{\mathbb{D}}$. Then, by the maximum principle this would imply that $1/f(z)\equiv 0$ on all of $\mathbb{D}$. But this contradicts the fact that $f$ is holomorphic (non-constant) in $\mathbb{D}.$  $\textbf{Case 2}$: Suppose $f$ has a finite number of zeros in $\mathbb{D}$. That is, let $\{b_1,...,b_n\}$ be points of $\mathbb{D}$ such that $f(b_i)=0.$   Let $r=\min \{|z-b_i| \forall z\in \partial\mathbb{D}\}$, and consider the annulus $$A=\{z\in\mathbb{C}: r<r_1<|z|<1\}$$  Then, $1/f(z)$ is holomorphic on $A$, and can be continuously extended to $\bar A$. (Note that, $1/f(z)$ is already holomorphic for $|z|=r_1$.  Let $$g(z)=\frac{1}{f(z)}\frac{1}{f(r_1/z)}.$$ Then $g(z)=0$ for all $z\in \partial \bar{A}$. By the maximum principle it follows that $g(z)\equiv 0$ on $A$, and by the identity theorem it follows that $1/f(z)\equiv 0$ on $A$. But this, again, contradicts the fact that $f$ is holomorphic on $\mathbb{D}$ and thus on $A$ as well.   $\textbf{Case 3:}$ This is the case where i'm not so sure what i'm doing is correct.   Suppose, now, that $f$ has an infinite number of zeros in $\mathbb{D}$. That is, let $E=\{b_i\in \mathbb{D}: g(b_i)=0\}$. Then, $E$ cannot have an accumulation point in $\mathbb{D}.$  My idea was to take neighborhoods, $\mathbb{B}_{r_i}(b_i)$, and consider $$g(z)=\frac{1}{f(z)}\prod_{w\in A_w}\frac{1}{f(z/w)},$$ where $A_w=\{w\in \mathbb{D}: |w-b_i|=r_i\},$ for all $z\in \overline{\mathbb{D}\setminus\bigcup \mathbb{B}_{r_i}(b_i)}.$  Then, I would argue similarly as in Case 2.  There is probably a much shorter method.  I'd appreciate any thoughts or suggestions!!


I'm not so good at programming and can't tell why this isn't working. Whatever I input, it always go straight to the else statement.      public void pizzaIntro()     {     Scanner user_input = new Scanner(System.in);     String user_command = "null";     String apology = "I'm sorry it appears there has been some kind of mistake in your order.";     System.out.println("Welcome to " + cM + " here we strive to deliver excellent services to all our customers!");     System.out.println("The current prize for pizza is $" + bP + " and an extra $" + tP + " per topping.");     System.out.println(); System.out.println();     while(user_command != "exit")     {         System.out.print("Would you like toppings?(yes/no):");         user_command = user_input.next();         if(user_command.toLowerCase() == "yes")         {             System.out.println("Good Eat Your Pizza.");         }         else if (user_command.toLowerCase() == "no")         {             System.out.println("Well Ok Then!");         }         else         {             System.out.println(apology);             System.exit(1);         }     }     pic1.show(); }


Do I use ext4 for all partitions (such as / and /boot)? What are the other formats used for?

I'm installing ubuntu onto a new laptop with 24gb SSD and a 500gb HDD. I wanted to put / and swap onto the SSD and /home onto the HDD. Is there anything I shouldn't use ext4 for?  I do not ever intend to dual boot. Ubuntu only.


Can I do a factorial ANOVA on non-normal data?

If I am comparing the effect of age, sex, location (numerical) on various numerical parameters, but one of these responses are not normally distributed, can I still do a factorial ANOVA? I can't do a Kruskal Wallis test as I am comparing so many variables. EDIT: Anderson-Darling normality test gave a p-value of <0.005


Just curious to know. Suppose physicists start from the very beginning, i.e defining the fundamental quantities, figuring out the math etc. So will they see the universe differently than what we have presently, particularly can we obtain any alternative to time? Why is time given such an importance? Why is time defined as : "Time is what the clock reads"?


Alternatives to one-way ANOVA for heteroskedastic data

I have data from 3 groups of algae biomass ($A$, $B$, $C$) which contain unequal sample sizes ($n_A=15$, $n_B=13$, $n_C=12$) and I would like compare if these groups are from the same population.  One-way ANOVA would definitely be the way to go, however upon conducting normality tests on my data, heteroskedascity seems to the main issue. My raw data, without any transformation, produced a  ratio of variances ($F_{\max} = 19.1$) which is very much higher than the critical value ($F_{\rm crit} = 4.16$) and therefore I cannot perform one-way ANOVA.   I also tried transformation to normalise my data. Even after trials of various transformations (log, square root, square), the lowest $F_{\max}$ produced after transformation with a $\log_{10}$ transformation was $7.16$, which was still higher compared to $F_{\rm crit}$.  Can anyone here advise me on where to go from here? I can't think of other methods of transformation to normalise by data. Are there any alternatives to a one-way ANOVA?  P.S.: my raw data are below:   A: 0.178 0.195 0.225 0.294 0.315 0.341 0.36  0.363 0.371 0.398 0.407 0.409 0.432     0.494 0.719 B: 0.11  0.111 0.204 0.416 0.417 0.441 0.492 0.965 1.113 1.19  1.233 1.505 1.897 C: 0.106 0.114 0.143 0.435 0.448 0.51  0.576 0.588 0.608 0.64  0.658 0.788 0.958


How do I get rid of my missing animal follower?

Dawnguard allows you to recruit an Armored Troll as an animal companion.  The Troll costs 500 Gold to recruit, but when I attempt to purchase the troll, the game tells me I already have an animal companion.  What steps should I take to ensure I don't already have an animal companion and successfully recruit the Armored Troll?  This is for the Xbox-360 version.


Internal storage displays as empty when connected to PC

My HTC One M9, when connected as a MTP device to my PC shows the correct portion of free memory to used memory, but when I try to access the files, it says this folder is empty. Any ideas? I am running android 6.0


Here's what I know about dark matter: Astrophysicists realized the movements of galaxies and other astronomical bodies cannot be explained by the gravitational effects of matter known to be there, so either there is a lot of matter missing that doesn't react with light or general relativity needs to be fixed. For the purpose of this question, assume the former. I've read that this "dark matter" can't be composed of baryons (quarks and leptons). My question is how do we know that it can't be baryonic? After all, air is invisible. Maybe that's a bad analogy, but you get my point: Why can't there be matter that is invisible, yet composed of baryons?


How to remove unwanted columns from a polygon in R AND keep the result as a spatial data frame?

To simplify my problem, I'm gonna start at the source instead of explaining my full-map problem.  I have a shapefile of Ethiopia pulled from GADM (). A lot of the attribute columns are unnecessary and just create extra clunkiness as I perform clips/joins/etc. with the shapefile. So I want to remove all but the first 4 columns. Doing this seems easy enough, and I tried and succeeded with this bit of code:  library(rgdal)  #read in shapefile eth <- readOGR(dsn = "D:/Mapping-R/Ethiopia", layer = "ETH_adm0")  #subset data/remove columns eth <- eth@data[, -(5:67)]   This does indeed leave me only with the first 4 columns, but it also makes the object a regular data frame rather than a spatial data frame ready for mapping. So how do I remove these unwanted columns while maintaining status of SPDF?


Trying to install Webmin on Ubuntu 18.04 - missing apt-show-versions

I've tried following the following commands to install Webmin on my home server:  sudo apt install python apt-show-versions libapt-pkg-perl libauthen-pam-perl libio-pty-perl libnet-ssleay-perl   But it cannot locate the apt-show-versions package. Do I have to add something to sources.list?  I've managed to find  and downloaded it onto my server.  I've cd'ed into the directory but how do I install it? It's the final requirement so I can execute the following command:  sudo apt install webmin


Conky does not work properly on Ubuntu 16.04 GNOME

I have this strange problem with conky. It doesn't show properly on the desktop:    I've tried everything from editing conky widget file to reinstalling conky and conky manager (v.2.4). Who knows how to fix it?


Does an enchantment curse go to grave if the cursed player loses?

In a multiplayer game, I enchanted someone else with Fraying Sanity. They milled out. Does  go to the graveyard when that player loses, or does it still stay attached?


Showcase of surprising possibilities with TeX

LaTeX is more or less built to typeset books, particularly (but not exclusively) scientific literature. It is less obvious that LaTeX is also extremely good at producing   Songbooks Play scripts Chess diagrams Linguistic literature and IPA Bibles Dictionaries Presentations Tolkien alphabets   Can people mention other surprising and inspring uses of LaTeX that go beyond scientific literature?  This question is meant as a place to showcase surprising uses of TeX, made by you or others, a bit similar to the posting , which focuses on beautiful TeX and LaTeX documents.


How far would I have to go to see a fully rounded Earth?  Recently, I saw a video on Youtube in which a sky diver called Felix Baumgartner ascends to $120,000$ feet (= $39$ miles) in a stratospheric balloon and make a freefall jump, rushing toward earth at supersonic speeds. I could see the full face of the Earth in this video from a height of approximately 39 miles. This prompts me to ask this question.


What is dark matter? Also what is dark energy?

Today one of the greatest questions coming up is what is dark matter. also what is dark energy. we don't know much about it still! I have tried to bring some light to this question.


On Windows I really liked  as a basic image editor/manager. Some of the main features I liked were   great shortcut keys good batch conversion options ability to work with many image file formats easy viewing of images in a folder ability to open the program and paste the clipboard and do a quick save simple cropping   Though it did have a lot of features, they tended not to get in the way of simple tasks.  What would be a good replacement on Ubuntu?


How to obtain inverse behavior for `tail` and `head`?

Is there a way to head/tail a document and get the reverse output; because you don't know how many lines there are in a document?  I.e. I just want to get everything but the first 2 lines of foo.txt to append to another document.


Hide Chatter in Home Page after Summer 15

Salesforce is phasing out the use of arbitrary HTML on Home Page Components.  I have used CSS or JS solutions to hide the Chatter Feed from within a HTML Home Page Component.  This allows a more completely customized Home Page solution.  ()  After Summer15 the only available component for customizing the home page will be a VF page - that will be nested in an iFrame.  This makes it impossible to include code that affects the rest of the page - like the chatter feed.   Any ideas on retaining this capability?


Under what circumstances will Stack Exchange, Inc. share private/sensitive information with the press?

What are Stack Exchange, Inc.'s policies regarding whether and when private or sensitive information will be shared by the company with the public, and particularly with the press?  By "private information," I mean information from sources such as:   Non-public chatrooms, including mod-only rooms Non-public Teams instances, including the one for Stack Exchange Moderators Private communications between moderators and users Private communications between SOI staff and moderators Deleted content, which can only be seen by moderators or "trusted users" Flag explanations, which can only be seen by moderators Users' Personally Identifiable Information   By "sensitive information," I mean information such as:   Characterization of patterns of behavior of individual moderators or users Characterization of on-site controversies   It would seem to me that it would be standard corporate practice to avoid sharing any of the above with the public, and especially the press, without significant exigent circumstances and the utmost of care. In particular, all of the "private" information listed above is shared on the Stack Exchange platform with explicit agreement or at least implicit mutual trust that what is transmitted in a private space stays in that space or in spaces at least as private.  However, following its removal of multi-community-moderator Monica Cellio, SE , sharing information from non-public spaces and characterizing the behavior of a specific user. This behavior makes me wonder whether the privacy assumptions I describe above are in fact reflected in company policy and practice.  As the shared trust regarding private information staying private is the basis of countless communications that my moderator colleagues and I engage in with Stack Exchange users, with each other, and with SE staff, I believe it's important that SE clarify whether and how this shared trust extends to the company.


Prove that $f: [a,b]\to \mathbb R$, $|f(x)-f(y)| \leq 4|x-y|$ is integrable, when $f$ reaches its maximum in any closed subinterval.

Let $f:[a,b]\to \mathbb R$ such that it reaches its maximum and minimum in any closed sub-interval of $[a,b]$.  In addition:  $$|f(x)-f(y)| \leq 4|x-y|$$  holds for any $x,y$ in the interval. How would you prove that the function is integrable using the fact that Riemann's condition (i.e. $U-L < \epsilon$ for any epsilon)?


Windows Explorer to open folder then next folder again (Enter not working)

I just realized that this annoying bug bothers me for years.  Example: I hit Windows+E to open the Explorer and want to hit Enter  again to choose the first item C:. The problem is that C: is not focused automatically. Instead I have to press cursor down, cursor up, and then C: gets highlighted and I can finally press Enter to open it. This behaviour is the same with all folders in Windows Explorer.  Could anyone enlighten me with the shortcut to directly open the first folder without any cursor keys?


In very much need of resetting admin password for MacOS Sierra.  Unfortunately the previous instructions for the Mac OS X does NOT work for my Macbook Air.  Please help!


Is it better to continue shooting in JPEGs instead of RAW if you are not planning to do post processing?

If I don't want to do post processing of the photographs, is it better to continue shooting in JPEGs instead of RAW? Or is there a push-button workflow which will produce better JPEG images by doing RAW to JPEG conversion outside of the camera? I.e., I am willing to give more computer time for the algorithm to perform the same outside of my camera.  I am specifically looking for potential off-camera RAW to JPEG conversion which will do a better job than my 5D Mark II. I don't want to move any sliders during the process nor am I planning to store RAW after it is done.


I want to enable Intel's virtualization technology in my BIOS but my BIOS is locked with a password which was setup by the previous owner of the laptop.  Is there any other way to enable Intel VT-X or how do I remove the password?


Casablanca alone for 4-5 hours alone . middle aged woman

Marocc Air just changed my flights and now I have an 8 hours lay over in Casa Blanca.  Is it safe to take train to city tour for 4 hours and come back?  Advice please.  I have never been to Morocco


Please would you find what is wrong in the \setbeamertemplate{subsubsection page} definition. The subsubsection title page is not displayed. I do not want to use the solution mentioned in answer posted; I want to find what is wrong in my code.  \documentclass{beamer} \usepackage{verbatim} \setbeamertemplate{navigation symbols}{}  \setcounter{tocdepth}{3} \setcounter{secnumdepth}{3}  \setbeamertemplate{section in toc}[sections numbered] \setbeamertemplate{subsection in toc}{\leavevmode\leftskip=3.2em\rlap{\hskip-2em\textcolor{violet}{\inserttocsectionnumber.\inserttocsubsectionnumber.}}\textcolor{violet}\inserttocsubsection\par}  \setbeamertemplate{section page} { \begingroup \begin{beamercolorbox}[sep=10pt,center,rounded=true,shadow=true]{section title}     \usebeamerfont{section title}\thesection-~\insertsection\par \end{beamercolorbox} \endgroup }  \setbeamertemplate{subsection page} { \begingroup \begin{beamercolorbox}[sep=2pt,center,rounded=true,shadow=true]{section title}     \usebeamerfont{section title}\thesection-~\insertsection\par \end{beamercolorbox} \vspace*{-1.pt} \begin{beamercolorbox}[sep=6pt,center,rounded=true,shadow=true]{subsection title}     \usebeamerfont{subsection title}\thesection.\thesubsection.~\insertsubsection\par \end{beamercolorbox} \endgroup }  \setbeamertemplate{subsubsection page} { \begingroup \begin{beamercolorbox}[sep=6pt,center,rounded=true,shadow=true]{subsubsection title}     \usebeamerfont{subsubsection title}\thesection.\thesubsection.\thesubsubsection.~\insertsubsubsection\par \end{beamercolorbox} \endgroup }  \setbeamercolor{section title}{bg=blue!40} \setbeamercolor{subsection title}{bg=blue!20} \setbeamercolor{subsubsection title}{bg=blue!20} \setbeamerfont{section title}{size=\Large,series=\bfseries} \setbeamerfont{subsection title}{size=\large,series=\bfseries} \setbeamerfont{subsubsection title}{size=\large,series=\bfseries}  \begin{document}   \begin{frame}[t,allowframebreaks] \frametitle{Table of Contents} \tableofcontents \end{frame}  \section{ Openings } \frame{\sectionpage}  \subsection{ Ruy Lopez Opening } \frame{\subsectionpage}  \subsubsection{ Ruy Lopez: Giuoco Piano Defense } \frame{\subsubsectionpage} \end{document}


I can't open My Ubuntu Software in my ubuntu

I newly installed My Ubuntu on virtual machine and I wanted to install VS Code, Discord, etc. But when I open Ubuntu Software it shows window and closes.


I have a mid 2009 MacBook Pro still on its original software cant upgrade

Help me please!!! I have a mid 2009 MacBook Pro running Mac OS X   Version 10.7.5 it won’t let me update it to anything I tried El Capitan  Sierra, high Sierra and nothing I don’t have a disk slot on my computer it was taken off to put another hard drive with a lot of storage and 8gb or ram I tried everything everyone has posted on here! On YouTube. And on other forums can some one please help me  image description here]()


$\displaystyle{\sum_{n=1}^{\infty} \left[\left( 1 + {1 \over n}\right)^{n} - {\rm e}\right]}$  I tried both root and ratio tests  (for the root test, the expression became way too complex to handle) but both didn't really work out.  Would there be an easy way of showing that this diverges?


I try to delete this file on my solaris machine  rm "-Insi"  rm: illegal option -- I rm: illegal option -- n rm: illegal option -- s   I also try this   rm "\-Insi"   -Insi: No such file or directory    rm '\-Insi'   -Insi: No such file or directory   so what other option do I have?


PlayFunction doesn't work in DLL, but does work in standalone exe

I'm trying to play music from within a DLL. However, whenever I try this, the PlaySound function does nothing.  I've already attempted having the wav file in a resource and I know that the code works as when I compile the DLLMain as a normal main, it plays the music with no problems. The DLLMain code looks like this:  if (ul_reason_for_call == DLL_PROCESS_ATTACH) {     PlaySoundA("C:\\Sound.wav", NULL, SND_FILENAME); }  return TRUE;   The strange thing is, I can see that the song is in the program's memory; the memory usage of it goes up to what it should do when it plays a song, but it has no sound. Also, the same code compiled to an exe works perfectly; I can't figure out what's going wrong.  UPDATE: It turns out this is because you can't execute lots of things in DLLMain - are there any ways around this?


Is it possible to write special characters using the alt key?

I want to be able to type characters such as ellipse and em dash using the same key combinations as in osx (that is, alt+period for ellipse, alt+dash for endash, alt+shift+dash for emdash, etc. I checked my keyboard layout file which indicates that such characters should writable :  key <AB09>  { [    period,      colon, ellipsis,   periodcentered ] }; key <AB10>  { [     minus, underscore,       endash,       emdash ] };   However when I try to write the these characters using the alt key I'm only able to produce  . :   and  - _  I know I can produce these characters by defining and using compose key, but if it's possible I'd much prefer my keyboard to behave as it does in osx


postfix discard or change Message-ID header based on another header line

I want to change the Message-ID header or better yet, discard it. I know everyone is going to ask "Why would you want to do that?" because I know it sounds weird to even write it.  Well I am developing a system that saves an incoming e-mail in EML format, changes it and sends it to the user, at some point the user can request to have the original EML sent to him/her. The issue is that when I re-send the EML it has the same Message-ID header which causes exchange servers to drop the re-send.  Of course I am hoping there is some option through postfix to do this, otherwise I will need to parse and change the EML but I rather not do that.  I tried to do this with "header_checks" and it works BUT I need to be able to do this conditionally, meaning only on a specific occasion, which I can identify by looking at the other headers, I want to remove the Message-ID.


I have 4 partitions and 106Gb unallocated. I try to install Windows on 106Gb Free Space. but While installing, I got that 2 partiotions got unallocated. How can I recover them??   result of quick scan with test disk:   Disk /dev/sda - 1000 GB / 931 GiB - CHS 121601 255 63  The harddisk (1000 GB / 931 GiB) seems too small! (< 22 TB / 20 TiB) Check the harddisk size: HD jumpers settings, BIOS detection...  The following partition can't be recovered:      Partition               Start        End    Size in sectors >  Linux Swap           12449 132 28 2697543 159 48 43136036832    [ Continue ] SWAP2 version 3147161575, pagesize=8192, 22 TB / 20 TiB   and also  Disk /dev/sda - 1000 GB / 931 GiB - CHS 121601 255 63      Partition               Start        End    Size in sectors >* Linux                    0  32 33 12449 132 35  199999488  P Linux Swap           12449 132 36 13694  97 35   19998720  P HPFS - NTFS          13694 130  5 32089 105 16  295514112  L HPFS - NTFS          32089 137 49 44837 191 26  204800000  L HPFS - NTFS          44837 223 59 70947  59 24  419446784  L HPFS - NTFS          70947  91 57 107747 157 58  591196160  L FAT16 >32M           107747 190 28 117776 162 18  161114112   result of fdisk -l  Device     Boot      Start        End    Sectors   Size Id Type /dev/sda1  *          2048  200001533  199999486  95.4G 83 Linux /dev/sda2        200001534 1953519615 1753518082 836.1G  f W95 Ext'd (LBA) /dev/sda5        720320512 1139767295  419446784   200G  7 HPFS/NTFS/exFAT /dev/sda6       1139769344 1730965503  591196160 281.9G  7 HPFS/NTFS/exFAT /dev/sda7       1730967552 1892081663  161114112  76.8G  6 FAT16  Partition 2 does not start on physical sector boundary.


When I was initially learning to use LaTeX, the professor who taught me the basics instructed me to use \\ as a way to end a previous line and start a new line of text.  However, many of the veteran users on this forum are opposed to this method.  Is there a method that is objectively better (and not just preferred) over the others and why?


If $\gcd(a,b) = 1$ then $\gcd(a,a + b) = 1$

Let $a$ and $b$ be integers. Show that if $(a,b) = 1$ then $(a,a + b) = 1$.   I'm stuck on how to do this proof. I tried using the fact that $ax+by=1$ but that didn't seem to help.


Let $R$ be a commutative ring $(\neq 0)$ with 1, I have proven that $R$ has at least one maximal ideal, but I can't proved that $R$ has at least one prime ideal. I read that it's trivial but I can't see it. Some help? Is clear that $0$ es prime ideal iff $A$ is an integral domain, but this isn't the case.


Not mangling names renders music unplayable on Windows 10 Samba

I have set up a very basic file server on linux. I used the Samba setting mangled names=no to disable to make sure the files are legiable under Windows, but once I do that, all the wav files I have stored in the folder are unreadable/unmovable/unplayable.   I cannot use different files, the script I am using can only generate .wav files.   An example of the file name would be 2017-07-24 12:54.wav, which otherwise gets mangled as 2BB0Y9~4.WAV.


I always thought larger sample sizes were better.  Then I read something somewhere about how when sample sizes are larger, it's easier to find significant p-values when they're not really there (i.e., false positives), because significance gets exaggerated.  Is there a name for this phenomenon?  I'm currently working with a large sample size (around 5,000 cases) where I did a t-test and the p-value turned out to be less than 0.001. What test(s) can I use to determine whether this is a valid p-value or whether this happened because the sample size was large.  I'm not a statistics expert, so please pardon any "newb-ness" evident in my post.


In javascript, how do I display "0" at the end of "$1.3" only when it's a whole number, not like "$1.32"?

What I'm doing is getting user input with   var x = document.getElementById('id');    and the output is in whole numbers due to rounding errors, so 1.34 is 134 and I display it with  id.innerHTML = '$'.concat(amount / 100);   It is displaying "$1.32" correctly but I don't want "$1.3" for consistencies sake.  So my question is what would be the best way for detecting that "$2.6" for example needs a "0" at the end whereas "$2.53 doesn't? And how to I implement that?


Should there be an apostrophe in the sign "residents parking". A quick Google  suggests there shouldn't. But why not? Is "residents" an adjective?


What happens to the images from deleted questions and/or answers?  Will they be kept or they will be deleted with the answer?  What happens with the images, that are edited out from the post? The links are still there in revision history, but what with the image under that link?


Is it possible to trade CFD without leverage?

I'm new to trading. Based on what I read, trading CFD involves high risk because of leverage.   Is it possible to trade CFD stocks without leverage (in Etoro for example)?  If this is possible, then I would lose/gain only the percentage by which the stock goes down/up.  Thank you


I have a little form where the website visitor can enter his email to subscribe for a newsletter. My goal is to make the form send me an email with the information he entered.  My problem is every single e-mail I get goes straight to the Junk folder.  HTML:  <form class="subscribe" action="subscribe.php" method="POST">     <input type="text" name="subscribefield" required="true" placeholder="Awe" />     <button type="submit"><i class="fa fa-paper-plane fa-lg" aria-hidden="true"></i>     </button> </form>   PHP:   <?php    $email = $_POST['subscribefield'];   $to = "test@live.com";   $subject = "new sub";   $body = $email;    mail($to, $subject, $body);    echo "your mail was sent"; ?>


If a prime divides a product then it must divide a factor of the product [Euclid's Lemma]

We have $q, p$ prime and $tq = (p-1)(p+1)$ for some positive integer $t$. The book I'm reading says that because $q$ is prime, it divides $p-1$ or $p+1$.   Question: Why exactly does it matter that $q$ is prime here?


Has there ever been a sequel that has been scrapped and remade after release?

There has been a lot of talk recently about The Last Jedi being hated, so much so that there are individuals that want to strike it from Star Wars canon and remake it.  Regardless of what you think of this movie (or the proposition to remake it), I'm wondering if there has ever been a movie in a series that has been completely scrapped from the series canon after being released. It seems likely that it hasn't happened in a major series, as that seems like it would be widely known. I'm wondering if a production studio officially has removed a movie from series canon after release, possibly due to fan reaction, later discovery that there were significant errors in production, or simply change of mind regarding the writing.


newbie to python: code doesn't see global variable of one type but it does of another

I am new to python, so this may be a silly question...  Why does the function fetchsamples not see the variable smilies? Strangely, the variable frownyDict and smileyDict are accessible, while smilies is not.  The error I get is:  Traceback (most recent call last):   File "simple.py", line 41, in <module>     fetchsamples()   File "simple.py", line 18, in fetchsamples     print smilies UnboundLocalError: local variable 'smilies' referenced before assignment   Below is the python code:  ##my global vars  frownyDict={} smileyDict={} frownyDict['_counter_']=0 smileyDict['_counter_']=0 frownies = 0 smilies = 0    def fetchsamples():     print frownyDict;     response = [":) happy",":( sad","sad","dunno"]     counter=0     print smilies     for tweet in response:         if (tweet):             tweet=tweet.encode("iso-8859-1", "ignore")             if ":)" in tweet:                 parse(smileyDict,tweet)                 counter+=1                 smilies+=1             if ":(" in tweet:                 parse(frownyDict,tweet)                 counter+=1                 #frownies+=1                 frownyDict['_counter_']+=1;             if ":)" in tweet or ":)" in tweet:                 guess(tweet)                 # let's predict!              if (counter % 50==10):                 print frownyDict;                 print smileyDict   if __name__ == '__main__':   fetchsamples()


Is it possible to pre-download a YouTube video to view it later offline?

I have the Galaxy S3, and I'd like to watch YouTube videos during my commutes. I like to watch long videos (around 1 hours), so I have no more than 1 video per commute.   However, youtube video takes a lot of bandwidth and I have a cap on data usage. Besides, connection outside during peak hours tend to be slow, which makes the video pause to download a lot of times.   Is it possible to pre-download a video at home (using my Wi-Fi, which is faster and has no data cap), and watch it on the way? I tried pausing it at home and let it download, but whenever the phone sleep (it sleeps often!), or the application switch from youtube to anything else, it seems all previous download will be lost.


When I have to choose my DNS I think that I should consider:   Speed Reliability Privacy Control (reports and stats)   The main options that come to my mind, and how I weigh them according to the above factors, are:   My ISP = faster (closer to me) but less privacy (they can associate my DNS requests to myself) OpenDNS and such = more control and more privacy (all they have is one of my e-mail addresses) Google = less privacy (they can associate my DNS requests to my Google Account and my searches)   What weighting factors, or other options, have I missed?


I submitted an article to one of the OMICS journals and also paid for it only to find out they are a predatory journal. article not yet publish. Any advice what I should do?


Do we know why speed of the light in vacuum is exactly 299792458 $m/s$?

I know similar questions were already here, but anyway, do we know the reason why the measured speed of the light is exactly 299792458ms? Why it is not twice more or half of it? Is there something braking the light in the vacuum down? I mean something like a dark matter or a dark energy? As far as I know the light does not interact with these two (except its probably curved with the dark matter gravity), but anyway, do somebody has a theory why it is exactly like that?  Edit:  The answer I like most:  :  Ultimately, the answer is that we don't know. And, at the same time, we don't know if we can ever know why it is this way.  We've measured cc with respect to a unit system that we humans have devised1, but we do not know if there is any reason for it to take that particular value; it simply is what it is.  1 We defined the speed of light as a constant in 1983, so technically the meter and second are determined from cc, not the other way around as I have suggested here.    But if somebody has a theory why it is exactly like that ;)...


I sometimes accidentally change the behaviour of the view port navigation. I don't know how I do it, nor how to reset it.  The behaviour is different insofar that if I press the middle mouse button and move the mouse, the view does not rotate around a point that lies somewhere where I'm looking at but more like around a point in the "camera" of the view port.  It's like looking around in a first person shooter.  What mode is this and how do I change it back?


Story about machines generating energy with parallel universes, endangering ours

I suppose I read this story in a book in the nineties but I have no memory of actually reading it or the cover, I just remember a lot of the plot.  Scientists find out they are being contacted by the inhabitants of some other universe. I believe this happens by one element being exchanged with another (I remember wolfram was involved because I had never heard that word before) and messages somehow added. This leads to earth building some sort of machine together with the other universe (it is the description of this machine that I really would like to read again) that somehow generates energy on both sides. Only later do the people on earth realize, that it also slowly changes some of natures constants, threatening, I believe, the sun. The book also had detailed descriptions of everyday life in both universes. I remember some sport played in the lower gravity of the moon and the aliens having three distinctive sexes.


I'm relatively new to ubuntu.  With all the  news of ransom ware lately I'm curious as to how susceptible Ubuntu is?


Centre a 4 Horizontally DIV Block Using CSS

I have four div blocks and I want to Centre the Horizontally, they keep stacking under each other.. any ideas how I can do this.

1. name of the company

2. name of the company

3. name of the company

4. name of the company


Percent Signs for Shell Vars to Remove Extension

for file in *.pdf ; do     newname=${file%\\.\*} done   I don't understand how the %\.* is removing the file extension, can someone walk me through it.


how to create new scene with no default objects?

It's very annoying to have to delete the cube, camera, and light every time I start a new scene. I only use Blender for games, so I never use those things. I would love for a new "General" scene to include a clean slate.


Is there a rule why the correct spelling for "Marketing" is not " Marketting"?

I have always assumed that you doubled the consonant when the vowel preceding it is short.   bet and betting for example; Why is this different for market and marketing?


I have the following function:  def my_func():     """My docstring is both funny and informative"""     pass   How do I get access to the docstring?


Skype 4.3.0.37 stopped working after installation of Nvidia 340.32 drivers

I did a fresh install of Ubuntu 14.04 and tried skype, it worked.  Now I decided to install the video driver from NVIDIA website, install went successful but now Skype is not starting anymore, no error, nothing.  Any help to diagnose this problem, please?  Thank you.


I am getting the following problem while generating JasperReports's report.  I am using JasperReports 4.5.1 version, Java 1.8.  Exception:   Caused by: java.lang.NoClassDefFoundError: net/sf/jasperreports/compilers/GroovyEvaluator    Could you please help anyone.


Upgrade from 15.10 to 16.04 - "no new release found"

I have Ubuntu 15.10 installed. I want to upgrade to 16.04. The option to do this does not show up in software updater. When I ran do-release-upgrade -cd it returns No new release found.   So I downloaded the iso and put it on a usb stick. When I boot up into the installer the option to upgrade 15.10 to 16.04 is blanked out. It will allow me to erase the current installation or install alongside.   Is there anything else I can try before erasing my current installation (thus losing some of my settings).


In Madoka Magica, are the girls' powers related to their wishes?

Some of the Puella Magi seem to have magical powers related to the wishes that they made. Sayaka has regeneration abilities, and she wished to heal someone. Homura has time manipulation abilities, and she wished to go back in time.  But other magical girls, like Mami and Kyouko, don't appear to have powers related to their respective wishes.  So, is there a connection, or is it only a coincidence for Sayaka and Homura? If it's the former, how do Mami and Kouko's wishes relate to their powers?


Make a static IP permanent 18.04.4 LTS bionic

I can set the static IP with ifconfig eth0 10.0.0.1 but reboot I have to do it again. There is no /etc/netplan or /etc/network/interfaces so where or how to set the IP permanent? the command ip is so convoluted as to be useless


how calculate running time of method containing other method using new Date().getTime() in java?

i want to calculate running time of method (encryptTree)and this method call inside it other method(encrypt) as the follwoing:  public  BloomFilterIndex encryptTree(BloomFilterIndex tree) {     for(int m=0;m<tree.root.children.size();m++){         BloomFilterIndex.BFINode<Integer>n = (BloomFilterIndex.BFINode<Integer>) tree.root.children.get(m);         encrypt(n);     }     return tree; }  public void encrypt(BloomFilterIndex.BFINode<Integer> root) {     List<double[]> ress = new ArrayList<>();     if(!root.isLeaf()){         c = new double[root.value.size()];         for (int i = 0; i < root.value.size(); i++) {             c[i] =root.value.getBitSet().getWord(i);                                                                                }          ress.add(c);         root.value = null;         root.value2 = ress;          for(BloomFilterIndex.BFINode<Integer> g:root.children)             encrypt(g);       } else {         double[] y = new double[400];         double[] z = new double[400];         Random r = new Random();         Integer g1 = r.nextInt();         double m5 = (double) ((double) Math.round(g1 * 10) / 10.0);         java.util.Vector<Double> m6 = new java.util.Vector<Double>(400);         java.util.Vector<Double> n1 = new java.util.Vector<Double>(400);          for (int i = 0; i < s.size(); i++) {             if (s.get(i) == 1) {                 m6.add((double) root.value.getBitSet().getWord(i));                 n1.add((double) root.value.getBitSet().getWord(i));             } else {                 m6.add( 0.5 * (root.value.getBitSet().getWord(i))+m5);                 n1.add( 0.5 * (root.value.getBitSet().getWord(i))+m5 );             }         }          for (int i = 0; i < 400;i++) {             for (int j = 0; j < 400; j++) {                 y[i] += a2[i][j] * m6.get(j);                 z[i] += b2[i][j] * n1.get(j);             }         }         ress.add(y);         ress.add(z);         root.value = null;         root.value2 = ress;     } }   i want to use new Date().getTime() to calculate the running time of encryptTree that guarantee it contain all method inside it. when i try to use it as:  public  BloomFilterIndex encryptTree(BloomFilterIndex tree) {     startTime9=new Date().getTime();     for(int m=0;m<tree.root.children.size();m++){         BloomFilterIndex.BFINode<Integer> n = (BloomFilterIndex.BFINode<Integer>) tree.root.children.get(m);         encrypt(n);     }     end=new Date().getTime()-startTime9;     end/=1000.0;     System.out.println("encrypt node in :"+end);      return tree; }   but i not get the correct result.


A countable family of point-wise bounded functions defined on finite measurable set is actually uniformly bounded on a closed subset

Let $m$ be Lebesgue measure on $\mathbb R$ and $\mathcal{F}$ a countable set of Lebesgue measurable functions defined on Lebesgue measurable set $E\subset\mathbb R$ with $m(E)<\infty$. Assume that for each $x\in E$, the set $\{|f(x)|:f\in\mathcal F\}$ is a bounded subset of $\mathbb R$. Show that for all $\epsilon>0$, there is a closed set $F\subset E$ and a number $M<\infty$ such that $m(E\setminus F)<\epsilon$ and $|f(x)|\le M$ for all $x\in F$ and all $f\in\mathcal F$.     My attempt:  By , for each $f_n\in\mathcal F$, there exists a closed subset of $F_n$ such that $f_n$ is continuous on $F_n$ with $m(E\setminus {F_n})<\epsilon/2^n$. Then for every $f\in\mathcal F$, $f$ is continuous on the closed set $F=\bigcap_{n=1}^\infty F_n$ with $m(E\setminus F )<\epsilon$.   Now how to prove that it is uniformly bounded on $F$?


James Paterson in his novel writes, “she was shrink by trade, a forensic profiler, and Jack Morgan’s number two at Private “.   What does whole sentence mean?


Form or asymptotic behaviour of $T(n) =2T(n-1)+n$

$T(n) =$ if $n=1$, then time execution is $1$, if $n \geq 2$ then $2T(n-1)+n$  The options are:   $T(n) = 2^{n+1} - n - 2$ $T(n) = O(n2^n)$ $T(n) = \Omega(n)$ $T(n) = \theta(2^n)$   Thanks.


What happens to Temporary Hit Points when you Wild Shape?

I have a character that has Inspiring Leader, and I can grant temporary hit points to my team members.  We have a Druid in the group that tends to use Wild Shape frequently.  When the Druid uses Wild Shape, do the Temporary Hit Points transfer over to the new form, or are they "attached" to the original form?  Is there anything in the books that handle this?


I was trying to experiment with docker, Ubuntu 14.04, 64-bit. I managed to run an image, and I gave it the path on one of my removable drives, /media/Drive1.  Now, whenever I reboot, I see there is a /media/Drive1 with only a docker directory inside it, and the actual drive which should be Drive1 ends up mounted on /media/Drive11, and this happens every reboot - even when I unmount these drives, and do a sudo rm -rfv /media/Drive1 before rebooting!  So something probably creates /media/Drive1 before it is fully mounted, and I guess that something is docker, because when I boot, I have:  $ ps axf | grep docker  2085 ?        Ssl    0:00 /usr/bin/docker -d   So, how can I disable the docker autostart, so it doesn't interfere with the mounting of external USB drives at boot?


Setting pagination for images attached to a post

I am trying to figure out how to paginate a post for it's images. I have a custom post type set up to act like a gallery - images only. And would like to paginate the images. I am having a hard time trying to figure out where to start with this.   I am using get_posts() within the loop to get the images attached to the post. I would like to set it up so 30 images display per page.   Any idea where I should start? Or do I need to alter the way I have this gallery feature set up in WP?  Thanks in advance!


How do I archive with subdirectories using the 7-Zip command line? Or, how do I KEEP the folder structure while archiving?

I have a bunch of files like this:  C:\G\G1\35antique-shop.mp3 C:\G\G2\35antique-shop.mp3 C:\G\G1\09saguri.mp3 C:\G\G2\09saguri.mp3   I just want to know how to keep the folder structure while archiving. This is more important than the duplicate thing, to know how to solve that, would be a bonus.     @Lamb "Do you want to archive only selective files (not the whole folder content) from the G1 and G2 folders?"   That almost says it all, but I'll try to improve: Not only do I want to move only some selected files to an archive. I also have a list of these files, including path-names to each file.  So, in SubDir1 there might be 10 files, of which I want to zip three, and in SubDir1\sub2 there might be five files, of which I want to zip all five. The files that I need to archive are in a listfile.  There might be duplicate files, so my hope is that with subdirectories added, 7-Zip does NOT see them as duplicates.  And I like to do it on the command line.  I've tried a batch file like this:  7z a -r MyArchive.7z C:\G\G1\35antique-shop.mp3 7z a -r MyArchive.7z C:\G\G2\35antique-shop.mp3 7z a -r MyArchive.7z C:\G\G1\09saguri.mp3 7z a -r MyArchive.7z C:\G\G2\09saguri.mp3   This also means that files 01antique-shop.mp3, 02antique-shop.mp3, ...., til 33antique-shop.mp3 and 34antique-shop.mp3, should NOT be archived.  The foldernames (=subdirectories) weren't added to MyArchive.7z, and this is the problem.  Obviously, I'd like to use just one commando with a listfile, but that doesn't work either.  I've tried:  7z a -mx0 -tzip C:\$$-edrive\F-G-H.zip @fgh.txt   which actually works pretty fine as far as the selecting goes, but it does NOT keep the directory structure. Sadly.  How do I do this?


I want to create a new user to run a service on the system but don't want to have /home and other configuration files for it. Like there is a user for postgres but it doesn't have any /home directory.


90s fantasy book: man can access a parallel medieval world while 'dreaming'

I read a book in my high school library back in the late 90s and pretty sure it was written in the mid 90s. I can't remember the author or title.  The setting is current to the 90s mid-west. But it also takes place in an alternate medieval style fantasy world that only certain individuals can go to via falling asleep.  The main character is a gas station attendant in his early 30s, whose father left or died and he inherited a storage container full of odd stuff. For as long as he can remember he has had these real dreams where he is a monk at a monastery scribing books. He has no knowledge the dreams are actually a real world, that he's part of a family who can travel between the worlds.   Those that can travel between the worlds also possess binary magic, it uses opposites: life/death, fire/water, strength/weakness etc. The main character discovers that he can use life/death. Two strangers save him from the monastery, a woman using strength/weakness and her son who uses fire/water.   The two strangers who rescue him from the monastery are trying to take him to their family holdings to explain why he is important and what the other world is.  In the modern world he is falsely kidnapped and rescued to introduce him to the families, because they want a magical relic that each family has and that his father has taken and hidden.   Because he is new to binary magic and not taught the same rules as everybody else growing up he learns new things that were never considered, such as holding the bond open so he can see other people using magic etc.


How to create a link to a folder in Ubuntu 18.04 using GUI

If my memory is not playing me up this could be done with old versions of Ubuntu but I can't find a way of doing it with 18.04.   Is there a way of doing it?


Installing ubuntu 16.04 on a usb flash drive using windows

So i installed ubuntu on a flash drive using rufus, but every time i reboot everything gets erased (everything i did in the last session before rebooting.)


Conceptual data model for warehousing objects

I'm student and new to databases. I must conceptualize a database model for warehousing video games using a  (MySQL).  Every objects in the warehouse have common fields (unique ID, picture url, price, weight, name, etc.).   Then, there is three object's types with their own specific fields :    Video Games Consoles Accessories Controller Hardware Etc...   What would be the best relation model to link a common object to its specific category, fields and sub-category?  I know that there is  that could do this easily, but I must work with MySQL.


using a table as an attribute in java class

I want to make a table as an attribute  and retrieving it was successful but it comes with an error  public class Main {     public static class stock {         public int n;         public int t[];         public stock(int n)         {             t=new int[n];         }         public void display()         {             for(int i:t)             {                 System.out.print(i+"   ");             }         }     }     public static void main(String[] args) {        stock s=new stock(4);         stock c[] =new stock[4];         for(int j=0;j<2;j++)         {         for(int i=0;i<4;i++)         {             s.t[i]=i;         }         c[j]=s;         }         for(stock x:c)             x.display();     } }   this is the result with an error how can i get rid of it where is the problem


Can I leave Schengen one day after my visa expires?

I have a Schengen visa from 14th to 17th. Due to some circumstances, I had to change the flight from 17th to 18th, so I'm not flying out of Schengen on 18th around noon. Is this legal? If not, what are my options to extend my visa?


How I can use UTF8 in PDO PHP, whe I want display my result?

<?php $pdo = new PDO('mysql:host=localhost;dbname=leonzemaim', 'leonzemaim', 'leonzemaim'); $stmt = $pdo->prepare('SELECT * FROM Orders'); $stmt->execute(); ?>   Hi. I try get my result in utf8 code?


When to use “that” and when to use “which”, especially in relative clauses

When is it appropriate to use that as opposed to which with relative clauses?


Detect the Internet connection is offline?

How to detect the Internet connection is offline in JavaScript?


Finding convergence or divergence of a complex series

I want to determine the convergence of the following series: $$\Sigma_{n=1}^{\infty}\frac{n!}{n^n}i^n$$ I have tried applying the criteria of the n+1th over nth term: $$lim_{n->\infty}\left|\frac{(n+1)!}{(n+1)^{n+1}}i^{n+1}\frac{n^n}{n!i^n}\right|=lim_{n->\infty}\left|\frac{(n+1)n^n}{(n+1)^{n+1}}i\right|$$ $$=lim_{n->\infty}\left|\frac{n^n}{(n+1)^{n-1}}\right|$$ But how can I evaluate this limit?


The FAQ  contains the question And can users see their own comment upvote number somewhere?.  However,  does not cover this.  Can users see their own comment upvote number somewhere?


MacBook Air mid 2011 - Handoff not supported

Is there a failure with OS X Yosemite?   I have a MacBook Air mid 2011, with:   Bluetooth Version 4.3  Bluetooth Low Energy Supported  LMP Version 0x6      Does somebody experience the same behaviour?