What is the best way to record an audio conversation made in Skype?

Question: I will be interviewing someone in a few weeks for a story, and we won't have the opportunity to meet in person. Therefore, the interview will be done on Skype or something along these lines.
What's the best way to record both me and the person I'll be interviewing?
Comment: May want to specify this is for MacOS and not the iPhone or iPhone version
Answer: I suggest you use Ecamm Call Recorder. It's a plugin for Skype that will record both sides of the conversation into separate tracks. If you need high quality audio, you could have your interviewee record their own audio locally with QuickTime and send you the audio file. We use a combination of these two to create the Ask Different Podcast - individual QuickTime recordings for quality, and a Skype recording that we use to sync up the conversation.
Comment: Sounds good, I'll look into it.
Answer: This is a solution involving exclusively  free applications that I found in a great answer here. It involves Soundflower and Audacity. A great video on how - here. It seems that it's superior to the payed solutions, which I found discussed on the net, but which do not provide the same level of customization and complexity (especially, separate tracks and channels).
I will replicate that solution here with some adjustments according to my system. I have tested this on Mavericks. For more details of the rationale behind this solution, see the links above.

First, install Soundflower. Restart probably needed.

(From the aforementioned source:
Why You Need Soundflower
...you need a separate set of speakers and an additional mic so that Audacity can listen to the output from the speakers through the second mic. We're assuming you don't want to buy any additional hardware, and this is where SoundFlower comes in. Using SoundFlower, you will create a separate audio stream i.e. a virtual sound device that you can route the output audio to, and then have Audacity listen to it as if it were input from a second mic.)

Install Audacity. Just copy the entire folder into Applications (or in a different location if you must).
Open Sound settings and modify like below:

Go to Applications > Utilities > Audio MIDI Setup and from the Window menu, select 'Show Audio Window'. What you have to do here is to reroute the audio to an output device (a virtual one) that Audacity can listen to and record from. From the plus sign at the bottom, select 'Create Multi-Output Device'. Once created, select your output source (we were using our built-in speakers) and Soundflower (2ch).

Next, click the plus sign again and select 'Create Aggregate Device'. Here, select your input device.

Go to Skype's preferences and select this newly created 'Multi-Output Device' as the output device for 'Speakers'. Your audio output from Skype will be routed to it

Start Audacity (relaunch if already running). Go to Preferences and make these changes: change device to 'Aggregate Device' and its channels to 3 or to 4, so that you will have one or (why not) two channels for your mic, and two for the other person's audio.

Start recording the Skype conversation. Use a test call first. (Then, use a real call but only for testing purposes. See if after several minutes distortions occur. If so, you may try a different sample rate in the Aggregate Device settings...)

You will get a three-channel audio, that is, your voice and that of the other person will be separate tracks into separate channels.

It might be a good idea to save your project, thus having the conversation in the original format of Audacity, for future editing, if needed. But in order to save the conversation for use outside Audacity, you have to export it.

By default, Audacity will try to downmix to mono all the tracks (make one track out of them). You might want to keep them separate: that is a big plus if, for example, you record an interview, which needs to be transcribed and therefore needs to be listened in detail. Your voice and that of the other person can be easily heard/edited/exported separately if they happen to superpose.
So, go to Audacity's preferences and change to use custom mix for export

You will be presented with options regarding the channels settings. You should probably leave them unchanged - see below; (or, if you really need to, you can put different tracks into one channel, or one track in multiple channels, or even increase the number of channels.)

To see that you got the separate channels in the exported audio file, open it in Audacity. In case the voices are superposed and it's difficult to understand what a person says, you may hear the voices separately, if they are on separate channels, by listening to only one channel at once.  For this, select the 'Solo' option for that channel, and then play.
That's why it is better to leave each track in a separate channel - as they are by default if you use custom mix for export. (Then, you can also export only that channel or a part of it etc).

IMPORTANT!
The changes made to the Sound settings should be reverted when finishing. (The changes made to Skype are not that important, and the program will behave as before.)
If Sound output is set to Soundflower (as in the first image), you may be unable to hear anything when playing music in iTunes, for example, if Soundflower is not running, or if 'Built-in' option is not checked like below:

So, open Soundflower and set it accordingly if you need to use it, or, if you don't need it anymore, close it and change back the Sound output settings to the original: Internal speakers or Headphones - instead of Soundflower.
Answer: There are multiple ways to do this.
You can records video and sound with Screenflow or you can record your audio on your Mac with software like Audacity or Apple's very own QuickTime player by using a jack connecting your audio output with your audio input.


Trigonometric Substitution

Question: I am having some trouble with a homework problem that reads:"Use the subsituition $x=\sin(t)$ to evaluate the $\int\sqrt{36-x^2}dx$. I would really appreciate if someone could help me with this problem!
Answer: The substitution should be $x=6\sin(t)$. If we substitute $6\sin(t)$ for $x$ in the expression, you get
$$ \sqrt{36-x^2}=\sqrt{36-(6\sin t)^2}=\sqrt{36-36\sin^2t}=\sqrt{36(1-\sin^2t)}=6\sqrt{\cos^2t}=6\cos t$$
That's all there is to it. Do the substitution, then apply the appropriate pythagorean identity.

Trigonometric Substitution


How to prune an apple tree

Question: I have 2 apple trees that are about 5 yrs old.  They are about 6 to 7 ft. tall, but the main stem seems to be dead. There are quite a few new branches lower down,near the base and in the middle.  Is it ok to cut off that main stem? Not sure what to do.
Answer: Unfortunately your photo doesn't really show the lower part, but it seems like the growth is not from the grafted top part, but rootstock suckers pushing up. Suckers should usually be removed as soon as possible, because they can "suck" some of the energy that should be going into the crown of the tree otherwise. If my assumption is correct (check where the new growth is coming from), you should replace the tree. If the top part - that which was grafted onto the rootstock - is dead, keeping the suckers doesn't make sense.
The fruit from the rootstock will not be what you expect, because the rootstock was bred and selected for its ability to grow a strong root system and to feed the crown, not for bearing fruit desired for eating or further preparation.

How to prune an apple tree


Can I trace a spoofed text message?

Question: Someone is texting me threats and I have no idea who. Is there a way to "unspoof" the number? I know for a fact that they are spoofing as a legit number, because I called it. Thanks in advance.
Answer: Your cell phone carrier will likely have the capability to do this for you. However for privacy reasons (silly I know) they may be reluctant to share the source number with you. However you may be able to ask them to permanently block that number from contacting you.
In addition if what is being sent to you possibly violates the law, of course you should contact your local law enforcement.
Comment: I do appreciate the response. I dont know wat the 9 18 means, but I sure wish I could validate my suspiscions. Thats wat i kinda figured. I have a computer repair shop and have customers asking these type questions quite often. I will refer them to this board/forum and enjoy looking around myself. Concerned parent here. Anyway, thanks for the answers and Have a Great Day

Can I trace a spoofed text message?


Can I add a service panel in the shed near a generator which powers a cabin?

Question: I currently have a 200amp Main panel in my off-grid cabin I am building.  I want to feed the panel from my generator which is about 100' in a shed.  Originally my contractor a few years back buried cables between the shed and cabin.  They are (2) 4/0 and (1) 2/0 cable. I have them terminated in cabin panel. I was wondering if I can put another 200amp panel (or 150amp)in my shed, since the 4/0 and 2/0 are stubbed out in the shed (not connected to anything).  I am also assuming that really my "main" panel should be the in the shed, and the "sub" panel in the cabin.
My Honeywell generator is a 12kw standby generator, which will supply 50amps I believe.
Can I do this?
Comment: @Jon -- what size is that conduit, and is it plastic or metal? Can you post the photos that you have?
Comment: Are you wanting to power anything at all in the shed from the generator?
Comment: Yes.  Probably only a light or two, and an outlet.  The cabin is a typically two bedroom cabin, but most power requirements to major appliances (stove, frid, washer/dryer, fireplace) will run off propane, with probably minimal 120v for lights or whatever they use.  Biggest thing is my 230v 1 phase pump.  Well head is 170' from cabin, and has pump control under cabin in crawlspace.  It works fine with my portable generator.
Comment: How many HP is the well pump, and are the existing wires between the shed and the cabin directly buried, or in conduit? Also, is this Honeywell generator of yours permanently mounted (outside the shed, I hope!) or a portable?
Comment: The pump has a 4 conductor (3-#8, 1-#10) wires direct buried from well to pump control under cabin. The 4/0 and 2/0 are also direct buried cables.  Pump is 1/2 hp.  Generator is in shed by itself (10'x8').
Comment: Why does it matter whether it's in shed or not?  It will be vented appropriately of course.
Comment: I my pea brain, I am thinking I would connect another breaker panel (200 or 150amp) in shed.  Hook the generator first to transfer switch (left in manual mode, since I am not on grid), Then run cable to power panel in shed (where 4/0 and 2/0 are).
Comment: Ah.  I ask re: the generator inside a shed because properly venting internal combustion engines in structures is a fair bit trickier than venting a typical gas or even oil burners. (It's doable, and is done on a reasonably regular basis in heavy institutional construction, but the applicable codes and standards aren't the same....(pro tip: think of something you'd use for exhausting a solid fuel burner)
Comment: is retrenching the wire between the shed and the cabin an option btw, or is that out of the question altogether?
Comment: Retrench? Expensive to go under cabin. It has a concrete 4ft stem wall for foundation perimeter. Why retrench?
Comment: Because unless you're willing to splash out some money on a *transformer*, feeders require 4 wires....(hot, hot, neutral, ground)
Comment: Yeah, I'm not sure what the contractor was thinking... leaving off the ground wire... did you say "Oh, only the generator will be at the shed, the house will be the MAIN panel"?  I can certainly see an application for such big wire for solar/battery/low voltage... Or do you anticipate a grid connection in the future?
Comment: There will be no grid power in my life time sadly.  My house panel is grounded with with two rods (per code).   The cable is in a conduit.  I realized I had a picture of it, and it was in conduit.  I would ground the generator of course in the shed.  Nothing other than support panels, maybe a inverter/charger and battery bank.  My use daily for electrical will be around 4000 watts is all.  Gas (LP) is plumbed to shed for generator, but not connected yet. I guess if I had to run a separate ground, I would have to dig trench.
Comment: I might then of course put in some wire for a remote start switch in house to generator.
Answer: It's interesting, the divergence in design philosophies.  On one hand, an all-gas cabin (I live in one) has very minimal electrical needs (we have 30A/120V, and what's amazing is I didn't even know that for 15 years, it just never came up until the lost-neutral incident).
So you have this off-grid home that will never have utility power, yet there's a 4/0 service line (not feeder; no ground) suitable for 225A mains service.  And no thought toward power at the shed (short of doubling back with another 12/3 UF cable or something).
It's a misfit for the property... like the contractor didn't know what to do, so just did the standard thing for a utility home.  The lack of a ground wire is especially eccentric; you have between $500 and $2000 of wire there; overlooking a $40 ground wire seems silly. Since you say it is conduit (is it all the way or just the stub-ups?) you can just add a #4 ground wire of the same metal, and at least solve that.
I would not remain loyal to any of that, since it is so confused.  I would re-think the entire thing from the ground up.
A low-key low-dollar DC system
Given the dollar I see already having been put into this, this may a little lowbrow for you: I mention it because from your stated needs, it would suffice.
Given your modest needs, a low voltage 12/24 VDC battery system may suffice.  You run an inverter only for loads which are impossible to run on 12/24 DC.  For instance lighting is readily available 12/24V.  If you look at TVs, DVRs, internet routers etc., many of those have a wall-wart that actually makes 12 volts DC - you can simply bypass the wall-wart and feed them 12V direct.  All power conversions are "vampire loads" even when they are in "standby", so avoiding an unnecessary power conversion is always a good idea.   However, a refrigerator is a must-have 120V load -- the people who have been doing off-grid for 40 years have determined that it's more cost-effective to upsize the system a bit, eat the conversion losses, and use any modern, common Energy Star fridge - the appliances are so efficient that $3000 bespoke 12/24V fridges can't beat 'em.
Your well pump obviously needs higher voltage AC power due to the long distances both to the wellhead and down the well.  (most well pumps are at the bottom). But that inverter only needs to run when you call for water.
You don't need to use cheapie lead-acid batteries that wear out after 5 years, a lithium pack with good on-board energy management is good for 15-20 years.  And for 40 year life, they still make traditional Edison Nickel-Iron batteries (which were for EVs; those were popular in the 1900 era when gas engines were really not ready for prime-time).
In this case, the 4/0 might come into play to bring low voltage solar/wind power from an array or windmill, and/or you could store the batteries at the shed instead of the house.
A midrange system
However, a much more comfortable fit would be one of the midrange off-grid systems  - not the Tesla PowerWall but vaguely similar options, possibly assembled from various quality subsystems (Morningstar, Schneider etc).  In that case you use a quality inverter that does run 24x7 and is able to support all 120V loads... and just go ahead and upsize the system to support that (smaller because quality) vampire load and conversion losses.
For topping up the large battery pack, you can use a generator, but total life-cycle ownership costs will be better on a solar array, windmill or run-of-creek micro-hydro.
If you run the generator, it can be quite small, since it only needs to meet average demand; the battery covers surge demand.  Also, you get to run the generator at a time of your choosing, and it runs near full power for the least time possible, which is optimum for both fuel efficiency and wear/tear. The engine isn't running max RPM no load on the off chance that you open a water faucet.

Speaking of that, if you've got the hills for it, think about a tank-up-high to passively pressurize your water system.  Then, you only need the pump to top up the tank, and you can do that at a time of your choosing (e.g. when batteries are full and the solar/wind system is in "dump" mode).

In this scenario, the 4/0 would serve little use, except (if you add a ground) to give you the flexibility to put the gen/battery/inverter system anywhere you please. (but I recommend all in the same place).
By the way... if the cable was direct burial and you needed a ground, just saying, Rigid conduit is an allowable ground path and it only requires 6" cover (12" under vehicle pathways). The shell alone covers the ground, leaving you an empty conduit to fit what you please. It's expensive as all getout, but you can trench it with a garden trowel lol.
Comment: Thanks for long answer.  Not sure where or what to do now.  Here is the current setting.
Comment: Thanks for long answer.  Not sure where or what to do now.  Water is at cabin and I have a 81 gallon diaphragm tank and which currently works with portable generator.  So that's good to go. I have to check exactly what's in ground, but I don't think they ran a ground. So simply, generator in shed, gas stub out to shed, cable, trench are all worthless?  So I would guesstimate cement pad for outside generator, reroute gas, retrench with new cable, tear out existing cable, and design a workable system.  $15 to $20K?  MIght as well not bother at that cost.
Comment: So I guess I have this option.  Move the current generator to along side the house on a pad (eliminate shed for this system), and rerun cable that will go from generator into house main panel.  Figure out a way to self start it, when pump needs to fill tank, then shut off so it won't dead head the pump.  I would assume I would need battery backup to do my minimal voltage draw during the day.
Comment: @Jon Honestly, I'm guessing that ThreePhaseEel is working on a really good *practical* answer, that's why I chose to go with a "view from 30,000 feet" answer.  Rest assured the cable in the ground can  be saved, it's just a question of most expedient and useful method.
Comment: @Jon -- if you're still with us, can you get us photos of that conduit please?


Physical interpretation of negative total energy

Question: I am going through Griffith's text on Quantum Mechanics, in which he states
$$\begin{cases}
E < V(-\infty) \text{ and }V(\infty) \implies \text{bounded state}\\
E > V(-\infty) \text{ and }V(\infty) \implies \text{scattering state}
\end{cases}$$
where $E$ is the total energy of the particle. This makes sense. However, he notes that most potentials tend to 0 as you approach infinity, and so the above simplifies to
$$\begin{cases}
E < 0 \implies \text{bounded state}\\
E > 0 \implies \text{scattering state}
\end{cases}$$
This is where I am having some trouble with the physical interpretation. How can one have negative total energy? Can someone provide some intuition and maybe an example?
Comment: It's a matter of where you assign the reference. Usually what you care about is the potential difference and the amount of work done as you move from one place to another. Examples are gravity  and orbits, or electrostatics as you move a charge in a coulomb potential. So if you assigned the reference differently you could change how you label the energy axis, but the work done  or difference between energy levels etc. would still be the same.
Comment: They are defining the reference to be at infinity. So the analogy is for gravity  if E >0 the particle would not be able to orbit. For a quantum well potential  or an atom the electron would not fall into the potential well and be trapped at an energy well unless E<0. Note even with E>0 it would still be influence by the potential and for example change direction -so for E>0 scattering. E<0 could be trapped in a bound state or energy level or orbit depending on the nature of the potential.
Comment: @UVphoton So the total energy in this case is relative?
Comment: See [Potential energy curve for intermolecular distance](https://physics.stackexchange.com/q/94281/37364)
Answer: The total energy can be negative because, away from infinity, the potential can be negative. If the total energy is negative, then regions with zero potential are unaccessible for the particle, since it can't have negative kinetic energy. That's why Griffiths calls that situation "bounded": the cases with negative energy are constrained to the region of space in which the potential is negative enough for the total energy to be whatever value it is while the kinetic energy is still non-negative.
Particles with positive total energy, on the other hand, won't have those restrictions at infinity (for potentials vanishing at infinity). Hence, they can keep going on forever, without being restricted to a finite region. That's why Griffiths calls this case scattering.
Comment: Thank you for the reply. What would be an example of a negative potential and what is its interpretation? At the moment I think of a negative potential as a sort of "attractive force", for lack of a better term. Also, from what I can gather the general rule is that you cannot access regions where the potential energy is greater than your total energy. So in this case it makes sense as to why a particle with negative energy cannot access a region of 0 potential.
Comment: Expanding on my last comment, the intuition I am building is that having a positive total energy means you have the ability to move freely (assuming the potential vanishes at infinity), where as a negative total energy means you are bounded to a certain region (in my analogy, you are subject to some kind of attractive force and hence negative). Is this the correct physical picture to have?
Comment: @CCBAM A negative potential does correspond in these cases to an attractive force (although there can be more details). An example of a negative potential is that of the Kepler problem, for example (which also corresponds to the potential for the hydrogen atom). And precisely, a particle can't access regions where the potential is larger than the total energy. That would require the kinetic energy $\frac{p^2}{2m}$ to become negative, which is not possible.
Comment: @CCBAM Even with positive energy, there could be "hills" in the potential which the particle can't access (apart from tunnelling), so there are also some more details. For example, there could be a region where the interaction is repulsive. Nevertheless, that is indeed the general idea.


Why is the result of this calculation 0 and not 1?

Question: Why is the result of this calculation 0 and not 1?
Comment: If you switch to cycles and set the shading mode to 'rendered' it works as expected. I guess it's a current limitation of Eevee...? Not sure. Otherwise might worth to file a bug report.
Comment: My quess is that somehow your value ends up 0.999999 and floor rounds it down to 0, but I would like to know why as well
Comment: I tried to recreate it and it shows black in both eevee and cycles
Comment: I got the same result as @brockmann - it shows white in Cycles, but black in Eevee. The problem seems to be the *Floor* node. If I mute it, the result is white in Eevee, too. If I render it without *Floor* and check the RGB values in the render result, they are all 1.0000 which should be white with *Floor* as well. Maybe there is a floating point issue and somehow it is 0.9999999... instead of 1 or it's a bug in Eevee. Also if I set the value to 10.000001 which is shown as 10.000 it works in Eevee.
Answer: This is caused by accuracy problems of floating point numbers. Those problems [typically?] don't occur with small whole numbers like 10.0, as you can see for yourself here:
IEEE-754 Floating Point Converter
You can also test your node setup by disconnecting Math > Modulo and inputting 10.0 manually as the first Value of the Math > Divide node. This shows the problem happens inside the modulo node.
I'm not well versed in the Blender source arcane, but it seems the source of that node is in COM_MathBaseOperation.cpp
void MathModuloOperation::executePixelSampled(float output[4],
                                              float x,
                                              float y,
                                              PixelSampler sampler)
{
  float inputValue1[4];
  float inputValue2[4];

  this->m_inputValue1Operation->readSampled(inputValue1, x, y, sampler);
  this->m_inputValue2Operation->readSampled(inputValue2, x, y, sampler);

  if (inputValue2[0] == 0) {
    output[0] = 0.0;
  }
  else {
    output[0] = fmod(inputValue1[0], inputValue2[0]);
  }

  clampIfNeeded(output);
}

However, when I try to fmod(10.0, 100.0) in C++:
float numer = 10.0, denom = 100.0;
float modded = fmod(numer, denom);
float floored = floor(modded);

I get correct results:

So I suspect that behind the scenes, the numbers aren't evaluated as presented in the node setup. Perhaps they are scaled down for some reason?
float numer = 0.01, denom = 0.1;
float modded = fmod(numer, denom);

Just a guess here.
I think in order to stay sane, you should always assume that your number may randomly increase or decrease by the smallest possible step at any point, so think of it as randomly increasing/decreasing by 0.00000001 and work around that.
As a bonus, try to set your divisor in the Math > Divide node to 9.999999. Once you test it and see you get a white material, click on the value, change nothing, and press Enter.
Comment: Perhaps a small anecdote, I remember when I wrote a shader in Adobe Flash AGAL and a comparison with a number worked as expected on my desktop GPU, but failed in the CPU emulation mode on my old laptop. Just an anecdotal evidence to support my second last paragraph.
Comment: nope the result is 10... I just checked within blender.
Comment: I'm sorry, I had a brain fade yesterday and was proposing a nonsensical argument.  I'm going to delete my comments.
Comment: @MartyFouts no problem, cheers!


How should I put the title for the student research experience on CV?

Question: When I was taking master's degree, I attended a one year's program in affiliation between my university and a commercial research institute. At that time, on the contract, I was placed as visiting student. Then after graduation, I extended my contract for half a year. And the renew contract shows that I was under the agreement of visiting researcher. I put visiting researcher for this whole 1.5 years' experience on my CV because visiting student seems not strong enough. Is this right to do? I didn't notice this problem until I found that my former supervisor always referred me as visiting student and I've sent out several Ph.D. applications. Is this a kind of cheating that I call myself visiting researcher?
Answer: Do you have a copy of your renewal contract? If you don't, you should ask for it since the contract is with you.
Ask your supervisor if they are willing to be your reference. Point out to your supervisor that you are referred to in the contract as a "visiting researcher".
The next time a prospective employer asks you for a reference, contact your supervisor and remind them that you worked for them as "visiting researcher".
List your position as "visiting researcher" since you have the renewal contract to back up your claim.
Having said that, the description you give of your duties will give away what you actually did. If all you did was say washing test tubes, no fancy job title is going to make up for a lousy job description.
Comment: Yeah, I have the copy. I think I should contact my former supervisor. And I actually conducted individual research in that company. But how should I explain the inconsistency during the interview?
Comment: @deathlee - Why should you? It's their problem.


export inkscape image for work in Finale Cut Pro

Question: how do i export an .svg file in Inkscape so that when i import the .png image into Finale Cut Pro, it doesn't look grainy?  the image in the video doesn't need to be super-high definition; just something a little better than i'm currently getting.
Comment: I'm not sure I understand. You say are exporting an SVG, but importing a PNG into other software. What are you using to create the PNG? Aren't you exporting the PNG from Inkscape? PNG images exported directly from Inkscape shouldn't be grainy.
Comment: sorry, ya, i'm taking a .svg file and exporting it to .png within Inkscape.  when i import the .png file, it appears graining — not terribly so, but i was hoping for a little bit better clarity in the image.
Comment: Is the PNG grainy when exported from Inkscape? I can't reproduce the problem. Can you share the image?
Answer: "Grainy" is a very specific adjective, which I think will not apply on a SVG image exported.
You probably are seeing pixelation or saw edges.
In any case, simply export to the exact size you need or as a bigger image.

In order to have a higher resolution as default, you can simply leave the DPI number higher than the actual number. If it is set to 72dpi you can put 150, or whatever number you need. This depends on how the SVG was originally made.
Comment: ok, that makes sense.  is there a way to set the default export image size in Inkscape?  i have about 1000 images, and i don't want to set the image size for each one.
Comment: I added new info on the anaswer.


Does rugging horses interfere with the grow of the winter coat?

Question: Pretty much what the title says.
I've heard that decreasing daylight encourages winter coat growth. Others say that rugging will prevent winter coat growth.
My question:
Does rugging horses interfere with the grow of the winter coat?
Answer: In two studies it proves that winter/summer hair growth can be controlled and stimulated by photo period - or daylight length, by using artificial light sources. This is independent of rugging.
Promoting effects of an extended photoperiod treatment on the condition of hair coats and gonadal function in Thoroughbred weanlings

The colts and fillies in the EP treatment group changed from winter to
  summer coats (molting of winter coats), whereas those in the control
  group did not.

CONTROLLING HAIR LENGTH IN HORSES
USING EXTENDED DAY LENGTH REGIMES

The use of an extended lighting program is an important management
  tool for horsemen who need to get horses to slip winter hair or keep
  hair short throughout the year.

The difference a rug will make is it will flatten the hair, so it doesn't look as woolly. This can also inhibit the horse's ability to stay warm, as it is the extended hair that creates a barrier between the cold air and the horses skin.

.../ horses can make their hair stand-up, which is called piloerection (think of goose bumps), which acts to increase their hair depth and traps air next to their bodies creating an insulating layer.

This article from the RSPCA, discusses rugging horses in winter:

What about rugs in winter?
In cold wet weather a good quality and well fitting rug can help the
  horse to maintain condition, as a cold wet horse will burn a lot of
  energy keeping warm. Keep in mind though that if your horse is young
  and healthy but tends to get fat, rugs will actually help him or her
  to maintain that fat. In a natural situation excess body fat is burned
  off through the winter.
The coat of an unrugged horse stands up in cold weather to trap air
  and warm the horse. If you decide to rug you have to compensate for
  this mechanism as a rug will stop the hair from being able to do its
  job. In some circumstances a rugged horse is actually colder than an
  unrugged horse if it is a badly fitting thin rug that flattens the
  hair and reduces the movement of the horse without providing any real
  warmth.
Rugs need to be checked regularly (at least twice a day) to make sure
  that the straps have not broken and the rug slipped, which can cause
  injury to your horse. Hoods can be very dangerous for horses and
  should only be used if the horse is being checked very frequently
  (much more than twice a day) because if a hood slips it can cover the
  eyes and rub the eyeball (which can cause an ulcer on the eye – a very
  serious condition for a horse requiring immediate veterinary
  attention). Horses with slipped hoods (due to not being able to see)
  have been known to fall into dams (and drown), injure their eyes on
  branches or other protrusions etc. or panic and run through fences.
A rug should be removed regularly to make sure it is not rubbing,
  letting in water etc. and to make sure the horse hasn't lost weight or
  gained too much weight. Rugs prevent horses from exfoliating their
  skin properly (by rolling and mutual grooming etc.) so a rugged horse must be groomed thoroughly and frequently to get rid of the build up of dead skin and hair (see the article Why do I need to groom my horse?).

There's many other factors to consider when deciding whether to rug a horse, including living conditions, diet and grooming which is outside the scope of this question. This is purely about whether rugging prevents winter coat growth.
Answer: My father was a thoroughbred horse trainer he always taught me to let your horse be natural no blanket because they must get used to the cold and a blanket will cause the horses coat not to grow in properly ...but he would allow blankets if it was well below zero only during the coldest part of the day ...or night ...so we always followed his orders and my horse is now 30 years old her winter coat is sooo THICK she looks like a wooly mammoth haha lol its going to take a lot of curry combing to help her shed that coat in the spring.
We have the horses in as barn at night and paddock with outbarn during the day so they have protection from wind snd weather at all times but if its snowing that old mare wants to be out in the snow she loves the snow she actually chooses to go in the snow instead of protection of a roof and walls And she's 30 years old....
Comment: 30 years is a good age for a horse. Where I am the temps get no where near that cold. Welcome to the site :)


Composite mist pass after-the-fact to finished rendered video using the original blend

Question: Say you have 500 stills comprising a video, and you also have the original blend file that created the stills. Is there a way to do a render that skips the time-consuming Image pass but still provides various other passes (like Mist, Shadow, etc.)? And such that those passes are stored in a way that can be input to the compositor to apply the result to the stills? I have done very skimpy passes (low bounces, etc.) that sort of achieve this, and stored them as multilayer EXRs, but haven't found a way to apply the output to more than one frame at a time.
Answer: I think the way to do this is as you said: low bounces, no caustics, etc.
You can bring the already rendered image sequences into the compositor with the image node:

Add an image node (ShiftA> Input > Image)
Open the first frame of your image sequence in the image node
Change the source type to Image Sequence:

Set the Frames, Offset and Start frame values.

Frames is the number of frames to use.
Start frame is the scene frame on which to display the first frame
Offset is the amount to offset the current frame. (e.g. with Offset = 5, the image for frame 6 will be read instead of the image for frame 1)

You can load your sequence of Multilayer images alongside your original render into the compositor in this fashion. If you rendered the Multilayer images with the render passes enabled you should be able to use the passes from the Image node.
You can also use this alongside the Renderlayer node to composite with the render directly, e.g. with a 150 frame image sequence:
Comment: gandalf3 - Thanks, then I guess that really is as good as it gets. I was hoping for a way to do both 1) Run the PNG/JPEG file Image Sequence side-by-side with the live animation render 2) completely turn-off the main RGB pass in the animation render while still doing other passes that don't require it. The lesson I take from this: Always render to multilayer EXRs with as many passes checked-off as you could conceivably regret missing :)
Comment: @PlenusFranckly It's possible the disable to RGB (combined) pass, however this is pointless as cycles still needs to path trace the scene to generate a result for the other passes (to prove this try disabling *Use surfaces* in the renderlayers panel, all the passes will have no data.) you want, which takes the same amount of time as it would otherwise. In other words, to get a rendered pass, you need to render it. As for 1, if I understand correctly, you should be able to do that with the image sequence node. Have you tried it?
Comment: To answer your question, yes, I've been able to composite a PNG image sequence side-by-side with a multilayer EXR sequence; the approach that didn't work was running the PNG image sequence concurrently with "live frames" from the Render Layers output (what I meant by "live animation render"). I can do one-frame-at-a-time, but not batch. I was interested only because it seemed like a more flexible approach, since I could play with just how many bounces & samples i could do-away-with to still get convincing mist.
Comment: @PlenusFranckly Hmm.. It should work.. See my edit.


Waves plug-ins don't work on Mac's bootcamp?

Question: I have the waves silver bundle and use it on my mac with pro tools no problem but I also have windows XP installed on my bootcamp side of the drive where I run Sonar 8.5 and Sound Forge. For some reason waves doesn't work even though it is compatible with windows XP. Why is this? I email waves and they just said bootcamp is not compatible! But its running windows so why? Any ideas?
Answer: Do you have your iLok drivers installed in Windows XP?  Go to ilok.com and make sure your ilok is recognized.
I ran bootcamp with Windows 7, Waves worked fine on both the Windows and Mac side.  I can't imagine it would be different with XP.
Comment: @Chuck Russom Thanks, you got it, my bootcamp partition wasn't recognizing my ilok. Its working fine now. Thanks
Comment: Cool, glad you got it working.


kohana 3.1 in subdirectory + ubuntu 14.04 + php-fpm + nginx 404 errors

Question: i have an old kohana app that i'm trying to put on my VPS but can't seem to get it working. i've spent hours googling and looking at cached forum answers. i have tried them all and nothing seems to work. admittedly, i have no idea how to deal with nginx. my local version of the app works fine with apache. i'm one step away from just canceling my linode account and getting shared hosting! please talk me off this ledge.
my vps:
ubuntu 14.04LTS with php5-fpm and nginx 1.4.6.
i am serving everything from my user directory.
my nginx sites-available file:
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;

root /home/gabreal/Sites/public;
index index.html index.htm index.php;

# Make site accessible from http://localhost/
server_name localhost;

location / {

    try_files $uri $uri/ @kohana =404;
}

error_page 404 /404.html;

# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
    root /usr/share/nginx/html;
}

# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
location ~ \.php$ {
    # With php5-fpm:
    fastcgi_pass unix:/var/run/php5-fpm.sock;
    fastcgi_index index.php;
    include fastcgi_params;
}

location @kohana {
    rewrite ^/(.+)$ /index.php$request_uri last;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
location ~ /\.ht {
    deny all;
}
}

my kohana application is in the directory like so:

├──/home/gabreal/Sites/public/
│   ├── horizons/
│   │   ├── grader/ (aka the kohana application)
│   │   │   ├── index.php
│   │   │   ├── application/
│   │   │   ├── system/

when i visit the application by going to http://example.com/horizons/grader the kohana bootstrap file loads and all the redirects are called. for example, my default route redirects you to a start page. if you aren't logged in, you go to 'user/login'. the url is being set correctly. going to the url above, the browser redirects to http://example.com/horizons/grader/user/login but i get nginx 404 page.
so somehow the controller/action pattern is just not working with this nginx setup.
please help for the love of whatever you love in this world.
UPDATE
just fyi, i installed phpmyadmin and it is working perfectly. i still can't get kohana to work though...
UPDATE 2
i did a fresh install of kohana and tried to set up a few basic controllers. only the default controller works just like in my application. so, going to the base url for my application ALWAYS works but going directly to any /controller/action/id type of resource gives me nginx 404 error on both a fresh install and my existing application.
Answer: This is the obvious problem:
    try_files $uri $uri/ @kohana =404;

The =404, and the entire @kohana location block, are probably combining to cause the problem.
You can simplify this by getting rid of the @kohana location block, and simplifying try_files to:
    try_files $uri $uri/ /index.php;

(Kohana doesn't need any other parameters when you pass the request to index.php; see the Clean URLs page for details.)


CentOS 6 - nameserver entry in resolve.conf resetting after restarting network services?

Question: In /etc/resolv.conf, I've changed the nameserver line to a new IP address.  After saving and exiting, I run service network restart.  I then go open /etc/resolve.conf again and see that the IP address I changed is now back to what it was prior to changing.
Why is this happening?
Answer: According to the RedHat 6 Documentation this is the same as with RedHat5:
Put PEERDNS=no either into the global configuration file, or into the specific interface-configuration file.
Answer: If you are running on Centos/RHEL edit the ifcfg configuration file and add
DNS1="xxx.xxx.xxx.xxx"
DNS2="xxx.xxx.xxx.xxx"
Then restart networking using service network restart
I know this is a very old question, I am adding my answer to help those who didn't accept the accepted answer above. Such as myself.
Answer: Might be you have dhcp-client in your system and it make resetting your resolv.conf file after restarting the network service.
Check in  /etc/sysconfig/network  or interface file  whether dhcp-client protocol has defined and try to configure the static ip.
If not, you can protect your /etc/resolv.conf from being modified by anything is setting the write-protection attribute.
chattr +i /etc/resolv.conf

Answer: If you are using DHCP for address assignment, the cleanest way to accomplish modifying resolv.conf is to make the changes on the DHCP server side. That will in turn correctly update resolv.conf


Why img without position is like "absolute"?

Question: Check this code :
HTML :

        Hello

CSS :
.inf-image
{
    position: relative;
    cursor: pointer;
    margin: 3px 8px 0px 0px;
    width:20px;
}

.inf-content {
    background-color: #FF0000;
    padding: 10px;
    width: 150px;
    height:50px;
}

looks like the div (which is relative) is under the image (which look absolute). Why? It should push the div over its height.
Comment: Why would you even be using `align="right"`? `align` is obsolete.
Answer: Floating elements (like an ) offset only the content of block elements, but not their backgrounds, so the red background of the div is seen under the image.
Comment: `align=right` is exactly the same as `float: right`. Inspect the applied styles in Chrome devtools or Firebug and you'll see the attribute triggers a `float: right` style.
Comment: Float is CSS, align is a normal HTML attribute. Avoid the latter one in favor of the other.
Comment: @markzzz I believe they behave the same way in many instances, including this one.
Comment: Really? So what's the difference about float/align?
Answer: Its all about the CSS stacking context. If you give an element another position than static it will be moved to its own stacking context. From a logical point of view the .inf-image { position: relative; } is no longer a child of the parent DIV or a sibling to .inf-content. What you have now is a DIV with another DIV (the red one) inside. The image itself "hovers" in its own context right below the document root (HTML) and is just positioned relative to that element, which preceded it in the source.
Which is shown above which element can be determined by a combination of position and z-index.
https://developer.mozilla.org/en/Understanding_CSS_z-index
http://reference.sitepoint.com/css/stacking
Answer: According to your css and html your div is positioned absolute while your image is positioned relative.  This is your problem.

        Hello

.inf-image
{
    position: absolute;
    cursor: pointer;
    margin: 3px 8px 0px 0px;
    width:20px;
    right:0;
}

.inf-content {
    background-color: #FF0000;
    padding: 10px;
    width: 150px;
    height:50px;
}

Comment: The OP never said he/she has a problem…


Complementary text for mathematical Quantum Mechanics lectures

Question: I'm looking for a text to complement Frederic Schuller's lectures on QM.  His approach is very mathematical -- in fact it looks like the first 12 of 21 lectures are just about the mathematical foundations of QM.  He introduces Hilbert and Banach spaces from scratch (from basic linear algebra and analysis really), derives the functional analysis version of the spectral theorem, and gives what I assume are more rigorous definitions.  For instance in all of the undergrad books I've looked at, quantum states -- if they're given any definition at all -- are said to be elements of the Hilbert space.  But Schuller claims that that is not correct.  States are in fact positive trace-class linear maps on the Hilbert space.  Does anyone know a good undergrad level QM book that I can follow along with so I have some exercises and extra material to work through as I go through the lectures?  Thanks.
Comment: The text that was used in the QM classes I took was Griffiths. I don't have anything to compare it with, so I don't know if it's actually recommendable.
Comment: @EstonianFootballerJoelLindpere I've looked at Griffiths -- it's way more informal than I'm looking for.  And it doesn't follow Schuller's approach.  Thanks for the suggestion, though!
Comment: I'm working through Gerald Teschl's book and enjoying it.  I think of it as more of a math book, though.  http://www.mat.univie.ac.at/~gerald/ftp/book-schroe/schroe.pdf
Comment: Incidentally, unit vectors in the Hilbert space are a valid representation of *pure* states, whereas general mixed states are maps on the space satisfying certain conditions.
Answer: I'll just make my comments into an answer.

Reed and Simon Volume 1: Functional Analysis (Methods of Modern Mathematical Physics) here on amazon has a table of contents.
Reed and Simon Volume 2: Fourier Analysis, Self-Adjointness (Methods of Modern Mathematical Physics) here on amazon, again you can see toc.
Cohen-Tannoudji - Quantum Mechanics (2 vol. set). Reasonably rigorous and may fit Schuller to some extent - lots of end of chapter appendices. amazon link
Messiah Quantum Mechanics (2 Volumes in 1) - two volumes has a lot in it, might not be as rigorous as you want it. amazon link
Quantum Mechanics in Hilbert Space: Second Edition, suggested by user254665 - The preface to the first edition starts "This book was developed from a fourth-year undergraduate course given at the University of Toronto to advanced undergraduate and first-year graduate students in physics and mathematics. It is intended to provide the inquisitive student with a critical presentation of the basic mathematics of nonrelativistic quantum mechanics at a level which meets the present standards of mathematical rigor." Seems to fit the course reasonably well judging by toc - amazon, toc, preface etc.

R&S Volume one introduces Hilbert spaces, Banach spaces, spectral theorem etc. and leads from bounded to unbounded operators and the fourier transform.
R&S Volume 2 is very physics orientated, with topics on fourier transforms, hamiltonians in non-rel QM, and talks about self adjoint operators, and a bit about time dependent Hamiltonians.

As a note on quantum states, there's various definitions. They can be

vectors in a Hilbert space $\mathcal{H}$, but specifically one that satisfies a Schrodinger equation you're interested in (Assuming you're in Schrodinger picture in non-rel QM). State space would be a subspace of a Hilbert space.
elements of the projective hilbert space $\Bbb P\mathcal{H}$
traceclass positive operators of trace $1$, normally called $\textit{density matrices}$.
A rank one projection operator.

It depends on what you want to do with them.
The first I think is the most common, as when teaching quantum mechanics, the wave functions usually belong to an $L^2$ space, and are found by solving the Schrodinger PDE.
The second last one is useful for statistical mixtures and open quantum systems, you can have pure and mixed states. The pure states can be identified with the last item on the list.

As a sidenote this was asked by a different user on physics stack, same question on schullers course, and it was closed, even though it's physics, and a pretty reasonable request. It might be useful to check there for the one answer that was able to be posted before it was closed.
https://physics.stackexchange.com/questions/259583/good-texts-on-quantum-mechanics-to-accompany-this-online-course#comment579079_259583
Comment: There is a text by Prugoveski..... I can't recll the exact title. The title of his course at U of Toronto was The Mathematics of Quantum Mechanics.
Comment: @user254665 Is this it? https://www.amazon.com/Quantum-Mechanics-Hilbert-Space-Physics/dp/0486453278
Comment: The preface to the first edition starts "This book was developed from a fourth-year undergraduate course given at the University of Toronto to advanced undergraduate and first-year graduate students in physics and mathematics. It is intended to provide the inquisitive student with a critical presentation of the basic mathematics of nonrelativistic quantum mechanics at a level which meets the present standards of mathematical rigor."


Air flow or illusion

Question: If you have temperatures in the teens on the outside of a new single hung window in a house and temperatures of 70 degrees on the inside of the house and it feels like air is coming through the seals of the window is it actual air penetrating the seal or is it air flow caused by the pressure deference's between the cold air meeting the warm air giving the illusion that air is penetrating the seal? Is this possible? There is air flow. I tapped a piece of ribbon above the upper and lower window where the two windows seal together. The ribbon twirls around.
Answer: Cold air outside cools the warm air inside. Cold air is denser and flows downward.

Air flow or illusion


How to do appcoef and detcoef using pyWavelets?

Question: I am new to signal processing and currently doing a school project in wavelet transform using Python. I want to extract all details and approximations (Example: cA2, cA1, cD2, cD1), pywt could return the cA2, cD2, and cD1 except cA1. I noticed that there are the functions named appcoef and detcoef from MATLAB to return all the approximations and details. How can I do the same using pywt?
Answer: From the matlab docs https://www.mathworks.com/help/wavelet/ref/appcoef2.html
the appcoef function does: "If N = NMAX, then a simple extraction is done; otherwise, appcoef2 computes iteratively the approximation coefficients using the inverse wavelet transform."
import pywt

def appcoef(coeffs, wavelet, level, **kwargs):
    max_level = len(coeffs) - 1
    if level == max_level:
        return coeffs[0]
    # this function also calculates the IDWT (kinda confusing API)
    approx = pywt.waverec2(coeffs[:-level], wavelet, **kwargs)
    # not sure why PyWavelets sometimes gives duplicate final rows/columns
    if np.all(approx[-1] == approx[-2]):
        approx = approx[:-1]
    if np.all(approx[:, -1] == approx[:, -2]):
        approx = approx[:, :-1]
    return approx

I tested against matlab on a single grayscale image for a couple levels, and the normalized results matched to 1e-15; but of course there could be some issue I am missing for other cases.
Oh also detcoef: detcoef = lambda coeffs, level: coeffs[-level]


Is saying " I never did say that" correct, grammatically?

Question: My question here is that can we use never plus did plus the first form of verb?
Answer: Grammatically, yes, "I never did say that" is fine, but unusual, and wild only be used for some specific reason.
Reasons you would choose it over the simpler "I never said that" might be if you wanted to emphasise that you choose not to ("In the end, I never did say that."), or if you want to contradict something ("You said the Earth was flat!" "I never did say that!"). "I never did say" places a lot of emphasis on never did, and you would need some reason for that emphasis.


C# alternative to Visual Basic .NET namespace My

Question: I'm a VB.NET programmer, but I'm new to C# and now I'm working with C# project which uses local resource files (.resx).
Using VB.NET I can access to variables in resource file via My.Resources.< LocalResourceFile >.< MyVariable > . But in C# I can't find any alternatives for My namespace, but I still can access to resource if I replace My namespace with < MyProjectNamespace >.
Maybe there are any other way to access my local resources?
Comment: There is no such thing in C#.
Comment: You can use (most of) the My namespace's convenience classes from c# if you wish: http://msdn.microsoft.com/en-us/library/ms173136(v=vs.110).aspx
Answer: If you absolutely must use the equivalent of the My namespace, there is actually such a thing in C#. It is the Microsoft.VisualBasic.Devices.MyServices namespace. To use that, you must add a reference to Microsoft.VisualBasic.dll and add using Microsoft.VisualBasic.Devices; to your code file. For this route, see here: http://msdn.microsoft.com/en-us/library/ms173136.aspx
I would not, however recommend doing that. Instead, to access resources, you simply use MyNamespace.Properties.Resources like this:
namespace SomeNamespace
{
...
    var myFile = SomeNamespace.Properties.Resources.MyFile;
...
}

Answer: You can do this which is virtually the equivalent:
Bitmap image = Properties.Resources.picture000;

Answer: It still works the same way, just don't put "My.Resources" in front of the name.  So if you added a .resx file named "Resource1" and put a string named "Foo" in the resource then the variable name is "Resource1.Foo".
If you put code in non-default namespaces then you may have to prefix it with the default project namespace.  Like "WindowsFormsApplication1.Resource1.Foo".  If you are lost then just look at the auto-generated code.  In the Solution Explorer window open the node next to the .resx file and double-click the Designer.cs file.  Don't edit it.
Answer: There is no built-in My namespace, but you can reference Microsoft.VisualBasic.dll and have it.
Check out: http://msdn.microsoft.com/en-us/library/ms173136(v=vs.80).aspx


Calculate elevation from rgb from png created from qgis

Question: I am using qgis to create a raster elevation image (png) from SRTM data. I need to create a png via qgis which I will then query to determine the rgb of particular pixels via php. How do I define a color scheme within qgis in a way that I can then use the same gradient to calculate the elevation of the pixel from the png?
Answer: To be honest that is not a good way to do it.
But if you must then you could encode the value of the dem in the R (or G or B) element of the image by calculating 256*(value/maxValue). Your Php code could then reverse the calculation as maxvalue*(pixel/256).
Comment: Thanks. I need to determine elevations between 0 and 5000m so 256 colours would give me 19m intervals which I guess is the resolution of th SRTM data so that would work I guess. So I just choose multiband colour from the style section of the layer property?
Comment: better to use a 32bit tiff and read out directly


Why do we create?

Question: It could be an invention, or an idea, or anything.  What is the main reason behind why we create things?  I realize that there could be many reasons but I'm wondering if they can be summed up into one main reason.
Comment: @GeorgeChen I wasn't sure if this was the right place for a question like this but I threw it out there anyway.
Comment: Good question, who downvoted?
Comment: Is there any chance you could draw this out a little more? What exactly is it you would like someone here to explain to you? What might have made this an important problem for you in your study of philosophy? (Is there anything in particular you've been reading or studying that's made this problem become interesting to you?)
Answer: That answer depends heavily on the philosophy you are using to approach it.  Some conflicting answers might be:

Our concept of creation is illusionary, and it is the greater universe that is truly doing the creation.
We create because God gave us the ability to do so.
We create because it is the most powerful method we have at our disposal for reducing our entropy.
We create because it is required of us as humans by the supernatural forces that created the universe.
We don't create.

I think you might be able to make an argument "we create because we are conscious, and creation makes it easier to think."
Answer: The dominant reason behind creativity is blind impulse. Few communities have realized the value of blind impulses because blind impulses do not appear to have purposes. In Bertrand Russell's words:

In all men who have any vigorous life, there are strong impulses such as may seem utterly unreasonable to others. Blind impulses sometimes lead to destruction and death, but at other times they lead to the best things the world contains. Blind impulse is the source of war, but it is also the source of science, and art, and love. It is not the weakening of impulse that is to be desired, but the direction of impulse towards life and growth, rather than towards death and decay.
Source: Russell, Bertrand. Why Men Fight. New York: The Century Co. 1917

Since events in the brains do not transcend physical laws, the ultimate reason why some people have these impulses must lie in the physical nature of these brains. In another book, Education and the Good Life, Russell emphasized the importance of good habits.

Why do we create?


"bag" vs "package"

Question: In American English, would you say that chips, cookies, and candies are usually packed in bags or would you say they are packed in packages? I can't see much difference between a plastic bag and a rather big loose plastic package as their definitions seem to overlap to an indefinite extent. Would you please help me distinguish those concepts ("bag" and "package") when it comes to food packaging?
Answer: "Bag" is definitely the word of choice for packaging that is loose, allowing for movement of the contents.
"Package" would be understood, but is generally reserved for rigid packaging (even if the outside consists of sealed plastic). A point of possible confusion is that many people use "package" when referring to something that has been (and is currently) packed for shipping (e.g. cardboard boxes).
"Box" does not appear on your list, but, in my mind, is the word in general use for rigid containers with rectangular sides (usually made from thin cardboard and containing a sealed bag which holds the items).
This probably goes without saying, but the convention is always to refer to the outermost container.
Answer: I'd call this a package of cookies:

I'd call this a bag of chips:

I'd call this a box of cereal:

The box is made of cardboard on all sides. The bag has no firm sides, and no inner packaging; it's much like a sealed pouch. A package is often made using a material similar to the bag, but the inner plastic tray makes it a package.
NOTE: This is only for packaged foods. There are other kinds of bags:

and this is a package made from a box:

Interestingly enough, after you open that package, it becomes an empty box.
Comment: This is an excellent answer.
Answer: A bag is a specific type of container, made from a loose material, such as plastic or cloth, although there are also paper bags.
A package, generally speaking, refers to the entire packing container and its contents.  This could be contained within a bag, a box, or some custom wrapping of sorts.

"bag" vs "package"


Designing a centralised command api

Question: I'm working on a personal project that has a fairly complex UI. As much as possible I would like to remove mouse interaction. To help with that I am working on a kind of in app command line, where you can find all the actions by opening a popup and type in the names to run them. (think intellij ctrl-shift-a, or eclipse ctrl-f12). I would also like a way to add a way to pass an arg to the command (e.g. skipback 50s)
I am having a hard time figuring out how to design this. Currently my idea is to have a common Commands object that contains all the commands, and a Command interface that contains logic, a user friendly name, and an arg description (if any). Part of the problem is that some actions can only be performed in certain contexts, and the other problem is where to put the individual Commands (this is an issue because scala objects are lazy, and they won't be added to the Commands object until after being referenced). I'm also unsure how to keep type safety, since thees Commands will also be linked to from UI hooks inside the app.
Any ideas on how to fix this and/or improve the current model?
Answer: One way to accomplish what you're looking for is to implement the Observer pattern.
For example, instead of having a single, centralized "commands" object that defines all possible commands, you'd have a centralized event dispatcher. Each "command", when instantiated, would register itself with the dispatcher.
When the command palette is called, an "event" is emitted containing the current context data. The dispatcher will send that event to each command registered. Using the context data sent with the event, the command can then decide what to do: include itself in the list, ignore the event, modify itself based on the context data provided, etc.
A more sophisticated model would be to emit different types of events for each context. Commands could then, when registering with the dispatcher, state explicitly which types of events they care about. The dispatcher would then decide which commands should receive the event in the first place.
Answer: One possible solution is below.
These take in a data structure and return another data structure. These delegate and have no ifs or loops. This should have idempotent functions only so it is unit testable.
For things depending on the environment, make a interface for a pitiful are role. Then make roles implement the interface with dependency injection (integration tests, one thing at a time with mocks for what's not under test). Then make a class return one of the choices.
Your UI is now variable, separate from business rules.
As for context, your packages or namespaces should scream it. Make names after job titles. Those are user roles. Locations in the company building have a few work flows. Each workflow can be a interface and a situation can be one implementation. Make sure the interface allows failure and partial completion. A graceful failure class for each could redirect what people do to get around the problem.
Comment: I'm totally confused.

Designing a centralised command api


debian can't install a package from bookworm/backports

Question: I have tried to install emacs 29.1 from bookworm-backports, but emacs --version still gives me the wrong 28.2 version.
user@user-x370pro4:~$ sudo apt install emacs/bookworm-backports
[sudo] password for user:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
emacs is already the newest version (1:29.1+1-5~bpo12+1).
Selected version '1:29.1+1-5~bpo12+1' (Debian Backports:stable-backports [all]) for 'emacs'
The following package was automatically installed and is no longer required:
  librnp0
Use 'sudo apt autoremove' to remove it.
0 upgraded, 0 newly installed, 0 to remove and 67 not upgraded.
user@user-x370pro4:~$ emacs --version
GNU Emacs 28.2
Copyright (C) 2022 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of GNU Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.

Above that, I cannot do sudo apt install emacs-gtk/bookworm-backports as I get the following:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Selected version '1:29.1+1-5~bpo12+1' (Debian Backports:stable-backports [amd64]) for 'emacs-gtk'
Selected version '1:29.1+1-5~bpo12+1' (Debian Backports:stable-backports [amd64]) for 'emacs-bin-common' because of 'emacs-gtk'
Selected version '1:29.1+1-5~bpo12+1' (Debian Backports:stable-backports [all]) for 'emacs-common' because of 'emacs-bin-common'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 emacs-common : Depends: emacs-el but it is not installable
E: Unable to correct problems, you have held broken packages.

Thank you very much!
Here is my sources.list:
# See https://wiki.debian.org/SourcesList for more information.
deb http://deb.debian.org/debian bookworm main non-free-firmware
deb-src http://deb.debian.org/debian bookworm main non-free-firmware

deb http://deb.debian.org/debian bookworm-updates main non-free-firmware
deb-src http://deb.debian.org/debian bookworm-updates main non-free-firmware

deb http://security.debian.org/debian-security/ bookworm-security main non-free-firmware
deb-src http://security.debian.org/debian-security/ bookworm-security main non-free-firmware

# Backports allow you to install newer versions of software made available for this release
deb http://deb.debian.org/debian bookworm-backports main non-free-firmware
deb-src http://deb.debian.org/debian bookworm-backports main non-free-firmware

Comment: What is the output of `sudo apt update` ? and have you tried: `sudo apt install emacs -t bookworm-backports` ?
Comment: Thank you very much Gilles Quénot ! It works, the question is resolved
Answer: You need:
sudo apt update
sudo apt install emacs -t bookworm-backports


Can you change your party's starting positions?

Question: In most battles, it would be advantageous for one party member to start in one spot as opposed to another. Is it possible to swap their start locations or influence it in any way?
Answer: From what I can see, you can get a different party layout if you choose 2 rabbids as opposed to 1 mushroom kingdom member and 1 rabbid. It doesn't appear to be a fine-grained control but it can help in some cases.
Answer: To clarify Seiyria's answer, the level starting positions are basically fixed and ordered 1-2-3. The starting positions are filled in your team roster order, which is determined by reading the selected characters from left to right in the team selection screen.  Mario is on the far left, so is always position one.  The next selected character as you read from left to right is number two, and the rightmost one is number three.
Update: It appears that Luigi, Peach, and Yoshi are always assigned to position 3 regardless of party selection
With this in mind, you can exert limited control over the starting positions. If you really want, for example, Rabbid Mario to start in position #2, then select a party member that sequentially comes after Rabbid Mario on the team selection screen to be your third member.
Comment: This doesn't appear to be true, at least not with what I'm trying. Right before 2-8 where Peach gets inserted, it swaps out Luigi no matter which Rabbid you select (even Rabid Mario, who's sequentially after Luigi). So it seems like the Rabbids are always before Luigi.
Comment: @JeradRose Having just retested, if you have selected a non-rabbid as a party member (Luigi, Peach, Yoshi), they are always in position 3.  If you select two rabbids, my original description is accurate (My example has been updated)
Comment: Yeah, I also figured out (after getting Peach) that you have to have at least one Rabbid. You can't have a party with Mario, Luigi, and Peach. Thematically makes sense, but strategically unfortunate in some cases.


Would asking why the TF2 Market is and began fluctuating be a valid question?

Question: I want to know why the TF2 economy started changing crazily, but I don't know if it would be considered a valid question on this site. Should I ask it, or would it likely be closed?
Comment: I am talking about the rise of keys and drop of buds (which leads to the drop of everything else).
Comment: I was about to write an answer but decided against it. I'd be inclined to think that your question pertains more to economics than to gaming. However, if you look up [Diablo 3 questions about the auction house](http://gaming.stackexchange.com/search?q=%5Bdiablo-3%5D+auction+house+is%3Aquestion), there are over 100 results. So, I'm not so sure.
Comment: No, because it's a time limited thing. It won't be relevant in a few years' time, or possibly even in the coming months. Most of the Steam Community Market is crashing thanks to the influx of GTAV, in which many players have sold their items for cheap prices to get money for it, causing a lot of normally expensive items to fall down in price quickly.
Comment: @hotlinecalifornia I am not asking about the Steam Community Market, I am asking about the TF2 Market, and what caused it to start going to ruin a couple of years ago.
Comment: @ShadowZ. I would still close it as too localized.  People either claim a few things, either the massive downfall of ref and the rise of price of keys on bp.tf, or others will claim it is the rise of CSGO that lay an end to TF2.
Comment: @hotlinecalifornia So it seems like there would be too many non-concrete answers, and a concrete one would take too long to find?
Comment: @ShadowZ. More like a concrete answer is up to everyone's personal interpretation.
Answer: Our experts in TF2 - whilst great at explaining gameplay and strategy & could probably talk about the mechanics of trading - probably don't have a complete  understanding of how the TF2 Economy works and what could cause such a fluctuation.
I feel like any answer would require more than just a general understanding of Economics and therefore would require users who can explain what causes market fluctuations in general and why they apply to this specific case.
I think you should consult with Economics.SE instead and see if it is a question they could accept there.
Comment: Although I would also vote questions like these as off topic on our site, you should keep in mind that there are a lot of (online) games with players focusing solely on the economic aspect of the games. I think these questions could be on-topic with a rise of popularity in in-game economics.


publishing objects and thread safety

Question: I read in "Java Concurrency In Practice" that "publishing objects before they are fully constructed can compromise thread safety".
Could someone explain this?
Answer: Consider this code:
public class World{
    public static Point _point;

    public static void main(String[] args){
        new PointMaker().start();
        System.out.println(_point);
    }
}

public class Point{
    private final int _x, _y;

    public Point(int x, int y){
        _x = x;
        World._point = this;//BAD: publish myself before I'm fully constructed
        //some long computation here
        _y = y;
    }

    public void toString(){
        return _x + "," + _y;
    }
}

public class PointMaker extends Thread{
    public void run(){
        new Point(1, 1);
    }
}

Because Point publishes itself before setting the value of _y, the call to println may yield "1,0" instead of the expected "1,1".
(Note that it may also yield "null" if PointMaker + Point.<init> don't get far enough to set the World._point field before the call to println executes.)
Comment: To be exact, it may even print "0,0". If we leak the this reference from the constructor, the JLS doesn't make any guarantees wrt finals.
Answer: new operator is allowed to return a value before the constructor of the class finishes. So a variable might not read null but contains an uninitialized class instance. This happens due to byte reordering.
Some clarification:
From a single thread perspective the JVM is allowed to reorder some instruction. When creating an instance traditionally you would think it goes like this:

allocate memory
run initialization (constructor)
assign reference to
var

While in fact the JVM might do something like:

allocate memory
assign reference to var
run initialization
(constructor)

This has performance advantages since addresses don't need to be lookup up again. From a single thread perspective this doesn't change the order of the logic. You're program works fine. But this poses a problem in multithreaded code. This means the reference can be published before the constructor has run. Therefor you need to an 'happens-before' rule to make sure the instance is fully initialized. Declaring variables volatile dos enforce such happens-before rules.
More on reordering:
http://www.cs.umd.edu/~pugh/java/memoryModel/jsr-133-faq.html#reordering
Comment: I would have thought that, instead of this, the reference is likely talking about publishing the object within the constructor (or something that it calls).  I cannot think of a case where the new operator returns an object reference before the constructor that is called is complete.
Comment: @Travis Any source for this? For one, constructors may be inlined just as any other code and then there's no guarantee that one assignment happens before another. The only guarantees the JLS gives on this topic is that the reference isn't assigned before all final variables have been set - and that was added with the Java5 Memory Model. Now I also think the question is about publishing the this reference itself in which case we lose even the finals guarantee, but that doesn't change the fact that the answer here contains only facts.
Comment: Also we don't need a source for this - at least it'll be pretty hard to find this spelled out in the JLS, because it's just the usual "as-if" rule. As long as assigning the not fully constructed object to the reference does not change single-threaded behavior and does not violate any other rules specified by the JLS (in this case the whole finals stuff) the JVM is allowed to do it if it wants to..
Comment: Who downvoted this? My statement is simply true. This is one of the reasons why double checked locking is broken.

publishing objects and thread safety


How did the Trojan allies get to Troy?

Question: Also, across which territory did they pass? From which side of the world did  they come?
Comment: To avoid obvious answers, you should take a look at the [Trojan Catalogue](https://en.wikipedia.org/wiki/Trojan_Battle_Order) article on Wikipedia and update your question to tell us what more you are looking for.
Answer: Trojan war is known to us really only through Homer. His epic poems are more works of mythology than history. So the events of Homer's war are not really  historical facts that can be reasoned about in this way.
We can fairly reasonably trust some of the basic facts Homer presented though. For instance, here's a map of Bronze Age Greece, with place names given by Homer.

One thing you may notice immediately is pretty much every place is on the coast. There's a reason for that. Boat was by far the fastest means of travel at the time, but even by the standards of the day, Greek society was maritime-based. Particularly in Anatolia, the powerful Hittite Empire controlled the interior, but anywhere a boat could reach in this area was instead Greek.
Troy, where the map-makers have placed it, is also a coastal city. So it frankly wouldn't have made much sense for anyone who ever attacked it, barring neighbors who share a border (or the Hittites) to have arrived any other way than by boat.
In fact, the part of the Illiad all these place names are taken from is called the Catalog of Ships*. According to that work this was accomplished with a fleet of over a thousand ships arriving from 29 different places.
* - This is considered by some to be a later work, tacked onto Homer's
Comment: I want to help you,- only Percotes came with a boats,others came "go on foot".Paeonians travelled 12 days, Homer never says they passed across the sea .Thracians came with horses,without boats,but how?

How did the Trojan allies get to Troy?


How well does the CanoScan Lide 400 Slim digitize 35mm negatives?

Question: I'm an amateur in the analogue photography scene and don't have the resources to "build" an analog lab where I live. However, I want to make some experiments with some developed film I have at home and then digitize the negative to process the results. Now the problem is that this is going to be an experimental thing and would like to buy a scanner with a good value for money. During this research I saw this scanner being mentioned several times, but when I see the reviews, people mostly buy it to scan documents and whatnot, and I'm having second thoughts. Has anyone tried it with 35mm film?
Comment: I don't think this scanner provides a back light option to scan transparencies.
Comment: " analog lab "  =  Darkroom  -  " analogue photography "  =  Film Photography. " digitize the negative to process the results " = Non analog photography!
Answer: According to the Canon website, the CanoScan LIDE 400 is "made for scanning photos and documents". The type of sensor it uses is not suitable for scanning film negatives or transparencies.  (CIS = Contact Image Sensor)
Other options include:

Flatbed scanner with transparency adapter.  Many people seem to get good results with Epson Perfection V### scanners. They usually include the backlight and film holders needed to scan a variety of film formats.
Dedicated film scanner. The highest rated film scanners, made by Nikon and Minolta, appear to no longer be in production. Mid and low-end models from other manufacturers are still available.
Film digitizer. These use digital camera sensors for capture. They're faster than true scanners, but have reduced image quality from the small sensor size and color array. Some models capture directly to SD card. They are fast and easy to use. Depending on your needs, this type of digitizer may produce adequate results.
Slide-copy attachment. There are two types. One has a built-in macro lens that attaches directly to your camera. The other attaches to the filter threads of a macro lens you already own. The quality of your captures depends on how careful you are with setup, lighting, and post processing. This is the most time consuming option.
Have someone else scan your film for you. Most labs offer this service along with development.
Comment: Anecdote here about my experience in getting the lab to scan film (but for 120 film).  One lab (B+W lab, doesn't process color) local to me is charging around $20/image for its lowest resolution scan.  So it doesn't take much scanning to add up to the price of a decent scanner.  If I get low res scans with development at another lab its $5 to process and $12 more to scan the roll at the same time (but I'm not happy with their scans).  So the overall outsource vs buy economics are important.  After my last shoot I'm halfway to the cost of a V850 after selecting just the best pics only. But YMMV
Comment: I looked at the LIDE series when I was shopping for a scanner (literally over this past weekend) and dismissed them when I noted that none offer a backlight.  I wound up buying a used Epson 4870 which, at 4800 ppi, should pull about 31-32 MP out of a 35mm negative.
Answer: I've not used that particular scanner, but based on my experience with other flatbed scanners and dedicated film scanners I'd say you'd almost certainly be better off using a dedicated film scanner that typically has higher resolution and better backlighting of the negative than flatbed scanners do. Just be sure to get one that allows you to connect it to your computer to control it as it scans using an application and that allows you to save the results in at least 16-bit TIFF, rather than converting them to JPEG before sending them to your computer.
But to get the best results requires equipment well out of that price range. If possible, get the negatives scanned by a pro lab with very high end scanning equipment and request the image be delivered in 16-bit TIFF format, rather than converted to JPEG.


Catholic Church - What happens when a married couple will never have sex?

Question: Let's say that they just do not want to have sex for some reason after the wedding.
Does it mean that their marriage can be annulled by the Catholic Church even if they were married for 10 years?
Comment: What research have you done, and what has  your pastor told you about this?
Comment: @KorvinStarmast : I have no pastor. :-) And, I have not asked anybody from the clergy of the Catholic Church about it yet.
Answer: In the general case marriage requires consummation, but the Catholic Church allows an exception which is called a "Josephite Marriage."  This is the kind of marriage that the Catholic Church believes Mary and Joseph entered into: a marriage without sex.
Despite the fact that no consummation took place, a Josephite marriage is not intrinsically invalid.  Even so, a marriage that has never been consummated would be more easily exited than a marriage that has been consummated.  Indeed the condition of consummation goes hand in hand with indissolubility.  If a marriage is consummated, it is indissoluble.  If it is not consummated, it is dissoluble.  Whether or not it is consummated, the marriage exists.
Dissolution of a marriage is actually different from annulment of a marriage.  Annulment says the marriage never existed; dissolution means that a partial marriage is being dissolved.  If a marriage is ratified and consummated then there exists the possibility of annulment, but not the possibility of dissolution.  If a marriage is ratified but not consummated then both the possibility of annulment and dissolution exist.

Canon 1141 explains the Church's theological understanding of the
  significance of the consummation of a valid marriage: a marriage which
  has been ratified and consummated (ratum et consummatum) cannot be
  dissolved by any number power, or by any cause other than death.  If a
  couple have been validly married, and have consummated their
  marriage, the Church holds that their marriage is indissoluble.
  Period.
But if the couple were validly married, yet had never consummated
  their marriage--a marriage ratum sed non sonsummatum, in other
  words--the situation is theologically quite different!  Such a
  marriage can be dissolved by the Roman Pontiff for a just reason,
  at the request of one or both parties to the marriage (canon
  1142).  A ratum sed non consummatum marriage is not
  indissoluble, because the indissolubility of a valid marriage comes
  about through its consummation.
-Canon Law and Consummating a Marriage
Comment: Occasionally, spiritual marriages may also be entered later in life, with the renunciation of sexual relations after raising a family to fully dedicate oneself to God. In October 2001, John Paul II beatified a married couple, Luigi Beltrame Quattrocchi and Maria Corsini, who bore four children, but later in life lived separately and committed to a Josephite marriage.
Comment: I'm wondering if Joseph and Mary's marriage was only valid without consummation because of the extraordinary choosing of them for raising the Christ, their therefore true but not strictly regularly begotten Child.
Answer: According to Catholicism, what happens when a married couple will never have sex?
As long as they wished to remain married, they shall be be considered as a married couple.
Or for some just reason one or both decide to separate, it is up to the Roman Rota to grant a dispensation from ratified and non-consummated marriage. Since the marriage has not been consummated, an annulment is not necessary. Up to August 30, 2011 only the Holy Father could dissolve a marriage "ratum sed non consummatum". Pope Benedict XVI had transferred this over to the Roman Rota.
It must first pass through the local ordinary (bishop), who will take the petition to the Vatican. (Source)

Apostolic Letter in the form of a "Motto Prprio": QUAERIT SEMPER of the Supreme Benedict XVI with which the Apostolic Constitution Pastor Bonus is amended and certain competences transferred from the Congregation for Divine Worship and the Discipline of the Sacraments to the new Office set up at the Tribunal of the Roman Rota for processes of dispensation from ratified and non-consummated marriage and for cases concerning the nullity of sacred ordination.
I have therefore deemed it opportune to transfer to a new Office, set up at the Tribunal of the Roman Rota, the competence for processes of dispensation from ratified and non-consummated marriage and cases concerning the nullity of sacred ordination.

A dissolution of an unconsummated marriage is more in view of a dispensation (dissolution) from marriage vows.

The favor of dispensation from a marriage ratum sed non consumatum is an inherently administrative procedure, while the process for obtaining a Declaration of Nullity (often misleadingly termed "annulment") is an inherently judicial one. In a ratum the valid marriage bond is dispensed from, while in a Declaration of Nullity a marriage is declared to have been null from its beginning. A ratum ends, for a just reason, a marriage that truly is (although never irrevocably and sacramentally "sealed" by consummation) while a Declaration of Nullity juridically declares that a marriage never truly was in the eyes of Catholic theology and matrimonial law. - Dispensation vs. Declaration of Nullity
Comment: @KenGraham That's not correct.  A consummated marriage is also considered a valid marriage, but that doesn't mean it cannot be annulled.  The conditions required for a declaration of nullity can apply to a marriage whether or not it has been consummated.  Again, the only difference is that a consummated marriage cannot be dissolved.  An unconsummated marriage can be annulled or dissolved, as those are two different things.  If the ratification was believed to be true, then it must be dissolved rather than annulled.  If it was believed to be false then an annulment would be sought.
Comment: @KenGraham "Up to August 30, 2011 only the Holy Father could dissolve a marriage "ratum sed non consummatum". Pope Benedict XVI had transferred this over to the Roman Rota." This is not correct: He transferred the preperation of the dispensation from the of the Congregation for Divine Worship and the Discipline of the Sacraments to the Roman Rota. It wont dispensate independently, but "submits a petition to the Supreme Pontiff requesting the dispensation" (Art. 126 § 2 Pastor Bonus in version of Art. 2 Quarit Semper). Only the Pope in person can dispensate such a marriage (can. 1142 CIC).
Comment: So, in such a case every single marriage when the husband and the wife have never had sex after the wedding will be annulled, right?
Comment: It can not be annulled, but it can be dissolved. This is the term used for a marriage where the couple have practiced virginity.
Comment: It can be annulled or dissolved, but it will not necessarily be annulled or dissolved.  It is presumed to be a true marriage until someone undertakes a process of annulment or dissolution.

A Josephite marriage can be annulled just the same as a consummated marriage.  The only difference is that a consummated marriage cannot be *dissolved*.
Comment: @zippy2006 A marriage non-consummated is considered a valid marriage, it can not be annulled. An annulment is a declaration that the marriage is invalid and never took place. Thus it can only be dissolved prior to sexual intercourse by a competent authority. That is why it is reserved to the Roman Rota to make the decision.
Comment: @zippy2006 I never said a unconsummated marriage is not a valid marriage or can not be annulled.
Comment: You have never said it is invalid, but you have said it cannot be annulled.  In the second comment above you say, "It can not be annulled,..."  In the fourth comment above you say, "A marriage non-consummated is considered a valid marriage, it can not be annulled."