How to batch resize canvas of multiple files placing the original pictures in the centers?

Question: I have got some hundreds of pictures of different shapes. For example one is 600x600, another is 307x600, the third is 600x400, the fourth is 500x300. What I need to turn them all into 600x600 (or 610x610 perhaps to add some reasonable padding) files placing the original pictures into centers of the new pictures (rather than scaling them or placing them near the edges). The only application I know capable of this is Paint.Net but it features (AFAIK) no automation facilities so processing hundreds images is nasty. Any way to do this in batch? Windows and Linux solutions welcome. An opportunity to specify the colour (including an option of PNG empty colour) to fill the canvas space added is highly desirable.
Comment: You have misunderstood 16 bits per channel is 48 or 64 bpp 8 bits per channel is 32 or 24 bpp. Diferent metric. Understandable confusion.
Comment: Read the paragraph text above and they CREARLY state  **8 bits-per-pixel component** == per channel. Full text: "*Versions with Q8 in the name are 8 **bits-per-pixel component** (e.g. 8-bit red, 8-bit green, etc.), whereas, Q16 in the filename are 16 bits-per-pixel component.*" italics and bold mine. We changed language once it became apparent images can have many channels.
Comment: I updated my answer to add color http://graphicdesign.stackexchange.com/a/37314/4338
Comment: Use imagemagick.
Comment: @joojaa I have taken a look at the ImageMagick site download section and it says there are 16 and 8 bits-per-pixel versions. Although I have made a simplistic picture that can fit into these constraints for an example, I actually need to process 32 (or 24, I am not sure) BPP photographic quality pictures actually.
Comment: @joojaa I have checked, it actually says 16 bits per pixel, not per channel: http://imgur.com/yLDaAvG
Answer: If you have ImageMagick installed, you can use the mogrify command to batch-process an entire folder.  It will allow you to resize the canvas of each image, centering the original image within this new dimension, and filling the background with a color (or transparency).
For handling a directory of JPGs, and using white as the background:
mogrify -extent 640x640 -gravity Center -fill white *.jpg

For PNGs, and having a transparent background:
mogrify -extent 300x300 -gravity Center -background none *.png

Comment: BTW although ImageMagick distributions are labelled as 8/16 bits per pixel they (I have tried the 16 bits per pixel version) seem to work with TrueColor pictures just fine.
Answer: You can do this with actions & the batch automation feature within Photoshop. To accomplish a colored or transparent background with new size dimensions, you'd create an action set (folder icon) and create an action within that set for each color you're looking to batch.
Step 1: Create the action
Record yourself resizing the canvas for future automation

Navigate to the actions panel or Alt+F9
Create a new action by clicking the layer icon on the actions panel
Do the actions you want automated
Click the stop icon on the actions panel

While recording your specific action: (with image open)

Go to Image > Canvas Size and change to 610x610
Add a square shape for background
Change color of shape to desired color / make no background for transparent
Move beneath your image

Repeat this, creating a new color action within your action set as desired

Step 2: Setting up a batch automation
Tell Photoshop which folder of images to apply your re-sizing action to

Go to File > Automate > Batch
'Play' section, choose your newly created action
'Source' section, choose a folder of images to apply this action to
'Destination' section, choose a folder where the newly re-sized images should output.
Click Ok and your automation will begin immediately.

Side Notes:

Changing the canvas size will center image within the new dimensions.
Custom actions record the things you do in Photoshop, in this case re-sizing.
'Action Sets' in the batch dialog are folders or groups of actions in the actions panel.
Answer: A slightly modified answer, to make it a complete answer.

Install ImageMagick via terminal.

Resize all the images in the folder you want to change, to a sample size, e.g.:
magick mogrify -resize 256x256 *

then run
mogrify -extent 300x300 -gravity Center -fill white *


Failed the private written test and I need an authorized instructor's statement, is there any way I can get that online?

Question: I failed my Private written (I was being stupid and overconfident) but I got my endorsement online, I need an AUTHORIZED INSTRUCTOR'S STATEMENT to retake it and my original instructor is unavailable. Is there a way to get that online or do I have to find a new instructor to go over and sign off on it.
Comment: Hi ZKelly, welcome to Av.SE.  It looks like you have two separate accounts; please see https://meta.stackexchange.com/help/merging-accounts for steps to merge them.  Also, please be aware that "resource location" (i.e. where can I obtain ___) is off-topic here, so you probably won't be able to get a list of online instruction providers who do that sort of follow-up (if such exist -- I'd be a little doubtful).  Although I think there are enough other aspects to your question that it's okay as it stands.
Answer: First of all, don't be too hard on yourself for failing the Private Pilot written.  You're not the first person to underestimate the difficulty of the exam. You'll likely be exceptionally prepared for your next written test.
According to FAR 61.49 you need another endorsement as you noted in your question.
I'm assuming you took an FAA approved online course and received the initial endorsement via an online printed form validating that you have the proficiency to pass the knowledge (written) test.
Unless your initial online course provider (or another FAA approved provider) offers follow-up additional instruction and another endorsement via an online form, you would have to find an authorized instructor for this per FAR 61.49.
(The regulation does not state that the endorsement to retake the written test must be from the original instructor).

61.49 Retesting after failure.

(a) An applicant for a knowledge or practical test who fails that test may reapply for the test only after the applicant has received:
(1) The necessary training from an authorized instructor who has determined that the applicant is proficient to pass the test; and
(2) An endorsement from an authorized instructor who gave the applicant the additional training.

(emphasis is mine)
It may also be helpful to review the FAA's AIRMAN KNOWLEDGE TESTING MATRIX
for additional information regarding Airman Knowledge Testing.  See page 13 of this document which addresses the Private Pilot Airplane knowledge (written) test (partial image shown below):

(yellow highlight emphasis is mine)


Terminal Services Buttons Stuck (mstsc)

Question: After connecting to a remote server via mstsc, the window opens fine and everything in full-screen mode, but the close/minimize/restore buttons get stuck. I.e they do not respond to any action (they don't change when you mouseover them or do anything when you click on them). However, I am running an extended desktop, so when I click on the desktop on the other monitor the buttons start working. It's a perplexing problem, any ideas?
Answer: Unpin the menu bar at the top of the screen.
Comment: Tried this :( It didn't work.

Terminal Services Buttons Stuck (mstsc)


Logging in with Google, Facebook etc but using the same account

Question: Let's say a user logs in to a site with their Facebook account, then later decides to log in with their Google account. Should a separate account be created for each method of login or should the user be able to log in to the same account using various login methods? If the later, how would it be recognised that it's the same person logging is using a different method? Or, would the option to merge one account with another be better? Is there a best practice for this situation?
Answer: The expected behaviour would be logging into the same account. This only works, if you give the user the option to connect their social media SSO into their account.
If the user is not connected it would create a new account. You could ask the user something like "Do you have an existing account? Connect now" and give them the option to login into their already existing account and the option creating a new account like "or create a new account here".
In my opinion, Bungie's Destiny 2 connect is a good example for that. You can connect to steam, xbox, psn etc. with one account or create multiple (even though not recommended)


If I delete a game I downloaded, can I reinstall it later?

Question: If I remove a game on my PS4 to save space, will I always have that game, even if it is a PS+ title and can always install it again?
Answer: You will get to keep your games.  You'll notice that when you get the free PS+ titles, they're added to your account whether you download them or not.  Uninstalling games will not remove them from your library, which can be viewed at the far right of the PS4 home screen.
i.e. the library is tied to your PSN account, not the console's hard drive.
Please note that should you cancel your PS+ subscription at any point, any of the free monthly games you have in your account will be removed from your account until you re-subscribe to PS+.
Answer: Normally, you can download any game you've downloaded before as often as you want to, free of any additional charge.
However, there is one exception to that rule: If the game has ever been pulled out for any reason, you won't be able to download it again until it somehow returns to the PSN. Luckily, the list of games that have been removed entirely is very short (the latest example would be P.T., which is a demo), and you can still use the game until you decide to delete it.
As for PS Plus games, they're treated like any other game. Just keep in mind that you won't be able to play those games without a valid PS Plus subscription. If it runs out, you only need to subscribe again in order to play.
Comment: I don't believe this has ever happened with paid content.  Note that there are many things that are no longer available for sale that can still be downloaded if you purchased them when they were.
Comment: Yes it has! It HAS happened with some paid games for PSP which had exploits allowing users installing them on Vitas and then running PSP homebrews made for the Custom Firmware (CFW) on PS Vita.
Answer: PlayStation Plus titles are granted a special ownership status.
When you download a free PS+ title, without paying for it, you own it as part of your PS+ status. So, if you decide not to pay for PlayStation Plus anymore, then once it expires, you will not be allowed to play that game anymore. However, if you re-subscribe to PlayStation Plus, you will regain access. You don't even have to keep the game downloaded on your machine - redownloading it after resubscribing to PlayStation Plus works fine.
Source: I did this after I got my Vita and wanted to try some old games that were cross-play.


LINUX - Last login for root user

Question: on a redhat server I logged with my domain username, and then switched as root.
As I switched as root I received the message for the last login for root (Last login: ....).
I am asking if the "last login" message displays the date that every user logged/switched as root, or it displays the date that my username switched as root.
The strange thing is that the date displayed for the last login as root was 2 month before the last record in wtmp.
Thanks a lot, best of all.
Answer: You did not elaborate on what exactly you mean by "switched as root". I assume you were using the command su -, possibly in the form sudo su -. As described on its manpage, this command starts a new login shell for the root user. The "last login" message reports the last time a login shell was started for the same user.
In response to your question this means that the "last login" message appearing after su - reports the last time anyone switched to root via su - or logged in directly as root. The same holds for the "last login" message appearing when you log in directly as root.
Comment: Hi! I've used the command "sudo su -", it's the same for "su - root", true?
Comment: Correct. I have updated my answer to clarify.

LINUX - Last login for root user


Commenting on closed questions

Question: Why is it possible to comment on a closed question?
Comment: here is an example:http://stackoverflow.com/questions/6548841/watin-to-click-the-yes-button-of-the-security-alert-in-ie6
Answer: Allows for people to post a case for re-opening the question. Especially if they don't have enough rep in order to cast a re-open.
It can also allow for a little tidy up of any loose threads that were fraying just before the closing of a question.
And it will allow a mod or one of the closers to explain why the question was closed in the first place.
Answer: One reason I could think of: to let people without vote for reopen powers to let others know that they feel the question is valid.
I do not think that this is the reason it was done that way - only Jeff might have some insight on that - but for sure a good usage for it.
As Random beat me by 2 seconds, here another reason: to let the OP know what edits would help to turn it into a valuable question.
Comment: Beat you by only 2 seconds!
Comment: Total upvote on the comments helping out the Asker improve their question for re-openabilityessness.
Comment: What's this? Night of the rising dead? random shot you down! So stay on the ground.
Comment: Goaded him to consider bringing it back up because it was a good answer. Just lost out by 2 seconds.
Comment: @random: You are too good for this world ;)

Commenting on closed questions


How much of .NET is unmanaged?

Question: Frequently when I am using the Reflector, I come across lots of unsafe code. Anyone knows how much of .NET is unmanaged/safe?
Comment: Which part of .NET are you talking about, exactly? Unless you specify code as unsafe yourself, your code won't be unsafe.
Comment: How would this be answerable?  Do you want measurements in lines of code or something?
Comment: Pretty much any part like look at the list, array class.
Comment: Well how many types in .NET is answered with a number, but I am sort of looking for guesstimate percentages.
Comment: Note that unmanaged and unsafe are very different things.
Answer: There are many instances of PInvoke that just call Win32 APIs. However, there is some functionality that is implemented in the CLR itself (e.g. Interlocked operations). If you want to see how this is done, look at Rotor.
I go into a detailed explanation of locking (viewing the Rotor source) in this post on my blog.
To specifically answer your question, you'd have to get all the .NET source code (e.g. use NetMassDownloader and grep for lines that say "InternalCall" or "DllImport") and compare that with the count of all lines. Perhaps you could multiply each of these "unmanaged" lines by some factor to guess, or you'd have to dive into Rotor or the Windows source code to get the actual numbers. If you went this far then things will get fuzzy (e.g. if File.Open calls Win32's CreateFile, then should CreateFile be counted towards .NET? I think not). So, at best you'd only multiply the "InternalCall"s by some factor to guess.
Answer: This is a really difficult question to answer.  Unsafe code is easy to quantify in the sense that it exists in the binary and can be measured in terms of IL instructions.
Real unmanaged code, say PInvoke or COM, do have code in the binary but it is insignificant.  It represents only the minimal stub necessary to call into the native function.  This means you can't really measure how much native code is being excercised in a managed DLL.  All you can do is measure the number of calls which provides no real measure of how much unmanaged code is executing.
Answer: Much of System.Windows.Forms calls into the unmanaged windows API, but I have not found the need to manually dispose of objects I create in this namespace.
When using the System.IO.FileStream class (also calls into unmanaged code), make sure you call Dispose when you are done so you can guarantee the file gets closed right there and then instead of when the finalizer executes.
Comment: There is a reason that an object implements IDisposable.  You may not see a problem, but you probably have a memory leak if you are not disposing of the objects,
Answer: It doesn't really matter as the unsafe calls are wrapped by the corresponding .NET objects.  What you need to be concerned about is resource allocation and disposing of objects that implement IDisposable.

How much of .NET is unmanaged?


How can I transmit signals from pre-amplifiers to a laptop nearby using bluetooth?

Question: I am trying to collect signals from preamplifiers (Aquarian Audio preamps, PA-4) and have them sent to a laptop nearby wirelessly, I have not found a dedicated device for this process, and the preamplifiers have BNC connector. I need suggestions and this is the specs for the pre-amplifiers that I am trying to collect the data from http://www.aquarianaudio.com/pa4.html. If anyone has been into this similar situation, I need your advice.
Comment: Did you ask this the other day? Then just delete and post again?
Comment: Yeah, I did, but It was in the wrong format, so I asked it again.!
Answer: The output of the preamp is analog.  The computer accepts digital. You will need to use an analog to digital converter before trying to send the data via blue tooth.
Without knowing anything about it besides what it says on the web site, NewEgg has an ADC that might be what you need.  The output of the ADC is not something you can plug into your computer so you will need something like this from Amazon.
To get from the BNC output of your preamp to the ADC, you will need a BNC to RCA adapter, something like this from Amazon.
That said, I think you would do better with something like this device from Amazon that (the web page says) will accept analog input and run it to your computer via USB.  Sorry, you will be tripping over cables but it's a much simpler solution.


Styling selected objects with SLD

Question: Does anyone knows - is it possible to style selected objects in Geoserver (using SLD) in different way than "normal" objects? For example: "normal" points from layer would be shown in blue, but selected (by clicking, queries etc.) in red.
I have searched through in Geoserver docs, SLD specification etc., but without satisfactory result.
The only traces of what I need can be found in "Definition and Implementation of an Active Web Map Service" article (by Nieves R. Brisaboa, Antonio Fariña, Miguel R. Luaces, David Trillo and Jose R.Viqueira).
I think that mentioned styling is not possible yet. Maybe CSS would help?
Comment: have you look into generating new styling and sending it via the SLD_BODY parameter? if a query should set all type=selected in red, then you should be able to define a new sld document and send it to geoserver.
Answer: Usually you draw a second layer over the top of the map with a different style and a filter that makes your selection specified in the CQL filter that goes with the selection layer.

Styling selected objects with SLD


GPS patch antenna feeding line layout issue

Question: When I tried to put Molex GPS ceramic patch antenna 2042860001 on two-layer PCB, I found it's impossible to connect the feed pin to the RF trace on the two-layer PCB if following the recommended layout. As indicated in the recommended PCB layout as below, the feed pin is fully surrounded by the ground copper on both layers which leaves no path for the RF trace. Does this mean for this RF antenna, more than 2 layers are mandatory? If not, how should the feed pin be connected?
Answer: Yes, Molex's drawing requires a PCB of at least 3 layers.
I would use a 4-layer PCB.
It's strange that Molex doesn't say anything about the impedance of the antenna trace that should be 50 Ohm.
If you want to use a 2-layer PCB I suggest you to:

Draw the antenna trace on the top layer. The adhesive sheet suggested by Molex will isolate the antenna from the body of the GPS.

Fill the bottom layer with copper connected to GND.

Fill the top layer of copper connected to GND except for the antenna trace.

Difficult part: antenna width and clearance from the GND copper should be calculated in order to have  characteristic impedance of 50 Ohm (*).

Keep the antenna trace as short as possible

Connect together top and bottom layers using a lot of stiching vias on the border of the PCB. Put them on the border and not close to the antenna trace.

(*) Use this free tool. Your trace, as I design it, is a coplanar waveguide trace. You should design it in order to have a characteristic impedance Z0 of 50 Ohm.
https://chemandy.com/calculators/coplanar-waveguide-with-ground-calculator.htm
That tool supposes that the copper height of your traces is 0.035 mm which is the standard value of 99% of the PCB manufactured on Earth.
Comment: Thanks for your comment. To meet the requirements of Molex, I'd like to change the PCB into 4layers. If I set layer stack as follows: layer1- RF signal; layer2 - GND; layer3- Power; layer4 - digital signal,  and build the ground wall around the feeding pin on  layer1/layer4 as datasheet described, then which layer would be better for the waveguide trace on? The GND or the Power layer?
Comment: Layer 1: RF and slow signals, Layer 2: GND, Layer 3: Power, Layer 4: signals. Stiching vias connected to GND all around the border create a GND cage that contain spurious RF emissions inside the board.


Cron job hangs n 'in process' status

Question: I have implemented a bridge between an external system and Magento, retrieving product details for the external system and save it after processing to Magento.
My problem is that when there are more than some amount of records (not many, ~100) coming from the external system my job hangs in the 'in process' status.
I am suspecting the database connection, but I have tried multiple ways to make it work such as to inject ResourceConnection on each class constructor I need it, or to create a connection in the beginning of cron job and distribute it (as param) to any place needed, but I had no success.
Also, I am using the ProductInterface in order to identify the product in Magento and I use the set methods to change values and the save method in the end.
Can anyone help me please?
Thank you in advance
PS: I am using magento 2.3.5
Comment: Try how Magento product import does.
Answer:
If you have external system API, then use CURL in Magento to create or update product. And execute it by custom Cron jobs.

Create custom REST API in Magento for create and update the products. and call it in external system.

Cron job hangs n 'in process' status


Does the School of Magic count as all colours, or do you choose one colour when it's played and it is that colour permanently?

Question: It states that it has the colour of your choice (for calculating income). Do you make that choice when the card is played and it becomes permanently yellow for example, or can you change it each round?
Answer: I believe you choose each round.
In my version of Citadels (Fantasy Flight, 2009) there isn't a card called 'Mage Tower'.  There is however a very similar card called 'School of Magic' which text states.

For purposes of Income, the School is considered to be of the colour
  of your choice.  If for you are the King this round, for example, the
  school is considered to be a nobel (yellow) district.

To me that sounds like the card you are describing with extra text clarifying which sound like it may be missing from your edition?  Also if you had to decide when it was build there should be some way of marking that and the game does not come with tokens for doing so.
Comment: Sorry, I have no idea why I typed that! I've fixed the question. Thanks for your answer
Comment: Essentially the School of Magic always adds to your colour-based income.
Comment: Note that during endgame scoring "School of Magic" does NOT change color and is always purple, so it doesn't provide additional help to get bonus for all colors. Though there is another building "Ghost city" that does exactly that, if you have met its prerequisites.
Comment: @Deo There's also the Court of Miracles (? - "Hof der Wonderen" in dutch) that can also count for any desired color at the end of the game.
Comment: @steenbergh It is the card I'm talking about. Purple district for two. Apparently correct english name is "Haunted City" rather than "Ghost City". It is top left one here.
https://boardgamegeek.com/image/147403/citadels?size=original
Comment: @Deo Yes, it's the same card. I'm kind of surprised about the difference in naming. Then again, we call this game 'Machiavelli', not Citadels...
Comment: Now that we've played about 5 games at work, Machiavelli is definitely a better name for it. I wasn't sure if there were any methods to get income from two colours during the income phase and thus it would matter if the school of magic was a single colour of your choice, or acted as all colours. But it looks like there isn't a way to do that, so it's not a problem.


Is a bound elemental or elemental construct a valid target for psionic mind-swapping?

Question: In a similar vein as this question, can an elemental bound item, such as would be created by the Bind Elemental Feat or other related concept, such as a Nimblewright (a construct possessed by an elemental spirit) be a valid target for the psionic powers mind seed, mind switch, true mind switch, or similar effects?
Comment: You should probably include the methods of mind-swapping under discussion in this question, too, rather than forcing folks to bounce back and forth between questions. (Also, I don't think it's a good idea to swap into the body of an elemental bound *via* the feat Bind Elemental—the baggage that comes with that feat's binding of elementals isn't immediately evident in the feat's description; you might want to make that its own separate question.)
Comment: Updated. Regardless of if it is a good idea or not, I am only looking for an answer of valid target: (yes/no), and why. If it is proven to be valid, then you have a point in addressing the ramifications thereof in another question. At such time, I can do so.
Comment: After all, does the elemental binding stick to the soul/mind, or to the body? If the former, then it's not an issue, if the latter, then it is.
Answer: The Monster Manual description of the golem says

The animating force for a golem is a spirit from the Elemental Plane of Earth. The process of creating the golem binds the unwilling spirit to the artificial body and subjects it to the will of the golem's creator. (134)

Similarly, the Monster Manual III description of the nimblewright says

Like a golem, a nimblewright is a powerful creation that combines awesome magic with elemental forces. Its animating force is a spirit from the Elemental Plane of Water. The process of creating a nimblewright binds the unwilling spirit to the artificial body and subjects it to the will of the creator. (163)

Thus, prior to such constructs' creation, there are just parts and a free spirit, and it's the construction process that makes the spirit and artificial body one being, giving the collective entity the type construct, and it's that construct type that grants immunity to mind-affecting effects, vastly limiting the ability of most of the powers in question to target the resultant magical robot.
Were a DM to rule that the elemental spirit could be affected separately—that the elemental spirit were more than just an intangible, undetectable battery that enables the construct to move and follow commands and that the spirit were, instead, its own independent creature yet trapped in the construct shell—there's still a matter of targeting the elemental spirit. Even the 9th-level telepath power true mind switch [telepathy] (Expanded Psionics Handbook 120) requires line of sight and line of effect, and—so far as I'm aware—there's no way to get line or sight or line of effect to the creature's animating force. Similar to how a typical creature can't opt to cast the spell magic missile at—or poke a sword at!— his foe's soul, a creature can't opt to target with the power true mind switch a golem's animating force—even if the attacker knows there's a soul or animating force in there somewhere! (A DM would have to rule that, like, golems and other such creatures literally wear their hearts on their sleeves for this to be a thing.) (Spells that target a golemlike creature's animating force would likely have to be the product of original spell research—see Dungeon Master's Guide 198.)
(Also, keep in mind that the game offers no further description of the elemental spirits that are bound to such constructs. Any DM that decides to make this a plot point must homebrew such spirits.)
The feat Bind Elemental (Eberron Campaign Setting 51) has a description that runs only about 200 words, significant for a feat but not overwhelming. However, Magic of Eberron actually describes what it means to employ the feat Bind Elemental… and that takes over 2,700 words (from pages 11 to 14 including details on elemental vessel binding). In short, what happens when an elemental is bound using the feat Bind Elemental is that the elemental is shrunken and confined within a Khyber dragonshard in which it zips around endlessly, powering the magic item to which its attached. While the shard remains intact, establishing line of sight and line of effect to the elemental within is virtually impossible. (Even for vessels powered by bound elementals, "[t]o establish line of effect with a bound elemental, you must be touching the dragonshard to which the elemental is bound" (Explorer's Handbook 26), but the only effects that are listed as being usable due to that line of effect are charm, dominate, and elemental command via rebuking.)
Now, I guess, in theory, using an effect like the 4th-level Sor/Wiz spell scrying [div] (PH 274-5) a caster could peek in on the elemental to make sure the elemental's in there then—probably, somehow, likely with the 5th-level Sor/Wiz spell magic jar [necro] (PH 250-1) with its substantial differences from the psionic powers the question mentions—swap souls with the elemental, but then the caster would find himself trapped in the Khyber dragonshard!
What happens next is GM fiat, but this DM would likely have the caster find himself forced to zip around powering whatever it is the bound elemental was powering. This sounds like the last desperate act of cornered wizard and an excellent plot hook, but—like the 9th-level Pain domain spell eternity of torture [necro] (BV 93-4)—a really terrible way of living forever.
Comment: @BenBarden True. But *extending* that line of effect to *everything* means the possibility of targeting the elemental with *other* spells—including crazy things like *polymorph any object* to turn the elemental into a mailbox or just straight-up murdering the elemental with *phantasmal killer* or whatever. That, to me, is a bridge too far. I'll stick with what the text says and assume it's being comprehensive. (Nonetheless, I've hedged a bit just in case.)
Comment: It is indeed possible to establish line of effect on at least some bound elementals - specifically those used to fly airships.  See the sidebar quoted in my own answer.
Comment: @BenBarden Thank you for pointing that out. Addressed.
Comment: There's nothing in particular that indicates that the effects listed are the only ones that can be made through that link - it's just that those are the ones that are described for the purpose of controlling the vessel.
Comment: There's never a question whether a mind-affecting spell has line of effect to the mind? I think this is an odd argument.
Comment: @Wyrmwood Line of effect is needed only to the creature.  The whole paragraph beginning *Were the DM to rule…* is a hypothetical, requiring the DM to have made a very specific set of house rules.
Answer: Mind Seed, no.  Mind Switch, sort of
Mind Switch targets "a nearby living creature".  True Mind Switch inherits that without modification.  Mind Seed must target "One touched Medium or smaller humanoid".  Elementals qualify as living but not humanoid, and nothing about being bound into an object changes that.  Now, as a bound elemental, your ability to act is likely to be limited, and, I believe, you'd be blind.  Still, yes, it should be possible.
In particular, it would be entirely possible to mind switch into an elemental, and then, as that elemental, be bound into an object.  There's no particular reason to think that you could not do that in the opposite order, and it's certainly possible to get within range close.  Certain kinds of elemental bindings might fully surround the elemental within a casing, which might raise line of sight or line of effect issues, but not all of them.  Mind Seed's requirement of touch isn't an issue due to having already failed the humanoid requirement.
To address an issue raised in the comments, even elementals bound into items still exist as entities capable of thought and potentially capable of being targeted.  A quote from a sidebar in the Eberron Campaign Guide, page 267:

In order to make the elemental obey any of these commands, an
  unmarked character must win an opposed Charisma check against the
  elemental (virtually all elementals have a Charisma modifier of +0).
  If the elemental wins the opposed check, it either continues with the
  current course of movement or brings the vehicle to an immediate stop,
  according to its whim.  If the character wins the opposed check, the
  vessel moves as the character intends.

It is noted somewhat later in the sidebar text that a spell of Charm Monster also does the trick of keeping control of the vessel.  Thus, the elemental is capable of some degree of agency even without direction (though quite limited) and can be targeted by mind-affecting abilities (cast by people who are touching the control stone).  Nothing stops Mind Switch other than a desire to not be a bound elemental.
For the nimblewright, there are a couple of problems.  Quote from MM2, page 162-163:

The process of creating a nimblewright binds the unwilling spirit to
  the artificial body and subjects it to the will of the creator

Thus, even if you could get line of effect on the bound elemental, you would be mindswitching into an elemental that is already bound, and the implication is that it is the fact of being bound to the nimblewright that subjects the elemental to the will of the creator.  That's supported by the fact that the nimblewright retains the full suite of construct traits, including the immunity to mind-affecting abilities.
Comment: @KRyan I stand corrected.  As does my reply.
Comment: Fair enough, good edit. But I still think the answer's wrong, personally; I don't find your reasoning about what binding should or should not be like particularly convincing. Can you back up any of your claims about how binding does or doesn't work or what state it does or doesn't leave the elemental in with statements from the book? That would improve your answer.
Comment: @KRyan are you questioning any part of the answer other than "your ability to act is likely to be limited, and, I believe, you'd be blind."?  If so, could you clarify which bits?
Comment: The assumption that because you could *mind switch* into an elemental and then be bound to an item, the reverse would also work (I don't think that's true), and while I think you are correct that the nimblewright could not be targeted with *mind switch*, your reasoning as to *why* seems very much like your own made up fluff rather than anything the books actually suggest, much less state outright.
Comment: @KRyan I have added quotes and additional logic.  You were correct on the nimblewright (now changed) but I believe my point still stands on the bound elementals.


RFID tags inside metal items?

Question: Is it possible to use an RFID tag inside a stainless steel enclosure? I am looking for a way to uniquely and easily identify a sensor. An alternative possibility is a laser engraved bar code.
Answer: RF coupling
The "perfect" Faraday cage requires the metal to be a perfect conductor.  Copper is a great material for Faraday cages.
However, stainless steel isn't a great conductor.  It's ok, but you will find that some RF, particularly low frequency high power RF, will penetrate the case, and the RFID tag will affect that field.
However, you're probably not going to be able to use an off-the shelf RFID unit for this if you depend on RF coupling.
Magnetic coupling
Most inexpensive RFID tags operate on the magnetic field rather than the RF field, and fortunately for you many stainless steal alloys have very weak interaction with magnetic fields.
If you choose an RFID transponder with a large magnetic loop antenna, and you have the reader very near, you should be able to use RFID inside your stainless steel case with very few problems.
You'll want to experiment with different stainless steel alloys, and different transponders, but you should be able to find something off-the-shelf that works.  I'd aim for lower frequency RFID - I would expect 125kHz RFID to work fine in this situation.
Answer: I agree with most of the previous answers that the environment is very challenging, and with all the theoretical arguments raised. My answer is: with a usual tag, probably not, but then you can take a look at iDTronic In-Metal Tags. (just search it like that in Google).
Personally, I haven't tested these tags, so I cannot guarantee performance or readability in your environment, just wanted to point out that such a product exists and in UHF.
Answer: Not possible if the tag is completely enclosed by metal, the enclosure is an effective Faraday cage.  The bar code might be the better choice unless you can somehow mount the RFID tag on the outside of the enclosure.
Comment: @DirkBruere In practice it doesn't generally work, however there is one company that claims to have a solution to metal-embeddable RFID: http://www.xerafy.com though I'm not sure how it works or if it works in a completely enclosed box.
Comment: I thought the RFID was a near field effect which might be somewhat immune to a simple Faraday Cage effect ie it might have a magnetic component that could penetrate the stainless steel
Answer: It might work to a certain extent at low RFID frequencies (like 125 kHz) and with a thin stainless steel enclosure but it will be impaired. If the RFID frequency is 13.56 MHz then it's not going to work at all.

RFID tags inside metal items?


Finding the smallest number $n$ such that every two-colouring of the edges of $K_n$ contains a Path on 3 vertices

Question: What is the smallest number $n$ such that every two-colouring of the edges of $K_n$ contains a (not necessarily induced) path on 3 vertices?
Comment: Sorry, Do you mean a path where every edges has the same color?
Comment: @mathnoob yes, all edges should have to have the same color
Comment: Seems like $K_3$ already does the job which makes me think that you meant to phrase the problem differently. (A path on $3$ *edges*, for example.)
Answer: If it is a path on 3 vertices , $K_3$ works as it is garanted that two of the three edges have the same color, well then they form a path on three vertices.   If what we want is a path of length $3$, my guess is $5$. Look at a vertex $u \in V(K_n)$, there are 4 edges connect to it. It is guarantee that at least two of the edges $e_1,e_2$ connected to it have the same color. So the edges connected to $e_1$ and $e_2$ not via $u$ must be color the other color. But then that gives a path of length 3 in the other color.
Also, here is an example of coloring of $K_4$ that does not admit a path of length 3, the edges are colored using numbers 1 and 3.
Comment: Am I right????????????
Comment: Seems right to me, modulo a coloring of $K_4$ that does not contain a path of length $3$ (which is not hard to find).
Comment: Great! Thank you!


Area of an irregular, n-sided, non-intersecting (edges) polygon algorithm

Question: I need to generate an irregular, n-sided polygon of non-intersecting edges (n= 200, for example) with the smallest area possible. The position of the vertex is random and I've tried designing a couple of algorithms with no satisfying result. Is there something out there with this specifications or a way of designing it? I have OpenGL if it helps.
Comment: What is the condition on the side lengths?
Comment: You receive the vertices, so it depends on it.
Answer: Given a set of $n$ points in the plane, the problem of finding a minimum area convex $k$-gon among the points was considered by Eppstein, Overmars, Rote, and Woeginger in this paper.  They give an algorithm that runs in time $O(kn^3)$.
As Gerry Myerson mentions, there is also the variant where we do not require the $k$-gon to be convex. Both these problems can be solved in time $O(kn^k)$ by checking all $k$-tuples of points.  However, this paper by Eppstein claims that no faster algorithm is known (see the Introduction) for the non-convex version.
Comment: @GerryMyerson That's true.  The wording of the question was a bit vague, so I took my best guess at what it meant.  I guess we will have to wait until the OP clarifies.
Comment: OP doesn't use the word, "convex", so I'm not sure this is what's wanted. It may be one is required to have on the boundary all of the $n$ points given.


How do I fix Wifi in Debian 9?

Question: Upon Boot, Debian doesn't show an internet signal. When I click on it, it shows that wireless is "unavailable". I'm on an HP laptop, so I press F12 to try to enable my Realtek internet adapter. I still don't get a response. The peculiar thing is, upon my first boot I had the same problem, but when I rebooted the system to use internet on my Windows installation, it worked. I booted back into Debian after doing some searching and found that my internet was working! I've since been using my internet on Debian to research the other problem I have. I recently shut down my laptop for transport and when I booted to Debian, internet wasn't working anymore. Is this a driver problem? How do I fix this?
Comment: I am using Debian. I know my username is KALI99, but that was because I had Kali a few months ago. I installed Debian recently because I was recommended by other Linux experts, and because my laptop seems to (for now) run better,
Answer: It works with internet cable?
If so do this:
<code>    echo 'deb http://ftp.debian.org/debian/ stretch main contrib non-free' >/etc/apt/sources.list
    apt-get update
    apt-get install firmware-realtek
</code>
To install the network drivers...
Restart the computer and try again to locate the wifi networks.
If you do not have a way to use the internet via cable, download the package from here:
http://ftp.us.debian.org/debian/pool/non-free/f/firmware-nonfree/firmware-realtek_20161130-4_all.deb
Save in a pendrive, open the pendrive on the debian machine, click with the right button of your mouse in the pendrive "folder", Open in a Terminal, them install it using:
<code> dpkg -i firmware-realtek_20161130-4_all.deb
</code>
Restart the computer and try again to locate the wifi networks.
Comment: I will try this, my internet came back. I got it on by not doing a full shutdown. I instead hit restart in windows and switched to debian.
Comment: Thank you! As soon as I booted my laptop from a complete shutdown, I noticed that the info on the screen was missing an error line that I had seen since installation. It so happens that line was that a firmware file rtl*****.bin was missing. I'm guessing with what I typed in replaced that missing file. Again, thank you.
Comment: This missing files are proprietary (non-free), so they cannot be distributed on debian by default. The repository in sources.list must be with the "non-free" option enabled so then you can install this packages... and that is why this solved your problems.

How do I fix Wifi in Debian 9?


How do you edit the html of teaser excerpts

Question: All my teaser excerpts have no formatting applied to them. With firebug I can get the text to look how I want by editing the html but I don't know where to edit the html in wordpress. How can I do this? Thanks
Answer: wordPress does this by default.  you can either use a plugin such as:
http://wordpress.org/extend/plugins/advanced-excerpt/
http://wordpress.org/extend/plugins/the-excerpt-re-reloaded/
or write your own functions to remove the default filters from the_excerpt() such as:
http://bacsoftwareconsulting.com/blog/index.php/wordpress-cat/how-to-preserve-html-tags-in-wordpress-excerpt-without-a-plugin/
Comment: caveat: this code http://bacsoftwareconsulting.com/blog/index.php/wordpress-cat/how-to-preserve-html-tags-in-wordpress-excerpt-without-a-plugin/ does seem to leave broken html tags - tested with a `` tag.
Comment: Thanks for the suggestions but I probably should have mentioned that I'm using the thesis theme therefore the plugin doesn't do the job. I found this code in the link you provided:  $allowed_tags = ',,,,';     which sounds promising but I'm not sure how to implement it
Comment: plugins don't work w/ thesis?  i'm skeptical.
Answer: @Michael: I wrote the tutorial you are referring to: http://bacsoftwareconsulting.com/blog/index.php/wordpress-cat/how-to-preserve-html-tags-in-wordpress-excerpt-without-a-plugin/
It does not leave any broken html tags, I use it on my blog. Unless the excerpt ends between the starting and ending tag. You need to make sure that your excerpt does not break whatever tag you are using.
Check it out in the main page: http://bacsoftwareconsulting.com/blog/
@Nick: To answer the question on how to use the code of the reference above:
Copy the "MAIN_CODE" and paste it in your "functions.php" file of the thesis theme.
After that you need to replace line 22 of the "MAIN-CODE" with the "$allowed_tags" you want. For instance to allow p, a, em, strong and image, you replace Line 22: with <code> $allowed_tags = '<p>,<a>,<em>,<strong>,<img>';</code>
One of the things the code can't do is to add color or larger fonts. Like I said before, you always need to make sure that the excerpt does not end in between the opening and closing tags. You can also change lines 25 and 28 to your liking.
The tutorial is self explanatory, but you need to spend on it few extra minutes.
Hope this Helps.
Boutros.
Comment: my apology if my remark caused any offence, however I am of the opinion that it should not be the user's task to make sure that the excerpt is not cutting through any html tag. that is the whole point of an automatic excerpt, and any coding to keep html tags in the excerpt should take care of this. I also looked this up myself in the past, and I am aware that this is no simple task. I have not checked if the 'advanced-excerpt' plugin can do this.
Comment: i think there is a specific file/folder in thesis for custom functions (ie that won't get overwritten on upgrades), but since i don't use it i am not 100% certain. point being, for the OP to be careful posting things in functions.php w/ a theme like Thesis that will probably see updates
Comment: I agree, for the thesis theme, you should refer to the documentation where to add user generated functions. It might be in a different place than "functions.php".
Answer: Use remove_all_filters to remove filters on the_excerpt. Have a look at wp-includes/default-filters.php - a ton of filters are added to the_excerpt and get_the_excerpt which removes most of the formatting.


Why do black lights show bacteria and proteins?

Question: Why are blacklights used to show proteins and bacteria? Is it related to their ability to make white colors glow? Don't black lights just radiate in the ultraviolet/purple range?
Answer: As you well know, our eyes can only see the visible spectrum (lets say from red to violet). Now, if you turn on a black light in a dark room you can only see a purplish glow. You are "blind" to the ultraviolet light that the bulb is also producing. The things you see under a black light (when illuminating a fluorescent poster, a brand new white t-shirt, etc) are called phosphors. The phosphors is a substance that absorbs the UV light and emits it as visible light.
The same general principle holds with bacteria and proteins. Some bacteria contains plasmind, which in turn contains a certain gene, which codes for the Green Flourescent Protein. So you can put the plasmid in the bacteria, the plasmid starts making that protein in the bacteria and the result is a glowing pile of goo. (try a google search on the matter, there are tons of articles, etc. )
Comment: Is this the main protein that fluoresces? Puff adders track prey after having bitten it by seeing in UV because the prey invariably wets itself on being stricken and the urine holds a protein which fluorescences in sunlight at very short wavelength


Using eof or end-of-input in ff match?

Question: I have a huge data file in the following format:
section 1
data 1
end section

section n # n is a large number > 10000
data n
end section

The marker for the end of each section is the same, "end section". I need to frequently get a section and then another section to the end of the file. I do so in 2 steps:
cat dataFile | perl6 -ne 'my $n=1234; .say if /section \s $n/ ff /end \s section/' > neededPart
cat dataFile | perl6 -ne 'my $n=4321; .say if /section \s $n/ ff *' >> neededPart

This is cumbersome when I have do it many times. I wonder if perl6 has something like end-of-input or eof in match, so that I can just do in one line:
cat dataFile | perl6 -ne '.say if /1234 || 4321/ ff /"end section" || endOfFile/' > neededPart

Using the following does not work:
/1234 || 4321/ ff (/end/ or *)
/1234 || 4321/ ff ($_ ~~ /end/ or *)

Answer: You could try to use two ff conditions instead of a single. For example:
perl6 -ne '.say if (/1234/ ff /"end section"/) || (/4321/ ff *)' <dataFile

Using eof or end-of-input in ff match?


Is playing an electric guitar easier on the left hand than an acoustic?

Question: My left thumb has some arthritis so I am thinking about switching to an electric — thinking that playing an electric would be easier on the thumb joint. Any advice on the subject would be appreciated (including suggestions on instruments).
Comment: Is your acoustic steel- or nylon-strung?
Comment: The instrument is a Martin with steel strings.
Comment: Not an answer to your question, but an in-between solution might be to use lighter gauge strings. Go Ducks!
Answer: An electric guitar is definitely easier on the left hand, but it won't be easier on your thumb joint because the problem with your thumb joint is your technique.
You should not squeeze the neck between your thumb and fingers. You should activate your left bicep to provide the static force through to your hand so your fingers can depress the strings. That can tend to pull the neck of the guitar towards you, which means you'll have to apply some pressure to the body of the guitar with your right forearm to keep it from moving.
At the same time, you should not be getting a bicep workout while playing. You want to use the minimum amount of force to prevent string buzz. If you're getting a slight buzz on some notes, then you know you're right around the right amount of force.
You should be able to play fairly well with your thumb not even touching the neck. It's mainly there to provide stability and awareness of position on the neck. Bending with the thumb over the top of the neck is fine because that's still mostly the finger flexors doing the work, the thumb opponens and abductor muscles should still be relaxed when bending.
Answer: Yes and no. Basically this is a question of the neck dimensions, and in terms of non-classical acoustic guitars there are many guitars that have necks quite similar to electric guitars.
The gist is: A guitar with a slim neck will make comfortable "lazy" playing much more viable, which is why players often feel like these are "easier" to play. Playing a slim neck will make it easier to play while not even placing your thumb on the neck (but rather holding the neck in the palm of your hand). Usually playing on a wider neck such as on a classical guitar is mostly a question of proper hand technique, as a well placed thumb will act as a pivot to allow your hand to go anywhere.
Now if you have problems with your thumb a slim neck and not placing your thumb on the neck could be a viable option as long as you keep to simple stuff. Once you want to play more complex stuff you really want to make use of your thumb.
That being said you might improve your technique somewhat. You want to make sure the thumb joint always curves inwards, you do not want the thumb to point outwards, as the joint is not made to take strain in that direction. Also you should not need to put a lot of pressure onto your thumb. You do not really need your thumb that much to compensate the pressure of your fingers, as your playing arm and your upper body is already stabilizing the guitar. This is by the way even easier on a big bodied acoustic guitar than on a small bodied electric.
Also you might want to make sure that your strings are not too high tension and that the action of the guitar is not too high. A badly setup guitar will require you to exert more force which will eventually also put strain on your thumb. So in this case I really think it is worth it to invest in a instrument with straight neck, level frets and get it setup really nicely.
And most importantly: When you feel playing is putting strain on you, stop and rest. Muscles will build up. Sinews to some extent too. But straining joints will only cause damage and not cause you to get stronger or anything. Instead you'll risk permanent damage to your thumb.
Answer: On a well set up guitar, acoustic or electric, there won't be much, if any discernible difference. The necks of a good acoustic (Martin's one) and a good electric will not be far different from each other, in width, depth or fretboard radius. Obviously, with a high action, or thicker strings, thus tighter, neither will be kind to anyone's hand.
That said, your thumb should not be acting as one half of a vice. Most players actually press too hard, believing that's the thing to do. On a well set up instrument, there's just no need. Press as hard as needed, so the notes don't rattle. Any harder is just a waste.  In fact, even with barre chords, there should be no need to squeeze the life out of that neck, which won't have helped the arthritis at all.
Comment: Is there a way for me to tell if my guitar is setup correctly?
Comment: Other than taking it to a luthier, or gaining the experience over several years, probably not.  These things take time!
Answer:
It is my understanding (which may be incorrect) that an electric requires less string pressure than an acoustic

That is correct, at least in 99% of cases, maybe 100 (sorry, I don't have enough points to "Add a comment" on that part you wrote)
One person pointed out bringing it to a luthier, and not knowing your budget, if ever that's an issue, you could always go try an acoustic in a store as though you were shopping for one just to see if you feel less tension. Of course, some guitars have higher action (more strain in your case) but it'd still give you a sense if your Martin is way out of wack.
This may sound ridiculous, but have you thought about maybe wearing a thumb contraption of some sort? I don't have any problems and have played for 25+ years but when I was sometimes injured, I'd even put electric tape around my thumb (I don't advise it) but drugstores or whatnot probably have various forms of "thumb protectors". You can google it, they probably sell them online too. It's not meant for that specifically but could work out maybe in alleviating the stress on your thumb


Why did Descartes claim that animals have no souls if they have the pituitary?

Question: As far as I understand it, Descartes claimed that the pituitary is the "antenna" through which the brain and the soul communicate, and he also claimed only human beings have souls. So, how did he explain away the fact that many non-human animals also have the pituitary?
Comment: Did René Descartes do what is expected of and what comes naturally to - on pain of being ridiculed to death - people who make statements like "the pituitary/pineal gland is the seat of the soil"?
Comment: The first account of the *pineal gland* into the [Treatise of Man](https://plato.stanford.edu/entries/pineal-gland/#TreaMan) is totally "mechanistic": D speaks of animal spirits. Only later, in the *Dioptrics* (1637), D asserts that the gland is the seat of the *sensus communis* and "that this gland is the principal seat of the *soul*, and the place in which all our thoughts are formed." Up to now, we may simply understand that animals, man included, have the gland but **only** man has the soul. In case of man, the glad is the place were the soul "communicate" with the body. [1/3]
Comment: Just because there is an antenna does not mean that there is also a transmitter to tune in to, and the pineal gland has purely corporeal functions aside from receiving soul transmissions. To Descartes, a human is a ghost in the machine, and animals are machines without the ghost, "*the souls of animals are nothing but their blood*". His arguments are based on anecdotal surmises of  animal behavior, lack of language in particular. Perhaps, God had a master design for both human and animal machines, and multipurposed human pineal gland for soul reception.
Comment: Only in [The passions of the soul (1649)](https://plato.stanford.edu/entries/pineal-gland/#PassSoul) we have D's full account of the solu: ""We need to recognize that the soul is really joined to the whole body, and that we cannot properly say that it exists in any one part of the body to the exclusion of the others. [...] nevertheless there is a certain part of the body where it exercises its functions more particularly than in all the others. […] The part of the body in which the soul directly exercises its functions is not the heart at all, or the whole of the brain. [2/3]
Comment: It is rather the innermost part of the brain, which is a certain very small gland situated in the middle of the brain's substance." [3/3]
Answer: Actually, it was the pineal gland that he attributed the soul to.
As for its presence in animals, he never discusses it, and therefore we can not know why he dismissed it, or even if he was aware of it.
Thomas Willis, writing of the gland shortly after Descartes' writings on it were published, simply offers its presence as a refutation of Descartes.
Answer: What in the world did Descartes know and understand about the physiology, structure, and function of the human brain? Where was his data? His evidence? He had no knowledge, no understanding, no data and no evidence on this topic and so his assertions can be dismissed without argument. They do not even rise to the level of irrelevance.


MPPT Solar Panel Schematic

Question: I've been looking at a few MPPT schematics, and I'm confused about the operation. The point of MPPT tracking is to extract the maximum amount of power from the solar panel, which means controlling the amount of current coming from the panel. These circuits are structured as buck converters, which means that at 50% duty cycle, half the time the current coming out of the solar panel is increasing, and half the time its decreasing. Why not have the inductor before the switch, so that the panel current is constant, as shown in the first circuit here?
Comment: Because then it wouldn't work as a buck converter.
Answer: MPPT controller works when voltage from solar panel is higher than the battery voltage. That means input voltage needs to be reduced. This reduction is done using Buck Converter, which produces lower output voltage but can have higher output current than on the input. The way it operates requires switch before the inductor: when the switch is conducting the current flows through inductor into load and output capacitor. When output voltage reached required level, switch is getting open, but current continues to flow from the energy stored in the inductor (that is why diode is also required as it provides the path for this current). Cycle repeats at high frequency. Duty cycle is controlled depending on output voltage and current required and not fixed at 50%. When input voltage is low duty cycle can potentially go to 100%. Having switch after inductor will prevent normal buck coverter operation
Answer: The following video may be extremely helpful to visually explain the dynamics of buck (and boost) converters, going through different basic (and also incorrect) design ideas and their pros and cons. Voltage is shown as distance (height), and the current magniture by arrow size. The role of inductors and capacitors in a network is especially clarified here.
https://www.youtube.com/watch?v=vwJYIorz_Aw
Comment: Link-only answers are heavily discouraged here. Summarize the important points from the video, instead, then link it in addition to that.
Answer: I will answer by question which points you to core of problem. What happens when your switch connect left 10uF capacitor charged to "high" voltage with right 10uF capacitor discharged to "lower" voltage ? Large current limited by resistance of your switch and capacitors ESR wil flow from left to right and dissipate energy to heat and that is the reason to place inductor between them.

MPPT Solar Panel Schematic


How to merge selected features with different attributes in QGIS?

Question: I want to merge several features with attribute values that fall within a certain range. I use Select by Expression to select the relevant features, but when I click merge selected features, QGIS times out and ends up crashing. I think it's because the features have many attributes, which are different, and QGIS is not sure how to merge them. I thought I would be prompted with a window to define the attributes after the merge, but I guess not?
Comment: Which QGIS version are you using? I suggest you to create an issue here: https://github.com/qgis/QGIS/issues/
Answer: You could also try the Dissolve algorithm (under Vector geometry in the Processing toolbox).
When you have selected the features to be merged, you can merge them using Dissolve (with Selected features only, and no Dissolve field(s) specified).
The resulting layer will only contain the generated (multi) feature.


What is numerical step by step logic of SVD (singular value decomposition)?

Question: After this previous question, we want to perform a numerical  approximation to the singular value decomposition  $\mathbf A=\mathbf U\mathbf \Sigma\mathbf V^\top$. But we can operate only with matrix individual elements such as  $a_{i,j}$  , $u_{n,k}$ , $v_{m,\ell}$ etc. (like we do in most programming languages). What shall be our step by step algorithm for performing SVD?
Answer: If you absolutely, genuinely, really, truly need to implement the singular value decomposition yourself (which I have already advised you not to do based on my reading of you), you will want to see the ALGOL code in Golub and Reinsch's classic paper. (Alternatively, see the EISPACK implementation.) There have been a lot of improvements to the basic two-part algorithm (bidiagonalize and apply a modified QR algorithm to the resulting bidiagonal matrix) since then, but not knowing your background in numerical linear algebra matters, I'll refrain from mentioning them for the time being.
Answer: There is no finite algorithm for SVD, only numerical approximations. See http://en.wikipedia.org/wiki/Singular_value_decomposition#Calculating_the_SVD.
Comment: that is kind of not step by step...
Comment: @Kabumbus: lhf's point is that there are a bunch of canned methods for performing SVD, taking care of any subtleties you may not have had in mind. You really don't have and should never have a need to write your own program, unless you have expertise in numerical linear algebra.
Comment: @J.M., actually, my point was that there is no algorithm for SVD like there is for solving linear systems, e.g., Gaussian elimination. But the point you make is also important.
Comment: Maybe if I give an inkling of how complicated the actual business is, I can scare the OP... :)
Answer: Hmm, I do not quite understand what you mean with "step-by-step algorithm", so this answer might be useless, anyway.
Before the much complicated, elaborated (and also optimized) approaches to SVD, as detailed in @lhf's wikipedia link, there is a conceptual simple method: jacobi-rotation to principal-components-position along rows and the along columns (which of course must be iterated until accepted convergence like all other methods)
That rotations can be implemented very easily and are in general numerically stable: a pair of rows are rotated by an angle for which the criterion can agayin easily be determined.(requiring not more that the sums of squares of the current a_i's and a_j's under iteration). Having accumulated the rotation-criteria in the then unitary ("rotation") matrix U the same process is performed over the columns, giving another rotationmatrix V. (If the original matrix M is symmetric, U and V are transposes/inverses of each other and we have the diagonalization of M).
With current speed of computers, one can handle matrices of some dozen rows/columns in a second; a 80x100 -matrix M needed 2 seconds to be computed.
Using the implementation in my MatMate-program I just formulate:
n,m = 80,100
M = randomn(n,m)  // generate a random matrix of n rows, m columns

U = gettrans(M ',"pca") '   // get the row-rotation matrix for rowwise PC-position
V = gettrans(M ,"pca")      // get the col-rotation matrix for colwise PC-position

D = U * M * V               // get the quasidiagonal matrix D

This needed at most two seconds(guessed).
The "gettrans"-procedure does simply pairwise rotations of all rows (resp cols) and iterates until convergence, keeping track of the rotations in a matrix T which is then returned as result of the procedure.
As said: the procedure is in no way optimal in time and space consumption; the time consumption is at least cubic with the size; with matrix-size of 200x100 I needed one minute for the same computation using a randommatrix M, so it advised to use it only for such small matrices. And for instance may not converge fast if the rowwise or columnwise PC-positions are not unique because of equality of eigenvalues in M*M' or M'*M (the apostrophe meaning transposition) , and thus should be modified and sophisticated to cover also the "unfriendly" cases. But it is -in my view- conceptionally straightforward and very simple to implement as a starter (and also numerically stable), so is -again in my view- a good example for the self-study of the method.
[Update:] A time-saving precondition as mentioned in the first of the two papers linked by @J.M. (here again) can easily be inserted into the MatMate-procedure:
r,c = 100,200
M = randomn(r,c)  // generate a random matrix of n rows, m columns

   // precondition
Q = gettrans(M, "drei")    // get the col-rotation matrix for lower-triangular position
                           // this is also QR-decomposition
M1 = (M*Q) [1..r.1..r]     // r is the upper-limit for the rank;
                           // for SVD use submatrix only

      // SVD on the preconditioned matrix
U = gettrans(M1 ,"pca")     // get the col-rotation matrix for colwise PC-position
V = gettrans(M1' ,"pca")'   // get the row-rotation matrix for rowwise PC-position

D = V * M1 * U               // get the quasidiagonal matrix D of lower rank

// if the full solution for the roation-matrices is needed, proceed as follows:
// to get the full svd, matrices Q and U must be combined, but are of different size,
// so U must be extended and the new diagonal-elements must be set to 1
U1 = einh(c)                 // 200x200-unit-matrix
U1[1..r,1..r] = U            // insert 100x100-rotation-matrix
U  = Q*U1                    // get full 200x200 SVD-rotation matrix

Time without preconditioning: ~ 60 secs
Time with preconditioning: ~ 8 secs
[/update]
Comment: Re: Jacobi, there are in fact two ways to do Jacobi for the purposes of computing the SVD. The usual distinction divides "two-sided" Jacobi algorithms from "one-sided" ones. [Kogbetliantz's algorithm](http://dx.doi.org/10.1007/BF01398880) is the canonical example of the "two-sided" methods, while [Nash's method](http://dx.doi.org/10.1093/comjnl/30.3.268) is the usual example for the "one-sided" methods.
Comment: In fact, though Jacobi might be quite slower than the QR approach, it can be shown that it gives more accurate results for some families of matrices. See these [two](http://www.netlib.org/lapack/lawnspdf/lawn169.pdf) [papers](http://www.netlib.org/lapack/lawnspdf/lawn170.pdf) by Zlatko Drmač and others for details.
Comment: @J.M.: very nice papers, indeed! The rank-detection preconditioner procedure by an initial QR-procedure mentioned in the first of the *two papers* reduces the time-consumtion of to 200x100-example from 60 to 7 seconds... :-) I'll add that precondition to my answer
Comment: Yes, it is indeed the case that performing a preliminary (pivoted) QR decomposition and then feeding the triangular factor to the Jacobi algorithm makes for better performance. :)
Comment: @J.M.: That two papers please me much, thanks again. It's too much to read them through today but luckily they require a level of understanding only such that I seem able to follow the core ideas :-) Well, I'd like to implement that optimization-ideas immediately into my MatMate-code, but probably may be, that this will happen in my next life ;-) I've still to chew that sources concerning the vandermonde interpolation which you made me aware of in the other thread and which seems again one of the sort which I'm able to go through. Multiple thanks again for this very kind support!
Comment: No problem. I picked up most of my numerical analysis expertise from reading stuff on the Internet and doing many, many experiments; I'm glad I am now at a position to be able to spread the knowledge!
Comment: Grate answer... finding how [MatMate](http://go.helms-net.de/sw/matmate/) works was fun...=) But it works!=)


Importing matplotlib using PyScripter

Question: I am using PyScripter as an IDE for python coding. I installed matplotlib in windows.Now i written a program which imports matplotlib but PyScripter doesn't import this lib.How i can matplotlib using PyScripter.
Answer: This might be very late :-) but to those browsing - Pyscripter can connect to the internal bundled python installation and to your global installation (as a remote engine). Packages imported to the global will not be available in the internal engine. Just connect to remote, and you should be good.

Importing matplotlib using PyScripter


DataModel for Workflow/Business Process Application

Question: What should be the data model for a work flow application? Currently we are using an Entity Attribute Value based model in SQL Server 2000 with the user having the ability to create dynamic forms (on asp.net), but as the data grows performance is getting down and hard to generate report and worse if too many users concurrently query the data (EAV).
Answer: As you have probably realized, the problem with an EAV model is that tables grow very large and queries grow very complex very quickly.  For example, EAV-based queries typically require lots of subqueries just to get at the same data that would be trivial to select if you were using more traditionally-structured tables.
Unfortunately, it is quite difficult to move to a traditionally-structured relational model while simultaneously leaving old forms open to modification.
Thus, my suggestion: consider closing changes on well-established forms and moving their data to standard, normalized tables. For example, if you have a set of shipping forms that are not likely to change (or whose change you could manage by changing the app because it happens so rarely), then you could create a fixed table and then copy the existing data out of your EAV table(s).  This would A) improve your ability to do reporting, B) reduce the amount of data in your existing EAV table(s) and C) improve your ability to support concurrent users / improve performance because you could build more appropriate indices into your data.
In short, think of the dynamic EAV-based system as a way to collect user's needs (they tell you by building their forms) and NOT as the permanent storage.  As the forms evolve into their final form, you transition to fixed tables in order to gain the benefits discussed above.
One last thing.  If all of this isn't possible, have you considered segmenting your EAV table into multiple, category-specific tables?  For example, have all of your shipping forms in one table, personnel forms in a second, etc.  It won't solve the querying structure problem (needing subqueries) but it will help shrink your tables and improve performance.
I hope this helps - I do sympathize with your plight as I've been in a similar situation myself!
Answer: Typically, when your database schema becomes very large and multiple users are trying to access the same information in many different ways, Data Warehousing, is applied in order to reduce major load on the database server. Unlike your traditional schema where you are more than likely using Normalization to keep data integrity, data warehousing is optimized for speed and multiple copies of your data are stored.
Comment: Clearly this is a joke answer meant to be funny. Hahaha.
Answer: Try using the relational model of data.  It works.
Comment: That was a big help to the OP, I'm sure.


Doc Library stopped updating required multiple choice field

Question: I have added two columns to a document library under online version.  First worked fine to start with.  Now second is a required field, but cant update the library either as individual items or as a multiple items.
Field change is "saved" but then reverts back to previous state.
Answer: How did you change the column value? Right click the item and click properties?
Narrow down this issue as following:

Create a new multiple choice column with required and have a test to check the result.
Besides, you could use Quick edit to change the value and compare the result. Note: set Allow 'Fill-in' choices to NO if use quick edit.
And check if there is workflow or event receiver to update the column with previous value.
If the issue exists, please create a new library and column to check the result.
And also you could clear the browser cache and change a browser to check the result.
If necessary, you can reboot or change the computer to test it.
Comment: thank you. Will check out your suggestions and report back.
Comment: I have done further review of the issue.  It appears to relate to forcing "check out" on the library.  If not checked out then under quick edit it will not allow an update.  To change a required field have to check out, quick edit, save, then check back in each item.  NOT ideal.
The checkboxes do NOT work in edit individual item, and do not show in Word App.


is there any excuse or reason why our bubble in Hawking's space-time foam theory is retained?

Question: Hawking said that universes are like bubbles that pop into existence and pop back into the vacuum some form then immediately pop, he calls this space-time foam, our bubble doesn't seem to pop immediately after it's formed, is there a reason for our bubble staying so long, is it because we're simply too tiny to notice?
Comment: Hi! It would be very helpful if you could provide for us a citation of where Hawking said this.
Comment: If you're talking about [QUantum foam](https://en.wikipedia.org/wiki/Quantum_foam) that is not universes poping into existence, but the quantum fluctuation of spacetime on very small scales.  So I think we really need that citation for Hawking, to see what he really said.
Comment: What is the video called? I only know Hawking's spacetime is one with a complex time. Imaginary time to account for the beginning of time. The rest is just a curve spactime evolving to present day universe. It could be that this universe is a volume in an inflating universe. Its not co-inflating so to speak. It stopped co-inflating after matter was formed. In other parts of the infinite space smaller or larger bubbles can be found. As I explained in the answer. I dony believe in it.
Comment: What is Hawking's spacetime?
Comment: I saw it on the yt video, might not be reliable I think, that you are all so unfamiliar with it.
Answer: I think you refer to the theory of eternal inflation. Space is infinite in that model and eternally inflating for some magic reason.
For some magical reason, at some places inflation comes to a halt and a universe comes into being. It seems as local bubbles appear in which inflation is much less than in the rapid expanding surroundings.
For some magical reason in all these bubble pockets the laws of physics and amount of matter can vary. So this can give rise to different kinds of bubble universes. Some last like ours, and will be taken up in the bigger picture of the externally inflating space (presumably like ours in the far future. Some will live shortly and are almost immediately "taken up" again in the whole. Only to have added a tiny amount of matter.
Note that this is a bit similar to the pyrotechnical universe but that's another road to travel.


questions about docker --link parameter

Question: As we know, in one host with docker daemon, containers connect to the docker0 bridge, and so containers can access each other by default.
Then what's the use of --link option? Is it any different with the direct access by ip way?
What does it actually do?
Answer: From the Docker docs:

When you set up a link, you create a conduit between a source container and a recipient container. The recipient can then access select data about the source
When two containers are linked, Docker will set some environment variables in the target container to enable programmatic discovery of information related to the source container.

And some more:

In addition to the environment variables, Docker adds a host entry for the source container to the /etc/hosts file. Here's an entry for the web container:

So, basically --link creates a set of environment variables and adds some entries to the /etc/hosts file in order to ease communication. But, the containers are still directly accessed via IP.
Answer: When you create a container using --link option, Docker exposes the linked container into the new one in two ways:

It creates a entry in /etc/hosts with the IP of the linked container and the alias given when creating the link.
It exposes some information as environmental variables about the linked container. As Docker documentation shows:

Docker will then also define a set of environment variables for each port that is exposed by the source container. The pattern followed is:

<name>_PORT_<port>_<protocol> will contain a URL reference to the port. Where <name> is the alias name specified in the --link parameter (e.g. webdb), <port> is the port number being exposed, and <protocol> is either TCP or UDP. The format of the URL will be: <protocol>://<container_ip_address>:<port> (e.g. tcp://172.17.0.82:8080). This URL will then be split into the following 3 environment variables for convenience:
<name>_PORT_<port>_<protocol>_ADDR will contain just the IP address from the URL (e.g. WEBDB_PORT_8080_TCP_ADDR=172.17.0.82).
<name>_PORT_<port>_<protocol>_PORT will contain just the port number from the URL (e.g. WEBDB_PORT_8080_TCP_PORT=8080).
<name>_PORT_<port>_<protocol>_PROTO will contain just the protocol from the URL (e.g. WEBDB_PORT_8080_TCP_PROTO=tcp).

It is not differences if you access via IP, but using links let setting the container ignoring the ip that will be assigned by Docker Daemon. Check Docker documentation for further information.
Answer: If you start the docker using --icc=false option, the container can't communicate to each other by default. You must use --link to connect two containers.

questions about docker --link parameter


From a traditional web based application how can I able to call ethereum network node?

Question: Let's say there is a web application running on server 18.104.22.168 ip. Peer A open this web application in his own browser.Now how he will be able to connect a ethereum node where peer B is running.Please note ip of peer A,peer B are different from the ip where web server is running i.e. 18.104.22.168.
Answer: I'd suggest you shall not make your UI directly talk to your ethereum node because its not safe to expose the node directly to UI.
however, you shall try and create a middleware in nodejs to communicate to Ethereum backend.
In nodejs middleware you can use web3js api to connect with your ethereum node.
We have recently created such middleware APIs in node.js. You can take a look at this repo for reference -
https://github.com/Imaginea/lms/blob/master/server/routes.js
The UI talks to node.js middleware and then middleware talks to Ethereum node.
Hope this helps.
Comment: "I'd suggest you shall not make your UI directly talk to your ethereum node because it's not safe to expose the node directly to UI." - There is nothing inherently unsafe in communicating directly with a node..
Comment: If any geth Node is openly accessible, then I can directly connect with it to get some information that how many accounts present, what are the balances etc. So i generally feel that it's not good to expose the node directly.
Comment: True. Exposing a node with stored accounts is foolish. I would however assume that if this user is setting up a node for a web application to interface with then he/she would not 'add' accounts to it.
Comment: It may depend on the use case, the recent project which I did had the requirement of creating an account for every new member of the app. So we had to introduce middleware.
Answer: Via embedde web3 in the client's browser. Thus, the client's browser needs web3. Best way to do it is MetaMask. In MetaMask, the user (client) can configure the node. MetaMask comes with some central nodes, so the user (client) actually does not need to setup any node.
This is how I do it, e.g. http://www.chainify.io
Answer: If you are planning to use web3 as a javascript api, you can specify url to ethereum node as a HttpProvider:
<code>web3 = new Web3(new Web3.providers.HttpProvider("http://PEER_B_IP:8545"));
</code>
If you know the ip of a client you may put the additional restriction on the Peer B server (firewall) only to accepts connection on port 8545 from the client ip.
In may also consider using Metamask browser plugin or publically available Infura node if you don't have strong security reasons to host your own Ethereum node.


Why do red LED battery operated Christmas lights dim the quickest?

Question: Sorry really ridiculous question but sure it sort of ties into the season, I recently noticed a set of battery operated LED Christmas lights I have on some garland seemed to be getting dim, upon closer inspection I noticed that it was specifically the red LED's that were dimmest, now given that energy of a photon is inverse of the wavelength and red has a lower frequency than blue photons can anyone explain why a red LED which requires less energy is not a bright as the blue LED which requires more energy (the lights are in parallel and operate at 4.5V on 3 standard AA batteries)
Comment: It is not directly related to photon energy, but to the forward voltage of the light emitting diode. The battery voltage is larger, so the current needs to be limited, probable by a resistor, possible with different values for different diodes. So it becomes an electronics question how the led current depends on battery voltage: electrical engineering.
Answer: The voltage drop of an LED is related to the band gap and the color emitted. Red is typically about 1.8V and blue about 3V (and green a bit less). Some chemistries have a bit different forward voltages (in particular green LEDs used to have a lower Vf than modern ones), but that is approximately correct.
So, what the hey, you ask, if we put a simple resistor in series with each LED the red ones would dim less than other visible colors as the supply voltage drops.
I suspect that they are putting two red dice in series for each red lamp, to get a similar brightness and similar forward voltage.
Chances are there are resistors somewhere in the circuit.
From here is a graph of Vf vs current for different LED colors.
Comment: @Pieter Sure, I'm visiting from there. It's fairly common to have two red LED dies (and one each blue and green)  in RGB leds.
Comment: That was also what I thought might be an explanation, two red leds in series. But folks at electrical engineering  would know.


Can't get it right (donut icing proportional editing)

Question:
In this video at 33:54 I m trying to use the tool but instead of the stuff he gets I get this. How do I fix it?
Comment: Welcome to BSE @TheNoob1 questions or answers based on external video links are not compatible with BSE rules, since links can change, and videos can be removed, please edit your question to be more descriptive without being totally based on video links.
Comment: please add more details of your issue
Answer: You just forgot to hide the top part of the mesh. What he does is:

Select the top part and hide it with H. It leaves a circle.
Enable the Proportional Editing option / Random type.
Select one vertex of the circle.
Drag the vertex up. As the Proportional Editing is enabled, it will randomly affect the other vertices. Increase the effect with the mouse wheel or with the parameters on the bottom of the Tools panel (on the left of 3D view, T to display).
Unhide the rest of the mesh with altH.
Answer: It seems you have proportional editing enabled and on random falloff

Just  press "O" to disable it and then you can proceed as usual
(you can also use "shift+o" to cycle through different falloff types
Answer: Use a torus to obtain a donut shape and right after you added it change its radii in the panel to the left.

The image shows the default settings, but set major radius to 1,5 and minor to 1. Subdivide the torus and apply proportional editing to faces. It seems you applied it to vertices and hence it's pointy.


Why didn't the Japanese cut the ropes in Hacksaw Ridge?

Question: In Hacksaw Ridge the Japanese just let the American soldiers climb up and there appeared to be no defence. The American soldiers were absolutely safe once they climbed down the ridge. The Japanese could shoot since they occupied a higher elevation. So why didn't they cut the ropes?
Answer: Keep in mind the movie is based on true events and there can be all kinds of reasons they didn't cut the ropes given the chaos of war and strategic motives of the different sides.
The Battle of Okinawa is known to be one of the bloodiest battles of the Pacific War and the key attack points were the beach and the ridges. The movie makes it seem like the rope ladder was abandoned and left with two guys to guard it at certain points. I find this highly unlikely. If the US took the time to put a mesh rope ladder up, they would leave enough forces to defend it. Any Japanese soldiers that came close enough to the ridge to attempt to cut it would have been gunned down. That said, its very possible that they DID attempt to cut the ropes down and its very possible that they succeeded in some of these attempts.
Ultimately, whether they attempted to cut the ropes or not is a detail not important to the movie's plot.
We are meant to suspend our reality and assume that if any attempts were made to cut the rope, they either failed or were remedied by putting it back up.
Answer: According to the true story the Japanese wanted the Americans close to their hideout for tactical reasons. I guess that is part of the reason why they didn't cut the ropes. Another reason could be the exposure to the heavy artillery at sea. Also, according to the true story Desmond Doss was one of the volunteers to climb up and attach the ropes (not depicted in the movie). So it was mounted by the Americans, not the Japanese.
Comment: Welcome to Movies & TV! We're looking for long answers that provide some explanation and context. Don't just give a quick unsupported answer; explain why your answer is right, **Ideally with citations or quotes/extracts**. Answers that don't include explanations may be removed.
Answer: You can find the answer in many accounts of the specific battle and I recommend watching the documentary on Doss, The Conscientious Objector.  It is true that Doss was one of the ones tasked with securing the nets in the first place.
The ridge is much shorter than depicted in the movie and the terrain below it is far from flat so Japanese positions on the hill had a clear view of American movements all the way down to the landing zone.  The only time that American troops could not be seen was right at the base of the ridge.
According to survivors anyone sent up to the top of the ridge for reconnaissance prior to securing the nets that was shot and killed.  However, in accordance with Japanese tactics at the time, once it was clear what the Americans were doing, the Japanese soldiers waited until a concentration of troops had made it to the top before they opened fire.  This was to ensure the maximum amount of casualties and that's pretty much what they did every time the Americans tried to secure the ridge--up to eight or nine times.
As long as those nets remained, the Japanese suspected the Americans would keep using them and putting large numbers of troops right in their line of fire.  Though not always followed, this strategy was used in the hopes that the Americans would get tired of the fighting and offer a negotiated peace.  Instead it convinced the US that an invasion of Japan would be too costly and the atomic bomb should be used instead.  For what is probably the most comprehensive view of the battle from the Japanese perspective, I suggest The Battle for Okinawa by Colonel Hiromichi Yahara.
Answer: Simple answer the Japanese built that rope latter to get on the hill. However that hill is one way up and down whatever food and supplies the Japanese would get came from the rope so they can't cut it since that is there supply chain. Also why cut the rope if it's a one way up and down. It's make it easy for ambushing since you have the exact location that the enemy forces are coming from. This is all what war is ambushing and counter ambushing.


Alternative to downthemall

Question: i used to download updates via synaptic mark all upgrades then save script because the internet is too slow here then open the generated file by firefox then i used downthemall manager to download all deb packages. Now downthemall no more availabe. Is there another way to download updates in the same way?
Answer: You can download them using wget or curl, Synaptic Package Manager generates a shell script that you can execute in any GNU/Linux system.

Here is the generated script:

If you're downloading these packages from a GNU/Linux based system, you can download all the files by using:
chmod +x generated-script.sh
./generated-script.sh
But if you prefer a browser plugin, then I recommend you to search here: https://addons.mozilla.org/es/firefox/
Maybe this downloader could be useful for you: Elite Download Manager
Hope it helps.
Comment: Yes, you can resume the download, the `-c` flag is for continue, you can verify it on the manual pages [here](https://www.gnu.org/software/wget/manual/wget.html#index-resume-download), but, If you're talking about the web browser plugins, in that case, this tool has its limitations, so I recommend you again to use the shell script.
Comment: In this way i cannot resume and continue the download later
Answer: uGet is a lightweight and very powerful download manager application. You can install uGet in all currently supported versions of Ubuntu with this command:
sudo apt install uget

There is an option in the uGet settings to always show a uGet system tray icon in the notification area of the panel to the left of the clock and volume icons.
Features

Resume downloads  – If your connection is interrupted, you can start right back where you left off with download resuming. (not guaranteed, it's server controlled and cannot be bypassed by a download manager)

Queue downloads

Classify downloads in categories

Batch downloads

Multi-Protocol – support for downloading files through HTTP, HTTPS, FTP, BitTorrent and Metalink

Clipboard monitoring

Import a list of URLs to download via .txt or .html files ✅

uGet also can be launched from the terminal with the command: uget-gtk
Comment: Generate a download script in Synaptic and then open the script in a text editor and remove everything except for the hyperlinks. The finished file must contain nothing but a list of links and each link needs to be on a separate line. Save the edited file as a .txt file.
Comment: How can i generate  a txt or html file to import the list?
Answer: You can use DownThemAll! installing it in another browser that supports it, like Waterfox, an open-source fork of Mozilla Firefox, that can install all Firefox extensions.
I described it in a video (https://youtu.be/OQ--UyyWbx8) on YouTube (in Italian language, but it's simple to follow the steps that I've done on my PC. In that case I'm using Linux Fedora 26 XFCE x64, but you can do the same under Window or MacOS).
Cheers

Alternative to downthemall


Access 2010 Query counts double

Question: all.
I've put together a very simple budget database in Access 2010. When I ran a query to find the sum of expenses in each category, I found the following results:
In some instances, the amounts added-up. I.e. I spent $240, and that's the amount returned.
In one case, the amount returned was double the amount entered. When I changed "Sum" to "Group By" in the query design module, it returned 6 records that added-up to half of the amount I found with "Sum." When I changed "Group By" to "Count," it returned the value 12.
In other case, I had similar results. However, in that category, I would find 33 records using "Group By," but when I used "Count," it returned the value 40.
Here is my SQL:
SELECT tblType.typName, tblCategories.catName,
Sum(tblEntries.entAmount) AS SumOfentAmount,
tblBudgetParameters.budAmount
FROM tblVendors INNER JOIN (tblType INNER JOIN ((tblCategories INNER
JOIN tblBudgetParameters ON tblCategories.catID =
tblBudgetParameters.budItem) INNER JOIN tblEntries ON
tblCategories.catID = tblEntries.entCategory) ON
tblType.typIncomeExpenditure = tblEntries.entType) ON tblVendors.venID
= tblEntries.entVendor
WHERE (((tblEntries.entDate) Between [Enter Start Date] And [Enter End
Date]) AND ((tblBudgetParameters.budExpired)=False))
GROUP BY tblType.typName, tblCategories.catName, tblBudgetParameters.budAmount;

How do I find out what is doubling and how to fix it?
Thanks,
-Rob
Answer: Try eliminating tables one by one and get a count to find out which table is giving you the duplicates. For example:
SELECT tblVendors.VenID, Count(tblVendors.VenID)
FROM tblVendors
INNER JOIN tblEntries
ON tblVendors.venID = tblEntries.entVendor
HAVING Count(tblVendors.VenID) >1

Access 2010 Query counts double


How to determine volatility for private company for Black-Scholes

Question: I am trying to determine the volatility to use Black-Scholes to value some warrants for a private company. Very few comps are public or they are large diversified businesses.  Any thoughts on how to do this or ranges to start from?
Thanks
Connie Dubois
Comment: You are facing a similar issue than this post:
http://quant.stackexchange.com/questions/20721/how-to-compute-the-volatility-for-the-mertons-model-for-private-firm/20722#20722
Answer: There is an easy method to calculate volatility if you have a historic time series of price data. First, obtain the standard deviation of the log returns.

Imagine you have these observed prices,

{30.00, 31.70, 27.38, 27.50, 23.96, 23.30, 30.63, 24.04}

Calculate the log return,

ln(31.70/30.00), ln(27.38/31.70), . . . ln(24.04/30.63).

Calculate the standard deviation of the series,

sd = 0.07325

Keep in mind that this is a simple method, and it does not allow for skewness or kurtosis in the frequency distribution of returns, but neither does the Black-Scholes option pricing model.
Comment: As he said it is a private company ...