I want to plot ROC for Leave-one-out (LOO) cross-validation (CV). I have the decision values as well as probability values for each class from SVM classifier. I did see the answer to this ; however, the answer was not complete about plotting ROC according to probabilities.  As an example the output of my classifier for one sample is like this:  c1a   1  attr(,"decision.values")           1/0 c1a 0.1338180 attr(,"probabilities")             1         0 c1a 0.6824716 0.3175284 Levels: 0 1

I am interested in calculating area under the curve (AUC), or the c-statistic, by hand for a binary logistic regression model.  For example, in the validation dataset, I have the true value for the dependent variable, retention (1 = retained; 0 = not retained), as well as a predicted retention status for each observation generated by my regression analysis using a model that was built using the training set (this will range from 0 to 1).  My initial thoughts were to identify the "correct" number of model classifications and simply divide the number of "correct" observations by the number of total observations to calculate the c-statistic. By "correct", if the true retention status of an observation = 1 and the predicted retention status is > 0.5 then that is a "correct" classification. Additionally, if the true retention status of an observation = 0 and the predicted retention status is < 0.5 then that is also a "correct" classification. I assume a "tie" would occur when the predicted value = 0.5, but that phenomenon does not occur in my validation dataset. On the other hand, "incorrect" classifications would be if the true retention status of an observation = 1 and the predicted retention status is < 0.5 or if the true retention status for an outcome = 0 and the predicted retention status is > 0.5. I am aware of TP, FP, FN, TN, but not aware of how to calculate the c-statistic given this information.


I am a student with both Master's and Bachelor's degree in Biotechnology with a good aggregate. But, i have a low GRE score of 295. My TOEFL score is 107 along with a research project going on.   What do you think are my chances of getting in in a PhD program for Biological sciences?  I have had a good academic as well as extracurricular career.  Apart from GRE what factors should i be concerned about which might affect my admission?

As I've already saw, many people here are related to admission process. And I want to ask their opinion on what is priority of all stuff from application: what is the most important (letters of recommendation or personal statement, GPA or maybe test scores), what is less important for admission and what is the least important? Would admission committee prefer applicant with good scores, high GPA, but with not outstanding personal statement and without letters from famous or well-known professors (for example, my scientific advisor in undergraduate school get his PhD only a couple years ago), or student with less GPA, test scores, but with letter from university's prof?  Some graduate schools require General GRE (Graduate Record Examinations). Would it better to send GRE scores (general or subject or both) even if it's not required (in case of relatively good result), or them wouldn't be considered at all?


I am working on an application where I need to detect whether user has pressed ctrl+f6 for certain navigation path. How to capture ctrl+f6 key press event in javascript/jquery?

I want to handle F1-F12 keys using JavaScript and jQuery.  I am not sure what pitfalls there are to avoid, and I am not currently able to test implementations in any other browsers than Internet Explorer 8, Google Chrome and Mozilla FireFox 3.  Any suggestions to a full cross-browser solution? Something like a well-tested jQuery library or maybe just vanilla jQuery/JavaScript?


I'm so new to Ubuntu, I just started playing with it 19 hours ago. I'm really not 100% sure what I'm doing, so please excuse the mistakes in terminology and general processes.  As I was attempting to make my Samsung 740U3M able to dual boot, I had no extra USB drives except my external hard drive. I used etcher to put the ISO on the drive, but the website said it wouldn't delete everything.  It did delete everything when I put the ISO on there.   So, I powered down the machine and bought a second 32GB USB drive to install from. I now have the latest Ubuntu and updates installed on the internal HDD.  Is there any way to save the stuff from my external hard drive? I haven't used it, so I don't believe it's been overwritten. Please help!? I'm an undergrad and all of my work was on there!  EDIT It's not a duplicate of that question because he was trying to make an image of his HDD, whereas I was trying to put the ISO "next to" my files on my external HDD. Etcher "flashed" my HDD when it put the ISO on the HDD. I'm currently running a quick search in TestDisk. Instructions called for me to check the "Intel" option for the search.

I need some help recover files from a partially overwritten partition.  I will start with what happened. I was trying to make a image out of my hard drive using dd, but I found somewhere online that using pv would tell me the best bs count to make the copy, what it didn't say was that it would make the copy.  I ran the following command:  pv < /dev/sda > /dev/sdc   When I realized what was going on I stopped it, but it had already written around 1GB. I would like to recover the files that were not written over, I suspect those that were are long gone.  If someone knows a way I would be thankful.


I have edited sshd_config file by adding "AllowGroups   tried Combinations :   AllowGroups \GroupName AllowGroups \GroupName

I have join my linux to windows domain succesfully, and now everyone in the domain is able to log in to the server by using ssh.  But we only want to allow certain users from a group to log in.  Example of current two groups:  #it_admin  Domain Admin


I'm a sys admin being tossed in to a DBA role. I currently have two SQL Server boxes, 2016 Enterprise, in an AG. The DB has synchronized without any issues.   A third party vendor needs to have an identical user on both servers with the same User Mapping. But when I try to adjust the mappings on the secondary I get an error stating that the DB is in READ ONLY mode. How can I create this user with the correct mappings?

We have 2 servers in an AlwaysOn group.  While the user accounts within each synchronized database exist on both servers, the database instance level logins only exist on one of the servers. Ie DBINSTANCE->Security->Logins are missing on one server.  Therefore when there is a failover, I get login failures on the second server (which doesn't have the corresponding instance level logins).  How do I overcome this issue? Was I supposed to set up the user account in a special way?


I was looking at  recently, so if you look at the diagram for op-amp, it's just a bunch of npn and pnp junctions. But how could they come together and work as a voltage amplifier and achieve a \$V_{out}>>V_{supply}\$?  How does Bipolar junction transistor amplify the voltage?

If you try to obtain a voltage greater than the power rails of an op-amp, what will happen?  I am assuming that the output == the rail limiting it. Is that correct, or does it break the op-amp?


The motion of a photon in the gravitational field is described by a simple condition: the four vector has zero norm. My question is: is it possible to derive this dynamic from a Lagrangian? I was thinking to use the usual action but I have realized very soon that it applies only for massive particles.

For relativistic massive particle, the action is $$\begin{align}S ~=~& -m_0 \int ds \cr ~=~& -m_0 \int d\lambda ~\sqrt{ g_{\mu\nu} \dot{x}^{\mu}\dot{x}^{\nu}} \cr ~=~& \int d\lambda \  L,\end{align}$$ where $ds$ is the proper time of the particle; $\lambda$ is the parameter of the trajectory; and we used Minkowski signature $(+,-,-,-)$. So what is the action for a massless particle?


I'm trying to set my disk as a download folder for qBitTorrent. The problem is that when I'm trying to choose /media/milano/Milano Disk - here is my disk mounted. But nothing is being downloaded and when I try to open the folder using qBitTorrent it says:  Which is weird because qBitTorrent is running under milano user and Milano Disk has these permissions: milano@milano-desktop:~$ ls -la /media/milano/ total 24 drwsrwsrwx+ 3 root   root    4096 lis  7 16:19  . drwsrwsrwx  3 root   root    4096 dub 11  2020  .. drwxrwxrwx  1 milano milano 16384 zář  7 23:57 'Milano Disk'  Do you have an idea where is the problem? The same problem is when I try to use a different disk to be the destination.

I have Ubuntu 18.04 LTS installed. I inserted USB-flash to my laptop. It was automounted to /media/username/DISKLABEL and opened in Nautilus. I can read and write objects to it. How can I access it from the application, which is installed as Snap? I tried snaps of the following applications such as gedit, arduino-mhall119, organize-my-files. All them show me errors if I navigate to /media folder:    Could not read the contents of Media Error opening the directory of '/media': permission denied  Output of active Snap  is below: $ snap interfaces  | grep -v ".*-$" Slot                             Plug :browser-support                 organize-my-files :core-support                    core:core-support-plug :cups-control                    gedit :desktop                         gedit,organize-my-files :desktop-legacy                  gedit,organize-my-files :gsettings                       gedit,organize-my-files :home                            arduino-mhall119,gedit,organize-my-files :network                         arduino-mhall119,gedit,organize-my-files,pulsemixer :opengl                          organize-my-files :pulseaudio                      organize-my-files,pulsemixer :unity7                          arduino-mhall119,gedit,organize-my-files :wayland                         gedit :x11                             arduino-mhall119,organize-my-files,pulsemixer gnome-3-26-1604:gnome-3-26-1604  gedit gtk-common-themes:gtk3-themes    gedit gtk-common-themes:icon-themes    gedit gtk-common-themes:sound-themes   gedit -                                arduino-mhall119:serial-port -                                gedit:avahi-observe -                                gedit:mount-observe  Updates:  connecting mount-observe to Gedit with snap connect gedit:mount-observe does not help. it seems that we need special Snap with support of  interface.


ok.setOnClickListener(new View.OnClickListener() {          @Override         public void onClick(View v) {             // TODO Auto-generated method stub             if(mode.getText().toString()=="Default"){                 Toast.makeText(getApplicationContext(), "Cannot Delete Default", Toast.LENGTH_SHORT).show();             }               //else{              /*  db = openOrCreateDatabase("MY_App_Data", MODE_PRIVATE, null);              db.execSQL(DATABASE_TABLE_CREATE);             ContentValues cvInsert=new ContentValues();             cvInsert.put("mode",mode.getText().toString());             cvInsert.put("msg",msg.getText().toString());             db.insert("SSP_Data", null, cvInsert);             Toast.makeText(getApplicationContext(), "Mode Added", Toast.LENGTH_SHORT).show();             list.add(mode.getText().toString());*/             //}         }     });   hey guys in the above code my if statement is not working please help me out there iz no syntax error then why its nt executing please say smthing abt it

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


in visual studio, I create a new branch from my master branch, write something new, and these changes also appear there when switching to the master branch.Can someone tell me how to configure it so that they do not go there automatically?Thanks

I am working on a git repository with a master branch and another topic branch. I have switched to topic branch and modified a file. Now, if I switched to master branch that same file is shown as modified.   For example:  git status in git-build branch:  # On branch git-build # Changes to be committed: #   (use "git reset HEAD <file>..." to unstage) # #       modified:   cvsup_current #   Switch to master branch  [root@redbull builder_scripts (git-build)]# git co master M       builder_scripts/cvsup_current Switched to branch "master"   git status in master branch  [root@redbull builder_scripts (master)]# git status # On branch master # Changes to be committed: #   (use "git reset HEAD <file>..." to unstage) # #       modified:   cvsup_current #   Why is that the file is shown as modified in master branch even though it was modified in git-build branch?   My understanding was that the branches are independent of each other and when I change from one branch to another the changes do not "spill over" from one branch to another. So I am obviously missing some thing here.   Anyone got a clue stick?


How can I center a <section> vertically and horizontally inside a div?  jsFiddle:

I have a div 200 x 200 px. I want to place a 50 x 50 px image right in the middle of the div.   How can it be done?  I am able to get it centered horizontally by using text-align: center for the div. But vertical alignment is the issue..


Is it legal to change  $\exists$x A(x) $\implies$ $\exists$y B(y)  to:  $\exists$x $\exists$y (A(x) $\implies$  B(y))  If i'm thinking correctly, A(x) is free from $\exists$y and should be allowed to move. However i am not able to prove it. So far i have:  $\neg$$\exists$x A(x) $\vee$ $\exists$y B(y)  $\forall$x $\neg$A(x) $\vee$ $\exists$y B(y)  $\forall$x $\neg$A(x) $\vee$ $\neg$$\forall$y $\neg$B(y)  $\forall$x ($\neg$A(x) $\vee$ $\neg$$\forall$y $\neg$B(y))  $\forall$x $\neg$ $\forall$y($\neg$A(x) $\vee$ $\neg$B(y))  $\neg$$\exists$x $\forall$y($\neg$A(x) $\vee$ $\neg$B(y))  $\neg$$\exists$x $\forall$y(A(x) $\wedge$ B(y))  $\neg$$\exists$x $\neg$$\exists$y $\neg$(A(x) $\wedge$ B(y))  $\neg$$\exists$x $\neg$$\exists$y ($\neg$A(x) $\vee$ $\neg$B(y))  $\neg$$\exists$x $\neg$$\exists$y (A(x) $\implies$ $\neg$ B(y))  I'm likely to have mistakes here, have not touched this in a while.

I found a statement that says  $$\forall x[P(x) \rightarrow Q] \equiv \exists x[P(x)] \rightarrow Q$$  Where $Q$ is a formula that does not contain $x$. I need to know when exactly would the equivalence hold. Can we just convert $\forall$ quantifiers to $\exists$. Is there a way to prove the right hand side statement from the left hand side?


I am using heredoc statement for printing html, but how can we embed php code inside that html for example:   $results = $conn->query($sql);  $html = <<<html

             ID	             Technician	             Project	             Region	             Date	             Type	             Notes

         <?php while($row = $results->fetch_assoc()):
             {$row['ID']}	             {$row['Technician']}	             {$row['Project']}	             {$row['Region']}	             {$row['Date']}	             {$row['Type']}	             {$row['Notes']}
         <?php endwhile; ?>

 html;   How can we do something like that . . .

In PHP, the HEREDOC string declarations are really useful for outputting a block of html.  You can have it parse in variables just by prefixing them with $, but for more complicated syntax (like $var[2][3]), you have to put your expression inside {} braces.  In PHP 5, it is possible to actually make function calls within {} braces inside a HEREDOC string, but you have to go through a bit of work.  The function name itself has to be stored in a variable, and you have to call it like it is a dynamically-named function.  For example:  $fn = 'testfunction'; function testfunction() { return 'ok'; } $string = <<< heredoc plain text and now a function: {$fn()} heredoc;   As you can see, this is a bit more messy than just:  $string = <<< heredoc plain text and now a function: {testfunction()} heredoc;   There are other ways besides the first code example, such as breaking out of the HEREDOC to call the function, or reversing the issue and doing something like:  ?> <!-- directly output html and only breaking into php for the function --> plain text and now a function: <?PHP print testfunction(); ?>   The latter has the disadvantage that the output is directly put into the output stream (unless I'm using output buffering), which might not be what I want.  So, the essence of my question is: is there a more elegant way to approach this?  Edit based on responses: It certainly does seem like some kind of template engine would make my life much easier, but it would require me basically invert my usual PHP style.  Not that that's a bad thing, but it explains my inertia..  I'm up for figuring out ways to make life easier though, so I'm looking into templates now.


I am getting Linux Training and came across one question that I am unable to find answer of:  What does the . mean in chmod command? Eg: chmod 777 .

Simple question, but I'm not sure where to look and google doesn't respond to periods and slashes.  I'm just trying to count the # of files & directories in the current directory (not including subfolders/files) and was trying to differentiate ls -1 | wc -l and ls | wc -l since they seem identical.  A site I was looking at said "Keep in mind that this is also counting the ./ and ../ directories." regarding the one with ls -1, and I'm not sure if that means it includes the directories before or something (which I don't want), but it didn't seem to do that from testing.  Could someone confirm which one of those would be most adequate for counting # of files & directories in the current directory only (not sub) and what they mean by ./ and ../ directories?


I'm trying to prove that the relation R on $\mathbb{Z}$ is an equivalence relation, where R is defined by:  $$\{(x,y)\in \mathbb{Z}\times\mathbb{Z}: x^2\equiv y^2 \!\!\!\mod \!\!4\}$$   I know I need to show that it is reflexive, symmetric, and transitive, but I'm not sure how to do that when working with congruence. Thank you.  I answered my own question below but I'm not sure if I did it correctly. Any feedback would be really helpful. Thanks.

Question 1: Let $x,y \in S$ such that $x\sim y$ if $x^2 =y^2\pmod6 $. Show that $\sim$ is an equivalence relation.    This is what I tried: Reflexive: $x^2\pmod6 = x^2$  implying $x\sim x$ Symmetry: suppose $x\sim y$, then  $x^2 =y^2\pmod6$ Operating by inverse of $x^2$ both sides we have $e=(x^2)^{-1} y^2\pmod6$ Then I have $y^2=x^2\pmod6$, hence $y\sim x$ I would like to get some corrections up to here because am not sure with this     Question 2. Find the orbits of the given permutation:    $$v:\mathbb{Z}\to\mathbb{Z}\quad\text{ defined by }\quad v(n)=n+3$$   Here is my solution which I would also want somebody to correct me! Let the relation $\sim$ be defined on $\mathbb{Z}$ by $a\sim b$ if $b=a+3$ I consider that the orbits of $v$ are the classes of $\mathbb{Z}$ with respect to $\sim$ given by  $\{b\mid b=a+3\}$. Thus I get only three orbits which are $\{1,4,7,10,…,3n-2\mid n\in \mathbb{Z}\}$, $\{2,5,8,…,3n-1\mid n\in \mathbb{Z}\}$, and $\{3,6,9,…,3n \mid n\in \mathbb{Z}\}$.


In Android KitKat on many devices, it is simple to move an app to an external microSD card.  It's as simple as Settings -> Apps -> [Select the app] -> Move to SD card.  For apps whose manifest allows them to be moved (something every good app should allow except when there is a valid reason to not), this works like a charm.  Doing this frees up the device's internal storage, allowing room for more apps.  But to where are the apps actually moved?  I thought the apps would be moved to the Android/data and Android/obb folders on the external SD card.  But upon examining those folders with several root file managers, the moved apps are not visible in those locations.  What's the story?  To where are those apps being moved?    I am voting to self-close this question, as I see another very similar question here:   I'm not going to delete it because Susan's answer is very useful and appreciated.

My phone (Sony E4g, running Android 4.4.4) offers the possibility of moving some of the installed apps partially onto the (removable) SD-card. I use this feature regularly, and -in theory- quite a big part of the apps are already moved on it. My problem is however that I can't find these anywhere on the SD-card, and there are no separate partitions on the card either. So my question is: where exactly are this moved apps stored on the external storage in KitKat ? Thanks.


If I am correct in stating that a factorial of a number ( of entities ) is the number of ways in which those entities can be arranged, then my question is as simple as asking - how do you conceive the idea of arranging nothing ?   Its easy to conceive of a null element in the context of arrays, for example - so you say that there is only one way to present a null element.   But, in layman terms - if there are three humans $h1, h2, h3$ that need to be arranged to sit on three chairs $c1, c2, c3$ - then how do you conceive of a) a null human, and b) to arrange those ( that ? ) null humans ( human ? ) on the three chairs ?   Please note that referral to humans is just for easy explanation - not trying to be pseudo-philosophical. Three balls to be arranged on three corners of a triangle works just fine. So basically, how do you conceive of an object that doesn't exist, and then conceive of arranging that object ?  So, in essence ... is $0! = 1$, a convenience for mathematicians ? Not that its the only convenience, but just asking. Of course, there are many.  If yes, then its a pity that I can't find it stated like so anywhere.  If not, then can anybody suggest resources to read actual, good proofs ?

How can I prove  from first principles that $0!$ is equal to $1$?


My brother and I were both born on March 18, but he was born in 2000, and I was born in 2002. What do you call that?

What is the term for two siblings born on the same calendar day, one or more years apart? I know there's a term, and I'd know it if I saw it, but I can't for the life of me remember it.


I have a class that extends FormBase and there are 6 services that are injected into the class via Dependency Injection (DI). My problem is when I submit the form it says to a class property that normally should be injected, it's NULL and can't be called the load() function on NULL. However when I debug, I clearly see all the dependencies are injected to the class and saved to the properties, but until the execution reaches the validation/submit function somehow it became all property to NULL. Why does this happen? How can I use DI in the form validation/submit phase? I'm really thinking if this class is not a deserialized cached version... Extra info this form also has an ajax function where the DI works fine.  I went a bit deeper into the system, after the classfinder creates my form with the injected things and saved into this place: $form_state->getBuildInfo()['callback_object'], I found it out the problem is the cache. (/core/lib/Drupal/Core/Form/FormCache.php:149)    protected function loadCachedFormState($form_build_id, FormStateInterface $form_state) {     if ($stored_form_state = $this->keyValueExpirableFactory->get('form_state')->get($form_build_id)) {       // Re-populate $form_state for subsequent rebuilds.       $form_state->setFormState($stored_form_state);        // If the original form is contained in include files, load the files.       // @see \Drupal\Core\Form\FormStateInterface::loadInclude()       $build_info = $form_state->getBuildInfo();   The system loads the formstate from the cache with the following lines, the $stored_form_state contains the cached state, without any dependencies, and the $form_state->setFormState($stored_form_state); line overwrites my formstate which contains the right properties with the DI classes... And that's a problem.

In order to make a managed_file field permanent I did this in my module configuration form:  <?php  namespace Drupal\my_module\Form;  use Drupal\Core\Form\ConfigFormBase; use Drupal\Core\Form\FormStateInterface;  /**  * Class MymoduleSettings.  */ class MymoduleSettings extends ConfigFormBase {    /**    * {@inheritdoc}    */   public function getFormId() {     return 'my_module_settings';   }    /**    * {@inheritdoc}    */   public function buildForm(array $form, FormStateInterface $form_state) {     $config                    = $this->config('my_module.settings');     $form['my_module_title'] = [       '#type'          => 'textfield',       '#title'         => $this->t('Title'),       '#description'   => $this->t("Enter the title"),       '#maxlength'     => 64,       '#size'          => 64,       '#required'      => TRUE,       '#default_value' => $config->get('my_module_title'),     ];     $form['mymodule_icon']   = [       '#type'              => 'managed_file',       '#title'             => $this->t('Icon'),       '#description'       => $this->t("Upload the image file for the icon"),       '#upload_location'   => 'public://',       '#upload_validators' => [         'file_validate_extensions' => ['gif png jpg jpeg'],       ],       '#default_value'     => $config->get('my_module_icon'),     ];     return parent::buildForm($form, $form_state);   }    /**    * {@inheritdoc}    */   public function submitForm(array &$form, FormStateInterface $form_state) {     parent::submitForm($form, $form_state);      $this->config('my_module.settings')       ->set('my_module_title', $form_state->getValue('my_module_title'))       ->set('my_module_icon', $form_state->getValue('my_module_icon'))       ->save();      // First we just grab the file ID for the icon we uploaded, if any.     $icon_field = $form_state->getValue('my_module_icon');     $file_id    = empty($icon_field) ? FALSE : reset($icon_field);      if (!empty($file_id)) {       // Make this a permanent file so that cron doesn't delete it later.       $file         = File::load($file_id);       $file->status = FILE_STATUS_PERMANENT;       $file->save();       $file_usage = \Drupal::service('file.usage');       $file_usage->add($file, 'my_module', 'file', $file_id);     }   }    /**    * {@inheritdoc}    */   protected function getEditableConfigNames() {     return [       'my_module.settings',     ];   }  }   but I'm getting warning to use dependency injection principle in this case:  File::load calls should be avoided in classes, use dependency injection instead   and  \Drupal calls should be avoided in classes, use dependency injection instead   I looked through  but still not sure that I really get it.  Can someone explain me what I need to do in this particular case so I can get a better view on this issue and figure it out?


Is it possible for two benders to have a child who could wield both abilities of its parents?

After reading this question  While it seems that it would break one of the rules of the show, that only the avatar can master all four elements. There would also be good reasons as to why someone couldn't learn all four, there is always the opposing element that is hardest for the Avatar to learn. I don't see any reason why someone couldn't learn to bend two elements (not master, but just bend since Thadeus's Answer  to the previous question is apparently the Definitive Answer on the subject.)    Many benders do learn to bend beyond their element such as Toph becoming a metal bender and Katarra bending blood. Now metal is considered part of the Earth but so is sand and it seems that sand is moved more like water. Iroh was able to adapt a water bender technique to fire bending which means it is possible to learn and use different bending styles. Also Iroh spent time connecting to the spirit world and that seems to be the main reason the Avatar is able to bend all 4 elements. So if someone was connected to the spirit world or even their past life that would fulfill that requirement.   Would it be possible to bend two elements?  There do seem to be times where it has been done in the series such as bending mud which is both Earth and Water. And there would definitely be limits such as a Earth bender couldn't bend Air and a Water bender couldn't bend Fire. But why couldn't a Fire Bender learn to bend Air. They both use breath control as a main focus of their bending. It also states on the Energybending wiki entry that all bending used to be done as an inner bending but that it became element bending.   So with new bending techniques being formed all the time, already stated used of combined elements being used, an assumed spiritual connection to a past life or a spiritual journey been taken, energybending rediscovered is it possible that two elements could be bent by one bender who is not the Avatar?


I am trying to put a matrix determinant into a table, but the left line of the matrix does not show up:   Can you help me get the left line to show up in the determinant matrix?  Thank you!  Here is my code:  \documentclass[11pt]{article} \usepackage{booktabs} \usepackage[table,x11names,dvipsnames,table]{xcolor} \usepackage{blkarray} \usepackage{colortbl} \usepackage{multicol} \usepackage{mathtools}  \begin{document}  \begin{table} \centering \rowcolors{2}{blue!10}{white}     \begin{tabular}{c|c|c|c|c|c|c|c} \rowcolor{blue!50} Row & $z^{0}$      & $z^{1}$      & $z^{2}$     & $z^{3}$     & $z^{4}$     & $z^{5}$      & $z^{6}$      \\ 1   & 0.01822 & -0.0891 & 0.5265 & -0.825 & 0      & -0.25   & 1       \\ 2   & 1       & -0.25   & 0      & -0.825 & 0.5265 & -0.0891 & 0.01822 \\ 3   & $\begin{vmatrix}          0.01822 & 1 \\          1 & 0.01822        \end{vmatrix}$        &        $\begin{vmatrix}          0.01822 & -0.25 \\          1 & -0.0891        \end{vmatrix}$          &        &        &        &         &         \\ 4   &         &         &        &        &        &         & \end{tabular} \caption[Jury's Table for $Q(z)$]{Jury's Table for $Q(z)$} \end{table}  \end{document}

I want to typeset a tabular with alterning row colors, containing matrices. Somehow, when adding \rowcolors{1}{}{black!5} the left bracket of some matrices is just omited. What am I doing wrong and how can I avoid this?   \documentclass[ border=2pt]{standalone}  \usepackage{amsmath} \usepackage[natural,table]{xcolor}  \begin{document}     \rowcolors{1}{}{black!5}     \begin{tabular}[t]{ll}         \rowcolor{gray!50}{\bfseries SKP} & \\ \hline         $A$ & $\begin{bmatrix}-0.25 & 1 \\ 0 & 0.5  \end{bmatrix}$\\         $b=g$ & $\begin{bmatrix}0 \\ 1\end{bmatrix}$         \end{tabular} \end{document}


I am currently backing an open source JavaScript presentation framework that I use and believe is one of the best available.  I am leaving out the name here on purpose as I don't know what proper etiquette or the rules are about this.  I am not the creator, author, nor am I associated with this project in any way other than I am currently using the framework.  I would really like to see the project get funded as it will accelerate development of this project to even better functionality and will enable the group behind the framework to create a series of learning videos.  Is there a proper way to point the vast StackOverflow community to this project as I believe there would be a very large group of developers who would be interested and could use this open source software.

I would like to advertise my  on StackExchange. After spending 10 minutes creating a 220x250 image, I was told that new users can't link images. I have been around a while on SO, so I feel this is a little over-protective. I need at least 10 points. Can someone upvote me, please?


function foo(bar) {     // ... }   and  foo = function(bar) {     // ... };   What is the benefit of one versus the other?  The main benefit I see in the latter is not running into errors with a function name already being defined.  However, there may be other benefits or drawbacks that aren't obvious.  What are they (if any)?

I've recently started maintaining someone else's JavaScript code. I'm fixing bugs, adding features and also trying to tidy up the code and make it more consistent.  The previous developer used two ways of declaring functions and I can't work out if there is a reason behind it or not.  The two ways are:  var functionOne = function() {     // Some code };     function functionTwo() {     // Some code }   What are the reasons for using these two different methods and what are the pros and cons of each? Is there anything that can be done with one method that can't be done with the other?


I ran a linear regression with one dependent and one explanatory variable. The data covers log returns of an index and log returns of a stock (natural logarithm).  log return of stock = Alpha + Beta + log return of index + error  The p value for the Beta estimate is <2e-16. I googled the meaning of this number, which means that the p value is extremely close to zero, but it does not equal to zero.  Now I am confused, since values below 0.01 show significant results, but what if the p value is practically zero? Does it mean that the regression provides a perfect fit?

For some tests in R, there is a lower limit on the  calculations of $2.22 \cdot 10^{-16}$. I'm not sure why it's this number, if there is a good reason for it or if it's just arbitrary. A lot of other stats packages just go to 0.0001, so this is a much higher level of precision. But I haven't seen too many papers reporting $p < 2.22\cdot 10^{-16}$ or $p = 2.22\cdot 10^{-16}$.   Is it a common/best practice to report this computed value or is it more typical to report something else (like p < 0.000000000000001)?


I was wondering if there was any complete guide to the Linux Terminal (don't mind buying a book or something), specifically, I want the list (or book) to do an A-Z of the commands with all their parameters, reasons why you'd use those commands and examples.  If anyone has recommendations I'd be most appreciative!  Thanks in advance!

I want to start using the terminal more often, but I don't know what are the different commands available to me. Is there a way to list all the different commands that I can make use of?


I want to run a command automatically. The problem is that it may only be run after I logged in and that it requires superuser privileges. I've heard of suid before, so I thought I'd use it for this.  I created a script /mountDropbox.sh which only contains the bash shebang and a mount command. Then I ran this command to set the setuid bit:  sudo chmod 4755 /mountDropbox.sh   However, when I try to run it as a normal user, mount complains about not being executed with superuser privileges:  $ /mountDropbox.sh  mount: only root can do that   Why does this happen? How can I achieve that this file is always executed with superuser privileges?  I use Ubuntu 16.04 with kernel 4.4.0-134-generic. / is an ext4 file system.  $ ll /mountDropbox.sh  -rwsr-xr-x 1 root root 77 Sep  4 17:35 /mountDropbox.sh*

The setuid permission bit tells Linux to run a program with the effective user id of the owner instead of the executor:  > cat setuid-test.c  #include <stdio.h> #include <unistd.h>  int main(int argc, char** argv) {     printf("%d", geteuid());     return 0; }  > gcc -o setuid-test setuid-test.c > ./setuid-test  1000  > sudo chown nobody ./setuid-test; sudo chmod +s ./setuid-test > ./setuid-test  65534   However, this only applies to executables; shell scripts ignore the setuid bit:  > cat setuid-test2  #!/bin/bash id -u  > ./setuid-test2  1000  > sudo chown nobody ./setuid-test2; sudo chmod +s ./setuid-test2 > ./setuid-test2  1000     Wikipedia :     Due to the increased likelihood of security flaws, many operating systems ignore the setuid attribute when applied to executable shell scripts.   Assuming I'm willing to accept those risks, is there any way to tell Linux to treat the setuid bit the same on shell scripts as it does on executables?  If not, is there a common workaround for this problem? My current solution is to add a sudoers entry to allow ALL to run a given script as the user I want it run as, with NOPASSWD to avoid the password prompt. The main downsides to that is the need for a sudoers entry every time I want to do this, and the need for the caller to sudo some-script instead of just some-script


I'm trying to prove that $\log F_n =  Θ(n)$ and where   $$F_n = F_{n-1} + F_{n-2}$$ $F_1 = 1$, $F_0 = 0$  There's already a  about this question, but the accepted answer doesn't explain a certain calculation in detail, and I was hoping someone here understands and could explain it to me!  I don't understand the part   $$\log F_{n+1}=\log(F_n+F_{n-1})=\log F_n+\log\left(1+{F_{n-1}\over F_n}\right)$$  More precisely I don't understand how $log(F_{n-1}) = \log\left(1+{F_{n-1}\over F_n}\right)$  I hope someone can explain how this is possible.

I need to show log $Fib_{n}$ is $\theta(n)$ by the Fibonacci numbers defined as   $$ F_n=F_{n-1}+F_{n-2}$$  for  $$ n \geq 2 $$ $ F_{0} = 0 $ and $ F_{1} = 1 $  I'm not sure how to approach this.   I can see it grows exponentially as I've shown a basecase for $F_{6}$.  Basecase for $F_{6}$:  $$ F_{2} = F_{1} + F_{0} = 1 + 0 $$ $$ F_{3} = F_{2} + F_{1} = 1 + 1 $$ $$ F_{4} = F_{3} + F_{2} = 2 + 1 $$ $$ F_{5} = F_{4} + F_{3} = 3 + 2 $$ $$ F_{6} = F_{5} + F_{4} = 5 + 3 $$  But how I prove it's true for log $Fib_{n}$ is $\theta(n)$ I don't know. Hope someone can help!


I've been watching The Original Series and on any occasion when Mr Spock has some health issues McCoy seems either baffled or unable to help him without taking risks or being completely unable to predict Spock's reactions to whatever treatment he can provide.  I wonder why the Enterprise  would have a chief medical officer who doesn't understand the biology of a member of the crew. Shouldn't all doctors aboard be perfectly capable of treating all of their patients regardless of their biology?  Is that mentioned at any point in the series later? Is this common with other medical officers in other series?

In  when Ambassador Sarek became critically ill, why didn't they send him home or send for a Vulcan medical expert? Since they were hosting many prominent political figures from many races, it seems strange that they did not have much medical support for a race so common as Vulcans (who are part of the Federation).


Does anyone know I can solve for the limit of (1/n!)^(1/n) ? Thanks in advance

How do I prove if $\sup\{ (n!)^{1/n} | n \in\Bbb N\} = +\infty$?  I don't know how to properly explain it


Initial Itinerary: (Entry) Italy (3 days) -> Switzerland (3 days) -> France (6 days) -> Netherlands (3 days) (Exit)  With the initial plan, I have to apply for Schengen visa in the French consulate. Now, after I get the visa, what if I need to change the itinerary to the following    Updated Itinerary: (Entry) Italy (5 days) -> Switzerland (3 days) -> France (2 days) -> Netherlands(3 days) (Exit)    In this case. What will the immigration officer ask when I enter Italy with a Schengen visa issued in France? Notice that I just change the number of days I stay in each country. Will this be a problem?  EDIT: For clarification.  The simpler question in my mind is, what if you like a place a lot, and intend to stay there longer, and vice versa, what if you don't like a place and want to move on to the next destination. This will result in change in the number of days declared per country during visa application.

My mother in law (Russian national) has a Schengen visa issued by Austria. The itinerary says she is entering Germany initially then travels to Austria in a few hours and stays there as her main destination.  We would now like to change this to a direct Austrian entry. Am I right in assuming that there will be no problem at the border since, while we dropped the point-of-entry country, it is not the one that issued the visa and so it's fine to just enter Austria with an Austrian-issued visa?  A side question is, is it also OK to add another country (Italy) and stay there for a few days longer than Austria, thereby making Italy the main destination? Obviously still within the original visa validity time frame!


The number $16$ can be represented as $2^4=4^2$. Is there a (real) number after $16$ that can be represented as $A^B=B^A$? Where A and B are two distinct real numbers.I've checked many numbers and I'm convinced that there are  no other numbers with such property, I conjecture that $16$ is the only real number with such property. But maybe I'm wrong. Is it true that $16$ is the only number with such property ? (My question here is much more specific than the other similar question has been posted.)

It's not too difficult to figure out that $x$ and $y$ can both be 1, and also $x$ can be 2 and $y$ can be 4 (and vice versa). But I can't rule out if there are other solutions. Does it have anything to do with inverse functions? Is there a way to see the solutions by graphing, or algebraically?


I don't understand why this happens, value l/m does not get truncated to two decimals after the dot...  root@OpenWrt:~# python3 Python 3.7.4 (default, Sep 15 2019, 18:13:03)  [GCC 7.4.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> l = round((69.2222222/100),2)                   >>> print(l) 0.68999999999999995 >>> type(l) <class 'float'> >>> m = 69.22222222/100 >>> print(m) 0.69222222220000007 >>> type(m) <class 'float'> >>> round(m,2) 0.68999999999999995   This happens on a custom openWRT 18.6 build with  installation.  Why does that happen?   Am I missing any packages?

The documentation for the  function states that you pass it a number, and the positions past the decimal to round. Thus it should do this:  n = 5.59 round(n, 1) # 5.6   But, in actuality, good old floating point weirdness creeps in and you get:  5.5999999999999996   For the purposes of UI, I need to display 5.6. I poked around the Internet and found some  that this is dependent on my implementation of Python. Unfortunately, this occurs on both my Windows dev machine and each Linux server I've tried. .  Short of creating my own round library, is there any way around this?


Hi guys I did something very stupid to my system   Chmod 777 -R /    After that everything disappeared including the mouse pointer I'm was able to log in now but things are so corrupted I can't use su and so on . I did search on the suse website and found that many people had faced this problem unfortunately with no help . Is there any guideline to put things back on the right track ??  What's the default permissions for any Linux system and how to know them??

I was trying to run chmod -R 777 ./ but ended up typing chmod -R 777 / and set 777 on my entire machine. What can go wrong? How can I fix it?


I may be missing something obvious here, but I cannot figure it out. In my attribute table under the area_ft_su column, I have a bunch of NULL entries. I want to change those NULL entries to zero without having to manually change each one. The output preview looks correct, but when I click "Ok", nothing happens. Nothing is updated. Am I missing something or is my syntax wrong?

Is it possible in QGIS either directly or via plugins to do a raster calculation including an if statement?  e.g., if raster1 > 0.3, then raster 1 * raster 2, else raster1 x raster3... something like that?


Can someone explain to me in detail if halls effect is magnetic induction?

I want to ask about the workings of the . Why do the electrons come to rest on the edge of the wire? The magnetic field pushes them up, and the electric field pushes them forward. Shouldn't they reach the top of of the conductor and then stop moving up but continue moving forward?  Why does the magnetic field stop them from continuing to flow? The magnetic force is up so why would it effect their velocity forwards?


New guy to Blender, want some advice on tutorial projects with small polycounts. So far I have modeled a pawn and a mug.

Since asking for tutorials, videos, resources, links to other content or downloads is considered off topic here, this is a specifically created Community Wiki which gathers resources for Blender and it has been approved by the .  Just write in the appropriate answer/section. If you have concerns, questions, post a  question, so we don't clutter the comments, but you can link your meta question from the comments.  Questions regarding such resources are not allowed anymore, except for very specific and on topic requests (ask on  if you're unsure about your question). Follow the instructions made in the question about how to post, what can be posted, etc.  Learning             Assets    (also see: )   Reference Images/Blueprints (also see: )    Tools    (also see: )      Other   Special Interest ()     Also see the .


I read some places that you can just install Docky using apt by default but that doesn't work. Tried adding the repository, but it's one of those that won't update because it's unauthorized or something. Is there a repo that works with Ubuntu 19.04 for Docky?  EDIT: @user535733   > $ sudo add-apt-repository ppa:docky-core/stable [sudo] password: > This ppa is currently used for builds of release builds of > docky and plank.  More info: > https://launchpad.net/~docky-core/+archive/ubuntu/stable Press [ENTER] > to continue or Ctrl-c to cancel adding it. >  > Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease Hit:2 > http://archive.canonical.com/ubuntu cosmic InRelease                   > Hit:3 http://us.archive.ubuntu.com/ubuntu disco InRelease              > Hit:4 http://dl.google.com/linux/chrome/deb stable Release             > Hit:5 http://us.archive.ubuntu.com/ubuntu cosmic InRelease             > Get:6 http://security.ubuntu.com/ubuntu disco-security InRelease [97.5 > kB]      Hit:7 http://us.archive.ubuntu.com/ubuntu disco-updates > InRelease               Hit:8 http://us.archive.ubuntu.com/ubuntu > cosmic-updates InRelease              Ign:9 > http://ppa.launchpad.net/docky-core/stable/ubuntu disco InRelease      > Hit:11 http://us.archive.ubuntu.com/ubuntu disco-backports InRelease   > Err:12 http://ppa.launchpad.net/docky-core/stable/ubuntu disco Release > 404  Not Found [IP: 91.189.95.83 80] Reading package lists... Done     > E: The repository 'http://ppa.launchpad.net/docky-core/stable/ubuntu > disco Release' does not have a Release file. N: Updating from such a > repository can't be done securely, and is therefore disabled by > default. N: See apt-secure(8) manpage for repository creation and user > configuration details.   You know, just you're usual can't update repo error.

When updating, I get the following error message:   W: The repository 'http://ppa.launchpad.net/mc3man/trusty-media/ubuntu xenial Release' does not have a Release file.   Here, I find another statement on this error:   This recommends removing certain PPAs; and, I'm not sure if I should do that since it might mean not getting the updates that I need.    Is this what I should do?


static testMethod void testPost(){      RestRequest req = new RestRequest();      RestResponse res = new RestResponse();     Profile testEditorProfile = [Select id from Profile where Name= :System.Label.Profile_Editor];      req.requestURI = System.URL.getSalesforceBaseUrl()+'...XYZ...';       req.httpMethod = 'PUT';      TService.PostResponseWrapper postResponseInstance=TService.doPost();      system.debug('***Response***'+postResponseInstance); }   Note:The post  method is defined in the service class and  does not have any       arguments

This is a canonical question and answer developed by the community to help address common questions. If you've been directed here, or your question has been closed as a duplicate, please look through the resources here and use them to shape more specific questions. To browse all canonical questions and answers, including more unit test resources, navigate to the  tag.  How do I unit test code that includes a SOAP or REST-based callout, or indirectly calls code that makes a callout? I'm getting an error saying that callouts are not supported.


I have repeatedly tried to use a LAN world with my sister. we are both on the same WiFi. whenever i start a lan world minecraft tells me it has been hosted on ***** port. my sister then checks on her computer and cannot see my world.  I know this has been asked before, here and elsewhere but i cant find a good answer anywhere.

My LAN server won't let my cousin join me or me join my cousin. It won't show up on the multiplayer screen - it keeps saying "scanning for LAN servers" but it never finds it. I am at his house and we use different computers but it won't connect. How can I fix this?


In how many ways can 9 black and 9 white rooks be placed on a 6 × 6 chess   board, so that no white rook can capture a black one?   A rook can capture another piece if it is in the same rank (row) or the same   file (column) as the other piece, with no other pieces between the two.   This is terribly hard. I literally dont understand.  The solution says you cant have one color occupy more than 3 rows, but it clearly can! How should I do this?

In how many ways can $9$ black and $9$ white rooks be placed on a $6 × 6$ chess board, so that no white rook can capture a black one? A rook can capture another piece if it is in the same rank (row) or the same file (column) as the other piece, with no other pieces between the two?  I was thinking of a $6×6$ matrix, but that option doesn't seem to help?


I am in the process of updating scripts and models from ArcGIS Desktop to work in Pro however I'm having difficulty getting results from geoprocessing operations to display in the map window.   As an example, for the following snippet:  import arcpy arcpy.env.overwiteOutput = True aprx = arcpy.mp.ArcGISProject("CURRENT") m = aprx.listMaps("*")[0] inputFC = arcpy.GetParameterAsText(0) outputWorkspace = arcpy.GetParameterAsText(1) outputFC = arcpy.GetParameterAsText(2) outputFC = outputWorkspace + "\\" + outputFC arcpy.MultipartToSinglepart_management(inputFC, outputFC) outputLyr = arcpy.MakeFeatureLayer_management(outputFC, "outputLyr") m.addLayer(outputLyr, "TOP")   I get the error: "ValueError: outputLyr". The process completes successfully, it's just that I can't get the result to add to the map.  My knowledge of python is quite limited but as I understand it, a feature class needs to be made into a layer before being added to the map. Previously in Desktop we used the following:  layer_file = arcpy.mapping.Layer(outputFC) arcpy.mapping.AddLayer(dataframe, layer_file)   Where am I going wrong?

I want to add a feature class within a Geodatabase to a map in ArcGIS Pro (1.4.1) using arcpy. I am converting some python code from ArcGIS Desktop to ArcGIS Pro.   This issue is very similar to:    and      However, instead of adding a feature class (or layer) to a map using the Python Window I am doing this from a  Script within a Toolbox. I have included a code snippet below.  lyrTest = r"C:\data\test.gdb\Layer1"  aprx = arcpy.mp.ArcGISProject("CURRENT") aprxMap = aprx.listMaps("MainMap")[0]  lyrFile = arcpy.mp.LayerFile(lyrTest) aprxMap.addLayer(lyrFile)   I get the following error message:  Traceback (most recent call last): File "C:\data\AddLayers.py", line 5, in <module>     aprxMap.addLayer(lyrTest) File "c:\users\user\appdata\local\programs\arcgis\pro\Resources\arcpy\arcpy\utils.py", line 191, in fn_ return fn(*args, **kw) File "c:\users\user\appdata\local\programs\arcgis\pro\Resources\arcpy\arcpy\_mp.py", line 1048, in addLayer return convertArcObjectToPythonObject(self._arc_object.addLayer(*gp_fixargs((add_layer_or_layerfile, add_position), True))) ValueError: C:\data\test.gdb\Layer1 Failed to execute (AddLayers).


I'm thinking a solution should exist already, but I'm unable to find it... so, how could I highlight citations to a work a specific author contributed to?  It's a bit like printing the name of a certain author in bold in the bibliography, but this doesn't work in citations where the author one wants to highlight is hidden in the "et al."  For highlighting an author in the bibliography, I use  with the \boldname command.   The highlighted author's name might have non-standard characters, so I use a silly example author, Därwin. The behaviour I want would be like this:   Where to start? Add a keyword and change all cite commands by calling \renewbibmacro*{cite}{...}? And what to put there ?  Here's a MWE, I haven't really done anything, but at least it should show the options I'm using (for the sake of conciseness, I left the \boldname definition out, but I could add it if it is relevant).   \documentclass{article}  \usepackage[latin9]{inputenc}   \usepackage[style=authoryear-comp,natbib=true,%  minbibnames=15,%  maxbibnames=15,%  backend=biber]{biblatex}  \usepackage{filecontents}  \begin{filecontents}{\jobname.bib}  @Book{Darwin.84,    author =      {C. D\"{a}rwin},    title =   {The different forms of flowers on plants of the same species},    publisher =   {John Murray},    address =      {London},    edition =      2,    year =    1884}   @ARTICLE{Davies.pnas04,  AUTHOR = {Davies, T. J. AND Barraclough, T. G. AND Chase, M. W. AND Soltis, P. S. AND Soltis, D. E. AND D\"{a}rwin, C.},  TITLE = {D\"{a}rwin's abominable mystery: {Insights} from a supertree of the angiosperms.},  JOURNAL = {Proc. Natl. Acad. Sci. U.S.A.},  VOLUME = {101},  PAGES = {1904--1909},  YEAR = {2004},  MONTH = Feb,  NUMBER = {7}  }   @ARTICLE{Vamosi.el10,  AUTHOR = {Vamosi, J. C. AND Vamosi, S. M.},  TITLE = {Key innovations within a geographical context in flowering plants: towards resolving {D\"{a}rwin}'s abominable mystery.},  JOURNAL = {Ecol. Lett.},  VOLUME = {13},  PAGES = {1270--1279},  YEAR = {2010},  MONTH = Oct,  NUMBER = {10}  }   \end{filecontents}  \addbibresource{\jobname.bib}   \makeatother   \begin{document}    \citet{Darwin.84} a souvent été cité, par exemple par    \citet{Davies.pnas04,Vamosi.el10}.   \printbibliography   \end{document}

Say I use a bibliography file in my document, relying on Biblatex and Biber for citation management.  Given a citation command such as \cite{A, B, C} (or any other standard Biblatex citation command), I'd like the resulting citations to be typeset differently depending on whether a given field (e.g. the author field) in the corresponding bibliography entry contains a given string (e.g. someone's lastname).   Besides, I'd like to generate two different bibliography sections in the resulting document, depending on the same condition as above.  Typically this would be used to differentiate, both at the citation level in the main text and in the appendix, the publications that I co-authored from others.  EDIT: adding a MWE:  \documentclass{article} \usepackage{filecontents} \usepackage[backend=biber,style = alphabetic]{biblatex} \usepackage[colorlinks=true, breaklinks, allcolors = blue]{hyperref} \DeclareSourcemap{%   \maps[datatype=bibtex]{%     \map{%       \step[fieldsource=author, match=Doe, final]%       \step[fieldset=keywords, fieldvalue=doe]%     }%   }% } \begin{filecontents}{\jobname.bib} @Book{p1,   author =       "A. U. Thor and John Doe",   title =        "A Scientific Article 1",   year =         "1975"   } @Book{p2,   author =       "John Doe",   title =        "A Scientific Article 2",   year =         "1985"   } @Book{p3,   author =       "Joe Bar",   title =        "A Scientific Article 3",   year =         "1995"   } @Book{p4,   author =       "Jane Baz",   title =        "A Scientific Article 4",   year =         "2005"   } \end{filecontents} \addbibresource{\jobname.bib} \begin{document} % Requirement 1: should make citations of Doe bold In \parencite{p4, p1, p2, p3}, ``TD75'' and ``Doe85'' should appear in bold (the semicolon should remain plain).  % Requirement 2: separating bibliographies. IT WORKS. \section{Co-authored Publications} \nocite{*} \printbibliography[keyword=doe,heading=none]  \section{Other Publications} \nocite{*} \printbibliography[notkeyword=doe,heading=none]  \end{document}


I am trying to figure out what to take into consideration before porting my whole application to MVC 3. I heard it built better for the web. I'd like to point out that my current website is based heavily on the Membership API, Roles etc.. Built-In with the .NET framework.  Will everything work?

I want to migrate an existing ASP.NET application to an ASP.NET MVC pattern format. What procedure should I follow? Any step-by-step instructions would be very helpful.


I need to find moments of vibrating string and I think that transfer function could be useful for this, but I don't know transfer function of vibrating string. Can someone give me some idea how to find it?

I have to calculate first 10 moments for vibrating string with damping, but I don't know how to do it. I read about moments and in definition they mention linear system $$x'=Ax+Bu, \qquad y=Cx$$ with  $$W(s)=C(sI-A)^{-1}B.$$ Then kth moment of a system above is $$C(sI-A)^{-(k+1)}B.$$ But for a vibrating string I know only wave equation $$Mx''+Cx'+Kx=b(t).$$ How to transform it to linear system?


Let $I = [0,1]$. Let $A = \bigl\{(1/n)\times 0 : n\in \mathbb Z_{+}\bigr\}$ be a subset of $I \times I$ with the lexicographic orer. Could you please give some idea to find the closure of $A$? Thanks

I need to find the closure of these sets on the ordered square: $$A = \{(1/n)\times 0 | n\in \mathbb{Z}_+\}$$ $$B = \{(1-1/n)\times \frac{1}{2}| n\in \mathbb{Z}_+\}$$ $$C = \{x\times 0 | 0<x<1\}$$ $$D = \{x\times \frac{1}{2}| 0<x<1\}$$ $$E = \{\frac{1}{2}\times y | 0<y<1\}$$ I know that the closure is just the set itself united with its limit points. For $A$, the set of limit points, I imagine, are $\{<1,0>\}$, that is, the $x$ coordinate is $1$ and the $y$ is $0$. But  is says the reverse. What am I getting wrong? Following the same reasoning, $B' = \{<1,\frac{1}{2}>\}$ $C' = \{<0,0>,<0,1>\}$ What am I doing wrong?


I remember seeing someone using a function that allowed you to create character vectors where the items were each one word strings as follows (I don't know what the function is called so I'm calling it c_special here):  a.random.vector <- c_special(hat, cat, bat)   rather than having to do this:  a.random.vector <- c("hat", "cat", "bat")   It'd be quite useful for me right now as I'm having to manually write out a lot of variable names (~1000) as part of a testing procedure and adding in the quotation marks is not very fun. Does anyone know what the function and package that has this in is or did I dream this up?  Note: I'm sure that this function is highly inefficient but I'm only using it for calling variable names so I'll happily trade that for less typing.   Edit: if I can't track this down I'll probably just use a text macro

Anyone know if R has quote-like operators like Perl's qw() for generating character vectors?


I have this code :   if (is_dir($dir)) {             if ($dh = opendir($dir)) {                 while (($file = readdir($dh)) !== false) {                     print_r(" ".$file. " ");                     $data = array(                         'emplacement' => 'uploads/slidesFiles/'.$file                     );                     $jpgId = $CI->dataaccess::InsertJpg($data);                     $data = array(                         'idSlideZip' => $zipId,                         'idSlideJpg' =>$jpgId                     );                     $CI->dataaccess::InsertJpgToSlide($data);                 }                 closedir($dh);             }         }   My folder :     But when I am using the read dir function to loop into my folder, I dont have the expected order wich is the next :     I tried to reorder with the sort function but that is not the result expected.    Any idea ?

I am reading through a directory with some pictures and such using a pretty simple implementation of readdir() like the following:  if ($handle = opendir($path)) {     while (false !== ($szFilename = readdir($handle))) {     if ($szFilename[0] !== '.') {         if (is_file($path.$szFilename)) {                 // do stuff             }         }      }  }   The problem that I am having is that the files are not being read in alphabetical order as the docs for readdir() state:     Returns the filename of the next file   from the directory. The filenames are   returned in the order in which they   are stored by the filesystem.   Another weird thing is that, on the local testing server, the same code works great.  This is running on a server using the LAMP stack in both cases.  I know that I can build an array and just sort it, but I was wondering if I was missing something in what I was doing.


When in casual conversation, being full accurate or detailed on what you mean isn't always necessary. For example, if I were to tell someone I want to buy a certain "waterproof" speaker and they correct me by saying it is water resistant, although it wasn't necessary. In the context of that conversation, they understand what I mean and it isn't needed to make clarification.

Is there a higher register word that means to criticize something highly specific and inconsequential? Any synonym I can think of seems a little too vernacular, e.g. "to split hairs", "to nitpick". What's a more professional/academic way of saying this? I'd prefer a single word if one exists.


For any three sets $A,B,C$ I have to prove $A\times(B-C)=(A\times B)-(A\times C)$. My book shows the following proof-  Let,arbitrary $(a,b)\in A\times(B-C)$ $\implies a\in A$ and $\color{blue}{b\in(B-C)}$ $\implies a\in A$ and $(b\in B$ and $b\not\in C)$ $\implies (a\in A$ and $\color{red}{b\in B})$ and $(a\in A$ and $b\not\in C)$ $\implies(a,b)\in(A\times B)$ and $(a,b)\notin(A\times C)$ $\implies(a,b)\in(A\times B)-(A\times C)$.  Now my question is in the part marked red we assume $b\in(B-C)$ which means $b\in B$ and $b\notin C$.But in the red part we say $b\in B$ which means we include the whole set $B$ without excluding the intersection with $C$ part. Now does these two things not contradict each other?I have a doubt whether this proof is correct. Edit-No reason why my post as closed as duplicate.I didn't want the proof.I specifically had difficulty with a particular logic.So no point redirecting my question to another proof without explaining my difficulty specifically.I already have that proof in my book.

If $A,B,$ and $C$ are sets, then $A\times(B-C)$ = $(A \times B)$ $-$ $(A \times C)$.  Proof. Observe the following sequence of equalities.  $$\begin{align} A\times(B-C) &= \{(x,y)\} : (x \in A) \wedge (y \in (B-C))\} \, (\text{Definition of Cartesian Product}) \\ &=\{(x,y) : (x \in A) \wedge \big((y \in B) \wedge (y\notin C)\big)\} \,  (\text{Definition of } -) \\  &=\{(x,y) : (x \in A) \wedge (x \in A) \wedge \big((y \in B) \wedge (y\notin C)\big)\} \, (P=P \wedge P) \\ &=\{(x,y) : \big((x \in A) \wedge (y \in B)\big) \wedge \big((x \in A) \wedge (y\notin C)\big)\} \, (\text{Rearrange}) \\ &=\{(x,y) : \big((x \in A) \wedge (y \in B)\big) \wedge \big((x \in A) \wedge (y\notin C)\big)\} \, (\text{Definition of }\cap) \\ \end{align}$$  I'm stuck on the last part -- $(x \in A) \wedge (y\notin C)$ translates to $(A-C)$ but I need it to be $(A \times C)$. I can't quite figure out how to reach that.


In Harry Potter, Harry had no idea about the wizarding world until Hagrid came to get him. Since he was sent to the Dursleys as a baby, how do the other witches and wizards know what he looks like when he shows up at Hogwarts, and the Leaky Cauldron? It couldn't have been his scar, because in the Leaky Cauldron, everything was dark, and Harry had his bangs over the scar. In fact, Harry always had to lift up his bangs to let people see it.  "He pointed at Harry's forehead. Harry pulled back his bangs to show the lightning scar." (Harry Potter and the Philosopher's Stone -- chapter 6, page 99)  So how did the wizarding world know what Harry looked like before he knew about wizards?

After the death of Lord Voldemort, Harry was taken to the Dursleys and became known as "The Boy Who Lived".  We know that the Wizarding World found out  that Voldemort was dead and undoubtedly it was Dumbledore that advised people that Harry had somehow survived the attack and caused Voldemort's death. According to Snape (in HP:HBP) there were even persistent rumours that Harry was a powerful Dark Wizard in the making until he turned up at Hogwarts a decade later.  My question is : Where did the Wizarding World think Harry was for the intervening 10 years?


I encountered integer expression expected error in the following code:      #! /bin/bash     # test integer: evaluate the value of integer     int=-5     if [ -z "$int" ]; then         echo 'int is empty.' >&2     fi      if [ "$int" -eq 0 ]; then         echo "int is zero"     else         if [ '$int' -lt 0 ]; then             echo "int is negative."         else             echo 'int is positive.'         fi         if [ $((int % 2)) -eq 0 ]; then             echo 'int is even.'         else             echo 'int is odd.'         fi     fi   Run it and get error report      $ bash test_integer.sh     test_integer.sh: line 14: [: $int: integer expression expected     int is positive.     int is odd.   I checked multiple times but fail to locate the bug, which seem to line-to-line comform to the book  What's the problem with my code?

I have an application which takes as an input attributes in double quotes embedded in single quotes. Take for example this right command:  command -p 'cluster="cl1"'   In order to automate it, I created a bash file using $CLUSTER as a variable. How should be my command? In other words, what should I put instead of cl1?  Please note that, If I modified the above command, it won't be accepted. For instance: command -p "cluster=cl1" is not accepted


I am looking for some direction to see if there is an equivalent metric to a z score that could be used to quickly identify individual values in a non-normal distribution that are not likely to occur (for example, + or - 3 standard deviations).    This is really basic with a normal distribution but the data I'm dealing with is highly skewed with a very large amount of values at 0.  Specifically, my data contains the geographical distance between two events that occur.  Many times, the events take place in the same location, leaving a huge volume of values of 0, with the rest of the distances decreasing rapidly in frequency.  I attempted to do a log transformation but this still does not work well with the values of 0.    Again, is there something like a z score that can be used on non normal data?  If not, what is the best way to find the values that are not likely to occur?

Under a classical definition of an outlier as a data point outide the 1.5* IQR from the upper or lower quartile, there is an assumption of a non-skewed distribution. For skewed distributions (Exponential, Poisson, Geometric, etc) is the best way to detect an outlier by analyzing a transform of the original function?  For example, distributions loosely governed by an exponential distribution, could be transformed with a log function - at which point is it acceptable to look for outliers based on the same IQR definition?


I was recently reminded of the Taylor series $\frac1{\sqrt{1-4x}}=\sum_{n=0}^\infty{2n\choose n}x^n$ and got wondering whether this can be proven combinatorially.  Of course the standard proof would be to look at the derivatives of $f(x)=\frac1{\sqrt{1-4x}}=(1-4x)^{-1/2}$. \begin{align*} f'(x)&=2\cdot(1-4x)^{-3/2} \\f''(x)&=4\cdot3\cdot(1-4x)^{-5/2} \\f'''(x)&=8\cdot3\cdot5\cdot(1-4x)^{-7/2} \\f^{(n)}(x)&=2^n\cdot1\cdot3\cdot5\cdot...\cdot(2n-1)\cdot(1-4x)^{-(2n+1)/2} \\&=2^n\frac{(2n)!}{n!2^n}(1-4x)^{-(2n+1)/2} \\&=\frac{(2n)!}{n!}(1-4x)^{-(2n+1)/2} \end{align*} This gives $$f(x)=\sum_{n=0}^\infty\frac{f^{(n)}(0)}{n!}x^n=\sum_{n=0}^\infty{2n\choose n}x^n.$$  This is all great, but we can also look at it a different way. Note $(f(x))^2=\frac1{1-4x}=\sum_{n=0}^\infty4^nx^n$. But now note what this is saying about the Taylor series. $$\left(\sum_{n=0}^\infty{2n\choose n}x^n\right)^2=\sum_{n=0}^\infty\left(\sum_{k=0}^n{2k\choose k}{2(n-k)\choose n-k}\right)x^n=\sum_{n=0}^\infty4^nx^n$$ This gives us the identity $$\sum_{k=0}^n{2k\choose k}{2(n-k)\choose n-k}=4^n$$ which I find very curious.  My question is if there is a combinatorial proof of the final identity. This would then also give a combinatorial proof of the original Taylor series.  The way I look at the term ${2n\choose n}$ is as the amount of paths from $(0,0)$ to $(n,n)$ by only going right by one or up by one at every step. Then a product such as ${2k\choose k}{2(n-k)\choose n-k}$ would be the amount of such paths that cross the point $(k,k)$. This is because we can simply join the paths to $(k,k)$ and $(n-k,n-k)$. But this means that every path from $(0,0)$ to $(n,n)$ gets counted in the product ${2k\choose k}{2(n-k)\choose n-k}$ if and only if it crosses $(k,k)$.  In conclusion, the sum $\sum_{k=0}^n{2k\choose k}{2(n-k)\choose n-k}$ can be combinatorially seen as the sum over all paths from $(0,0)$ to $(n,n)$ of the amount of times it touches the line $y=x$. The goal is then to show that this exactly equals $4^n$.

It's not difficult to show that  $$(1-z^2)^{-1/2}=\sum_{n=0}^\infty \binom{2n}{n}2^{-2n}z^{2n}$$  On the other hand, we have $(1-z^2)^{-1}=\sum z^{2n}$.  Squaring the first power series and comparing terms gives us  $$\sum_{k=0}^n \binom{2k}{k}\binom{2(n-k)}{n-k}2^{-2n}=1$$  that is,  $$\sum_{k=0}^n \binom{2k}{k}\binom{2(n-k)}{n-k}=2^{2n}$$  My question: is there a more direct, combinatorial proof of this identity?  I've been racking my brains trying to come up with one but I'm not having much success.


Take the sentence:     Who is the right person to turn to?   I'm not sure whether who or whom should be used in this position.

I can never figure out whether I should use who and whom. Most people use who for both colloquially, but some people say this is not correct.  What’s the rule for using who and whom correctly?


Can you please tell the meaning of """iris_dataset.data[:,:2]""" in jupyter notebook python

I need a good explanation (references are a plus) on Python's slice notation.   To me, this notation needs a bit of picking up.   It looks extremely powerful, but I haven't quite got my head around it.


I have files with extension .bok from Shamela file. They contain Arabic text.  What can I do to read .bok files in Ubuntu 16.04 LTS? Is there an application to open them?  === UPDATED Tue 18 Oct 2016 ===  I have followed this  but it doesn't work in Ubuntu 16.04.   .bok files can be opened by Maktaba El-Kirtasse & Maktabah Al-Miftah but they are not displayed correctly.   They look like this:  أچأ‘أ أ‡أ،أƒأ،أ أƒ - أ‡أ،أچأ³أ‘أ؛أ‌أµ أ‡أ،أƒأ¦أ¸أ³أ،أµ أ£أ¶أ¤أ³ أ‡أ،أچأµأ‘أµأ¦أ‌أ¶ أ‡أ،أ¥أ¶أŒأ³أ‡أ†أ¶أأ¸أ³أ‰أ¶ (أ£أ„أ¤أ‹أ‰) أ¦أ³أٹأµأ‘أ؛أ“أ³أ£أµ أڑأ³أأ؛أ¤أ‡أ° أ•أ³أ›أ¶أأ‘أ³أ‰أ° (أپ) أ¦أ³أأ³أٹأ³أڑأ³أأ¸أ³أ¤أµ أ¤أ³أ¦أ؛أڑأ³أ‡أ¤أ    is an example .bok file

When I use Windows I read my arabic book (*.mdb & *.bok) by maktaba shamela.  And now  I use ubuntu 12.04 and I need to read my *.bok & .mdb file. I tried to install makatba shamela with wine but the arabic font was not showed. I tried to install thwab (not Thawab) to read my arabic book (.bok), but I could not install it. And now I wanna install Maktabah Al-Miftah. But to read *.bok need to import file (.mfth) from Shamela file (.bok) by using AccessDump.py  and it depends on gambas3-gb-db-sqlite3. What can I do?


How do l recover hidden files on a pen drive,infected by a virus, as well as cleaning up the virus using ubuntu operating system

I scanned the home directory using ClamAV which found 13 threats. The list was also displayed, but when I tried to delete or quarantine files, it did not proceed. Any ideas?


Harry has part of Voldemort living within himself. When Voldemort's spell rebounded when he first tried to kill Harry, part of Voldemort's soul latched on to Harry, which basically makes him and Voldemort the same person (that's why Voldemort didn't kill Harry in the forest, he essentially killed part of himself).    We know that the wands choose the wizard. Draco defeated Dumbledore and became owner of the wand, then Harry "defeated" Draco and won the allegiance of the Elder Wand. However, he did this when there was still a part of Voldemort's soul living within him.    So, when Voldemort killed Harry in the forest and the two had their final battle, why was the Elder Wand not conflicted on who its master was?   Did it not recognize the part of Voldemort that lived in Harry?    Why would the wand not answer to the both of them since Harry was still part Voldemort when he "defeated" Draco?

There's a lot of emphasis on Harry becoming the master of the Elder Wand after he defeats Draco. But what constitutes a “defeat”?  It seems that Harry wins a wrestling match with Draco, so now he’s the master of the Elder Wand.  But lots of other stuff happens to Harry: Nagini almost kills him, and he escapes just in time, but his wand breaks. The Snatchers chase him through the forest. He and his friends practically surrender (and Hermione even tries to disguise Harry). Voldemort almost kills Harry in the Forbidden Forest (or actually does, depending on how you look at it).  Why are none of these considered to be “defeats”?


A few days ago I was in a middle of copying or cutting folders and data to my external hard drive and it was corrupted.  I have tried to locate the lost information on Test Disk but I have now lost it because it has already been over written. The file is 0. 0. copy and completed.  I have now only have the image.dd file. How can I restore this to it's normal folders and files? Many thanks.

A few days ago I was in a middle of copying or cutting folders and data to my external hard drive and it was corrupted.  I have tried to locate the lost information on Test Disk but I have now lost it because it has already been over written. The file is 0. 0. copy and completed.  I have now only have the image.dd file. How can I restore this to it's normal folders and files without losing the names? Many thanks.


I heard that in a fire , the "heat" excites the molecule .So they start vibrating and give of light due to atomic transition . But I didn't really found this process in detail. So I have some important question about them.  What is exactly atomic transition ? Why does , for example a candle flame , gives of red and orange light due to this atomic transition ? Can we calculate this wavelength for a combustion chemical reaction ? Why does the molecules get excited and vibrate from the chemical reaction anyway?

I have learnt that depending on the various gases those are involved in the reaction that produces fire, different colors (yellow, red or blue) of flames become visible.  I have a question .. what are the possible colors that fire can possess? and do they (how, if yes) relate to the intensity? like I know blue is more intense than red, etc..


Background  Creating a custom multi-column layout having columns that differ in width.  Problem  This question's problem is mentioned but not addressed in a previous :     Setting page=yes causes an unfortunate side-effect: the book is interwoven with blank pages in between chapters. These can be eliminated using Ghostscript to post-process...   In other words, without the page=yes option, ConTeXt is unable to format the text as desired. With the page=yes option, ConTeXt formats as expected but exports an undesired blank page between major sections.  Code  Minimum working example that illustrates the problem:  \definepapersize[BookPaperSize][width=24in, height=12in,] \setuppapersize[BookPaperSize]  \definelayout[BookTextLayout][   topspace=.5in,   backspace=.5in,   header=\zeropoint,   footer=\zeropoint,   grid=yes, ] \setuplayout[BookTextLayout]  \definecolumnset[BookColumns][n=4,distance=.25in] \setupcolumnset[BookColumns:1][width=11.75in] \setupcolumnset[BookColumns:2][width=3.46in] \setupcolumnset[BookColumns:3][width=3.46in] \setupcolumnset[BookColumns:4][width=3.46in]  \setuphead[section][   page=yes,   beforesection={\startcolumnset[BookColumns]},   aftersection={\stopcolumnset}, ]  \setuphead[subsection][   after={\column}, ]  \setuphead[subsubsection][   after={\blank[small]}, ]  \starttext \startsection[title={Section Title}] \startsubsection[title={Subtitle}] \dorecurse{2}{\input knuth}  \dorecurse{2}{%   \startsubsubsection[title={Subsubtitle}]     \dorecurse{1}{\input ward}     \dorecurse{2}{\input lorem}     \dorecurse{1}{\input bryson}   \stopsubsubsection }  \stopsubsection \stopsection \stoptext   Actual Output  The page before each section is blank:    Output Without Page  When the page=yes option is removed, the output has issues:    The \column command no longer appears to respect the column widths and the text bunches up at the bottom of the first column.  Expected Output  The desired output would not have a blank page between major sections:    Work Around  The  contains multiple pages. Using  works to delete every other page (e.g., using gs -sPageList=even), which produces the desired result:     Theory of Inflation by  Stars by    However, the extra blank page causes knock-on problems: extra image processing steps, PDF pages need reordering, and increased compile time due to needing two passes.  Question  What needs to change so that the blank pages are eradicated from the document?  Ideas  Adding page=yes to the \definecolumnset and removing page=yes from the setuphead resolves the issue of blank pages; however, the first page columnset is scrunched to the left. I've attempted to address the issue using:  \definecounter[BookPageNumber][   way=bychapter,   prefix=no, ]  \definecolumnset[BookColumns][n=4,distance=.25in,page={\doifelse{\rawcountervalue[BookPageNumber]}{1}{}{yes}}] \setupcolumnset[BookColumns:1][width=11.75in] \setupcolumnset[BookColumns:2][width=3.46in] \setupcolumnset[BookColumns:3][width=3.46in] \setupcolumnset[BookColumns:4][width=3.46in]  \setuphead[section][   before={%     \doif{\rawcountervalue[BookPageNumber]}{1}{\page}     \incrementcounter[BookPageNumber]   },   beforesection={\startcolumnset[BookColumns]},   aftersection={\stopcolumnset}, ]   However, this does not produce the desired output.

Background  Looking to achieve a fairly complex layout from a Markdown source document. The layout resembles:    Code  \usemodule[newcolumnsets,visual]  \setuphead[chapter][   header=empty,   footer=empty,   number=no,   page=yes,   before={\blank[none]},   after={\blank[none]}, ]  \setuphead[section][   number=no,   before={\blank[small]},   after={\blank[small]}, ]  \definepapersize[BookPageSize][   width=601mm,   height=305mm, ]  \definelayout[BookPageLayout][   backspace=10mm,   cutspace=10mm,   width=585mm,   height=147mm,   topspace=10mm,   header=0mm,   footer=0mm, ]  \setuppapersize[BookPageSize] \setuplayout[BookPageLayout]  % No page number at the top. \setupheadertexts[] \setupfootertexts[]  \setupindenting[yes, small]  \definecolumnset[BookColumns][n=4,distance=0.0333\makeupwidth]  % left page (even page numbers) \setupcolumnset[BookColumns:1][width=.5\makeupwidth] \setupcolumnset[BookColumns:2][width=.125\makeupwidth] \setupcolumnset[BookColumns:3][width=.125\makeupwidth] \setupcolumnset[BookColumns:4][width=.125\makeupwidth] % right page (odd page numbers) \setupcolumnset[BookColumns:5][width=.5\makeupwidth] \setupcolumnset[BookColumns:6][width=.125\makeupwidth] \setupcolumnset[BookColumns:7][width=.125\makeupwidth] \setupcolumnset[BookColumns:8][width=.125\makeupwidth]  \definecolumnsetspan[BookIllustration][n=4]  \starttext   \startbodymatter     \startcolumnset[BookColumns]       \chapter[title={Title},reference={title}]       \subsection[title={Subsubtitle},reference={subsubtitle}]       \column        \input ward        \section[title={Subtitle},reference={subtitle}]        \input knuth       \input tufte        \section[title={Subtitle},reference={subtitle}]        \startformula  \frac{\dot{R}^2}{R^2} = \frac{8\pi G}{3}\rho - \frac{kc^2}{R^2}  \stopformula        \startformula  \frac{\ddot{R}}{R} = -\frac{4\pi G}{3} \left(\rho + \frac{3p}{c^2}\right)  \stopformula        \input tufte        \placefigure[bots]{}{\externalfigure[https://i.imgur.com/nSBuPAA.jpg][width=\paperwidth]}     \stopcolumnset   \stopbodymatter \stoptext   This code produces the following, which is pretty close:    Problems  There are a few issues:   The fourth column contains a lot of whitespace at the top. The second column contains garbled text (could be a page height issue). The image is displayed on the second page.   Questions  How can I resolve these issues without changing the body matter, but affording some tweaks to \placefigure such that:   the last column is aligned to the top; the garbled text does not appear; and the image is on the same page as the text?   Version  Using ConTeXt 2019.04.04 13:31.


Today I have entered random float number and multipled by hundred firstly using normal code and then in console as was giving me wrong number, console is returning me the same.  The given float number is: 1050.6  Therefore: 1050.6 * 100 should be 105060, but javascript is returning me 105059.99999999999  Anyone knows why?

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


In Apostol's "Introduction to Analytic Number Theory", there is a definition for the Riemann Zeta Function for $0<s<1$.    Is there a justification for this formula?

I am currently reading the book Introduction to Algebraic Number Theory by Apostol. To introduce some important asymptotic formulas, Apostol gives a rough definition of the Riemann zeta function (for $s\in\mathbb{R}^+$),     $$\begin{equation}\zeta(s)=\begin{cases} \sum_{n}n^{-s}, &s>1\\ \lim_{x\to\infty}\left(\sum_{n\leqslant x} \frac{1}{n^s}-\frac{x^{1-s}}{1-s}\right), &0<s<1 \end{cases}\end{equation}$$   The second part really confused me. How could we approach this limit? If we see $\zeta$ as an analytic continuation of $\sum_{n}\frac{1}{n^s}$, it should be written as  $$\zeta(s)=\frac{1}{\Gamma(s)}\int_0^\infty \frac{x^{s-1}}{e^x-1} dx$$ This formula can be easily derived from $\Gamma(s)=\int_0^\infty x^{s-1}e^{-x}dx$ by substituting $x=nu$ (which was exactly what Riemann did in his paper). However, I don't see the connection between this formula and the limit form for $0<s<1$. I am really new to this function so maybe this is a dumb question. But please point it out why we can write $\zeta(s)$ in the limit form for real $0<s<1$.    Also, historically, is the limit form derived from the formal or the converse?    Thanks in advance, any help will be appreciated.


Have installed Ubuntu 11.10 on USB using Live CD. Followed the steps as provided in below link    After installation is complete in Refit menu, when i click on Linux icon I receive "Missing Operating System" message. I followed the steps provided in the below link from this forum, but am still receiving the same message.    Any assistance is highly appreciated.

If you select "USB" and "Mac" on , it gives a series of command line instructions to make a USB key which the MacBook will boot into Ubuntu from.  I've followed them to the letter two or three times on different USB keys, and it doesn't work. There's a very great deal of technical discussion about EFI etc. but this set of instructions seems to suggest it should just work, but it doesn't.  Help? I'm increasingly unhappy with the more locked-down approach Apple is taking, and I'd quite like to start using Linux with a view to transitioning over to using it as my main operating system, but booting from the CD takes forever, runs slowly and I'm really hoping to get it moving off USB.  Can anybody help me?


I'm an undergrad trying to read Algebraic Geometry Part I by Wedhorn and Gortz. They mention that if $X$ is a topological space and $U$ is open, then there are mutually inverses maps: $ \varphi:\{Y\subseteq U \text{ closed irreducible }\} \rightarrow \{ Z\subseteq X \text{ closed irreducible},  Z\cap U\neq \varnothing\}$ $Y\mapsto \overline{Y}^X$ (denoting closure on X) $\psi: \{ Z\subseteq X \text{ closed irreducible},  Z\cap U\neq \varnothing\}\rightarrow \{Y\subseteq U \text{ closed irreducible }\} $ $Z\mapsto Z\cap U$ I understand why both maps are well defined but I don't see why given $Z$ irreducible and closed in $X$ with $Z\cap U\neq \varnothing$, $\overline{Z\cap U}^X=Z$, i.e., why $(\varphi\circ \psi)(Z)=Z$. I would appreacite any help since I don't know much topology. Also is this part of a bigger picture?

Let $(X,\tau)$ be a topological space, $U \subseteq X$ a non-empty open subset of $X$ and let $W$ be an irreducible non-empty closed subset of $X$. Assuming $W \cap U \neq \emptyset$ why is this intersection irreducible in $U$ and its closure (taken in $X$) equal $W$?  Clearly $W \cap U$ is dense in $W$ because it is an open subset of $W$ and $W$ is irreducible so its closure, taken in $W$ is $W$ itself. I don't see why its closure taken in $X$ is equal $W$. Why is this? Also, why is it irreducible in $U$?  EDIT: OK $W=cl_{X}(W)=cl_{X}(W \cap U)$ I think. Why is it irreducible in $U$ though?


I have a table which I want to fill with multiple colors, each cell possibly different from another. Which means, I can't make use of e.g. \columncolor (as in  post).  While the table without any colors looks just fine (code at the end):   ...the table with one or more filled cells overwrites the table grid.   So my question is: Is there a way to, for example, redraw the grid after filling the cells or something?    EDIT: added complete code instead of code fragments Relevant LaTeX code:  \documentclass[11pt]{article}  \usepackage{color} \usepackage{colortbl} \usepackage{multirow}  \newlength{\Oldarrayrulewidth} % Cline redefining to add line thickness \newcommand{\Cline}[2]{%   \noalign{\global\setlength{\Oldarrayrulewidth}{\arrayrulewidth}}%   \noalign{\global\setlength{\arrayrulewidth}{#1}}\cline{#2}%   \noalign{\global\setlength{\arrayrulewidth}{\Oldarrayrulewidth}} }   \definecolor{intnull}{RGB}{213,229,255} \definecolor{inteins}{RGB}{128,179,255} \definecolor{intzwei}{RGB}{42,127,255} \definecolor{intdrei}{RGB}{0,85,212} \definecolor{intvier}{RGB}{0,51,128} \definecolor{intfunf}{RGB}{0,34,85}   \begin{document} % Empty table \begin{tabular}{*{5}{!{\vrule width 1.5pt}p{1.5cm}}!{\vrule width 1.5pt}l} \centering 4 & \centering 10 & \centering 24 & \centering 48 & \centering 72 &\\ \Cline{1.5pt}{0-4}  &  &  &  &  & Optic tectum \\ \Cline{1.5pt}{3-5}  &  &  &  &  & Retina \\ \Cline{1.5pt}{3-5}  &  &  &  &  & Myomeres \\ \Cline{1.5pt}{0-4}  &  &  &  &  & Arches \\ \Cline{1.5pt}{0-4} \end{tabular} \\  \hspace*{1cm}  % Partically filled table \begin{tabular}{*{5}{!{\vrule width 1.5pt}p{1.5cm}}!{\vrule width 1.5pt}l} \centering 4 & \centering 10 & \centering 24 & \centering 48 & \centering 72 &\\ \Cline{1.5pt}{0-4}  & \cellcolor{intnull} &  & \cellcolor{intvier} &  & Optic tectum \\ \Cline{1.5pt}{3-5}  & \cellcolor{intnull} &  & \cellcolor{intnull} &  & Retina \\ \Cline{1.5pt}{3-5}  & \cellcolor{intnull} &  & \cellcolor{intdrei} &  & Myomeres \\ \Cline{1.5pt}{0-4}  & \cellcolor{inteins} &  & \cellcolor{inteins} &  & Arches \\ \Cline{1.5pt}{0-4} \end{tabular}  \end{document}

So I need to make a colored table with multirows, together with the use of partial horizontal lines. I used \cline which does not work: the \cellcolor-command overwrites the line.  told me to change it to \hhline which will not be overwritten by \cellcolor. Instead, \hhline overwrites the color.  To make it more clear:  Without color:  \documentclass{article}  \usepackage{colortbl} \usepackage{multirow}  \begin{document}    \begin{tabular}{|c|c|}     \hline     \bfseries ColumnOne & \bfseries ColumnTwo\\ \hline     First data & 932\\ \hline      & 239\\ \cline{2-2}  % or \hhline{|~|-|}      & 137\\ \cline{2-2}  % or \hhline{|~|-|}     \multirow{-3}{*}{More data} & 319\\ \hline     Last data & 132\\ \hline   \end{tabular}  \end{document}     With color: Using \cline  \documentclass{article}  \usepackage{colortbl} \usepackage{multirow}  \begin{document}    \begin{tabular}{|>{\columncolor{red}}c|>{\columncolor{blue}}c|}     \hline     \bfseries ColumnOne & \bfseries ColumnTwo\\ \hline     First data & 932\\ \hline      & 239\\ \cline{2-2}      & 137\\ \cline{2-2}     \multirow{-3}{*}{More data} & 319\\ \hline     Last data & 132\\ \hline   \end{tabular}  \end{document}    Makes the lines in the right column disappear.  Using \hhline  \documentclass{article}  \usepackage{colortbl} \usepackage{multirow} \usepackage{hhline}  \begin{document}    \begin{tabular}{|>{\columncolor{red}}c|>{\columncolor{blue}}c|}     \hline     \bfseries ColumnOne & \bfseries ColumnTwo\\ \hline     First data & 932\\ \hline      & 239\\ \hhline{|~|-|}      & 137\\ \hhline{|~|-|}     \multirow{-3}{*}{More data} & 319\\ \hline     Last data & 132\\ \hline   \end{tabular}  \end{document}    Creates white lines on the left column.  Is there any possible way on how to resolve this?


So I happened to capture this really cool picture of a desktop screen taken through a mobile phone camera. I hope you can see those stripe-like patterns which have appeared in the photograph, but weren't there on the desktop screen. They have a striking resemblance to a hyperbola. They also appear to move and take different shapes as I move the mobile phone along the screen. I am really curious to know what is going on here..is this some sort of optical illusion? Why can't we see these weird patterns through out naked eyes?

I am not entirely sure this is an appropriate question for PSE, however since many of you have such diverse backgrounds, I'll give it a shot.  I have noticed that when one takes a picture of a computer, TV screen with a phone, you can "see" what looks like a saddle phase portrait.     Why does this happen? Does it have any relevance to differential equations or other areas of math?


For every natural number $n$, prove that $n^n > 1 \cdot 3 \cdot 5 \cdots (2n-1)$.  I tried solving this by assuming that the above equation is true for $n$ and tried proving it is also true for $n+1$, but did not reach anywhere.

The main question is :  Prove that $n^n>1\times3\times5\times7\times\dots\times(2n-1)$  My approach :  We can write the R.H.S as,  $$\frac{(2n-1)!}{2\times4\times6\times\dots\times2(n-1)}$$ We can write $(2n-1)!$ as $(2n-3)!(2n-1)2(n-1)$  Thus, in this manner we can cancel out even terms till $n$ appears. I'm having trouble doing this. What I intend to do is say that any positive number's factorial is less than the number raised to itself. I welcome any alternate method. Please help.  P.S. I am still in high school and do not understand binomial theorem and induction.


I was thinking if there was anyway so that we can pause the installation or downloading of any software from the terminal.Means if the terminal processes can be paused and resumed?? I asked because suppose I am downloading something from download manager and also a file from the terminal and I am not getting enough speed from the download manager due to this.So is there any way that the terminal process could be paused?? This question is different because i want to know what will happen if I pause a file which I was downloading fro the terminal and file download takes place through internet.I am not asking if I suspend an ongoing process like the running of a program which is internal to the computer.

Is there a keyboard key combination that I can use to pause a program running in the terminal? In case it matters, I don't intend to run anything else inside that terminal while the program is paused. I just want to pause the program execution, and resume it later. How can I do this?


Today, i stopped at 4 different pokestops multiple times but couldnt get any pokeballs.  My bag is not full but it just spins but not give anything.  I am using pokemon trainer club account.  We do use the same account on 2 iphones (and both have the same problem).

I can't do anything now. Can't catch Pokemon, can't get items. Does anyone have the same problem?


If $\vec A$ and $\vec B$ are two vectors such that $\vec A=<A_x,A_y,A_z>$ and $\vec B=<B_x,B_y,B_z>$ then $$\nabla({\vec A}.{\vec B})=A \times (\nabla \times B)+B \times (\nabla \times A)+(A.\nabla)B+(B.\nabla)A$$ In this relation what does this $(A.\nabla)B$ imply? How does this work on vector? Isn't gradient meant to be operated on scalar function?

If we consider the vector $\left ( A \cdot \nabla \right) \: B$, we have in Cartesian coordinates  $$\left ( A \cdot \nabla \right) \: B = \left ( A \cdot \nabla B_x \right ) e_x + \left ( A \cdot \nabla B_y \right ) e_y + \left ( A \cdot \nabla B_z \right ) e_z,$$ which gives in full writing:  $$\left ( A \cdot \nabla \right) \: B = \left (A_x \frac{\partial \: B_x}{\partial \: x} + A_y \frac{\partial \: B_x}{\partial \: y} + A_z \frac{\partial \: B_x}{\partial \: z} \right )e_x + \left (A_x \frac{\partial \: B_y}{\partial \: x} + A_y \frac{\partial \: B_y}{\partial \: y} + A_z \frac{\partial \: B_y}{\partial \: z} \right )e_y + \left (A_x \frac{\partial \: B_z}{\partial \: x} + A_y \frac{\partial \: B_z}{\partial \: y} + A_z \frac{\partial \: B_z}{\partial \: z} \right )e_z$$   Now, if $B=A$ and $A=\left (0, \: 0, \: A_z \right )$ (i.e. $A_x=A_y=0$), we have from the above definition, only the following term along the unit vector $e_z$:  $$\left ( A \cdot \nabla \right) \: A = A_z \frac{\partial \: A_z}{\partial \: z}$$  But this is equal to zero since $\frac{\partial A_z}{\partial \: z}=0$, despite $A_z \neq 0$.  So we get $$\left ( A \cdot \nabla \right) \: A =0$$  I would like to know the physical interpretation of this result. What is the significance of this vector being zero in terms of field lines?  Thanks a lot...


I am extremely interested in GR, but somehow feel that the books I read are not really enough. Frankly, I find many question on this site and elsewhere completely bewildering, which makes me think that I don't have a solid foundation, especially in classical mechanics and various mathematical techniques. Here's a list of books I have read:  MATHEMATICS(After pre calculus and basic calculus)  Mathematical methods for physicists(Still working my way through) By Arfken and Weber  Advanced calculus by David Widder  Ordinary differential equations by Coddington  Principles of mathematical analysis by Rudin  Vector Calculus  Tensor calculus by Barry Spain  RELATIVITY  Introduction to special relativity by Resnick  Gravity by Hartle  General relativity with applications to astrophysics by Straumann (newly acquired)  I have a few books on dynamics, nuclear physics, etc, but they are quite unnecessary. I am not much into QM, and have only read Griffith's. I also have, as a reference, PRINCIPLES OF PHYSICS by Resnick and Walker.  All my knowledge of classical mechanics and lagrangian formulism is from pdf versions of Feynman's lectures. Please suggest me some books that will fill the gap I have left out. Just to be clear, I want to read Mathematical theory of black holes by Chandrahekhar next, so I want to know where I need to improve.   NOTE: I am still in high school, and I don't have any professor to help me out, so the books should be suitable for self study. All the same, they should be properly rigorous.  EDIT: I am not very comfortable with the exercises suggested in most of the books (esp. Mathematical methods for physicists and both the GR books. Though I have no conceptual glitches, I really want to be able to solve the exercise problems, as doing so is both satisfactory and rewarding. Any suggestions on that( how to be more efficient)? Am I going too far too soon, and maybe need to stop down and consult a book which will perhaps give me a good foundation to solve the exercises, or a book with excellent exercises? If so, which one? 2: Of course, I have viewed the lectures by Susskind.

This question recently appeared :     Slashdot posts a fair number of physics stories. Many of us, myself included, don't have the background to understand them. So I'd like to ask the Slashdot math/physics community to construct a curriculum that gets me, an average college grad with two semesters of chemistry, one of calculus, and maybe 2-3 applied statistics courses, all the way to understanding the mathematics of general relativity. What would I need to learn, in what order, and what texts should I use? Before I get killed here, I know this isn't a weekend project, but it seems like it could be fun to do in my spare time for the next ... decade.   It seems like something that would be a good addition to this site: I think it's specific enough to be answerable but still generally useful. The textbook aspect is covered pretty well by , but beyond that: What college-level subjects in physics and math are prerequisites to studying general relativity in mathematical detail?


I understand how MCMC can be useful for approximating the shape of a density function if you're able to generate random samples from that density function. However, I don't understand how this is applied towards Bayesian inference because any specific selection of model parameters using MCMC would yield a number, not a distribution.  For example, if I have a binomial likelihood function and a beta prior, I might use Metropolis-Hastings to select a random starting parameter, $\theta=.3$. When that starting parameter and some data are input into my likelihood function and prior, I get a deterministic number as the output. No randomness involved.  Framing this issue another way: Why does the MH algorithm generate the posterior distribution from the count of visits to a parameter value rather than using the posterior values generated directly?

My understanding is that when using a Bayesian approach to estimate parameter values:   The posterior distribution is the combination of the prior distribution and the likelihood distribution. We simulate this by generating a sample from the posterior distribution (e.g., using a Metropolis-Hasting algorithm to generate values, and accept them if they are above a certain threshold of probability to belong to the posterior distribution). Once we have generated this sample, we use it to approximate the posterior distribution, and things like its mean.   But, I feel like I must be misunderstanding something. It sounds like we have a posterior distribution and then sample from it, and then use that sample as an approximation of the posterior distribution. But if we have the posterior distribution to begin with why do we need to sample from it to approximate it?