How to Restore Phone App in CM13?

Question: I disabled Phone application and set force stop in CyanogenMod 13.
Now, I cannot find the phone application anymore.
The phone crashes if I try to call.

How can you restore Phone Application in CM13?
Comment: If you don't have root you can enable it in settings if you're using CM13. Some apps will tell you to download SU this is a mistake if you're using CM13.
Comment: You're saying it's not there when you go to Settings app -> Apps -> tap All apps and choose Disabled -> you don't get to see Phone app?
Comment: @Firelord Yes, it is gone.
Comment: Have you tried `pm enable` command? It requires root access and package name.
Comment: No. I think I have no root. Installing any new phone app crashes the phone when I try to call with it. What to do?
Answer: It must be a problem with the ROM if it is not showing the app disabled through Settings app like this:
(Click image to enlarge)

Anyhow, if the Settings app doesn't show it then I see no way to solve this problem without root. If the following steps do not work then your ROM is faulty because they worked for CM13-snapshot in my Nexus 6. In case you do not know, root access can be enabled in CM13 from Developer options.
A disabled app is a user specific restriction and the restriction ends up in the file /data/system/users/USER_ID/package-restrictions.xml. USER_ID for primary user (owner) is always 0.
Find the entry responsible for disabling your app using the app's package name and either remove the whole line or make tweaks there. I'm instructing with a tweak. Here's how the restriction originally looked like:

For the case in question: In the line depicting the cursor and containing the string com.android.dialer, integer to enabled represents the state of the package and enabledCaller is the caller which instructed the package to be disabled. You can either remove the whole line or change enabled=3 to enabled="1". (Source)
Do a full or soft reboot and you would find your app enabled.
The alternative method is to use a terminal emulator app or adb with adb shell command to execute these:

su
pm enable PACKAGE   # PACKAGE refers to package name of the app to be enabled

If you don't know the package name of your app, follow View app's full package name?
Another alternative: While I didn't try, I've full faith that Titanium Backup
 would offer the option to unfreeze your app. There may be other similar apps that can help you out.
If the said solutions make no effect on the app's status, ditch the ROM.
Comment: Thank you for your thorough answer! I found the app in Settings > Apps.
Comment: Did you reboot or did something else? I don't follow how you weren't able to find it earlier but can do it now.
Comment: In the application view, I could not see it. I did not know that you have "Apps" menu inside Settings. There, I could find it.

How to Restore Phone App in CM13?


Ezybox hot shoe bracket

Question: I've recently purchased a Lastolite Ezybox softbox L2495 and looking for a speedlight bracket. They sell Lastolite Ezybox Hot Shoe Mark II bracket but it seems smaller than the attachment plate which comes with the softbox. What bracket should I buy?
Comment: "seems smaller"--have you just tried using the plate that came with the softbox? The fit _does_ have to be tight to keep the softbox from falling off.
Comment: The plate that comes with the softbox fits nicely. But the thing is, that plate is designed for studio strobes and not for speedlights. I wonder if there's a right bracket that fit this softbox
Answer: The Lastolite Ezybox hot shoe bracket is what you want. I can only find a kit on the Lastolite site, but I see that B&H has just the bracket.
Answer: An Amazon review mentions that the Godox S-Type Bowens-mount bracket works well for the standard Ezybox softboxes.

5.0 out of 5 stars
Also works great for Ezybox, February 2, 2016
By mcas
Verified Purchase
This review is from: Godox S-type Bracket Bowens S Mount Holder for T+L Speed Ring Softbox Speedlite Softbox Beauty Dish Reflector Umbrella (Camera)
I ended up returning this because I realized afterward that I needed the Elinchrom mount, but I wanted to mention that this bracket is cleverly designed... while the inner part is for Bowens mount, the outer edge of the circle is exactly the right size to allow for the standard rectangular / square Ezybox to attach to (though I don't think it would work with the octagonal Ezybox without the appropriate speedring added).

Ezybox hot shoe bracket


How to get an estimated amount of talktime,music/video playback time, idletime that could be possibly done based on the current level of battery left

Question: I am working on the amazing android platform. I am creating an app which deals with the phone's battery level.I am showing the current battery level of the phone, along with few other technical things.I wanted to  get an estimated amount of talktime,music/video playback time, idletime that could be possibly done based on the current level of battery left on the phone.Using this the user can get an idea that if his battery level is at 50% then possibly he can do another 2 hours of call talk (or) listen to 1 hour of music (or) if the phone is untouched then it would last for some 4 hours. In this way it would help the user.Please help me in suggesting an approach (or) is there any API available for this.?
Answer: Can't say for sure, but I highly doubt there would be any API for this.
I think the only workable approach is for you to collect data and try to estimate as close as possible. You can try to measure how much power each app / usage draws and also try to measure battery capacity. You'd have to tweak your values from time to time as batteries which are not new sometimes drop their voltage, etc so it's a moving target.
Answer: I think this is impossible to do.
As @dain suggests you could tray and measure historical data and make a guesstimation based on that, but as all sorts of background processes (connection strength low means lot of searching, wifi or not, data in the background, new applications, you name it) have influence on this, so it's hard to be accurate based on the collected data.
You might be able to target specific processes (like calling, or using a specific app like a music player), and check how much power they use on average, and go from there.
What sollution you use, I think because of the difference in all the data you will get some sort of mean out of it that would probably not be correct for the current situation. You might get away with a "minimum" vs "maximum" time per activity?
Answer: final Intent intent = new Intent(Intent.ACTION_MAIN, null);
        intent.addCategory(Intent.CATEGORY_LAUNCHER);
        final ComponentName cn = new ComponentName("com.android.settings", "com.android.settings.fuelgauge.PowerUsageSummary");
        intent.setComponent(cn);
        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
        startActivity( intent);
this works for me


speaker volume always at zero in alsamixer in terminal

Question: On every startup on Ubuntu 11.10, I have to open terminal and enter alsamixer to turn speaker volume up to get sound. Is there a way to lock this in so I don't have to keep opening the terminal.
Answer: There seem to be some problem in the interaction of Alsa and PulseAudio. So usually there are two options to work around:

Deinstall PulseAudio: If you deinstall PulseAudio you will have normal working sound at every startup. However most user find PulseAudio very convenient. So this might not what you want.
Change Audio Settings: Open gnome-volume-control (Alt+F2 and enter gnome-volume-control or System -> Preferences -> Sound). Look at the tab Hardware and check if the correct soundcard is configured. Below is a menu called Profile. Try different profiles and see if they work. It is hard to say what is the correct option for you. A forum post suggested "Analog Surround 5.1", but it depends from your soundcard. If you chosse the correct version, sound settings are the same on each reboot.


Hierarchical Bayesian model - issues with JAGS/BUGS switching between lognormal and normal

Question: I'm trying to construct a hierarchical model using JAGS, but I'm running into issues converting between normal/lognormal distributions and the more I stare at my problem, the more confused I get.
Some of the parameters I'm trying to estimate are a series of $M$ values - I know that $M$ is lognormally distributed. In order to estimate the mean of $M$ (the hierarchy), I want to use the normal distribution because I have prior information that the mean is likely around $0.2$.
I know that the following equations hold for when you 'switch' between inputting your values from a normal distribution (let's call it $X$) and a lognormal ($Y$, where $Y=\ln(X)$):
$\mu_Y = \ln(\mu_X) - 0.5\ln(1 + \frac{\sigma_X^2}{\mu^2_X}) = \ln (\mu_X) -0.5\sigma_Y^2$
$\sigma_Y^2 = \ln(1 + \frac{\sigma_X^2}{\mu^2_X})$
However, I'm having issues implementing these in my JAGS model code. Here's the relevant piece of code:
meanM ~ dnorm(0.2, 0.1)
precM ~ dgamma(0.001, 0.001)
varM <- 1 / precM
logvarM <- log(1 + (varM / (meanM * meanM)))
logprecM <- 1 / logvarM
logmeanM <- log(meanM) - (0.5 * logvarM)

for (k in 1:4){
  M[k] ~ dlnorm(logmeanM, logprecM)
}

I get an error from JAGS here that says that logmeanM has an invalid parent value, and when I try to debug it using OpenBUGS it says that something went wrong in procedure Ln in module Math. Am I completely wrong in my math or my code? The more I try to figure it out, the more confused about normal/lognormal I get, so apologies if that is reflected in this question.
Answer: meanM is apparently intended to be the mean of a lognormal random variable. The mean of a lognormal distribution cannot be negative. Therefore, you cannot put a normal prior on meanM since a normal distribution puts positive probability on negative values.
Comment: Even if the probability is small, it might happen once in a long simulation. Once is enough ...  The message *something went wrong in procedure Ln in module Math* should be clear enough ...
Comment: I thought of that, but I tried setting up something like `meanM ~ dnorm(5, 10)`, which has little probability of having a negative value, and I still got the same error.


What could cause infertility between humans living in gravity and humans in space? How could that cause speciation?

Question: Concerning long term effects of zero gravity on humans living in space compared with those living on super earths with 1.5x to 2x G, how could the gravity differences cause reproductive failure among the two groups? What biologic traits might be selected for (or against) that would start to cause infertility between humans living in zero gravity, and those living on planets with more gravity than earth?
Comment: It is worth noting that NASA scientists believe it is most likely impossible to carry a child to term in zero gravity.  The process is believed to be too exacting to complete all of its functions without the presence of a gravitational field to provide direction.  They could be wrong, of course, but you should factor this into your worldbuilding endeavors.
Comment: @CortAmmon Interesting little factoid there, you have any reading material I could dig into?
Answer: What you're referring to is known as speciation. In the context of two planets between which there is minimal gene flow, this is probably going to be allopatric speciation. Speciation is the process of a single species breaking into multiple species, which are generally defined as populations which cannot create viable offspring when breeding with one another.
Allopatric speciation is speciation that occurs due to geographic separation. This is seen on earth when something like a river valley separates a population of animals into two populations that can no longer reach each other. Chimpanzees and bonobos are one possible example. They do not differ significantly in terms of their environment, but their separation on either side of the Congo river has led to the formation of two different species.
In order for allopatric speciation to occur, there do not need to be any specific population pressures that force evolution of the two groups. Rather, it has been hypothesized that genetic drift is sufficient to cause the two groups to become reproductively incompatible given sufficient time.
A long period of separation is the critical factor, here. Over shorter periods of time, the two populations are likely to remain capable of producing healthy children, even if population pressures have changed the physiological traits of one of the populations. Corgis and German Shepards, for example, can still breed, despite the fact that they've evolved (with human help) to thrive in very different roles.
Comment: Do you have any estimation how many generations it takes until speciation occurs?
Comment: @Philipp: Well, wolves and dogs have almost achieved speciation, and that happened ~15,000 years ago. With 2-10 years between generations this is 1,500 to 7,500 generations. So that would be a first-order estimate.
Comment: I would argue that dogs and wolves aren't close to speciation, and also aren't reproductively isolated from one another, as wolf-dog hybrids are still being produced on a regular basis and are reproductively fit (to my knowledge). In fish, allopatric speciation takse .8 - 2.4 million years. (https://www.uic.edu/classes/bios/bios101/Speciation2/sld030.htm). The LCA for Humans and Chimpanzees is around 5 million years, so definitely less than that.
Comment: I'd say around 1 million years would be a safe bet, but probably hundreds of thousands of there's significant evolutionary pressure driving gene change.
Answer: The first obstacle would be the ability to physically mate with each other. Modern astronauts face fairly serious muscle loss and atrophy after weeks in space, so humans living in space would be that much weaker. I'm doubtful that they would even survive visiting the 2G planet, let alone build the necessary blood pressure to perform the act.
The 'super-earth' humans would also have problems, if they were to meet the others in space. Not surprisingly, there has been quite a bit of speculation (and very little actual testing) about zero-G sex, and the consensus seems to be that it's very difficult. Basically, without gravity there is nothing to keep the participants together. One thrust and you're tumbling across the room. There is also apparently a blood flow issue, in which the human body, adapted for Earth's gravity, has trouble sustaining physical arousal. It would presumably be even harder (or ...not) for people adapted to higher gravity.
This also leads to a physical adaptation that could cause speciation, as natural selection would lead to the space-people to be better able to copulate in zero-G, which could eventually lead to substantial changes in the reproductive organs.
Comment: @ruakh Let's face it, since they're *people*, they would find ways to help the process along.
Comment: Re: "natural selection would lead to the space-people to be better able to copulate in zero-G": And since they're people with a space-faring level of technology, they would probably find other ways to help this process along!
Comment: Harnesses. Kinky little space buggers.
Comment: I just laughed out loud at work.  Thanks for that, hahahaha.
Answer: It could be that our reproductive system doesn't work too well in zero gravity. That would impose a strong selection pressure to adapt the reproductive system to zero gravity, which then in turn might it incompatible with those living in a gravitational field.
The inability of cross-breeding would on one hand be a physical incompatibility, but the divergent evolution might also create a genetic incompatibility (for example, if the genes for the different reproductive organs are incompatible with each other).
In any case, something like this can only happen if the groups are not cross-breeding for a sufficiently long time (which may be reinforced by other adaptations to the respective environment which might make it impossible for the space dwellers people to even visit the planet surface, and at least inconvenient for planet dwellers to be in space).
Comment: Bone density differences could make it a very dangerous proposition.
Answer: If we imagine the adaptations for the different lifestyles are based on genetic engineering ( which seems quite logical in a interplanetary civilisation ) then we could expect rapid changes which may be sufficient to cause effective speciation. Not being a biologist I don't know exactly where you reach the point that offspring are infertile, but if peoples are engineering themselves in the interests of fitting better in specific environments then they are likely to hit that boundary sooner or later.
Also people who engineer themselves to be able to live in space might take things to a much greater extent than one might expect, like the Ousters in Dan Simmons' Hyperion novels - the lack of gravity meaning that our limbs designed for ground travel might be significantly changed or discarded to make it easier to get around.
There could be an interesting debate among colonists at the speciation point, where you have a political question of whether they want to become a new species or not and that becomes a decision for all the colonists of the new world. A speciation referendum is a great starting point for interesting stories.
Answer: A scenario that might lead to this case might be genetic engineering followed by a loss of the technology.
The rationale is if you took a group of colonists and dropped them on a 2G world, they wouldn't survive.  Our circulatory system, bones, and joints couldn't handle it.  Our bodies would break.  The fittest might survive for a while, but eventually the high gravity would kill everyone.
So to survive on the planet you'd probably need one of these:

Anti-Gravity technology to lower the gravity around the colony
Other advanced technology, perhaps mechanical exoskeletons and implanted devices that support the heart and lungs.
Genetic engineering, to modify the human body to make it more sturdy and to re-enforce the circulatory system.  Perhaps supplemental organic hearts.

If you have the first or second, then infertility between the two branches of humanity wouldn't be an issue because there'd be no evolutionary pressure for humans to change.  At least not for hundreds of thousands or millions of years.
If you have the 3rd, interbreeding would still be possible because of the high level of attainment in genetic engineering. They could just alter the genes as necessary.
So you'd have to have the genetic engineering that would make interbreeding impossible... but then lose that technology to prevent further engineering to make it possible.
On the flip side, the zero-G humans really have no reason to ever need to be zero-G humans.  Rotating a space habitat can create 'artificial' gravity.  And there's plenty of places in the universe where, even if at low G, there's enough gravity to prevent major health problems.
Comment: Actually 2G would probably be survivable. See http://worldbuilding.stackexchange.com/questions/158/would-the-human-body-support-living-on-planets-with-a-greater-gravity-than-earth?rq=1
Comment: In that answer you said "So the immediate conclusion is that young healthy adults would survive. Everyone else is in trouble....".  Evolution requires babies.  If babies and children can't survive until they are old enough to reproduce, there will be no evolution.  If medical science has non-genetic engineering ways to get them to survive, there will be minimal evolutionary pressure.
Comment: Yes, it's hard to know what the consequences of growing up in that environment would be - but even if only a few children from the first generation survive that sort of selective pressure will quickly lead to future generations that are better and better adapted.
Answer: Another aspect that no one has touched on is radiation: You will be exposed to radiation that people on Earth aren't.
We can assume shielding and whatnot, and so you'll still be able to live mostly cancer-free and make babies, but you will see mutations that Earth-people will simply not have.
Like others, keeping the population separate, having properties naturally selected for based on environmental changes, and difference in goals for genetic engineering will drive these changes. But the continuous difference in amount and composition of the radiation these space-people will endure will be the driving force behind the actual genome shuffling required to make Homo Aéronomie and Homo Sapiens incompatible.


CUDA threadfence and block level syncronization

Question: I happen to come across __threadfence() in CUDA manual! What is __threadfence() and how is it useful? also can we use __threadfence() to simulate a block level syncronization?
Answer: Modern architectures have a relaxed memory model, this means that the memory accesses are not necessarily executed in the order they appear in the program.
The Threadfence instruction is actually a memory fence - it assures that memory accesses appearing before the fence are actually executed before the fence. As you probably saw in the manual there are 3 variations of the fence dealing with shared (block) memory, global memory and host memory.
__syncthreads by the other hand offer block level syncronization ie threads in the block will wait. Note that __syncthreads also acts as a memory fence for the threads in the same block.
The example from the manual is a good illustration.
Check out the responses from the nv forum too
https://devtalk.nvidia.com/default/topic/412600/trying-to-understand-memory-fence-function-example/


Is there an example of fft where on the y axis wouldn't be power?

Question: my question is the same as in title. Is there an example of signal which after fft operation wouldn't have power on the it's y axis?
Comment: Plenty of examples.  For instance you can FFT daily fatality rates to see if there is any annual or weekly periodicity, etc.
Answer:
Is there an example of signal which after fft operation wouldn't have power on the it's y axis

Pretty much all of them. For the discrete case the Fourier Transform has the same units as the time domain quantity. For the time continuous case it adds $1/Hz$ since it's spectral density. So if your time domain signal is a voltage the units of the Fourier Transform would also be $V$ for the discrete case (which includes the FFT) and $V/Hz$ for the continuous case.
You can use the FFT to calculate the power spectral density but it typically takes a little massaging to have the units to come out to be Watts. In the case of a voltage signal you can square it but to be precise you would have to label it as "Power over a 1 Ohm real resistor" or something like this.
This holds for all field quantities: voltage, current, pressure, displacement, force,  etc.


What's the difference between simultanagnosia and neurological extinction?

Question: Both of these terms describe the inability to perceive more than one object at a time. I'm not too sure what the big difference is between them. Note that I'm referring to 'extinction' as used in neurology (wiki article), and not as used in psychology.
Answer: In extinction the patient may be able to get attention to an object in the contralesional field if it is the only salient object. If there is a competition from another object the patient won't draw attention toward the contralesional field (opposite side of the lesion; generally right parietal lobe).
Simultagnosia is described as the inability to perceive more than one object at a time in each visual field. It is consequence of bilateral damage to the parietal lobe
References
E. Bruce Goldstein-Sensation and Perception-Wadsworth (2010)
Answer: extinction is when two stimuli are presented at once and the patient only identifies one of them but is able to identify each by itself. in simultaneous agnosia, the patient can't voluntarily switch between two stimuli and everything other than the one stimulus the patient focuses, on is "dark".


Odds ratio increasing with variables added to model

Question: I am running a nested 3-block logistic model. In block 1, the odds ratio for Variable 1 (V1) is 2.0 but in block 2 when I enter other variables (demographics) it jumps up to 4.0 which is odd (pun intended). When I run the full model with vars in block 3, the odds ratio returns to the normal values I see in block 1. Something in block 2 is amiss. I've tried systematically removing variables in block 2 to figure out which one is the offender thinking it's a violation of linearity of logit assumption, but several different variables seem to be the issue albeit inconsistently. For example, I figured out V2 was the issue by removing vars one by one from the model. Then I reran without v2 and the effect was still there. Repeat and ID another variable, reran without v3, the effect is still there. I think the issue is some sort of suppressor or interaction effect between the variables in block 2. So 1) how problematic is my issue in block 2? It sets my spidey sense off. 2) any suggestions on how to fix it or what's going on? Also, my hosmer is significant though I know that that isn't always indicative of bad model fit.
Answer: It's hard to diagnose what's going on in a particular data analysis from afar, but in principle it's expected that adding covariates (or adding suitable random effects) to a model would make an odds-ratio further away from 1.
The odds ratio is not collapsible. I.e. if you omit covariates that matter (more than to a non-negligible extent), you end up (on average) shrinking the odds-ratio towards 1 (or equivalently the log-odds-ratio towards 0). So, would a non-collapsible effect measure be better? Not necessarily, because they cannot possibly be constant across different risk levels (while an odds ratio could be - which doesn't mean that it is) so that you end up getting interactions in your model when they might not have been needed (if only you'd used an odds ratio).
Answer: Agree with noncollapsibility being why the OR increases (i.e. the added variable is prognostic for the outcome) but it could also happen if one of the added variables is a confounder. Neither of these options implies anything bad for the analysis or for use of the odds ratio as an effect measure as noncollapsibility simply means that outcome heterogeneity is being accounted for.


How do items affect videos?

Question: Do the items in Tuber Simulator have to be in one room to affect the videos, or can they be in all three and still have the same effect? I want to move some items to the other rooms but I'm afraid that if I do then I'll lose views and subs on my videos since the items aren't all in my main room.
Answer: Items affect videos by upgrading the related topics. For example, NES upgrades the "Gaming" topic. Each level of the topics gives more viewers and subs per video.
Therefore, you do not need to keep the items in the room to keep the bonuses provided by the items.

How do items affect videos?


Conduction, convection, radiation: Does evaporation count as one of those?

Question: The forms of heat transfer are traditionally described as conduction, convection, and radiation.  Is evaporation (or any other change of state) counted as one of those forms?  Or is it considered its own distinct form of heat transfer?
Comment: Just because it ends with tion doesn't mean it is anything like the others.  The others refer to the contributors to the heat flux.  In evaporation, there is a jump change in heat flux at the surface equal to the rate of evaporation times the heat of vaporization.  The heat fluxes on both sides of the surface are determined by a combination of the three heat transfer mechanisms.
Answer: In engineering, heat transfer covers various mechanisms, including thermal conduction, thermal convection, thermal radiation, and transfer of energy by phase changes (e.g. evaporation).
At a given pressure, different boiling regimes exist depending on temperature (the following image applies to water at a pressure of 1 atm).

Image source: Wikipedia
In particular, the nucleate boiling regime is important in engineering (e.g. for the design of nuclear reactors) because of the high heat flux at small temperature differences. In this regime, isolated steam bubbles form at the hot surface, separate from the hot surface, and may condense again somewhere else in the subcooled liquid. Thus, in addition to the heat transfer by convection, the steam bubbles carry away heat in form of their enthalpy of vaporization $\Delta H_\mathrm{vap}$ which is released again when the bubbles condense. Furthermore, the movement of steam bubbles increases the movement of the liquid, thus increasing the heat transfer by convection.
(Note that if too much steam is generated at the hot surface, the steam insulates the hot surface from the liquid, thus strongly decreasing the heat flux after reaching the critical heat flux.)
Answer: Evaporation appears equivalent to one of the cases of heat being transported because the vapor carries enthalpy content away from the liquid. In this regard, one might also claim that fusion (melting) is type of heat transfer because it also transports enthalpy, in this case from a solid by a liquid. The same could be said for sublimation (enthalpy is carried away from a solid by a vapor).
While the three process carry away enthalpy, they are not a different form of heat transfer. Heat transfer is solely the movement of heat. It is not the movement of enthalpy. The movement of enthalpy requires the movement of mass. Heat transfer excludes the movement of energy due to the movement of mass.
To illustrate further, consider the classic case of a system and its surroundings separated by a boundary. The integral form of the energy balance equation around a control volume is written as below.
$$ \iint_{CS}\ \rho \left(\tilde{e} + \frac{p}{\rho} \right) \vec{v}\bullet\vec{n}\  dA + \frac{\partial}{\partial t} \iiint_{CV}\ \rho\ \tilde{e}\ dV = \dot{q} - \dot{w}$$
On the left side, the first term is the flow of energy by mass over the control surface and the second is the time rate of change of the energy in the control volume. On the right side, the first term is the heat flow (heat transfer) into or out of the control volume and the second term is the work flow.
Evaporation moves enthalpy content through a control surface and changes the energy content in the control volume. These two effects are represented entirely on the left side. The three forms of heat transfer are encompassed in the $\dot{q}$ term.
In summary, while they carry enthalpy away from the system, the processes of vaporization, fusion, and sublimation are not different forms of heat transfer. They are phase transformations.
Answer: No.
Conduction, convection, and radiation refer to the transport of energy carriers, such as phonons or electrons for conduction, bulk atom/molecule flows for convection, and photons for radiation.
These three mechanisms transport heat, while evaporation simply requires heat to occur. So evaporation may take energy away from an object, by absorbing energy of carriers such as phonons (vibrations), but it is different because it does not transport heat, unless you are speaking of the bulk convective motion of evaporated molecules afterwards.


Can you water bath a cooked then cooled jam recipe?

Question: I tried a peach jam recipe that is cooked then cooled to thicken without pectin (6+ hour cool time). The recipe says you can freeze it or can it. What would be the safest method to can it? I have always used the water bath method while the jam was still hot. Would you put the cooled jam in sanitized jars, seal and band them, then place in a 'cool' water bath bringing it up to boiling? Would you then process for 10 minutes like usual?
BTW...the jam is the perfect consistency. Would heating it change that? Thanks!
Comment: Welcome to SA!  While theoretically you could can the jam using some kind of very-slow-heating of the jars in a water bath, in practice I can't find any canning authority who thinks that's a good idea.
Answer: Yes, you may can it, but you will need to bring it to a boil again.
From The University of Georgia for the National Center for Home Food Preservation

Because we are interested in recommending jam and jelly making procedures that offer
the highest quality, the least health and safety risks, and the lowest chance of losing product, all
Extension recommendations for jams and jellies include a boiling water canning process for
room temperature storage of sealed jars. Standard canning jars used with self-sealing lids and
ring bands, pre-sterilization of clean canning jars, hot filling of product into the jars, and
processing for 5 minutes in a boiling water canner are recommended for highest quality and to
prevent mold growth.

Emphasis mine.
Please consult a reputable canning source for processing times for your situation and altitude.
The consistency may change, but I don't think it would be drastically different.


How can I control the light intensity of a LED tube?

Question: I want to implement a lighting system and control the light intensity of each LED lamp. I thought about using an LED light with some communication protocol, but it seems that it is very expensive so I decided to design a circuit with a TRIAC (you know the classic dimmer) to be able to control an LED tube or an LED reflector, but I don't know if with that I can get what I want, since I understand that LED lights have an internal driver and I don't know if the circuit that I intend to make will work. What would be the most efficient way to control the intensity of an LED tube or an LED reflector?
Comment: We need some help. Leds operate on DC. Using a triac with DC works sorta. Once triggered it will not turn off until the current falls below the triac holding current. By far the best way is to use PWM (Pulse Width Modulation). Leds are current devices, not voltage. Without knowing more about your application I cannot give you much more. Please state the voltages involved, LED tube, current, etc. How many lamps are involved, what protocol are you looking at. Post a schematic if you have one.
Comment: The way you control the brightness depends on how the power supply works.  Does the manual for the device say that it is dimmable?  If not, do you know what voltage the power supply provides?  Depending on the details it may be easy or you may need to replace the integrated drivers.
Answer: Identify the LED tube, manufacturer, part number.
I bought some that had an internal driver where the 'dim' pin was unused. I provided it with the requisite voltage, and the tube dimmed. Of course I had to dismantle the tube, and google for info on the IC used within it.
The chance of being able to dim a random LED tube from the outside is next to zero, unless the tube advertises that it uses a published protocol for communicating with it.
If the tube is the type where you can plug it into an existing fixture, that means it has a wide range input voltage capability to cope with the various different components it might be supplied from, guarranteed to prevent you being able to control it simply by altering or chopping the supply.
Comment: I found the same information, I must use a LED tube that has a specific connection to be able to control the dimming, otherwise it cannot be controlled.
Comment: @WalteRPH many LED lights that are designed to plug into the wall are also designed to work with triac dimmers. They should be advertised as dimmable. But you didn't really say what kind of LED tubes you're talking about.
Answer: Short answer - you can control the brightness a very little only.
The reason is that almost all LED bulbs which work on the mains have a circuit inside which convert the mains into a more "user friendly" voltage/ current for the LEDS. Changing the voltage by using dimmer tactics will more likely cause these circuits to fail rather than have any useful impact on the brightness.
Having said that, there ARE a few LED stacked "lights" which use a large number of LEDS in series powered directly from mains with just a series resistor. These CAN be dimmed.
However - you have to know which is which before committing.


Zend Framework2 using Zfcuser & Bjyauthorize routing

Question: I'm a beginer zend framework programmer. I did use ZfcUser for authentification and Bjyauthorize for authorization. I have to type of users : normal users and administrator . So what i want to do is to route the user to page A and admin to page B after authentification .
In the Zfcuser configuation file there not this possibility  we have just this line
<code> 'logout_redirect_route' => 'zfcuser/login',
</code>
how can do specify a diffrent route for my differents users?
Answer: To me your problem has nothing to do with ZfcUser or BjyAuthorize: Just let the user and the admin go inside your controller and there you can dispatch them depending on the user role.
<code>return $this->forward()->dispatch('MyModule\Controller\Index', array('action'=>'PageB'));
</code>
Answer: Suppose you have an 'admin' role in bjyauthorize that you want to redirect to another route.
In your loginAction replace the code:
<code>    if ($this->zfcUserAuthentication()->getAuthService()->hasIdentity()) {
        return $this->redirect()->toRoute($this->getOptions()->getLoginRedirectRoute());
    }
</code>
with this code:
<code>    if ($this->zfcUserAuthentication()->getAuthService()->hasIdentity()) {
        $roles = $this->serviceLocator->get('BjyAuthorize\Provider\Identity\ProviderInterface')->getIdentityRoles();
        if (in_array('admin',$roles))
        {
            return $this->redirect()->toRoute('admin_route');
        } else {
            return $this->redirect()->toRoute('user_route');
        }
    }
</code>


How to get the new ISO (from source code?)?

Question: 6.0-rc1 was just released. I couldn't find the iso there, only 2 assets (2 files in archive formats). How to create an ISO (if that's the assets are for)?
Comment: As far as I know, there isn't actually a 6.0-rc1 available. Beta 1 and Beta 2 have been on https://builds.elementary.io/ for a while, but those are .iso files. Where are you downloading from?
Comment: No, I mean 6.0-rc1 was on GitHub. Check the "os" section here: https://releases.elementary.io/ or here: https://github.com/elementary/os/releases/tag/6.0-rc1
Comment: Yep, that's the build system generating a release. They are now on https://builds.elementary.io/ and you will need to be a sponsor of elementary on GitHub to access them.
Comment: Thank you. And do you know if the final release of Odin also going to be only for the sponsors, or at first sponsors-only then after some time, general public?
Comment: The official stable release will be made available pretty much as the current stable release is now on the main site.
Answer: ISO's are available pre-built by sponsoring elementary on GitHub and can be downloaded at https://builds.elementary.io/

If you wish to build you own ISO, the instructions are avilable in the repository wiki at https://github.com/elementary/os/wiki/Building-ISO-Images
Comment: Thank you, Lewis.


Using other college/universities notes for practice?

Question: I like to get as much practice as I can before an exam so is it permissable to use other colleges or universities' practice exams or handouts for practice. I am not distributing them to anyone, selling them or profiting. Just want to get as much practice as possible. I was wondering if this is ok?
Comment: **Reading does not violate copyright.**
Comment: You want to study and it is OK. I am wondering why this may not be OK.
Comment: I'm worried I am violating copyright by using materials of another institution without being a student there. I am not distributing them or anything, just using them to study/learn but I just want to be 100% sure I am not doing anything wrong because I don't know much about the copyright and fair use laws
Answer: If they've put it up freely available online, then they have made it available for people like yourself to read. Enjoy!
Answer: Studying universities practice exams, handouts, pamphlets, books, etc. is perfect only if you respect their privacy and rights.
Comment: yeah I'm not 100% sure what their privacy and rights entail. Can I use it for my own studying and delete them after? I use google to find the files, download them then study off them and delete them after is that violation of anything?
Comment: @Practice You should look at the copy rights of the content you are downloading. Some academic publications are only available for universities' own students, while some other are published publicly to be used by other students too. I can not generally tell you what you can do.


How is it possible for the percentage of respondents who answer "Have you ever done X" to decrease with age?

Question: Consider the following survey conducted by Google and Gallup about gender differences in computer science learning:
https://services.google.com/fh/files/misc/encouraging-students-toward-computer-science-learning-brief.pdf (page 1-2)
Among other findings, it says that in a survey (conducted in 2015-2016), 57% of 14-year-old girls and 43% of 16-year-old girls answered "yes" to the question of whether they have ever learned any CS. The study reports this as "Reported learning of CS peaks at age 14, then generally drops for both [boys and girls]" (boys also drop here, but less than girls)
However, the question asks if the respondent has EVER learned CS. Therefore, if this is true of someone at age 14, it will by definition also be true of that person when they reach 16. Thus, assuming respondents are answering truthfully, this difference must be a cohort effect rather than an effect of age. In other words, two years before this survey was taken (when all the current 16-year-olds were 14) the "percentage of 14-year-old girls who had ever learned CS" must have been no greater than 43%. Thus this percentage must have increased from 43% to 57% in the space of two years. If true it seems this would be an extremely positive development, yet it is not reported that way in the study.
Is this type of anomaly (where the fraction of respondents who answer "yes" to whether something has "ever" happened to them goes down in the same group over time) common in these types of surveys? Am I correct in the assessment that there must be a positive development here which was overlooked by the study authors? Or are there other explanations which I'm not thinking of?
Comment: Was it longitudinal/panel study? I.e. same respondents asked twice? Sounds it wasn't since you mention cohort effect.
Answer: Are you sue the same question was surveyed two years earlier? If not, then the number didn't "increase" because it wasn't measured before.
The data clearly points to a cohort effect though, you are right about this.


Do you make a word then give it meaning, or do you think of a meaning and assign a word to it?

Question: I wonder which is more effective, creating a list of conwords then giving definitions or, creating a list of definitions then assigning conwords?
Comment: Readers of this question may also be interested in this one: https://conlang.stackexchange.com/q/1608/142
Answer: meaning and then words, because every language is built on the needs of the environment in which is based. List the main words used in that environment according to the geography and culture you are planning, then you can start to separate it into groups and assigns common radicals and all the other word-creation processes.
Answer: I have mostly made up conwords when I had a new meaning in mind. Most of the time now I am deriving new words from combinations of existing words. I do occasionally think of a conword that sounds so good that I replace past words or seek out a meaning so that it will become a fairly common usage.
That said, one way or another, I do wind up with conwords I like but don't need yet. I keep a list of them for future use. Importantly for my productivity, I have a counterpart list of English concepts for future use: so that I neither forget them nor randomly divert myself from the task I'm on when I think of them.


Eclipse hangs in building project after each save

Question: This has become so annoying.
Each time I save an Ant build I get Eclipse in rebuilding itself...
I have Java Project which depends from a non-Java project. When I edit a file in the non-Java project, save, build. I get the whole project sync process launched... 1-5 minutes later I get the prompt back.
Comment: it also happens if I edit the java project & save & run.
Answer: You could try to turn off automatic building globally in the Project menu. If you do this, the Build project... and Build all options become enabled, allowing you to manually build when necessary.
Another option may be to set the refresh workspace policy of your executed ANT build (granted you are using the Eclipse AntRunner): in the Run configuration on the refresh tab you could manually select only to update the project changed by the ANT build.
Comment: hum, can you help me more. What do u mean with : 'Run configuration on the refresh tab'. I'm not an expert in Eclipse, yes I run the Eclipse Ant Runner. Already turned-off the auto-build.
Comment: Sorry, I was not precise, because Ant is run as an External tool. So select Run/External tools/External tools configuration, then look for your Ant task on the left, select the refresh tab on the right (with your task selected), and make sure, nothing unneeded is selected to refresh.
Comment: OK thx. Did what you said, refresh only the ressource, removed recursive refresh.... same story.
Comment: Its is a bit shorter, but every 3 edits of a file in the java project I get a resync launched.
Comment: Sorry then, I have no further idea.
Answer: I had the same problem, everytime I edited web.xml, it would hang showing busy icon for 5-10 seconds. I tried an older web project, and it worked fine.
I discovered that the web.xml web-app tag was different and after changing it, the problem went away. I think it has something to do with the lookup of XML schemas.
I think it is possible to disable the schema check (that goes out and download the schema every time).
But otherwise find what I changed below to make it stop hanging on every save.
From:

`<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
    version="2.4">`

To:

`<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns="http://java.sun.com/xml/ns/javaee"
  xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_4.xsd"
  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
  version="2.5">`

I know the version is different 2.4->2.5 but notice it references schema location differently.
Comment: I've disabled all validators and still get this problem. Is it possible to see what eclipse is up to when it hangs?

(NB. Confusingly, when I disable the validators, eclipse tells me that it need to rebuild the entire project and then says its busy validating...)


How to get started with Python Coding in Blender?

Question: I want to start programming to help me in my artworks, and don't know python. However, I can pick languages quite easily. Where should I get started and what's the software I need? Plus, if I want to develop the Game Engine, will I need C++ programming knowledge? I want to become a developer for the game engine.
Comment: It will be useful in your question to state your actual months of experience with Blender and Python.  Even if people measure experience different ways.
Comment: Less than a year. No experience with Python.
Answer: Many times as you know more about Blender you will need less Python.
In Blender use the Python console window and execute your python from a text window.  Note that tool tips show Python references.  See text output in the Blender console window. One small project suggestion is to print out the names of the Blender Objects in the console window.
Python.org site can be incrementally read and searched via the internet.  There are certainly free videos and texts on the internet, with and without Blender.
Here at Stack Exchange there is a Python group.
Note that in Blender the [info window] shows Python for many of your user actions so you can observe and customize.
If you want to reinvent the 3D Wheel and get Python experience, pick a small project such as one that has many scripts and solutions already, so one may refer to known solutions.  Here is one idea.  Write Python to change the content of a [text] object over time from a Python list of strings.
Know that Node programming exists for the Compositor and Materials et cetera.  There is also BAN  ... Blender Animation Nodes.  There is also the driver feature of Blender which use Python.  One small project might be to animate the visibility of two objects based on the visibility of a third object.
I am not addressing the Game Engine in particular.


How can I remotely log out of my Google account on a recently used device?

Question: I have noticed a device I don't recognize in the list of recently used devices in my Google account. I'm not overly-concerned about it, because I think the device belongs to one of my family members, but I would still like to log out of it remotely. However, that doesn't seem possible. From an internet search, it seems that this is a fairly recent change, as it used to be possible in the past. What options do I have, other than changing my password? Has Google made this change because they are trying to get me to change my password more often?
Answer: I went to this https://myaccount.google.com/
Then clicked the "security" tab
Scrolled down to "my devices"
Then it shows all the devices you are logged into
Click the 3 dots "options" tab and click log out
Answer: The "Device activity & security events" section of https://MyAccount.google.com will show you all of the devices that have been used to log into your account recently, but you can't force a logout from there. The only way to logout of other devices is to change your password, and that will log you out of everything except the device you use to change your password.
Comment: There is now a logout option in the devices view described here
Comment: Will enabling two-step verification not sign me out of my devices?
Comment: Probably? I've had 2FA on so long I don't even remember whether it kicks you off other devices. It's worth a try.
Comment: Not true anymore. I just changed my password in my gmail and my phone kept have access to my gmail, google drive and so one..
Answer: Logging out of Gmail remotely is a great idea if you've accidentally left yourself logged in on a public computer you no longer have access to, like in a library or school. The same screen for logging out of web sessions is also useful for seeing from where your account has been accessed recently, including the apps that have access to your Gmail.

Open Gmail on a computer and scroll to the very bottom of the page below all of your messages.
Click or tap the Details link on the bottom right. It's right next to a sentence that reads "Last account activity:"
Choose the Sign out all other web sessions button.

Note these facts about signing out of your account from the last account activity page:

You will not be signed out of the current session you're using to access this option.
This does nothing to your Gmail password, so if another user has access to your account because they know your password or it's stored in their browser, and that's why you've logged them out, the only way to be sure that they don't get into your account again is to change your Gmail password.
Email clients connecting through IMAP are not signed out. For example, if you're logged on through the Gmail mobile app as well, you will remain logged on.
Comment: This answer is super decieving and dangerous! "Details" in Gmail will only show Gmail sessions, but will not show all Google Account sessions! For example, if you are logging in just docs.google.com, the session won't be listed there! So you might think "whoa I am safe, I am not logged anywhere else", but it's not true! Then, gmail can be open any time on that machine without giving a password! @ahorn


Any suggestions for a vehicle [Nissan Frontier] outside temperature guage - dashboard mounted

Question: Hubby's truck doesn't have an outside temp gauge.  He needs it for winter as he plows.  What suggestions do you have please [birthday present]  thank you!
Comment: Hi Sandie: for future reference, we try to avoid shopping questions in the main area as the information has as tendency to become out of date quickly. However, we almost always have chatty people hanging around in the chat room: https://chat.stackexchange.com/rooms/340/the-pitstop  Please feel free to stop by there any time you need more ideas for the Hub's truck. :-)
Answer: I bought one of these years ago for a car that didn't have an outside temp gauge and it worked great. Bought it at Walmart but they have them at auto stores too. You just have to run the sensor to the front of the car and outside the engine compartment. The base unit mounts inside somewhere on the dash. The units are powered by one or two AA batteries.
Here's a picture of a similar one.
Hope this makes Hubby happy.


How can people be encouraged to suggest edits to questions

Question: Seems like a lot (most?) badly received / asked questions can be really improved with a few suggestions. And there is the will there to help the wording of questions.
So there should be something which encourages this?
Comment: People do earn reputation points for making good edits to questions. And that incentive is well-advertised. So the encouragement is there. I'm not very active here on Phil.se, but on my stacks I'd personally prefer to see more question-askers take a proactive approach to reading and responding to comments by editing their own questions. I've seen one or two askers on my sites (not here) try to shift the burden of asking a good, clear, well-presented question to other people in the community, and that rubs me the wrong way.
Comment: @DanBron i agree with that... i do think that a couple of helpful etc. comments can usually make all the different tho :)
Answer: Coming from other SE sites, the only benefit to editing is the gain in reputation points and presumable the knowledge that you've helped the community by improving its content if that's something that matters to you.
On the other hand, if a question is seriously flawed, many people won't bother to save it, simply because it's time consuming, in some cases takes guessing what the questioner actually means, and then there's always the possibility that the original poster will get angry and revert all your edits to their apparently perfect literary work (I know you've commented on questions to say that you're always willing to edit questions to improve them - which is great! - but only a very small number of people who use the site will remember your name in the first place no matter how much you post). As a result, it's simpler to recommend a closure under the already pretty clearly-defined rules and hope that the user re-submits a better one. This is not to be taken as an insult, simply a statement that the question isn't really a good fit for the site in its current state.
This is how SE works, for better or for worse: There is a small benefit for helping improve things, but ultimately the reward is small enough that after a point people will not bother and instead rely on you to improve it if you want answers.
The question then becomes how to avoid people thinking that a question is beyond being worth saving. In my experience, things that can certainly help with avoiding the most common closures (without wanting to re-write the whole SE posting guidelines) are:
Have a clear title
Sounds pretty simple, but you're not trying to write a bestselling paperback or a tabloid news article where you want to be flowery, thought-provoking or witty in the title. If you can summarize the question in a single sentence, then put the question in the title (with a question mark!) and re-iterate and explain it in the question body. Otherwise, a general but descriptive topic-header such as "A question on Berkeley's Philosophy of Mind" and then the question stated below should be sufficient. The question isn't just for you - you want other people to easily find the question at a later date if the have a similar question or if they remembered an interesting point raised in the answers, and a descriptive title is incredibly important like this. I've seen great questions get almost completely overlooked because from the title it looks as though the question is going to be poorly-written, vaguely worded, not relevant or something of the sort.
Make the question answerable
Philosophy.SE, isn't a particularly good place for questions abut broad philosophical concepts or questions in general - "What is the meaning of life?" and "Is it true that we can't know if the world around us is real?" can't be answered in the way that SE expects but instead generates discussion (and SE isn't designed for discussion beyond the chat, which I don't use). Instead changing the central question can fix this in most cases - "Are there philosophers who think that life has no meaning?" (Answer, yes, and then you'll get a list of positions on that), or "Has there been any refutation to Descartes' inability to prove that the world around us is real?" are both much more answerable, because the answers are facts.
EDIT: One thing I always try to do with my questions is to finish the explanation with a (re-) statement of the question in bold at the end of the more in-depth description in the question body. That way, even if most of what I've written there isn't answerable, the question at the end is and so I can at least get some related information.
Make it within the scope of the site
Sounds pretty simple, but with only a few exceptions where there are significant overlap (e.g. Mathematics and Logic where the same things are taught in only very slightly different ways), you need to make sure that the question isn't more appropriate for another SE site or indeed another site in general (you could think of non-answerable as a sub-section of this). This is especially the case if you're not familiar with the existing philosophy in the area - a question you might think is about 'the philosophy of music' might in fact be more of a music question than a philosophical one.


Calling contract deployed on Tezos sandbox using Taquito

Question: I've a simple contract deployed on Tezos sandbox (https://assets.tqtezos.com/docs/setup/2-sandbox/) and I'm using Taquito in frontend to call this contract.
Earlier, I deployed the contract to global testnet and used the key to set provider (using InMemorySigner), but what should I give as key if I'm using a sandbox running on my localhost? I tried giving some random key but it gave me server error. (Also, any way to see some kind of logs from the server, ie, deployed sandbox to see what exactly went wrong?)
Answer: Flextesa comes with 2 preinstalled accounts: Alice and Bob. You can find their secret key in the link that you provided (the value after unencrypted:):
- alice
  * edpkvGfYw3LyB1UcCahKQk4rF2tvbMUk8GFiTuMjL75uGXrpvKXhjn
  * tz1VSUr8wwNhLAzempoch5d6hLRiTh8Cjcjb
  * unencrypted:edsk3QoqBuvdamxouPhin7swCvkQNgq4jP5KZPbwWNnwdZpSpJiEbq
- bob
  * edpkurPsQ8eUApnLUJ9ZPDvu98E8VNj4KtJa1aZr16Cr5ow5VHKnz4
  * tz1aSkwEot3L2kmUvcoxzjMomb9mvBNuzFK6
  * unencrypted:edsk3RFfvaFaxbHx8BMtEW1rKQcPtDML3LXjNqMNLCzC3wLC1bWbAt

You can use Alice's or Bob's secret key in the InMemorySigner when running contracts in your sandbox.


Why is multivariable continuous differentiability defined in terms of partial derivatives?

Question: Both in my textbook and on Wikipedia, continuous differentiability of a function $f:\Bbb R^m \to \Bbb R^n$ is defined by the existence and continuity of all of the partial derivatives.  Since there is a notion of a (total) derivative (AKA differential) for multivariable functions, I'm wondering why continuous differentiability is not defined as existence and continuity of the derivative map $Df(a)$?  Is there some reason why having existence and continuity of partials is more convenient or maybe continuity of the total derivative is too strict of a condition?
Comment: They are equivalent. Got to start with one of them.
Answer: Continuous differentiability of the function $f: \mathbb{R}^m \to \mathbb{R}^n$ (in terms of partial derivatives) is equivalent to existence and continuity of the map
$$Df: \mathbb{R}^m \to L(\mathbb{R}^m, \mathbb{R}^n)$$
$$ x \to Df_x$$
which takes a point to the derivative at the point. Any book on analysis on $\mathbb{R}^n$ will have a proof of this fact.
Comment: Curiously enough, some other user posted a heavily related question (part of the iff statement) here http://math.stackexchange.com/questions/1868748/missing-continuity-condition-in-theorem/ .
Comment: I see.  Thanks!$ $


Why are water waves transverse or up and down?

Question:
why are water waves transverse? why aren't the Longitudinal?
Comment: Possible duplicate of [Why can't transverse waves travel through a liquid?](https://physics.stackexchange.com/q/164491/)
Comment: Actually, they are both.
Answer: Water waves have a transverse and a longitudinal component. As I understand it the components are the direction of motion of the wave itself and the motion of individual water molecules. The latter comprises the longitudinal component, because water molecules have circular orbits in the wave. I think this becomes clearer with this image
Answer: Water waves can be quite complicated, they can be both transverse and longitudinal depending on what type of wave they are. I will list three types of waves that are common:
Capillary waves
Cappilary waves happen at small amplitudes and wavelengths and they are most likely what's happening in your picture. The restoring force is surface tension, so every part of the wave that's curvy has a force that is trying to make the surface less curvy. This creates waves that are mainly transverse.
Surface waves
Surface wave is a name that usually decribes a typical ocean wave. These happen when the wavelength is smaller than the depth of the ocean so they also fall under the category 'deep waves'. These deep waves show complicated behaviour: they are not perfect sinusoidals but are more peaked and the motion is a combination of longitudinal and transverse, resulting in a kind of circular motion as seen in Tatjana's answer.
Shallow water waves
Water waves are shallow when the wavelength is much larger than the depth of the water. Shallow waves are mostly longitudinal. Surprisingly tsunami's are shallow water waves even though the ocean is really deep. The wavelength of a tsunami can reach over 100km. The speed of a shallow wave goes as $v=\sqrt{gd}$ with $g$ the gravitational acceleration and $d$ the depth of the ocean floor. Where the ocean is over 6km deep tsunami's can travel at the speed of commercial airlines.
Answer: The surface waves are mostly trasversal because you push water in a localized manner and watch a side effect; the volume waves are mostly longitudinal (sound waves in a water volume below a membrane).
Answer: Physics is an empirical science, that is an observational science. Waves in matter in general will have both a transverse and longitudinal component.
Merely by looking at the picture you have posted we can see that the transverse component of motion is far larger than the longitudinal motion on the surface of the water. By continuity, we would generally posit the same in the main body of the water.
(A more quantitative observation will look at how both these components dampen with time, with distance from the disturbance both along the surface and also in the body of the water. And a theoretical study will try to connect this with the theory of shallow waves).


difference between correlation and coefficient in a regression

Question: What's the difference between correlation and coefficient in a regression?
If the author writes "there is a positive relationship between x and y" or "there is a positive correlation between x and y" is he taking about correlation or the coefficient in a regression?
Answer: Il your regression is $y=\alpha+\beta x+\epsilon$, then
$$\hat\beta = \frac{\sigma_{xy}}{\sigma^2_x},\quad\text{while}\quad\rho_{xy}=\frac{\sigma_{xy}}{\sigma_x\sigma_y},\quad\text{so}\quad\hat\beta=\rho_{xy}\frac{\sigma_y}{\sigma_x}$$
Since $\sigma_y/\sigma_x>0$, $\hat\beta$ and $\rho_{xy}$ have the same sign: a positive coefficient implies a positive correlation, a negative coefficient implies a negative correlation.
An example in R:
<code>> set.seed(1234)
> x <- 1:10
> error <- rnorm(10)
> y <- 3 - 2*x + error
> fit <- lm(y ~ x)
> beta_hat <- fit$coefficients[2]; beta_hat
        x
-2.035185
> cov(x,y) / var(x)          # == beta_hat
[1] -2.035185
> rho <- cor(x,y); rho       # same sign as beta_hat
[1] -0.9873359
> rho * sd(y) / sd(x)        # == beta_hat
[1] -2.035185
</code>
Comment: Please define your notation! $\sigma_{xy}$ is what (etc.)?
Comment: PS I did it in my response, maybe that's enough.
Comment: @Lewian I suppose it is a standard notation, see
Comment: Yes it is, and I have no problem understanding it, but you can't assume that the person who asked the question knows it as well.
Answer: If the author writes "there is a positive relationship between x and y" or "there is a positive correlation between x and y" then they would be talking about the correlation, not necessarily about the sign of the coefficient. A positive correlation means that Y increases with increasing X. I can't comment on what test the author used, but many coefficients also reflect the sign of the correlation. For example a Pearson correlation coefficient of -1 means perfect linear anti-correlation. Still, there might be  some coefficients that don't behave like this, so a "positive relationship" always refers to the sign of the correlation and not necessarily to the sign of the coefficient of the specific test.
edit: For example a Chi-Square test would not tell you the sign of the correlation, just a presence of a correlation. So if the author referred to a negative correlation it would not mean that the Chi-Square coefficient is negative.
Comment: If you want to compute the sign of a correlation, you only need to compute the correlation, not a test.
Answer: If you have two variables $x$ and $y$, correlation measures the relation between $x$ and $y$ in a way that is symmetric between $x$ and $y$, i.e., with $\rho_{xy}$ denoting the correlation between $x$ and $y$, $\rho_{xy}=\rho_{yx}$. I'm using the notation of the answer of Sergio here. A standard regression model looks like this:
$$
y=\alpha+\beta x+\epsilon,
$$
with $\beta$ the regression coefficient of $x$, $\alpha$ a constant intercept term, and $\epsilon$ a random error term independent of $x$. $\beta$ is related to how strongly $y$ depends on $x$. The answer of Sergio states that $\beta=\rho_{xy}\frac{\sigma_{y}}{\sigma{x}}$, $\sigma_x$ and $\sigma_y$ being the standard deviations of $x$ and $y$, which says how they are formally related. Note that this means that $\beta$ can be large if $\rho_{xy}$ is not that large in case $\sigma_{y}$ is far bigger than $\sigma_x$. The correlation $\rho_{xy}$ measures the connection between $x$ and $y$ free of the influence of $\sigma_x$ and $\sigma_y$, whereas the regression coefficient $\beta$ depends on these.
This also implies that the regression coefficent $\beta$ is almost always different from the coefficient $\gamma$ of a regression of $x$ on $y$ in a model
$$
x=\delta+\gamma y+\eta,
$$
i.e., regression coefficients are not symmetric in $x$ and $y$.
In fact, the idea of regression of $y$ on $x$ (first regression) is that $y$ is a function of $x$ plus some error (random deviation), and the error appears in $y$, not in $x$ (estimating the regression will minimise the squared error of the regression line comparing the predicted $y$ by the regression with the observed $y$), whereas the second regression of $x$ on $y$ implies that there is random error in $x$, not in $y$, leading to a different minimisation problem for estimation.
I don't have time to produce and embed a graph, but regression of $y$ on $x$ puts a line in a scatterplot between $x$ and $y$ that minimises the sum of squared distances of all $y$-observations to the line in y-direction, regression on $x$ on $y$ produces a line that minimises the sum of squared distances to the line in x-direction, and correlation essentially gives the slope of a line that minimises the sum of squared distances to the line of all $(x,y)$ orthogonally to the line, after having standardised the $x$ and $y$ to remove the influence of $\sigma_x$ and $\sigma_y$.
If an author writes about correlation, chances are they mean correlation ;-). If an author writes "there is a positive relationship between x and y" it doesn't matter because correlation and regression coefficient are positive in the same cases, although they won't have the same values, see Sergio's response.
PS: Note that this becomes more difficult and somewhat different in multiple regression. If there is $y$ and more than one $x$-variable, $x_1,x_2, x_3,\ldots$, say, it actually can happen that the correlation between $y$ and $x_1$ is positive whereas the regression coefficient of $x_1$ in the multiple regression for $y$ on all $x$-variables simultaneously is negative, due to potential dependence between different $x$-variables. If an author in such a situation says "there is a positive relationship between $x_1$ and $y$", chances are they mean the regression coefficient, however this is imprecise terminology and should be avoided.


Micro HDMI to VGA MOnitor for Raspberry PI 4b

Question: I'm using a Raspberry Pi 4b. I want to use my Acer LCD Monitor Version G206HQL  bd, which uses VGA or DVI inputs. I am also using a Micro HDMI to VGA adapter for my RPI to communicate with the monitor, but when the input type to the monitor is switched to VGA and I attempt to begin the boot up process for the Pi (using NOOBS at first but eventually Raspian) the screen on the monitor simply says No Cable Connected. The raspberry illustrations do not come to screen, and the boot is not output to the monitor. If anyone knows how to fix this issue, please respond.
Comment: Ah let me see.  In my Rpi3 days I did use HDMI to DVI/VGA adapter for my non HDMI monitor.  But now there might be a problem with Rpi4B which, I think, defaults to HDMI monitor.  When you plug in your HDMI monitor, even without power on, Rpi4B would supply logic circuit 5V power to HDMI to find it config to prepare for display as soon a power is on.  I noticed that the /boot.config.txt no longer has non HDMI device tree driver statements.  So it might mean that you need to provide your own DVI/VGA driver.  One way to verify is use Rpi3 to boot your VGA mon and then try Rpi4B.
Comment: Another thing is that I read the Rpi4B supports composite video (home TV like).  So if your VGA mon has composite video input, you try use it as a get around.  But I am not very sure of what I am saying, because I am only using HDMI mon for my Rpi4B now.
Answer: this might help:
hdmi_drive=2
#config_hdmi_boost=4
hdmi_group=2
hdmi_mode=47
hdmi_force_hotplug=1
disable_overscan=0
enable_tvout=0

credit to the poster at:
Can a simple cable convert HDMI output to VGA?
The only diff in my case is:
enable_tvout=0

with enable_tvout=1 there was still no signal at monitor
And I found config_hdmi_boost=4 was not needed.
The Adapter I used is not externally powered... I got this from amazon.ca
https://www.amazon.ca/gp/product/B00ZMV7RL2?ref=ppx_pt2_dt_b_prod_image
Comment: Exactly above settings helped me also, and i tried few different configurations before. I did connect my Pi 4 to VGA using HDMI switch, since i even didnt have the exact adapter - so now i hope it will work the same for the second Pi 4 of mine :)


Causing a black hole

Question: So in my concept, humanity needs to permanently destroy an enemy planet. But their defense systems won't allow the humans to get close enough to destroy the planet with whatever weaponry. Would it be possible to somehow start a black hole or singularity in the system to destroy the planet?
Comment: How far is this planet away? Far enough for a blackhole not to bother the home planet?
How is this generated black hole able to reach it but not something like a miniature star sent their way? Is this something that could then be used to destroy the home planet, or a defense to protect against is? How much energy do they have to work with?
Comment: We need some more information to be able to answer this, especially regarding the technology that the humans have available, the type of star that the enemy planet is orbiting and other bodies in the enemy system.  (Making a black hole requires truly vast amounts of mass, much easier to use what is already there than try importing planetary/stellar masses.)
Comment: It's a long while away, it would be close to the human border though. I was thinking that the enemy was using humans and turning them into cyborg killing machines. Idk if what I'm saying is realistic or not, my idea of what  distance is in space is basically just stellaris maps. @DangerLake
Comment: @KerrAvon2055 yeah you're right, this is my first post I didn't know what to include. In this scenario humanity is at least 1000-2000 years advanced from now. The planet orbits a g-type star (like ours) and is a similar distance from the sun as mars. 2 moons. There are various other planets in the system as well as an asteroid belt. (Pretty similar to ours)
Comment: If the black hole is intended to destroy the planet, then it's weaponry. But your conditions state that the defence systems won't let the humans get close enough to destroy the planet with whatever weaponry. So there's a contradiction in the question. Other long-range weapons than black holes are available, so it's not like a black hole is the only weapon that can be used from a range that's outside the planet's defence systems.
Comment: Check out [Niven & Pournelle Lucifer's hammer](https://www.fictiondb.com/title/lucifers-hammer~larry-niven-jerry-pournelle~116750.htm) for an option involving miniature black holes perforating the crust a planet and proceed orbiting *inside* a planet. The planet will get grinded, crunched and slowly  falls apart long before it is being absorbed.
Comment: In the "three body problem" the "earth hero" of the story destroys another planet by simply advertising it's existence to neighbouring alien civilisations and then they actually make the effort to destroy the planet. Also, what you talking about, some sort of type I-IV civilisations or just your run of the mill "future earth" tech.  Even if your story characters can't physically attack, there is always a way to manipulate _other_ sentient's civilisations. So without further restrictions on this question(which is a 1/2 paragraph in length) this is way too broad and needs a whole lot of focus.
Answer: Black holes are quite heavy, the smallest one observed is 3.8 times the mass of the sun. So too move an average sized black hole would require an astronomical amount of energy, more than $10^{30}$J, which is more energy than the earth would make in trillon years, (if you are working with that much energy it would probably be easier to accelerate an asteroid relativistic speeds). Additionally even if the mass isn't initially a black hole, it would still take a large amount of energy.
An alternative solution could be to turn an object in the star system into a black hole. This could be done by launching a small black hole ($1,000,000$ Kg) into the object, the black hole would then "eat" the object, and grow into a larger black hole. Unfortunately this wouldn't increase the gravitational force from that object, so it wouldn't gravitationally destroy the planet, unless the black hole hit the planet itself.
But if a small black hole is fired into the star, as it "eats" the star, the gas would get compressed and heated as it falls into it, which would then ignite and explode, similar to a nova. The explosion would push a significant amount of plasma from the star into the space around the star, including the orbit of the planet, and considering how damaging a little bit of stellar palsma was (the electromagnetic effect would especially devastating to electrical effects), having a significant amount of such plasma through out the system would destroy the planet.
hopefully that helps.
Comment: I dont think that accelerating a rock to relativistic speeds is a working strategy. You first need to find a good rock within a good distance of the target since you dont want to hit them in a couple of years time, build the accelerator on it, then accelerate it over a certain time period until it moves at the desired speed. Its likely that the defenders will track likely rocks and the acceleration method can be detected long in advance from lightyears distance. The attacker would need to protect the rock against deviating attacks or destruction by another rock for most of the journey.
Comment: @Demigan agreed that it is a technically challenging endeavor, but if their civilization is capable of moving black holes with masses greater than the sun and no solid surface to push against, then i imagine that it would be easier to put that energy into accelerating an  million tonne asteroid to $299 792 457$ $ms^{-1}$ (which would have enough energy to tear apart a planet) . As to visibility/detection, if it was launched from alpha centauri at that speed, there would be only 0.4 milliseconds (the human eye takes 400 milliseconds to blink) between seeing it leave and it arriving at earth
Comment: being able to push a BH and launching relativistic projectiles are different things, especially if you want to accelerate a rock from Alpha Centauri to relativistic speeds towards earth. It takes time to accelerate that rock, if only to prevent the rock from desintigrating due to the acceleration forces. That means its going to take days, weeks or months to get it up to relativistic speeds, and that acceleration period is what can be detected for far longer than 0.4 seconds and is its weakness: place somethjng in front at a distance to either deflect it or splatter it and you are safe
Answer: Frame shift: blacken their star (stealth Dyson sphere)
Graphene absorbs 2.24% of all light passing through it for each sheet of atoms present.  To reduce the visible light reaching their planet by 50%, spin about 30 layers of graphene around the star (formally a Dyson sphere).  The distance between sheets is about 3.3 angstroms, so you need a full 10 nanometers.  It melts at about half the Kelvin temperature of the Sun, so you need to move it out a little from the surface, so take 6E18 (the Sun's surface area in meters) times 2.  You also need to do this so it doesn't glow just like the star and provide useful visible light; at 3000 K it should glow dimly with heat that mostly bounces off the atmosphere.
So you need 1E-8 m x 6E18 m^2 = 6E10 m^3 of graphene, or about 60 cubic kilometers.  Grab some comets and get to work!  It'll be easier than making a black hole, at least.  Note also an efficiency expert might not even make it a full Dyson sphere, just a little strip along the orbit of their star that is easier to keep in a stable orbit, which could cut this down to less than a cubic kilometer's worth.  Focus more on repairing any damage they do to the graphene with bombs, and slaughtering them when they venture out from their defenses.
Comment: What methods would you use to deploy those sheets undetected, and how do you protect them? They will "detect" what is going on when the sun's light gets dimmer, and then will either push it into the sun or try to destroy it. Assuming jets from the sun dont do a number on it.
Comment: I took this as a siege where the defenders are only safe within their defenses, so that their counterattack might be stopped.  Additionally, a Dyson sphere of this type would be made by trillions of tiny fabricators; only the part actually damaged needs to be remade.  If the enemy is sufficiently rambunctious, it might make more sense to slip in sunshields at random distances from the planet and maintain their positions actively until they are destroyed.
Answer: Through some really intense stretching of quantum entanglement or hand-wavium perhaps.
Star-Trek did recently with a Red liquid concentration of mass.
Problem is a black hole would likely destroy entire systems unless there was a way to set an expiration time on them.
Maybe long ranged Gravity crushing technologies? Though if they have that kind of power, destroying planets may become too easy.
Edit: Perhaps making the planet uninhabitable to life would be a more approachable solution than throwing a black hole at it.
Perhaps find a way to slow the planet's orbit enough to have it orbit close enough to the home star to fry it, though it may collide with other bodies at that point.
Comment: It would not destroy the entire system. If we swapped our sun out for a black hole of equal mass, the planets would just keep spinning. The BH would simply act like anything as massive as itself, only with the energy of its evaporation as a problem for those around it.
Comment: They want to destroy the entire system, collateral damage could be an issue. I was wondering if there was a way they could put a field up around the system, or some kind of device that would suck in all the matter and implode or smth like that.
Comment: I have to agree that when you have the power to erase star systems a very large can of worms is opened up. My belief comes out of suspension at " humanity *needs* to permanently destroy an enemy planet." Humanity is the bad guy now.
Comment: Problem is, we're not replacing a star with a black hole of the same mass. We appear to be targeting a planet. One could argue that you'd replace the planet with likemass, but the addition of the planet's mass into an newly established black hole would likely be more mass in total than what was being replaced.

Causing a black hole


How can we change the background of the desktop via filing?

Question: I  wish to change the background of my computer by doing filing in C language but I dont have any idea how to proceed in this regard.Please guide me to the files i must open and what changes must i do to them
Comment: Turbo C? Forget it. There are excellent Win32/64 C compilers for free such as Pelles C.
Comment: @fahad: What's your environment (OS, etc.)? Anyway, maybe this question is more affine to stackoverflow.com.
Comment: @cYrus: Sorry, my bad! And I also vote to move it on SO
Comment: I too think it´s better asked on SO
Comment: Wrong forum... that should be on StackOverflow....
Comment: I am using windows(XP)  and my compiler is old turbo C
Answer: That is highly OS specific and so not worth the effort to do it in C because for each environment you support you will have to do a lot of code but of course, it's up to you to choose.
In linux you have several tools available and you can look at their source-code.
I believe it even depends on the type of graphic environment you're in. For gnome there is gconftool-2, for KDE you have to look yourself but it's easy to find.
For linux it would be wiser to do a system call like:
<code>char str[] = "gconftool-2 -t str --set /desktop/gnome/background/picture_filename /path_to_your/pic.png"; // adapt it
system(str);
</code>
instead of writing code from scratch.
For windows there is a very short batch script here that should be easy to convert:
batch - change background.
To do it in C you write the strings to a text file with the extension .reg then do a system call to apply it.
For Mac OS it's different too, so you have to be more specific


Workflow e-mail to external address

Question: I want to use a Workflow to send an e-mail to an external address but SharePoint Designer 2013 won't let me do this.  Searching the web tells me to use a SharePoint Designer 2010 Workflow but I get an error message saying "Microsoft SharePoint Designer cannot be used to edit web sites on servers different from Microsoft Server 2010." Could someone please lay out in simple steps how I can send my external e-mail?
Answer: It is possible to send an email to an external address in a Workflow on SharePoint Online.
You need to use SharePoint Designer 2013 and in it you need to create the SharePoint 2010 Workflow (you can choose that option on the initial screen for creating the workflow). Then, you can add "Send email" action to the workflow, where you can add external address in to/cc/bcc fields.
You were on right track, but instead of creating the SharePoint 2010 Workflow in the SharePoint Designer 2013, you installed SharePoint Designer 2010 (I guess that from the error that you pasted here).
One more thing: If you have requirement that your main workflow must be SharePoint 2013 workflow, you can still create a 2010 workflow with only one action (send email), create the initiation parameter for it (the email address), and then use the "Start SharePoint 2010 workflow" action to start the workflow and pass it the requested email address as the parameter.
Comment: Damjan,  Many thanks for you help - problem solved.

Workflow e-mail to external address


Question about Ethernaut Telephone question. Creating attack method instead of using constructor

Question: This is entire contract for the ethernaut Telephone question. I created attack() function, but a youtuber suggests constructor(). Anyone knows why?
Answer: It's not important. A contracts constructor is ran at deployment time, so it would save one transaction (everything happens on deployment instead of you having to deploy then call the attack() function) but that's the only point.


Exposed filter as dependent dropdown?

Question: Is it possible to create a view with exposed filter similar to the image given, where location field is a taxonomy term and rest of it are content types with location field as term reference.
Answer: Views Dependent Filter Module integrates this functionality with views

Allows the presence of exposed filters on a view to be controlled by
  values in another exposed filter. Dependent filters are hidden when
  not relevant, and their values are not considered when the exposed
  form is submitted.

Exposed filter as dependent dropdown?


I cannot do Traditional IRA. But I can contribute to Roth IRA. Can I do the non deductible IRA at the same time?

Question: I am not eligible for Traditional IRA this year (2020). But I am still under the limits for Roth IRA. I will contribute to Roth IRA in full. I heard that there is a Non-deductible IRA. Can I do the Non-deductible IRA as well? That is Can I contribute to Roth IRA and Non-deductible IRA at the same time?
Answer: No, if you max out the Roth you cannot also contribute to a Traditional IRA, neither pretax nor after-tax. The max amount you can contribute to an IRA is the total of all contributions you make to any kind of IRA. In 2021, the total contribution limit is $6000 if you are under age 50, and $7000 if you are 50 or older. You could theoretically contribute less than the limit to the Roth, and then you could also make after-tax contributions to a Traditional IRA as long as the total is under the contribution limit. However, you would rarely ever want to put after-tax money into a Traditional IRA while you still have the option to put it into a Roth.
In the future, if you are no longer eligible to contribute to a Roth due to income limits, then you can make after-tax contributions to a Traditional IRA, and if you wish, convert them to a Roth IRA without penalty. (Usually you would aim to convert as soon as possible if you didn't already have a lot of other money in Traditional IRAs.)
Side note: the cutoff for contributing to an IRA for 2020 is April 15, 2021. This means between now and April 15, 2021 you can actually contribute up to $12,000/$14,000 to the Roth. You can assign $6/$7K to 2020 and $6/$7K to 2021. After that you won't be able to contribute again until Jan 1, 2022.
Answer: Yes, but no...
The core point is that the total of the two is limited to 6000 (or 7000 if older than 50). Within this limit, you can spread your contributions between any number of IRAs and Roth IRAs.
Also: You can always contribute to an IRA, there is no upper income limit. The income limit is for being able to deduct the contribution from your taxable income. However, and that's probably what you meant, it is not that useful once you are over the limit; better to contribute to the Roth IRA instead.
Furthermore, once you get over the Roth IRA income limit, you can go back to contributing to the IRA and convert it to Roth IRA right away - as the contribution is from after-tax money, there is no tax impact, and you get the money into the Roth IRA for free (this is called a 'backdoor contribution').
However, if you already have pre-tax money in your IRA (from previous years), make sure you understand the IRS view to this - they consider those contributions 'merged', no matter how you handle it, which results in complex consequences and paperwork.
Comment: I'm pretty sure you mixed up the part about the income limits for traditional IRA. That only applies if you have a 401(k) or similar at work, which presumably OP does, which explains being ineligible for pretax Traditional IRA but still eligible for Roth.


free linux command line tool to convert SVG to PDF and/or some commonly-used bitmap format?

Question: Is there a free linux command line tool to convert SVG to PDF and/or some commonly-used bitmap format (for example PNG)?
Comment: `mogrify -format pdf -- *.svg`
Answer: Imagemagick is great when rasterized (pixelated) output is what you want (or is at least acceptable), but is a bad choice otherwise, since it effectively embeds in the pdf a rasterized version of whatever you are trying to convert. The whole point of svg/pdf is that it can be vectorized, thereby smaller in size, while remaining smooth at any resolution.
So, I would definitely recommend using either Inkscape or CarioSVG. The latter has several command line utilities precisely for this purpose (svg2pdf, svg2ps and svg2png). The only hitch is that it is basically just a python egg, so if you don't have a python environment set up and aren't savvy enough (or don't care enough) to set one up, then that option is a no go. I tried myself, but had problems setting up the required libcairo (not that I tried too hard).
Inkscape is awesome, but the cli is a little clunky if you want just a quick little command to do all the work for you. I put together a couple of little scripts for taking care of this all for me:
svg2pdf
#!/bin/bash

for i in $@; do
  inkscape --without-gui --export-pdf="$(basename $i .svg).pdf" $i
done

svg2png
#!/bin/bash

for i in $@; do
  inkscape --without-gui --export-png="$(basename $i .svg).png" $i
done

Put the first one in ~/bin/svg2pdf and the latter in ~/bin/svg2png, run chmod +x on both of them to make them executable, and boom! You have a quick and easy shortcut for these often wanted operations that doesn't require you to think or remember how Inkscape's CLI works. (Obviously you need Inkscape installed before this will work)
Comment: It may be faster, but you're loosing the vector nature of the graphic, so it's probably also 10 times larger (although I would love to have you correct me if I'm wrong). The reason it takes longer is because it is doing actual vector manipulations, which is a lot more complex than rasterizing (which is basically equivalent to rendering).
Comment: I did just one fast performance test with imagemagick and inkscape with generation of ten pdfs and **imagemagick** is **5.77 times faster.** `time for i in {1..10}; do time inkscape --without-gui -f "drawing.svg" --export-pdf="drawing$i.pdf"; done;` real 0m2.192s `time for i in {1..10}; do convert drawing.svg drawing$i$i$i.pdf; done;` real 0m0.381s
Comment: CairoSVG is awesome!
Answer: There's Image Magick, and Inkscape also has command line tools.
Comment: `convert` wins by far. It is even able to convert to and from esoteric formats you didn't even know existed, and apply more effects to them then you'll ever need.
Comment: Just to clarify for unfamiliar readers, `convert` is a command-line tool for ImageMagick.
Comment: and one more clarification: if you use convert, you will switch from vector to raster and lose the ability to scale the image. in my book, it's inkscape that wins. it just depends on what you need.
Answer: Inkscape
To PDF:
inkscape -A a.pdf a.svg

to PNG:
inkscape -e a.png a.svg

Found at man inkscape and How to use Inkscape in commandline mode
Comment: To add: -e is for PNG; use -A for PDF
Answer: as I know, there is a way to operate Inkscape via cmd - I already used something similar for batch export PNG thumbnails from my huge SVG collection. As Inkscape also supports PDF export via Cairo, it should be possible to export PDF too. I would ask on some Inkscape forum. :-)


Derivation of the supergravity action in 11D

Question: The Einstein-Hilbert action of general relativity is uniquely determined by general covariance and the requirement that only second derivatives in the metric appear. Yang-Mills theory can be motivated in a similar way. In the original paper of Scherk, Julia, Cremer there are some arguments given from which they deduced the form of the action. They are only sketched however. Is there a more complete exposition of the derivation in the literature, or possibly even a uniqueness result as in the case of general relativity or Yang-Mills theory?
Comment: The arguments relied heavily on computer algebra to figure out how to close the terms, and I don't think people have replicated the calculations since, but we have consistency checks from string theory relating to M-theory, so the computer program didn't have a bug. The action must be unique, since the multiplet structure is very simple--- it's just the graviton plus the three-form field, and the gravitino that's it. The argument from counting the number of components is pretty persuasive. What do you find unconvincing here?
Comment: A counting argument can only give a neccessary condition not a sufficient one. I would be satisfied if there were a theorem that stated, that there is a (unique?) supersymmetric action, without exhibiting it explicitly. Ideally the theorem should give an algorithm to compute the action. This would be the situation one is in the case of General Relativity or Yang-Mills.
Comment: When there is a further restriction on spins >2 counting should be enough to establish uniqueness. You can only have one spin-2 object, some spin-1 objects (various dimension forms), and exactly one spin-3/2 object, you can't have 2 gravitinos (because then you would need N=2 SUSY's and you would get spins >2). So you need 1 graviton plus N spin-1/2 and an assorted collection of spin-1's for k<11, and it should be possible to exclude all these by counting. It is remarkable that a SUSY action exists for the graviton+3-form and gravitino all by themselves. But I agree, a proof would be nice.
Comment: It's exactly the same condition. One looks for the most general 11D field content and action that has exactly 2 derivatives in each term - the presence of a fermion is counted as 1/2 of a derivative (square root as a derivative) and a fundamental boson such as the metric tensor or a gauge potential is dimensionless. If you require 11D supersymmetry of such a theory, the 11D SUGRA action is the unique solution up to field redefinitions. One may prove those things starting from the free spectrum and adding interactions, http://motls.blogspot.com/2012/04/royal-status-of-11-dimensional.html
Comment: @LubošMotl : Is the procedure of beginning from the free spectrum and adding interactions trial and error, or does it follow some algorithm? I imagine that you begin by postulating some supersymmetry transformation between the fields, compute and find what terms do not cancel, add those and so on. At some point you find that the remainder can be written as a total derivative and you are done. I think that is more or less what was done in the original paper. Given that there are many of those miraculous actions I feel that there should be a systematic way.
Answer: A beautifully conceptual derivation of 11d SuGra was given in

Riccardo D'Auria, Pietro Fré, Geometric Supergravity in D=11 and its hidden supergroup, Nuclear Physics B201 (1982) 101-140 (nLab)

using the excellent supergeometric methods later laid out in their textbook

Leonardo Castellani, Riccardo D'Auria, Pietro Fré, Supergravity and Superstrings - A Geometric Perspective World Scientific, 1991 (nLab)