How to make a branch in SmartGit with beanstalk?

Question: I have SmartGit GUI tool for my beanstalk repos. I want to make a branch of one of my repos. For this i have created a branch using smartGit branch manager, but how i create this to beanstalk. and the other question is "What is track-branch" in SmartGit.
Thanks
Answer: If you are not currently on your created branch, use Branch|Switch to switch to your branch. Perform Remote|Push which will ask you whether to configure tracking, confirm this. After that your branch will be pushed to beanstalk. Finally you should see origin/branch in the branch manager (assuming that your remote beanstalk repository is the origin)
Answer: Beanstalk will automatically detect new branches pushed to it once it is established as a remote.
While switched to your new branch, push it to your Beanstalk remote using SmartGit.
You can verify the new branch being successfully pushed by browsing to that repository in Beanstalk and clicking the "Change tree" button:

In this view, any remotes and tags that have been pushed to your Beanstalk remote will be presented.


How to determine motherboard/case form factor

Question: I have an old (no more than 5 or 6 years) Compaq that I'm planning to re-purpose. The motherboard and CPU need to be replaced but I'm going to be able to re-use the hard drive    and optical drives. I'd also like to be able to re-use the case. I'd heard that some Compaq (as well as Dell, HP, etc...) build motherboards with non-standard form-factors that only they (the vender) use. How would I be able to determine if the case can take a standard form-factor or if it only takes a special Compaq form-factor? The case itself is a standard, mid-tower size.
Comment: @FrustratedWithFormsDesigner, I updated my answer to include a link.
Comment: What is the specific model of the Compaq?
Comment: measuring is really the only way; or eye balling the shape/size and placement of the holes... that is if you have the experience
Comment: @Logman: Do you know where I'd find a description of the exact position of the screw holes? I imagine that I could measure the screw positions relative to the motherboard edge or the case (or both) and that would determine if it's a standard or proprietary design.
Comment: @FrustratedWithFormsDesigner  if you can post an image of the mobo inside you case maybe we can help narrow it down. You can also take that picture and compare it to some online images http://upload.wikimedia.org/wikipedia/commons/1/11/VIA_Mini-ITX_Form_Factor_Comparison.jpg (from Josh's wiki link) but still measuring is the only way or taking a good picture and superimposing it over an existing form factor and seeing how the holes line up.
Answer: Hate to post a link to Wikipedia, but this page has all the maximum size dimensions of a remarkable number of motherboard sizes and form factors.  Probably a good place to start when measuring.
Answer: In all likelihood, if the system uses a proprietary form-factor, it probably won't be the actual physical dimensions (width, length) that are the problem but rather the placement of components on the backplane and of the standoff holes.
If the backplane is unusual, you can probably/hopefully just pop in a compatible bezel (figure 1), though the case may not be designed to support replacing the bezel (you may be able to just cut a hole).
If the standoff holes (figure 2) are in the wrong place, then you may have to find other means of securing the board to the case, or if you are lucky, perhaps secure it with just one or two screws.
FormFactors.org has a comprehensive list of form-factors for motherboards, power-supplies, and other components, with links to PDFs of the specifications for each that include dimensions and mounting-hole placements.
Figure 1: Variety of bezels:

Figure 2: Standoff holes:
Comment: Thanks! Are there actual numbers for how far from the edges a screw-hold should be? The backplane of this case looked pretty standard, last time I looked at it (nothing seemed strange or in an odd location).
Answer: Look at the wiki link Josh posted.  As you heard, many OEMs used to build their mobos to whatever size they pleased.  From what I have seen more recently (past 10 years or so) OEMs do build their motherboards to "normal" standards, though they do something silly like putting a metal peg in their case that sticks up through a specially cut hole in their mobo (I'm lookin at you Sony) or angling a corner of the mobo and putting a piece of metal in the case where the angle was cut off (I'm lookin at you Dell).  This is done to prevent you from re-purposing your case.  The solution in both cases is simple; break out the dremel and go to work on the piece of metal (AFTER removing all electronics from your case of course).
I'll step out on a limb and say your case most likely accepts an mATX, but again, verify this by measuring your old mobo and comparing the results to the Wiki link.


What is the relation between image file size and image quality?

Question: Is small image file size means low image quality?what is JPEG image file size of 5d mark iv .Can we achive better image in small image file size?
Comment: Image size has nothing to do with quality - much like a 1-second `.wav` probably won't have lower quality than a 2-hour `.mp3`. As to the 5D IV's specifications: [Have you even read the manual?](http://gdlp01.c-wss.com/gds/0/0300024970/01/eos5d-mk4-im-en.pdf#page=576) As to your last quastion: **better than _what_**?
Comment: Harjun, please do a little bit of research before posting your question. *What is the relationship between file size and image quality* is a good question. *What is the JPG file size for the 5Dmk4* is not - as it's easily answerable by you simply cracking the manual. As for *can better quality be achieved in a small file* - this cannot be answered unless you define what you mean by "better". This usually involves setting parameters like: is the image destined for web or print? If print, what size will it be printed and at what distance will the viewer see the print?
Comment: Please try and split this up into one clearly defined and answerable question - Stack Exchange isn't a format which deals well with posts which ask more than one question.
Comment: An image of a flat single-color surface with even lighting and no details at all will compress a lot smaller than a highly detailed landscape image, with no significant difference in the loss of quality (although the flat image may look a bit worse because there's no details for the JPEG artifacts to get lost among). Final JPEG size is highly dependent on the content of the image as well as the encoding options you use (quality, subsampling, etc)
Comment: Related: https://photo.stackexchange.com/questions/19270/what-are-jpeg-artifacts-and-what-can-be-done-about-them and https://photo.stackexchange.com/questions/94581/trying-to-understand-losses-in-jpg-compression
Answer: File sizes of JPEG images can be highly variable depending upon the image contents, even when comparing files with the same resolution and "quality" setting created with the same camera. This is due to the way they use compression to reduce file sizes. An image that is uniform in color and brightness will compress much smaller than an image that contains many different colors and brightnesses, even when both are compressed at the same "image quality" setting.
Canon publishes 'typical' file sizes for the various in-camera JPEG quality settings. For the 5D Mark IV, they list the following on pages 171-172 of the EOS 5D Mark IV Instruction Manual :

As you can see, there are "quality" settings of 'Fine' and 'Normal' at various resolutions. The difference between the 'Fine' and 'Normal' settings is in the degree of compression used when the JPEG is created.


REST Layer Security And Integration

Question: I have an widget-based front end talking to a REST layer. To use the front-end, a human needs to log in with a username and password. Once in, the user can interact with the widgets, which make calls to the REST layer. At this point, no authorization is done at the REST layer. If you have logged in successfully, you can do whatever you want.
However, I want to ensure that only users who have logged in can hit the REST layer. If you try to hit it with a browser or other client, you should get a 404.
We have managed to do this with OpenSSO, but it is complex. And its future is in doubt with its transformation to OpenAM. Also, there will be the need to integrate with other REST layers where Java code at the REST layer I have built will act as a client to other services secured by conceivably anything.
Thus, I have an issue with securing my stuff and security pluggability with other stuff.
I have been reading up on OAuth and CAS and OpenID and JOSSO and on and on and find myself confused as to which problems they all solve. I thought my problem was fairly basic, but I am at a loss. Any insight is appreciated.
Thanks.
Answer: That's depends what framework your are using for your REST layer.
For example, in restlet.org framework you can extend org.restlet.security.SecretVerifier
and implement your authentication scheme based on session, cookies etc.

REST Layer Security And Integration


Creation Date of Outlook/Exchange Calendar Event

Question: Is it possible to get the creation date (or last modified date) of an event in Outlook Calendar? I'm running Outlook 2013 (but the event is created with Outlook 2010) against Exchange Server 2010.
Answer: In Outlook 2010 or Outlook 2007 you can change the calendar view to list, Then add columns that will show different fields,  To do, once in the list view, go to View settings, in advanced view settings select columns,  There a number of field types to chose from, find the one that has "Created", "modified" and you might also want to find "changed by",  These additional fields in the list view will give you the informaiton you want.
Answer: In 2013: Click on "VIEW", Choose "Change View" and choose "list"
On the top left corner of the data, right click on the icon that looks like a sheet of paper.
Choose "View Settings"
Sellect "Columns..."
Then add the colums you wish to view in your list of data.
Change the dropdown under "Select available columns from:" to "All Appointment fields"
Add the columns you wish to have shown by left clicking on your choice and then click Add to move it to the left. I added "Created" and "Modified" to my columns.
Don't forget to click Okay and Okay.
The columns should now be in your list view data.
I hope this works for you.
Answer: Just found out that in OWA there's a "Sent: [date]" in the top right corner.
Answer: List view is not very easy to navigate with a lot of entries, and I found the  option below works better.  However, as an Exchange administrator when I open a meeting I see the last modified date and time in the status bar, but I don't understand why it's not showing for others.  If anyone has any ideas on this please let me know.
Open an item (appointment in this case) - go to its File, Options, Customize Ribbon. Select "All Commands" at the top. Click in the list below and type P on the keyboard (to jump to the Ps) then find Properties. There will be 3 "properties" - you want the middle one (plain old "Properties"). You will have to Create a New Group on the Appointment menu, rename it to Properties and Add Properties to this group. This will now sow the Properties icon for each appointment. Clicking Properties will show the last Modified date and time.


Is it better to wash eggs before refrigerating?

Question: I want to know how to store eggs in the refrigerator. Some people say to never wash them, others say it's ok to wash eggs before refrigerating. Which is correct?
Answer: I would personally avoid washing the eggs.
The problem is that wet eggs are bad.  This goes for both Europe, where the eggs are sold unwashed, and in the US, where the eggs are pre-washed and refrigerated.
If you did wash your eggs, you need to get them thoroughly dry afterwards.  Otherwise, you will do harm to the eggs.
If you're buying unwashed eggs, you could use a dry brush on them before you stored them, but I wouldn't recommend anything more than that.
Comment: @ASIM : it's in the link : "Sweating of eggs should be avoided because moisture on the shell surface weakens the egg's natural defence mechanisms, providing as it does an ideal environment for the growth of micro-organisms, and further facilitating their penetration through the shell pores. "
Comment: Can you please explain why and how do washed eggs can harm?
Answer: I raised chickens and handled many hundreds of eggs (my all time high was over 200 in one day.) I didn't like the idea of unwashed eggs going into the refrigerator, though they appeared quite clean.
Washing eggs does make the shells a bit more porous, so washed eggs don't stay fresh quite as long. If you do wash them, though, it's important to wash them in warm to hot water so that the contents expand slightly as they are being washed. That way, no wash water (or more importantly, bacteria in the wash water) enters the egg. Cold water would cause the contents to contract a bit allowing seepage into the egg. A quick wash/rinse with plain water is fine.
There are other ways to clean an egg, but it is far more work imo.
If you don't plan to refrigerate the eggs, you might want to just let them be, wiping off any dirt. Keeping the nesting boxes clean and good management of the coop/flock is important.
Comment: @Rob - I assume you'll be cooking them immediately after? This reduces the risk considerably. I like to wash my eggs, but I know not everyone does, and not all those who don't get sick. The real risk (I think) is washing, storing, or using/handling them improperly.
Comment: Did you wash the eggs before use?
Comment: @Rob - I washed them once, after collecting. That's all. Sometimes, if I knew I would be using them that day, I would not refrigerate them, therefore did not wash them at all.
Comment: I ask because, if they come right from the coop, and then you crack them for use, the dirt and everything else gets pushed into the contents or when it runs down the side of the shell and into your pan.
Comment: @Rob - Also please note: if the eggs are lain on clean sawdust (what I used), they *appeared* pristine. I would never take a dirty egg into the house.


"Kick your ass on the road" meaning

Question: I heard "Kick your ass on the road" in a movie. The context is that there were two people in a truck. One guy said it to the driver. From the context, I guess it probably means he had asked the driver to start off. I can't find it on the web. So, I want to ask if "Kick your ass on the road" is a common phrase? If so, what does it mean?
Comment: So is the speaker a passenger?  It could be possible that he intends to berate the driver (that is, "kick his ass" in the sense of verbal punishment), but it's necessary to get the truck started first for other reasons.  So this doesn't mean "drive the truck on the road," but it could mean, "start driving now, and then I'll begin yelling at you [kicking your ass]."
Comment: What do you mean by "start off"?  The "kick your ass" could mean either a physical beating (if both characters exited their vehicles), or it could mean to beat the other driver in a road race. It's unclear from your question what the context is.
Comment: @CanadianYankee I meant he asked the driver to drive the truck on the road. Can the sentence express that meaning?
Comment: @CanadianYankee yes, the speaker is a passenger. Your interpretation seems to make sense in that context. Thanks!
Answer: According to the Collins Dictionary
kick (someone's) ass

to punish or defeat someone

On the road is just setting the place where the defeat or the punishment may take place.
The speaker is saying to the driver that he (or maybe a third person) is going to defeat him.

(I'm going to) Kick your ass on the road
  (The Bad Guy is going to) Kick your ass on the road

More context is needed to specify who is the ass-kicker but I think that the main meaning of the expression is clear
Comment: That was what I thought, but the context doesn't seem to suggest this meaning.
Comment: @dan Thanks for accepting the answer but I think that you're not completely satisfied with it. Maybe if you indicate the movie and when that scene happens, you can get better help from others.
Comment: I think your answer is correct. The interpretation from Canadian Yankee is correct for that context.

"Kick your ass on the road" meaning


New roll of film rewound into canister after 4 exposures

Question: I've been playing aroubd with an 1997 Canon Sure Shot Owl and I recently put a new roll of film in. The last roll I put in was fine, but after taking 4 or 5 photos the film rewound into the canister as if it was the last on the roll. After I loaded the film, I had a moment where the camera wasn't feeding the film but that was resolved when I pulled the tab slightly further out of the canister and was able to take a few pictures. I know how to fix an accidental rewind, but I'm not sire what to do about those first few exposures without over or double exposing?
Comment: When you say you "know how to fix an accidental rewind", you mean you know how to fish out the leader?  Is there any reason you can't set a fast shutter speed and fire through the first several frames in a dark room?
Answer: If what happened is as you reported, i.e. only 4 frames exposed, you likely will be OK shooting the remainder. This is because the film cassette is light proof thus is protects the yet to be exposed film. Re-load, fire off 6 frames and then shoot.
One can never be quite positive about such things, something might not be as reported. If it were me, I would keep this rolls as sacrificial test roll. You can practice loading and rewinding etc. The decision to use this roll is based on how valuable the images you are about to take are to you.
Comment: Likely the first 6 frames are light fogged. Suppose the repair was accomplished in total darkness, then the 6 frames should be OK (not likely). In this case, reload the film as if it were an unused roll. With the lens cap on or suitable opaque cover over the lens, snap off 6 frames. The opaque cover will protect previously exposed frames. We often used this technique when we switched from one type of film to another. You can shoot B&W, maybe half a roll then rewind taking care to keep the tongue from rewinding. Remove this roll and replace with another. You can interchange at will.
Comment: To the digital shooter, it is almost counterintuitive that this won't overwrite the frame with black :)
Comment: I'll give you an up vote if you explain OP how to fire off the first 6 frames without actually exposing the already exposed frames a second time


Pixelated sculptures

Question: I'm new to blender and I have Been trying to learn sculpting, however, I bought some excellent sculpting sets, but it's always blurry, even if I Increase the subdivision modifier
It's still blurry
Comment: Hello. Did you apply the modifier? Maybe If you  add an image that illustrates your issue, it will be easier to help you.
Answer: You can only sculpt geometry that is existing for real. If you increase the details with a Subdivision Surface modifier, this is procedural geometry, i.e. "virtual" and not yet existing geometry. It cannot be sculpted since procedural geometry can be changed anytime by changing the resolution for example. This would mean all sculpting would be lost if it could be sculpted.
To sculpt the higher detailed mesh creted by the Subdivision Surface modifier, you can do one of the following steps:

Go to the modifier, hover your mouse over it and press Ctrl+A to apply it.
At the top of the modifier, click on the dropdown menu $\lor$ and choose Apply.
In the 3D Viewport with the object selected in Object Mode, press Ctrl+A and choose Visual Geometry to Mesh.

Now you have applied the modifier and generated a "real" detailed geoemetry which can be sculpted. Note that you can no longer change the subdivisions as the modifier is gone now.

Pixelated sculptures


What application is recommended to find dead pixels on LCD panel?

Question: I suspect there are few of hot pixels on my panel. As it is still under warranty and by the rules of my vendor I can replace a machine if panel has a 3 dead pixels on it, I'd like to check   how many dead pixels there actually are.
In Windows, there are plenty of simple applications that just fill the whole screen with different colors so hot/dead pixels are easily visible. Does something like this exists for Ubuntu?
Answer: This page just provides the white / black / red / green / blue screens to test your monitor: http://lcdtech.info/en/tests/dead.pixel.htm
Comment: Any reason to recommend this HTTP website over any similar web test? Webpages aren't typically saved for offline use and I feel that the answer is off-topic.
Answer: open terminal and install:
sudo apt-get install screentest

then:
screentest

right click on the screen to access the options for different test colors and patterns
Comment: this tool seems to be designed for CRTs and is not fit for checking dead/hot pixels. go with the web tool posted by @pba.
Comment: It is perfect for dead pixels.
Start the program, right click, choose blink and set the background color for red, then green, than blue. Because it is blinking continuously, a dead pixel will "jump out".
Answer: You could use GIMP Image Editor to make 4 images that are the same size as your desktop and color them red / green / blue / white.
Then open them in Image Viewer ( default picture viewer ).
Then dual click on the picture to get it full screen.
GIMP Image Editor is available from the Ubuntu Software Center
Following is a How-To for the visual learners.


Appropriate Multiple Testing Correction for Correlation Matrix

Question: I have $N$ samples of $D$ variables, for which I want to study the correlation. Specifically, I want to know if any of these variables are correlated. I can get estimates and a matrix of p-values in R using Hmisc::rcorr, but from the documentation for this function it seems no multiple testing correction is applied. A Bonferroni correction, dividing my threshold by $D(D-1)/2$, seems too conservative, since intuitively it doesn't seem like I really have that many independent tests (is the correlation of A and B, and B and C, and A and C, really 3 independent tests?). What would be a more appropriate strategy?
Answer: Let $(Y_{i1},...,Y_{iD})$ be a random vector, and $ i =1 , .., n$. Assume  $(Y_{i1},...,Y_{iD})$ and  $(Y_{j1},...,Y_{jD})$ are independent for $i\ne j$.
Fit two models:
Model 1:
     $$\left(\begin{matrix} Y_{i1}\\...\\Y_{iD}\end{matrix}\right)\sim N\left[\left(\begin{matrix} \mu_1\\...\\ \mu_D \end{matrix}\right),\left(\begin{matrix} \sigma_1^2&...&\sigma_{1D}\\...&...&...\\ \sigma_{1D}&... &\sigma_D^2 \end{matrix}\right)\right] $$
Model 2:
     $$\left(\begin{matrix} Y_{i1}\\...\\Y_{iD}\end{matrix}\right)\sim N\left[\left(\begin{matrix} \mu_1\\...\\ \mu_D \end{matrix}\right),\left(\begin{matrix} \sigma_1^2&...&0\\...&...&...\\ 0&... &\sigma_D^2 \end{matrix}\right)\right]$$
Then perform the likelihood ratio test. The null hypothesis is all of the covariance are zero (corresponding to all correlation coefficients are zero), and the alternative hypothesis is at least one correlation coefficient is not zero.


Fixed point as limit

Question: Let (X,d) be a complete metric space and $f^n$ be a contraction mapping with
$x_0$ as it's fixed point. I have already proved that $x_0$ is also a fixed point
of f, I need to prove that:
$$\forall x \in X  \lim_{k \rightarrow \infty} f^k (x) = x_0$$
If i take only $\lim_{nk \rightarrow \infty} f^{nk}(x)$ then it's easy as the powers of $f^n$ are also contraction mappings, but I'm not sure it's correct.
Answer: Hint: Let $x\in X$. Prove that the sequence $(f^n(x))_{n\in\mathbb N}$ is a Cauchy sequence. Since your space is complete, it converges to some $y$. Then prove that $f(y)=y$. Since $f(x_0)=x_0$ and $f$ is a contraction, $y=x_0$.

Fixed point as limit


Do UI adjustments for people 45+ harm younger user UX?

Question: Sidewalk curb cuts benefit people in wheelchairs but also help everyone else. Is this also true when making buttons bigger, fonts larger, contrast stronger, timeouts longer, etc.? Or do younger people have a harder time using web sites and apps?
Comment: Consider the products made by [OXO](https://en.wikipedia.org/wiki/OXO_(brand)), which were originally designed for arthritic users but are now coveted by everyone.
Comment: To spin it a bit: Why would they harm younger users?
Answer: Not at all. There are many studies demonstrating that general adjustments for older people are of benefit for both the elder and the younger extremes. These studies also demonstrate younger demographics (specially teenagers and kids) prefer big, bold, contrasting elements over subtle, low contrast elements.
While there are many misconceptions around this issue, research shows those are just that: misconceptions. Just in case you want to know more, here you have an interesting article on these myths (because they're just that: myths). You could also take a look to this document with research and even some formulas
So, in short, to answer your question: no, there's no relation
Answer: I always ask people:

Have you ever thought about an application: 'This is to easy to work with,
  I can't work like this!'

They always answer no, sometimes they ask something about missing functions. But an application that is missing some parts is not the same as an easy one.
If there is any difference it might be more in the marketing department: What attracts young people to return to a webshop and buy, might totally be different to what older people want to see. But even then, there's no reason why you can't cater to both groups.
And don't forget the accessibility, sometimes you don't need to implement the functions people need but only make sure their own browser or computer add-ons can use your creations effectively. (Think about screenreaders for example)
We're all still human, we do have a lot in common because of being the same species.
Comment: Even with the web stores and such, there's still going to be some overlap.


Hide contacts from search results ,added to specific group

Question: I am looking for hiding contacts in CiviCRM from search results,added to specific group and also Drupal user should be blocked in automatically soon after adding them to a group.Soft delete using civirules is one option.But I don't want the user to get trashed.Any help?
Comment: i think you need to try and explain this a bit more clearly. eg 'blocked' for a user makes sense, but 'thrashed' doesn't. And are you talking about 'drupal users' when you say 'soft delete' as I don't associate that term with Users but I do with Contacts.
Comment: Sorry if I have not clearly explain. Using Civirules, a contact added to a group can be soft deleted so the contact will not be available in quick search results
Comment: Can you edit your question then to be clear where you are talking about Contacts v Users. It helps if you don't use them interchangeably since they mean quite different entities
Comment: i changed 'thrased' to 'trashed'. hopefully that is what you meant.
Answer: This is directly not available through UI, but you can do this by creating your own extension and using hooks like post and queryobject.
HTH
Pradeep
Answer: You can achieve this via UI with ACLs, but it is somewhat messy and does have some performance implications:

Use the Include / Exclude Search to search for all contacts but your specific group by excluding it and create a smart group for it
Remove the CMS permission to view / edit all contacts for your desired CMS user role
Assign an ACL to read / edit your newly created smart group for your desired ACL role
Assign users to the ACL roles

Perhaps you can play around with the Drupal Rules module and its CiviCRM integration to block users beeing added to a group.


Safest way to duplicate failing sd card

Question: I have a 64 gb SD card that is starting to have problems. I want to duplicate as much of it as I can. Is DD the safest/best option to deal with failing sd cards?
Comment: `ddrescue`  (https://help.ubuntu.com/community/DataRecovery)
Comment: @guiverc That's not a comment!  That's an answer!  Please post an answer, ping me [at]Fabby and I'll come back and upvote! **;-)**
Answer: I would use ddrescue myself.
I'd suggest looking up https://help.ubuntu.com/community/DataRecovery for more information, and especially note the caution:

You should NOT write to the failed device, as it can worsen a hardware
  failure, and overwrite existant data in case of lost files .

(it's covered in the Imaging a damaged device, filesystem or drive section)

Safest way to duplicate failing sd card


How would I combine hard surfaces and soft surfaces for rigging a robot?

Question: I've been struggling for awhile now to rig a robot with a "rubber covering" over the midsection while the chest and waist stay solid, unbending or moving while the rubber portion bends and stretches to connect to both parts. Is there any way to manipulate the mesh/armature/weight paint to make it work properly?
Answer: Here is a 'robot' that has a chest, waist, and mid section.  It's fairly simple, but it does for exposition:

I'll explain the loop cuts in the middle section below.  The top cube serves as the 'chest. The middle cube as the 'mid section' and the bottom cube as the 'waist'.
I added an armature.  It's very simple and the parent hierarchy is also simple.  The chest is the child of the upper mid section. The upper mid section is the child of the lower mid section. The lower mid section is the child of the waist.  Notice that I named the bones to match their roles.

Also notice the position of the head and tail of the bones.  They match the center of the horizontal planes that make up the parts of the robot.  This will matter in how well deformation works.
In object mode, I parent the robot to the armature, selecting "with empty groups":

You could try automatic weight painting, but since this robot is simple, I decided to populate the groups by hand.  To do this I select the robot, then shift select the armature and then type CTRL-p to bring up the parent menu.
This is where I differ with the first answer to this question:  The vertices of the shared planes should go in vertex groups for both of the bones that meet at the plane.
The next four steps involve selecting vertices and adding them to the vertex groups that were created by parenting.  First I select the robot and go into edit mode.  Next, I select a vertex group from the Properties editor -> Object data properties -> Vertex Group list:

Notice that there are four vertex groups and each one has the same name as one of the bones.
I make sure the weight is set to 1 and then I select the relevant bones.  Since I selected the chest vertex group, I pick:

I click assign in the vertex group list to add those vertices to the Chest vertex group.
Next I pick mid section upper and the bottom of the chest as well as the upper half of the mid section:

I click add to add these to the mid section upper bone.  The other two bones are
mid section lower

waist:

To see why I placed some vertices into more than one vertex group I select the armature and in pose mode, I rotate the chest:

As you can see, and as you should expect, the middle part of the robot has deformed as a result of the chest movement.
Now look at this pose where I rotated the mid section upper:

It shows a rather bad deformation at the middle of the mid section.  This is where fractional weights come into play.  That bone should also gently deform the next part of the mid section as well.  This is where weight painting becomes important.
I also said I would explain the extra loop cuts.  As you can see this robot doesn't deform very smoothly.  The more loop cuts you add the better the deformation will look but the harder that weight painting will be.
Unfortunately this answer is very long already and there's really a lot to weight painting.


Are Apache, PHP and MySQL installed by default?

Question: Are the Apache server, PHP, and MySQL installed by default when you install Ubuntu 13.10, or should you install them separately later?
Answer: No they don't come with the desktop version of Ubuntu 13.10 by default. You have to install those three by yourself. For "how to install" please go through this link .
Answer: The simplest way to install all three is to run the lamp-server task:
sudo apt-get install lamp-server^

The caret at the end means that this is running a task, not installing a package. There is no lamp-server package, so if you leave off the caret, apt-get will return the error message,

Unable to locate package lamp-server.

The task will install Apache, MySQL, and PHP, and will also take you through the setup steps, such as creating a password for the MySQL root user.
Comment: Thank you so much TRiG. This will be a very helpfull... In fact, tha caret thing.. is new for me.
Comment: I only learned about the caret thing here, so Ask Ubuntu has helped both of us.
Answer: You can use XAMPP for Apache, Mysql, PHP from this link: http://www.apachefriends.org/en/xampp-linux.html
its very simple easy and fast.
Try it :)
Comment: Thanks, but the idea is to install these applications natively . I know that the easiest way is to use XAMPP but then where is the fun?


is this derailleur short cage or long cage?

Question: I'm selling the rear derailleur off this bike, and someone asked whether it's short or long cage. I assume it's long. Is this correct?
Answer: Campagnolo derailleurs come in three lengths, short, medium and large.
To determine the size measure it. The centre to centre distance between the sprockets is 55, 72.5 and 89 mm and my guess is that you have a medium flavour rear derailleur...
How much are you selling it for, b.t.w.?
Comment: thanks it's 55mm, which would make it short. I sold it and the record shifters for $300.
Comment: Oops! I mean't short!
Answer: Based on the pictures shown at Jenson USA, it appears to be a short cage, or perhaps a medium.  Although the picture you posted doesn't give a very good view of the derailleur. Take a look at the pictures in that link to judge for yourself.  Based on the information behind that link, it says that short cages are usually used for road bikes with a double crankset, while larger cages are used for triple cranksets or mountain bikes with a larger range of gears.  Since the pictures shows a road bike with a double crank set, I would again think that it is a short cage.
Comment: The real distinction, of course, is the number of teeth that the derailer can "absorb".  Suntour, eg, used to make a triple pulley derailer that could accommodate as many teeth as a standard long cage, even though the cage was no longer than the one pictured.
Comment: It's pretty obvious it's strictly short cage.


How to verify fuse ampere rating

Question: Is there any method to verify the fuse ampere rating without destructing it .I know the fuses works on the principle of resistive heating .If there is any method to verify the ampere rating without destroying the fuse please answer
Answer: If you can do a resistance measurement on the fuse, and at the low m\$\Omega\$ this will be, you will need to do a careful 4 terminal measurement. Then you can compare the measured resistances with those made on some example known fuses, or calculations based on the sizes of fuse wire.
Good luck with very careful measurements.

How to verify fuse ampere rating


Do I need a business license to start a social media website?

Question: I'm planning on starting a social media website similar to other large social media websites. Do I need to register it as a business in order to make profits from it and/or get a trademark for its name? (I live in Georgia, USA)
Answer: In general, no. You can run a business as a "sole proprietor." However, certain activities may require you to get a business license.
For example, if you need to collect state or local sales tax because you are selling taxable things, you probably need to register with whoever collects the tax. If you are hiring employees, you generally need a federal Employer Identification Number (EIN) so that you can withhold income tax, pay FICA deductions, etc. If you are going to have a particular place that is open to the public for business, you may need to register with your state or local government. Depending on your line of work, you may need to get some sort of license or permit (health inspection, safety inspection, etc).
If all you are doing is running a website and getting a trademark, then there is no legal requirement that you incorporate, create an LLC, or register as a business. However, there are some good reasons to do so. For example, if you don't make a business entity (corp or LLC) separate from yourself, then if someone wants to sue your website, they would have to sue you personally, and you could lose money. If you operate the corp or LLC, then typically you can not personally be sued for your business activities.
Many developers start by running a website or an app without a corporation, then when any significant business activity or public presence begins, they create one. An accountant or lawyer can advise you further on your specific case.


How to post results to a Handler in a different activity in Android?

Question: I have an activity A that does some network I/O inside a thread. During that I/O, I want to be able to proceed to a different activity B and get the results of that thread inside B. Is there a way to post to a Handler from A to B?
Answer: Are you instantiating B from A then you can pass the object of handler from from A to B and send messages to handler in A from B
Answer: You can post to a handler from anywhere you have an reference to it. So there are a ton of ways to do this. If you have a reference to the instance of A you can make an accessor or post methods or you can pass the handler instance around as you see fit.


Not able to see '/home' drive

Question: I have installed "Ubuntu 12.04 LTS" with 3 partition:

/ drive for 100 GB
/home for 200 GB and
/swap drive for 8 GB

But after successful installation I'm not able to see /home drive .
I can see only / drive. I want to keep my data's in /home drive [as like D: drive in windows] .
Answer: If you've not started to really use it the simplest way to do this would be reinstall using the Something Else option at partition stage, editing partitions and choosing the correct mount points.
Otherwise you'll need to copy data from the existing /home into the new partition.
If you want to just add the partition to /etc/fstab and have it mount that can be done.
Answer: Ok first you need to make one thing clear: what utility/tool did you use to see what partitions you have?
If you are referring to Nautilus(the default file manager which opens your home folder/documents etc), then it would not show you the drives explicitly.
Just to be sure, open your dash and search for system monitor

and select the filesystems tab.

if you see home here, that means your home partition is in use.so whatever files you put in your home folder[Desktop, pictures,videos and all other folders inside Home will go into your home drive]
Answer: The windows concept of a "drive" does not exist on Linux systems. As you wrote, you mounted the 200GB partition you created under /home, and that is where it is located. There is no separate "drive" for that partition; instead, access to partitions happens transparently, i.e. every time you access something below /home, like /home/user/Desktop, you'll be accessing your 200GB partition.
So, if you really set it up like you said you did (you can use Sagar_R's answer to check that), everything is already as it should be.

Not able to see '/home' drive


Google Calendar sync with php in 2 ways

Question: I am creating a php website that uses the Google Calendar API. It's working fine with Create, Update and Delete: any event from the PHP website goes into my Google Calendar events after login.
Events created on my site are created in Google Calendar.
What I want now that is: when I create an event from my test page it goes into Google Calendar after login, then if I update or delete that event from Google Calendar then it should automatically update or delete the php website event.
Basically: 1-way sync is working fine but now I want 2-way synchronization.
If anybody has any ideas then kindly share with me, it will be much appreciated.
Comment: What I want if I delete an already synced 'Google Event' from my 'Google Calendar' it should also be deleted from my already synced PHP application.
Does anybody have any idea for this?
Answer: There are no application hooks in Google Calendar (gCal) that allow you to trigger an action when an event is deleted. Instead you must either poll gCal at intervals (this could be a cron job every few minutes/hours) and update your calendar accordingly, or any time you perform an action from your calendar have a 1 in X possibly of a full re-sync.
This implies that you are using the gCal as the definitive source, and mirroring those changes back to your local application.
Comment: I agree with Andy here, that there is no way in the API to do this
Answer: well, after following these answers and building a hole 2 way sync process,
i realized there's a push notifications for calendar since 2013.
you will still need a full sync process because the push notification only notifies about a change but no data about the change.
hope it will save you some time.
Push Notifications
Comment: If you're shaking your head in disbelief [like me] that the push from the API notifies *that a calendar changed* but not *what changed*, [this post](https://plus.google.com/+MatthewZimmerman/posts/ag6CEJoXxbM)—unfortunately—confirms the bad news.
Answer: Would it not be an option for your system to generate an iCal output at a special, user-specific URL, and then have the user subscribe to that calendar in Google Calendars (or their iCal-reading calendar of choice)?
That way, your system would always hold the authorative calendar, and Google Calendar would reflect any changes you make automatically.
Alternately, if you are wanting changes in the Google Calendar to be reflected in your application, then you may be able to subscribe to iCals for the User's Calendar, and then poll them at a regular interval to reflect any changes the User has made at that end.
I would lean towards the first option (your iCal subscribed through Google Calendar), as it is a simpler and easier solution.

Google Calendar sync with php in 2 ways


Do political systems evolve with economic progress?

Question: Do political systems evolve with economic progress? In a lot of sci-fi movies you don't see government evolve with technology and economy, but in Star Trek, I believe, the political system ended up turning into a socialist system given that economic limitations slowly disappeared with technological advances such that they became socialist although private property exists. Was there any theoretical framework made to understand the relationship between economic progress and political development?
Comment: It may be helpful to know that some folks in this philosophical area distinguish between personal property and private property. As I understand this world view, owning a picture of your family is personal property and is ok, but owning a factory is private property and is not ok.
Comment: @JoelHarmon  Yes. People think many strange things.
Answer: The current economic system has many elements which require faith in the rule of law.

Consider currencies. It used to be that the king's minting of coin was a promise that the coin had true weight and purity. Today there are fiat currencies. That's necessary since limiting the money pool to the supply of specie is crippling for an economy.
Consider joint-stock companies. The idea that there can be a partnership where one partner can sell the shares without consulting or even informing the others. Startups collect venture capital to try fresh ideas, from people who can trust that their money might be mis-invested, but not outright embezzled.

That is difficult with a system which depends on personal, feudal ties to a king.
Answer: Of course things evolve with economic progress. I'll give two examples: Slavery and education level.
Regarding slavery: Until three of four hundred years ago, slavery was a very widely accepted practice. Economic progress made slaves a burden rather than an asset. Slavery is universally denounced nowadays (but it still does exist).
Regarding education: Until two or three hundred years ago, having a ninth grade education meant one was well educated, and a having twelfth grade education meant one was extremely well educated. Economic progress has made those count as undereducated and barely educated nowadays (but high school dropouts do still exist).
Answer: Different forms of governments have appeared historically in correspondence with the prevailing economic conditions and technological advances of the period. For example, after the Romans reached certain level of economic, technological and military development, they entered an expansionist phase for which the Roman senate was inefficient as compared to the dictatorship of Caesar and the emperors. Also, after the industrial revolution, the emergence of the bourgeoisie lead to the modern liberal democracies. The failed socialist republics of the 20th centuries didn't achieved the level of technological advances required to realize the socialist economy, and they brought highly oppressive forms of government in order to establish socio-political stability (which still happens in Cuba and China irrespective of their economic disparities).
There is no socialism if the prevailing economic relations derive from private properties according to Marxism. Thus, the fictional social order you see in Star Trek is neither socialism nor communism.
Comment: yes, private property over the means of productions (according to Marx, Proudhon, etc.) and personal property should be considered different. I hope Star Trek society isn't socialist/ communist, for then, I'll looking for political asylum with the Klingon.


New keyboard shortcut to display Shortcut Overlay (instead of Super)

Question: I would like to set a different shortcut to show Shortcut Overlay (the default is Super alone). I cannot find any relevant setting to modify. How can I define a new keyboard shortcut for this?
Answer: You probably already figured this out but you can set a custom shortcut in the settings menu. For the command to run: /usr/bin/io.elementary.shortcut-overlay.
I found the command using lxtask and opening and closing the shortcut menu repeatedly till I found the process, then did whereis io.elementary.shortcut-overlay and finding the location in the output.


Question about leaving supervisor

Question: My supervisor is going to leave to work at another university before I finish my thesis. I'm not sure how this process works. Will this cause problems with me graduating?
Comment: Your supervisor should be willing to help you facilitate the change to another person in the department, possibly his replacement, or another staff member who is already established.
Comment: ... or finish supervising you from the new place. In any case, he should have an idea how to transition his current students.
Comment: And how did your supervisor answer this question?
Comment: @user119264 That depends on the rules of your university, of course.
Comment: @Compass there's is no one in my department whose research is even close to my supervisor's area.
Comment: @xLeitix can you elaborate on that? I'm not sure how this process works. Can I be supervised by a member of staff from another university.
Answer: This is a fairly common situation, but there are lots of ways in which it can be handled.  A lot depends on the specifics of your situation and how well your advisor and your current department are getting along.
One important issue is the source of your funding.  If you're currently funded by your advsior's research grant, and that grant is moving with your advisor to the new institution, then it is may not be possible for you to continue being funded through that grant as a research assistant at your current university but it might be possible to continue with that funding at your advisor's new institution.
On the other hand, if you're currently funded by institutional or departmental sources such as a departmental teaching assistantship, you might be able to keep that funding where you are but it would not be possible to take it to your advisor's new institution.  However, it might be possible for you to obtain some kind of institutional or departmental funding at your advisor's new institution.
There are three common ways in which this handled:

The student continues at the advisor's old institution and the old institution allows the advisor to continue to supervise the student as an adjunct faculty member of the old institution.  The student ultimately completes the degree at the old institution.  This works best if the student is close to completion and has funding that is independent of the advisor's grants.
The student transfers to the advisor's new university and completes the degree at the new university.  This typically works well if the student is supported by the advisor's research grant and if the student is not very far along in the graduate program.  The new university would have to agree to accept the student into their graduate program.  The new university may have different course requirements and the student might have to repeat prelim exams or a candidacy exam.  Foreign students would have to get a new student visa.
The student remains where they are and switches to a new advisor.  This works best for students who have departmental or institutional funding and aren't very far along in the graduate program.

You should talk to your advisor about how he or she wants to handle this, and you should also talk to your department chair or the head of the graduate program to get the department's position. You'll also have to think about what you want- what's best for you may not be what your advisor or department wants.
Comment: @Drecate yes, that's a more specific answer.  The point is that this isn't a completely trivial process and it could delay a student.
Comment: Funding is not really an issue since my research is in mathematics. My funding comes from being an adjunct tutor/teaching assistant. I think the first option would be best for me. Because I'm almost finished and the research I do is wholly unique my supervisor. Besides,  the new university he is transferring to is across the world and wholly inconvenient for me as well.
Comment: Is it possible to mix options 1 and 2, where you add a co-advisor at your current institution but continue working with your original advisor remotely?
Comment: @RogerFan yes, that might be an option.
Comment: Transferring from one program to another doesn't necessarily require a new visa; it requires a transfer of the SEVIS record to the new institute and a new I-20 form for the student
Comment: This covers all the situations that I have personally seen over the years. Within a year of graduating, you stay and finish up. First year - you might switch to another group. In between, you can move to the new university with some assurances that your coursework and passed qualifiers from the old will be honored by the new (or your adviser should be shot for not negotiating that!). The professor who is moving really wants the core of the group to come and set up the new lab (which might not be in your interest, mind you).
Answer:
Will this cause problems with me graduating?

First, I recommend to discuss with your supervisor how their departure might affect you.
Things to bring up:

Whether s/he can (and is willing to) continue supervising you after transferring to another institution.
The process for identifying replacement supervisor: Whose responsibility is this, and will your supervisor assist in some way? Can they recommend one or two colleagues they think would be a good fit for you and interested in your thesis topic or research area?
Potential difficulties you or the supervisor anticipate that could increase your time to graduation, and steps you could take to prevent such issues.

The answer to your question also depends on some of the following:

How far along you are in the program and into your thesis, and whether the new supervisor is receptive to the work you have done already

Note: This assumes current supervisor is unable to continue playing this role from another institution. This may not be the case, but some programs require that the committee chair/supervisor be a member of the same department.

Whether the new supervisor will be receptive to your thesis ideas, methods you have or plan to use (work done so far), or if they have some concerns that would involve re-work.
Personality fit with new supervisor: This is an important factor. Think about people with whom you had or can easily imagine having some conflict or communication difficulties, and try to avoid getting them assigned as your new supervisor.

Instead, think of who you see yourself working well with in terms of their work ethics/supervisor style, e.g. would they micromanage you or expect perfection, will that benefit or impede your progress, etc.
Lastly, I encourage you to think beyond graduation itself. The supervisor can be a key resource for furthering your career upon graduation. If you are in Master's program, their connections can decide your fate in terms of where you end up for your PhD, should you choose to go for doctoral study. If you are already in PhD program, their connections and your relationship with them could play an important role in securing a job after graduation (perhaps even one of your top choices). So I encourage you to think a little longer-term and consider how that person can contribute to your professional development not just to the extent of graduating but becoming a potential mentor for years to come. Good luck!

Question about leaving supervisor


Tuning/Best Practices Inetsoft Style Report BI Tool?

Question: Is anyone using the business intelligence tool Inetsoft Style Report ?  I'm stuck with it and was wondering if anyone has advice on tuning and/or best practices for server admin?  We are running on a fast Solaris box using Tomcat with a db2 database.
Answer: You have my sympathy. We run ours on a dual Xeon with 4G ram, and it's still a pig. One of our programmers is an ex-Inetsoft employee and has done everything known to optimize it.
My only suggestion is if your organization is considering StyleReport, run!
Answer: Jim & Clint,
This is Mark from InetSoft. Sorry to hear of performance issues. This is definitely the type of thing our Support team can help with. So please reach out to your InetSoft account manager or log a ticket at http://www.inetsoft.com/customer/support.jsp . The next versions of Style Intelligence and Style Report come out this month, and performance enhancements are on the list of advances.
Answer: One thing you can check is whether the CPU is fully utilized when the server is running. If it's not at or close to 100%, check the Tomcat thread pool size and try increase it. There should be parameters in StyleReport to control it's thread pool sizes too. Normally if the CPUs are fully utilized, the performance should be ok.


How long should I allow pressure-treated plywood to dry before applying non-skid strips?

Question: My handyman just laid salt-treated plywood on a wheelchair ramp.  He said the wood was very wet and would need several days to dry out.  How long should I wait to install the adhesive non-skid strips?
Comment: Can air get to the underside of the plywood, i.e., the side that is down on the ramp? Is the ramp a continuous surface or is it a framework? Can the plywood dry from both sides or must it dry from the surface facing up? How long is the ramp? What I am wondering about is whether drying could be hastened by blowing on it (maybe from the underside) with one of those high velocity fans used for drying the inside of a house which has flooded from a burst pipe. Even blowing with the output of a shop vac might speed up drying.
Comment: You're not going to like it, but at the wood shop, our rule is "an inch a year".  So a 1/2" plywood would be 3 months (allowing it to work from both sides).
Answer: Have you read the instructions? I'd start there, especially since you haven't told us what product we're talking about.
In reality the plywood will take weeks or longer to truly dry out, and depends heavily on your weather and sun exposure. The answer to your question partly depends on the size and shape of the tape. If it's composed of narrow strips, I'd wait at least a few days (in the sun) or a week (in the shade) so that the surface is noticeably dry. If it looks dark and damp or feels cool, your adhesive probably won't bond well.
If the tape is wide or a full sheet, give the wood much longer to dry out. You'll effectively seal in the water, and it may collect beneath the tape and cause it to release.


What is the right citation for the power iteration method to find eigenvalues?

Question: What is the right citation for the power iteration method to find eigenvalues, if I want to cite the method in a paper? I've seen some Google PageRank references in this context. But Brin and Page didn't invent the power iteration method, did they?
Comment: You could also just cite a well-known text book in the area that explains the method. I'm sure the power method is explained in many numerical linear algebra books, like Golub and Van Loan, for example.
Comment: It is probably more useful to your readers if you cite it in a standard textbook or two, rather than the original paper of Jacobi (or whatever).
Comment: I've heard someone refer to it as Jacobi's method, so it may be very old.
Comment: I had to cite it in a paper recently (well, orthogonal iteration in fact), and I went for Golub-Van Loan, too. If I were a reader that does not know the power method, I'd rather see a reference to a standard textbook than to a 1910 paper in German.
Comment: Nobody expects you to be a historian. If the provenance isn't clear, why not just cite who you think is responsible, and include citations from other papers who mention the topic? Nobody is going to accuse you of not being thorough.
Answer: Several researchers indicate that the power iteration method dates back to Herman Müntz.  According to the survey aricle  "Eigenvalue computation in the 20th century" by Golub and  van der Vorst,

Householder called this Simple Iteration, and attributed the first treatment of it to Müntz (1913). Bodewig attributes the power method to von Mises, and acknowledges Müntz for computing approximate eigenvalues from quotients of minors of the explicitly computed matrix $A^k$ , for increasing values of $k$.

Ortiz and Pinkus also mention in "Herman Müntz: A Mathematician's Odyssey" that

In 1913 he published two notes in Comptes Rendus in connection with the use of iterative techniques for the solutions of algebraic equations. It is very possible that Müntz was the first to develop an iterative procedure for the determination of the smallest eigenvalue of a positive definite matrix. It certainly predates the more generally quoted result of R. von Mises of 1929.

Müntz's real innovation in the first one of his 1913 papers is the method of simultaneous or orthogonal iteration: "Qu'on parte des n directions consecutives ...; en orthogonalisant et en normant, d'apres les notations connues de M. Schmidt, les determinants, on obtiendra convergence ... vers les axes principaux, en general toutes les n."
The relevant papers by Müntz:

Solution directe de l'équation séculaire et de quelques problèmes analogues transcendants, C. R. Acad. Sci. Paris, 156 (1913),  43-46.

http://gallica.bnf.fr/ark:/12148/bpt6k3109m/f43.image.langFR

Sur la solution des équations séculaires et des équations intégrales, C. R. Acad. Sci.
Paris, 156 (1913), 860-862.

http://gallica.bnf.fr/ark:/12148/bpt6k3109m/f860.image.langFR
Answer: In his Ph.D. thesis Erhard Schmidt proved the existence of an eigenfunction of a symmetric integral operator by using iterated kernels, the equivalent of matrix powers in a function space. In order to avoid convergence problems in the case of eigenvalues of equal modulus, he did not apply the integral operator directly to a function.
https://gdz.sub.uni-goettingen.de/id/PPN235181684_0063?tify=%7B%22pages%22:[479]%7D
In his 1909 textbook "Determinantentheorie" Gerhard Kowalewski, a distant relative of Kovalevskaya's husband, gave a finite-dimensional version of Schmidt's existence proof for a symmetric matrix T, and then proposed "a simple infinite process to get to an invariant of T", the power method.
Answer: I vaguely remember, that this is due to Hotelling (1933). I don't have the monography of S. Mulaik "The foundations of factor analysis" (1972) at hand, but google-books let's you have a peek for "Hotelling".
At page 114/115 this is discussed and Mulaik writes: "However, in 1933 Hotelling published a paper in the Journal of Educational Psychology which described a method of finding the characteristic equation directly (...)" Page 115: "(...) permitting us thereby to pick from among the eigenvectors the one associated with the largest eigenvalue. As a matter of fact, both kinds of methods are available. The first, which converges to the eigenvector associated with the largest eigenvalue, is due to Hotelling.(...)"
The method named after Jacobi to find the eigenvalues/eigenvectors is the special case of rotating the columns of a matrix to approximate a certain maximization criterion iteratively. This can be done if a symmetric matrix was decomposed for instance in its two triangular cholesky-factors, and the lower triangular factor is ("Jacobi"-) rotated to "principal components position". Here all pairs of columns are rotated to maximize some criterion and this is repeated until some convergence criterion is satisfied (I can provide that criterion if needed because I've implemented it in a software).
The book of S. Mulaik is a bit aged and of the year 1972, and although there is a lot of modern development in factor-analysis I rate it as still the best monography/standard textbook for the basic understanding of factor analysis and related basic methods of linear algebra (as well for the history...)
(google:
http://books.google.de/books?ei=vTnTTLOeJYT5sgbqs7yKDQ&ct=result&id=ytwkAQAAIAAJ&dq=Mulaik&q=Hotelling#search_anchor
)


Understand multiple-column index for mysql

Question: Suppose I need to query:
select * from table where f1='f1' and f2='f2' and f3='f3'

And I have indexes for f1_f2 and f2_f3, then will my query take advantage of these two indexes? Or I need to create a new index f1_f2_f3?
Thanks
Comment: If you create an index by `f1_f2_f3` then: #1 - you'll optimize your query completely; #2 - you may remove the index by `f1_f2` because it is obviously excess (the query which needs in it may use newly created index instead). The only exclusion is the case when `f3` is long string/binary column.
Comment: You can try using `EXPLAIN` to examine your query and the index usage.
Comment: Since all tests are via `=`, the new index can have the columns in any order.  The performance will be virtually the same, regardless of which column you have first in the `INDEX`.
Answer: If you want an index to optimize the search for all three columns in the best way, you'd be better off creating a three-column index on f1_f2_f3.
MySQL does have an index merge algorithm, but it doesn't kick in as often as you'd think. Usually the optimizer chooses just one index per table reference. Besides, an index-merge of two index lookups would be less efficient than a single search using one index.
By analogy, suppose you are searching a book using the index at the back of the book. You could look up pages that match one word like "Earth" and that would give you one list of pages to check. Then you look up another index entry for pages that match another word "history" and that would give you a different list of pages. Then you'd have to compare the two lists to find the pages that appear in both lists.
If you had one index entry for "Earth history" that gives only pages that match both words, that would be more optimal.
Comment: The latter scenario is what a multi-column index would do.
Comment: Suppose we have index for both `f1` and `f2` and would like to query `where f1='f1' and f2='f2'`. Then the latency approximately proportional to examined rows for `f1` + examined rows for `f2` + comparing/merging these two lists?
Comment: But suppose examined rows for `f1` is 100 while for `f2` is 1000000. Then the query will be greatly slowed down due to `f2`.
I think more reasonable is based on the already examined 100 rows for `f1`, we start to further filter according to `f2` index (sort of involves merging)


.php extension not being parsed by apache on mac os x 10.6

Question: I wanted to use postgres with php, and the default install of mac os x, doesn't have the postgres php modules installed. I tried using the entropy.ch install not realizing that it was incompatible with mac os x 10.6. After removing the entropy code, attempts to render php files responded with a textual representation of the php file.
Answer: Additional configuration of php is called out in this line:
Include /private/etc/apache2/other/*.conf
of /private/etc/apache2/httpd.conf
I believe I had accidentally deleted the php configuration file that should be in that directory. I created a file named php.conf and put the following lines into that file:
<FilesMatch
   "\.php$|\.php5$|\.php4$|\.php3$|\.phtml$|\.phpt$">
     SetHandler application/x-httpd-php </FilesMatch> <FilesMatch "\.phps$">
     SetHandler application/x-httpd-php-source
 </FilesMatch>

That enabled apache to set the right mime type on the request, pass it to php which then rendered the code. Painful time wasting mistake.
In addition you need this also:
<IfModule dir_module>
    DirectoryIndex index.html index.php index.htmls index.htm
</IfModule>

Answer: You might want to consider using XAMPP or MAMP fore development purposes. I think most Mac devs do and I do as well. It makes things much easier for me.


LG G3 device not recognized by Eclipse on Windows

Question: I recently bought LG G3 and I have enabled debugging mode but Eclipse is still not recognizing it, back when I used the Galaxy S3 for development I had to install Samsung Kies. The G3 drivers are installed and I can see it in My Computer, do I need something like the Kies but for the LG? If so can someone please post a link for that?
Comment: Install google drivers from your device manager.
Comment: I have a similar issue, too, so I'll add some details: the device comes up showing MTP, but no other device is listed in the device manager... that is, no device that would normally be used to attach the ADB drivers to. Toggling debugging mode doesn't work, either. @Tal: What version of the G3 do you have?
Answer: See update below

I found the answer that worked for me.
When you plug in the phone, bring down the status shade, pick the USB item ("USB connected") then, from there, pick "Internet connection" -- I chose Ethernet, but I'm not sure the choice matters on the dialog that pops up..
This enables USB debugging to become active; leaving it on Charging, MTP, or PTP does not work.
Once you do this, you can follow @Siddharth's steps to setting the ADB drivers, if needed. (You may need to use the actual LG drivers and not the Google drivers, but once I got this far, it was just like any other phone.)
Caveat
For me, even after going through this once, I still get the "installer" first and then have got go in and choose the "Internet connection" again. But, at least it works.

Update 10 Dec 2014
A recent firmware update has, indeed, removed the "Internet connection" as an option. Instead, PTP now works. I still get the "Connected as an installer" notification every time I plug in the phone and have to click on the notification then click on "Camera (PTP)" -- or wait about a minute. It's slightly better than what It was.
Also note: When this change occurred I had to install the drivers again for the phone, since it comes up as a different type of device when "Camera (PTP)" is chosen than when I used the "Internet connection" option.
Comment: So weird.  This was the only thing that worked for me.  Thanks.
Comment: I had to choose the Internet Connection option before I was able to do any debugging.  Thanks for the tip!
Comment: This also worked for me (the accepted answer did not). Very strange and unintuitive, but at least it's working now. Thanks!
Comment: Thanks for this answer, after trying multiple different solutions, this one worked.
Comment: I am running into the same problem. I can't find the Internet connection. Can you help me with that please?
Comment: My understanding is that "Internet Connection" was removed from the USB options menu in a recent update.  I'm trying to find an up-to-date solution for this, no luck so far.  Setting it to "Camera (PTP)" works but means dealing with multiple popups and having to change settings every time you plug in USB.
Comment: This worked for me on Mac while trying to use the Build and Run option with Unity.
Comment: Trying to use adb from command line on Mac. This was the only solution I could find.
Comment: thank you, MIDI device option worked for me and as soon as I chose that, it immediately asked me to accept the RSA key and it worked right away after that.
Answer: For me, this has solved the problem: simply go to LG's website, http://www.lg.com/us/support/software-manuals, select the model (I have selected 'D850') and go to Software Updates tab where you can download the driver. I have installed it and then Eclipse recognized my device. I'm working on Windows 8.1, by the way.
yakobom
Comment: Thanks, that worked for me! I have LG-D855 and D855 is not listed. I tried D850 or D852 and it worked for me.
Comment: the only solution that worked for me too. Windows 7 here
Comment: Great. Actually, I had to do this in several computers since the first time, and this solution is the only one that have worked for me.
Comment: Windows 7 / Android Studios user here.  Your solution worked for me, when all others failed.
Comment: This fixed it for me - although to get the drivers for the D855 I had to go to the UK site (the US one doesn't display drivers for this model)
Comment: on Windows 7, I went to http://www.lg.com/uk/support/software-manuals and downloaded the usb driver for windows. The following link is for LGD855 http://tool.xcdn.gdms.lge.com/dn/downloader.dev?fileKey=UW00120120425   it's a 12.5MB file. I hope there's not going to be a bunch of junk in it. NOTE: after you plug in your LG G3, wait a couple of mins whilst windows does something with the drivers. Then the phone shows in DDMS
Comment: thanks my friend , wasting time on crazy solutions , just simple :)
Answer: After a lot of searching and trying all solutions still I couldn't connect my LG G3 to eclipse on mac. Finally I find this solution, it works for me hope for you works too:

Install LG USB driver for mac
Go and enable developer mode in your G3 (Setting->About phone (in General Tab)--> Software information --> Tap 8  times on Build Number) then you will see the message which says the Developer option is enabled
In this step you expect that after connecting your mobile via USB cable, the Eclipse detect it
But for me it didn't happen
in this step you need to go (Setting--> Developer Options--> and turn off this option from above green (on/off) switch then again switch on this option from same place (If you don't do this step the "USB Debugging" mode will stay fray and you can not enable it)
In Developer Options menu scroll down until find the "USB Debugging" then tic it and enable it.
almost finished , you should back and configure running mode for your application and see the G3 in your connected usb devices
Comment: on the mac, all I had to do was switch the USB connection to PTP
Comment: Step number four is what it did it for me. Who would've guessed. Thank you!
Comment: i was missing step 5, ticking  "USB Debugging" . i thought Top On/Off is enough. thanks.
Answer: Try this solution :

Right click on My Computer --> Properties --> Device Manager
Right Click on your device --> Update driver software
Click on "Browse my computer for driver software"
Give path of your android sdk like "D:\Android_Sdk\sdk\extras\google\usb_driver" and tick "Include subfolders"
Click
Now repeat the steps till "Browse my computer for driver software".
Then click on "Let me pick form list of device drivers on my computer". Click on the first option and click next and then click yes. Drivers will be installed for your device.

Hope this helps.
Comment: @Usman : Open up your sdk manager, then go to Extras section, check on Google USB Driver option and install it.
Comment: I tried it, the fist step the Driver was allready updated. right after the second step done the device itself asked me to install it drivers again and this time it worked... So i guess i should say THANK YOU!
Comment: there is no 'usb_driver' folder: D:\android_workstation\sdk\extras\google\  just 'google_play_services' and 'm2repository' folders. please help.
Answer: Change the USB mode to PTP and you will get the RSA prompt.
Within the prompt, select allow it > ok and you are done.
This worked for me when I had the same problem on a Mac computer.
Comment: The person asking the question references 'My Computer' -- something meaning they are using a Windows machine, not a machine running OSX.
Comment: this worked for me on windows 7, enable PTP to get RSA prompt. cool
Answer: To contribute to possible solutions for this fix: I am using an LG G3 on a Mac.
In my case, ADB saw it as a device when I checked, and the Mac showed the device information in the System Information window, yet Eclipse did not see it. I also did not get the RSA confirmation pop-up when I connected the device through USB.
To fix, with my G3 connected, I selected the USB PC Connection (either from the navigation bar or through the settings) and changed it to be Send Images (PTP). Once this was on, I was given the RSA pop up and Eclipse recognized the phone in the Run Configurations window.
Comment: Using PTP worked for me as well. Not sure why none of the other solutions worked, this is a strange bug.
Answer: If you have this problem on Ubuntu; here is what I did to get it working:

Switch to PTP from MTP on the phone (this assumes you're connected via USB)
Disconnect the USB cable
Go to settings -> developer options and select revoke usb authorizations then ok
Make sure USB Debugging is checked
Reconnect the USB cable and your phone will say its connected as an installer; wait a minute or three and debugging mode should appear on the status bar (on the phone)
Open Eclipse and go to DDMS
Select "reset adb" in the dropdown if your phone isn't appearing yet
Comment: Thank you! your instructions worked for LG Leon too.  I was missing Google USB (usb_driver) in sdk/extras/google folder  http://developer.android.com/sdk/win-usb.html
Answer: Working on Windows 7. All of the solutions from other sites didn't help (i.e. restarting adb and switching between MTP, PTP, Charing).  In the end, I found this article (http://www.technobuzz.net/install-lg-g3-lg-drivers-windows-mac-usb-adb/), which contains links for the necessary drivers for the lg g3 (and some others I think).  This did the trick and made the RSA key fingerprint dialog appear finally.  After confirming, adb and eclipse recognize my device perfectly!
Answer: I had this buggy error with my LG Optimus L3 phone connecting to Win7/8 machines!
Cause: Device Driver was missing as it seemed at the end when I fixed it!
How to Fix:

Search through web (using Google) "LG < Your_Phone_Model Number > Drivers Download".(Ex.:- Go to About phone in your settings list > Model Number, for me it's LG-E400f)
Mostly the first few links are related to the required Device Driver download page.(Ex.:- for me I got the following link and for each device driver LG or most of the other vendors/manufactures have that kind of a Manuals and Drivers Page) Visit that page mentiioning about software update and drivers downloads.
Scroll down to the section of "Manuals and Software Update" and doing just the Step 1 was enough for me, which is "Install the USB DRIVERS "
Download it(for Mac or Windows) > Install It > Check Your Eclipse ADT > and it should be visible under Devices tab by now

Cheers!!!
Hope this helps to someone else to clearly get to the solution!
Answer: it seems that Eclipse shows the offline mode for lg G3 and some newer devices
and there is no way no use these devices for ADB debugging
there is a way
I am using windows 10
1- download this 11 MB file < http://dl2.uncox.com/android/upload/platform-tools-v22.zip>
2- then go to the directory that you installed the SDK
3- extract the zip file in to the platform-tools folder , override all files(click yes to all) be sure that Eclipse doesn't running
4- open Eclipse and select your android device that stands in devices tab at the right-top corner of your screen and then you can see the arrow near the screen- capture icon and you will find the reset-ADB. click on it ,after that your phone will ask you to allow android debugging for your device click on it
5- congratulations .now you can see that your device shown online
i hope this will help .sorry for my english
Answer: I also had a great deal of trouble when attempting to debug android applications on my shiny new LG G3.  What ended up working for me was first installing the default google drivers onto the G3 and then following the process detailed by @lilbyrdie.
The process of installing the google usb drivers is very nicely gone through here.
However, with the most recently pushed android update to the G3 there are no longer the options for internet connection or charge only; but they seem to have fixed this defect forcing you to make this odd choice to enable debugging.  The only options remaining are MTP and PTP, but if you pull down the notification drawer, choose the 'USB connected' notification (assuming the device is connected to your computer via USB of course) and from there click on 'Media sync (MTP)' even if it is already selected then debugging should be enabled.
Comment: Is there a way to avoid the two popup dialogs this opens on the host PC?  (On my setup, this opens up a Finder window when I plug in to USB, and an "Image Capture" window when I switch the mode.)
Comment: For anyone hitting the same problem, I managed to at least solve the Image Capture popup with this: http://debugfix.com/2011/11/os-x-image-capture-opens-plug-iphone/
Comment: And to get it to connect straight into MTP mode instead of the useless "installer" mode, these instructions: "Open the stock dialer app, then enter the code "##3328873" and press send. It'll prompt for a service code, which is (of course) "000000". While the Verizon G3 appears to be missing a large chunk of the hidden menus, this section still seems to work. One of the options is a checkbox for "Tool Launcher enable" - uncheck it to disable the Verizon autorun installer." -- Source: http://forum.xda-developers.com/showpost.php?p=55725408&postcount=1
Answer: Android can't update on the fly the developer mode. So, after turning on developer mode (and given you have the latest driver) switch the green button(under settings->general->developer options) to off and then back on. Then turn debug mode on (after that windows recognizes a new device) and you should be good to go.
Answer: In my solution for Windows 7 was helpful to update Android SDK Tools to latest version.
Answer: ADB Single/Composite values for LG G3 phones -
I found it was necessary to update (~userName/.android/)adb_usb.ini file with the line 0x1004:
# ANDROID 3RD PARTY USB VENDOR ID LIST -- DO NOT EDIT.
# USE 'android update adb' TO GENERATE.
# 1 USB VENDOR ID PER LINE.

0x2207
0x1004

In addition, I needed to add the following entry in (.../sdk/extras/google/usb_driver/)android_winusb.inf:
;
; Android WinUsb driver installation.
;
...
[Google.NTx86]
...

;LGE Android Phone
%SingleAdbInterface%        = USB_Install, USB\VID_1004&PID_633E
%CompositeAdbInterface%     = USB_Install, USB\VID_1004&PID_631D&MI_00
%CompositeAdbInterface%     = USB_Install, USB\VID_1004&PID_631D&MI_01

[Google.NTamd64]
...

Oh, and set USB to PTP as well as turn-on USB debugging.
When you're all done with the file modifications and several passes at installing the drivers (ref. earlier posts), you can verify your phone is ready via the Device Manager.  It will list your phone as "Android Device"->"Android Composite ADB Interface".  I believe an earlier post explains setting up the drivers


How to hide development work from a not so trustworthy fellow farm admin or site admin?

Question: Unfortunately there are some unfriend-lies out there even in your own circle who doesn't mean your work or progress well. Sometimes even a service account has been used to peer in and worse.
Is there a way to hide/safeguard dev work ( SP 2010 Workflows, sub-sites and InfoPath forms ) only meant for me to finish , away from those folks ( in any shape or manner without breaking paths too much ) before completion and unveiling .
Comment: If  someone has access to a service-account, they would in theory be able to access anything. If you have someone ruining your stuff, you should get to the bottom with the actual problem. Or you could make it a habbit to backup your site collection often where you develop stuff so you know that you always have a backup of your work if anything "would happen".
Comment: Thank you Jussi you are right however are there any tricks to make your work a little more covert? The problem leaves me to find a solution for myself since the Admin is the Manager's "favorite" and because of it he abuses his authority. Doesn't leave much for me to after I approached and professionally made the complaint and was basically ignored. Obfuscation, Password the folder, etc?
Comment: Create your own dev machine. Not sure how you are versioning the WF and IP forms but if they are stored in source control that they will be visible anyway.
Answer: Outside of your own Dev environment like Marek suggested, you can hide things by keeping them in draft mode - so if you're creating a new sub site, don't check it in (in the case of a publishing site at least) just hit save. You'll still be able to browse to it, however not even site admins will be able to see it.
Same with workflows and Infopath forms - hit save, but don't publish. It makes it incredibly hard to test however, because you will need to publish before you can test it properly.
Sounds like you're in a terrible situation, and I'm sorry to hear it.


Do Christians need to keep the Passover?

Question: Do Christians need to keep the Passover on the 14th day of the first month? If not, why?
Comment: Whose point of view are you seeking?
Comment: What @Anonymous is saying is that not all Christians agree about everything, including observing the Law of Moses.
Answer: No, paticularly if you are not a Jewish (Messianic) Christian.  The outcome of the Council of Jerusalem is quite clear - Gentile (non-jewish) believers do not need to follow Jewish customs or ceremonial law with the following caveat:

...It seemed good to the Holy Spirit and to us not to burden you with anything beyond the following requirements: 29 You are to abstain from food sacrificed to idols, from blood, from the meat of strangled animals and from sexual immorality. You will do well to avoid these things... (Acts 15:28-29 NIV)

In the case of Messianic Jews, there is no necessity to keep the Passover to satisfy a  legal requirement (Christ has completely fulfilled the ceremonial law), but it is quite legitimate for them to observe the Passover out of a desire to preserve their Jewish culture and to identify with their fellow Jews - to which the Apostle Paul gives them a good example and relevant instruction:

To the Jews I became like a Jew, to win the Jews. To those under the law I became like one under the law (though I myself am not under the law), so as to win those under the law. (1 Corinthians 9:20 NIV)
Comment: It doesn't matter whether you are a Gentile or Jewish Christian. No Christian is under the Law; no Christian is obligated to keep the Passover (nor is such a thing possible without the Temple).
Comment: @H3br3wHamm3r81 Thanks for the comment and I wholly agree - do you regard my edit as sufficiently expressing this point?
Comment: Please!! The Passover was kept without the Temple (before the Temple was built and during the exile) but there was and is no lamb on the menue.
Answer: The short answer is no, because Christ fulfilled the Passover.  He is the true Passover Lamb, the "Lamb of God, who takes away the sin of the world" (John 1:29, cf. Revelation 5:6).
In the Old Testament, the Passover was instituted the night the Lord led His people Israel up out of captivity in Egypt.  The blood of the Passover lamb was placed above the door frames and post of the homes of the Israelites to mark them as the Lord's people.  This mark of the blood of the lamb caused the angel of death to "pass over" the Israelites, saving their first born sons from death (Exodus 12:21ff).
This was pointing forward to what Christ would do on the cross.  He came as the true Passover Lamb, marking us with his blood, and causing eternal death to "pass over" us, thereby freeing us from captivity to sin and death.  In fact, just as the Israelites ate the Passover Lamb, so too does Christ institute a Supper for himself; in the Lord's Supper we eat the body and blood of Christ which was "given up" and "poured out" for us (cf. Matthew 26:26; Mark 14:22; Luke 22:19; 1 Corinthians 11:24).
So, just as Christ fulfilled the Sabbath for us (by resting in the tomb) and all the commandments by being perfectly obedient, even unto death (Philippians 2:8), so too does he fulfill the Passover, completing what it pointed to.


Pepper plant leaves turn brown with white spots

Question: I live in the pacific north west, I have some pepper plants that got infected with a weird disease that I can pin point. White spots that are in clusters sometimes and the leaves just turn yellow and brown.
Comment: is there anything that moves on the underside of the leaf?
Answer: Take a look at image number four at this site. I think this clearly resembles your photo. The conclusion is whiteflies
From wiki:

The eggs of Aleyrodidae generally are laid near each other on the food
plant, usually on a leaf, in spiral patterns or arcs, sometimes in
parallel arcs.

This source suggests a cure:

Whiteflies are resistant to chemical insecticides. Instead, use a
homemade remedy of 1 tablespoon liquid soap, two parts rubbing alcohol
and five parts water.
Spray this solution onto the plant's leaves to kill and prevent
whiteflies.

If you have healthy plants too, then quickly remove/destroy the damaged ones and save the treatment for later minor attacks on those you kept.


The difference between "came in slow" and "came in slowly"

Question:
The big breakers came in slow.
The big breakers came in slowly.

Are there any differences between the two sentences?
Answer: "Slow" and "slowly" are both adverbs but they are not completely synonymous with one another. A usage note at the entry for the adverb slow in Merriam-Webster's Collegiate Dictionary explains:

Slow is almost always used with verbs that denote movement or action, and it regularly follows the verb it modifies  (beans . . . are best cooked long and slow —Louise Prothro). Slowly is used before the verb (a sense of outrage, which slowly changed to shame —Paul Horgan) and with participial adjectives (a slowly dawning awareness . . . of the problem —American Labor). Slowly is used after verbs where slow might also be used (burn slow or slowly) and after verbs where slow would be unidiomatic (the leadership turned slowly toward bombing as a means of striking back —David Halberstam).

No, there is no difference in meaning between your two sentences.
Answer: In this sentence most people would say slowly, but there is no difference in meaning.


How do I cite programming manuals and software user guides in IEEE

Question: I have seen posts on citing documents, but none of them have specified IEEE format in particular. So here is my question. How do I cite technical reference manuals and software user guides in the IEEE format for references?
Comment: Which IEEE journal or conference are you writing this paper for? That venue's site should have instructions on details beyond simply using the IEEE citation style in LaTeX.
Comment: I am writing my Masters thesis
Comment: I would talk to your school then. They will have further information, but I doubt they care too much one way or the other as long as it looks presentable.
Answer: The IEEE Style guide gives the following format for citing reports:

The general form for citing technical reports is to place the name and location of the company or institution after the
  author and title and to give the report number and date at the end of the reference.
  Basic Format:
[1] J. K. Author, "Title of report," Abbrev. Name of Co., City of Co., Abbrev. State, Country, Rep. xxx, year

For handbooks:

[1] Name of Manual/Handbook, x ed., Abbrev. Name of Co., City of Co., Abbrev. State, year, pp. xx-xx.

And online sources:

[1] J. K. Author. (year, month day). Title (edition) [Type of medium]. Available: http://www.(URL)

For example:

[1] J. Jones. (1991, May 10). Networks (2nd ed.) [Online]. Available: http://www.atm.com

Examples for manuals/software:

[1] L. Breimann. (2003). Manual on Setting Up, Using, and Understanding Random Forests v4.0. [Online].
  Available: http://oz.berkeley.edu/users/breiman/Using_random_forests_v4.0.pdf, Accessed on: Apr. 16,
  2014.
[2] M. Kuhn. The Caret Package. (2012) [Online]. Available: http://cranr-project.org/web/packages/caret/caret.pdf

Side note: this answer comments that in BibLatex you can use <code>@software</code> to generate the correctly formed citation. I'm not sure however if this is supported by the IEEE style templates.


What color are stars?

Question: I know that the sun looks white to us because it emits a large variety of color, making it appear white to our eyes but does this mean that all stars emit a variety of light? If so, then how can we know the temperature of the star (relating to it's color)?
Answer: I think that you should first read some of the answers to the question Why do metals only glow red, yellow and white and not through the full range of the spectrum? which explains the colours that we observe when viewing hot objects.
So although stars emit a range of wavelengths they do not all appear to be white because the colour of a star depends how much of each wavelength it emits which depends on the surface temperature of the star.
So Betelgeuseis a relatively cold star with a surface temperature of approximately $3,500\, \rm K$ and when observed from the Earth appaers to be red whereas Rigel with a surface temperature of approximately $11,000\, \rm K$ is seen as a bluish white star.
When star light is viewed from the Earth's surface the atmosphere complicates matters as does the absorption of certain wavelengths in the upper atmosphere of the stars however to a reasonable approximation one can say that the radiation (not just visible light but also infra-red, ultra-violet etc) emitted by a star is the same as that emitted by an idealised hot body called a black body.
The variation of light intensity as a function of wavelength is show below but not that in this graph the wavelength decreases as one moves to the right on the wavelength axis.

The "fit" for the the Sun's spectrum (red) compared to a black body at about $5,800 \, \rm K$ (orange) is shown below again wavelength is decreasing to the right where wave number is $\frac {1}{\rm wavelength}$.

Notice that the peak of the spectrum moves towards a smaller wavelength as the temperature increases.
For black bodies there is a relationship between the wavelength of the peak in nanometres ($10^{-9}\,\rm m$) and the temperature in kelvin called Wein's law.
$$\rm temperature\, (K) = \frac{2897000 \,\rm (K\,nm)}{\rm wavelength \,(nm)} $$
So by finding the value of the wavelength at the peak of the spectrum from a star one can estimates its surface temperature.
Here is one for you to try with a linear wavelength scale which comes Page 55 of NASA Space Math V and the answer is on Page 56.
Answer:
but does this mean that all stars emit a variety of light?

Yes.  All objects emit a spectrum of radiation, dependent on their materials and temperature.  If the temperature is high enough, some of the emission will be in the visible band.

If so, then how can we know the temperature of the star (relating to it's color)?

While the sun emits radiation of different colors, the power of each is not the same.  This spectrum changes as the temperature changes.

Our eyes are able to discern large shift in this spectrum.  A very cool star appears red, a very hot star appears blue.  But by using more sensitive instruments, fine differences in the spectrum can be recorded, which correspond to relatively small differences in temperature.
Answer: The stars we can see and study with telescopes emit a variety of colors of light. But because they are predominantly made up of the same substances, the colors they possess are well-accounted for by differences in their surface temperatures. In this regard, they all display the same well-known correlation between temperature and color that all hot objects possess. This allows astronomers to determine the temperature of the star fairly accurately, even if it is extremely far away from us.
Comment: @safesphere, I purposely tailored my answer to the background level I perceived in the OP's question.  Kindergarten was 60 years ago for me but to the best of my recollection I was not taught anything at all back then about the relationship between the blackbody spectrum and the color of a star.  You might think that a downvote was "well deserved" in this instance but I would submit that even if this was true, there would be literally dozens of different ways to convey that particular sentiment to me in this public place which would not be nearly so insulting.
Comment: I didn't downvote. Many people other than the OP read answers here. You can always split the answer into simpler and more advanced parts if you prefer, but an answer that just rephrases the question without actually answering it is not worth posting. Sorry for the earlier comment, no harm intended. I've deleted it.

What color are stars?