Salesforce DX setup

Question: I am looking into setting up SFDX and one of the first things is to enable Dev Hub in the production org. We are external consultants and I want to verify the impact this will have on the org. The customer is still using classic screens and I do not want to affect them.  I am also unfamiliar with the concepts regarding 2nd generation packages. Does anyone have a recommendation for the best place to read about it?
Comment: This is really 2 questions. I might suggest taking the 2nd generation package questions out of this and adding a new question. Here's a good guide on asking a question: https://salesforce.stackexchange.com/help/how-to-ask
Answer: Turning on Dev Hub doesn't have any other effects on Production, saving the most edge of edge cases (e.g., if something reacted poorly to the mere presence of the objects that track scratch orgs that are created). However, you can't turn it back off.
See Enable Dev Hub in Your Org:

Enabling Dev Hub in a production or business org is completely safe and won't cause any performance or customer issues. Dev Hub comprises objects with permissions that allow admins to control the level of access available to a user and an org.

Users won't see those objects unless they have permission to, so the only negative outcome I can even speculate about would be an integration running on a user account that does have permission to see scratch org records and which has some undesired behavior when it sees a new kind of sObject.
There is a Trailhead module providing an introduction to unlocked packages.
Comment: Here's a blog post that discusses Unlocked Packages. It is the first of a planned series. They are intended to create a structure for modularizing code no matter who is writing it. https://developer.salesforce.com/blogs/2018/06/working-with-modular-development-and-unlocked-packages-part-1.html
Comment: I've enabled DevHub on 4 production orgs we have few months ago and zero impact to the end user. I was under the impression that 2nd Generation packaging for the ISVs.
Comment: @SLman 2GP (now called Unlocked Packages) are intended for everyone.

Salesforce DX setup


Nav2 makes obstacles where there are none

Question: I'm using Jammy and Humble and Nav2. The robot is beginning to do waypoint following and driving on his own. However, sometimes the Nav2 program is making black dots, as obstacles, appear where there were none on the map provided. The area was clean white. The floor is carpet, and apparently the laser is seeing something? It's a Velodyne puck, and I understand only one scan laser is in use in Nav2, of the 16 in the unit. Is there a setting I can adjust to stop the mapping/navigation from finding and developing these obstacles in robot's way?
Answer: check your sensor outputs for noise. Things don't just appear without reason. It might be necessary for your to lightly filter the output of your sensor data if you're noticing erroneous measurements that are causing a problem. The laser filters package might be useful for you to look into and are commonly used to model and remove common sources of laser scanner noise.
http://wiki.ros.org/laser_filters
Comment: Thanks, Steve. Is there a setting on Slam Toolbox that would help the Velodyne overlook the two antenna that are in its way? If we could set a minimum distance to actively scan, say? I wonder if these are bothering the lidar? I noticed that the trouble decreased when I reduced scan rotation from 600 to 300 rpm. Where is this laser filters package you speak of? In Nav2?
Comment: Check out the laser filters. I believe one there will do it for you with configuration.


Generate signal with sinusoidal change of frequency

Question: What is the mathematical formula to generate a sine wave, which changes its period sinusoidally?
E.g. a sinusoidal signal, with sinusoidal change of frequency.
Comment: It might be better to ask this on the Math.SE site. They have MathJax over there that will make it easier to write mathematics.
Comment: Basically, you're looking for y=sin([sin(ax)+e]x). You have to play with the constants a lot to make it work the way you want.
Comment: I'm voting to close this question because it's a question about a mathematical formula which is off-topic.
Answer: I'm presuming you mean something like this (the blue waveform): -

The red waveform is amplitude modulation and the blue waveform is frequency modulation.
This should be the formula you need: -

y(t) is the FM output
fc is the unmodulated carrier frequency
f(delta)/fm is the modulation index - see this wiki article
fm is the modulating frequency
t is time


How to Continue a Line Feature in QGIS?

Question: I'm looking for a way to continue a line feature in QGIS. I have checked  the Digitizing Tools plugin (both regular and advanced) for a Prolong Line tool, but I haven't had luck. In ArcGIS there's a Continue Feature button when editing but I haven't found one so far in QGIS. I'm looking for a way to do this while editing/digitizing rather than through code. Can this be done?
Comment: Use the Node Tool http://gis.stackexchange.com/questions/41663/editing-polylines-in-qgis-extend-trim-fillet-etc
Comment: QGIS 2.16 Extend Line Tool http://changelog.qgis.org/media/images/entries/52726f3b8cd8b62d63a32b9628dd8d3cef53172c.gif
Comment: Good to know that Extend Line comes out in the next version, I'm looking forward to working with 2.16.
Comment: QGIS 2.16 is available here http://qgis.org/en/site/forusers/download.html
Answer: In the next release (8 july 2016) this wil be fixed.  Have a look at http://changelog.linfiniti.com/en/qgis/version/2.16.0/
There you can read:

Feature: Extend linestring geometries with reshape tool
The reshape tool now allows you to extend linestrings, by starting a
  reshape at either a line's start or end point.
This feature was developed by Martin Dobias

Untill then you can do what Mapperz suggests
Answer: In QGIS 3.4 (and probably before that), you can use the 'Vertex' tool (which is next to 'Add line' on the toolbar, by default). Choose it, then hover the mouse over the ending or starting point of a line, and you'll see a plus symbol next to it—this allows you to continue the line. Similarly, it allows you to add a new point between other two by hovering the cursor there and clicking on the plus symbol that appears.
Comment: This is already answered elsewhere but now I landed here from a repeat web search—so I guess I'll leave the proper answer for when I forget it again.
Answer: The Digitizing Tools plugin has to amend line function
https://github.com/bstroebl/DigitizingTools/wiki/Usage
Prolong line
applies to: line layer (multi or single part)
Continue editing existing online features. Just click any end point of an existing line and digitize new vertices as if you would digitize the new feature.
Comment: This appears to do what I want it to based on the description, however I'm searching for what the icon looks like. I do have Digitizing Tools enabled, but I'm having trouble finding the tool. I'm using 2.14.0-Essen, if that's helpful.
Comment: @RachelW I am looking for the same!
Comment: Cant find this...
Answer: In QGIS3.x, you can use advanced digital tools. You could set 'parallel' mode, then click the line you want extend.there will appear a dashed line along the former line like what in AutoCAD.
Of course, it's still slow and stupid. But the method doesn't depend on any third party plugins.
Comment: Getting this to work in 3.12 is tricky for me. I can only get it to work if I click 'Reshape' -> click on the line endpoint -> toggle/click Parallel on the Advanced Digitizing tools -> then click back on the line endpoint again. But it works.

How to Continue a Line Feature in QGIS?


Would two 70 pint dehumidifiers work as well as one 140 pint unit?

Question: If so why are dehumidifiers above 70 pt so much more expensive? pros cons? Having two 70 pt in same room vs 1 140 pt?
Comment: I would anticipate two dehumidifiers to be more effective than one with an equal capacity. Why? Surface areas would be the primary reason. Not to mention they can be placed in two affected areas vs. only one. However, now you are spending more energy to drive two compressors instead of one. Bigger is sometimes better, but when you use more metal, more coolant, more engineering to fit more in a smallish package, prices go up. Supply and demand would also play a role. Ultimately the manufacturer is going to push the product they can sell more of, more often.
Comment: I'd suggest breaking this into multiple questions; as it is, it's hard to answer, and removing the question about why 140 pint humidifiers are more expensive.
Comment: Do you have any interest in air conditioning the space?  An air conditioner is simply a dehumidifier with different ducting on the hot side (the side that does not matter to water removal).
Comment: 1. yes ... 2. see #1 ... 3. unclear what is being asked ... 4. also unclear
Comment: Hello, and welcome to Home Improvement. Unfortunately, without studying the supply chain and consumer demand, we can't answer your first question. And, the second question is probably convenience; do you  want two loud boxes in your room, rather than one?
Comment: @DanielGriscom I get that, I'm just wondering as an end user is there any advantage such as less heat output or units above 70 pt are simply overpriced because of low demand?
Comment: @UnhandledExcepSean that would make more sense...
Answer: You crossed the line into industrial
I immediately noticed that a search for 70 pint dehumidifiers yielded the usual consumer tier listings... Target Walmart CostCo Home Depot etc. Different deal for 140pt. It gave my local heating /cooling contractor, damage response companies, and industrial suppliers.
So you have made a qualitative leap. From Yukon to Humvee.  This also affects what the customers are looking for.

The consumer product wins when you put it in your cart, what happens afterward hardly matters.   The industrial product wins then it has lowest total cost of ownership.
the consumer unit is built no tougher than it needs to be to be parked in a corner for five years. The industrial unit is designed to be dragged around to job sites every day.
the consumer unit is absolutely designed to work on lowest common denominator mains power,  probably 120V at 12A max.  The industrial unit,  all bets are off. It's assumed a lot of equipment will be in use at that job site,  and someone will be managing electrical loads.
it is also assumed that very dirty power will be on that job site, possibly from a generator,  and so the unit will be built for that, and also will have no compunction about creating dirt on the lines.
as part of the "total life cycle" mentality, the industrial unit will be repairable for considerably less than the cost of a new one. This maintenance may be required.   The consumer unit, into the trash it goes.
industrial units are often deployed with pusher fans to circulate humid air to the unit, so one unit can service a large area. It is sized for that. A consumer is unlikely to do such engineering or desire it.
the consumer unit factors for consumer sensibilities in style, efficiency and noise.   The industrial unit, nope.

These factors, rather than cost, should guide your decision.
Nothing wrong with arrays of cheap expendables;  Google won the search business using numerous cheap beige box PCs while competitors used top tier DEC and Sun systems. Google was forced to learn to adapt to constant hardware failure.
Comment: The consumer product will be designed for a maximum noise level based on consumer perceptions. The industrial product will be designed for maximum noise level based on OSHA requirements - and not one decibel less!
Comment: As far as Google adapting to HW failure - yes, they did. In the end they came out way ahead. I suspect (from casual reading, not real research) that Google learning to adapt to 'x' % hard drive, motherboard, etc. failures where 'x' > 'y' of top tier machines, paid off when they scaled to thousands of machines per data center where **any** brand will have some number of failures and Google is able to manage the problem well. A lot of hosting companies (except the one I mainly work with - partly due to their efficiency in handling the inevitable occasional failures) still haven't figured it out.
Answer: I would opt for 2 units for several reasons, but the reasons that the 140 pt dehumidifiers are more expensive is they usually require wheels and handles some have pumps that the smaller units don't have.
Why would I opt for multiple units, a room is a fixed area de humidifiers can only draw the moisture out of the air if the air is available, for example, having a large bonus room down the hall from our kitchen and dining area, if we only use a dehumidifier in the large bonus room the dining area will be very humid and the bedrooms even further away will be worse at night. What we had was 2 smaller units 1 in the bonus room and one in the dining room since it had more space and was closer to the bedrooms, this worked quite well (a whole house system was not an option because the bonus room was on a different system than the rest of the home).
So for more effective moisture removal having smaller units at multiple locations is better. The cost is reduced because the lighter units are easier to carry or move around, as far as noise I find the fans that move the air are the majority of the noise on the units I have had with out air movement the units won't do much good so the larger units have much larger fans trying to move the air.  So depending on the layout of your home I would suggest smaller units, even with open layout having smaller units at opposite ends of the area will function better , be quieter and less expensive, the con for 2 units now you have 2 water buckets to empty.
Answer: I would opt for the 2 dehumidifiers over the 1 just due to the noise that the single large unit produces. My neighbor has one of those large dehumidifiers which is rated near the 140 pint/day you asked about and it is extremely noisy, was very expensive, and takes up a lot of floor space. While the water removing capacity would be about the same, those large units are usually very expensive to buy or replace. "My 2 cents"


Cash reward for help retrieving my 0.5 bitcoin

Question: Mainly due to utter curiosity I purchased 0.5 bitcoin in 2013 and I have a piece of paper with 3 different passwords on. however, I've recently opened the wallet I had the coin in, but nothing shows up! Neither does it ask me for a password?  I've searched around for knowledgeable individuals who can guide me - in very layman terms - as to what process I need to go through in attempting to retrieve this 1/2 coin. As I'm very much in need of getting rid of the 1/2 coin I shall be more than happy to financially reward any person who can successfully retrieve it.
Comment: Welcome to Bitcoin SE.  Just so you are aware, this is not a site that acts as a job board, where you can offer money in exchange for services.  In fact, that is likely to get your question closed.  I recommend you re-word this question to remove your offer of a "cash reward" in exchange for help.  People here are likely to point you in the right direction anyways.
Answer: First off: DO NOT send those exact passwords to anyone offering help. Having those passwords may allow them to access and steal your coins.
If you open your wallet and see a zero balance, that is probably not a good sign if you haven't moved the coins yourself. Look at the history of transactions, and see if there are any that moved the coins to a new address. You need to figure out if the bitcoin has been moved to an address that you no longer control.
Comment: The Bitcoin ledger has grown *a lot* since 2013: it will take you a while to download the whole thing (= synchronization). If you want to spend your 0.5 BTC without downloading the entire ledger, you will need to import your private keys into an SPV wallet (*e.g.* electrum). So, it seems that your priority is to find out what your private key[s] is/are, **without disclosing them to anyone else**. If the passwords that you wrote down are passwords for unlocking your full-node wallet, then you should be able to extract your private keys from that wallet while safely unplugged from the internet.
Comment: first para - good alert.
Comment: I've checked the history of transactions and no other addresses are showing up. I will not send any password info to anyone I'm just not sure how to go about searching into my hardrive or anywhere else as to where the actual data is that will make my coin appear in the wallet.
Comment: What addresses do show up when you check transaction history? Check them on blockchain.info to confirm the balances.

Wallets do not work by 'hiding some addresses until you enter the right password'. So if your software is properly synced and displaying a balance of 0, chances are your balance is 0. What software are you using?

What is the format of the passwords? DO NOT send the actual passwords, just give a general description of them (eg: a mix of numbers, letters & symbols, or just numbers and letters, or just numbers and dashes, etc). Perhaps one of them is a seed, not a password
Comment: That's interesting regarding the wallet being properly synced. It's showing up as out of sync and as I've not opened it since 2013 its showing "synchronizing with network ", and saying ive just over 168,000 blocks remaining. Software is "Bitcoin version v0.8.1-beta. Only 1 address shows up and I've checked it with blockchain but it shows no coins.
Comment: You see this is my whole problem. What your saying makes very little sense to me. My last straw was to appeal to someone very honest and knowledgeable out there to help me in doing the necessary to retrieve, if possible, this coin without the act of myself deciphering terms such as "full node wallet and private keys ". I have no clue where to go with that. You are obviously aware of these technical terms and how to apply them in attempting to retrieve what could possibly be or not be there and that's why I'm very willing to handsomely reward the person who can guide me in very layman terms.
Comment: @Chris, this stack exchange site is where you "go for that" :)  Bitcoin is NOT something that should be taken on by those who are unwilling to learn about it.  I don't mean to sound harsh, this is exactly how people have lost huge sums of money.  If you are serious about retrieving your investment, I don't see any excuse for not *learning* about that investment.  This site is a wonderful resource for learning, but you have to be willing to ask the questions...not just ask for someone to do it for you.
Answer: Chris,
Did you go to blockchain.info and copy/paste the public address of your wallet into the search box in the top right-hand corner of the screen?
This will let you see the amount of bitcoin assigned to that address on the blockchain itself, so you don't have to wait to download the entire thing. If you have done that and it shows zero bitcoin we probably have two scenarios; theft or its the wrong public address for the wallet. If it does show your 1/2 BTC in there you will need the private address to import it. I'd recommend opening the account in blockchain.info, since it just references the blockchain instead of making you download it. If you have a blockchain.info accoutn you can import your 1/2 BTC wallet using the private address at this location... Settings -> Addresses -> + Import Bitcoin Addresses -> Import Address -> put the private key in the box -> Import -> Close
Answer: The information provided is quite vague so I will provide my assumption as to how to resolve it. It sounds as if you have a paper wallet. Paper wallets have a public/private key pair. In your post you mentioned a third piece of information which might be the seed of the wallet.
First step, search the public key on a blockchain explorer (blockchain.info or tradeblock.com are good choices). There you will see all transactions associated to the wallet.
If the balance is 0.5 then it is just a matter of importing the key pair into a wallet (this can be done through the mycelium wallet). You can also YouTube how to sweep a paper wallet for more information about importing the key pair.
If this answer doesn't help then you need to add more information about the paper that you have: how long are the "passwords", are they a combination off all characters, are they words or public/private keys.


Why is "This program cannot be run in DOS mode" text present in .dll files?

Question: Recently I opened a .dll file produced by Visual Studio 9 while compiling a native C++ DLL project and was surprised to see the "This program cannot be run in DOS mode" text near the beginning.
Why have this text in .dll files?
Answer: A dll is very much like an executable with a different extension. The text you saw is part of the 'standard' executable header on windows. It is (was) used to gracefully abort the attempt to run a windows executable from DOS.
Answer: The Portable Executable format specification states the following:

The MS-DOS stub is a valid application that runs under MS-DOS. It is
  placed at the front of the EXE image. The linker places a default stub
  here, which prints out the message "This program cannot be run in DOS
  mode." when the image is run in MS-DOS. The user can specify a
  different stub by using the /STUB linker option.
At location 0x3c, the stub has the file offset to the PE signature.
  This information enables Windows to properly execute the image file,
  even though it has an MS-DOS stub. This file offset is placed at
  location 0x3c during linking.
Answer: Win32 programs run from DOS mode (ie, single user, no graphics) print that text.  DLLs probably print that message too if you try to use them without Windows running.


Is concept of Bipartite Graph relevant only for Connected Graph?

Question: Is concept of Bipartite Graph relevant only for Connected Graph?
For Example :
4 vertices and just 2 Edges i.e. one from node 1 to node 2, and the another from node 2 to node 3.  So, is this Disconnected Graph also a Bipartite Graph? Or Bipartite graph deals with Connected Graphs only?
Answer: A bipartite graph only requires that the vertex set can be partitioned into two disjoint sets, say $A$ and $B$, such that every edge in $E$ connects a vertex from one of the sets, to the other. You can have isolated points. If one denotes the bipartite graph by $(A,B,E)$, then formally you will have a different bipartition depending on if you place an isolated vertex in $A$ or in $B$.
Comment: So, the one example I mentioned in the question is a Bipartite Graph, as it have one isolated vertex.
Comment: @RudrakshaBaplawat Yes. Let node $1$ and $3$ be in vertex set $A$, and node $2$ in $B$, then place node $4$ in whichever you wish.
Answer: No, the definition works perfectly well for a disconnected graph. A graph is bipartite if and only if each of the connected components is bipartite.
Comment: and since an isolated vertex is also a Bipartite graph, the example I mentioned above is Bipartite.


need to download from eMule on linux

Question: i have a dedicated ubuntu server and would like it to download files from emule....but it has no gui.
i am looking for a command line tool like rtorrent but that handles e2dk links.
Answer: Check for AMuleCMD.
Another option would be to connect to the server with ssh -X, and use the amule GUI remotely - but that way you will need to keep the connection open.

need to download from eMule on linux


Custom Namespace on .NET web app

Question: So I wrote some custom classes and put them all in a namespace, call it "Sphere".
On my aspx.cs codebehind file, I have "using Sphere;" written. I know that this works because it's always worked until I copied this project to a new folder. Also, even when I click "view in web browser" everything works perfectly.
Simply, Visual Studio 08 is not recognizing the namespace and so I cannot build without an error and consequently cannot debug. Thanks for the help!
edit:
I have my namespace in my App_Code folder in a .cs file
Answer: Are  your custom classes in a separate project? If so, you might need to add a reference to that project. If you have copied the project to a new folder, the path to your Sphere DLL/project in VS2008 might be broken.
Comment: I just have the namespace in a .cs file in my app_code folder
Answer: I actually just figured it out:
My .cs files were set to "build action: content" rather than "compile." I right-clicked + properties all my files and changed the build action, and now it all works!
Comment: Please change the question title because this really had nothing to do with namespaces.
Answer: Check your references. It's possible VS is no longer finding them after you moved your application's folder.
Answer: Sounds like missing reference.
In your new project, do you have a reference to the project that defines the actual Sphere namespace?
Answer: It sounds like when you moved the files the references were broken. If the sphere classes are in a seperate dll try deleting and re-adding the reference. If it is just in a .de file be sure that filein the project is still in the relative path.
Answer: Probably you got this error:

The type or namespace name 'CustomClass' could not be found (are you missing a using directive or an assembly reference?)

And the reason the type was not in the assembly is that App_Code folder is specific folder for Web Site Projects. These files get compiled at runtime when they are deployed on server and not when you are building the project.
In Web Application Project every file has Build Action property. By default the classes files have value of Compile. But if the class is created in App_Code file it gets value Content. and does not get compiled when running as Application.
A the end the App_Code folder is not meant to be used in Web Application. Or as you figured it out you can manually change the Build Action to Compile.
I found the answer by searching these links:

Vishal Joshi's Tangent - App_Code folder doesn't work with Web Application Projects (WAPs)
Build Action" property set to "Content" for class files inside App_Code folder

Custom Namespace on .NET web app


Why do the poles and zeroes of a transfer function cause a slope change in frequency response?

Question: Why is it that as the frequency approaches a pole or zero of a system, the slope of the magnitude of the transfer function changes by 20dB/decade?
Whenever I see this stated when reading about transfer functions, it's never explained. What causes this property of transfer functions?
Answer: Have you read about roll-off? Wikipedia has a great explanation of this topic. Basically when you have a pole or zero of a system, you are representing, in this case, the transfer function of a circuit:

To express the magnitude in decibels of the system on a frequency point you use this equation:

Or expressed as a loss:

At frequencies well above ω=1, this simplifies to:

Now, if you want to know the difference in decibels between to frequencies, you may have to use the same equation but this time using (ω2/ω1) in the logarithm.

If the difference here is a decade, or a frequency ten times ω1, the logarithm will be always equal to 1. Then you multiply this result with 20 because of the fifth equation, then you have:

That's it! Maybe you really want to know another reason besides the one I gave to you, but it is explained mathematically.
Answer: This is just a result of the definition of poles and zeros of a transfer function.  A transfer function in the Laplace domain is written as
$$
H(s)=\frac{b_ms^m+...+b_2s^2+b_1s+b_0}{a_ns^n+...+a_2s^2+a_1s+a_0}
$$
By factoring the polynomials (which is often not easily achieved by hand) you can rewrite this as
$$
H(s)=\frac{(s-z_1)(s-z_2)...(s-z_m)}{(s-p_1)(s-p_2)...(s-p_n)}.
$$
This form is what defines the poles and zeros; the $p_i$ are the poles and the $z_i$ are the zeros.
To see how this leads to the 20 dB per decade rule, lets consider a concrete example:
$$
H(s)=\frac{(s-1000)}{(s-10)(s-100000)}.
$$
I've intentionally spread the poles and zeros very far out to illustrate the point.  When $s\ll 10$ (i.e. $s$ is much smaller than all of the poles and zeros), then this reduces approximately to $H(s)\approx\frac{1000}{10*100000}$ and the transfer function is flat.  When $s\sim100$ (i.e. much larger than the first pole but smaller than the zero) this becomes approximately $H(s)\approx\frac{1000}{s*100000}$ and the transfer function is falling at 20 dB per decade.  Upon crossing the zero, at say $s\sim10000$, the transfer function becomes approximately $H(s)\approx\frac{s}{s*100000}=\frac{1}{100000}$ and the transfer function is again flat.  Finally for $s\gg100000$ the transfer function becomes approximately $H(s)\approx\frac{s}{s*s}=\frac{1}{s}$, and it is falling at 20 dB per decade again.
Honestly, the best way to get a feel for this rule is to simply plot a number of transfer functions.  There is an online tool here which allows you to type in an arbitrary number of poles and zeros to see how the Bode plot looks.  The plot below shows its output for the example I described above except that it sets the DC gain to 0 dB.  The 'asymptotic plot' is the approximation that I've described above, and the 'real plot' is the actual Bode plot of the transfer function.


Minimization and gradient descent

Question: I am bit puzzled by using gradient descent method.
My doubt is that gradient descent is an iterative method for finding minima/maxima of a cost landscape. And it uses steepest ascent/descent method. But on the other hand setting my gradient vector equal to zero vector I should have got my optimal point. Then why to use gradient descent??
Comment: I think it's best to think of a classical parabola. If you are far away from the optimum the large gradient pushes you fast towards the optimal point. If you are in the vicinity of the optimal point, the gradient descend is a good guess on how close the real optimum is. The method should converge in the optimal point and there the gradient is zero.
Comment: Thanks Quickbeam2k1 for reply. I think I am not able to explain you problem well.What you said is true. My doubt is why we need gradient descent. Knowing the equation of parabola and setting its first derivatives to zero I should get optimal points. Isn't that true?? So whole point I want to make is that what is need of gradient descent method??
Comment: The gradient method is just a different method that can work. Furthermore it can be applied to higher dimensional problems (and if i remember correctly even to implicit defined ones). Of course for the parabola the calculation is easy. But what would be the extremum of e.g $e^x +x \log(x) -x$. This is hard to calculate by hand (if not impossible)
Comment: Okay !!! I got your point . Thanks
Answer:
setting my gradient vector equal to zero vector I should have got my optimal point.

More precisely: setting the gradient vector equal to zero vector and solving this  equation you would find a critical point.
One equation between vectors in 2 dimensions is actually a system of 2 equations. Those are in general nonlinear (unless your landscape happens to be a second-degree polynomial, which I doubt). To solve such a thing with algebraic manipulations is unlikely. One would have to use some numerical method for solution, which is probably going to be iterative itself.
In addition, equating the gradient to zero could give you a maximum or a saddle point. The gradient descent is more likely to approach a minimum, though it may be fooled by a saddle point sometimes. One still has the issue of figuring out whether the found minimum is  global... but this is an issue for every method.

Minimization and gradient descent


Select A Rendering Not Recognizing Allowed Controls From Placeholder after App Pool Recycle

Question: I'm experiencing an issue in Sitecore 9.0.2, Lucene index, and 10.2, Solr index, where some, but not all, of our placeholders in Experience Editor are not recognizing the renderings inside the Allowed Controls and produce the below version of Select a Rendering rather than the listing of all allowed renderings.

Typically I'll uncheck the "editable" box, save it, recheck, save it again, and then our list of renderings appears in the Add Component Select a Rendering window. Resaving the item only works until the next app pool recycle though at which point we'll receive the above Select a Rendering window.
Currently we use Unicorn to handle syncing and tracking of our placeholder items, however, I've removed them from Unicorn's watch list and still have the same issue after an app pool recycle.
Any suggestions would be greatly appreciated as I'm running out of ideas. At first I thought it was a Lucene issue. Unfortunately, our current upgrade has proved otherwise as a fresh install of 10.2 (with our code applied) using Solr is producing the same issue.
Answer: We went ahead and created a new Placeholder item with the same placeholder key and the issue no longer exists.


How to derive the equation for fixed-pinned beam?

Question: I have a problem in finding the reaction force of the pinned-fixed structure. If I take moment at both ends, the reaction forces at A and B should be the same and the answer is wrong. How to derive the reaction forces and the bending moment?
Answer: A shorthand calculation of the left-hand moment is:
We first consider a fixed-fixed beam loaded at the center with P.
The fixed end moments are
$$M=-PL/8$$
Now we release the moment at righthand support returning it to pin support with zero moment,$M_B=0.$
We know half of this moment, $1/2(-PL/8)= -PL/16 \ $ will be transferred to the lefthand support, $A.$
$$\therefore \  -PL/8+(-PL/16)=-3PL/16$$
That is the moment you have in your question. I used sign convention as a positive moment creating tension on the bottom fibers, but it doesn't matter!
Comment: I like this. It feels like a very simplified version of the Hardy Cross (moment distribution) method.
Answer: A slightly more convoluted (but completely general) procedure is to work out the differential equations given by Euler-Bernoulli beam theory.
The first step is to replace all unknown reactions (the fixed support at A in this case) by an equivalent unknown load that will be treated sepparately. This can be done because the beam in question is considered linear elastic.
In this case your system becomes as follows

Now you proceed to determine the support reaction and bending moments for both these systems. Since both are simple isostatic cases I'll just state the results.
$$
M_1(x)= \begin{cases}
\frac{P}{2}x & \text{if }x\leq\frac{L}{2}\\
\frac{P}{2}x - P(x-\frac{L}{2}) & \text{if } x> \frac{L}{2}
\end{cases}
\qquad M_2(x)=\frac{M}{L}x-M
$$
Now, for a beam with constant elastic properties $E$ and $I$ you can write the curvature as
$$
\varphi(x)=\frac{M(x)}{EI}
$$
Ane Euler-Bernoulli beam theory tells us that
$$
\theta(x)=\int\varphi(x)\,dx \quad \text{and}\quad v(x)=\int\theta(x)\,dx
$$
This is technically the solution to a $2^{nd}$ degree ODE, but it's so simple it can be solved by direct integration. Results for deflection $v(x)$ are stated below
$$
v_1(x)= \frac{1}{EI} \begin{cases}
\frac{Px^3}{12}+C_ax+D_a & \text{if }x\leq\frac{L}{2} \\
\frac{PLx^2}{4} - \frac{Px^3}{12}+C_bx+D_b & \text{if } x> \frac{L}{2}
\end{cases}
\qquad v_2(x)=\frac{1}{EI}\left(\frac{M}{L}\frac{x^3}{6}-M\frac{x^2}{2} +C_2x+D_2\right)
$$
To find the integration constants we have the following conditions
$$
v_1(0)=0\qquad v_1(\frac{L}{2}^-)=v_1(\frac{L}{2}^+) \qquad \theta_1(\frac{L}{2}^-)=\theta_1(\frac{L}{2}^+) \qquad v_1(L)=0 \\
v_2(0)=0 \qquad v_2(L)=0
$$
Solving for these constants nets you
$$
v_1(x)=\frac{1}{EI} \begin{cases}
\frac{Px^3}{12}-\frac{PL^2}{16}x & \text{if }x\leq\frac{L}{2} \\
\frac{PLx^2}{4} - \frac{Px^3}{12}-\frac{3PL^2}{16}x+\frac{PL^3}{48} & \text{if } x> \frac{L}{2}
\end{cases}
\qquad v_2(x)=\frac{1}{EI}\left(\frac{M}{L}\frac{x^3}{6}-M\frac{x^2}{2} +\frac{ML}{3}x\right)
$$
With this, you need only apply the condition defining the fixed support at A. this condition is $\theta_1(0)+\theta_2(0)=0$, using the value of $M$ to enforce this equality. Doing the algebra leads to
$$
M=\frac{3PL}{16}
$$
Exactly as the value you got on the original prompt.
This looks like a lot of algebra, but the main advantage is that the procedure is completely general. Following the same steps you can solve a beam having a any end support conditions, supports at the mid-span, concentrated or distributed loads, etc. Furthermore, this allows to calculate bending moment and shear at any point, which is also an important consideration. With some work you can write a program that solves this numerically, needing to work out all of this only once.
As a final note, if you plot the deflections $v_i(x)$, positive values point downward.
Answer: Since the moment at the fixed end $A$ is given, then you can sum the moment about $A$ or $B$ to solve the reactions. Let's start with $\sum M_A = 0$ first.
$R_B*L + \dfrac{3PL}{16} - \dfrac{PL}{2} = 0$
$R_B = \dfrac{P}{2} - \dfrac{3P}{16} =  \dfrac{5P}{16}$
Now, $\sum M_B = 0$,
$R_A*L - \dfrac{3PL}{16} - \dfrac{PL}{2} = 0$
$R_A = \dfrac{3P}{16} + \dfrac{P}{2} = \dfrac{11P}{16}$
Finally, $\sum F_y = 0$
$R_A + R_B - P = \dfrac{11P}{16} + \dfrac{5P}{16} - P = P - P = 0$, check!
Note, when taking the moment about a joint, you can take either CW or CCW as positive rotation but must be consistent throughout that operation, then the result will be carrying the correct sign.
Comment: For this system, there are 4 unknown forces (3 at support "A", and 1 at "B"), but there are only 3 equilibrium equations available, so, this is a structurally indeterminate beam to the first degree (4 unknowns - 3 equations), which can't be solved using the method for simply supported beam. For this case, you need to find one more equation or condition, so the number of equations = the number of unknowns. (Note, for simply supported beam, there are 3 unknowns with 3 available equilibrium equations)
Comment: Thanks for your answer! However, how can I derive the given moment if I do not know the formula?
Comment: how to come up with 3PL/16?
Comment: The simplest way, look up your structural analysis textbook, there must be a page or two providing the FEM for the single span beam. The second method is to release the support at "B", calc the deflection at the freed end "B", and place a unit load to close the gap (I assume you know the consistent displacement method), then figure out R_B by proportion, From here, with R_B is known, this becomes a simple cantilever problem.
Comment: May I ask a stupid question? Why isn't taking moment at A possible in this question? P(L/2)+RB(L)=0 As i got RB= P/2 from this method.


Is there a word that describes a reading deficiency where information may be understood but is not absorbed?

Question: As far as I understand it, reading comprehension relates only to the ability to understand what is read. I'm asking because my Craigslist ads contain enough pertinent information about an item being sold but for some reason potential buyers still ask me questions that are clearly answered in the ad (I've resorted to just copying and pasting the ad to answer their emails). When I talk about this phenomenon to others I have no way to describe this reading deficiency in one word. Thanks for any help.
Comment: You may be drawing the wrong conclusion. People will often ask questions just to start a conversation, before they feel comfortable enough to haggle about the price.
Comment: @michael.hor257k, I think the OP is referring to asking redundant questions just to confirm what they already *read* (and not just as a way of exchanging pleasantries).
Comment: @alwayslearning I am referring to the same thing.
Answer: Assuming the reader read the written information carefully enough, if they still honestly ask questions already answered therein, they are probably just reconfirming.
This should mostly be due to technical reasons. For one, probably (to them) there is some ambiguity in the written word (it's possible, which is why we have legalese and all those legal professionals surviving on it). And then, they may want something implied in the text to appear explicit in their written communication with you. Plus, their written/email communication with you is preserved unlike a Craiglist ad which can technically become unavailable for reference later.
M-W:

reconfirm
transitive verb
:  to confirm again; also :  to establish more strongly

ODO:

reconfirm
VERB [WITH OBJECT]
  Confirm again.
'this has been reconfirmed by a recent Higher Labour Court decision'
  'The players continued with the tour only after the agreed procedures had been reconfirmed with diplomats and security advisers.'
  'Once confirmed, they do not need to be reconfirmed later.'
  'Call
  the airline to reconfirm your flights on the day of departure to
  prevent any surprises at the airport.'
Answer: Those of us who have been teaching literature and writing courses will point to a scary but growing phenomenon among our students--they have read the material with what is known as "mindless reading," that is, they have read each word but have failed to internalize the material.  In your example, however, I agree with a previous comment that your readers may want to confirm what is critical information to them--in other words, they want what amounts to a promise that certain things are true.


Not very familiar with odds ratio, should we use odds ratio here?

Question: We have two groups of vehicles (group A: regular vehicle and group B: vehicle with ADAS system), all vehicles are equipped with data acquisition systems for continuously collecting driving data. Participants drove the vehicles as normally as they could, just like drove their own vehicle.  100 participants in Group A drove 10000 miles totally, 5000 acceleration ( >0.3g) were collected, 100 acceleration of the 5000 > 0.7 g, which are treated as safety-critical acceleration.
20 participants in Group B drove 3000 miles totally, 2000 acceleration > 0.3g were collected, 10 acceleration of the 2000 > 0.7 g.
Could we use the odds ratio to determine whether ADAS can improve driving performance (less number of safety critical acceleration), like the table below?
Answer: I'm not familiar with your application and so the jump from computing a hypothesis test for the odds ratio to "Could we use the odds ratio to determine whether ADAS can improve driving performance" is I (and I suspect many others) will not be able to make.
However, assuming you feel confident enough to make the inference yourself, the table can be used to analyze the relationship between risk of safety critical acceleration and group.  There exist several ways of analyzing 2x2 tables like these, and the odd ratio is not my favourite.  Odds are difficult to interpret directly and so I'd opt for risk differences because they are easy to understand.
The risk difference is simply the binomial test of proportions (and if I'm not mistaken, a test using odds ratios and a binomial test of proportions should be asymptotically equivalent).  There are lots of examples of how to perform this test on the internet and on this site.


Virtuemart & Paypal integration

Question: I am using virtuemart and paypal.  The user will go through the whole checkout process fine, the page redirects to paypal for payment.  The user might have a different bill to address than ship to address.  If they select a different address in the paypal page it still has the billing address as the ship to address.  Any advice on how to clean up this problem?
Answer: It shouldn't matter what address they select/enter in Paypal -- if they have selected the shipping address in Virtuemart then that address is what is stored in the Virtuemart Invoice/Purchase order.

Virtuemart & Paypal integration


Macs on wireless network can't see eachother

Question: I've got an iMac and Macbook Pro, both running Snow Leopard and both on my home wireless network (running off a Linksys E2000). They both can get online fine, both have file sharing enabled, neither have a firewall enabled, and they both have IPs on the same subnet (192.168.1.144 & 146). Yet neither one can seem to see the other. If I open the network browser in Finder it's empty, attempts to go to the other machines IP directly fail after a long timeout, and even trying to ping the other machine fails. Yet, strangely, I've been able to get services like Synergy working just fine between them. Any ideas as to why these two machines are so inconsistent about talking to eachother?
Comment: Snow leopard likes ipv6 for bonjour in snow leopard. Have you turned that off in either network pref pane or on the router.  Also, try pinging host.local as you shouldn't need an ip or dns with a local suffix added ton the short name.
Comment: Pinging .local fails from the other machine, unfortunately. As for the IPv6 stuff, I hadn't thought of that before, but upon some investigation it looks like my router (the aforementioned E2000) doesn't support IPv6 unless you flash it with 3rd party firmware like DD-WRT. (Really, Cisco? Really?) I've been considering doing that for a while anyway, so this may be a good excuse, but should I really have to have IPv6 for file sharing? That seems a bit extreme.
Comment: Even if the router doesn't know how to route IPv6 (i.e. to the outside world), it should still be able to bridge it between computers on the private network (whether wired or wireless).  At that level, it's all just ethernet frames, so they'd almost have to go out of their way to break it...
Comment: Wow - if pinging a local host fails, I would temporarily use an Ethernet cable between the two macs to ensure it's not software/firewall or configuration issue before digging into the router.
Comment: Sorry, I should clarify. I can ping localhost in any of it's various forms. (I'd be REALLY worried if I couldn't!) I can't ping the other machine with any address, though, wether I'm using it's IP directly or the appropriate .local name.
Answer: I have almost the same setup except that I have an E3000 but I'm not running Synergy.  My Macs can ping each other and share files.  I have IPV6 turned off.  You may have tried some of my suggestions but let see if any of them will help the cause.
I have file sharing enabled on both Macs and I can see my other on-net mac in the Finder Sidebar under Shared.  My Sidebar Preference under Shared allows connected servers and Bonjour computers.  With these settings, can either Finder see the other Mac?  It's good to verify this on both machines as a control.  If you can see either machine, you should be able to double-click to log in.
If not, please turn off Synergy then reboot each mac and see what comes up in Finder.
Make sure your E2000 basic wireless is set to mixed.
I did not use Cisco Connect opting to configure my E3000 manually and I'm not running WPS (WiFi Protected Setup).  If you are running WPS, temporarily disable it to rule it out as a potential cause.  On my E3000, I have configured any MAC access lists and access point isolation is disabled.
Temporarily disable any security option under Wireless Security for both the 2.4G and the 5G settings.
Save router settings.
Reboot each mac and see what comes up in Finder.  This will help us see if this is a Mac, Synergy or Cisco issue.
Answer: Okay, this is really random and bizarre but after a second power-cycle of my router suddenly everything started talking again, good as new! I'm honestly pretty stumped by what happened here, and annoyed that this didn't resolve itself on the first power-cycle I tried, but all's well that ends well I guess.
If anything I'm sorry that I didn't come out of this with better advice for people with the same problem down the road. Good luck, future network debuggers, 'cause I don't have any advice for you! :P
Comment: LOL, so typical. I would estimate that roughly half of the network issues I have seen people stumped by are fixed by simple reboots/power cycling. I suggest you mark this as the accepted answer since it fixed your problem and is a good reminder to everyone with network problems.
Answer: I had similar issues with a Linksys E2000 router... the Macs on WiFi could ping the router, an iPad, Linux machines and various infrastructure but could not ping each other and could not be pinged from anything else. This was despite OSX Firewall being turned OFF.
According to Wireless>>Advanced Wireless Settings the AP Isolation option was Disabled. Just for a laugh I Enabled it, Saved Settings, Disabled it again and Saved Settings. Lo and behold the Macs could ping each other and could be pinged by everything else.
Hope this helps someone else.


How to extend External Language Input?

Question: Is it possible to add a new option here and bind an evaluator?

Is it possible to take SageMath, Matlab, Maple, etc. as examples to provide a complete process demonstration?
Comment: Add it to the stylesheet so that it goes with ```CurrentValue[EvaluationNotebook[], {StyleDefinitions, "ExternalLanguage", CellFrameLabels}]```. It seems the menu there changes a `CellEvaluationLanguage` option.
Answer: It was just an attempt to add a ExternalCell, and did not successfully create an evaluator bind.

First create a new package called ExternalEvaluate_*, only this form can be recognized by External Evaluator Manager.
Then add cell icon and set "ShowInFrontendCellQ" as True.
Then run the ExternalEvaluate`RegisterSystem.

ExternalEvaluate`RegisterSystem["SageMath",
    <|
        "ExecutablePathFunction" -> Function[{vers}, unimplement[]],
        "ExecutablePatternFunction" -> Function[{vers}, unimplement[]],
        "ProgramFileFunction" -> Function[{version}, PacletManager`PacletResource["ExternalEvaluate_SageMath", "REPL"]],
        "ScriptExecCommandFunction" -> Function[{uuid, exec, file, opts}, unimplement[]],

        "Icon" -> Import[PacletManager`PacletResource["ExternalEvaluate_SageMath", "Icon"]],
        "IconCell" -> ToBoxes@Import[PacletManager`PacletResource["ExternalEvaluate_SageMath", "IconCell"]],
        "ShowInFrontendCellQ" -> True,

        "VersionExecCommandFunction" -> Function[{exec}, unimplement[]],
        "PacletName" -> Automatic,
        "SessionProlog" -> None,

        "DeserializationFunction" -> BinaryDeserialize,
        "SerializationFunction" -> BinarySerialize
    |>
  ];

Then a new kind of External Cell is available.
But it needs to bind executable program, still have no idea.

How to extend External Language Input?


Thiessen polygons modified for slope

Question: I seem to recall to have read about Thiessen polygons which, instead of having straight boundaries, had some irregularly shaped sides. That was since those polygons were actually taking into account the terrain's slope. Did anyone come across something like that?
Answer: Thiessen polygons are defined as the set of points that are closer to a given site than to any other site. Usually, the distance is an Euclidian distance, which yields the straight lines of the most familiar Thiessen polygons. However, it can be generalized to other distance metric, in which case you don't end up with the same lines, of course. In GIS, distances such as Mahalanobie or Manhattan are not commonly used, but cost distance analysis are more frequent. You example with terrain's slope would be a special case of cost distance analysis. It is called cost allocation in most softwares, but note that 1) this is then a raster analysis and not something you can solve easily directly with vectors and 2) not all algorithm take the orientation of the slope into account to create the cost allocation.

Thiessen polygons modified for slope


iphone 6 ios 8 siri only working with external mic!

Question: I have a jailbroken iPhone 6 running iOS 8.2. My problem is that Siri does not work with the internal microphone. Siri and dictation work fine with any  external mic like the kind that you'd find on the stock Apple iPhone headphones.
Answer: do you have any tweaks or something that works with bluetooth, and or the mic?
to rule out jailbreak, turn off your phone and turn it back on while holding the volume up button, this disables all the jailbreak tweaks... like a safe mode, if siri works fine, then you know it has something to do with your JB if not? then it has something to do with your OS
Comment: i started my phone is safe mode and ruled out jailbreak. :/
Comment: next step would be to test the microphones, start up voice memos and touch the microphones verify that the microphone at the bottom works

Next step disable bluetooth

next step settings - general- accessibility- phone noise cancelation on

next step turn siri off, then back on and turn hey siri on, try them both out

next step try connecting a bluetooth headset and activate and try siri with it

next st... i can't think of anything else
backup restore (use with caution because of your JB) your JB will disappear
Comment: on all my suggestions, if there is toggles involved, try with both on and off settings! let me know, and good luck!
Answer: You would start by quitting all the running apps on your phone:
iOS: Force an app to close
http://support.apple.com/kb/ht5137
Double-click the Home button.
Swipe left or right until you have located the app you wish to close.
Swipe the app up to close it.
When you have done that restart the phone and test the issue again:
iOS: Turning off and on (restarting) and resetting
http://support.apple.com/kb/ht1430
Comment: thanks, but ive ill ready tried that.
Answer: Dictation and Siri uses the front facing microphone. This is separate from the microphone voice memo uses. I thought there was only one microphone on iPhone 6 which initially let me to believe Siri/dictation not working was a software configuration issue.
If the microphone is defective you won't hear audio after you record a selfie video saying "Steve Jobs was the bomb".
Answer: Ok this is SOLVED!!! Yeaaaa!! :-)
After I updated, Siri and Dictation quit working and only worked on Bluetooth!
I tried everything and spent days researching it on the web and no one knew anything!
I checked all the settings, I tested the memo mic and the main camera mic and all worked good. I was positive it was a software issue and it was... More or less.
Turns out that the selfee mic IS the problem, it's the mic on the screen side of the phone near the camera. And it's not the same one used for memo recording that's on the bottom!
Maybe my phone used more than one mic or a different mic for Siri and Dictation before the update, and then after the update used only the Selfee mic... I don't know, but I bought a camera and mic combo part and a pentalobe screwdriver to get the screws out and changed it my self.
And BINGO! no more Siri and dictation problems. WHEW!!!


How busy is New York City on New Year's Eve?

Question: How busy are the streets in New York City on New Year's Eve?  I've seen TV shows like How I Met Your Mother show it as one unyielding crush of humanity, but I was wondering whether that is actually realistic.  Is it possible to travel far by foot or other means, or are you limited to the immediate surrounds of your residence?
Comment: just for fun, you can find hundreds of videos on youtube showing NYC in new year's eve... check some of them it will give you a picture of the reality..
Comment: Keep in mind, it's a big city.  Living in Manhattan, I found it was more empty than usual as long as you stay away from tourist areas.  After all, a lot of people leave the city for New Years and there's less work-related congestion.  But yes, if you go near Times Square, it will be very crowded.
Answer: I haven't done a Times Square New Year's Eve in over a decade, but I'd say if you can manage changing trains at 42nd Street during rush hour, it's no great challenge.
Compared to most American cities (if not, say, Mumbai), New York City is an "unyielding crush of humanity" on any ordinary day. The sidewalks are crowded, the subways are crowded, the stores are crowded. The good news is that on account of this, New Yorkers are quite accustomed to negotiating crowds wherever they go. You find others in the crowd going the same direction as you are and go with that flow rather than trying to move against it on your own… or you learn to push and be pushed a little. That's how the stereotypical New Yorker is, to this day, always rushing around town from appointment to appointment— not working endlessly at the office like a Tokyoite or on the mobile phone stuck in traffic like an Angeleno.
New Year's Eve is the biggest party day, but there are other big parties like St. Patrick's Day, not to mention dozens of parade days, street festival days, game days, and other excuses to congregate in public areas. Inside Times Square or wherever the main event is, people will be shoulder to shoulder, but in the area beyond only an extreme agoraphobe would be unable to move about. Road travel is tougher, as surrounding streets may be closed during special events and it may be hard to find a taxi, but that's true of any city.
If you find a group of immobile tourists on New Year's Eve in Manhattan, it's probably the cold. People seem to underestimate how cold it gets, since the tall buildings both block out the sun and channel stiff winds.
Comment: Times Square during the New Year celebration is basically locked down starting from about 8pm.  Including no subway trains. Given the amount of alcohol consumed it doesn't feel that cold. :)
Answer: If anything, I'd say that a show like HIMYM understates just how bad the heart of the midtown Times Square festivities are, post 9-11. Because people are so heavily penned in and the lanes of traffic are so controlled by security, there is little to no mobility for actual revelers.
As for the rest of the city, it's busy, but not any worse than any other busy holiday evening or rush hour -  the crowds are just a bit shifted from their usual locations, away from office towers, and closer to bars and the waterfront.
Comment: *Foot traffic*.
Comment: There is no traffic in or under Times Square on New Years' Eve.  It's locked down.


_deprecated_argument for constants

Question: i'm working on updating a theme and previously it had used a lot of php CONSTANTS to set up some options as true or false.  we're going to be updating these "decisions" to use add_theme_support() instead.  is it appropriate to use the _deprecated_argument() function to tell child themers that these constants are deprecated?  if not, what is the best way to trigger a deprecation warning for a constant?
Answer: Unfortunately there is no way to trigger WP deprecation warning for PHP constants.
What I can suggest - to use your constants and "theme support" options together. First for backward compatibility, second for customization facilities. Your theme will have to rely on "theme support" options only, and keep constants only for child theme.
The trick is in the way of declaration such constants. You have to define your PHP constants based on what has been added to support by theme.
After updating your theme, you need to let people know that you don't use PHP constants any more and you will remove PHP constants in further releases. You can place such information on a site via which you distribute your theme.
Comment: what if instead we switched everything to add_theme_support and has_theme_support, but then for backcompat did if(CONSTANT) add_theme_support('bacon')... then the rest of the code will be future proof and that one line can be dropped when enough time has passed?

_deprecated_argument for constants


Is there a Birkhoff-like theorem for stationary axisymmetric metrics?

Question: I know about the theorem by Robinson and Carter about the uniqueness of the Kerr metric in the case of stationary axisymmetric (SA) black holes. Are there any uniqueness theorems like Birkhoff's theorem for stationary axisymmetric metrics?
Comment: But that one assumes the existence of event horizon, so it is true for black holes.
Comment: Yes, similar theorems exist. You may consult Harvey Reall's notes on Black Holes. http://www.damtp.cam.ac.uk/user/hsr1000/black_holes_lectures_2016.pdf
Answer:
Note first of all that $U(1)$ axial symmetry is much smaller than $SO(3)$ spherical symmetry.
(Let us put the cosmological constant $\Lambda=0$ to zero.) Where as spherically symmetric vacuum solutions are static and there are no spherically symmetric gravitational waves, the axisymmetric vacuum solutions are not necessarily stationary and there are axisymmetric gravitational waves. Even if the axisymmetric vacuum solution is additionally assumed to be stationary or static, there is still too much freedom left. Hence there is no axisymmetric version of Birkhoff's theorem.
The following electrostatic analogy with 3D Poisson's equation is telling: Spherically symmetric solutions $\phi$ to Laplace equation are restricted to just $\phi= Ar^2+B/r$. On the other hand, for axisymmetric solutions to Laplace equation in cylindrical coordinates, we have no control over the $z$-dependence.
Answer: There is nothing as strong as the Birkhoff theorem in the case of stationarity and axisymmetry. Note that the Birkhoff theorem in its strongest form can be stated as:
"If even a piece of the space-time is spherically symmetric and a vacuum, then it is a piece of the Schwarzschild space-time."
There are various theorems about axially symmetric and stationary space-times which say that we reduce to Kerr under various conditions such as e.g. regularity outside of and on the horizon, connectedness of the horizon, asymptotic flatness, and global vacuum. I.e., with some physicist-faith leeway, we can construct arguments that as a reasonable, globally strictly vacuum and asymptotically flat space-time, the Kerr space-time is unique.
However, we do not know any reasonable matter solution which would match the Kerr space-time as an "exterior" solution. Geroch has even conjectured that there is no "interior" solution to the Kerr metric, i.e. a non-black-hole star which would reduce to Kerr outside its surface. (I personally believe that Geroch's conjecture is true.)
In practice, when we construct solutions of neutron stars, we find that they always differ from the Kerr case in the quadrupole and higher mass-multipole momenta of the space-time and we have to match them to approximately constructed non-Kerr metrics. I.e., when we are not globally vacuous, the uniqueness of Kerr is broken for sure.
There is even a rather well-known class of solutions derived by Manko & Novikov in 1992 which allow to set all of the infinite asymptotic values of mass-multipole momenta to arbitrary values. This, however, comes at the cost of weird singularities at the horizon and/or singular matter sources outside it. If you want a simpler playground for gaining some intuition on this, you can check out the axisymmetric and static Weyl metrics where you can plug in any Newtonian (axisymmetric and stationary) gravitational potential to generate a new space-time deviating from Kerr in its vacuum regions.
Answer: No. The key point is the (in general) non zero value of the multipoles modes.

Physically, it must be emphasised that there is no Birkhoff theorem
  for rotating spacetimes — it is not true that the spacetime geometry
  in the vacuum region outside a generic rotating star (or planet) is a
  part of the Kerr geometry. The best result one can obtain is the
  much milder statement that outside a rotating star (or planet) the
  geometry asymptotically approaches the Kerr geometry. The basic
  problem is that in the Kerr geometry all the multipole moments are
  very closely related to each other  whereas in real physical stars
  (or planets) the mass quadrupole, octopole, and higher moments of the
  mass distribution can in principle be independently specified. Of
  course from electromagnetism you will remember that higher n-pole
  fields fall off as 1/r^{2+n}, so that far away from the object the lowest
  multipoles dominate  it is in this asymptotic sense that the Kerr
  geometry is relevant for rotating stars or planets. On the other hand,
  if the star (or planet) gravitationally collapses  then classically a
  black hole can be formed. In this case there are a number of powerful
  uniqueness theorems which guarantee the direct physical relevance of
  the Kerr spacetime, but as the unique exact solution corresponding to
  stationary rotating black holes, (as opposed to merely being an
  asymptotic solution to the far field of rotating stars or planets)

Source: Visser (2008)


Calculus I known material, getting students engaged

Question: I'm currently teaching Calculus I problem solving sessions for college freshmen.
The problem is that the majority of students have studied the material in high school (what's a function, even/odd, limits, asymptotes...).
What can I do in this situation to make those who're familiar with the material engaged in the problem solving sessions?
Comment: _engaged in the problem solving sessions_ I think you already answer your question. Let them solve the problem while you watch them do it.
Comment: Why do you want to engage them? You are re-explaining something they already know. They should not be required to attend the lectures.
Comment: If you're standing up in front of the class and solving problems on the board, stop doing that, because it's obviously not working. Offer students flexible possibilities for using the time well. For example, ask each student to write goals for the next session on an index card. Sort these cards into stacks, and find things they can do if they're in that stack. Email these things to them. Then at the next session, walk around the room and help them with what they're doing or check their work.
Comment: @Federico Poloni I totally agree, but it's the course instructor's decision that attendence is mandatory, which I can barely do anything about.
Answer: One thing you might do is try to incorporate non-routine questions into your Calculus problem solving sessions. Knowing the requisite material is not enough to solve a [non-routine] problem (i.e., question for which the method of solution is unknown at the outset; used in contradistinction with exercise).
There is a lovely paper ("technical report") with five example problems that you might try out:

Selden AN, Selden JO, Hauk SH, Mason AL. (1999). Do calculus students eventually learn to solve non-routine problems? Department of Mathematics, Tennessee Technological University. Link.

Here are the five non-routine problems:

The paper explores how effectively students did (or did not) use their resources (in the sense of Schoenfeld, 1985) when attempting these problems. Perhaps the ideas contained in the aforecited/aforelinked can help inform how you approach your own problem solving sessions.
To close, here is the final, non-original (Putnam 98/B2) problem foot-noted by the authors:

Given a point $(a, b)$ with $0< b< a$, determine the minimum perimeter of a triangle with one vertex at $(a, b)$, one on the $x$-axis, and one on the line $y=x$. You may assume that a triangle of minimum perimeter exists.

(I suggest trying all the problems yourself, first, before reading the solutions!)
Comment: Alright. I'll check the article out. I liked the idea that maybe I could incorporate this type of questions to the problem solving sessions. Thank you!
Answer: If your students are anything like my students in Calc I, I'd emphasize a different perspective on what they're doing.  Many first year students have a mechanical/algorithmic understanding of the derivative and don't have a very strong geometric understanding.  A favorite of mine is the inverse function theorem:  if $f$ is differentiable and invertible near $b$, then $(f^{-1})'(b)=\frac{1}{f'(f^{-1}(b))}$.  This has a great geometric justification.  Sure, the strongest ones might be able to prove this algebraically using implicit differentiation, but it'd be nice for them to understand why it's "obvious" geometrically.  (Also, problems involving $(f^{-1})'$ are also hard for them to interpret physically; that's another reason I emphasize this.)


Shortcut Keys Issue

Question: I created some custom keyboard shortcut keys for some of the file shortcuts,
But after I deleted above mentioned file shortcuts, I cannot assign the keyboard shortcut keys associated with old ones to any new file shortcuts,
How do I fix this?
Also is there any application available that shows all the current assigned keyboard shortcut keys?
Thank you
Answer: Whenever this happens to me, a simple reboot frees up the keyboard shortcuts previously assigned so I can reassign them.
As for the second part of your question, see if this helps: How do I get the list of defined shortcut keys in the Start menu?

Shortcut Keys Issue


How do I get the menu created using react-burger-menu to not have a scrollbar?

Question: How do I get the menu created using react-burger-menu to not have a scrollbar? I've tried adding and changing different properties all across the board in the css, and most of them don't have any real kind of effect. Here is an image of the open menu and my css:
(https://i.stack.imgur.com/UyFBW.png)
<code>/* Nav */

 .bm-burger-button {
    position: relative;
    right: 10px;
    padding: 0;
    margin: 0;
    width: 26px;
    height: 20px;
    margin-top: 0px;
    padding-top: 0px;
    justify-content: center;
    align-items: center;
    display: flex;
}

.bm-burger-bars {
    background: #373a47;
}

.bm-burger-bars-hover {
    background: #a90000;
}

.bm-cross-button {
    height: 24px;
    width: 24px;
}

.bm-cross {
    background: #bdc3c7;
}

.bm-menu-wrap {
    position: relative;
    overflow: hidden;
    margin-top: -30px;
    padding-bottom: px;
}

.bm-menu {
    background: #373a47;
    padding: 2.5em 1.5em 0;
    font-size: 1.15em;
    position: relative;
    overflow: hidden;
}

.bm-morph-shape {
    fill: #373a47;
}

.bm-item-list {
    color: #b8b7ad;
    padding: 0.8em;
    height: 200px;
}

.bm-item {
    display: inline-block;
    color: #d1d1d1;
    margin-bottom: 10px;
    text-align: left;
    text-decoration: none;
    transition: color 0.2s;
    cursor: pointer;
}

.bm-item:hover {
    color: #ffffff;
}

.bm-overlay {
    background: rgba(0, 0, 0, 0.3);
}
</code>
I tried changing the heights of the menu and menu wrap properties. The menu was offset originally too, and I ended up having to shift it up to cover the upper portion of the screen. I'm sure there was a better way to do that, but it works for what I'm doing. The scroll bar was there before and after I did that, so that didn't cause it to appear. Any help would be very much appreciated. As far as html is concerned, it's nested in the header portion of the app currently.
Answer: I solved this by setting max-height in .bm-item-list to 95%. Don't understand how this fixed it, so if someone can explain it would be very welcome.


Is PET bottle English?

Question: There is a Japanese-made katakana expression PET bottle, which refers to plastic bottles. More than 10 or 15 years ago, the NHK English show taught that "PET bottle" is a katakana expression and should be expressed as plastic bottles in English. These days, however, some English speakers living in Japan say PET bottle is okay. Is PET bottle used as an English expression in English-speaking countries?
Answer: PET is a standard abbreviation for a particular type of plastic, polyethylene terephthalate. It is used when sorting plastic items for recycling, but in everyday conversation I think most people would call it a 'plastic bottle'.
Comment: The codes for different types of plastic are PET, HDPE, PVC, LDPE and PP, but we wouldn't use those in conversation unless we were actually talking about recycling.
Comment: Thank you! I see.

So, is it okay to think that English speakers distinguish using PET bottles and plastic bottles according to the context? Daily conversation or recycling.
Comment: PET bottles are one kind of plastic bottle.
Comment: Anybody who doubts the usefulness of this answer should watch Episode 2 of the first series of Breaking Bad. There was never a more graphic lesson.

Is PET bottle English?


How do I get the most buck for my bang?

Question: Is it more cost-effective to sell many items of poor quality, or fewer items of higher quality that have been repaired together? Does the answer change depending on the item? Does it change depending on my repair skill?
Comment: I seem to recall that fixing items until the 'no more penalties line' (75% for weapons 50% for armor) gives the highest amount of caps.
Comment: The best bang for the buck is gambling with luck maxed out (and knowing the method in Caravan). The caps you can win make sales profits seem puny.
Comment: it usually depends on your carrying limit and yes, repair skill.  Most times I tend to use heavier items to repair each other and keep the lighter and more expensive items separate (i.e. higher caps/weight ratios).  Having jury rigging also helps a lot.
Answer: You should repair items before selling them, rather than selling many cheap weapons.
There are two reasons for this:

You don't need to go back to town as often; weapons get heavy pretty quickly. You will definitely make more money-per-minute-played, considering the time to get to town, sell your stuff, and get back to whatever hole-in-the-ground you were exploring.
You'll make more money by repairing items together*. This is especially true when the weapons are under 25% quality.

Once you hit a repair skill of 90 and level 14, it's worth picking up the Jury Rigging perk just so you can merge vaguely-similar weapons together (and convert the cheaper weapon into a higher quality on the more-expensive weapon).
*This depends on your skill, of course. I don't have numbers to back me up, but if your skill is below 25 or so, you may lose money. (But you'll still make more money-per-minute-played, because you're not trudging back to town as often.)
Comment: In my experience it's usually better to just give the armor to your nonhuman companion, he can't wear it, and your weapons to your humanoid companion, who won't use it if you don't also give them ammo. If one fills up you proceed to give the rest to the other companion. This adds roughly 400 lbs to your carrying capacity before being overloaded.

How do I get the most buck for my bang?


Should academic experience from other domains be included on a CV?

Question: As an undergrad, I was a double-major in neuroscience and music. Now, I'm working on putting together a CV for applications to master's programs in neuroscience. But, my thesis work was done in the music department and unrelated to neuroscience whatsoever. Should I include this on my CV, or would it be seen as irrelevant "padding" of my CV? (I'm not really concerned about shoring up my experience, as I've had several years of directly relevant work experience since I finished my bachelor's degree.)
Answer: If your undergraduate program requires a Bachelor's Thesis, graduate school admissions committees might expect to see it on your CV. Completely omitting your thesis in your CV might raise questions.
Your ability to do independent work is also important, even in another field. If your thesis work is not related to your graduate school field, I would mention it but not focus on it. (i.e., include the title and one sentence summarizing what you did). If your Bachelor's Thesis is publicly accessible (and it is a good thesis), citing it in your CV cannot hurt.
Comment: @DaveLRenfro I removed that claim from the answer.
Answer: As a past admissions committee member for graduate studies (in a different discipline), one of our biggest concerns were which applicants had the independence, stick-with-it-ness, and structuring and writing ability to finish a degree. A thesis in any discipline is solid evidence of that and will likely be looked on favorably.
From another angle, it is worth noting that academia favours CVs - which stands for curriculum vitae, the course of one's life. These tend to be multipage documents including all accomplishments concievably of relevance to the reader. Of course, a CV should be tailored to the audience, but basically you include everything and the bar for calling something "padding" is pretty high (low?). This is very much in contrast with industry-favored résumés, highly selective summaries chosen to be most directly applicable to the position being sought. That's why résumés tend to be 1-2 pages even for an accomplished experienced professional, while even a pretty junior CV is likely to be much longer.
Comment: Yes, definitely. Padding a CV? Definitely not. A resume, maybe.
Answer: Put it in for clarity, it's not padding. The point of a CV is not just to claim a set of knowledge, but to provide evidence of skills like research, analysis, self-motivation.
Also, you never know where you are going to end up, some time in the future you may do research at the intersection of these interests (such as how the brain interprets music).
Answer: There are two key elements of such applications, normally called the CV and the SoP (Statement of Purpose). Your CV details your past accomplishments and should probably be complete. Your SoP is directed at your future goals with some care given as to how the past enables the future.
So, my recommendation is to include everything in the CV. This avoids any possible future problem of anyone thinking that there are gaps and wondering why you are not giving a complete picture. But in the SoP, or equivalent, only mention music if it is somehow relevant to your plans in neuroscience.


Are 2 megapixels enough for HD resolution pictures?

Question: HD pictures has 1920x1080 = 2073600 pixels = 2025 kilopixel = 1.98 megapixel.
Does this mean that we can take HD pictures with a 2 MP camera? If not, why not?
Comment: I think that in general due to rounding, it doesn't really matter if "megapixels" is binary or decimal. _Megapixel_ is a useful term because it happens to be in the range where we get human-useful small numbers with the digital cameras (so far). It's rarely used to mean a _precise_ value — one 16-megapixel camera will likely generate photos with a slightly different size than one from another brand. For the same basic reason, "kilopixel" isn't a _real_ word, because there's no particular case where it would be useful.
Comment: Not to be pedantic, but I think the accepted definition of megapixel is 1 million pixels, not 1,048,576.  So HD would have 2.07 MP
Comment: Basically yes. In practice most people don't use the term HD with photography, unless they are using it for marketing purposes as companies seem eager to slap the term HD on everything today. If you are displaying images on a 1080p TV, yes 2MP will look great.
Comment: In my opinion, a high resolution is almost always good because you can crop out unnecessary parts that you don't need and extract the good parts of the photo. If you have to economise on the resolution, then it is harder to liberally take photos.
Answer: If the resolution long axis is at least 1920 and the short edge at least 1080 then yes, you can take HD images without having to upscale.
However, due to benefits of oversampling, you will make a better HD image by grabbing a 16MP image and then resize with the best available resize method, e.g. lanczos interpolation if available.
Another problem you may encounter is that a 2MP camera have not been designed with high quality imaging in mind (*unless you are talking something like a Canon EOS D2000 from 1998 which has the wrong aspect ratio , anyway), so they saved costs on not only the sensor but the rest of the imaging system as well - low end optics, ADC, processing, etc. yielding a lower total system resolution and IQ.
Comment: I would be willing to bet 90% of the photographing population who might benefit from this question won't know what "lanczos interpolation" is. ;P I would use the phrase "some basic downscaling in Photoshop", which is more than good enough to average pixels, reduce noise, and improve the sharpness of a 1920x1080 output image.
Comment: @jrista I don't know what the situation is in the US, but here in Europe Lanczos and other kernel based filters are part of the preschool curriculum ;)
Comment: @jrista Why not provide more information? I don't know what it is, but because Michael mentioned it, I'm able to do research on interpolation methods to find out more.
Comment: Remember my oversampling image tests in another question where I showed that fine texture would persist in the downscaled version, while shooting directly to that resolution didnt capture the texture? I noted that the end result relied on using the best available resize method. I guess I can write that :)
Answer: No, because of the Bayer filter.  You would actually need around 11 megapixels.
What a Bayer filter is
Colour camera sensors use Bayer filters to capture the various colours.  The Bayer filter effectively halves the resolution of the sensor for each colour (though green is left with slightly more in a checker-board pattern).
Each pixel on the sensor can only capture either red, green or blue light, but not all three colours.  A software algorithm needs to interpolate the data later to re-construct the full resolution photograph in full colour.

Demosaicing
This interpolation process (called demosaicing) will visually restore a lot of the effective lost resolution, making it look pretty sharp again, but it can only do so by taking fairly intelligent guesses.  It's not the same as if you had been able to capture the image at full resolution in the first place.
For example, while demosaicing is fairly good at claiming back lost sharpness from the Bayer filter, any fine detail such as hair, comb-like patterns or fine stripes are likely to suffer from aliasing, which can show up as colourful interference patterns:
 (source)
(These images show very poor demosaicing algorithms for the sake of illustration.  Modern cameras - even cellphones - use much smarter ones.)
Modern demosaicing algorithms are pretty smart and can minimise the effect of aliasing, but it still cannot retain the fine detail.  A distant picket fence shot on a 1920x1080 colour sensor will retain less effective resolution than an RGB 1920x1080 image that is computer-generated or scaled down from a larger sensor or scanned on a scanner.
How this affects the resolution
(and how I came up with the "11 megapixels" figure)
The effective resolution of the resulting image after demosaicing doesn't look like it is half the resolution claimed by the sensor, because of the gains made by smart demosaicing routines, and the fact that the green channel, which correlates well with luminance, has more resolution than the other colours.
But it still would need to be shrunk by 50% to remove any loss due to interpolation.  If you really wanted to ensure that your picture was "full resolution", without any loss of detail due to interpolation, you would need to have a colour sensor with double the resolution you want, in both the horizontal and vertical direction, and then resample the resulting image to 50%.
In order to capture full effective resolution of 1920x1080, a colour camera sensor (with a Bayer filter, which includes 99% of colour camera sensors) would need to have a resolution of double that: 3840x2160.  That's over 8.2 megapixels.  Due to cropping on the sensor (again due to the camera's demosaicing method) you'd effectively need around 8.8 megapixels to be sure.
And that's if your sensor had a perfect 16:9 aspect ratio.  If your sensor has a 3:2 aspect ratio, you'd need around 10.7 megapixels to capture a 3840x2160 image, including discarded areas on the top and bottom to make up for the aspect ratio, and a small border to account for any demosaicing crop.
Sensors without Bayer filters
While 99% of colour camera sensors use Bayer filters, there are some that use an alternative pixel layout, but the principle is the same.
There are also some colour sensors that don't need a colour filter at all, such as the Fovean X3 sensor, but these are still exceptionally rare and have their own issues.  Manufacturers also tend to lie about their pixel count (in order to be competitive with sensors using a Bayer filter, where the pixel count always sounds a lot more impressive than it really is due to the above described filter).
Another alternative that is employed by some expensive professional video cameras is to have three entirely separate sensors, one for each of red, green and blue, and use a light splitter to throw the same image on all three of them.  Obviously this cannot exist in a DSLR or compact camera or any normal type of consumer stills camera.  But it can explain why pixel counts on the sensors of professional video cameras can't be compared to those on DSLRs.
But video uses chroma-subsampling anyway!
(For technical minds only)
Even though video (and sometimes JPEG) uses chroma sub-sampling, it still needs the luminance channel to retain full resolution.  In an image from a Bayer sensor, the luminance channel still needs to be calculated using a process of interpolation, even though with a good demosaicing algorithm, it can appear to approach full resolution due to the high correlation between luminance and the green channel in most content.
Comment: Your 11 megapixel math assumes that Bayer demosaicing has _no_ value. Reasonable people can disagree where the exact number is, but it's surely something a little less dramatic.
Comment: It's late and I'm a little on the tired side, but doesn't your math assume that the 4x4 bayer array is a discrete pixel without overlap?
Comment: Yep, I said it was late... :) 2x2 is what I meant. However, if I recall, the algorithm for sensor demosaicing overlaps such that a 4x4 array would actually give you 9 pixels worth of data. I could be very wrong though.
Comment: I'm downvoting this answer, even though it's well written, and here's why: _almost_ every camera, through Bayer interpolation, gives pictures with the same number of pixel as its sensor. This is commonly accepted. If one talks about a 12MP digital photo we can safely assume it came from a 12MP camera which technically has a 12MP sensor. On the other hand we're talking about resolution but we need to address aspect ratios and image quality as a whole. Interpolation is there with the quality loss it implies, but that's a different issue.
Comment: How can taking a 3840X1216 frame that has been already been interpolated before downsizing be any more accurate than a 1920X1080 frame that has been interpolated from a 1920X1080 Bayer array? It seems to me we would need to keep the RGB channels from the larger image un-interpolated. It would need to be 2X as wide and high to allow for one R, one B and 2 G pixels to be *combined*, rather than *interpolated*, into each pixel of a 1920X1080 frame.
Comment: @mattdm the 2x figure is simply based on the minimum required downsampling to *totally eliminate* any effect of interpolation.  You are correct that the Bayer filter does not completely halve the effective resolution of the resulting image - it preserves more detail than that.  But to fully eliminate it from having any interpolation effect requires to halve the resolution.
Comment: If you mean 2x2, then that is the effective assumption, yes.  It's based on the 2x figure being the minimum required downsampling from the original data to totally eliminate any need to interpolate.  I'm not asserting that every 2x2 group of bayer pixels stores no more information than a single RGB pixel, however.
Comment: You would be right.  Demosaicing algorithms, in order to detect patterns, *need* to take into account a range of surrounding pixels when doing their calculation.  It's also why demosaicing algorithms in-camera tend to crop a few pixels off the edge of the image - the edge would confuse the simpler, embedded demosaicing algorithm.
Comment: MattiaG: I dont see this answer ever implying that a X MP image comes from a Y (where Y ~ X/2 ) mP sensor. He is saying (correctly) that to capture fine details that won't get messed up due to bayer patterns (in fine detail the algorithms' assumptions actually fail) you need to double the resolution (on both dimensions, resulting in a x4 factor on the MPs. And Clark: it does help to interpolate the finer details first and then resample to downsize, because it doubles the maximum frequency in the signal you can capture.
Comment: And in interpolation you are guessing unknown data, which always means you make assumptions, while in resampling you are reinterpreting data you know, so it is more reliable.
Comment: I think that 11 megapixels is too much, but it's still the best answer, as the others completely ignore bayer filters and the color resolution
Comment: The first illustration in this answer is utterly false and incorrect. Take a look at the response curve of any Bayer masked sensor and it is plainly obvious that *some* of the other two colors (actually range of wavelengths) make it through each filter. The same is true of the cones in the human retina. Our brains construct "color" from the difference in intensity between the three. I've never seen a Bayer masked sensor with no overlap between the red, green, and blue filtered sensels, and you haven't either.
Comment: Further, because almost all details that we often refer to as 'resolution' happens in the green band for human vision, even very crude demosaicing algorithms give a Bayer masked sensor about 1/2 the resolution of the total number of pixels. Very good algorithms can get it closer to 1/√2.
Answer: You are right that a 1080p HD image has just under 2 megapixels.
Now where you have to be careful is in considering the aspect ratio of your camera. If it shoots natively 16:9 images and it has 2 MP, then you would have enough resolution. If the camera has a 4:3 sensor which is the most common for small cameras, a 2 MP camera would most likely capture a 1680x1260 image. This unfortunately does not give you enough horizontal resolution.
On the other hand a 3 MP camera with a 4:3 sensor produces 2048x1536 images usually which is enough for your to downscale and crop to a 1080p image.
Answer: There are three common high-definition video modes:
Video Mode:     Frame size (WxH):       Pixels in image (resolution)  Scanning Type

720p         1,280x720               921,600 (almost 1MP)         Progressive
1080i        1,920x1,080             2,073,600 (>2MP)             Interlaced
1080p        1,920x1,080             2,073,600 (>2MP)             Progressive

it depends on what usage are you planning. if you want to project your video on a large screen (e.g. projector), then use a higher video mode of at least 1080p which of course requires a higher resolution (means more mega pixels) for smooth projection of the image.  Take note also of when using a higher resolution mean a more space consumption on a memory card and would require a higher specs of your PC for the video editing. But if you're planning for a small screen projection, (Laptop, PC) a 720p would do.
Special Note on Scanning Type
Progressive - is a way of displaying, storing, or transmitting moving images in which all the lines of each frame are drawn in sequence. The main advantage with progressive scan is that motion appears smoother and more realistic.
Interlaced - commonly used in analog aged of tv and crt,  is a technique of doubling the perceived frame rate introduced with the signal without consuming extra bandwidth.  The main problem of it is the interline twitter.  For instance, a person on television wearing a shirt with fine dark and light stripes may appear on a video monitor as if the stripes on the shirt are "twittering". This aliasing effect shows up when the subject contains vertical detail that approaches the horizontal resolution of the video format.


What can be used as the source for Arms of Ahriman?

Question: Can a character that has the Harbinger of the Abyss flaw be used as the source for Arms of Ahriman?  Could a Talon of the Abyss shadow elemental be used as the source for Arms of Ahriman?
Answer: There appears to be a distinction between "shadow" and "darkness."
Arms of Ahriman can emerge from an area of "shadow" — but "shadow" isn't the stuff of which Obtenebration is made. Obtenebration is made of "darkness," which has some tangible quality and is able to do things like put out fires and inflict harm. If you're doing something that manipulates shadow, like Shadow Play or summoning elementals with Eyes of the Abyss, you can launch a tentacle from there. However, the Talons and the Harbinger flaw produce Obtenebration "dark matter," which can't be necessarily be used as a tentacle spawn spot.
Answer: There is a  huge difference in WOD between shadow and darkness. The darkness a Lasombra controls comes from deep within; the shadow from a land called the abyss. Legend has that the Lasombra  antediluvian communed with this being of darkness on the  bottom of the oceans of the spirit world...
So my answer would be Harbinger of the Abyss, no; Talon of the Abyss can, by the rules. Although in terms of mecanics, in my humble view it would only suport one singular arm.
Comment: We strongly discourage pasting large parts of copied text from games, for a few reasons. In this case, two problems result: it was entirely unclear what parts of the text you thought supported your answer, and it's probably a copyright violation. You can avoid both problems by just quoting the exact lines that support your answer, so that readers don't need to guess.


How to choose a resistor value for Wheatstone bridge such that it is a balanced circuit?

Question: I have a 3V sine wave input and I want to measure resistor precisely from 1 ohm to 40ohm. I have tried using Arduino to measure the resistor using voltage divider but it became obvious that I will not be able to measure within 0.1ohm accuracy. I am now learning to use four point probe (wheatstone bridge).
How do I choose resistor value such that it becomes a balanced circuit to measure resistance from 1ohm to 40ohm. I hope to learn from you all.
Comment: Four-wire probing is a Kelvin connection, not a Wheatstone bridge. Are you sure you're not mixing things up?
Comment: Sam, accuracy is something traceable to NIST standards (or DIN, or similar.) Resistors are often specified with 1% accuracy or 2% accuracy (initial-only.) So, suppose you are designing a method to measure 100 milliOhm accuracy of a resistor. How would you approach this problem? What level of accuracy would you require of the parts you use in the experiment? How could you design an arrangement that balances the required accuracy of parts so that it is distributed evenly and not concentrated all in some one part that has to be super-accurate?
Comment: @jonk  I want to atleast try wheatstone bridge and see what the result looks like. I don't want to be discouraged. What I would like to know is how can I make the circuit balanced such that the output voltage is linear as the unknow resistor goes from 0 to 40ohm.
Comment: @Sam An accurate current source is how you would create a voltage that is linear with resistance.
Answer: As commented you are probably making confusion between Kelvin connections and Wheatstone bridges. They are completely different things!
A Wheatstone bridge is simply a glorified two-voltage-divider system, really.

simulate this circuit – Schematic created using CircuitLab
One divider on the left, one divider on the right and a null detector in the middle (in the original construction). When it was invented you put your X resistor at, like R1 position and tuned R2 or R4 until you got 0V between branches. R3 would set the range, more or less. The advantage is that R1 and R3 can be of different orders than R2 and R4 (it's not practical to make a, say, 10 ohm variable resistor).
These days the Wheatstone is mostly used as an amplifying device for transducers with multiple resistor varying (i.e. strain gauges and similar).
A Kelvin connection (or Kelvin sense or 4-wire resistor measurement) is a way to avoid errors due to connecting lead resistances:

simulate this circuit
The idea is that the 'wire joints' are made directly on the resistor (current shunts have actually 4 terminals precisely connected in that way).
With a voltammetric measurement you force a known current in the resistor and measure the drop (Ohm's law follows). However the measurement leads themselves have some resistance (on the order of 0.1 ohm, typically) that would get included in the measurement with a standard ohmmeter. Using two different leads and and high impedance voltmeter you can avoid the error since on the sense leads circulates no current.
Now, measuring a resistor with a Wheatstone bridge and a single ended ADC like the one on the Arduino simply can't be done. You need a differential amplifier for that. And it's actually trickier than it seems since the error and tolerances propagate really fast (also, by the way, the Wheatstone bridge is not linear with only one varying resistor).
1 to 40 ohm with 0.1 ohm precision is quite feasible and not too hard with a Kelvin sense. The main issue is the power you dissipate on the resistor, that could be a problem. Assuming you are not going to use a dedicated amplifier (they make them), if you wanted 2.5V with a 40 ohm resistor you would need 62.5mA and dissipate about 156mW on the resistor in the process.
For the resolution: assuming 2.5Vref and a 10 bit ADC (not sure if the Arduino one is 10 or 12 bits), one LSB is about 2.44mV. 0.1 ohm on a 62.5mA current gives 6.25mV, so it's about 2.5 counts of converter. Could be better but on paper you have the resolution needed, oversampling a lot would help if possible.
As for the precision… well, you didn't say. Precisely is not exactly… precise. In this application the main sources of error are the constant current generator and the ADC Vref (the Vref generator internal to the MCUs usually is quite poor).
Comment: Thank you for all the information. What I would like to know is how can I make the circuit balanced such that the output voltage is linear as the unknow resistor goes from 0 to 40ohm. I know how to make a balanced wheatstone bridge but how can I make it balanced for a range of resistor such as 0 to 40ohm.
Comment: *By definition* the bridge is balanced *only* at one point, when the differential is zero. There is a quadratic relationship for the output when the bridge is *not* balanced (so for this application it kinda sucks). You could, for example, have the incognito arm as (1-40ohms)+(100ohms) and balance it with (1-40kohms)+(100kohms); the 1-40kohm would be your variable resistor