Why I can't detect Media Queries in IE9 using modernizr

Question: I searched support of CSS3 Media Queries in browsers, and IE9+ support it, http://caniuse.com/css-mediaqueries, but when I use Modernizr to detect it, it turns out, ie7-ie9 not support it, ie10 support it.
What I do is :

generate custom modernizr js: http://modernizr.com/download/#-mq-teststyles-load
html code: below is my code in the html head, I want to detect if the browser support for the min-width media query use, if it support, add support.js, if not, include nosupport.js

In support.js: alert("support");
In nonosupport.js: alert("not support");

Result: ie7-ie9 alert "not support", in ie10, alert "support". I think ie9 also should alert "support", right?
Is there something wrong with my code?
Another weird thing is if I USE the sample usage from http://modernizr.com/docs/#mq
:
Modernizr.mq('only screen and (max-width: 768px)')  // true

Chrom, firefox and IE7-10 will alert "not support", I think modern browsers should alert "support". Why?
Answer: On your first question - I am not able to replicate. Modernizr.mq('(min-width: 0px)') returns true in IE 9 for me. Check your document mode in the F12 tools to see if you are falling back to a non standards mode.
On your second, browser modernness has nothing to do with wether or not it will return true. Modernizr.mq tests if the browser matches a media query. If it is false, that means that the browser window is larger than 768 pixels.


In a products collection have addAttributeToFilter 'check' child products of a configurable product?

Question: For our API we have an option to use filters, these work great so far and are pretty simply made with the addAttributeToFilter function.
However, the problem is that when a configurable product has a child product with an attribute which indicates that it's blue, and I filter the products on the color attribute with the corresponding blue filter value, it also filters out that configurable product.
We'd like to have these configurable products in our response, but how? I've seen suggestions to use addFieldToFilter, but that gives the same results.
Comment: So, you want to have both the child product and parent(configurable) product available after applying filtering.. right?
Comment: @Mr_Green Yes, and I want the filter to look 'inside' configurable products to see if it matches one of the available child products
Answer: If the child products you are mentioning are simple products then you can do the following:
Include this function:
<code>public function getConfigurableProductsFromSimple($filteredProducts){
    $configurableProducts = new array();
    foreach($filteredProducts as $simpleProduct){
        $parentIds = Mage::getResourceSingleton('catalog/product_type_configurable')
                     ->getParentIdsByChild($simpleProduct->getId());
        $parentId = $parentId[0];
        $configurableProducts[] = Mage::getModel('catalog/product')->load($parentId);
    }
    return $configurableProducts;
}
</code>
and then change your filtered products something like this:
<code>$filteredProducts = $this->getConfigurableProductsFromSimple($filteredProducts);
</code>
Comment: The issue with this is that the total product count of the collection would not be correct any more and the API call could become very slow


I am sorry, I am  and I am happy usages

Question: When someone asks our name, we use I am [name]. Also, we use I am to express our feelings, like I am sorry, and I am happy. So do we use I am for both our identity and our feelings?
Comment: 'I am' is **never** called a _prefix_; that term is already taken and universally agreed upon in linguistics. The copula _be_ is very commonly used to show identities ('I am John') and states ('She is cold') (_be_ is used in other ways; it's very versatile). // Though 'He is a disciple _and_ a leader' and 'I'm tired and hungry' are totally acceptable, a mixed statement ('I'm a leader and angry') is not.
Answer: Yes. Unlike some other languages (eg Spanish, Japanese), English uses the same copula be for contingent properties, innate properties, identity, and sometimes location:

I am happy (contingent or transitory property)
I am human (innate or permanent property)
I am Colin (identity)
I am in my house (location).
Comment: great. the words late, right and wrong does they belong to contingent or transitory properties?. Like, i am late, i am right, i am wrong....etc...
Comment: Given that I've just pointed out that English doesn't distinguish these kind of properties, I wonder why there is any point in asking this question here. But I would say that none of them is innate or permanent (though some people act as though being "right" is a permanent attribute that they have!)

I am sorry, I am  and I am happy usages


RAID on HSM network

Question: I want to implement a network of HSMs to secure millions of private keys. To increase fault tolerance and speed, I would want this network to run RAID 50 (striping, parity and duplication). As I understand, one of the key point of HSMs is that they never share their keys. Does this mean that I just cannot run RAID (because I cannot replicate keys)? Or that "normal" server network with some crypto software would be just as good as a HSM network for this purpose?
Comment: Why are you trying to store so many keys?
Comment: Why would RAID 50 and your HSM have anything to do with each other? Your HSM doesn't care whether you have a single hard-disk or a pile of disks RAIDed together.
Comment: Business idea with many clients, each having at least 1 key.
Comment: I'm going to guess that if you could use the same seed, you could store the key on multiple HSMs. I hope you have a big budget though - this is going to hurt.
Comment: @StormChaser does the business idea require that all signing with the client keys happens only on your systems (your HSM) and the clients themselves won't be able to retrieve/see/use those keys directly themselves?
Comment: This is still very hypothetical, but yes all signing would happen in-house. After reading the answers below, I now understand that that many keys are probably better stored out-HSM
Answer: Yeah, don't.  That is to say, don't assume you will be storing 1m+ keys on an HSM, regardless of who made it.  HSMs are not hard drives.  Don't use them like one.
Some HSMs support external keys.  These are keys which are encrypted/wrapped using a specific AES-256 (for example) key, derived from some other key.  This 'master' key derivation key remains in the HSM.
Store your 1m+ keys on a raid array, or using an RDBMS, or hadoop, or whatever.  It. Does. Not. Matter. from the viewpoint of the HSM.  What matters is the latency on searching, finding, reading and sending the key to the HSM for decryption and use.
Most HSMs provide a way to cluster, so that if one HSM isn't fast enough for your use case, you can gang a second (or third, or fourth, or Nth) next to it.  These cluster machines use the same master key derivation key, so any one of them can decrypt the key, use it and discard it, without ever exposing it or risking compromise.
I've generated 1m keys (RSA 2048) on a cluster of HSMs of different speeds (I think there were 10, but it was what was in the lab at the time, and it was on a lark so I wasn't keeping notes).  It took 10 hours to generate them.  Used a MySQL instance in a VM for storage.
Answer: Do the keys need to be in the HSM?
Scenarios like this often are solved by not having a million separate secrets in HSM, but by having a million encrypted secrets and having a HSM decrypt them if needed.
In your mind, what's the conceptual difference between secure storage and use of a million keys versus a million passwords (assuming that they need to be recoverable for some reason), or a million creditcard entries?
Answer: HSMs are available that are built for this usage, look up "clustered HSM".
Another option is to have a regular security database that is protected by the HSM (either a card in a slot, or available on the network).  You could then use one or more HSMs to protect your high availability certificate storage servers.  Of course depending on your actual requirements for key storage this might not be acceptable, but it should be less expensive than clustered HSMs.
Keep in mind that you can duplicate HSMs.  Consult the manufacturer, but they have procedures for doing this for a variety of circumstances.  In fact you may want to simply consult with several manufacturers regarding your needs entirely, they may have solutions you've overlooked.
Answer: There are purpose built HSMs in the market for this very requirement. With these HSMs you only store your KEKs (key encryption key) in the HSMs, the actual key / customer data is encrypted by the KEK and stored in a relational database - outside of the HSMs. Whenever the data needs to be decrypted, the request to the HSM is sent along with the data (from the database, encrypted under the KEK) and the handle / identifier of the KEK to be used for decryption. The operation is completed by the HSM in its secure environment and the response sent back to the requesting application.
Thales nShield HSM is one such device available and you are only limited by the size of your database, enabling you to store as many keys / data encrypted under the protection of a master key (KEK) on the HSM.

RAID on HSM network


How to use existing Whatsapp account on new mobile with new SIM?

Question: I could not use my existing whatsapp account because My mobile have been stolen. I bought new mobile and new SIM as well, now I want to configure my existing whatsapp account on new Mobile with another SIM number. Can anyone please help me?
Answer: You cannot use your old Whatsapp account with new sim when you don't have access to your old number.
All you can do is to contact your network provider and explain the situation, submit documents and request a new sim with the old number. Once you get your old number back, you can either choose to use whatsapp account with it or shift the account to new number.
Shifting Whatsapp account to new number maintains the old account's whatsapp groups, account info, settings. You still have to share your new number with your contacts so they know its you and update their address list.
To shift the WhatsApp account from old number to new number, login whatsapp with old number and open Settings >> Account >> Change number .


Jackrabbit Observation with Spring

Question: I am new to observation, although the repository supports observation,
onEvent() is never invocked. Here're the details:
I created a Param class, and it's just a POJO with setters and getters
hasing properties that each represents a parameter for:
ObservationManager.addEventListener()
I careted an interface XListener that extends EventListener, and defined a
method: Params getParameters().
Crated MyEventListener implements XListener and implements the
getParameters() and onEvent()
getParameters() just populate a Param object (with NODE_ADDED) and return
it to be used later to add this listener,
and onEvent() currently it only prints out a message NEW NODE ADDED.
Then created a new class ListenerRigistrar and added it in the
applicationContext.xml for Spring with a  which is a set
of XListeners.
Added a new bean for MyEventListener.
back to ListenerRegistrar, I iterate over the set of listeners and use the
Params object embeded with the listener to call
ObservationManager.addEventListener()
The problem is that the message NEW NODE ADDED is never printed means
onEvent() method is never invocked!!
Can anyone help me please?
Thank you in advance.
Answer: I would say the problem you have is that your ListenerRegister is never being invoked (looks like it's simply declared it in the application context).
As you're using Spring and JCR, I suggest you use Spring Modules, and follow these instructions.
Good luck,
--dj

Jackrabbit Observation with Spring


Is it possible to disconnect a bluetooth connection using Applescript?

Question: I want to disconnect a connection to a bluetooth device through an Applescript. Please note that I don't want to disable or enable bluetooth, I just want to disable one specific connection.
Answer: Here is what I use for disconnecting my Samsung Soundbar. Also remember that you need to give permission to application to use SystemUIServer steps for that.
System Preferences > Security & Privacy > Accessibility > [name_of_your_application]
One little remark: you need to have bluetooth icon on your menu bar.
tell application "System Events" to tell process "SystemUIServer"
    set bt to (first menu bar item whose description is "bluetooth") of menu bar 1
    click bt
    tell (first menu item whose title is "[Samsung] Soundbar") of menu of bt
        click
        tell menu 1
            if exists menu item "Disconnect" then
                click menu item "Disconnect"
            else
                click bt -- close main dropdown to clean up after ourselves
            end if
        end tell
    end tell
end tell

Comment: Works well.  I wouldn't have thought to do it via the menu bar, but it works great.  Thanks man.
Answer: Bluetooth functionality isn't made available through the Mac OS APIs (System Events being the chief one for things like this). You should be able to do this with GUI scripting (a great intro can be found on the Mac OS X automation site), but this is a really wonky way of doing it and is error-prone (unexpected dialog windows being the single biggest problem).
Answer: Not sure if this will work, my bluetooth has been b0rk3d for quite some time, but
man networksetup

You should be able to say something like
networksetup -getInfo <interface>

and then you could use the vast array of tragically randomly capitalized switches to work your will upon your bluetooth device, which should be a network interface.
OR
You want to disable one connection, and one connection alone?
/sbin/ipfw -q add deny ip from <bluetooth interface> to [any|badguy.com]

Comment: I don't think this is the correct way. I'm not talking about a bluetooth PAN or something like this. I refer to a simple bluetooth connection between a Human-Input Device (HID) and my Macbook.


How to remove the archiving in Gmail

Question: Is there a way to get rid of archiving in Gmail? I don't want or need it.
Comment: What do you mean by getting rid of archiving?
Answer: You cannot disable archive, but nothing is forcing you to use it. You can move all your messages from Archive to Inbox by these steps:

Click "All Mail" on the left to open all email messages.
Click checkbox to select all messages.
As step #2 will only select messages you are viewing, you have to click "Select all XXX conversations in All Mail" at the top of your message list so it selects everything in "All Mail".
Click "Move to Inbox" in the toolbar.

Now you have all your messages in Inbox and Archive is not used.
Comment: The problem is in new gmail GUI, The Archive button float on the mail title so It's very easy to wrong click it, and if you don't notice to click `undo`, you will waste your time to search how to unarchive your mail, **everytime** you do it because you can't remember how to unarchive your mail.
Answer: You can remove the archive button by:
click on the settings cog >> settings >> general >> hover actions
then change it from:
<code>Enable hover actions - Quickly gain access to archive, delete, mark as read and snooze controls on hover
</code>
to
    Disable hover actions
(I kept accidentally archiving too, it was very annoying!)
Comment: That works well for the buttons Google added in the recent redesign, but the Asker seems to have been looking for a way to remove the functionality altogether.

How to remove the archiving in Gmail


Is my kimchi still okay?

Question: My kimchi (still in the fermenting crock) tastes very vinegary.   Is it still good to jar & refrigerate?   I've made it a number of times throughout the winter (our home is old & cool).
Comment: How did you make it?
Answer: IF you've made it with the correct amount of salt, it is likely fine.  Kimchi (all lacto-ferments) will continue to ferment.  It may get too funky for your liking, but it will not be a hospitable environment for anything that will make you sick. It will not "go bad", in the sense that it could make you sick.  If it was under salted, all bets are off.  If it gets slimy or is growing fuzzy mold, you probably want to discard.
Answer: Kimchi will continue to ferment and get sour over time. This is perfectly normal, provided you made the kimchi correctly. If it gets too sour for your taste, it's time to use it in other foods:

Wash it and use it as a wrap (ssam)
Use it in stew (kimchi jjigae and budae jjigae)
Use it in dumplings, Korean pancakes (buchimgae) or fried rice (bokkeumbap)

In fact, people will sometimes store the kimchi at room temperature to quicken the souring process, so that they can use it to make these other dishes.
Answer:
My kimchi (still in the fermenting crock) tastes very vinegary. Is it still good to jar & refrigerate?

Yes. This is perfectly fine. Thanks to lactobacillius, kimchi ferments even after you put it in the fridge, but at a much slower rate. The extra strong, vinegary taste that you mentioned is most likely a sign of mild over-fermentation, which isn't a bad thing at all; it just means that the kimchi will smell and taste stronger, and might have a stronger effect on your stomach.

Is my kimchi still okay?


VBA - Accessing and looking up values in CSV files efficiently

Question: I am working on a complex model that needs to lookup values in a series of distinct tables.  If I embed all of the information in the model itself, then the file quickly becomes unwieldy.  I am hoping to find a solution where I can have a series of CSV files that contain all of the lookup tables, and then have my VBA code just quickly read each CSV file as necessary and return the appropriate value.
My initial thought is to read each CSV file in working memory as needed, lookup the necessary values, then discard the information once the lookups are complete. Is that most efficient way to do it?
Comment: Could you load all your lookups into memory for the whole session, or would they be too large?  What kind of lookups are you doing - just two-column or can the lookup value be from one of a number of columns?
Comment: The lookups can be from multiple columns, but primarily just two-column stuff (or, more specifically, looking up the different 2-column combos in the same table multiple times - matching columns A and C, then B and D, then A and E, etc.)...I am not sure what memory limits are, but the tables are anywhere from a few hundred rows to 30,000 or 40,000 rows...
Comment: During a previous mission, I had excellent efficiency and reusability by creating a class module for each of the lookup file "types" I had to use. The advantage of this is that if the layout ever changes, you only have to update your class module. Additionally, if you work in a team, you can easily export and share those class modules.
Answer: Here's an idea which might work for you: load your csv file into a variant array the first time it's required, then subsequent calls will use the cached data.  You can lookup values in any column and return the corresponding value from any other column.
EDIT: updated to show how to populate lookup arrays from CSV files
Sub Tester()
    Dim arr1, arr2

    arr1 = CsvToArray("D:\Analysis\tmp\Data1.csv")
    arr2 = CsvToArray("D:\Analysis\tmp\Data2.csv")

    Debug.Print TestLookup(arr1, "lookup1", 2, 1)
    Debug.Print TestLookup(arr2, "lookup2", 3, 1)
    'bunch more lookups...
End Sub

Function TestLookup(arr, val, lookincol As Integer, returnfromcol As Integer)
    Dim r
    r = Application.Match(val, Application.Index(arr, 0, lookincol), 0)
    If Not IsError(r) Then
        TestLookup = arr(r, returnfromcol)
    Else
        TestLookup = "Not found" 'or some other "error" value
    End If
End Function

Function CsvToArray(filepath As String) As Variant
    Dim wb As Workbook
    Application.ScreenUpdating = False
    Set wb = Workbooks.Open(filepath)
    CsvToArray = wb.Sheets(1).Range("A1").CurrentRegion.Value
    wb.Close False
End Function

Comment: Thanks for the response - I like this method, but I am not sure I understand it completely...I see how this is function is doing the look-up with a dynamic 'lookin' and 'returnfrom' col, but I am not clear on how I read the data from a file into an array (forgive my ignorance).  I was thinking I would read each CSV into a user-defined type variable (I know file structures in advance) with a distinct variable array for each column.  I would then pass my type variable to the lookup function to return the appropriate match.  Is that compatible with this solution?  Thanks again!
Comment: See edits: I altered the lookup function to add the data array as a parameter.
Comment: Thanks again for the reply - I got this code working properly with my model.  My last question would be related to efficiency/performance - is loading the CSV file into an actual workbook going to be a fast way to do it?  My initial inclination was to read the file directly into an array through file scripting code - could you comment briefly on how efficient this method is versus reading the whole file into a giant string, for example, and then parsing the string based on the commas and new lines?
Comment: That's easy to test: if you're concerned about performance then you can easily run the relevant code in a loop and compare timings. I suspect opening the cvs as a workbook might be slightly slower, but maybe not if you factor in the time it takes to create the other approach.  ;-)
Answer: if you really have to do it in excel, then this is a method:
Function GetData(This As String, ResultCol As Integer)
Dim LastRow As Long

Application.ScreenUpdating = False 'Turn off screen refreshing

Workbooks.Open Filename:="E:\my_files\tables.csv" 'Open the CSV file

LastRow = Cells.Find("*", SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row 'used for range in vlookup
GetData = Application.WorksheetFunction.VLookup(This, Range(Cells(1, 1), Cells(LastRow, ResultCol)), ResultCol, False)

Workbooks("Tables.csv").Close 'Close the CSV file

Application.ScreenUpdating = True 'Turn on screen refreshing

End Function


Is there a way to check when my Android screen was on and off?

Question: Is there a way to check when my Android screen was on and off? I am doing a medical control of when I go to sleep and when I wake up and the screen on/off is a great way of doing it.
Answer: You can setup an automation app to log those events in a file. Tasker and MacroDroid, both are capable apps that can do this.


Do security questions make sense?

Question: Is it a good practice, or is it obsolete? I'm asking because I've never managed to remember a single security question, thus I always write down the answers. I think they are useless, long passwords or 2FA is a much better practice.
Comment: Honestly, I think it depends with each user. On webites which require me to answer a security question I select the most obscure question I can and I just set the answer to some random characters (like another password) that way it's not something that could be SE'd (in theory). I am not convinced they help especially if you use the same password everywhere. (I don't and I don't really use social media so)
Comment: Security questions for what? As a second factor during authentication? Or for account recovery? Or something else?
Answer: The inherent contradiction of security questions
For a security question ot be good, it must:

Have one definitive unambigious answer that the user would never forget...
...but is secret and hard to guess for everybody else.

The problem is that the higher you score on #1, the lower you score on #2. So you have to walk a tight rope here. If you lean to far towards #1, users will forget the answer and brick their accounts. If you lean to far towards #2, anyone can guess the answer and the question becomes essentially useless.
There probably is no sweet spot here. So should we just ditch the whole concept?
Well, it depends.
When and how to use them
Security questions can be used in many ways.
Let's start with a very bad way to use them - as the only protection for account recovery and password reset. The answer to the question basically becomes a second password that is both easier to crack and guess than the first. That's just spectacularly bad. If you don't believe me, ask Sarah Palin.
That usage pattern is probably what have given security quesitons their bad name. But is there actually some other legitimate use case for them? Maybe. How about this:

As a poor mans 2FA for login or sensitive actions.
As a check before sending password reset emails.

In both cases, a determined attacker could find the right answers. But not all attackers are determined. A simple security question could make large scale automated attacks after big data breaches impractical. If I have a million passwords from site A, I can't just test them on site B if B also requires a security question. Or if I breach an email provider, I can't send a million password reset links from all sorts of sites, because I don't know the answer to the security questions.
The backside here is the contradiciton discussed above - the less obvious the answer to the security question is, the more likely users are to brick their account by mistake. There are better solutions here, like real 2FA or account recovery codes. But implementing 2FA can be hard, and so is getting your users to actually print and store those pesky recovery codes. So sometimes, for pragmatic reasons, a security question might a good compromise.
That is the best case I can make for them. I'm not sure if it's a good enough case to actually ever use them.
TL;DR

It's hard to construct good security questions, because the harder the answer is to guess, the harder it is to remember.
Still, security questions could be a useful complement to other efforts to protect against dumb automated attacks if you don't have the resources to implement better solutions, such as 2FA.
Answer: Security questions are a terrible idea.

There are no "best practices" like there are for passwords: a password should be hard to guess, long enough, etc. Are security questions any of that? By design, they are the opposite of secure: easy to guess, guessable using a dictionary attack or a list of last names, etc.
You may not want to let people access your account that know the answer to your security questions (my uncle knows my mother's maiden name, but I don't want them to access accounts of mine).
Anyone who knows the answer can become a target. To learn your first pet's name or your mother's maiden name, an attacker doesn't need to trick you to figure it out, they can trick it out of your grandma (or a bunch of other people) instead.
There are common answers. "Favorite food" was the question which I guessed for some people of whom I absolutely did not know their favorite food. Pet names and most other questions fit a nice probability curve.
You know the data format you're looking for: a mother's maiden name won't have an exclamation mark in the middle or be written in l33tsp3ak to make it harder to guess.
As a user, I needed my security question once and actually forgot my answer because it had been a few years. My favorite food had changed and I don't know what I put in there a decade ago. My password, on the other hand, I typically remember because I use it every time I log in. If I haven't logged in for a while, I don't know the password but definitely not the security question.

So not only are they insecure, they also don't reach their goal. Don't use secret questions, almost literally anything else is better.
Answer: As you can see from other answers on the same topic (searching for "security question" here returns several related questions), traditional security questions like "What's your mother's maiden name?" are now considered very bad practice.
Some websites, instead of traditional security questions, will ask for your phone number or an alternate email address. They might also regularly remind you to check if your profile info is up-to-date, to make sure you still use the email associated with your account, etc. Another way to check your identity might be to ask you questions about how you have been using the service, what private data the service is storing about you, etc. I'm not sure of all the things Google can actually ask you, but I'm pretty sure they can ask you the approximate date when you created your account, or the name of the city where you usually log in.
I still think that security questions can sometimes be useful as additional info, as long as you let the users write their own questions, maybe along with a clear and huge warning saying that they must not choose questions that can be answered easily by anybody else. But those security questions should not be an easy way to bypass the password login anyway. They should only be used as an exceptional way to help prove the user's identity, and the process should not be automated (a non-automated process might involve a phone call, for example).
Comment: +1 The important part here is that security questions can be used to assist non-automatic manual account recovery. And never ever automate account recovery solely by security questions.
Answer: It's better than no second-factor, but current 2FA standards recommend

something you know
something you have

A lot of banks use security questions or image-recognition because it's thought to provide an anti-phish protection, where once you are accustomed to seeing your image/ answering your security question, you will notice its absence.
This can of course be defeated by having the phishing site forward the username you enter, retrieve the question/image, and display it to you, but that's beyond what most phishing campaigns will do.
tl;dr Security questions are not good if used as client-verification, but they can be useful as server-verification, so that you can be reasonably sure the site you are logging into is the actual site.
This doesn't apply if the site makes you select the security question each time, but that's not what any banks I've seen using SQs do.
Answer: In a surprising number of applications a password + security question is considered 2 factor authentication. The idea is that its something you know whereas a password is expected to be something you will remember (I write passwords down too - but in an appropriately encrypted database!).
Yes, there are much better solutions - but the web developers of the world are not standing by waiting to write the perfect authentication mechanism to be used by readers of this website. There are lots of ways to complement (or improve on) password authentication, but they need something which does not inconvenience their users, is available to all their users, which doesn't cost too much, which doesn't span jurisdictional boundaries, which they can understand, which they feel they have some control over...
Comment: Password + security question is 1FA because both are something you know/remember. That would be same as splitting the password in two parts and pretending you have 2FA, except that splitting password in two parts would usually be safer because most people actually understand something about passwords. Second factor is biometric id, having specific encryption key or some specific device (e.g. TOTP).

Do security questions make sense?


Simulate website load on Node.JS

Question: I am thinking of creating my own simple load test, where I can hit my website with multiple requests (like 100-1000 concurrent users) to see how it performs. I want to try Node.js out, but I don't know if it is the wrong technology for the job, since Node.js don't use threads?
Can I with the async model that Node.js uses, simulate the many user requests, or would that be more appropiate to do in another language like Ruby/.NET/Python?
Comment: Is there a reason you want to use node, rather than the likes of [JMeter](http://jmeter.apache.org/) or [ab](http://httpd.apache.org/docs/2.2/programs/ab.html)?
Comment: I know there exists multiple frameworks for it, but I do it mainly for 2 reasons. To improve my programming skills (it is just a small hobby project), and to be able to test ajax calls (I don't think too many of the tools have that option, since they don't interpret the Javascript)
Answer: Node can fire off pretty much as many requests as you want it to (though you may have to change the defaults for http:Agent). You're more likely to be limited by what your OS can do than by anything inherent in node (and of course such limitations will apply in any other language you use).
Answer: Node.js ought to be perfect for the task. I do this at work. The one crucial piece that you will have to change is the http socket pool. The following code snipped will disable pooling entirely, letting you starve your Node.js process if you want to.
var http = require('http');
var req = http.request(..., agent: false)

You can read about this more at the http.Agent documentation.
Your concern about threads is astute, but even if you hit that limit (Node is very good at keeping your resources efficient) the solution is simple: start multiple instances (processes) of your load test. As it is, you may have to use multiple machines entirely to correctly simulate load.
In any case, you will not win automatically by using Ruby or Python for this. Asynchronous programming is ideal for I/O and network-bound tasks, and Node excels at this. Similarly, while Ruby and Python have third-party asynchronous frameworks, they're by definition more obscure than the standard asynchronous framework given in Node.
Comment: Thanks, also for the tip about disabling the pooling.
Answer: It's simple to create load tests with nodeload.

Simulate website load on Node.JS


How do I transfer files from my Android smartphone to my Windows laptop?

Question: How do I transfer files from my android smartphone to windows laptop?
NOTE: Bluetooth is working fine on both the devices and is in ON mode.
Comment: try AirDroid https://play.google.com/store/apps/details?id=com.sand.airdroid
Answer: There are a lot of different ways to get files to/from computer to Android device. Here I would like to share three methods frequently used:
1. Transfer Files Using USB Cable.
2. Wireless Transfer Using Cloud Storage.
3. Transfer Files via WiFi or Mobile Networks.
The following is the detailed intro of these three ways.
Transfer Files Using USB Cable
The most direct and simplest way to transfer a file from your PC to android phone is using the USB cable. Most of the phones we bought equip with a compatible cable, so there's no need for you to buy one. Just connect your PC and your Android using the cable, and you will see there's a message on the phone screen asking what do you want to do.
Choose the option that allows using the phone as a storage device, and you're good to go. Transferring file is as simple as copying the file from your PC to a USB drive.
Note: The exact format of the message varies, depending on the manufacturer or your telecom carrier of your android phone, but different roads lead to the same destination.
Wireless Transfer Using Cloud Storage
Cloud storage is famous for online collaboration and easily sharing data across multiple devices, like file servers, desktops and mobile devices. So using cloud storage to transfer files is also a convenient way. Most of the big players, such as Dropbox, Google Drive and SkyDrive, provide free spaces to users, which is big enough to transfer your commonly used files.
All you have to do is to register a free account. And install the PC client and app for your android phone. Each app designates a hard drive folder, and anything saved on your PC will be automatically synced to the cloud and other devices.
Transfer Files via WiFi or Mobile Networks
Some people may think connecting Android device to PC with the USB cable is annoying, or using the Cloud Services is not reliable enough, here I will introduce you another method, using WiFi. Most people have WiFi networks at their workplace or home, so it's really convenient.
There are lots of apps allow you to use the WiFi to transfer files. Let's take one of them-WiFi File Transfer -for an example. All you have to do is type a specific URL into the web browser of your computer, you can see your device's internal memory and SD card, from where you can download any files to your computer, or upload files to your phone.
Contrast of the Three Ways
The limit of WiFi File Transfer and Cloud Storage is the size of the file, the free version of these apps limit the file size. You can transfer the music, pictures, movies, word document, etc by above two ways. For files with large size, you can use the USB cable directly.
6 Ways (via Network) are here
Comment: Is there an app which i can install on my android smartphone and use the bluetooth to transfer the pictures from the smartphone to my laptop ?
Comment: I do not have an internet connection on my smartphone, but i do have an internet connection on my laptop.
Comment: I think you can send files from mobile to PC(which have a bluetooth antenna) without using any apps. Just do it as how you done with phone-to-phone.
Comment: +1. Thanks. Does using bluetooth on both phone and computer turn the phone into some server (web, ftp, ... server)?
Answer: If you are using Windows, USB should be your best bet. But several distros of Linux doesn't support MTP protocol (ICS and above) and hence, you can't mount your Android to those computers. There are a number of methods which you can use for wireless file transfers. My favorites:

Install Airdroid- This is a very simple app which converts your device into a lightweight web-server. After installation, connect your PC to your Android over WiFi hotspot or existing infrastructure WiFi network. Airdroid will give you a web address. Just type it in your PC web browser and you would get a nice file management interface for your phone.
Use any FTP server for android (like remote file management tool of ES File Explorer)- The connectivity method is the same as mentioned above. Here you can use FTP for file transfer over USB (Tethering mode) or WiFi (Hotspot mode). This is very handy if you're using Ubuntu (due to FTP client integration in Nautilus). In Ubuntu, press Ctrl + L and type the ftp://:/ in file path. You should get full SD card mounted as network drive.

I've been using the second method since past few months. Since android WiFi access point always gives the same IP, I've managed to put everything in a bash script to facilitate one click mount.
BASH Script:
#!/bin/sh
nautilus ftp://<device_ip>:<port_no>/

Don't forget to grant 'execute' permission to your shell script!
sudo chmod 777 <path_to_your_script>

Comment: Why 777? You can just `chmod +x`. 777 is bad practice.
Comment: +1. Thanks. Does using bluetooth on both phone and computer turn the phone into some server (web, ftp, ... server)?
Comment: Also I followed your second method, but it seems that I can't move a directory of my phone from my computer. What do I miss?
Comment: @Tim: Some FTP servers don't support recursive file operations. That's why you might be getting this issue. Are you able to copy and paste single file (from server to client)?
Comment: @Tim: Bluetooth file transfer is also based on client-server model. It uses a specialized object exchange technology, called OBEX, which facilitates file transfer over asynchronous radio link.
Comment: (1) I can copy and paste single files, but I can't move a directory. (2) Is OBEX an alternative to ftp or http?
(3) when turning the phone into a http server, we can't change the files in the phone, right? When turning the phone into a ftp server, we can change the files in the phone, but only subject to the constraint in (1)? How can we have full access permission to the files and directories in the phone?
Comment: OBEX is an object push technology and is a part of Bluetooth protocol stack. This however also depends on the type of Bluetooth profile supported by end user devices. OBEX is not supported in my Android device. So I rely on HTTP and FTP servers. It is possible to modify server side files over HTTP (the server may also use some PHP scripts to do so). Airdroid is an example. There are a lot of free FTP servers which support directory operations. I've been using my own FTP server which I wrote a few months back. You can use FTP tool of ES File Explorer to get full device access. It worked for me.
Answer: when you connect your android phone to the windows pc you will get notification in notification in notification panel of android .  Tap on it and choose mobile device (MTP) to browse  the  contents of your phone both internal and external memory will be shown .
the below link will give you a short description about it :
http://blog.armazine.com/2012/how-to-change-from-mtp-to-mass-storage-mode-in-android-xperia-ray/
Answer: Email yourself the files. It is often the easiest solution.
Comment: Easiest? Perhaps. Most time-consuming and inconvenient? Almost always.


Protection for Solid State Relay.. Advice please

Question: Please excuse me if this question is not appropriate for this site..
I wish to switch a Pool Pump using a Solid State Relay.. The pump is rated at 10Amps, 240 Volts AC.
Allowing for a safety margin, I intend to use a SSR rated at 20Amps...
My question is....Do I need to include additional components to protect the SSR from spurious inductive feedback from the motor.. Given the cost of high current SSRs, I consider it important to seek advice before proceeding!
Thank you...
Comment: What's the datasheet for the part you are buying recommend? Maybe the protection is built in already.
Answer: The most significant problem with starting motors is the high inrush current when they are first turned on and only dropping to rated current when the motor reaches full speed. Rather than estimating the needed safety factor yourself, you should buy a relay that is rated for starting a 240 volt motor with the power rating of your motor. A solid state motor starter would be better and include overload protection for the motor.


Use a powershell script on a webpart component

Question: can you tell me if it's possible to use a powershell script that would be used with a webpart component, as we can do with javascript scripts?
Answer: I'm not sure if I anderstand it right. But powershell is for scripting on the server. With powershell you can for example acces to to webparts and change their parameters from server console (shell, PowerShell ISE console).
May be you are asking about codebehind c# code, which you can use on on premis SharePoint (not in Sharepoint online).
I'm afraid you can't use powershell in webpart, but you can use c#, if you are developing your webPart.
Answer: If you're asking about running a PowerShell script from server-side of a Web part, that is technically possible but not recommended.
Here's how you can do it (you'll find a lot of articles on the subject on the Web): http://blogs.msdn.com/b/kebab/archive/2014/04/28/executing-powershell-scripts-from-c.aspx or https://stackoverflow.com/questions/11120452/run-powershell-script-from-c-sharp-application.
If your point is about running PS scripts on the client-side, this is not possible.


Shamir's Secret Share

Question: I'm not quite sure the benefits of working over a prime modulus in Shamir's secret share- but doesn't limiting the numbers you pull from make the secret easier to guess? Instead of being over the real numbers, with infinite elements, limiting yourself to some prime limits the possibilities-albeit that number can get very large.
Isn't this bad? What benefits are there to working over a prime that justify this choice?
Comment: A computer can't represent real numbers
Answer: Computers are unable to handle real numbers, especially irrational numbers.
Computers can handle a fraction of the rational numbers (for being limited in size in a binary representation), and without some special tricks it can't handle the entire field $\mathbb{Q}$.
So you're down to integer arithmetic anyway (if you consider floats: rounding and cancellation can really mess things up). However, addition and multiplication over integers are just a ring structure and not a field (multiplicative inverse elements do not exist). So if you need to invert multiplication you need to use the finite structure.
Answer: As long as computers have a finite amount of RAM, then they cannot handle infinite amounts of data.
Shamir's secret sharing is "perfect" in the following sense: it does not leak any extra information. When a threshold $t$ is used, an attacker obtaining $t-1$ shares learns nothing that he did not already know. But we assume that "what the attacker already knew" includes the set of possible values for the secret. For instance, the attacker may know that the secret is "a 128-bit key", which means that they key is any one of the $2^{128}$ possible sequences of 128 bits.
Since we use practical computers which exist in the real world, the attacker necessarily knows that whatever secret value we are handling must fit in a computer, thus be part of a finite (but huuuuuge) set of possible values. This knowledge is intrinsic; no amount of cryptography can change anything to that. If I tell you that "I know of a secret value" then I reveal that I know of that secret value, which implies that the secret value fits in the set of "things that can be known" -- in particular, it cannot be so large that I would not be able to store it or remember it, otherwise I would not "know" it.
While most of the above is rather empty, this still highlights the importance of taking care of your encodings. When using Shamir's secret sharing on a per-byte basis (by working in $GF(2^8)$), the size of each share (in bytes) is equal to the size of the secret value. So the size may leak information; thus, people who indulge in Shamir's secret sharing shall first agree upon an encoding of the shared secret which has a fixed length for all possible secret values. This is easy if the secret is, say, a symmetric key (a 128-bit key for AES). This can be a bit more tricky if the secret is a RSA key with ASN.1/DER encoding.
Comment: How does it not leak extra information? Doesn't knowledge of the other keys reveal some sort of divisibility criteria? If some attacker finds out that $(1,2)$ and $(2,1)$ are keys, won't he know that the polynomial must be of the form $(x-1)(x-2)$ and some other stuff? Does that not help at all?

Shamir's Secret Share


I'm stuck in the sky after respawning

Question: I'm a new Minecraft user. So I dug too deep into the void and died. Now I respawned in the sky and am stuck there. I tried dropping to the ground and I fall and it sounds like I hit ground, only I only fall a few feet below the clouds in midair. I had an awesome house build going. Is there a way to get back to the ground?
Comment: Is the world all black? Could you clarify with a screenshot? And you tried double-tapping space (after all, you can fly in creative mode)?
Comment: If you're in creative, can you grab a bucket of water, point straight down and hold right click? It might take a few goes but it should place the water and save you from the drop. It seems strange that you only hear the ground though, and don't see it. Hit F3 and check your coordinates, it might be worth editing the the world file to put something solid just underneath you
Answer: I would teleport yourself down back to regular ground level. Using the command <code>/tp @p ~ 70 ~</code>. This command would teleport you close to ground level or maybe underneath ground level a few blocks. From there you can dig up or already be close to ground level. If this doesn't work you may be experiencing lag and I can't help with that.
Comment: Actually 64 is around the ground level. 70 will be in the air unless it is a mountain

I'm stuck in the sky after respawning


Extra HDD or hybrid SSD for my Laptop

Question: I have an SSD installed on my laptop and currently it boots 4 Operating Systems. I have my old HDD installed but it is low on capacity. I want to increase the capacity by buying another HDD. I see the options available are 1TB or more HDD or 750 GB hybrid. My question is, if I already have an SSD as a primary drive, does buying an extra hybrid ssd make sense?
Answer: I do not know this for fact... but... I don't think a hybrid drive will be of any benefit. I have a hybrid drive in my Mac and it was a huge increase in performance, but what it did was simply cache my most used items. Since your primary drive is a full SSD, this is already done.
I would go with a normal HDD.

Extra HDD or hybrid SSD for my Laptop


Windows Server 2008 stopped showing progress of installing updates after emergency reboot

Question: I had to reboot machine with w2k8 server by pressing "reset" during it was installing updates due to hung update. After this when I've rebooted and resumed update process it installs update but does not show usual messages like "Installing update X of Y" and name of update, and progress bar also does not show progress. How to fix this?
Answer: Does the system event log show any windows update specific error messages?
Have you restarted the server after it completed installing the rest of the updates?
Answer: It looks like you've encountered some bugs in the update process.  Whether and how update progress is displayed is not configurable and there isn't anything you can likely do to change it.  It's also not something that would typically be considered a problem that needs solving.
Answer:
Reboot in safe mode and uninstall recent updates
Check logs in C:\Windows\SoftwareDistribution directory, also clean Downloads there.
Reboot and try to install updates once more
Answer: The solution helped me
<code>1. Start elevated shell
2. net stop wuauserv
3. rmdir /S /Q C:\Windows\SoftwareDistrubution
4. net start wuauserv
</code>
Then go to Windows Updated and check updates.


How to use update-alternatives in an alternate root path

Question: Is there a way to have the update-alternatives command operate on a root file system mounted on a path other than '/'?  For example, the update-rc.d and ldconfig commands have an -r <path> option to do this. The update-alternatives man page does not indicate such support.
Comment: Can you chroot in into the root file system, and run the command in that chroot?
Comment: Thanks.  I had resolved this issue with some shell scripting to do the equivalent of the update-alternatives command.  The chroot option looks like it will also work and would be simpler.
Answer: You can use the --admindir option to choose a state directory such as /my/root/var/lib/dpkg/alternatives, and the --altdir option to choose a link directory such as /my/root/etc/alternatives. However update-alternatives will see absolute symbolic links in /my/root/etc/alternatives, pointing to /usr/bin and the like, so it might see broken links for programs that aren't installed in the alternate root.
There's no option to tell it to work entirely inside a root. So use the generic method: chroot.
chroot /my/root update-alternatives …

If you don't want to run as root, you can use fakechroot.


Visualize 2d folded image

Question: Can you please recommend free or inexpensive software, or a plug-in that will allow me to preview/visualize a flat 2d square image when it has been folded in half or in thirds?
Answer: Parts of the image are selected and distorted(=stkewed + scaled horizontally to smaller width) to simulate some folding.  The angles are "by eye", not exact known degrees. The widths also are "by eye". Of course one can have a prepared model to follow in another layer. It shows the places of the corners (=total 8 here) before, in the middle and after the work.
Some apparent smooth curvature in the bend is simulated by making two smaller foldings with different widths.This comes easily  unintentionally when one makes a tweak.  The mid part is darkened a little and a  shadow is drawn and blurred to the background.
Total working time = few minutes. If you can live with this kind of low level sophistication and accuracy, you will do well with Photoshop, GIMP or any other photo editor which allows layers and easy distortion of selections.
This one is crunched together in Photoshop, which is especially easy and flexible without any add-ons for transformations this simple.
Answer: There are lots of services / plug ins / pieces of software that will automatically generate a 3D visual from a piece of flat artwork, one of my favorites is http://www.psdcovers.com, but that relies on you having photoshop and being able to use it at least a little. A bit of searching will throw up many others.
The problem with the free and easy solutions is that they tend to be somewhat inflexible. If you are serious about visualizing your designs then your time would be well spent learning how to create your own visuals. This would involve use of some 3D modeling software or getting VERY good at using Illustrator, Photoshop or similar.
Comment: Nothing wrong with blender

Visualize 2d folded image


Diff of module version releases

Question: I'm trying to debug an error I'm encountering in the latest version of the Custom Formatters module and I'm encountering a common problem I have in debugging.  There's no easy way to do a project-wide diff of project from release to release.  I'd like to easily diff https://www.drupal.org/project/custom_formatters 7.x-2.4 with 7.x-2.3.  I can use software locally to do that, but github has spoiled me I guess.  Am I missing a hidden function of drupal.org that shows diffs between releases?
Answer: You can clone down the project via
git clone --branch 7.x-2.x http://git.drupal.org/project/custom_formatters.git
When in the directory do a git diff 7.x-2.4..7.x-2.3 and review the output.
If you don't want to scroll through your terminal, try git diff 7.x-2.4..7.x-2.3 > version-change.diff and pop the output into a diff viewer.
I wish cgit had this built it, but the diff viewer in it only supports per commit (as far as I know)
Comment: Thanks.  I didn't think it'd be quite that easy to do in Git.  I still think it'd be nice to see diffs on drupal.org/cgit.drupalcode.org, but this is a solid solution.  I found more `git diff` tips on tags on this other SO post for anyone else who's interested: http://stackoverflow.com/a/3211829/721065

Diff of module version releases


How to login on on-premise SharePoint(local SharePoint) in IOS?

Question: Trying to make an app for local sharepoint login and access sharepoint list data in IOS app. I have try to login and pass parameter as username and password but give error 401 unauthorized.
I tried to login. Only one response send 401 unauthorized by server.
Please help me.
Answer: You problem of 401 is an authentification problem.
You need to use REST API and OData of SharePoint (hope you are in 2013).
And do all you stuff with this API (authentification, query list ...). There is not API in IOS for SharePoint.
Have a look at this topic in the MSDN who explain how to do that : Build mobile apps for other platforms using SharePoint 2013
Or check this exemple from codeproject : Development of iPhone client application for SharePoint 2013
I'm not a IOS dev, so I will not past.
Hope this exemple will help you


In a group we have $abc=cba$. Is it abelian?

Question: Let $G$ be a group such that for any $a,b,c\ne1$:
$$abc=cba$$
Is $G$ abelian?
Answer: Suppose $a,b\in G$, $ab\ne 1$ and $a,b\ne 1$. Then $1=ab(ab)^{-1}=(ab)^{-1}ba$, so $ba=ab$. Of course, if $ab=1$ then $b=a^{-1}$ and $ba=1$ as well, and finally, if one of $a,b$ is $1$, then also $ab=ba$. So the group is abelian.
Comment: Congrats on getting [the Populist badge](http://math.stackexchange.com/badges/39/populist) off of Math Gems' answer!
Comment: Hmmm, an answer from a seasoned math olympiads excontestant, brilliant!.
Comment: @MatemáticosChibchas: Was that an olympiad question?! I just guessed it may be true! And even there are more generalized questions!
Comment: @CutieKrait During my undergraduate studies I was math olympiad contestant a few times. Andrés' answer brought me fond memories about that, because of the style of the answer: concise and impeccable.
Answer: The proof is easy to find by writing equations $\,x = y\,$ in the "relator" form $\,xy' = 1,\, $ for $\,y' = y^{-1}.\:$ Doing so below, we seek to transform the $\rm\color{#0A0}{green}$ term into the $\rm\color{#C00}{red}$ term, and the value of $\rm\:c\:$ that produces such a transformation is clear when written this way.
$$\begin{eqnarray}
abc = cba &\iff&\color{#0A0} a&\color{#0A0} b&\color{#0A0} c&\color{#0A0}{ \!a'b'} &\color{#0A0}{\!\!c'} &=& \,1\\
          &\iff& a& b& c& \!\!(ba)'&\!\!c' &=& \,1\\
   &\ \ \Rightarrow&\color{#C00} a&\color{#C00} b&  &     &\!\!\!\!\!\!\!\color{#C00}{(ba)'} &=& \,1\quad\text{for}\ \ c\, =\, ba\\
          &\iff& a&b&=& b\ a
\end{eqnarray}$$
Remark $\ $ This method of matching-up equations normalized into relator form $\, r = 1\,$ proves quite handy when proving equations in groups presented by generators and relations. By viewing the relators as puzzle pieces, we can rotate (conjugate) them and fit them together to form a planar diagram whose boundary represents a proof of the desired equation. A basic result of combinatorial group theory implies that if an equation is a consequence of the given equations (relations), then the proof can be represented by such a "cancellation" diagram, known as a Van-Kampen diagram.
Below is a simple Van-Kampen diagram. It yields a visual "proof without words" of
$$r= x^2yxy^3 = 1,\ s= y^2xyx^3 = 1\ \Rightarrow\ x^7 = 1$$
The puzzle pieces are the relators $\,r,s.\,$ To verify the proof one simply checks that traversing the boundary of each interior region yields a relator, and that traversing the external boundary yields the sought relator, here $\, x^7$ (invert the label if you traverse the edge opposite its arrow direction).
$\qquad$
Comment: you have to assume $ab\ne 1$ (if $ab=1$ clearly $ba=ab$).  It's a more constructive answer.
Comment: Yes, that's the easy part, which most readers will have no problem with. My point was to show how to *discover* the hard part.
Comment: I think your diagram method is more like a street fight mathematics... unless had we a more complicated case and would it allow us to construct an algorithm out of it.
Answer: If we reformulate the question as follows:
Let $G$ be a group, and $a,b,c \in G$,
Let's define two 3-cycles: $\tau_1 = (abc)$ and $\tau_2 = (acb)$ to identify the left$(1)$ and the right$(2)$ side of the equality given.
Then isn't it obvious that, as $\tau_{1,2} \in \mathscr{S}_3 $ and $\mathscr{S}_3$ is known not to be commutative, the only condition which would imply this equality, is $G$ being abelian?
Comment: What does this have to do with commutativity of $G$?
Comment: I should have detailed: Let's introduce $\sigma_1 = \left (
\begin{matrix}
 a & b & c\\
 a & b & c
\end{matrix}
\right ) = Id_{\mathscr{S}_3}$ to represent left side of our equality; and $\sigma_2 = \left (
\begin{matrix}
 a & b & c\\
 a & c & b
\end{matrix}
\right ) = (bc)$ to represent the right side. Can't we have then the transposition $(bc)$ is identity, thus $bc = cb$?


What do you call a sentence fragment when it's appended to an independent clause?

Question: For example, in a sentence like "He spoke softly, his voice barely audible over the dull roar of the ship's engine" what do you call the thing that comes after the comma? Is this even grammatical?
Comment: It's OK. I'd say this is an 'absolute' construction, a kind of supplement that normally has a non-finite verb phrase, cf. "his voice being barely audible ...", but your ex. is the verbless analogue of this. Notably, absolute clauses contain a subject and are thus syntactically independent of the main clause. Like other supplements, they are not integrated into the syntactic structure, but sit apart as non-constituents, typically marked off by punctuation in writing and a slight pause in speech. Supplements are not modifiers; instead they have a semantic 'anchor', here the referent of "he".
Comment: @BillJ That sounds like an official answer. Can you make it one?
Answer:
He spoke softly, [his voice barely audible over the dull roar of the
ship's engine].

It's OK. This is an 'absolute' construction where the bracketed element is a kind of supplement that normally has a non-finite verb phrase, cf. "his voice being barely audible ...". Your example does not contain a verb and hence is the verbless analogue of this.
Notably, absolute clauses contain a subject and are thus syntactically independent of the main clause. Like other supplements, they are not integrated into the syntactic structure, but sit apart as non-constituents, typically marked off in writing by punctuation and a slight pause in speech.
Supplements are not constituents and nor are they modifiers. Instead they have a semantic 'anchor': here the anchor is the referent of "he".
Answer: It's not a sentence fragment. It's a dependent phrase.
Consider the reverse of the sentence:

His voice barely audible over the dull roar of the ship's engine, he spoke softly.

The fact that the dependent phrase in your original version comes after the independent clause doesn't change its semantic role. It's acting in an adverbial way to address the manner in which he spoke softly.

Update: I had originally used the term dependent clause, until it was pointed out to me that it had no verb. I then changed it to dependent phrase.
But apparently, there is a more specific linguistic term for this: verbless clause. Going by that terminology, it should really be a dependent verbless clause.
This nomenclature is expressed in an article called "Dependent Verbless Clause: Its Structure, Function and Use" by Jarmila Petrlíková:

The  term  "clause"  is  not  only  applied  to  structures  which  comply  with  formal  prerequisites, containing a subject and a predicate conveyed by a finite verb, but also to such structures which are analysable into  clause  elements.  The  verbless  clause  is  a  structure  containing  no  verb element  at  all  (either  finite  or  non-finite),  usually  having a covert  subject,  but  containing  other  expressions which  can  be  identified  as  a part of predicate (subject complement or adverbial). The verbless subordinate clause is joined to its superordinate clause syndetically or asyndetically  (a  supplementive  verbless  clause), or by  the  prepositions with or without.    As  an optional clause element, it functions as an adverbial, expressing a range of semantic roles, usually suggested by the introductory  conjunction,  or as  an  "optional  subject/object adjunct" (supplementive  verbless  clauses), conveying a twofold  relationship: to the  predication and,  at  the  same  time, to  the  subject  or  object  of  its superordinate  clause.  Considered  one  of  the  means  of  sentence condensation,  it  is  mainly used  in  written language.

I am choosing to leave my answer with the simpler dependent phrase—but with this additional note.
While dependent verbless clause may be a very specifically correct term, I find that the "fragment" (in conjunction with the independent clause) still looks like a phrase—and it meets the definitions I've seen of that word. (My original error was in not noticing that it lacked a verb.)
It's possible that it's both a phrase and a verbless clause, where the latter is a syntactical subset of the former—and, where the terminology overlaps, those who are more detailed choose to use the latter term instead.
One of the criteria for the more specific terminology is the assumption of an underlying elided be verb. This is fair. I base some of my own semantic interpretation of sentences on elision. So, it would be hypocritical of me to do so in some situations but object to it in others. (Unless I could determine firm criteria for the differences.)
Nonetheless, in terms of understanding what's going on with the sentence in question, I don't know if it's necessary to be pedantic about this particular terminology. The key point is understanding how the pieces are actually functioning.
I think that the short answer to the original question is: yes, it's grammatical.
Comment: It doesn't contain a verb, so it isn't a clause (at least not according to every definition of "clause" I've been able to find).
Comment: @hasnohat You are absolutely correct! I had misused *clause*. It's actually a *dependent phrase*. I have edited my answer accordingly.
Comment: @hasnohat  It's not a phrase - it's a verbless clause.
Comment: @hasnohat  . . . and updated my answer again . . .


how to pair JBL bluetooth device with Ubuntu laptop?

Question: I'm using 14.04 xubuntu version and want to pair it with the bluetooth JBL Flip 4 speaker. If I turn on the bluetooth on the laptop and "setup new device" choose "JBL Flip 4", "Connect to..." A2DP Sink (Send Audio)" I get the anser "Device added successfully, but failed to connect". Does anybody know how to solve this problem, how to pair and connect successfully?
Comment: There's no "4.10 xubuntu". Please [edit] and correct it.
Answer: Desktop OS: Ubuntu 18.04
Speaker: JBL Flip 4
I couldn't connect JBL to the notebook via Bluetooth.
The message was
a2dp-source profile connect failed for Protocol not available.

I solved this problem simply installing pulseaudio-bluetooth and restarting PulseAudio.
Maybe this info helps someone to save his/her time.
Answer: I had the same problem. The solution (for me) turned out to be very simple. Even when you were able to connect the device, you still have to go to the sound settings. (you can find this at the speaker-icon in the right upper corner) Here you still have to select the output; play sound through: in your case "speaker JBL". standard the "speakers built in audio" will be selected".
This is what solved the problem for me. I hope this will help you too.
Regards,
Nick


Does the U.S. Securities and Exchange Commission govern Bitcoin?

Question: Do SEC regulations apply to:

Exchange of Bitcoin for US dollars
Investing in companies with Bitcoin
An exchange that sells shares of company stock for Bitcoin
Bitcoin futures contracts
Answer: Is a Bitcoin a security?   The SEC hasn't said that it believes it is and not communicated with or taken action, formal or informal, asserting that a miner is issuing securities or that exchanges are engaging as brokers of a security, which is a regulated activity.
Is a Bitcoin an asset or commodity?   Does your grocery store need SEC approval to sell bananas?   Or, more similarly, does a coin dealer need SEC approval to sell gold and silver bullion?
Now a broker where gold bullion is speculated on is regulated in the U.S., just not by the SEC.  The Commodity Futures Trading Commission (CFTC) is the regulatory body that addresses that.  To-date, there are no bitcoin-related services offering futures contracts, options, or anything similar which operate from the U.S.
Now issuing shares in a company is exactly the activity the SEC addresses.  There are no bitcoin-related services issuing company securities or operating a secondary market for shares that operates from within the U.S.  The regulators may still assert jurisdiction though if securities are offered to investors from the U.S.
Now there may be registration requirements for an organization that holds deposits or where an exchange interacts with the banking system they may need to register as a money transmitter, but that is not something under the SEC's purview.
Answer: That is in the eye of the beholder! Luckily, the SEC itself has let on that they have a view on the issue. I would summarize it as a resounding maybe. Here's my source:

Whether a virtual currency is a security under the federal securities laws, and therefore subject to our regulation, is dependent on the particular facts and circumstances at issue.
SEC Chairman Mary Jo White, in writing, as reported on Bloomberg.

If you'd rather read my summary than go to the source, let me just point out that she went on to explain that lots of finance-like things you might do with virtual currencies would automatically fall under SEC regulations, regardless of whether the virtual currency used for it does or does not by itself.
I believe this letter was in preparation of a US government hearing in November. If I remember correctly, it was reported somewhere that the SEC then took the view that it could regulate Bitcoin, if it wanted to, but I cannot find a source. If you're willing to trust what may be a niche news site, then "[the SEC] made the case that the increasingly popular cryptocurrency, the Bitcoin, was actually a security and should be regulated." (New American article)


Fields of Study in Chemistry

Question: Is there a standard classification scheme for different areas of study and research for chemistry like mathematics has Mathematics Classification Scheme (MSC)?
Comment: I think there is none. See the six major and traditional classifications by the American Chemical Society  here https://www.acs.org/content/acs/en/careers/chemical-sciences.html
Answer: Neither one of the following two might be rigorous enough from the perspective of a mathematician because of some overlap of the fields within chemistry, or by initial inspiration / interaction with fields outside chemistry.  Thus I think the answer is no.
However, curricula at universities typically divide chemistry into general, inorganic, organic, physical, analytical chemistry, biochemistry, etc. This is reflected in study guides like chemistry.se's compilation of resources for self-study, or the organization e.g., of bookshelfs Chemistry LibreTexts.  As an example of topical overlap however, there are spectroscopic or electrochemical methods which may attributed to physical chemistry as well as of analytical chemistry.  A topic like bioinorganic chemistry may be recognized as an offspring in common of inorganic chemistry and biochemistry.  There equally are subjects where chemistry may be very relevant, but "chemistry" is not part of the name, too, like toxicology, geology, materials science, to mention a few.
Complementary to this, for long, there have been attempts to classify knowledge into divisions.   This is reflected by the labels (not only scientific) libraries put on their media (books, journals, etc.).  One of them is the system established by the Library of Congress with starting letters QD as root for chemistry within science (cf. entry wikipedia, or entry LOC).  An example for this may be the record for Chemistry of the Elements by Greenwood and Earnshaw here and other topically related entries of shelf QD466.

An other attempt are IPC as the international and CPC as the cooperative patent classification (USPTO and EPO) assigning patents related to chemistry (and metallurgy) to class C (entry EPO/espacenet). This classification however may be less helpful than a library catalogue à la LOC since patents may be filed in more than one (sub-class) at once.  Equally, you may find multiple patents related e.g., to keyword thiophene in classes other than C, too.
Comment: I just upvoted this fine answer. One thing I might add is that many chemists nowadays (I know many of them) focus on solving problems and eschew traditional divisional lines as no longer relevant (if they ever really were).

Fields of Study in Chemistry


Series power with unusual denominator

Question: I have a series whose terms are:
(x^n)/(n+a)
where n is a positive integer, x a real number that is greater than 0 and smaller than 1, and a is a real number smaller than 1. It is easy to proof that the series converges, but I cannot find if it is the series expansion of an algebraic function.
Can anybody help me?
Thank you in advance
Marco
Comment: Welcome to Mathematica.SE! I suggest the following: 1) As you receive help, try to give it too, by **answering questions** in your area of expertise. 2) Read the [faq]! 3) When you see good questions and answers, vote them up by [clicking the gray triangles](http://tinyurl.com/ch98nrh), because the credibility of the system is based on the reputation gained by users sharing their knowledge. Also, please remember to accept the answer, if any, that solves your problem, [by clicking the checkmark sign](http://tinyurl.com/4srwe2t)!
Answer: <code>Sum[(x^n)/(n + a), {n, 0, Infinity}, GenerateConditions -> True]
(* ConditionalExpression[HurwitzLerchPhi[x, 1, a], Abs[x] <= 1 && x != 1] *)
</code>

Series power with unusual denominator


Is this appropriate to give to a Jehovah Witness?

Question: I am not Jehovah Witness follower but my Mother in Law is. She has recently lost her son. I was going to paint her a plaque that has the saying "Your wings were ready, but my Heart was not" with a feather that has doves coming out the end of the feather with her sons initials and date of birth and death at the bottom. I do not know if this is appropriate due to her religious beliefs. I want to do something nice for her and not offend her. So if I could please get some input from someone who could help me out it will be greatly appreciated.
Comment: Sorry KorvinStarmast but reason for asking on here was because I had taggged it for those in Jehova Witness faith assuming someone might know and respond that was a member of her faith. I was unable to go to the funeral because I have just gotten out surgery and am starting through Chemo and radiation so yes I thought of asking in person but no I am not able to. Was just trying to do something nice for someone with what I had and was able to do here. I can not imagine losing a child and I know she is having a rough time right now.
Comment: Has it occurred to you that you are not giving to a Jehovah's Witness , but offering condolence to your mother in law. Jesus did the same for Mary the sister of Lazarus.
Comment: @vwade OK, understand.  Maybe someone has something useful/helpful to offer you.
Comment: You should probably ask a JW but it seems to me they would throw it in the trash. People tend to give gifts that they themselves would like to receive. But JWs would much prefer something from the Watchtower magazine or from scripture. That would be considered worldly (and I'm not saying that it isn't).
Answer: I am one of Jehovah's Witnesses.
This sounds like a very nice gift. Expressing your condolences will be comforting to your mother-in-law, but a plaque such as this could also help her to feel better when she finds herself grieving again in the future.
As you may know, Jehovah's Witnesses don't believe that we become angels in heaven when we die. We believe he is asleep in death (see What Happens When You Die?). We do believe, however, that we will see our dead loved ones again in the resurrection on a Paradise earth (see What Hope Is There for the Dead?).
If possible, I would do some more research on a suitable scripture or phrase which would reflect the hopes of your mother-in-law, or even a personalized scripture that describes some positive attribute of her son. Remember that this should be comforting to your mother-in-law, and not bring back painful memories.
From personal experience, the scripture that comforts me most is Revelation 21:4:

4 And he will wipe out every tear from their eyes, and death will be no more, neither will mourning nor outcry nor pain be anymore. The former things have passed away.

Here is a brochure that should help you: When Someone You Love Dies.
You may also like this article with tips on gift-giving: The Quest for the Best Gift.
Comment: Thank you so much for your help. I will read the links you gave me and will search for a better quote than the one I have.
Comment: @vwade You're welcome! I'm confident she will be touched by the effort you've gone to. I'm so sorry to hear of your loss.
Answer: This JW website describes their belief about death.

What happens at death is no mystery to Jehovah, the Creator of the brain. He knows the truth, and in his Word, the Bible, he explains the condition of the dead. Its clear teaching is this: When a person dies, he ceases to exist. Death is the opposite of life. The dead do not see or hear or think. Not even one part of us survives the death of the body. We do not possess an immortal soul or spirit.

At some point in the future many will be resurrected, but for now they are not conscious in any way, according to JW beliefs.
The sentiment "your wings were ready" has connotations of becoming an angel in heaven, or perhaps flying away like a bird. Either way it does not accurately describe  the JW understanding of what has happened to your brother-in-law.
This website is a mail-order site for sympathy cards including quotes from the New World translation of the Bible, some of which are rather long for a plaque, but show the kind of message regarded as appropriate to JWs.
They include these:

He will swallow up death forever
Lord Jehovah will wipe away the tears from all faces
I am the Resurrection and the Life
Looking forward to the happy day

and others, and there are other similar sites, which may give other ideas.
Whether your mother-in-law would be offended obviously depends on her, few persons take offence at the kind thoughts of others however expressed, but the idea that your brother-in-laws wings were ready for him is not strictly in accordance with the  beliefs she adheres to.
NB I am not a witness myself, so hopefully one will come along and give a clearer and  better argued answer than this.
Comment: Thank you for your help I was wandering on the angel reference and will work on finding something more in accordance with her beliefs.


When i try to install Hive 2.0 i get a multiple SLF4J bindings and that Hive metastore database is not initialized

Question: English is not my native language; please excuse typing errors.
I tried to install hive with hadoop in a linux environment following this tutorial. Hadoop is installed correctly but when i try to install hive i get the following output in my shell:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/home/phd2014/hive/lib/hive-jdbc-2.0.0-standalone.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/phd2014/hive/lib/log4j-slf4j-impl-2.4.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/phd2014/hadoop/share/hadoop/common/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]
Logging initialized using configuration in jar:file:/home/phd2014/hive/lib/hive-common-2.0.0.jar!/hive-log4j2.properties
Java HotSpot(TM) Client VM warning: You have loaded library /home/phd2014/hadoop/lib/native/libhadoop.so.1.0.0 which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
Exception in thread "main" java.lang.RuntimeException: Hive metastore database is not initialized. Please use schematool (e.g. ./schematool -initSchema -dbType ...) to create the schema. If needed, don't forget to include the option to auto-create the underlying database in your JDBC connection string (e.g. ?createDatabaseIfNotExist=true for mysql)

In my ~/.bashrc file y put the following:
export JAVA_HOME=/usr/lib/jvm/java-8-oracle
export HADOOP_PREFIX=/home/phd2014/hadoop
export HADOOP_HOME=/home/phd2014/hadoop
export HADOOP_MAPRED_HOME=/home/phd2014/hadoop
export HADOOP_COMMON_HOME=/home/phd2014/hadoop
export HADOOP_HDFS_HOME=/home/phd2014/hadoop
export YARN_HOME=/home/phd2014/hadoop
export HADOOP_CONF_DIR=/home/phd2014/hadoop/etc/hadoop
export HIVE_HOME=/home/phd2014/hive
export PATH=$PATH:$HADOOP_HOME/sbin:$HADOOP_HOME/bin:$HIVE_HOME/bin

I also export the variables HADOOP_HOME and HIVE_HOME inside the .profile file
This question here didn't work for me, i also run the command to create the Schema but it failed : schematool -dbType derby -initSchema
I have one more thing that i think it could help and is to modify the pom.xml file to avoid the multiple SLF4J bindings, but i can't find it. Try this but i didn't find it.
Thanks in advance
Comment: Does this answer your question? [running hive 0.12 with error of slf4j](https://stackoverflow.com/questions/27050820/running-hive-0-12-with-error-of-slf4j)
Answer: SLF4J is a logging API. It will dynamically bind to an implementation but it expects that there will only be one present. In your case it appears that you have three jars that provide an SLF4J implementation; hive-jdbc-2.0.0-standalone.jar, log4j-slf4j-impl-2.4.1.jar and slf4j-log4j12-1.7.10.jar.
hive-jdbc-2.0.0-standalone.jar appears to be a "shaded" jar - it includes the classes from multiple third party jars, including the contents of log4j-slf4j-impl. I am guessing that this is what SLF4J actually selected since it was the first one found.
The issues is that you are somehow including jars that the standalone jar has already incorporated. Normally with a standalone jar everything you need should already be in that jar.
Comment: Thanks for your answer rgoers, you clarified some of my doubts. I think i could decide which jar to use in my pom.xml file, as is explained in this link [link](http://www.slf4j.org/codes.html#multiple_bindings) , but my problem is that i couldn't find my pom.xml.
Answer: When i try to install hive 2.0.0 i got the error that i posted, but if i install the version 1.2.1 instead it works fine, just by setting the environment variables and creating the /user/hive/warehouse directory in the HDFS. It must be a bug of the new version. My recommendation is to install the version 1.2.1 instead of the 2.0.0


2006 Audi A4 2.0

Question: I am in the process of increasing horsepower with more boost in my turbo. What's the max boost I can do if I did the k&n air filter upgrade and put a 2.5 down pipe and 2.5 inch exhaust all the way back?
Comment: Firstly I would ask have you considered the ECU in your plans? In the 2.0 TFSI the ECU "requests" boost from the N75 valve. If it sees anything outside of the range it expects you'll be generating faults in the ECU.
Comment: What mechanism are you using to increase boost? What engine code do you have?
Comment: @StevenRichardOakes You have a very very good point there.
Answer: It just so happens I wrote a How-To article on AudiWorld.com about tune reviews for the A4 B7 platform.
For instance, you can purchase a Stage 3 remap of your computer from GIAC (assuming a 2.0 TFSI engine) and have the car produce an extra 100-130hp with 75-145 lb-ft gained in torque. Not only will you want your cold air intake, but you'll need some other mods as well (read their page). For a 2.0 liter engine, that is some serious power gains. The engine itself stays stock. The mods they talk about are all supporting, to ensure your engine is compatible with the remap of your computer. You can purchase their Stage 1 remap, which will give you an extra 30-60hp ... which is still a serious kick in the pants.
Bench racing your engine (ie: How much will my engine make if I ...) is not anywhere close to an exact science. One of the reasons is, I can tell you to throw a tank of nitrous onto your car, let you blow as much laughing gas into the intake as you want, and the engine will produce 1000+hp ... the real question to ask here is: How long is my engine going to last? ... the answer to that question is: Not very long. Consider that when combining to make horsepower in any situation.
Answer: You can boost away almost indefinitely until the AFR goes lean or you start pre-detinating (knock).
At which point you'll need a new engine.
But once you get outside your turbo's compressor efficiency map, more heat, less VE, and a whole bunch of other concerns.  Time for a bigger turbo.
Are you going to run 93 pump, E85, meth/water spray?
First post is spot-on; you need a good ECU tune (and great tuner) to realize any benefits from bolt-on mods.  Otherwise any power you perceive gained will just be a result of leaning out your AFRs, and eventually causing stress and damage.
Just changing the CAI is likely to need a MAF remap.  Otherwise, lean and possibly boom!
It's an expensive slippery slope (but fun).  Just ask me-I can barely afford to type.
Please, please, please get a proper ECU flash.

2006 Audi A4 2.0


Anet A8 beginning layers not printing correctly

Question: I have had an Anet A8 printer for about two months now and still have not gotten it to print good prints.
At first, it would only print completely solid parts and every time I would try infill from 10-90% the first layer would not stick or it would print really filmy like. As of now, it won't print the first layers for anything well but once it gets up about 10-ish layers it prints perfectly. I have tried a lot of stuff but it seems to be making it worse.
The pictures show my recent attempt at these settings below (Cura's default for normal quality), the print is supposed to be a 10 mm square. I have gone back to the default settings because nothing else was working.

Using blue painter's tape
Layer Height       0.1 mm
In. Layer Height   0.3 mm
WallThicken        0.8 mm
Top/Bottom Thick   0.8 mm
Infill Density     20%
Grid Pattern
Print Temp         210°C
Bed Temp           65°C
Dia                1.75 mm
Flow               100%
Brim (raft is a little better)

Any suggestions?

In the top picture you can also how the top layer has two bubble effects.
Comment: With respect to the filament lifting off, and/or not adhering correctly, on the first layer, see [Filament lifts from the hot bed while printing](https://3dprinting.stackexchange.com/questions/4018/filament-lifts-from-the-hot-bed-while-printing)... you may need to clean the bed, calibrate the leveling and the nozzle height (see [my answer](https://3dprinting.stackexchange.com/questions/4018/filament-lifts-from-the-hot-bed-while-printing#answer-4021))
Answer: With respect to the filament lifting off, and/or not adhering correctly, on the first layer, see Filament lifts from the hot bed while printing... in particular, you may need to clean the bed, calibrate the leveling and the nozzle height (see my answer).
The fact that the prints are fine, after 10 or so layers, could be to do with the heat - at the higher layers the print is warm and no warping occurs, but below that, maybe the print bed is acting as a heat sink and making the filament cool too quickly - hence the distortion. Are you using a heated bed? If not, then maybe consider installing one.
Not sure about the bubbles: how do your store your filament? The bubbles could be due to water, which expands as it gets hot, thereby causing the filament to bubble. It is best to store your filament in an air tight container, to prevent it collecting moisture and dust from the air.
Answer: My Anet A8 has a concave bed, which is a defect. Check if yours has the same defect by putting a long ruler on its edge on the bed and look for a gap between it and the bed in the middle. If you find a gap then it is concave. The best solution is to put a piece of glass on the bed instead of blue tape, because glass is very flat. It will also help a lot with bed adhesion. I highly recommend this mod.
Answer: Try lowering your Z height a bit more for the first layer if you find yourself having bed adhesion problems. What brand of filament are you using? Did you try using some other brands?
Answer: When I first started printing with the anet A8, I also had trash first layers.
I tried (almost) everything:

Leveling the bed maniacally several times (all the screws in the
frame need to be very tight)
Varying bed temperature and nozzle
temperature at all possible combinations.
Adding blue masking tape

Nothing would significantly improve my first layer, except for HAIRSPRAY.
After discovering this secret, I went back and un-varied everything. I tried with and without tape, at high and low temperatures. With-out the hairspray it never stuck well. With the hairspray it stuck perfectly every time. A small spray is sufficient.
After you are done making a mess, use nail polish remover ( acetone ) to properly clean everything.
If you are doubting your G-code, get a pre-generated one for the A8. The ones that came on the SD card should print very well, nothing like the image you showed of the 1st layer.


Is there a $3$-dimensional shape such that for any given volume that shape will have the greatest possible surface area?

Question: I was just thinking about this studying for a biology test as for cells a greater surface area to volume ratio is desirable, so I wondered if there was a theoretically optimal shape that would maximize this ratio. I thought it might be that there is no such shape as you could just add folds to the surface indefinitely but I don't know if that is truly the case.
Comment: There's no upper bound on the surface area given a fixed volume (think of a very long and thin rectangular prism) and it can even be infinite (https://en.wikipedia.org/wiki/Gabriel%27s_horn). Surely in biology you don't just want a large surface area but also some kind of restriction on the diameter so it doesn't take too long for molecules to be transported between different parts of the cell.
Comment: **Off-Topic**: Assuming that you accept Darwinism, there is a separate issue.  Assume (perhaps wrongly) that the greater the surface area per volume, the better, regardless of other considerations.  This doesn't necessarily make it *game over*, regardless of the complexity in evolving from (for example) an ameoba to a human.  Some chain of mutations must occur that lead to the high surface area shape.  Absent the occurrence of such mutations, it becomes irrelevant how desirable such a cellular shape would be.
Comment: This was more of a thought inspired by biology rather than a question about biology itself but thank you for your answers it is very helpful.
Answer: One way to show that there is no maximum surface area associated with a given volume is to consider very long cylinders (biologically, roughly the shape of a worm).  The volume $V$ of a cylinder of radius $r$ and height (or length if laid horizontally) $h$ is:
$$V = \pi r^2h$$
For a given volume, say $V^*$ we can therefore express $h$ in terms of $r$:
$$h=\dfrac{V^*}{\pi r^2}$$
The surface area $A$ is:
$$A=2\pi rh+2\pi r^2$$
Substituting for $h$:
$$A= \dfrac{2V^*}{r}+2\pi r^2 > \dfrac{2V^*}{r}$$
Given the constant $2V^*$ in the numerator, we can therefore make $A$ as large as we like by choosing a sufficiently small value of $r$.


How does someone not know they're Jewish?

Question: In this answer, someone said they got offended when people wore crosses, especially if they didn't know they were Jewish. I'm just wondering how someone can not know what religion they follow?
Comment: Rob, welcome to the site and thanks for asking this weighty question. I hope you stick around and enjoy the site.
Comment: How does a Jew know they are a Jew if Abraham's genealogy was destroyed when the temple was destroyed? And 2000 years of word of mouth is difficult to accept. A proselyte could tell their children they are Jewish. DNA only proves one of your parents are Jewish. I'm not judging, just being realistic.
Comment: Normally we rely on what is known as *chazakah*. However, these are interesting points that you are bringing up. Thanks much for your insights!
Comment: I believe that even Jews who are born Jewish (i.e., not Jews by choice) must not only consider themselves born into the covenant and therefore physical offspring of Abraham, but they must also consider themselves to be spiritual offspring of him, even if not their genetic father.
Answer: In Jewish Law, a Jew is a Jew and remains a Jew no matter what actions he or she takes.
You could even say, "once a Jew, always a Jew".
That means, if someone is born to a Jewish mother (because Jewishness is passed through the mother) and is never told that they are Jewish, they are still a Jew.
Judaism is not a religion like Christianity or Islam is. One's Judaism does not depend on what they practice or believe. You can convert ten times over and you will still be Jewish. Sorry ;).
Comment: @userunknown. I'll try to address some of your misconceptions, but a comment thread is not the best place. 1) Religion is supposed to be authoritarian. What G-d says, goes. Period. That is the basis for religion. If G-d doesn't set the rules, then is it a religion of G-d worship, or self-worship?  Judaism actually does a wonderful job of reconciling that with a democratic halachic process which is too complex to deal with here.
Comment: @userunknown. Continued. 2) Judaism is actually one of the most free religions I've heard of. It's the only one I know of that says non-members have a place in the world to come, and that does not punish sins committed in ignorance. Hence, those 64 Jews are blameless. I don't see how that's "unfree", especially relative to other religions where they would be considered sinners and deserving of punishment.
Comment: @userunknown. Continued. 3) Saying "imho" does not make an arrogant statement humble. Calling a central principle of one of the worlds oldest and most influential religions "absurd" on the basis of one SE answer, is foolish and yes, not humble. A little more research into the topic would be proper.
Comment: That pretty cool, I guess I sort of knew the passed on from the mother part, but didn't know it stuck no matter what. That's pretty neat.
Comment: @Rob. Yeah, we like to think so :D. Allow me to echo msh210's welcome, and I hope to see you around!
Answer: A person is a Jew if their mother is a Jew. If a jewish woman marries out of the faith and did not bring up her children as Jews they are still Jewish, even if they do not know it or practice it. And then her daughters children remain Jewish and at this point most likely they have no idea what it means to be a Jew.
Comment: @userunknown, a person who decides not to be a Jew is a sinning Jew.  We hold out hope that he will come back someday, and his halachic status as a Jew is not changed by how he feels about it.
Comment: For me, a person who decides not to be a Jew is no Jew.
Answer: In totalitarian regimes wives would not tell their husbands they are Jewish. There is plenty of people who are Jewish (in maternal line) and do not know it today. Also, it was far more common for Jews to become (forced) Christians than otherwise. I have a bit of 'Jewish DNA' and found very very distant cousins among New Mexico conversos/'marranos' descendants and in other places. With very slight probability I could be born Jewish, and if I wear a cross, then I could offend someone. G-d only knows what is hidden in us. DNA can tell both maternal line and paternal line descent, but, unless one is extremely lucky, it can only tell approximate geographical area of origin, with no meaning for the Jewish faith. By the way, every Jew has sincere (otherwise they would not upbring Jewish children) converts 'blood' to various degrees, making it more difficult to track 'legitimate' Jews based on genetics only - it is practically impossible.


Hiding a Categories content on just the Homepage 'Posts'?

Question: Is there a way I can hide a certain categories content from just the homepage Posts section of my Wordpress Site? So, those posts are still posted and live; just not visible nor accessible from the homepage posts area. I'm calling the category twice on the homepage; once in the header within a plugin I'm using, and the other where the posts are created by default by Wordpress. How can I hide my 'featured' category in the main page content of recent posts on the homepage?
Comment: What exactly do you mean by "homepage"? Are you referring to the **Site Front Page** specifically, or to the **Blog Posts Index**, whether displayed on the Site Front Page or not?
Comment: Thanks for the response; I'm not sure the exact name of the area. But looking at; http://wordpress.org/extend/themes/twentyten The old twenty ten theme. The main wider area on the left, that populates with posts as you create them. I just want to prevent a certain category from appearing there. But I want them to still exist, just not displaying there.
Comment: Sure... but *in what context* do you want to do this? Always? Only on the site front page? Some other context?
Comment: I'm using a header/slider plug-in that calls that category to populate it; it's setup that the header links to those posts within said category. I want this to remain in tact across the site's header; I just don't want the category to be present anywhere else without accessing the links within my header plug-in to get there.
Comment: Does the slider always appear in the header, or only on the front page?
Comment: It will just need to appear on the front page.
Answer: Okay, it sounds like you'll want to modify the primary Loop using query_posts(), but only on the Site Front Page.
I don't think TwentyTen includes a front-page.php template file, so we'll modify index.php directly. Add the following code to index.php, anywhere before the Loop output:
<?php
// Determine if we're on the site Front Page
if ( is_front_page() ) {
    // Globalize $wp_query
    global $wp_query;
    // Create argument array in which we
    // exclude desired category IDs. Categories
    // are listed as a comma-separated string.
    // e.g. '-3', or '-1,-2,-3'
    $exclude_cats = array( 'cat' => '-3' );
    // Merge custom arguments with default query args array
    $custom_query_args = array_merge( $wp_query->query, $exclude_cats );
    // Query posts using our modified argument array
    query_posts( $custom_query_args );
} // is_front_page()
?>