How many cables are you allowed to run through a single hole in a wooden floor joist?

Question: How many cables are you allowed to run through a single hole in a wooden floor joist? For example, could I run five 12-2 cables through a 1-1/8" hole? I know they physically fit, but is there a code to regulate this? Is there any limit on this or some table for guidance?
Comment: Would the cables be bundled on either side of the hole?
Comment: by cable I assume you are specifically talking about electrical (as opposed to networking or coax or low voltage or the like?)
Comment: I don't know how many cables by the latest code, there is one though. I only know the outdated one from the 80's that was 2 per hole. The reason for the limit is heat build up, same reason why cables can't be pulled tight or staples be driven tight.
Comment: What type of cable?  Will the cables be in contact with insulation near where they pass through the joist (are the joist bays insulated)?
Answer: Nonmetallic-Sheathed Cable
The Answer
According to the National Electrical Code, you can have 4 12/2 nonmetallic sheathed cables through a single bored hole that is fire- or draft-stopped using thermal insulation, caulk, or sealing foam, or where proper spacing is not maintained for more that 24 in. If you maintain proper cable spacing (which is defined by individual cable manufacturers) where not passing through joists, you can jam as many cables as you like (without damaging the cables) through a bored hole (that is not fire- or draft-stopped using thermal insulation, caulk, or sealing foam).
The Work
Article 334.80 tells you that you can use the 90°C column from Table 310.15(B)(16) for derating, but the final value must not exceed the 60°C column.  If you look at Table 310.15(B)(16), you'll find that 12 AWG copper wire is rated at 30 amperes at 90°C and 20 amperes at 60°C.
Table 310.15(B)(3)(a) tells you that with 7-9 current carrying conductors, you'll have to derate the ampacity by 70%.  So with the information from Table 310.15(B)(16), and Table 310.15(B)(3)(a). The math is quite simple.
4-6 current carrying conductors
30 amperes * 80% = 24 amperes
7-9 current carrying conductors
30 amperes * 70% = 21 amperes
10-20 current carrying conductors
30 amperes * 50% = 15 amperes
Which shows that you can have between 7 and 9 current carrying conductors through the bored hole, before the wires are derated below 20 amperes (from Table 310.15(B)(16) 60°C column). Since each 12/2 cable has 2 current carrying conductors, you can figure that only 4 cables can pass through the bored hole (2 * 4 = 8).
The Codez

National Electrical Code 2014
Article 334 Nonmetallic-Sheather Cable: Types NM, NMC, and NMS
II. Installation
334.80 Ampacity. The ampacity of Types NM, NMC, and NMS cable shall be determined in accordance with 310.15. The ampacity shall be in accordance with the 60°C (140°F) conductor temperature rating. The 90°C (194°F) rating shall be permitted to be used for ampacity derating purposes, provided the final derated ampacity does not exceed that for a 60°C (140°F) rated conductor. The ampacity of Types NM, NMC, and NMS cable installed in cable tray shall be determined in accordance with 392.11.
  Where more than two NM cables containing two or more current-carrying conductors are installed, without maintaining spacing between the cables, through the same opening in wood framing that is to be fire- or draft-stopped using thermal insulation, caulk, or sealing foam, the allowable ampacity of each conductor shall be adjusted in accordance with Table 310.15(B)(3)(a) and the provisions of 310.15(A)(2), Exception, shall not apply.
  Where more than two NM cables containing two or more current-carrying conductors are installed in contact with thermal insulation without maintaining spacing between cables, the allowable ampacity of each conductor shall be adjusted in accordance with Table 310.15(B)(3)(a).
Article 310 Conductors for General Wiring
310.15 Ampacities for Conductors Rated 0–2000 Volts.
(B) Tables.
(3) Adjustment Factors.
(a) More Than Three Current-Carrying Conductors in a Raceway or Cable. Where the number of current-carrying conductors in a raceway or cable exceeds three, or where single conductors or multiconductor cables are installed without maintaining spacing for a continuous length longer than 600 mm (24 in.) and are not installed in raceways, the allowable ampacity of each conductor shall be reduced as shown in Table 310.15(B)(3)(a). Each current-carrying conductor of a paralleled set of conductors shall be counted as a current-carrying conductor.
  Where conductors of different systems, as provided in 300.3, are installed in a common raceway or cable, the adjustment factors shown in Table 310.15(B)(3)(a) shall apply only to the number of power and lighting conductors (Articles 210, 215, 220, and 230).
Comment: Do you know which version of the IRC will spec the 2014 NEC?  Michigan is still using 2009 IRC (which uses the 2008 NEC).
Comment: @HerrBag No idea.  I'm not sure anybody has adopted NEC 2014 yet, so It's not likely IRC will pick it up until folks start adopting.
Answer: To my understanding per the NEC you can put as many wires through the bored hole as you want providing you don't over-stress or damage the wires. I'm not sure the discussion on de-rating is applicable since that applies to wires run through a raceway or a conduit, and the hole would have to be bored through a material that is 2 feet thick before the hole could be considered a raceway. As always however, you need to make sure your local electrical code does not have language regarding this issue which might be more stringent than the NEC.
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: Article 310 describes the general case of cables that do not maintain spacing for 600 mm / 24". A series of holes through floor joists is not described by that sentence. Moreover, references in the section to holes include firestopping. So the derating would apply to holes between floors that are firestopped but not joists which are not. Consider Gardner Bender's MuliCable Staples that support up to 8 12-2 NM cables in tight proximity. For the balance of the run, just as in between floor joists, the  conductors can dissipate heat build up that might occur where the cables are bunched through unfirestopped holes or the multicable staples. So, it seems both situations are tacitly excluded by Article 310. One wonders how being sandwiched within wall insulation gets address and not sure it does though that is where I might also wonder about grouping cables together and consider derating. Seems worse than in raceways.
Answer: Each 12/2 nm-b is a separate raceway so you can put as many as you want
If you read the question thru a hole not raceway


What is a good site to explore all of the different print materials?

Question: I am new to design and looking to get more familiar with different materials available to print on, different paper weights, learn about vinyls, etc. Does anyone know of some good sources to learn more about this?
Comment: Not an exact duplicate, but there is some relevant info here: http://graphicdesign.stackexchange.com/questions/80227/physical-paper-weight-reference/80239#80239
Answer: Modern machines can print on pretty much anything, the best thing to do is find a local print supplier and have a look at some items they produced. Some large printers can send you actual samples of different material.
Another thing you can do is look for a trade show in your area, these are multi-day events where all these providers and equipment makers will show off their tools and techniques. There will possibly be seminars and live demos you can attend. The Inprint trade show in Munich, Germany is one good example.
One thing i did recently was order a free business card sample pack from Moo which includes different types of paper and other finishes like varnish, silver layer, gold finish, etc.


How to connect my wordpress newsletter form to civiCRM?

Question: I need some help with connecting my wordpress newsletter form to civiCRM. I've just started using civiCRM and I want to connect the sign up form ( that I aready have in wordpress) with civiCRM, so that when contacts sign up for my newsletter in my page, it gets added in my lists in civicRM.
Comment: Welcome Dea!  You can help us help you by editing your question to add more info.  What plugin are you using for your newsletter signup form?  What's the service you use to send the mail?  Also - typically it works the other way around, you create a newsletter form in CiviCRM, then that sends the data to your newsletter service - but if you share more info maybe someone will have a solution.
Comment: @JonG-MegaphoneTech Thank you for replying, Im sorry Im new to all of this and Im trying to do everything on my own due to low budget.Service for sending mail is sendgrid My newsletter form in CiviCRM I can create it in Profiles, right? And how to I send data to my newsletter service? Isn't there some type of code in civicrm so I can implement it in wordpress?
Comment: It's a bit confusing to understand your setup, so there's a limit to how much DIY assistance you'll get.  Also - are you saying you construct your newsletter's content on Sendgrid.com?  That's pretty unusual - most people use Sendgrid as a pass-through for another service (e.g. CiviMail).  You can use profiles to let people sign up and their data will be entered in CiviCRM, but if you already have a form submitting that data to Sendgrid, you can't combine the features of both forms into a single form without custom code, which you want to avoid.
Comment: Various ways to approach this depending on requirements and what you want to achieve. You can use a CiviCRM profile and expose that via a shortcode on a page. Or you can use the Form Processor extension which I think can integrate with a form made using something like the Contact Form 7 plugin in WP.
Answer: you will need a 'connector' between WordPress and CiviCRM. Depending on if CiviCRM is installed within the Wordpress website or installed seperately, the way to connect will be different. If they are independent then you need a tool such as CiviMcRestFace. The inlay extensions pack can also be an alternative to expose a newsletter subscribe form on an external website and register the contact in CiviCRM.
You might need to change the form builder you use in Wordpress to tools that are compatible with CiviCRM. Actually there are different ways of setting this up.


Sympathy for a villain

Question: I have a villain. The villain is the hero of their own story. The villain starts off as good, looking to overthrow a monstrous leader. They were once in the same shoes as the heroes. Part of the heroes' journey will be to not fall from the heroes path the same way the villain did.
Is there something that can make the reader sympathetic to the villain as they make the cruel choices. I don't want the reader to love the villain or agree with them, perhaps just be a little sad that they gave up their humanity along the way.
Answer: You don't need to do much to make a reader sympathize with a villain. As you said, a reader doesn't have to like or agree with the villain, and in most cases they really shouldn't. However, a reader should be able to put themselves in that antagonist's shoes and see why they think the way they do, and why they have the mindset they do and make the choices they make. This is the key to creating believable villains that the reader will connect with and understand, despite not actually agreeing with their goals and their (usually horrible) actions towards the protagonists and others.
Great ways that I have found to make a villain more sympathetic and believable, while still keeping them "evil" enough:

Give the villain a backstory that shows where their dark side comes from. Perhaps they are cruel and hateful towards others because other people in their life have been cruel to them, and they have never learned any different. Perhaps they were brought up in poverty and needed to do terrible things to survive. Maybe their close friend or spouse fell ill and they turned to dark arts in desperation to save that person's life, but those arts slowly corrupted them. Whatever it is, give them something to show why they became this way and make them more sympathetic to the reader.
Give them a personality beyond just "being evil." A personable, charming, charismatic villain is sympathetic even while they perform horrible acts, and even small character traits beyond "evilness" go a long way to making sympathetic villains. A great example is Gollum from the Hobbit, who was corrupted by the One Ring's darkness but still retains flickers of his old personality and kindness he once had, making him sympathetic.

"Gollum looked at them. A strange expression passed over his lean hungry face. The gleam faded from his eyes, and they went dim and grey, old and tired. A spasm of pain seemed to twist him, and he turned away, peering back up towards the pass, shaking his head, as if engaged in some interior debate. Then he came back, and slowly putting out a trembling hand, very cautiously he touched Frodo's knee." - J.R.R. Tolkien, The Two Towers

Have a character whom the villain shares their thoughts with or confides in, to shed light on how they think. This could be a foil to the villain, or a captured protagonist whom the villain debates philosophy with, revealing layers of their character. An example is the imprisoned soothsayer from Kung Fu Panda 2, with whom the antagonist, Shen, debates the morality of his actions and thus illustrates why, under the cool facade he presents to the protagonists, he really wants to conquer China.

Soothsayer: Are you certain it is the panda who is the fool? You just destroyed your ancestral home, Shen.
Shen: A trivial sacrifice, when all of China is my reward.
Soothsayer: Then will you finally be satisfied? Will the subjugation of the whole world finally make you feel better? ...It is time to stop this madness... So your parents can rest in peace.
Shen: My parents... hated me.
Answer: Make him three dimensional and give him, as Sciborg says, a backstory to explain his journey into the shadows.
The character might just see the big picture and think the hero is naive and no different from how he was once. He will not notice the corruption of his soul as it was gradual and seemed necessary to attain his goal.
You could give him moments of regret and he might misunderstand his own situation just enough that he believes he might help the hero by teaching him what experience taught him.
Villians who are one note are boring. Those that are complex and have thoughts beyond destruction are more chilling and intriguing as they are more realistic.
Sometimes the villain is right. Ozymandias in Watchmen did what he did to promote world peace. Lex Luthor in Batman vs Superman is presented as a man who saw the big picture and might actually be right about potential risk of having an alien living among us.
Give your dark one some thoughts outside of plotting, something beyond ruling with an iron fist. He might have learned the necessity of such from history. The Tsars, for example, tended to alternate between a ruler who wanted to improve the lot of his people and failed - often assassinated - to tyrants who saw their kinder father killed by the people he wanted to help. His son would rue the lengths to which his father went and be lenient, repeating the cycle.
Make him a person who has strayed off the path and not noticed that the darkness he sees is within him. Give him something to hold onto, something beyond the usual. Give him some humour and maybe some charm. His actions are terrible, his choices impossible, but he himself believes that such must be done, sacrifices made for the greater good.
In one novel I was working on, I had my hero hating my villain. He hated everything he stood for and he would strive to foil him at all points, knowing himself to be the hero. He was the mage wielding white magic and this black sorcerer was evil incarnate.
Only, I discovered he was wrong. My villain was serving the greater good, making sacrifices that seemed impossible but were necessitated by the actions of the hero, who was wreaking havoc with the best of intentions. I had a villain who was serving the good and a hero who was paving his road to destruction with the best of intentions. I liked this better, the supposed hero being an inadvertent villain and the feared villain holding everything together with everything at his disposal.
Answer: In Writing Screenplays that Sell, Michael Hauge lists these methods for creating empathy with a character, and I believe they work the same for heros and nemeses:
By creating sympathy - by making the character a victim of undeserved misfortune.
By putting the character in jeopardy - which doesn't have to be life threatening. It could be about the danger of exposure, embarrrasment, loss of a job...
By making the character likeable -

showing them as good hearted and generous (this particularly relates well to your question - he cites Tom Hanks in Road to Perdition being a mobster and hired, killer, but he is first introduced as caring family man - gaining the audience's empathy)
showing them as well liked by other characters
Make them funny - there are some really reprehensible characters out there that we still like because they make us laugh

By making them highly skilled - we are drawn to people who are talented
By showing them in touch with their own power - closely related to skill. Powerful characters fascinate and attract readers
By giving them flaws and foibles  - we all walk into walls from time to time, so seeing a character do the same increases identification.
Hopefully there's something in there you can use!

Sympathy for a villain


Behavior Monitoring in Endpoint Protection Platform

Question: There are some EPP solutions that are considered very innovative (Crowdstrike, SentinelOne...) for the use of Behavior Monitoring. What is the difference with more standard EPP solution (ex. Symantec Endpoint Protection) that have also some behavioral monitoring capabilities?
Answer: Generically, an EDR-EPP combination such as the ones you describe will assign a threat score based on machine learning, statistical techniques, and a variety of known badness factors, such as enrichments from machine-readable threat intelligence (which can, in turn, also be informed by machine learning, reinforcement learning, and statistical techniques).
I would say the primary variables that lead to a higher threat score (and this changes over time), would be Prevalence factorization, such as through a large customerbase, but also specific to each's environment(s).
Combined with spawning numerous processes, levering LOLbins in unusual/outlier ways, and other combinatorials (not too too many packaged Portable Executables will lever kernel timing functions and also have access to the camera, microphone, and network stacks -- only implants typically display ALL of this activity at once). Those combinatorials typically are referenced through function (API) analysis, and their associated imports. Anti-detection, system querying, anomalous in-binary values, and certain memory-handling conditions are supplementary to the above.
Please ask deeper questions on the above and I can provide deeper answers.
Answer: Crowdstrike and Sentinel one use EDR or Endpoint Detection and Response, Symantec EEP, Mcafee need a central server to help make the decision of the response. This can hampen decision times (by seconds) but with Malware this can make the difference between a compromise or not.
Symantec uses IOA's and heuristics to detect events.
Crowdstrike uses IOA's IOC's and Machine Learnt data.
SentinelOne uses IOA's IOC's and Machine Learnt data.
The problem with older type AV (like SEP) is that an attacker could be in the network for days or weeks before they detonate any malware or attack. Most NGAV's should catch this reconnaissance if its out of the normal.


A word to describe hidden sexual intent... play on words

Question: What's a word to describe hidden sexual intention? e.g "Haha I was reading your profile and ...you seem pretty tight ;-)"  How would I respond with a word that describes double meaning of a sentence to actually mean a sexual advance on the sly? Does that make sense? A play on words..
Answer: The one I am most familiar with is a double entendre. Merriam-Webster gives

double entendre
noun dou·ble en·ten·dre \ˈdüb-əl-äⁿ-ˈtäⁿd(-rə); ˈdə-bəl-än-ˈtänd(-rə)\
1
  :  ambiguity of meaning arising from language that lends itself to more than one interpretation
   2
  :  a word or expression capable of two interpretations with one usually risqué
Answer: The phrase Sexual Innuendo is what I would say they're using.

The term sexual innuendo has acquired a specific meaning, namely that of a "risqué" double entendre by playing on a possibly sexual interpretation of an otherwise innocent uttering. For example: "We need to go deeper" can be seen as either a request for further inquiry, or a request to go deeper into an intimate part.

Innuendo on Wiki
Answer: The word is Double-Entendre. This can refer to any sentence with two meanings, but most often is used when one meaning of a sentence is innocent and the other is sexual.
If it has an unintentional sexual undertone, you might call it a Freudian Slip, implying that someone's sexuality accidentally expressed itself.
A colloquial phrase for this is "... if you know what I mean." This is useful for when you want to call to attention the sexual meaning a sentence can have.


cp --reflink=auto for MacOS X

Question: cp --reflink=auto shows following output for MacOS:

cp: illegal option -- -

Is copy-on-write or deduplication supported for HFS? How can I COW huge files with HFS?
Answer: Apple's new APFS filesystem supports copy-on-write; CoW is automatically enabled in Finder copy operations where available, and when using cp -c on the command line.
Unfortunately, cp -c is equivalent to cp --reflink=always (not auto), and will fail when copy-on-write is not possible with
cp: somefile: clonefile failed: Operation not supported

I'm not aware of a way to get auto behavior. You could make a shell script or function with automatic fallback a la
cpclone() { cp -c "$@" || cp "$@"; }

but it'll be difficult to make it entirely reliable for all edge cases.
Comment: @JorgeOrpinel The easiest, cross-platform way is to time it: just copy a 512M file. Reflink happens at the extent level, so there should be no expectation for knowing it from, say, reading the inode. I am not aware of any command-line interface to the physical extent on APFS.
Comment: Seems to work for me. How do you check the copy is actually a reflink?
Answer: Updated November 2021: This answer has been rendered obsolete by oncoming coreutils changes. reflink=auto has been the default since 25725f9 (coreutils 9.0). APFS cloning is committed in the tree as 5e36c0c and should appear in coreutils 9.1.

Original posting November 2019: I wrote a patch (mailing list) for GNU coreutils that enables --reflink for macOS > 10.12. Yes, --reflink=auto will work, at least according to my time measurements.
Here are two ways to use it:

clone the git repository, run ./bootstrap, and then the usual ./configure -C and make -j12 install.
Apply the patch (rebased for 8.31) to another version of coreutils to skip the painful bootstrapping.

You can grab a bunch of possible parameters to use from the homebrew formula. Since the change is only useful for cp and mv only, you can opt to only replace these two binaries. (mv with reflink is useful for submodules.)

There is an associated patch that enables reflink=auto by default for cp and install too. If you keep forgetting about adding the option or want faster ginstall in your Makefiles, try it.
Comment: fwiw regarding the update: I have `cp` from coreutils v9.4 on Mac and it fails when using `--reflink=always`. Only `/bin/cp -c` works.
Comment: @hraban hmm, `gcp --reflink=always` is working on my end. It's also 9.4... macOS 13.6.4, bottled binary from homebrew.
Answer: uutils is a GNU coreutils clone written in Rust and supports reflink copies on macOS' APFS via the same syntax as GNU coreutils does on Linux.
Answer: Unfortunately the --reflink=auto option wasn't available in MacOS just yet. HFS also does not natively support CoW (Copy on Write).
Perhaps in future such support will be added - likely when ZFS becomes natively available or another native filesystem adds support.
I suggest referring to the man page to get the options that are currently available to you: man cp

NOTE:
In MacOS, most commands (including cp) only support short options, not long options. Thus, if there were an equivalent, it would be a single character only. Example would be -L or --dereference available in GNU coreutils' version of cp. In MacOS, only -L is available.

cp --reflink=auto for MacOS X


How would a Lagrangian be used to recover the Schrodinger equation?

Question: I heard that the  Lagrangian is defined in the path integral formulation of quantum mechanics. How would the Lagrangian in this formulation be used to recover the Schrodinger equation that we normally use?
Comment: This is probably what you're looking for: http://users.physik.fu-berlin.de/~kleinert/kleiner_re242/node2.html
Comment: The derivation in the link shows how you get from a solution of the Schrödinger equation to the path intergral formalism, but not the other way around. In this sense, the question is not really answered by it.
Comment: Googling "path integrals in quantum mechanics" will give you many sources, for example http://en.wikipedia.org/wiki/Path_integral_formulation If you have difficulty following the standard presentation please ask another question :)
Comment: Duplicate: http://physics.stackexchange.com/q/69982/
Answer: I am not sure if you are looking for this, but you can define a Lagrangian in such a way that the L-EOM (equation of motion) is the Schrödinger equation.
$\cal{L}=\Psi^{t}(i\frac{\partial}{\partial t}+\nabla^2/2m)\Psi$
$\frac{\partial\cal{L}}{\partial\Psi^t}=0$
The second term of the Lagrange-equation (derivative with respect to $\partial_{\mu}\Psi^t$) is zero since no derivative of $\Psi^t$ occurs in our field Lagrangian density .
Answer: To get from a given Lagrangian to the Schrödinger equation you have to realize that the latter is actually given in terms of the Hamiltonian of the theory. Lagrangian and Hamiltonian are related by a Legendre transformation.


time domain reflectometry pulse shape

Question: Alot of TDRs use square waves or needle like pulses for length determination. Why are not other pulse shapes like sine or triangle used?
Comment: If you need a good distance resolution, you must generate and detect very short pulses.
Comment: very short pulses can also be sine
Comment: If it's a pulse, it ain't a sine.
Comment: If it's a pulse it ain't a sine but it can be a "raised cosine" or a Gaussian.
Answer: In TDR, the two main parameters are pulse length (or rather shortness), to get bandwidth, and pulse power, to get signal to noise ratio. Once you've struggled to produce those, the pulse shape is whatever the mechanism you've used happens to give you.
It's rather like the dog that says 'sausages'. The wonder is that the dog can talk at all, not that its pronunciation is poor.
TDRs tend to use a step recovery diode into a pulse shaping network, for instance a shorted transmission line. All pulses tend to come out looking a bit Gaussian (if you're lucky). Square pulses tend to have their edges rounded off, delta pulses tend to be spread out a bit. As long as the pulse doesn't have a long tail, or ringing, or a double peak, then most users are generally happy with what they get.

time domain reflectometry pulse shape


How to open a URL with Terminal through applescript by using mpg123?

Question: I need to use mac terminal to open an audio stream from a URL through an applescript. I know that mac terminal is already equipped with afplay, but that only plays a file which is available on your computer. An alternative is mpg123 which can be installed in mac by means of brew. My question is how I can use this command in an apple script.
Answer: Command line programs can be run using the do shell script "..." command in AppleScript.  You can generally write a command as you would in Terminal, keeping in mind that double quotes need to be escaped with a preceding backslash \.  The do shell script command returns the last output to stdout.
So, for example:
do shell script "myvar=hello world; echo \"$myvar\""

will return hello world as a string.
These commands are run without a terminal, so can't interact with the user, e.g. to receive user input.  If you need a terminal, you can tell application "Terminal" to tell the front window to tell the front tab to do script "...".
But, do shell script "..." is perfect for most situations where bash commands need to be employed.
If it's useful to know, iTunes can also play audio streams from the internet.  You can do this from the command line like this:
open -a itunes "http://ssl.gstatic.com/dictionary/static/sounds/20160317/pronunciation--_us_1.mp3"

From within AppleScript, this might look like:
do shell script "open -a itunes \"http://ssl.gstatic.com/dictionary/static/sounds/20160317/pronunciation--_us_1.mp3\""

or, using iTunes scriptability:
tell application "iTunes" to open location "http://ssl.gstatic.com/dictionary/static/sounds/20160317/pronunciation--_us_1.mp3"

Comment: But I prefer to play the sound through terminal. I specifically need to know the syntax for using mpg123 command so that terminal can play the sound.
Comment: Type this into _Terminal_: `man mpg123` and it'll bring up everything you need to know on how to use the command.


How can I create a graphic like illustration of an actual design in photoshop?

Question: Okay, let me elaborate on the use case a little. I have a home based business that creates handcrafted products using cloth. Now I want a catalog of the designs of the cloth materials that I have in my inventory. I can work my way around by taking actual photographs of the cloth material and handing it over to the client. But this doesn't seem too professional to me, as the images look like they are crumpled and taken on a cell phone camera. How can I provide a more refined filter and make it look more graphical rather than an actual photograph.
Comment: Can you post an image please?  I don't know if it's possible to tell you anything without some visual reference - and as you know, graphic design is all about visuals
Comment: Take a couple of photos and put them to some cloud for us to see. Or insert one to your question. Do the photographing  under the sky, but in a shadow. Include a piece of neutral grey material into a corner of the same photos, not separately. Use white paper, if there's nothing else.
Answer: As someone who shops cloth from time to time, I would advise against using anything illustrated.
The look and feel of a piece of cloth is very important, one piece of patterned cotton isn't the other. It's going to be very hard to put a realistic representation of the fabric in your catalog through illustration. Personally, I wouldn't shop from a catalog with computer generated preview images, because there is just no way of telling what you're actually getting. It might also suggest you are trying to hide the 'real' photos, suggesting that the quality isn't all that.
I would suggest to either hire someone to take photographs of your cloth, or invest in making your own. You can get a long way with even 50 bucks and either make or buy yourself a small lightbox to shoot photos in. If you have a modern smartphone with decent camera, a lightbox can get you a long way.
Answer: You could use a scanner rather than a camera.
You could hire a professional photographer to take photos - resulting in high quality digital images, rather than "cell phone photos".
You could recreate patterns in software to create digital representations. How you accomplish this greatly depends upon the pattern itself and may or may not take considerable time and/or skill. Without some sample images, it is impossible to provide any real direction with this method.


Will it look good in my CV if I code up the same app or software using different paradigms?

Question: For example, I make an android app using different paradigms - functionally and imperatively. My premise is that it will look good on my resume, since I demonstrate that I can operate and implement software using various approaches.
Comment: Are you planning to do this as a project (for adding to your CV), or did you already do this, and are asking about how to advertise it on your CV?
Comment: plan to do it!!
Answer: You could start a blog series doing just that, ie. translating imperative code to functional and vice-versa. There you can demonstrate your knowledge (to the potential employer) by talking about the code, esp. the bits that don't translate, what needs to be done differently etc.
The point here is not writing the code per se, but demonstrating you know what you're talking about.
Answer: I think it would be fine, as long as these apps are well enough done and you have enough thought put into the resulting questions that might arise in an interview.
For example, if I was interviewing you and saw these apps, I'd be asking you which approach was "best", how you'd decide to use one tech over the other in future, etc. I'd be wanting to make sure you're not a 'shiny golden hammer' kind of person who finds out something new and then is determined to use it, even if it's not appropriate.
Answer: As previous experience has shown, it is never a bad thing to have something to show when you go on an interview. I've had several job interviews where they asked if I had examples of my work. Sadly, all of my coding is done for employment, and they rarely allow me to parade around internal software (I do a lot of internal client work), so I've had no examples. One recruiter very seriously told me to "get a hobby" and make some non-work related sites or software in order to have something to present to a prospective employer.
As long as they work and look somewhat decent, and as long as you tell the interviewer that they are proof of concepts or prototypes, then by all means show them off. They all like to know they're not hiring a person with no idea what they're doing, or only know what academia has told them. (Academia and Reality very generally do not co-exist well. Hah)


How to ask current company if they want to hire me and how to handle different company offer

Question: I'm currently doing an internship in a company. Supposedly, after finishing the internship they are going to hire me, that's what the told me when I first had the interview, but the thing is that I have no physical proof of that.
In the meantime, I have a friend that told me that in their company were looking for somebody and If I wanted them to recommend me. I was not especially interested, but I said yes anyways, because I didn't want to close any doors.
The thing is that if I'm offered a job after the internship in my current company, I would prefer to stay here rather than change to the other (if they also wanted to hire me), but since I don't know 100% for sure if they will hire me, I don't want to reject the other offer (if they make me one).
I haven't had the interview with the other company yet, I'm delaying it since I don't really know what to do.
I'm planning to have the interview anyways and I actually have two questions, depending on the possible scenarios:

In the case that I receive the other company's offer before knowing if they want to hire me in my current company, it would be ok to ask hr if they plan to hire me? If it is, how should approach the issue?
If they actually want to hire me, and the other company also wants to hire me, how should I reject the offer from the other company?

Note: The question title might be confusing, I didn't really know how to title it, so I if anyone can improve it I welcome edits.
Comment: [Is it okay to ask for a job guarantee at a company after an internship?](//workplace.stackexchange.com/q/99662) [What is the best protocol for courteously declining a job offer?](//workplace.stackexchange.com/q/1430) [Turning down a job offer professionally.](//workplace.stackexchange.com/q/5844)
Answer:
In the case that I receive the other company's offer before knowing if
  they want to hire me in my current company, it would be ok to ask hhrr
  if they plan to hire me? If it is, how should approach the issue?

Take the interview at the other company and proceed until the conclusion of the interview process.  At the moment, you do not have a guarantee of a permanent position from either company.

If they actually want to hire me, and the other company also wants to
  hire me, how should I reject the offer from the other company?

If you get an offer, then take that to the company you are interning at, and ask them if they would be willing to take you on as a permanent employee.  If the answer is no, at least you have a permanent job.
This is the only logical way I see to get a win out of your scenario, otherwise you risk potentially having nothing at the end of this.
Good luck!


Limit number of users in a security group

Question: I've a requirement like there should be only one user with some specific permissions on a given site. We should not allow Admin to add more than one user with those permissions, So I created a group with those permissions, now can I limit number of users in that group? or is there any workaround for this requirement?  I'm using office365.
Answer: On premises you can use this:
http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.speventreceivertype.aspx
In Office 365
You can in theory create an app that will handle the administration of those groups for you. However you'd have to hide the original permission management page (master page changes).


Recover hard disk file from corrupted one

Question: I bought a 1 TB hard disk from my friend to back up my files but when I tried to copy 150 GB of data to the hard disk, during the last 5MB my laptop shut down due to power loss. After power came back it boots normally but doesn't allow me to access the hard disk, I can't open it in Windows or Ubuntu. I tried Kaspersky virus removal tool to the clear virus and also the following:
$ sudo -i
# apt-get update
# apt-get install --reinstall exfat-fuse exfat-utils
# mkdir /media/user/exfat
# chmod -Rf 777 /media/user/exfat
# fdisk -l
%%Assuming the external drive partition is /dev/sdc1
# mount -t exfat /dev/sdc1 /media/user/exfat

Which is the command to change an un-accessible drive to accessible but in my case it shows:
FUSE exfat 1.0.1
ERROR: failed to open `/dev/sdc1'.

How can I access it?
Comment: It's just the 1 TB drive that's corrupted, right? Your laptop's drive is still ok?
Answer: Hard disk filesystem may be corrupted.
Install gparted:
sudo apt-get install gparted

open it:
gparted-pkexec

and then check the hard drive partitions. Be sure it's the correct disk: editing it will wipe out data.


Are there any horses that can carry items?

Question: In Oblivion I was able to give items to my horse. In Skyrim my horse is useless, all it does is attack monsters and get itself killed.
I have the basic horse (1000 gold) bought at Whiterun.
Are there any better horses? Where can I find them?
No spoilers, please.
Answer: Horses in Skyrim, like in Oblivion, have no means to carry items in the base, unmodified game.
(I'm not sure why you think your horse could carry items in Oblivion, unless you are referring to the bug wherein you beat Shadowmere unconcious and store items in her body)
Answer: Dead Thralls make decent luggage: you can have two, you can change bags when you like, and you can store them in a basement when not in use.
I like the luxury chashmere lined Gucci range of dead thrall, available covered in brown (leather), black (ebony), green (orcish), classic business (iron) and ivory (dragonbone - now Illegal).
Answer: There is one better horse which you get during the Dark Brotherhood quest line, but no he doesn't carry stuff for you.
If you want someone to carry stuff for you, I'd suggest getting a Companion/Follower and giving them your items. I wouldn't give him/her anything extremely valuable though, because I have had my companion lose items before. Also, companions do have a weight limit, although I'm not sure what it is.
Comment: my companion is also full, too bad I can't have more then one :(
Comment: wait limit for a companion is 300 pounds
Answer: If playing on the PC, installing the Horse Inventory mod will allow your horse to carry items.

No more Lydia have to carry your burdens, horse will do! This mod allows you to use inventory of your steed. All you need is to sneak and then activate the horse. So get all your loot and pack it on animal - "skyrim horses are not fast but sturdy". Make the hell out of their sturdyness!


Automatic UI configuration change handling in Activity and Fragment sometimes fails

Question: I have written android app now for a long time but now I'm facing a problem that I have never thought about. It is about the android lifecycle of Activitys and Fragments in in relation to configuration changes. For this I have create a small application with this necessary code:
public class MainActivity extends FragmentActivity {

    private final String TAG = "TestFragment";
    private TestFragment fragment;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        FragmentManager fm = getSupportFragmentManager();
        fragment = (TestFragment) fm.findFragmentByTag(TAG);

        if (fragment == null) {
            fragment = new TestFragment();
            fm.beginTransaction().add(R.id.fragment_container, fragment, TAG).commit();
        }
    }
}

And here is my code for the TestFragment. Note that I'm calling setRetainInstance(true); in the onCreate method so the fragment is not recrated after a configuration change.
public class TestFragment extends Fragment implements View.OnClickListener {

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setRetainInstance(true);
    }

    @Override
    public View onCreateView(LayoutInflater li, ViewGroup parent, Bundle bundle) {
        View rootView = li.inflate(R.layout.fragment_test, parent, false);
        Button button = (Button) rootView.findViewById(R.id.toggleButton);

        button.setOnClickListener(this);
        return rootView;
    }

    @Override
    public void onClick(View v) {
        Button button = (Button) v;
        String enable = getString(R.string.enable);

        if(button.getText().toString().equals(enable)) {
            button.setText(getString(R.string.disable));
        } else {
            button.setText(enable);
        }
    }
}

And here is the layout that my fragment is using:
<LinearLayout
    ...>

    <EditText
        android:id="@+id/editText"
        android:layout_width="match_parent"
        android:layout_height="wrap_content" />

    <Button
        android:id="@+id/toggleButton"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="@string/enable"/>

</LinearLayout>

My problem is that if I rotate the device the text of the Button change back to the default value. Of course the View of the Fragment is new created and inflated but the saved instance for the Views should be restored. I also have an EditText in my layout and there the text and other properties remains after the rotation. So why is the Button not restore from the Bundle by default? I have read on the developer site:

By default, the system uses the Bundle instance state to save information about each View object in your activity layout (such as the text value entered into an EditText object). So, if your activity instance is destroyed and recreated, the state of the layout is restored to its previous state with no code required by you.

I've also read a lot of answers the last days but I do not know how actual they are anymore. Please do not leave a comment or an answer with android:configChanges=... this is very bad practice. I hope someone can bring light into my lack of understanding.
Answer: You should save state of your fragment in the onSaveInstanceState(Bundle outState) and restore it in the onViewCreated(View view, Bundle savedState) method. This way you will end up with the UI just as it was before configuration change.
Comment: @Cilenco I think your assumption is wrong here - things like TextView and Buttons have `freezesText` false by default - probably for performance reasons - these components are typically read-only.  Things like EditText or ScrollViews do save and restore their state - because it is expected the user will manipulate them.
Comment: But as I said default views should save and restore their properties automaticly
Comment: When you give a `TextView` (Button is a subclass of it) a layoutId the state will be restored by default (look [here](http://stackoverflow.com/a/6097177/2047987) for the last two comments) In my case the Button has an Id so it should restore its state.
Answer: TextView subclasses don't save their text by default. You need to enable freezesText="true" in the layout, or setFreezesText(true) at runtime for it to save its state.
Comment: Also the superclass `TextView` save it when it has a layout id .
Answer: As per documentation, views should maintain their state without using setRetainInstance(true). Try to remove it from your onCreate, this should force the fragment to be recreated on screen rotation, hence all of it's views should be saved before rotation and restored after.
Answer: This stack overflow should answer your question:
setRetainInstance not retaining the instance
setRetainInstance does tell the fragment to save all of its data, and for ui elements where the user has manipulated the state (EditText, ScrollView, ListView, etc) the state gets restored.  That being said, normal read-only UI components get reinflated from scratch in onCreateView and have to be set again - my guess would be that their properties are not considered "data" that needs to be retained and restored - Google probably does this for performance reasons. So things like a normal Button, ImageView, or TextView need their contents set manually when they are reinflated if it differs from the initial state in the XML.  (TextView's android:freezesText basically puts the TextView in a mode that uses an implementation to save it's state and restore it).
PS: According to this stack overflow Save and restore a ButtonText when screen orientation is switched, you may be able to set android:freezesText on the button to have it keep the text you set - I haven't tried it, but it makes sense.
Answer: Edit after Op feedback
Although this fails to answer the question, after consultation with the OP, I've decided to leave it here as a reference point of information on the topic for people who land here. Hope you find it helpful.

Try putting your setRetainInstance in onCreateView. See here
@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    // setRetainInstance(true);
}

@Override
public View onCreateView(LayoutInflater li, ViewGroup parent, Bundle bundle) {
    setRetainInstance(true);
    View rootView = li.inflate(R.layout.fragment_test, parent, false);
    Button button = (Button) rootView.findViewById(R.id.toggleButton);

    button.setOnClickListener(this);
    return rootView;
}

Called when the fragment's activity has been created and this
  fragment's view hierarchy instantiated.  It can be used to do final
  initialization once these pieces are in place, such as retrieving
  views or   restoring state. It is also useful for fragments that use
  setRetainInstance(boolean) to retain their instance,   as this
  callback tells the fragment when it is fully associated with the new
  activity instance.  This is called after onCreateView(LayoutInflater,
  ViewGroup, Bundle) and before onViewStateRestored(Bundle).

developer.android.com/reference/android/app/Fragment.html#onActivityCreated

Control whether a fragment instance is retained across Activity
  re-creation (such as from a configuration change). This can only be
  used with fragments not in the back stack. If set, the fragment
  lifecycle will be slightly different when an activity is recreated:
onDestroy() will not be called (but onDetach() still will be, because
  the fragment is being detached from its current activity).
  onCreate(Bundle) will not be called since the fragment is not being
  re-created.
  onAttach(Activity) and onActivityCreated(Bundle) will
  still be called.

developer.android.com/reference/android/app/Fragment.html#setRetainInstance
And taken from here:

onCreate : It is called on initial creation of the fragment. You do
  your non graphical initializations here. It finishes even before the
  layout is inflated and the fragment is visible.
onCreateView : It is called to inflate the layout of the fragment i.e
  graphical initialization usually takes place here. It is always called
  sometimes after the onCreate method.
onActivityCreated : If your view is static, then moving any code to
  the onActivityCreated method is not necessary. But when you - for
  instance, fill some lists from the adapter, then you should do it in
  the onActivityCreated method as well as restoring the view state when
  setRetainInstance used to do so. Also accessing the view hierarchy of
  the parent activity must be done in the onActivityCreated, not sooner.

Let me know if this helps.
Comment: Thank you for this answer and all the quotes. These are really helpful. But at last it changes nothing if I put `setRetainInstance()` in `onCreateView`.
Comment: I'm also not sure about that. On the one hand there are really helpful information in it but on the other hand it could confuse some people. Maybe you can short it a bit and set a headtitle so it stays here as additional information


How do I export the Bazaar history of a subfolder

Question: I'm coding a framework along with a project which uses this framework. The project is a Bazaar repository, with the framework in a subfolder below the project.
I want to give the framework a Bazaar repository of its own. How do I do it?
Answer: You use the split command:
bzr split sub_folder

This creates an independant tree in the subfolder, which you can now export and work on separately.
Answer: Use fast-import plugin (http://bazaar-vcs.org/BzrFastImport):
1) Export all your history to the stream:
bzr fast-export BRANCH > full-history.fi

2) Filter the history to produce new stream:
bzr fast-import-filter -i subfolder full-history.fi > subfolder.fi

3) Recreate new branch with subfolder only:
bzr init-repo .
bzr fast-import subfolder.fi

Comment: If one wants to remove `subfolder` from the path in the new repository so it is not in the checked out tree, then add a trailing slash to the `-i subfolder` argument like `-i subfolder/`.  the fast-import-filter roots the filtered items at the deepest level folder specified with the -i argument.
Answer: As far as I know, there is not a way to do this easily with bazaar.   One possibility is to take the original project, branch it, and then remove everything unrelated to the framework.  You can then move the files in the subdir to the main dir.  It's quite a chore, but it is possible to preserve the history.
you will end up with something like:
branch project:
.. other files..
framework/a.file
framework/b.file
framework/c.file

branch framework:
a.file
b.file
c.file

Answer: As far as I know, "nested" branches are not support by Bazaar yet. Git supports "submodules", which behave similar to Subversion externals.
Answer: I have tried doing this with bzr split, however, this does not work how I expect.

The resulting branch still contains the history of all files from all original directories, and a full checkout retrieves all the files.  It appears the only thing that split does is convert the repository to a rich root repository so that this particular tree can be of a certain subdirectory only, but the repository still contains all other directories and other checkouts can still retrieve the whole tree.

I used the method in jamuraa's answer above, and this was much better for me as I didn't have to mess with converting to a new repository type.  It also meant that full checkouts/branching from that repository only recreated the files I wanted to.
However, it still had the downside that the repository stored the history of all those 'deleted' files, which meant that it took up more space than necessary (and could be a privacy issue if you don't want people to be able to see older revisions of those 'other' directories).
So, more advice on chopping a Bazaar branch down to only one of its subdirectories while permanently removing history of everything else would be appreciated.
Answer: Do a
bzr init .
bzr add .
bzr commit

in the framework directory.
Then you can branch and merge to just that directory.
The bazaar higher up will ignore that directory until you do a join.
Bazaar understands when you do things like
bzr branch . mycopy
bzr branch . myothercopy

The current directories .bzr won't track those subdirectories changes.
It saves you from trying to find a place to put a branch.


Extraction of citric acid from lemon

Question: Now i am extracting citric acid from lemon juice and i have a problem in adding sulphuric acid to calcium citrate because i don't know how to calculate the proper amount sulphuric acid to add to calcium citrate. Could anyone show me how to calculate the amount of sulphuric acid? And if anyone of you know the procedure for this extraction; please share me. Thank you!
Answer: When you add calcium hydroxide to the sodium citrate solution, you end up forming tricalcium dicitrate

In order to neutralize 1 mol of tricalcium dicitrate and form 2 mol of citric acid you need 3 mol of H2SO4 (each mol of tricalcium dicitrate have 6 mol of deprotonated oxygens and each mol of sulphuric acid provides 2 mol of H+).
So the balanced equation should be:
$$\ce{Ca3(C6H5O7)2 + 3H2SO4 <=> 2C7H8O7 + 3CaSO4-}$$
So, the proportion of tricalcium dicitrate to sulphuric acid is 1:3.
To fully neutralize the citrate to citric acid, for each mol of citrate you need 3 mol of sulphuric acid, or mathematically:
$$\ce{3n_{\ce{Ca3(C6H5O7)2}} = n_{\ce{H2SO4}}}$$
You know the molecular weight of both and the mass of tricalcium dicitrate that you have, now you can calculate how much sulphuric acid you need from the equation above.
There are several videos on youtube showing how to extract citric acid from fruits, I particularly like this one: https://www.youtube.com/watch?v=FMtayizdFiw

Extraction of citric acid from lemon


Why shouldn't I "bet the future of the company" on shell scripts?

Question: I was looking at http://tldp.org/LDP/abs/html/why-shell.html and was struck by:

When not to use shell scripts
...

Mission-critical applications upon which you are betting the future of the company

Why not?
Answer: Using shell scripts is fine when you're using their strengths.  My company has some class 5 soft switches and the call processing code and the provisioning interface is written in java.  Everything else is written in KSH - DB dumps for backups, pruning, log file rotation, and all the automated reporting.  I would argue that all those support functions, though not directly related to call-path, are mission critical.  Especially the DB interaction.  If something went wrong with the DB-interaction code and dumped the call routing tables it could put us out of business.
But nothing ever does go wrong, because shell scripts are the perfect language for stuff like this.  They're small, they're well understood, manipulating files is their strength, and they're stable.  It's not like KSH09 is going to be a complete rewrite because someone thinks it should compile to byte code, so it's a stable interface.  Frankly, the provisioning interface written in Java goes wonky fairly often and the shell scripts have never messed up that I can remember.
Answer: I kind of think the article points out a really good list of the reasons when not to use shell scripts - with the single mission critical bullet you point out being more of a conclusion based on all the other bullets.
With that said, I think the reason you do not want to build a mission critical application on a shell script is because even if none of the other bullet points apply today, any application that is going to be maintained over a period of time will evolve to the point of being bit by at least one of the those potential pitfalls at some point.....and there isn't anything you are really going to be able to do about it without it being a complete do over to come up with a fix....wishing you used something more industrial strength from the beginning.
Answer: Scripts are nothing more or less than computer programs.  Some would argue that scripts are less sophisticated.  These same folks will usually admit that you can write sophisticated code in scripting languages, but that these scripts are really not scripts any more, but full-fledged programs, by definition.
Whatever.
The correct answer, in my opinion, is "it depends".  Which, by the way, is the same answer to the converse question of whether you should place your trust in compiled executables for mission critical applications.
Good code is good, and bad code is bad - whether it is written as a Bash script, a Windows CMD file, in Python, Ruby, Perl, Basic, Forth, Ada, Pascal, Common Lisp, Cobol, or compiled C.
Which is not to say that choice of language doesn't matter.  There are very good reasons, sometimes, for choosing a particular language or for compiling vs. interpreting (performance, scalability, capability, security, etc).  But, all things being equal, I would trust a shell script written by a great programmer over an equivalent C++ program written by a doofus any day of the week.
Answer: Obviously, this is a bit of a straw man for me to knock down.  I really am interested in why people believe shell scripts should be avoided in "mission-critical applications", but I can't think of a compelling reason.
For instance, I've seen (and written) some ksh scripts that interact with an Oracle database using SQL*Plus.  Sadly, the system couldn't scale properly because the queries didn't use bind variables.  Strike one against shell scripts, right?  Wrong.  The issue wasn't with the shell scripts but with SQL*Plus.  in fact, the performance problem went away when I replaced SQL*Plus with a Perl script that connected to the database and used bind variables.
I can easily imagine putting shell scripts in spacecraft flight software would be a bad idea.  But Java or C++ may be an equally poor choices.  The best choice would be whatever language (assembly?) is usually used for that purpose.
The fact is, if you use any flavor of Unix, you are using shell scripts in mission-critical situations assuming you think booting up is mission critical.  When a script needs to do something that shell isn't particularly good at, you put that portion into a sub-program.  You don't throw out the script wholesale.
Answer: It is probably shell scripts that help take a company into the future. I know just from a programming standpoint that I would waste a lot of time doing repetitive tasks that I have delegated to shell scripts. For example, I know most of the subversion commands for the command line but if I can lump all those commands into one script I can fire at will I save time and mental energy.
Like a few other people have said language is a factor. For my short don't-want-to-remember steps and glue programs I completely trust my shell scripts and rely upon them. That doesn't mean I'm going to build a website that runs bash on the backend but I will surely use bash/ksh/python/whatever to help me generate the skeleton project and manage my packaging and deployment.
Answer: When I read thise quote I focus on the "applications" part rather than the "mission critical" part.
I read it as saying bash isn't for writing applications it's for, well, scripting.  So sure, your application might have some housekeeping scripts but don't go writing critical-business-logic.sh because another language is probably better for stuff like that.
Answer: I would wager the author is showing they are uncomfortable with certain aspects of qualtiy wrt shell scripting. Who unit tests BASH scripts for example.
Also scripts are rather heavily coupled with the underlying operating system, which could be something of a negative thing.
Comment: Most languages are tied to the OS in most regards.
Answer: No matter we all need a flexible tool to interact with os. It is human readable interaction with an os that we use; it's like using a screwdriver with the screws. The command line will always be a tool we need either admin, programmer, or network. Look at the window they even expanded on their Powershell.
Answer: Scripts are inappropriate for implementing certain mission-critical functions, since they must have both +r and +x permissions to function. Executables need only have +x.
The fact that a script has +r means users might be able to make a copy of the script, edit/subvert it, and execute their edited Cuckoo's-Egg version.
Comment: So what if they can execute a copied shell script?  If the user can create a file and execute it, then it doesn't matter if the user copied the file or wrote it from scratch: the executed file has the same capabilities either way.


Can we use magnetic energy to convert electrical energy by replacing mechanical work by a fan for concern watch the video

Question: Can we use a computer fan with magnets attached to its blades, and another magnet, to generate electricity, as shown in this video?
https://www.youtube.com/watch?v=jiAhiu6UqXQ
Comment: Please add additional information to the question outside of the video.  Currently we cannot tell what you are asking about without opening another site, which many of us will not do.
Comment: Also, you should mention what you have already done to answer your question.
Comment: actually i am not able to express my views the video is simple you can understand easily by just watching it
Comment: @RahulMeena Your question should provide a reasonable stand-alone reference to what you are asking.  Because you are not explaining the question in your post, anyone else who tries to read this will have to also watch the video to understand the question.  That is not what we want here.  We want to be a question and answer resource site.  It doesn't matter how "simple" the video is, it matters that the information _is not on this site_.  Personally, I find Facebook to be extremely annoying when you don't have an account, so I avoid those links more than most links.
Answer: Now that the link is to a YouTube video, I will take a brief crack at it.
The video is an illusion. There is no "free lunch" when it comes to energy generation - that is well established. If your magnet pulls the small magnets on the fan blades towards it, it will do so in both directions - there would be no net rotation. So let's hypothesize what the creator of the video might have done to create this trick:
I believe that the fan was rigged with a simple battery and a Reed relay. A Reed relay is a magnetic switch that closes when you move a strong magnet close to it. This battery could then power the fan, and the power could be put on the wires so it can light the bulb.


Hissing noise coming from the lights in my bedroom

Question: I have a ballast in my bedroom with three 60 watt led lights in it. The switch they are connected to is a brand new Lutron dimmer specifically made to work with led lights. The hissing is constant even when the lights are not dimmed, but it seems to get slightly louder when dimmed. I switched out the old dimmer to the Lutron in hopes it would stop. Their use to be a ceiling fan connected here. So I've come to the conclusion that there is just way to much power running to the lights hence the sound. Does this sound accurate? How would i reduce the power running to it to test my hypothesis?
Answer: You have two options, get rid of the dimmer or try different LED bulbs.  All LED bulbs hiss when on a dimmer, some bulbs hiss much louder that others.  A led compatible dimmer will help reduce the amount of hiss but it will never get rid of it.
Here is an article that compares a couple of different led bulbs and dimmer switches.  It looks at the quality of light and the amount of buzz each bulb makes with different types of dimmers.  http://www.cnet.com/news/which-led-light-bulbs-are-best-for-dimming/
Comment: It depends on the dimmer if it will hiss when it is turned on full.  Some do, some don't (really, some dimmers cheat and never go full on but just slightly dims when full on).  As for the exact cause of the buzz from the lights, I can't answer that but I do know it is caused by the electronics used to convert the chopped AC wave form to a level DC current.  Dimmers work by quickly (120 times a second) turning the power on and off, the lower settings keep the light off longer before turning it back on.
Comment: I see. So even if they're are not actually being dimmed they will still hiss? Why exactly do they hiss?
Answer: Some combination of the switch, ballast and lights you have may not be 100% compatible.
Take a look at Lutron's LED Selection Tool. You can pick the dimmer and the lights you have and then you can pull up a PDF report for the testing they have done.


Is "ceteris paribus" used in formal American English?

Question: A question for American people (English people are welcomed as well but I guess their use of English is more formal): do you use ceteris paribus in some formal text? If not, what would be the best alternative?
Comment: This question appears to be off-topic because it is not about English.
Comment: I can say that it isn't among the Latin phrases I commonly encounter in math or physics, but it could easily be used more in other circles. For example lawyers and biologists and doctors all have a lot of Latin words and phrases inherited into their professions. As for what to use instead, try simply its meaning: *all else constant*. Also, the context in which you would potentially use it would be helpful.
Comment: @Walter: Not being much of a scientist, I could be mistaken here. But isn't it the case that the basic principle of "all else being equal" is central to theoretical physics today? ["Fundamental symmetry principles dictate the basic laws of physics, control the stucture of matter, and define the fundamental forces in nature." says Leon M. Lederman, Nobel Laureate in physics.](http://www.physics.ucla.edu/~chester/PhysAsSymtry/) Doesn't "symmetry" there imply ***one*** "plane" of variability, with everything else remaining constant?
Comment: @snailboat: Thanks, I'll keep an eye out. My favourite "all else being equal" is Feynman, at 54m 33s in [Messenger Lecture 4 - Symmetry in Physical Law](http://www.youtube.com/watch?v=8K09ylkIVNQ). He shows how if we communicate with an advanced alien, we might think we had a lot in common, since all our physical laws would seem to be the same. Except in principle the alien could be made of antimatter. If that particular ET ever came to visit Earth, and copied our "greeting handshake" by extending his ***left*** hand, we'd soon find out we weren't ***quite*** the same!
Comment: @FumbleFingers Yes it is a definitely a central principle, but even so I've not encountered the Latin phrase often (just once as an undergrad, and only a couple times since then), which leads me to believe that it isn't commonly in the active vocabulary in these fields.
Comment: @Walter: Per comments to StoneyB's answer, it seems the term was sometimes used by C18/C19 "physicists", but [to the extent that it's used at all today {not much!}](http://books.google.com/ngrams/graph?content=ceteris+paribus%2Call+else+being+equal&year_start=1700&year_end=2000&corpus=15&smoothing=3&share=), it seems to be more evenly spread across a variety of academic contexts. IMHO, it's effectively *excessively* formal (or perhaps more accurately, *pseudo-formal*).
Answer: Ceteris paribus today is scholarly jargon. In my academic LitCrit days I used it freely.
Today, when I write primarily for business audiences or corporate websites, I do not. Instead I say "all else being equal".
I might use it if I were addressing an audience of lawyers, whose training obliges them to be familiar with many older usages; but I would advise them not to use it in contracts.
I would not follow a different practice if I were writing for British audiences.
Comment: @FumbleFingers I'm pretty sure what your NGram shows is the post-WWII GI-Bill-fueled surge in academic publishing. The peak is exactly when we 1st-generation Baby Boomers finished our doctorates and came out into a saturated market!
Comment: I didn't know the term until now - but [this NGram](http://books.google.com/ngrams/graph?content=ceteris+paribus&year_start=1900&year_end=2000&corpus=15&smoothing=3&share=) suggests it's become much more popular since the 60s/70s. And comparing US/UK corpora on that link, it seems Brits use it more than twice as often as Americans. Whatever - my impression is it's not so much an "older usage" that might be necessary for lawyers & such. It looks much more like a "neo-intellectual" usage to me. I think I'll stick with "all else being equal", thanks!
Comment: @ StoneyB: I think that's what I meant. It's not really an old "legal/lawyerly" term - rather something that's been embraced by modern academia. Interestingly, [this mid-1700s reference](https://www.google.co.uk/search?q=%22paribus+a+Latin+term+often+used+by+mathematical+and+physical%22&btnG=Search+Books&tbm=bks&tbo=1) says that (then, at least) it was *often used by mathematical and physical writers*. I've no idea if it's more common in the arts than sciences today (if it cropped up in my LitCrit studies in the early 1970s, I obviously didn't notice it! :)
Comment: *Ceteris paribus* is often used in academic economics.  As you mention, it is usually better to translate it to "all else being equal" or "other things being equal" or "holding everything else the same".


Short story: Ironic ending is a note 'Send more chickens like that'

Question:
A short story, mean farmer who finds a hole/cave that has aliens/monsters who give him gold in exchange for food
Provides chickens
Ends up disappearing
Wife goes to cave/hole and receives a note asking for the more chicken like the last one - her husband
Comment: Thanks for the acceptance! Your question will be closed as a duplicate. It's not a censure on you, but just a matter of that it's how we organize our data.
Answer: This is a dupe of Old story about mysterious creatures at the bottom of a well that have a taste for "live turkey" (i.e. human flesh)?, which has the answer of "Hey You, Down There" by Harold Rolseth.

A farmer digs a new well and discovers some sort of civilization of 'monsters'.
The farmer and his wife/daughter feed the 'monsters' by lowering down a turkey in a bucket.
The 'monsters' communicate back with the farmer using notes.
The farmer descends into the well, curious about the 'monsters'.
The 'monsters' send a note back up the well, thanking the wife for the delicious meal.

Short story: Ironic ending is a note ‘Send more chickens like that’


Moving personal belongings to Italy

Question: I lived in the USA for over 30 years. I am a resident of Italy for over 10 years.
I just came back to the States for sending my belongings kept in storage in Chicago.
I contacted many international shipping companies requesting a 20' container to transport my items from Chicago to my house in Italy.
They all seem to have a problem with me, being a resident of Italy. They all think that it's a relocation and I need to fill out a Relocation Form supplied by the Italian Consulate.
I am already a resident!!!!! They don'y seem to understand.
Where can I find an International shipping company that would provide me with a container, fill it up and ship it door-to-door to Italy without problems?
Comment: You say you are a "resident" of Italy. Are you an Italian citizen?
Comment: In my (limited) experience, relocations are typically exempted from import duties.  It is probably in your financial interest not to go out of your way to avoid characterizing the shipment as a relocation.
Answer: You are relocating your personal belongings.  The belongings are yours now and will still be yours after shipping.  Therefore, you should use a relocation form.
Someone I know used a regular shipping company to ship her stuff from the US to the UK, rather than a moving company with a relocation company.  Upon arrival, she had to pay significant import duties.  I relocated my stuff with a relocation company from Canada to the UK (when it was still in the EU) and paid no import duties.  But — there was no consulate involved; the shipping form was provided by the moving company.
The fact that your stuff moves 10 years later than you do doesn't matter.

Moving personal belongings to Italy


Alternative to povray?

Question: I need a raytracer, but I have some trouble with povray. is there a free, cross platform alternative which accepts a simple subset of povray syntax ? need to run it from command line. no graphics.
Answer: Would Yafaray meets your needs? I use it with Blender and I find it brilliant!
Answer: Good luck finding anything substantial that reads POV-Ray Scene Description Language. There's nothing but POV-Ray and maybe some handy little utilities and maybe some translators out there that can do that, as far as I've seen. (But I'm often missing out on something...)
But, loosening up on that requirement, there's Art of Illusion, LuxRender, Pixie, Kerkythea, Radiance (primarily a global illumination tool, but does ray tracing too), and more... try browsing the Wikipedia article on ray-tracing.
I didn't check if all these can be run from a command line or from within a program, but I think so.
While POV-Ray's SDL hasn't caught on outside its original turf, Renderman is much more widely accepted. Since that may be outside your interest, I'll say no more.
Another thing - pure raytracing seems to have faded away, mostly. Many renderers combine different algorithms for their total effect. POV-Ray, even, has photon mapping where light is thrown forward from source to surface, as in physical reality. Just how to handle interacting lighting between surfaces (global illumination), and rays passing through transparent/translucent materials that don't originate from the camera, is an active area of research, with the current state of the art being multiple choices depending on the type of scene to render. Thanks to super-duper hardware, compilers and operating systems today, creators of 3D scenes have choices among algorithms, including some previously thought hopelessly inefficient. We live in marvelous times!
So, instead of asking for just an alternative to POV-Ray, explain what kinds of scenes you want to make, with what final visual effects. Would you like HDRI output? Programming in Python for precise complex geometry? There's almost certainly a tool for the job.
Comment: I cannot answer for "Stefano Borini" but, I personally consider POV-ray invaluable just because of it scene-description-language which allows to create sophisticated scenes by scripting rather than using GUI. It is very valuable for e.g. sciencetific visualization, especialy if one does not have much experience with CAD, but large experience with programming.  I would be happy to get better answer here https://superuser.com/questions/604716/modern-alternative-to-povray-scene-description-languade
Comment: I still use povray because of its scripting interface and I feel uncomfortable having to rely solely on a GUI. But it is sadly very slow and I am always looking for alternatives.
Answer: MegaPOV is a version of POV-Ray with unofficial patches and improvements. It is free and runs under Snow Leopard (just tested under OS X 10.6.7).
Answer: povray will run from the command line with no graphics, and obviously will accept a subset of pvoray syntax. What problems are you having with it? It would seem to be more sensible to fix those problems than trying to avoid them.
Comment: it does not compile on snow leopard, and the binary is for ppc. rosetta crashes when I run it.
Answer: Luxrender is very nice. Syntax is different from Povray but similar. GUI & command line versions.
Answer: There are a few java ray tracers out there which are open source.
this is one of them.
You can probably run them with inputs from the command line.  I wrote a very simple one in java, and I have a friend who has a better one which can be easily modified to do what you need.

Alternative to povray?


What are the possible penalties in portuguese law for kidnapping or false imprisonment?

Question: Presumably there are custodial sentences applicable, what is the minimum and maximum length?
Comment: This question provides all details necessary to answer it, place, charge, and punishment length.
Comment: @User37849012643, did somebody suggest otherwise?
Comment: Ah, I see. Yes, that much was clear, and thank you. I was just confused as to the context, and was wondering if perhaps there might've been a comment before yours that was now deleted.
Comment: But now I understand. :)
Answer: The potential sentences are set forth in the Penal Code of Portugal at Articles 153 to 162. The statute for each offense sets forth a maximum penalty. The most serious offense of this type is punishable by up to 16 years in prison.
There is not always a minimum penalty and sentencing alternatives earlier in the Penal Code undermine the minimum sentences set forth in the selected cases where they are present so that they don't really mean what they appear to mean. So, it is not informative to try to list minimum penalties.


What is the simplest way to interact between a SAP OMS and Websphere Commerce?

Question: What is the simplest way to interact between a SAP OMS and Websphere Commerce?
Would it be using a Websphere Adaptor for SAP or webmethods or something else?
Does something else need to be considered while opting for one of these?
The final system needs to be synchronous between SAP and the WCS front end. No ques..no delays....
Answer: I recommend a combination of the SAP Business Connector (http://service.sap.com/sbc-download), which provides an easy interface for receiving/sending RFC calls from/to the SAP side, and the IBM WebSphere Java library, which allows easy interaction with WebSphere. ("webshphere.jar", can probably be found somewhere on http://www.ibm.com/developerworks/websphere.)
In the Business Connector you can then write a "Java Service", which acts as a bridge between the RFC data from SAP and the WebSphere data. Should be only a couple of days development effort.
Answer: Hmm... there is a white paper from IBM's website that shows the best way for you to do this.   Depending on your IT strategy choose your integration pattern and integration technology.


Slider/slideshow behavior on inactive page

Question: What's the appropriate behavior for a slider/slideshow on a page when it's not visible (e.g. user switched the tab or just scrolled down, so the slider is outside of visible part of the screen)?
Answer: I thought of it recently. My point is to pause slideshow because of the reasons:

transition effects and picture changing are resource consuming operations. It's better to switch the resources to current operations than waste it to the slideshow, which is out of a user's focus
returning to slideshow which is displayed the old slide, which was displayed before slideshow leaving, supports user flow. So user is able to recall some information and continue to watch slideshow.

An issue with marketing sliders which impacts business is possible product loss. The reason is a user could keep in mind some product he has noticed on a slide. After he returns to the slider again to get more details, he sees other product, which is not only confusing to him, but also could lead to business losses.
So there could be some solutions:

auto-pausing when the slider is out of view and auto-resuming when it turns in view again
designing better slider, which is more informative and more interactive (i.e. user controlled) and rely on recognition over recall, compare two:
Comment: Stopping slideshow seem to be the best option. What do you think about marketing embedded sliders?
Comment: @DeTeam I've updated the answer, please, take a look.
Answer: Switch tab or scroll down are already different. But if you can remove "useless" treatments it should be good.

"Scroll down" you stay on the same page and JavaScript go at fullspeed.
"Switch tabs" browser use to throttle speed (https://stackoverflow.com/questions/6585112/javascript-performance-when-running-in-an-unfocused-tab)
Comment: If your not talking about resources management, there should be few UX problem for something that is not visible. If you have 5 items rolling when off page, it is not very important as user can easily go back to interesting slide. if you have 100 pausing is certainly a better approach.
Comment: The question is more about UX then browser's resources management.I know those actions are different (full or partial context switching) but what's the best option in that case from point of UX?
Comment: Make sense, thanks. So it's more about element semantic and interaction design (long-term or short-term interaction, complexity, etc).


Citing Mathematical Proofs given on Math Stack Exchange

Question: Good morning.  I recently posted a question on Math Stack Exchange here and got a fantastic solution.  The problem in question is one that I've had for some time, and both myself and research professor have been searching for proof of the claim both through papers and using mathematical techniques.
It would appear that a particular solution to the problem has been found, though I must go through the proof with my professor to verify its truth.  If it is true, what is the protocol for citing the proof and giving the author credit?  Do stack exchange contributors post solutions knowing that their work may not be credited?  I would never want to plagarize, but the information is useful for the greater problems that we have been trying to solve.
Comment: Another duplicate: [How to cite an answer in StackExchange?](https://academia.stackexchange.com/q/84965/546)
Answer: There are actually two questions on MathOverflow that ask how to cite answers found on MathOverflow. I would recommend following their advice.
One of them is a fairly old question, whose answer is somewhat outdated. Summarizing:

Even though you may not be legally obligated to show where you got your answer (for example, when MO points you to a theorem already in the literature), it is a good idea — it never hurts to be generous and honest. (And if you're copying part of an answer, not citing it would be plagiarism.)
There is a little button for each answer that says "cite" and will give you a citation. You might have to reformat this to make it fit in your journal's bibliography style.
Comment: The authorities at MathOverflow seem to think this is sufficient. You might want to replace the author's MO tag with his full name in your citation, if they give it in their profile.
Comment: Whether it's sufficient depends on the policies of publication venue.  And to follow strict citation patterns, you should _add_ the authors real name to the MO tag (if they are different), not _replace_, because the real name doesn't show up anywhere on MO.
Comment: So it would seem that using "cite" to obtain code used for the bib would be sufficient?  That seems to be what I'm getting out of this question as I observe the answers I'm getting.  Thank you for your help.
Comment: I reached out to the author to let him/her know and hopefully from there i can get info necessary.  Thank you for your help.
Answer: Perhaps the person who posted it actually found it elsewhere and can provide a reference to you. Alternately, if you are willing to be publicly known here, you can find a way to exchange emails and hence give proper credit to the individual(s).
In the past, I've exchanged emails with members on this site using a mod as a go-between, but that implies that you can reach the mod via email and that the mod actually knows the other person's email. I note that the mods themselves aren't able to get people's email addresses from the site and it requires someone with higher authority. But if it is possible, the correct way is to ask a mod or administrator to give your email address to the other person, rather than to ask for theirs.
However, the rules are the same. If you use someone else's work, you need to cite them and an anonymous citation may not be enough unless they tell you on the site that you may do that. In that case, keep a record (pdf) of the exchange. The chatroom rather than the comment stream may be a better place to explore such things. (https://chat.stackexchange.com/rooms/2496/the-ivory-tower, or something similar at the math site: https://chat.stackexchange.com/?tab=site&host=math.stackexchange.com.)
But see the answers for the questions that this duplicates, also. I would, myself, worry about a citation that used an alias as author, rather than a true-name.
Comment: _I would, myself, worry about a citation that used an alias as author, rather than a true-name._ — **Why?**  Would you hesitate to cite a paper if you thought it might be published under a pseudonym?
Comment: @JeffE, not if the person published frequently under that pseudonym, but for a one-off, yes, I'd worry about how it would be viewed. Among other things, you don't know very well if the citation you are using was, itself, plagiarized. I'll note that Bourbaki was a case in point. It was a well established pseudonym for a group and therefore could be well trusted even when the members were anonymous. They established a _body_ of work that established the credential.
Comment: No, I don't know if any given paper is plagiarized, but that's also true for papers published under the authors' True Names (or more accurately, _presumably_ published under the authors' True Names, since we can't actually tell).  But more importantly, at least in my corner of the world, it's the _content_ of papers that determines whether they are trustworthy, not their authorship.


Why AWS RDS doesn't update minor version?

Question: I have a small RDS instance on AWS, and on the maintenance details I have set "Auto minor version upgrade" to Yes. But I still have the MySQL engine version 5.5.27, and AWS has  the version 5.5.33 available. Am I missing something here?
Comment: Have you had auto minor upgrade turned on all along, or did you enable it only recently?
Comment: @Michael-sqlbot it's been turned on all along, more than a year ago.
Comment: I'm having the same issue with two RDS instances that are currently on 5.7.19. AWS is telling me I should update to 5.7.23 however I've had the auto upgrade setting enabled since these instances were first deployed!
Answer: I have a couple of out of sight, out of mind 5.5 instances in RDS, and it turns out they are running 5.5.27 as well.
Between 5.5.27 and the highest currently-available version, 5.5.33, RDS for MySQL 5.5 only (apparently) supported one other minor release, which was 5.5.31.
RDS originally posted a schedule of when minor version upgrades to 5.5.33 would be done, and they subsequently announced they had suspended those automatic upgrades:

On 30th October 2013, based on signals we received from our monitoring systems, we paused the upgrade process in all the Regions. We will review the system and post a new schedule for the upgrades in the future.

This should explain why your system wasn't upgraded to 5.5.33, but it doesn't explain why you weren't upgraded to 5.5.31... or why I wasn't.
Then I realized that I don't actually remember an announcement about automatic upgrades to 5.5.31.
I searched for it, and didn't find it.
I did, however find the announcement of scheduled automatic upgrades to 5.5.27.
This leads me to speculate that RDS never actually did a mass upgrade to 5.5.31 like they did to 5.5.27 or will presumably still be doing to 5.5.33... in which case, the state of your instances, and my instances, makes sense.  I've searched pretty diligently and come up with no other explanations.  The AWS forum is also very low on search results when it comes to any questions referencing 5.5.31 at all.  I have also not been able to encounter any other "unsuspected settings" that would have stopped automatic minor version upgrades.
So I don't think you're missing something, I suspect that you will be automatically upgraded to 5.5.33 when they resume the automatic upgrades.  My plan is to wait, and if the upgrades roll around and I don't get mine, post to the forums.
The only other options, it seems like, would be to post to the forums now, to see if you can get an AWS person's attention or feedback from any users with suggestions... or to manually select the new minor version and apply it to your instance, though that won't serve to answer the question of whether minor version upgrades are broken, or whether what we're currently seeing is pretty much what we should be seeing, on systems running 5.5.27.
Answer: This question is quite old now, this answer explains a situation where this behaviour occurs in 2019 with the postgres 9.6.* engine version.
First lets look at the last few available minor engine versions:
$ aws rds describe-db-engine-versions --engine postgres --engine-version 9.6.8 | \
jq '.DBEngineVersions[0].ValidUpgradeTarget[] | select(.IsMajorVersionUpgrade==false)'
{
  "Engine": "postgres",
  "EngineVersion": "9.6.9",
  "AutoUpgrade": false,
  "IsMajorVersionUpgrade": false
}
{
  "Engine": "postgres",
  "EngineVersion": "9.6.10",
  "Description": "PostgreSQL 9.6.10-R1",
  "AutoUpgrade": false,
  "IsMajorVersionUpgrade": false
}
{
  "Engine": "postgres",
  "EngineVersion": "9.6.11",
  "Description": "PostgreSQL 9.6.11-R1",
  "AutoUpgrade": true,
  "IsMajorVersionUpgrade": false
}
{
  "Engine": "postgres",
  "EngineVersion": "9.6.12",
  "Description": "PostgreSQL 9.6.12-R1",
  "AutoUpgrade": false,
  "IsMajorVersionUpgrade": false
}
{
  "Engine": "postgres",
  "EngineVersion": "9.6.14",
  "Description": "PostgreSQL 9.6.14-R1",
  "AutoUpgrade": false,
  "IsMajorVersionUpgrade": false
}
{
  "Engine": "postgres",
  "EngineVersion": "9.6.15",
  "Description": "PostgreSQL 9.6.15-R1",
  "AutoUpgrade": false,
  "IsMajorVersionUpgrade": false
}

Notice that only 9.6.11 has AutoUpgrade set to true. This means that if you are running a version prior to 9.6.11 and you have AutoMinorVersionUpgrade set to true then you will be automatically upgraded to 9.6.11 during your next maintenance window.
If you are running 9.6.11 you will not be automatically upgraded to subsequent versions. This is despite the RDS console recommending the following:

Your DB instance is running postgres version 9.6.11. We recommend that you upgrade to version 9.6.15 because it contains the latest security fixes and other improvements.

Useful commands:
$ aws rds describe-db-instances | jq -r '.DBInstances[0].EngineVersion'
$ aws rds describe-db-instances | jq -r '.DBInstances[0].AutoMinorVersionUpgrade'
$ aws rds describe-db-instances | jq -r '.DBInstances[0].PreferredMaintenanceWindow'
$ aws rds describe-pending-maintenance-actions


Larger arrows in xy

Question: I'm trying to make a poster, and have managed to enlarge math symbols in XY for my diagrams, but the arrows are too thin and unless you're right up against the poster, the arrow heads are almost invisible.  Is there a good way to enlarge the arrows in xy?
Comment: Can you give a MWE?
Comment: I have a similar problem and am not aware of a good solution yet other than this which I can't get to work: http://www.tug.org/pipermail/xy-pic/2006-May/000368.html
Answer: If it's not too late, I would by all means design the poster at a much smaller size and then enlarge at printing. This is much more "natural" for the viewing situation at hand than enlarging font sizes etc.

Larger arrows in xy


Do Unix systems and other similar systems use the GPU for the startup splash/loading screen (when there is one)?

Question: I was wondering if Unix systems use the GPU for the startup splash/loading screen because I've been having some trouble with an overheating Mac with graphics issues. Unix-type systems (such as MacOS 10.6, 10.10 and different versions of Ubuntu) show the splash screen, but never actually boot into the GUI (typically just a plain black/blue/white screen after the startup splash). Windows, however, starts up (I assume this is what's happening as I can hear hard drive activity) and only shows a black screen (no splash or loading screen). This just made me curious as I have a cursed 2008 ATI iMac. I plan later to try reapplying thermal paste to see if that does any good, and then try a reflow (I know this'll only be a very temporary solution but I just want to see if anything will work), but if all else fails, it'll probably go into the bin.
Comment: With Linux, try some of the advanced settings. In Ubuntu, in the initial boot selection, it's F6. Try `nomodeset` `noapic` and `acip=off`. One, or a combination, of them may let you get past the startup screen.
Answer: The answer to your literal question is yes: all systems use the GPU to display startup messages and splash screens. That's because going through the GPU is the only way to display something on the monitor.
However, the answer to the question you meant to ask is no: the ways the GPU is used during startup and after the system has fully booted are different. During startup, the operating system uses the GPU in text mode or as a simple framebuffer. These involve very little work from the GPU, so they are unlikely to trigger GPU bugs or to make it overheat. Text mode is limited in that it can only show text in a single monospace font. Framebuffer mode can show arbitrary images, but it's slow. Both modes may use a resolution that's less than the maximum that the GPU and monitor can do.
Once the system has fully booted, it likely starts using the GPU in a different ways, using its computational capabilities. This involves a complex driver in the operating system, and may involve some nontrivial computation on the GPU. Under Linux, this mode is part of the X window system (or a replacement for it such as Wayland.
You may be able to get a GUI on Linux with the X.org fbdev driver (which uses the GPU as a simple framebuffer) or with the X.org VESA driver (which is a very old standard that does little more than a framebuffer and has limited resolution). It won't be fast, and it might not be pretty, but it's better than nothing.
You may need to work in text mode first to prevent X from starting in a mode that doesn't work. The way to do this depends on the distribution. The Arch Wiki may be useful even if you don't use Arch. Once you've logged in as root, create or edit /etc/X11/xorg.conf to choose the video driver. For example, for fbdev, you need something like this (untested):
Section "Device"
    Identifier "fbdev"
    Driver "fbdev"
    Option "fbdev" "/dev/fb0"
EndSection

You also need to install the appropriate driver (if it isn't already present), which again is distribution-dependent. For example, on Debian/Ubuntu, that's
apt-get install xserver-xorg-video-fbdev

Comment: Hi @Gilles 'SO- stop being evil', I tried your solution, however after leaving the mac for a few days, it appears that the graphics glitches have gotten worse :/. After attempting to boot into text mode (on lubuntu), I still had more graphical glitches. I believe the graphics chip on the imac is well and truly gone by now. Otherwise, thanks for your help and answering my question. As this did answer my initial question, I'll leave it as the answer for others who have any similar problems/are just curious. :)


Rotational spring

Question: I am looking to model a rotational spring, e.g. a balance wheel of a mechanical clock. The [rigid body constraint/generic spring] only allow for translational springs.
How could I do this?
Comment: are you looking to simulate, or just model that spring?
Comment: I am looking to simulate this. Just any object would behave like a rotational oscillator.  To model the spiral spring geometry is the next step, but this should be easy to do.
Answer: This can be done using...
Shape Keys + Curve Modifier + Skin Modifier
Enable the Add Curves: Extra Objects add-on.

Add > Curve > Spiral
Adjust the spiral as you like. I recommend a high step count for a nice looking SubSurf.

Convert to Mesh (AltC)
Add > Curve > Circle
To your spiral object, add the following modifiers:
Curve - Set the object to be your BezierCircle
Skin - Smooth Shading
SubSurf - 3 Subdivision levels

Create two Shape Keys - a Basis one where the spring is fully squished, and a second one where the spring is scaled up on Z, fully sprung... [ahem].

You can then animate the Shape Key slider to make the spring extend.
Comment: Nice work, but a rotational spring doesn't work like that.  See https://en.wikipedia.org/wiki/Balance_wheel#/media/File:Pocket_Watch_Balance_Wheel.jpg
Comment: @Xtremity Ha! ...crap. Well thanks for pointing it out. I'll give this some thought and post again if I solve it. Not that OP even seems to be following anymore, but in case others come searching. This is why reference photos are a good thing.
Comment: Oh, I didnt know how I can add a reference foto. I thought the term 'rotational spring' and balance wheel for a mechanical clock is reference enough. The problems still stands though.
Answer: I did this to model a roll of thick plastic - My way was to create a spiral in adobe illustrator , add a stroke to it, expand the stroke so it becomes one solid spiral shape and then exported it as an SVG file.
I then imported the SVG into blender and extruded it along a single axis.
Comment: This is not a good solution either since a spiral spring changes diameter while its rotated.

Rotational spring