Is there any way to activate full 'leech' mode?

Question: As I understand, bitcoin basically represents a situation where nodes are expected to (and do) serve other nodes in the network, information that represents the money of all transactions in that network. That is, that regardless of whether nodes(full/light non spv nodes) initiate the connection, recent blocks/transactions/etc are sent by those nodes to other nodes on the network, and that they have unequivocally no choice but to actively participate in the relaying of that information(regardless of content/intent/purpose/etc) to those other nodes. Is there really no way to make a light node(pruned) consistently passive, that is, not send any information relating to the data(possibly also headers) in each block to nodes that request it?(other than some relay bit that seems to be for spv specifically?)
Answer: You can start your Bitcoin Core with the <code>-blocksonly</code> configuration option. This stops your node from requesting and relaying unconfirmed transactions, and disallows inbound connections. Your node will then only request new blocks and the transactions that were confirmed in them. Since your node only forms outbound connections in that case, it will never be in a position to help other nodes with the initial block download. Since your peers would likely get compact blocks from their other peers, your node would also be seldom expected to forward a block.
In result, this should reduce your network traffic to the absolute minimum for staying synchronized with the chaintip, but you'll only learn about transactions after confirmation.
Answer: A newly created node has no data to relay. In order to help new nodes start up, existing nodes presumably cannot discriminate against nodes that claim to have no data available to relay.
Therefore I suspect you could, if you had the necessary programming skills, create a Bitcoin node that contributed nothing to the health of the Bitcoin network.
If this occurred on a large scale, people with an interest in seeing Bitcoin survive would presumably need to implement countermeasures that strongly discourage this.


How to use "onUserAfterLogin" Event?

Question: I want my users to get an email when they login for the first time.
I am thinking to create an array to store userids that have logged in before. When users login, compare their userid with the array, if it is in the array then do nothing, if not then add the id into the array and proceed to generate email.
The question is, where is the best place to do this comparison?
I am thinking it should be right after a user logs in and find this onUserAfterLogin event on https://docs.joomla.org/Plugin/Events/User. But how do I use it? And should I categorize what I want to do as a plugin?
Answer: Yes, writing a plugin and leveraging the onUserAfterLogin event seems like the best way.
As for how to check for the first visit:

You can check the user's lastvisitDate column for a 0000-00-00 00:00:00 value as discussed in this Joomla Forum Thread: First login redirect plugin.  However, if there was an error in delivering the email, you will need to add a consideration for how you want to be alerted of the failure.
You can create a new database table where you keep a record of all successfully emailed users. Then from the plugin, query that table for the user's id, if the row exists you never email again, if the email delivery fails don't add them to the list.
Comment: *onUserAfterLogin* is definetly the best way. OP should also go for option 1.. There is no need for a database table. I have this working without problems. A failure of the email sending will normaly not be detected by Joomla anyway, once it is set up correctly. So there needs to be only a notification to an admin if the whole setup is wrong..

How to use "onUserAfterLogin" Event?


Avoiding tax complexities of REITs

Question: I would like to invest in REITs for their high yield, but would like to avoid their tax complexities. If I buy exposure to REITs through an ETF or mutual fund, will that abstract away the need to do RoC calculations and constantly adjust my basis for when I sell? While these calculations may not be that bad for a single REIT, if you have many small positions in a number of them, doing the accounting paperwork will be a major burden.
Comment: Dunno if it's REIT officially, but one of my funds is real-estate based and the only way in which its mechanics differ from my other funds is that the numbers I need for tax returns are delayed several months while all the transactions settle out. Annoying, nothing more. Other funds may, of course, behave differently.
Comment: what's the yield?
Comment: Variable, like any fund. I'm deliberately leaving that open and not making this an answer because i'm just giving an existence proof. You still want/need to do your own research to establish whether any particular investment meets your needs.
Comment: My REIT allocation (and bond allocation) is 100% within my tax deferred retirement accounts.  My taxable has individual stocks and a legacy mutual fund from my grandparents.
Comment: Since you asked about tax law, you should probably tell us what country's law you're asking about?
Answer: Yes, a REIT mutual fund (such as Vanguard's) alleviates the need to do these return-of-basis calculations yourself, since the fund computes them for you.  As keshlam mentioned, one of the drawbacks is that you usually don't get your 1099 for the fund until about a month after you receive all your other 1099s.
Another drawback is that all the fancy accounting the fund has to do usually results in significant non-qualified dividends.  For example, in 2014 my REIT fund's dividends were 96.6% non-qualified, which means they were taxed at my marginal tax rate instead of the greatly reduced qualified dividend rate.  I believe (though I may be wrong since I've never done it) that a REIT you own directly will shed more of its profits to you as short-term capital gains, which you would then at least have the opportunity to offset with other capital losses before paying your full marginal tax rate on them.
(Alternatively you could of course stick all your REITs/REIT funds in tax-advantaged accounts.  See one of my favorite links, Principles of tax-efficient fund placement, for a fuller discussion.)
Comment: Is your REIT fund a mutual fund or ETF?
Comment: Mine is a [mutual fund](https://personal.vanguard.com/us/funds/snapshot?FundId=5123&FundIntExt=INT), but it has an equivalent [ETF](https://personal.vanguard.com/us/funds/snapshot?FundId=0986&FundIntExt=INT).

Avoiding tax complexities of REITs


Qt or Delphi... If you were to choose one over the other?

Question: If you had a differential of either venturing into Delphi land or Qt land which would you choose? I know they are not totally comparable. I for one have Windows development experience with Builder C++ (almost Delphi) and MFC (almost Qt), with a bit more time working with Builder C++. Please take out the cross platform ability of Qt in your analysis.
I'm hoping for replies of people who have worked with both and how he or she would compare the framework, environment, etc.?
Thank you in advance for your replies.
Comment: "MFC almost Qt"??? I'm amazed you haven't been flamed yet for this. :-)
Comment: I'm hoping for replies of people who have worked with both and how he or she would compare the framework or environment?
Comment: Why are you comparing an IDE to a UI framework?
Comment: I think you need to edit your question to be more clear.  You are very subjective right now.  Add some criteria by which to judge the suitability of each.
Comment: It is subjective. I see no clarifying possible. Thanks for adding the tag.
Answer: If you are talking UI frameworks, then you should be comparing Qt with the VCL, not the IDE (Delphi in this case). I know I'm being a stickler, but Delphi is the IDE, Object-Pascal is the language, and VCL is the graphical framework.
That being said, I don't think there is anything that even comes close to matching the power and simplicity of the VCL. Qt is great, but it is no VCL.
Answer: Edit: This answer was written in 2008. It probably is no longer so apt, though probably it is not entirely useless. Take with salt.
I have used both and have ended up going the Qt route. These are the reasons:

Trolltech offer quick and one-to-one support via email
Qt innovates, and introduces powerful new features regularly
The Qt documentation is amazing, and in the rare cases where it isn't, you can read the source code
Having the source code for Qt also allows you to debug inside your base libraries, which has been a life saver for me on many an occasion
The API is very consistent and well designed. We have put new people on the project and within a month they show deep knowledge of the toolkit and can learn new classes very quickly
It has bindings to other languages, eg. Ruby and Python.

C++ is somewhat of a downside, eg. compile times, packaging, and a less integrated IDE. However Qt does make C++ feel more like a higher level language. QStrings take all the pain out of string handling for example. Thus the additional issues with C++ that you would normally face, eg. more buggy code, are less prevalent in my experience when using Qt.
Also, there are more libraries for Delphi than for Qt, but this is mitigated due to the fact you can just use a c or c++ library in a Qt project, and also because Qt is so fully featured you often don't have to look any further.
It would be a strange situation where I would choose Delphi over Qt for a new project.
Comment: With most SKUs of Delphi, you have the VCL source, too.
Comment: Just a side note, check out precompiled headers functionality in C++, if you haven't already. (Since you put compile times as a downside of C++, it seems like you haven't use precompiled headers, which basically make compilation as fast as in delphi (in most cases)).
Comment: I've used precompiled headers; it helps. However, linking is still slow and not helped by PCHs, and header dependencies mean you often have to recompile more than you'd like.
Answer: I would pick Delphi.  Of course you ask any pascalholic and he is sure to answer just the same.  ;)
Qt again is fine, but the VCL just feels more polished.  But then that could be my years of working with it so it just feels right.  My experience with Qt was limited to a short lived project that ended up being rewritten in Delphi after it was determined that cross platform was not really needed thanks to the power of GoGlobal which can make any win32 app a web application, and therefore run on any platform.
Comment: another +1 for "pascalholic" :)
Answer: It really depends on your needs and experience. I have worked with both (though have to say that the last Delphi version I really worked with was Delphi 6, and I'm currently working with Qt 4.4).
The language
C++ pros:

C++ is more "standard", e.g. you will find more code, libraries, examples etc., and you may freely use the STL and boost, while Object Pascal is more of an exotic language
Qt compiles on different platforms and compilers (Kylix is based on Qt, BTW)

Object Pascal pros:

some dynamic properties are build right into the language, no ugly workarounds like the MOC are needed
the compiler is highly optimized for the language and indeed very fast
the language is less complex than C++ and therefore less error prone

The IDE
Qt pros:

Strictly spoken, there is no IDE for Qt besides the Designer, but it integrates nicely into your preferred IDE (at least Visual Studio and Eclipse)
the designer does a better job with layouts than Delphi forms (Note: this is based on
    Delphi 6 experience and may not be true with current versions)

Delphi pros:

The IDE is really polished and easy to use now, and it beats Visual Studio clearly IMO (I have no experience with Eclipse)
there is no point 2... but if I had to assign the buzzword "integrated" I would assign it to the Delphi IDE

The framework
I will leave a comparison to others, as I don't know the newest VCL good enough. I have some remarks:

both frameworks cover most of the needed functionality
both have the source code available, which is a must IMO
both have a more or less consistent structure - I prefer Qt, but this depends on your preferences (remark: I would never say that Qt is almost MFC - I have used MFC for a long time, and both Qt and Delphi - and .NET, for that matter - are way better)
the VCL has more DB-oriented functionality, especially the connection with the visual components
Qt has more painting (2D / 3D / OpenGL) oriented functionality

Other reasons that speak for Qt IMO are the very good support and the licensing, but that depends on your needs. There are large communities for both frameworks,
Comment: Qt has a really nice IDE now, Qt Creator.
Answer: A big difference between Delphi and Qt is the Qt signal/slots system, which makes it really easy to create N-to-N relationship between objects and avoid tight coupling.
I don't think such a thing exists in Delphi (at least there was no such thing when I used to use it).
Comment: It isn't built-in but there is e.g. http://www.deltics.co.nz/blog/?tag=multicast-events and http://blogs.embarcadero.com/abauer/2008/08/15/38865.
Answer: I just started experimenting with Qt/C++/Qt Creator and I must admit I was surprised that this "little cute bastard" was just below my nose for some many years and I pay attention to it just now.
It (the framework) looks neat, feature-complete (even was stuff that .NET lacks such as inbuld XQuery support).
Seems that most of the Qt applications written are dealing with 2D/3D/Games.
I believe the downsides are only: having to know C++ and the lack of DevExpress goodies like QuantumGrid.
I am seriously considering porting one of my simple applications (a picture viewer like ThumbsView).
And it REALLY runs from same codebase. FOR REAL!
Forget about Kylix, Mono, Lazarus, Free Pascal. This Qt thing beats them all in 10 times.
Qt Creator is far from IDE. But I hope in the future they will add a more powerfull debugger, code insight and refactoring (at least the "Rename" one) and more meaningful compiler errors.
I would seriously recommend to someone without experience in Pascal/C++ to take the Qt learning curve.
Answer: I would pick the Delphi Programming Language, but that is probably because I have programmed it before.  It seems there are still a number of companies which use it, and almost everyone who has 8+ years expierence has encountered it somewhere.  It seems that most programmers can relate to using it or at least learning Pascal.  Not to mention the fact that newer programming languages (C#) are based on it (at least partially).
Answer: Pick Delphi if your concern are native Win32 speed, a first class RAD environment and executable size. Pick QT if you need a truly cross-platform framework coupled with a now-flexible licensing policy and don't mind slightly bloated code.
I ported an old Delphi program under QT/C++, and I must say that QT is the framework that comes closest to VCL in terms of ease of use and power (IMHO)
Answer: I'd choose delphi. Only because I have more experience with it. I don't think that there is other reasonabl criterias.
Answer: Qt is cross-platform, Delphi not much if we count Kylix. Lazarus is cross-platform, but not quite feature-complete yet.


Issues with NSImage add representation in Retina Display

Question: I have two CGImageRef, imgRef1 and imgRef2.
I want to create a NSImage with two representations of those CGImageRefs (for creating NSCursor). For this I used BitMapRepresentation initWithCGImage method and then added those representations to NSImage. But this doesn't work.
Then I tried creating NSImage from imageRef1 and imgRef2 and then generated NSData from those NSImage's using TiffRepresentation and then added those representations to finally get the NSImage. But again this is giving low res Image in retina displays.
HEre is the sample code: (Any help would be appreciated)
float       aHotSpotX = (float)nHotSpotX;
    float       aHotSpotY = (float)nHotSpotY;
<code>NSSize nsSz;
nsSz.width = CGImageGetWidth(nLowImageRef);
nsSz.height = CGImageGetHeight(nLowImageRef);

NSImage* image = [[NSImage alloc] initWithSize:nsSz];

// Could have directly used NSBitmapImage initWithCGImage but some issues with that. Will revisit
NSImage *lImage = CreateNSImageFromCGImage(nLowImageRef);
NSData *lowData = [lImage TIFFRepresentation];

NSBitmapImageRep *lowRep = [NSBitmapImageRep imageRepWithData:lowData];
[image addRepresentation:lowRep];

NSImage  *hImage = CreateNSImageFromCGImage(nHiImageRef);
NSData *hiData = [hImage    TIFFRepresentation];

NSBitmapImageRep *hiRep = [NSBitmapImageRep imageRepWithData:hiData];
[image addRepresentation:hiRep];

NSCursor*   aCursor = [[NSCursor alloc] initWithImage:image hotSpot:NSMakePoint(aHotSpotX, aHotSpotY)];

[image release];
</code>
Answer: You need to reverse the order. My tests have shown that the higher res image needs to be at index 0 of the TIFF and the lower res image at index 1.


Closing workbook in Excel 2013 without closing the Excel window

Question: Further question related to topic: Working with multiple workbooks in Excel 2013
The functionality of Excel 2013 where closing a workbook closes the whole Excel 2013 window is quite annoying. Closing the window completely used to be able by clicking on the X of that window. If one wants to close only the workbook one could click on the X of the window of the particular workbook. Now there is no choice anymore.
The reasons that I find this annoying are:

I often have two or more Excel windows open in two separate (physical) screens. If I wanted to close a workbook in one of the screens and immediately open a new workbook I would just close the workbook. The Excel window would stay and I could immediately open a new workbook.

Now I have to first open a new workbook, then go back to the one I want to close and close it. If you are going through a couple of files that's an annoying extra step.
If you do close the open workbook first and then open a new Excel window - to be able to open a new file - you have no control over which screen the window will be shown. Furthermore, after you open a new Excel window and open a file it will keep the blank workbook that Excel automatically shows. So you would still end up with a workbook you don't need and need to close separately.

In previous versions of Excel the last open or save location would be retained per window. In the new Excel 2013 the last open or save location of any open workbook is the location that is shown upon clicking the open workbook button. So one has to navigate folders all the time if you have several locations where files are stored.

Has anyone found a solution for this?
Answer: Yes, I know it is an old post but so many struggle with this:
Use Control-W (Close Workbook); or File, Close; or the new ribbon inspired shortcut would be: ALT+F, C. Then S to Save or N to Not Save.


Mantaflow simulation is baking the fluid in the wrong place and at the wrong scale

Question: As you  can see from the provided picture, when I start baking fluid in this scene, the fluid flows from the wrong place and at the wrong scale (changing the size of the real inflow also changes the size of the "fake" inflow), it is also flipped in velocity direction. I have tried clearing the fluid cache as well as checking normals and surface thicknesses. No other inflow objects exists, only the collision effectors of which there are 4. Does anyone have any idea what might be causing this? I have had no issues in the past working with the new simulator and this is the first time I have run into this issue. I am happy to answer any further questions as well. Thank you!
Comment: Have you tried "Apply Scale" in the domain and flow objects?
Comment: Thank you Rich, this fixed my issue. For future reference for myself: Click on domain->Object->Apply->Scale->Free and rebake
Comment: Great - glad it helped. I've added an answer for completeness.
Answer: The fluid simulation is sensitive to the scale of the domain mesh - if it is has been rescaled (resized in any way) you should Apply Scale to ensure the scale is set back to 1.0 in each dimension. In your case, the adjusted scale (possible negative scale) was affecting the results of the simulation.
To address this, select the Domain object and press Ctrl+A and select Scale to 'Apply Scale' (the same option is availble through Object/Apply/Scale menu). You should then Free and re-Bake your simulation if necessary - to pick up the changes.


SP 2013 Form Customization

Question: How can I change the checkboxes and radio buttons in a SharePoint list form to be horizontal rather than OOTB vertical to save space?
Answer: The easiest way to upgrade forms in SharePoint is using InfoPath. Unfortunately this only works with the enterprise version.
If you don't have that, you can use SharePoint designer to customize the forms directly however you are limited in what you can achieve in terms of changing the controls.
I do believe it is possible using SPServices (see http://spservices.codeplex.com/wikipage?title=$().SPServices.SPArrangeChoices&referringTitle=Documentation)

SP 2013 Form Customization


Can a singer sing a song from its notation if he/she has not heard the song before?

Question: Is it possible for a singer to sing a song just by reading its musical notation? A song which he/she has never heard before?
Comment: If that weren't possible, what would be the use of having musical notation at all?
Comment: @KilianFoth - I'm guessing OP means a proper performance first time off.
Answer: Yes, a properly trained musician can sing music (either in their head, what we call "audiation," or out loud) just by reading the notation. This is something that we call "sight singing," and it's a standard part of musical training.
There are a lot of problems with the metaphor that "music is a language," but the metaphor does apply here. Think about a language you can speak fluently: if you see it written down, can you reproduce it in sound? Furthermore, if you hear it, can you reproduce it in notation?
The same logic applies to musicians: sight singing translates written notation into sound, and what we call "dictation" translates sound into written notation.
With that said, musical dictation is rarely as accurate as language dictation, if only because there are often multiple lines happening at once in music as opposed to just a single thought being expressed. When you see (or hear of) musicians hearing a full orchestra and immediately being able to transcribe every musical line, these are savant-level dictation skills; very few musicians have that ability.
Comment: Transcribing a full score from hearing an orchestral piece is a rare ability, as you say. But the direction closer to what OP's describing — reading an orchestral score, and hearing (an approximation of) the orchestral piece in one' imagination — is a standard part of many classical musicians' training; most composers/conductors, in particular, can do this to a very high level.
Comment: @BruceWayne Correct. It may seem odd that there's a different word for it, but since most trained musicians study it, it's used to differentiate sight reading on their main instrument.
Comment: @Richard - there's a difference, though. When sight-reading on an instrument, there's usually (except Theramin!) a physical aspect - the frets, the keys to press, the holes to cover - which doesn't happen with vox. Even violin and trombone have visible places for each note. Love to find out how we sing the right notes! And even in keys that are in the cracks!
Comment: So broadly speaking, sight singing is basically sight reading, only it's the voice that's the instrument, not piano/flute/etc?
Answer: Yes. This is called "sight-singing", and it is a skill that can be learned. Musicians trained in sight-singing typically need to be given a starting pitch and can then sing the song accurately from there.
There are many posts on this site about learning to sight-sing and to train your ear as a part of that process. Search for questions with the tags sight-reading and/or ear-training. That will give you a start.
Answer: It doesn't even have to be a singer, many instrumental players can do this - particularly the tune itself.
It's a very useful skill for any musician to learn, especially for singers. Knowing intervals is key to being able to do it - and it does save an awful lot of time in rehearsals.
A lot of composers will be doing a similar trick while composing - not singing out loud, but hearing the different parts in their heads.
I used to work with vocalists who would turn up at gigs and simply read songs they'd not seen or sung before. Really it's hardly any different from instrumentalists sight-reading well. I guess it would help if a someone possessed absolute pitch, although having a good relative pitch would do the job, the vocalist having a start note or key chord.


Is it better to use sampling rates which are a power of 2? 32-64-128-256-512Hz? instead of using for example 30- 60-100-250-500Hz?

Question: I am recently working with a sensor that I its sampling frequency can only be configured to either 32hz- 64hz- 128hz-256hz... and I was wondering whether using such sampling frequencies have any benefits. For example is it better to use 128 Hz than use 100 Hz? or 64Hz rather than 60 Hz?
Comment: In many cases this will be constrained anyway by whatever HW you are using.
Answer: There's a lot of things that influence your choice of sampling rate.
First of all, of course, the Nyquist theorem, which says you need to sample at more than twice of the signal's single-sided bandwidth $B$ (for real signals)¹.
Then, you often choose a sampling rate that is useful for your system. For example, a lot of 3G/4G/5G systems use sampling rates of 30.72 MHz (or multiples thereof). That's not an elegant multiple of anything (as far as I know) – it just happens to be what the symbol rates in the standard suggests, so it's very useful if you're already sampling at rate that is rational relative to what you'll be using in the end.
That's a generally important rule: Pick a sampling rate that makes sense for what you'll be doing to the signal afterwards.
Then, especially in audio and lower-frequency sampling, you choose sampling rates that are multiples of other rates, so that it's easy to keep multiple subsystems in synchronization. For example, your CD audio sampling rate is 44100 Hz – first of all, that's an integer multiple of 100 Hz, and that's good, because it means it's easy to keep not only the second counter on your CD player correct by simply counting the samples and dividing by 44100, but also things like studio hardware, which tends to have higher "human-readable" time resolution. But, why the strange rate 44100? Well, that rate happens to be $44100=2\cdot2\cdot3\cdot3\cdot5\cdot5\cdot7\cdot7$. Back in the 1980s, when that rate came up, it was harder than it is now to derive good clocks from each other, unless they had an integer factor between them. So, a clock with "all" the small integer factors was chosen. A curious choice!
Another reason to pick a specific sampling rate is noise alignment, or intentional non-alignment. While it's not a sampling rate itself, the NTSC frame rate of 29.97 frames a second is still something that you find in video systems today, so you find a lot of video capturing ADCs that run at a high multiple of 29.97 Hz. And that frequency was chosen so that the zeros of the color information shaping filter didn't interfere with the brightness info.
In the very same motivation, you'll find noise-sensitive systems where the ADC rate is as far as possible from being rationally related to the other dominant digital clocks in the system – so that the noise from these clocks distributes more evenly to the digitized signal.
In other systems, you painstakingly try to align all these clocks – so that clock noise ends up being narrow interferers in the digital signal, and thus can be digitally filtered out using notch filters.
Of course, you also need to be able to get any rate you'd want to use – you can't just by a 876.543 kHz oscillator, even if you wanted to, these don't exist commercially. Sure, you can synthesize one with either a lot of jitter or a lot of effort, but in the end, complexity and cost restraints are relevant for almost any system design.
As you can see, a lot of conflicting reasons!

¹ that's not necessarily twice the maximum frequency in the signal! A lot of systems, especially superheterodyne systems, i.e. systems that have a strictly bandslimited signal on an intermediate frequency (IF) use subsampling, i.e. the sample rate is $> 2\cdot B$, but $\ll 2\cdot f_\text{max}$. The aliasing that occurs doesn't distort the information content, but aliases the signal down from the IF to the Nyquist band. It's a very useful, very common technique.
Answer: Only requirement for sampling frequency is that it should be more than twice the maximum frequency component in desired signal. Any other constraint can only be because of the oscillator design of the ADC circuit. So, the sensor you are working with might be able to generate a fundamental frequency of 32Hz and, using squaring non-linearity to produce 2x, 4x, 8x, ...so on That is why it can be configured only to sample at 32Hz - 64Hz - 128Hz - 256Hz.
Answer: Aside from the good points mentioned in the answer by @Marcus Müller, some other considerations are the required oversampling in Rx (for noise suppression in discrete time domain), similarly oversampling in Tx to ease the design of the analog front end filters.
It is not unusual to get sampling rates in practical wirless deployments that are not a power of 2, but if it possible it makes sense to have it as a power of two for other things like windowing, spectral estimation etc etc.


Is there a way I can customize the application names in the Application folder?

Question: I have so many apps in the Applications folder that I forget what some of them do.  Is there a way to customize the name to be more descriptive, other than renaming the app?  I am afraid that if I rename the app it might not work, like if the app checks to see if it's name has been altered.
Comment: I have updated my answer
Answer: you are right changing the names may have unforeseen consequences later.
You can make a new folder somewhere. Named Apps. Or what ever you want to name it.
Then create alises to the applications Placing the aliases in the new folder.
You can name the aliases what ever you like and have the new folder in the dock.

1, Create the Aliases. Drag Applications to your new folder.
They should automatically choose to be alias files because you are dragging from the Applications folder.
The cursor should become a curved arrow while you are dragging. If not then hold down the alt+cmd keys to make the copies allies files.

2, Now rename the alias files what ever you want. This will not affect the real files.
I have just named some of them here

3, Place the Folder in the Dock. And now when you go to it the Alias file will look like the real apps. Have your names and open the real apps.

You can Also just place any of the Alias files directly on the Dock.
Answer: You can also do this in Launch Pad by creating folders of apps in specific categories (but I also prefer the folders + aliases idea).
Another trick is to use tags/labels to create category groupings of apps. "Graphics Apps", "Productiity Apps", etc. and then you can sort your Applications folder in list view by tags/labels.
Answer: Rather than renaming the files, another idea might be to add tags to help you identify the applications.
Select an application and hit CMD ⌘+I to open the Info window. At the very top is a box where you can select an existing tag or add your own. These tags will be shown in the preview at the right within Finder's column view as shown below.


Moving from Visual Sourcesafe to Mercurial

Question: What's the best way to move a Visual Sourcesafe repository to Mercurial (I'm interested in retaining all history)?
Answer: While I haven't made that particular conversion, I have gone from VSS to SVN using (IIRC) this script.  You'll probably want to look into tailor and do a search for vss2hg.  Also keep in mind that it may make sense to go through an intermediate step like vss2svn + svn2hg or similar.
The primary bit of advice I'd give though is: script the conversion so you can re-run it easily.  That will let you run nightly conversions from VSS to Hg and make sure that everything is converting correctly before you pull the trigger on it.
Answer: I am the author of the vss2hg.pl script and have used it to move many projects from VSS to Mercurial.  It has one or two minor bugs where some comments are not completely converted but I haven't seen any other issues.  It converts complete history and works-around a problem with VSS where a user's PC clock can affect the order in which changes appear to be made.
A version of the script is available here.
Comment: the website is no longer there looks like
Comment: Use the version linked from @Edmund below; he's maintaining it now as we've kicked the VSS habit.
Answer: I used the vss2hg.pl script from here. It is a Perl script, so you need to install ActivePerl first.
It worked great, but I ran into a problem with the dates. It turns out that the script supports three kinds of date formats. By default it is set to the UK date format (in line 547). The other two date formats are commented out in the code. After enabling the US date format, the script converted my SourceSafe database without a problem.
Comment: I made some fixes to the script. You can download it [here](http://edmundv.home.xs4all.nl/sw/vss2hg.pl).
Comment: It seems most of the published links to vss2hg.pl are broken. Can you provide corrections or redirects as appropriate? I have discovered after some trial and error that an old version of the script (linked to from http://mercurial.selenic.com/wiki/SourceSafeConversion) is available at http://mercurial.selenic.com/wiki/SourceSafeConversion?action=AttachFile&do=view⌖=vss2hg.pl and a more recent version is available (but not published anywhere except Google search results) from http://edmundv.home.xs4all.nl/sw/vss2hg.pl
Answer: The Mercurial wiki has this page, which might be of interest: https://www.mercurial-scm.org/wiki/SourceSafeConversion. I've never used Visual source safe, so I don't have any personal experience with it.
I also found a mail from Patrick Mézard about the subject, but unfortunately he writes that a VSS converter will be difficult. He also talks about converting to Subversion first, and then from Subversion to Mercurial. I guess that means that there are VSS -> SVN converts out there. You can probably google that yourself.
Answer: I have done a conversion from SourceSafe to Mercurial for a client. I first converted the SourceSafe database to a Subversion repository and then from Subversion to Mercurial using the hg convert extension. See my blog post for details.
Answer: I just tried using vss2hg and ran into a problem that it only pickup up and converted 1 user. This means all my changesets etc will not be accurate as I won't be able to see who did them. Is this because I've not pre-setup all the required users in hg?
Comment: You might have better luck asking this as its own question.


How can civlization industrialize amidst a zombie outbreak?

Question: In my world, there is a zombie pandemic that happens. The zombies are fast, but can be defeated by a large army. My world a little before the outbreak was close to having an Industrial Revolution. They had good agriculture, had a capitalist way of thinking, a system similar to the putting out system, and begun to mess a little with machinery. Is it still possible for them to industrialize, and how?
Comment: I admit to being intrigued by the putting out system.
Comment: Are these the classic, shambling zombies that can be stopped by a fence or wall and will putrefy in about six weeks regardless of any action by the living? Or are they something else that you are calling "zombies?" Why would an army be needed? Are the zombies intelligent enough to operate in groups? Are your zombies be more vulnerable to slow-rate massed musket fire instead of the more typical traps/obstacles/ladders?
Comment: As written this is a very broad question. Each industrial nation on earth had their own path to industrialization. What makes you think that the addition of zombies suddenly makes this question specific enough to be a good fit for this site?
Comment: Willk: isn't that also called "the oldest profession"?
Comment: They are a mix of several types, but mostly like zombieland, and the setting is Renaissance and medieval with muskets and cannons.
Comment: What percentage of population have turned into zombies? If it's the majority then industrialization won't be possible simply because there aren't enough people.
Answer: Heck, the zombies might spur the industrialization, as a threat.
Think of the zombies as a kind of predator. Early farming humans built walled villages and homes, primarily to protect themselves against predators (including other humans). The walls were made of wood, mud bricks, stones, eventually tall enough and thick enough to protect them.
Industrialization is just the beginning of automation of some prevalent activity that is done frequently. The ideas of industry, assembly lines, and machine assisted mass production begins with some sort of engine.
IRL, that was capturing the natural energy of wind and rivers. The word "mill" comes from ancient roots meaning to grind, as a place it was a building to grind grain (circa 900AD) into a powder (aka flour). The first "industrialization" was indeed about using a water wheel turned by a river or stream as the power source to turn heavy stones that quickly ground grain into flour. Later this was adapted to turn saws, and became the "lumber mill". Elsewhere, on coasts where the wind was fairly reliable on most days, "wind mills" were used both for grinding and for pumping water. In essence the nature of the word "mill" came to mean something besides grinding, it was a building designed to capture energy to turn something.
Many people think textiles were the beginning of industrialization; along with steam engines, but in truth the water wheel at least a thousand years before that was a breakthrough in using non-animal power.
Amid a zombie outbreak, the primary concern of humans is to isolate and protect themselves from zombies, and some clever industrialization and automation can help that. Nobody resists the automation because they all want to live.
Building walls, digging deep ditches, routing streams. Building weapons, swords, knives and nets. Building traps. Building alarm systems. Boiling water for drinking and cooking.
Farming, fishing and hunting can be industrialized. The threat of zombies means we suddenly have far more work to do than we have people to do it; and part of the answer is turning some of that work over to machines that we build to do it. This can be the spur for some genius to invent the steam engine.
I'd begin with a small walled settlement straddling a stream, so we can use a water wheel for power, and even rig it to catch fish for food. (It scoops up the big-enough fish in woven baskets that drain out the water, then as the wheel raises them, the turn of the wheel tips the basket of still live fish into a chute leading to a shore-side pool where the fish will be easy to net as needed.)
That should solve nearly all of the daily protein problem, at least.
I'd posit that after that, the industrialization extends to extending the walls of the village, up and down the stream. Perhaps invent steam engines, and build out, away from the river. Steam engines can be used to both dig (wells, mining) and to pump water, and good well-sites are typically plentiful even a few miles from a stream or river. The reason for moving away might be to farm, but any farm needs to fenced off from zombies, and that's a huge amount of labor best done by machines.
In short, protecting ourselves from a zombie threat can be the catalyst for industrialization, creating factories, and multiplying the effectiveness of people by using machines. Not an impediment to industrialization at all.
Look at the USA in WW II. The entire country mobilized to fight Hitler, the men went to war, the women, for the first time, went to work en masse as factory workers producing weapons. There was enormous cognitive dissonance in the country, Rosie the Riveter and all that, females doing that kind of heavy lifting machine factory work was unheard of, and then suddenly common.
Why the sudden upending? The threat of Germany taking over the frikkin' world, conquering everything if we did not. That external threat forced changes to all of American society and the roles of men and women, permanently. And not just in America, in Europe and most of the world.
The Zombie outbreak is a similar existential threat, and a very good spur for people to consider a whole new model of their society, just to survive.
Answer: Zombies are a potential source of limitless labour
If your zombies are physics busting creatures that seek brains, they can be harnessed to power devices. They can replace fuel sources like coal and help power machines to run industrialization.
Rather than destroying any chance at industrialization, they could enable it.
You can put them in wheel or cranks, dangle a brain in front of them, and power all sorts of machinery.
Anyone who dies can donate their body to industry for a good fee.
Comment: Humans in large hamster wheel arrangements used to provide power for various purposes when water or wind wasn't reasily available. Zombies are less demanding than serfs and peasants, so using zombies for "mindless work" like turning wheels and cranks for power makes perfect sense.
Answer: Industrial Revolution will be delayed
When there is threat to survival, the first thing people will do is to save their lives. As told by Amadeus, in WW II, the entire country of USA started to produce weapons. As told by the U.S. Department of Defense

Prior to World War II, factories in the United States were turning out
automobiles, large and small appliances, and childrens' toys.
In January 1942 — a mere month after the attack on Pearl Harbor,
Hawaii — President Franklin D. Roosevelt ordered the establishment of
the War Production Board.
Its purpose was to convert the factories of peacetime industries into
manufacturing plants for weapons and military equipment for the fight.

The same thing will happen in your world. All the factories will start making weapons and forget other industrial things. So even if your world "was close to having an Industrial Revolution", they will convert all industry into manufacturing plants for weapons.
The Industrial Revolution will be delayed until the danger is over.
Answer: Just England.
Or your equivalent island full of tea drinking scientists and engineers.  Because they manage to purge the zombies from their island with the St Patrick maneuver borrowed from the Irish (they are ok too) snake ridding technique, followed by careful screening of incoming ships (each incoming crew member in turn dances naked on the poop deck under the scrutiny of the portmaster).  New zombies are forbbidden entrance and industry blossoms!
On the mainland the problem is that there is a bottomless reservoir of zombies stumbling in from the benighted hinterlands and so every time they think things are under control - zombomania redux.
Answer: it depend how big the zombie Outbreak.
i mean if zombie infect animal ( like rat and crow biggest animal in city) or insect (like mosquito) , then human will perish.
they must find a place far far from civilization. then they can build safe zone
like island
Comment: Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer).
Answer: Going Underground
It may help an advanced civilization to go underground to quarantine against zombie infection. Technology will develop because they will be living and working in modified mines.
Zombie Limitations
Zombies may be fast, but almost certainly have lost some of their mental capacity (due to the lizard brain thing discussed by many zombie experts). They will either lay in wait or wander randomly. Zombies, like other creatures, will need some form of food to survive although they may be more able to survive on reserve capacities or in a near hibernating state when near starvation.
Limitations of your Civilization
Many civilizations develop mining skills quite early, and are capable of living in caves far before then. Even pre-industrialization the ideas of systematic quarantine was understood as a means to control infection. The combination of quarantine with mining, and perhaps a system of surface holes which lets in surface daylight (possibly covered with glass, which was also developed pretty early and was pre-industrialization) may allow underground agriculture.
The individual communities, because of quarantine-style community separation, will be cut off from communication and exchange with other communities. Each mining city will need to be self-sufficient in some way. If goods need to be exchanged they may have to take a risk using the basket system. Just outside the city gates the exchange product is lain, with the request for the product that is needed. The baskets must then be exchanged with no direct contact. This is supposed to reduce the threat of becoming a zombie.
How Technology May Develop
The earliest forms of industrialization began with water power. Underground streams, springs, and rivers can be controlled for these purposes. Metal casting and blacksmithing will eventually give way to metal hammer forges (hydraulic or steam mechanic presses), which will make robust mechanization of tasks possible. Fuel could be charcoal from trees harvested from the surface, or coal from the mines (indicating rich deposits at different layers, so it must be a geologically unique area for industrialization to work well).
Their thinking, although capitalistic, may also have to adapt to resilience and long-term resource sustainability. This is because without vast interconnected highways and waterways it is very possible to deplete resources too rapidly. This indicates that the actual pace of work within these underground cities will be slower than most modern civilizations.
The underground citizens will be very aware of the zombie threat and will be working towards various methods to keep safe and to defend themselves should zombies come within their perimeters. Eventually they may have to join with other underground cities to fight them as an army (once it becomes apparent that they have the technological means to do so). The avenue by which this happens must be nearly accidental, since this will be so different than the way in which they have done things before.
Perhaps something will cause the dynamic with the zombies to shift. This could include some person of malicious intent deciding to use them as a weapon or some kind or evolution in the zombies that cause them to be more of a threat. Whichever is the case, it will be necessary to band together to survive, which will lead to the vast overground war that you are describing.


How to add/modify/delete a method in Pry?

Question: I am trying Pry for main code REPL editor.
I discovered this is very close to what I was looking for, but I don't know well about how to use it. I want to know how to add/modify/remove each method (or any other members) to/from a class.
When I tried this,
➜  ~  pry
[1] pry(main)> class AAA
[1] pry(main)*   def bbb
[1] pry(main)*     "ccc"
[1] pry(main)*   end
[1] pry(main)* end
=> nil
[2] pry(main)> cd AAA
[3] pry(AAA):1> ls
AAA#methods: bbb
locals: _  __  _dir_  _ex_  _file_  _in_  _out_  _pry_
[4] pry(AAA):1> def xxx
[4] pry(AAA):1*   "yyy"
[4] pry(AAA):1* end
=> nil
[5] pry(AAA):1> def xxx
[5] pry(AAA):1*   "zzz"
[5] pry(AAA):1* end
=> nil
[6] pry(AAA):1> cd ..
[7] pry(main)> Pry.WrappedModule(AAA).source
=> "class AAA\n  def bbb\n    \"ccc\"\n  end\nend\ndef xxx\n  \"yyy\"\nend\ndef xxx\n  \"zzz\"\nend\n"
[8] pry(main)> AAA.new.xxx
=> "zzz"
[9] pry(main)>

It worked well as I expected. But The source code contains duplicated definition of xxx method. If I want to erase older one (or both), how can I do that? Also, if I want to remove existing method (or any other member) without exchanging to a new one, how can I do that?
P.S. I am doing this mainly to edit, store and restore class source code between memory and disk. (a kind of image based persistent)
Answer: I found the answer. Use undef command.
[11] pry(main)> cd AAA
[13] pry(AAA):1> ls
AAA#methods: bbb  xxx
locals: _  __  _dir_  _ex_  _file_  _in_  _out_  _pry_
[14] pry(AAA):1> undef xxx
=> nil
[15] pry(AAA):1> ls
AAA#methods: bbb
locals: _  __  _dir_  _ex_  _file_  _in_  _out_  _pry_
[16] pry(AAA):1> cd ..
[17] pry(main)> Pry.WrappedModule(AAA).source
=> "class AAA\n  def bbb\n    \"ccc\"\n  end\nend\n"
[18] pry(main)>


Attribute Error: 'numpy.ndarray' object has no attribute 'transform'

Question: #Text Representation
from sklearn.feature_extraction.text import TfidfVectorizer
tfidf = TfidfVectorizer(sublinear_tf=True, min_df=2,max_df= 0.3, norm='l2', encoding='latin-1', ngram_range=(1, 2), stop_words='english')
features = tfidf.fit_transform(df.ContextualText).toarray()
labels = df.category_id
features.shape

#Running Linear SVC
from sklearn.model_selection import train_test_split

model = LinearSVC()

X_train, X_test, y_train, y_test, indices_train, indices_test = train_test_split(features, labels, df.index, test_size=0.2, random_state=0)
model.fit(X_train, y_train)
y_pred = model.predict(X_test)

#Predictions based on model
vectorized_text = features.transform("Heathcare is good").toarray()

Comment: Hi @Manan Nawal, thank you for the post. However, we are struggling to understand what it is you are exactly asking and the context behind the issue you are experiencing. Could you edit your post accordingly so then we can help you?
Comment: Hi, and welcome to the stackexchange network. To learn more on how to ask a good question, which is likely to be answered, please visit the site tour (https://datascience.stackexchange.com/tour), especially the "how to ask" part (https://datascience.stackexchange.com/help/how-to-ask).
Answer: Your question leaves a lot unexplained, but the error you're receiving probably came from the last line vectorized_text = features.transform("Heathcare is good").toarray().
The variable features is itself an array (it came from features = ... .toarray()).
I'm assuming you meant to replace it with
vectorized_text = tfidf.transform("Heathcare is good").toarray()?


Where did Noah find polar bears and penguins in Palestine, according to those who accept a global flood?

Question: According to Christians who accept a literal global flood, how could animals accustomed to thriving in extreme temperatures be found in a common place for preservation aboard the ark?
Comment: I don't think they necessarily needed to be on the ark. Both species eat sea creatures and spend significant amounts of time dwelling on floating sheets of ice. They probably just waited things out at the poles floating on their own iceberg-arks.
Answer: First of all I live in the Middle East in the same country as Mt. Ararat where the ark landed. Note this is not in Palestine nor do we know where Noah started from. The problem could just as well have been that he was starting from the Siberian tundra and needed some African wildebeests. You're trying to solve a specific problem that you don't have enough scenario data to build a case for or against.
However back to the plausibility argument. Here in the neighborhood of Mt Ararat there is a zoo here that has penguins. They are kept out of doors and, with the exception of having free access to a small pond, cope with the same baking heat the rest of us deal with. They may not like it but they survive.
Secondly I grew up in the Southwest high desert. The zoo where I grew up had a polar bear exhibit, again out of doors. In more recent years it has acquired some shade and a larger (very fun looking) series of pools but the one I remember as a kid wasn't much more than a concrete box.
As if that wasn't enough to at least cast doubt on the argument against the plausibility of such a thing, let's consider the other implications of the flood.
Hand in hand with the flood come a host of other radical global changes. The arrangement of dry land vs ocean has likely radically changed as tectonic plates rose and fell in order for the water to cover the whole land. How high mountains were, where they were located and even the divides between contents are likely very different.
In the same vein, global climate would have been radically different. Many believe from the Genesis account that there were changes in the atmosphere and that likely post-flood earth has a lot more extremes of hot and cold in different areas than pre-flood earth.
Lastly, it's not always alleged that every variation of species we have today was on the Ark. It's possible a representative of the bear family was all that God required to cover the basis for both polar bears and black bears.
And most importantly, don't you think the God who created the animals in the first place and gives them the instincts that make them what they are could not manipulate the system in a miraculous way to lead a couple of stray bears on a long walk? Similar wild and seemingly impossible journeys by strangely motivated animals have been documented
All in all, the specific allegations you bring up are small items in the big picture. If you really have a problem with the science, you need to start at the other end of the spectrum and work backwards. Those little details sort themselves out in the big picture.
Comment: If you look at the genetic diversity of animals alive now, "manipulate the system in a miraculous way" is the only possible answer.  Then again, the flood itself would have had to be miraculous also--if you really need to assume that there were baby dwarf elephants hibernating on the ark to make everything work, is that really more unpalatable than that there were magnitude 14-15 earthquakes and thousands of feet of water covering the land?  About all we could say is: _In a miracle so profound and dramatic, we cannot know the details._
Comment: This answer was never meant to be a bucket. It was only meant to anecdotal point out how many of the problems posed aren't as slippery as they are often made out to be.
Comment: This answer does not hold water, as @Rex pointed out.
Comment: This answer "holds water" very well, in fact. For one thing there was never a need to get a pair of EVERY animal that humans view as a separate species. Just as with dogs, most likely any pair of a bear would have been sufficient. Besides we can understand from Genesis 7:15 that the animals were directed to the ark by God. As the Creator of life on earth, He would have known what individual animals to direct to the ark in order to preserve the specific species.
Answer: Gen 6:20 reads as follows in the KJV:

Of fowls after their kind, and of cattle after their kind, of every creeping thing of the earth after his kind, two of every sort shall come unto thee, to keep them alive.

(emphasis added)
The sense here is that the animals came to Noah, not that Noah went out and got each animal.  I'm not sure that if I were a polar bear, I'd want to walk all the way from the polar regions to the ark, but if God is compelling the animals to come, then come they would have.
Also, remember that Noah had been building the ark for 100 years before the flood began, so there was ample time for the animals to reach the ark.
Comment: Polar bears could conceivably walk there, but not penguins, most of which live in Antarctica. Nor could koalas, worms and lizards that live in Australia, or tree sloths that live in South America.
Answer: There are two issues with your question.  First, the assumption the polar bears must have been on the ark.  The Bible specifies that there were two of each "kind".  If we take this to mean two of every species that modern science defines, then that would necessitate many more animals on the ark.  If, however, it just means that there were two of each kind, then there would be much fewer animals on the ark.
The idea is that all the genetic information for domestic dogs as well as coyotes (and perhaps wolves) could be contained within two representative wild dogs at the time.  Indeed, we can expose the range of variations in domestic dogs to get Great Danes and Teacup Poodles.
So, if there were two bears that contained sufficient genetic information to account for the various species we see today, black, brown, polar, grizzly, etc., then polar bears need not be on the ark, except within the genetic makeup of the two bears that were selected (probably very young bears--one pink and one blue).
The other assumption is that the pre-flood climate is basically what we have today as well.  There is sufficient evidence to show that this assumption is probably false.  For example, we find wooly mammoths eating tropical vegetation in what are now arctic regions.
Biblically speaking, people lived far longer prior to the flood than they did afterward.  A drastically different climate could certainly account for this.
So, Noah probably took one of each "kind" rather than one of each of the isolated species we see today.  Noah had 8 people--not 2 Chinese, 2 Europeans, 2 Africans, 2 Native Americans, 2 Computer Programmers, etc.  Also, the climate was likely much different then than it is now.
Comment: I guess ultimately if you mean "and was steered a bit by divine power" then all bets are off, and any view might be equal. If you mean "and then continued along the diversity lines that we now have a pretty good grasp of", then such rapid specialisation could only occur, as with dogs, by deliberate breeding for example by man. There's no robust evidence that I know of to support that kind of rapid *natural* speciation, and we have no records of ancient bear-breeding (etc) by man. But if you mean "with divine steering", then : as you like.
Comment: There is a huge difference between **breeds** (dogs etc, which is purely a husbandry term), and **species**. The ability (in controlled, deliberate, managed scenarios) to breed dogs with favoured characteristics does **not** extend to simply unloading the ark. Managing the breeding to the point where *species* develop would take a lot more work than merely breeds, and is not supported by history. One estimate of the difference between, say, "brown bear" and "black bear" is [1.5-2.5 million years](http://www.polarbearsinternational.org/polar-bears/polar-bear-comprehensive/evolution)
Comment: @MarcGravell The 1.5-2.5 million year guess is not supported by history.
Comment: "There's no robust evidence that I know of to support that kind of rapid natural speciation". Well, let me [help you with that](https://cosmosmagazine.com/biology/new-species-evolve-in-just-two-generations/). Another point to keep in mind is that the animals on the Ark would have had much more genetic *potential* than animals do nowadays. (And if you showed a paleontologist a Chihuahua skeleton and a Great Dane skeleton and claimed they were the same species, he'd laugh in your face. Seriously, why is this stuff so hard to believe?)
Comment: @MarcGravell http://www.biblicalcreation.org.uk/scientific_issues/PolarBears_Tyler.pdf
Comment: hybridisation is different to speciation; finding a viable hybrid does not mean that you can trivially breed *from* just one to there, in any appreciable time
Comment: @MarcGravell Yet, to say that it can't possibly happen is a bit of a stretch.
Comment: @Matthew:  What do you mean by genetic potential?  And why would animals a from a few thousand years ago have more potential?  I'd also like to point out that the definition of *species* is not so clear cut as indicated in the (quite fascinating!) article you linked.  For example, see examples of https://en.wikipedia.org/wiki/Ring_species, or anything which reproduces asexually.  (And note that the Wikipedia article itself seems to cast doubt on ring species.  The whole idea of a good definition of species is a mess.)
Comment: @JasonDeVito, to answer your "why" first... because entropy? Because mutations are harmful far more often than neutral (and *never* result in gain of information). As to diversity, [this article](https://answersingenesis.org/creation-science/baraminology/variation-yes-evolution-no/) goes into some detail, but the short version is that *heterozygous* genes (i.e. more information) allow for more possible traits (e.g. stripes *or* spots). Natural selection comes along and selects against stripes, and soon only the genes for spots remain; that's loss of information / genetic potential.
Comment: @JasonDeVito, in the beginning, you have a wolf (canine). The wolf has genes for being big, small, short-furred, long-furred, white, black, etc.... and as a result is somewhat nondescript. Some might be white or black (n.b. Mendelian genetics), but mostly you have gray. When selection (natural or by humans) starts ensuring that only certain traits survive, you start losing genes; you get only short hair, or only long hair, or only black, or only white... and soon you have Great Danes and Chihuahuas / many species of "dog"... but these are less heterozygous than the original wolf.
Comment: @Matthew:  I appreciate the prompt reply.  I must say, everything you wrote above seems quite speculative.  Entropy only applies in closed systems.  And while I agree that by-and-large, mutations are harmful (or neutral), this doesn't preclude  a gain of information.  "Never" seems too strong, to me.  Do we actually have genetic studies which indicate this loss of information occurs frequently enough to matter over approximately 10,000 years?
Comment: @JasonDeVito "Entropy only applies in closed systems"; yes, but no one has *ever* observed information to originate from a source other than intelligence, nor life to originate from non-life. Not even tiny bits. And the amount of information in modern life is mind boggling. Perhaps if the universe were *actually* infinite (though, even then, evolution makes many predictions that we don't see fulfilled), but in any *realistic* sense, it's impossible. (May I suggest [chat](https://chat.stackexchange.com/rooms/134852) if you'd like to continue this conversation?)
Answer: Couldn't the answer simply be:  "God 'snapped his fingers' and there they were."  Because that is how other non-natural events' origins are often attributed in Christian traditions (e.g., the Red Sea parting, the burning bush, virgin birth...or, well, the creation of the entire universe).  If God is taken to be omnipotent, what is the point of thinking anything mentioned in the Bible is, in your word, "implausible".
This is an answer for any implausibility you could find with this story (or any others). Not enough room on the ark?  SNAP!  Sure there is--it's like the TARDIS.  Etc.
I have trouble understanding why, if one believes in the existence of an omnipotent being, one is later stymied by "challenges" he and his followers might face.
Comment: Isaac Newton felt called by God to understand how God worked the miracles of Creation. Fundamentally, scientists - Christians amongst many of the founders - are not satisfied with the "miracle" explanation, not because they don't believe it, but because it shuts of inquiry. Jesus himself asked a lot of questions, so it isn't like God doesn't want the questions asked or investigated.  So, to answer your query, Christians ask how miracles, etc... occur because we want to understand how God works more fully. That's how we all learn.
Comment: Fair enough, but I guess I would still stress that while omnipotence is the ultimate answer, to rely on a base definition of it will appear to many as a cop out. I do want to make clear, I think you're right, but I'm not sure the answer adds much. God doesn't do magic, he does miracles.
Comment: @AffableGeek My answer was a direct response to the OP saying the account of Noah's Ark seemed "implausible", and so my discussion of omnipotence was intended to obviate the concern of implausibility.  Maybe, instead, what remains in your mind is not a doubt that it is plausible but a wonder at *by what intermediary means* God brought about the ark events, just out of curiosity about the "style" of the creator.  Something like that?
Comment: Oh, and my daughter and I both heartily approve of the Doctor reference ;)
Comment: @Jeff I don't think so; look at the front page--the most recent questions--and tell me if most of those are answered sensibly by, "Because God says so.".  For example:  "What do Christians mean by a 'personal relationship' with Jesus?".  Etc.  But yes, for quite a few of the questions, I understand how my answer could be seen as incurious.
Comment: If the people on this site were to accept the answer that "God can do anything at any time. Why bother questioning it?", this whole site would be irrelevant. Every answer for every question, "Because God says so."
Comment: The volume of the ark would have been a little over 1.5 million cubic feet.  By contrast, an elephant (full grown) as about 200 cubic feet.  A squirrel is about .02 cubic feet.  I'm not sure the ark has to magically expand.
Answer: Let's address this question for the different views which are common about the Flood:

The description of the Flood is to be taken literally, word for word, as a depiction of real historical events about a global Flood.
In this case, it's a miracle. A global Flood which covers all the mountains of the Earth can not happen naturally, there is not enough water for that on the planet, so it was a miracle. In case of a miracle, nothing is impossible, and the acquisition of penguins and polar bears is dwarfed by much stronger "violations of the laws of nature how we unterstand them".

The description of the Flood is based on real historical events about a local Flood. In this view, the "whole world" actually means the whole world known to the people of that time. In this case, there is no need for penguins and polar bears, as they were outside of the areas affected by the Flood.

The description of the Flood is largely symbolic. Just as in point 2., there is no need for penguins or polar bears here.
Comment: Comments are not for extended discussion; this conversation has been [moved to chat](https://chat.stackexchange.com/rooms/135541/discussion-on-answer-by-vsz-where-did-noah-find-polar-bears-and-penguins-in-pale).
Answer: One school of thought on the flood holds that it was not in fact global, but just occurred in Mesopotamia.  The argument is that Psalm 104 indicates the earth would never be fully covered with water after the creation, and the Hebrew words for "whole earth" in the flood account generally indicated a local area.  So Noah only had to save "local" animals, which, presumably, did not include penguins and polar bears.
Comment: That *does* conflict with Genesis 7, though. Interesting.
Comment: +1 - not that I agree with the argument, but it is one of the major explanations given.
Comment: @Marc: No it does not conflict with Genesis 7 - the Hebrew word translated "earth" (eretz) has a wide scope of meaning that includes various scopes of land/territory including the concept of "extent of human civilization at that time". The "whole world" can easily and comfortably mean only the whole of the lands in which mankind dwelt. Gen 8 lends a great deal of credence to this idea, where the tops of the mountains were seen only after the ark came to rest and Gen 8:9 then says that "the waters were still on the face of the whole earth", though the mountains were already visible.
Answer: I think there are some misunderstandings in your question. While there are other, good answers already, perhaps I can be a bit more explicit.

According to Christians who accept a literal global flood

"Christians who accept a literal global flood" will almost universally also accept that the majority of the (sedimentary, fossil-bearing) rock strata were deposited by that same flood. Since this obviously contradicts the alleged millions of years required for such deposition (and there is much scientific evidence to support such a claim), we can be more specific here and indicate that we are talking about "Young Earth Creationists", i.e. those that believe the Earth is ~6,000 years old.
I want to make this point specifically because it clarifies what sources we may use in defense of an answer, and why we can defend using the totality of claims of a historical reading of Genesis 1-11 without being limited to just "a global Flood".

how could animals accustomed to thriving in extreme temperatures be found in a common place for preservation aboard the ark?

So, first off, most YECs believe that there was a single continent prior to the Flood. There is good cause to believe that the climate may have been different as well. This already eliminates both the issue of how a pair of animals made it to the ark and how they survived the climate. Even so, neither of these were issues to start; there was around a hundred years or so of warning prior to the flood, leaving plenty of time for a group of animals to migrate from anywhere in the world, and many animals today can survive in a wider range of climates than what they typically inhabit.
That said, it's important to understand that Noah did not bring one of every "species" of animal on the ark. Our current definition of "species" is rather flexible and poorly defined, and has no Biblical basis whatsoever. Rather, God created animals after their kinds, and each kind was Created with significant ability to adapt to its environment. You can see this somewhat with domestic dogs, but also you can look at what animals are capable of interbreeding. For example, wolves, coyotes, jackals, dingoes, etc. are all part of the dog kind; zebras are part of the horse kind; and so forth. More particularly, polar bears are part of the bear kind.
Thus, Noah did not need to take polar bears, specifically, but rather one pair of bears. Since the flood, that one pair would have diversified into the many species of bears that we have today, including polar bears. Similarly, cold-weather penguins probably came from a pair that was more comfortable in temperate weather which then diversified into the various cold-climate and even tropical penguins that exist today.
This article and these articles go into more details, and there are many other resources to be found at those sites.
Answer: Also:
The flood was global, otherwise God most probably wouldn't have instructed Noah to build such a big vessel to accommodate just the regional animals and birds.
Ice floats on water, so the flood wouldn't affect animals and birds that live on ice.
More than 50% (or likely, more than 75%) of the animal kingdom including fish lives on water; then there is another percentage that are amphibians, all of which wouldn't be affected by the flood.
How did all the animals fit on Noah's Ark?
How big was Noah's Ark?
Comment: Arguing in comments is not cool.  There's [a chat room for the creation/evolution debate](http://chat.stackexchange.com/rooms/1254/creationism-vs-).
Comment: Welcome to the site!  This doesn't really have much to do with your answer, but I find that sharing the following tends to help new visitors avoid mistaking the purpose of this site. I do hope to see more from you!  When you get a chance, please see [How we are different than other sites?](http://meta.christianity.stackexchange.com/questions/1808/how-we-are-different-than-other-sites) and [What makes a good supported answer?](http://meta.christianity.stackexchange.com/questions/692/what-makes-a-good-supported-answer)
Comment: **Mod Notice:** __ Please note that the comment feature is NOT for debating the issues. They can be used to request clarification on a post and if the author thinks it deserves response they should [edit] the post itself, after which point the comment will be removed as obsolete.


Bigger battery for my Toyota corolla 2015 le

Question: So I got some subs in my car they say they have the potential to pull at max 10 volts each so it'll be maybe 20. My battery is a 12volt and I'm really wanting to get a battery with more volts to make sure it doesn't crash on me but I can't find anything at all helpful please help.
Answer: It's important to double check your terminology. I expect that your sub-woofers would have the ability to draw power at ten to twenty amperes, not volts. Your battery and the electrical system can provide only a limited amount of power (unknown to me) over a limited period of time.
If you want to upgrade an existing battery, consider first the physical space it occupies in the vehicle. It's not practical to shoe-horn a larger battery into the same space. I suspect that you've learned that other rolling boom-boxes add additional batteries, rather than replace one for a larger version.
Additionally, with a larger battery or a second battery, it will charge with the existing alternator at the manufacturer's maximum rate (when needed). Beyond that point, you may have to purchase a replacement alternator with a higher current capacity.
You can get away with a larger battery or a second battery without replacing the alternator if you recognize that the combination may have limitations on continuous use. It's practical to consider, for example, that your battery selection would provide sufficient power to your sound system for 4 hours continuously, but after that point would deplete the battery and eventually damage it or the alternator. Please note that the 4 hour reference is imaginary. The true duration depends on information not provided in the question, as you've not increased the amp-hour capacity of your existing system.
Comment: Also, for the relatively small subs the OP has, the usual solution is a large capacitor, not a bigger battery.


Adding to New context menu item in Windows Explorer

Question: When I right click within an Explorer window, down in 'New' I of course have the option to create a new folder, text file, etc. there. I would like to add the option of opening a cmd 'black box' window in the directory in which I right clicked. Is there a way to do this?
Comment: Something like this?  http://www.petri.co.il/add_command_prompt_here_shortcut_to_windows_explorer.htm
Comment: Yes, thanks. I also just learned that in Windows 7 (which is what I should have mentioned I am using), I can hold the shift key and then right-click on a folder and see the option to open a command prompt with that folder as the current directory.
Comment: If you found something that answered your question there, you might want to add that as an answer, then accept it.
Answer: I learned the answer that works on Windows 7. Holding the shift key and then right-clicking on a folder causes the option "Open command window here" to be available. You have to right-click on a folder icon of the directory you want to open a command window in, not just in Windows Explorer's right pane in the folder you want to open the command window in.


Booting into a Graphical Based Program in Debian (Raspberry Pi)

Question: I am trying to boot into chromium on a Raspberry Pi running debian. However on boot it goes to a full screen command line with no graphical display. I have in /etc/init.d/ a script that starts up chromium on boot, however this fails to work as it there is no graphical environment started therefore it fails to start. Is there a way to boot Chrome on startup in a graphical environment.
Answer: If you are running Raspian, the Debian image for Raspberry Pi, you can run raspi-config and check to make sure your Pi is configured to run in desktop mode, as that is what it sounds like you are trying to do.
sudo raspi-config

from the terminal should do the trick. The link below explains how to toggle boot mode:
http://www.dingleberrypi.com/2012/09/tutorial-prepare-your-raspberry-pi-to-become-a-web-server/
I dont think it is possible to stay in 'boot to console' mode and still be able to open a gui application on startup, it that is what you are trying to do...
Hope this helps,
nim
Comment: Exactly what I needed, thanks. Will booting to desktop require any form of login? I want it so that when it boots up it goes right to chrome with no login needed.
Comment: That depends on whether the user account you are logging in with has a password; 'out of the box' the default pi user account did not require a password IIRC. If you find that the account does need a password to log in, then I would suggest just creating a new user and then setting that user to not require a password. This is so that you will have a user account that can log in without a password and that does not have admin rights, and you would still have a known user account that I am assuming **does** have admin rights. Does the account you are using currently require a password to log in?
Comment: Yes, the account I have which has admin access does have a password. I n fact by default Raspbian has the user pi's password set to `raspberry` though I have changed it from this. If I create an account with no password how would it know to boot into the desktop environment using that account?
Comment: I have never tried to do this, and am unsure how. I also dont know if you will become barred from root access if you wipe the password from the pi account without another account in the sudoers file. You may want to post another question about debian + user accounts and passwords. In any case if you still wanted to try (though i don't advise it without more research, just to be safe), here goes; To remove the password from an account type this in the terminal: `passwd -d username` replace username with the real account name. You will now be able to log in without a password


Input fields not visible on Community

Question: I have created a VF page for add employee with 12 fields and added to community. These fields are visible when i login as salesforce user. But when i login as community user 4 input fields do not show up only the label is visible.
This 4 fields which are not visible are lookup fields where the controlling field being account. Is there any settings i need to enable?
Answer: This appears to be issue with Field Level Security. Provide appropriate FLS at community User's profile.
To set FLS follow

Setup->Manage Users->Profiles
Open Community User's Profile/Profiles.
Go To Field Level Security Section .
Click view against the object to which your fields belong.
click Edit to modify FLS as per your requirements.
Comment: Hi Mukesh,    Thanks for the help. I did change the fls and now i am able to see some fields and some fields are still readonly even after giving the edit permission on fls.
Comment: Its resolved with profiles i also added fls on permission set that resolved the issue. Thanks for the holp Mukesh.

Input fields not visible on Community


Anode RGB LED Arduino Hookup

Question: My question is regarding the hookup of a radioshack bright rgb anode led.  I have the led common going to a 5v supply and the other pins are going through a 330ohm resistor to 3 PWM output pins (9,10,11 on the Arduino Uno). I set the pinMode() on each pin to OUTPUT, and then I do a "analogWrite(RED_PIN, 255);" and set the other color pins at zero.  It should be red, instead it's dark purple.  If I do a "digitalWrite(RED_PIN, LOW);" the red led is fully lit.  My question is why is the digitalWrite() working and the analogWrite() not? I am new to electronics so excuse me if I used the wrong terminology, I'll do my best to clarify.
Answer: Setting the PWM duty cycle to 255 is the opposite of the digital write with low. The duty cycle of 255 means the pin is driven high (5v) 100% of the time. I suspect if you reverse your logic of the Analog writes you will get your intended results.
Comment: That did the trick!  Thank you, I should have known I even flipped the digitalWrite()'s to LOW instead of HIGH.
Answer: Just to add some clarification on why the analogWrite did not work as expected. You state the LED's are common anode, and so the RGB pins going to the arduino are negative wires. Therefore, when you  write analog 255 (or digital high) to the pin, you are turning off that color to the led - because it is not grounded and the circuit is broken. When you write low to the pin, you are grounding it (sinking it) and the circuit is complete, which turns the LED wire on.

Anode RGB LED Arduino Hookup


Custom fields to taxonomy

Question: Can I add some custom fields to specific taxonomy so when ever I call that taxonomy, custom fields attached to that taxonomy should also appear.
Answer: You can hook into the edit form field action of that specific taxonomy.
If you look in /wp-admin/edit-tag-form.php  there are hooks for every taxonomy.
Starting at Line 69:
        if ( 'category' == $taxonomy )
        do_action('edit_category_form_fields', $tag);
    elseif ( 'link_category' == $taxonomy )
        do_action('edit_link_category_form_fields', $tag);
    else
        do_action('edit_tag_form_fields', $tag);

    do_action($taxonomy . '_edit_form_fields', $tag, $taxonomy);

So for a custom taxonomy, it would be $taxonomy_edit_form_fields with $taxonomy being the taxonomies name.  So you would add the hook, within the function, add your form fields.  Then you also need to hook into the 'edit_term' action and if your form fields aren't empty then save it as an option using update_option().
This won't allow you to just "call the taxonomy" and have them already attached to the object, but you can loop through your terms once you get them and get the option associated with that term very easily.
Answer: I developed a small script that simplifies the process of adding custom fields to taxonomies (both core & custom), and optionally lets you add columns to the terms table for each field. The script is called amarkal-taxonomy, and is part of the Amarkal WordPress framework.
Using amarkal-taxonomy, adding a custom field simplifies to:
// Add a text field to the 'category' taxonomy 'add' & 'edit' forms:
amarkal_taxonomy_add_field('category', 'cat_icon', array(
    'type'        => 'text',
    'label'       => 'Icon',
    'description' => 'The category\'s icon',
    'table'       => array(
        'show'      => true,  // Add a column to the terms table
        'sortable'  => true   // Make that column sortable
    )
));

// Then you can retrieve the data using:
$icon = get_term_meta( $term_id, 'cat_icon', true );

You can change 'category' to whatever your taxonomy name is.
Comment: hmmm to answer an old question  just to link to your own product borders spam
Comment: @MarkKaplun It's an open source script that solves the problem that is addressed in the question. Nothing spammy about it.
Comment: your answer adds nothing to the accepted answer, and therefor it seems like its whole purpose of existence is SEO. Sane answer could have been given by the authors of ACF, CMB2 or whatever other frameworks are there, but none of them has done that....
Comment: @MarkKaplun many answers on stackexchange offer solutions to questions using a certain framework. If the author of another framework (like ACF) would have done the same, there would be nothing inappropriate about it.
Comment: If the answer can help anyone who stumbles upon this question, then the answer has served its purpose. I'm sure that many other developers who are looking for a way to add custom fields to taxonomies would appreciate an approach that doesn't involve writing 100+ lines of code.
Comment: answers should be good answers not just "maybe it will help someone" your answer is almost a "link only answer" which is generally a no-no around here.

Custom fields to taxonomy


Correlation between study time and eyesight problems

Question: Are there studies on the correlation between the time a kid spends on studying which includes reading/writing/doing homework/using computer etc and any eyesight problems they develop?
Answer: Yes and no.  I'm not going to link the study because I can't find it right now, but the general consensus I've found when looking into this matter is that there can be some temporary strain, especially associated with computer usage (14+ hours a day) or reading in low light, but that in general it all sorts itself out after a night's sleep.  I have seen no evidence to demonstrate any long term ramifications of time spent studying on eyesight.
Comment: I hope that holds for adults as well.
Comment: That is what the studies I've seen seem to indicate.  Tag me again if you want me to try and dig it up.
Comment: Only if you have it on hand, I would not worry otherwise.
Answer: So there is definitely a link between time spent studying and Myopia. It looks more like correlation than causation though. The real culprit seems to be - lack of daylight exposure.
See this article in this week's Economist.
Quoting from the article:
Excerpt 1:

A study of Inuit in Alaska, published in 1969, found that myopia was
virtually unknown in those middle-aged or older, but that rates were
above 50% in older children and young adults. Such a change is much
too fast to be purely genetic, and it had happened just as the study
participants had begun to adopt a more settled, Westernised way of
life. But the results went against the dogma of the day, says Dr
Morgan, and were ignored.

Excerpt 2:

And an intriguing study on orthodox Jewish children in Israel, in the
1990s, confirmed the link with long school hours. It showed that
boys—who receive intensive religious education in addition to the
normal curriculum—were more myopic than their sisters, who do not.

Excerpt 3:

Instead, the dominant hypothesis now is that exposure to daylight is
the main variable. A study of Californian children, published in 2007,
found that time spent outdoors was strongly associated with a lower
risk of myopia. Another paper, published the following year by Drs
Rose and Morgan and their colleagues, followed more than 4,000
children in Sydney for three years and came to a similar conclusion.
The type of activity—sports, walking, picnics—did not seem to matter.
Simply being outdoors was the crucial point. The researchers
cross-checked the close-work hypothesis and found that being outside
drastically reduced the risk of short-sightedness, even for children
that did a lot of it.

Excerpt 4:

Human trials, too, confirm the theory. One of the biggest, led by
Pei-Chang Wu of the Chang Gung University College of Medicine, in
Taiwan, was published in 2020. It reported results from millions of
Taiwanese primary-school pupils who had gone through the school system
between 2001 and 2015. In 2010 the government instituted a programme
called "Tian-Tian Outdoor 120", which encouraged schools to take
pupils outside for two hours a day. After it was implemented, rates of
myopia fell, slowly but steadily, from 49.4% in 2012 to 46.1% in
2015—reversing a decades-long trend of rising rates.


English idioms about inefficiency

Question: Is it right to say about something inefficient, for example: 'This process is poorly organized. It's like one leg is running and another is walking?'
Comment: Nor sure about an idiom but it does sound like a cool analogy.
Comment: I'm guessing you got this idiom from Russian, because my grandma also uses it.
Comment: There is the idiom, "Two steps forward, one step back" to describe a tough experience trying to get a job done. This expression doesn't blame the person making the effort for the difficulty but it is more about the nature of the problem being difficult to make headway on.  Sometimes that is turned into 'one step forward two steps back', humorously to say that the harder you try the worse things get.
Comment: I'm not aware of this idiom in Russian however, I speak rus. It's just an analogy.
Comment: That gait trips past *inefficient* to fall at *downright dangerous*.
Answer: That phrase is not a common idiom in English.  However, a similar idiom related to limbs exists and means something very similar:

the left hand doesn't know what the right hand is doing

The idiom is defined per Dictionary.com:

The actions are uncoordinated, especially when they are contrary, as in
Purchasing has placed the order and accounting says we can't pay for more supplies this month; the left hand doesn't know what the right hand is doing.

It relates to the phrase you described above in that it makes a figurative description of inefficiency by pitting the one arm against the other, similar to "one leg is running and another is walking."

English idioms about inefficiency


How to turn off Envelope and Body in SOAP request

Question: This is critical to my current project. I have written a client in C++ using Windows web services. This client talks to the Clickatell SMS SOAP web service. I have tested the request using the SOAPUI tool and get correct response. I also receive the SMS message. Now, when I do this programmatically it fails because the WsCall() [in the code generated from WSDL via wsutil.exe) inserts  even though the SOAP request I have already includes Envelope and Body. I cannot take out my Envelope since I have namespace specified in it like this:
http://schemas.xmlsoap.org/soap/encoding/\" xmlns:s=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:SOAP-ENC=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:tns=\"soap.clickatell.com\">
I know that the additional Envelope and Body are inserted since I see it in the Fiddler tool.
Any help I can get is highly appreciated!
Answer: Looks like you are using the older type rpc/encoded soap api.
Have you tried using the document/literal service?
(http://api.clickatell.com/soap/document_literal/webservice.php?wsdl)


How to make lemon powder using lemon juice like milk powder?

Question: Recently I had a good lemon harvest , and I'm experimenting with it . I like to know if I can make lemon powder , so I can use them later . I tried heating , but it all went black and became unusable , is there a way to remove all the water in lime juice without harming the taste ?
Comment: It's not powder, but there are ways to put them up for later.  For example, Morocan preserved lemons (salt cured).  I suspect you could can lemon juice, as it's acidic enough, but in [recipies for canning lemon curd](http://nchfp.uga.edu/how/can_02/lemon_curd.html), they call for bottled lemon juice so they can be more assured of the acidity.  (I'd get some litmus paper and powdered citric acid if it needed adjusting, once I knew what acidity level was needed)
Comment: Buy booze and make a bunch of limoncello?
Comment: Is powdered peel a viable alternative?
Answer: The problem is that you likely cannot afford it. It is done by vacuum, so the machine (rotovap) will cost you about 10 000 dollars, or you can find a few Chinese noname suppliers for maybe 6 000.
It is an amazing thing to play with in the kitchen, but it will cover the cost of buying supermarket lemons for several lifetimes.
Any conventional ways of conserving the lemons will result in something entirely different. Certainly not lemon powder which can be rehydrated to something lemon-juice like. But there are other techniques for preserving lemons, which simply create a different end product with different uses. You could ferment them, or make jam, or preserve the peel only, etc. This is the more feasible way to deal with them.
Comment: You could use a freeze drier (Lyophilizer) instead of Rotovap, Vacuum pump and cold trap shouldn't set you back more than $500. I think either Rotovap or Lyophilizer might fail to give you a powder though, because some of a lemons flavor comes from compounds like limonene: https://en.wikipedia.org/wiki/Limonene which are liquids. I've never seen lemon powder, so I best you'll end up with at best a paste if you pull out all the water.
Comment: If we are freezing lemon juice then do we need to add anything to keep the taste as it is for a time?
Answer: I have placed fresh squeezed lemon juice in a Harvest Right freeze dryer. It does turn it to a powder. Within a short amount of time it changes to a sticky clump. I have been reading that you add Maltodextrin to it so it will not cake. I am interested in the ratios of this.
Comment: Welcome to [cooking.se]! We're a Q&A site and not a discussion forum, so if you have another question, please ask it by clicking the [Ask Question](//cooking.stackexchange.com/questions/ask) button and link to this question for reference.


particle velocity in the definition of specific acoustic impedance

Question: Specific acoustic impedance is defined as the ratio of acoustic pressure and acoustic particle velocity.
My problem is that the particle velocity is a vector, so the above definition doesn't really "compile".
What is missing from the above definition?
Comment: It is the magnitude of the velocity which is used.
Comment: Are you sure? I am asking since in 1D problems (where the velocity is a scalar) the velocity itself is used, and not its absolute value.
Answer: The specific acoustic impedance, according to Fundamentals of Acoustics by Kinsler et al. (2000), is a

characteristic property of the medium and of the type of wave that is being propagated.

Indeed, the component of the particle velocity vector that you choose depends on the type of wave, but you typically choose it along the direction of propagation. For example, for plane waves propagating in the $x$ direction, you choose the $x$ component of the particle velocity $\vec{v}$, namely $v_x$. For spherical waves, you would do the same, and the direction of propagation here would be along the radial coordinate $r$, so that the impedance is $z = p / (\vec{v} \cdot \hat{r})$.
The pressure $p$ and the particle velocity $\vec{v}$ are generally complex frequency-domain quantities, which means that the impedance may also be complex. The polar angle $\arg(z)$ then represents the phase lag between pressure and velocity. For spherical waves, for example, there is such a phase lag close to the source, which diminishes into the far field. For plane waves in lossless media, however, the pressure and velocity are always in phase.
Things get hairier for more complex wave fields, such as multiple overlapping plane waves propagating in different directions. Here, the particle velocity $\vec{v}$ would not necessarily just go back and forth in one direction like it does for plane and spherical waves, but might swing around in different directions. In practice, however, I don't really think I have seen specific acoustic impedance being used in such cases.
Normal specific acoustic impedance
As a sidenote, you may occasionally come across the normal specific acoustic impedance, especially when looking at reflection and transmission between different media:
$$z_n = \frac{p}{\vec{v}\cdot\hat{n}}$$
In this type of acoustic impedance, the component of $\vec{v}$ is given as the normal component to some interface whose normal vector is $\hat{n}$. Thus, this is a type of impedance where the question of which component to use is given. Therefore, normal impedance can easily be applied to more complex wave fields.
Comment: Thanks. I think you should also add to your answer that the pressure and velocity should be in the frequency/Laplace domain.
Comment: Good idea, I just added a paragraph about that.


Can VS launch FireFox in a new window when hitting F5?

Question: I am using FireFox as my default browser. I am using the setting "Open new windows in a new tab instead", since this is what I prefer when just browsing the web. However, this means that when I hit F5 in VS to start debugging, the web app is opened in a new tab in the active FireFox instance, alongside any other tabs I have opened already. I would like to separate my debugging sessions from my normal browsing so that VS always opens a new browser window when debugging, but at the same time keep my normal browser preferences for regular browsing. Is it possible somehow to tweak the way VS opens the browser when I hit F5?
I have already tried the "Start external program" option in VS, with command line arguments to open FF in a new window. The problem is that VS does not attach to the process, which makes it pretty useless.
Answer:
Open a WebForm file in VS (anything ending in .aspx  will do)
Select the "Browse With..." option from the File menu
Select your preferred browser from the list and click the "Set as Default" button
Comment: source: http://stevenharman.net/blog/archive/2007/08/02/setting-a-default-browser-for-visual-studio.aspx
Comment: Thanks, but I am not looking to just set the default browser. My default browser for debugging *is* firefox just like I want it to be. I am looking for a way to customize the way firefox is launched from within VS.