Canon 50mm f/1.8

Question: Is it worth buying a Canon 50mm f/1.8? What is the lens good at? I read a review that it is good at doing Bokeh. I tried using my Canon 18-200mm to do a Bokeh effect, but it wasn't that good.
Comment: Did that review explain aperture and depth-of-field ? Do you understand these concepts ?
Comment: Meta discussion on questions like this one which are essentially "please review this lens": http://meta.photo.stackexchange.com/questions/1803/what-about-review-this-item-please-questions  ... I don't think any strong consensus was reached.
Answer: I would almost say: "The Canon 50mm f1.8 is ALWAYS worth the buy!!".
It's the cheapest lens you can buy, but what fun can you have with this little piece of plastic. Don't let the plasticness fool you. Of course the image quality isn't as good as the f1.2, but if it comes to value for money, this lens is unbeatable.
Comment: Unless you don't know why you're buying it.
Comment: Even then. In my opinion this lens is truly one of a kind. At a price of <$100 it's affordable for everyone, so it's not a big investment that MUST perform. With that in mind you can just buy it without knowing what to use it for, or just buy it because someone told you it's a must have. This is in my opinion the only lens you can just buy and just start using to see what it can do for you.
Comment: As inexpensive as it is, you should still know what you're getting before you plunk down $100. If it sits on a shelf because the buyer prefers the flexibility of a zoom, that's $100 wasted. Likewise if the buyer is likely to upgrade quickly to the EF 50mm f/1.4 (which is still pretty affordable, faster, and built better). I agree that the 50mm f/1.8 is a fine way to get your feet wet, but the OP should still do some research and form a clear understanding of what he/she is buying and why.
Comment: With every other lens I totally agree with you. But with the 50mm f/1.8 I see it differently. That's what makes this lens so unique. But everyone is ofcourse looking at it differently. I'm just giving my opinion here ;)
Answer: The Canon 50mm F1/2 is good at taking good-looking pictures at a normal focal length (for full-frame users), a shallow depth-of-field and short exposure times.
Those characteristics come from the fact it's a 50mm f/1.2 prime lens.
It's also an L-grade canon lens, which means it's professional-grade lens, meant for far-above-average quality, reliability and toughness. From what I've heard of it, it delivers on all accounts.
Do you have to buy this lens in order to make nice pictures ? Hell, no.
Start from the pictures you'd like to take, and try to find out what kind of lenses people use to take these kind of pictures.
Comment: Oh, It's a f/1.8 now. Thread started as a f/1.2.

Canon 50mm f/1.8


FTR Quantization for any Subalgebra of $GL(n)$?

Question: As is well known, the quantum groups $SU_q(n)$, amongst others, arise from $R$-matrix solutions of the Yang-Baxter Equation. My question is: For any subalgebra of $GL(n)$, does there exist an $R$-matrix Yang-Baxter solution that q-deforms it?
Comment: What do you mean by "arise from R-matrix solutions of the Yang-Baxter Equation"?
Comment: The entries of the $R$-matrix encode in a direct way the commutation relations of the algebra deforming the coordinate algebra in question.
Comment: Are you referring to the- FRT construction?
Comment: Yes, that's exactly what I'm talking about.
Comment: In Kassel's book,  VIII.7,  FRT construction is illustrated for GLq(2) and SLq( 2) . I don't know a reference for SLq(n). One has to start with a given solution for QYBE and, as far as I know, there are very few that can be written down explicitly. Do you have a reference for SUq(n)?
Comment: The only reference for $SU_q(n)$ I have to hand to http://arxiv.org/abs/math/9802087.

I am not too interested in finding explicit $R$-matrices, only knowing whether they exist or not.
Answer: There are certainly FRT-type constructions for all the classical simple Lie groups, types A,B,C,D (and a modification of type A to encompass $GL_n$ instead of $SL_n$).  See e.g. Klymik and Schmudgen, Quantum Groups and Their Representations (I think that's the title).  Using the theory of roots, etc. it is also possible to construct subalgebras of $U_q(\mathfrak{g})$ corresponding to Borel subgroups, parabolic subgroups, and subgroups corrresponding to symmetric pairs (see papers by Dijkhuizen, Joseph, Kolb, Letzter, Noumi, Stokman, etc. with the words "quantum symmetric pairs" in the titles).
More generallly, there seems to be a philosophy that any construction involving simple algebraic groups of classical type has a quantum group generalization, but there are often interesting extra degrees of freedom when you quantize and unexpected subtleties.  If you elaborate which subgroups you're interested in, I can try to elaborate where to find sources (it would comprise a whole compendium to list sources for all such constructions =]).
One thing to clarify as regards your question:  In the cases I mentioned above, one doesn't seek a new R-matrix to describe the subgroups of $GL_n$.  Remember that the R-matrix is used to define the commutativity relations of the "coordinates" $a^i_j$.  This defines the "quantized coordinate algebra" O_q(G), which plays the role of O(G) in algebraic groups.  finding subgroups of G in terms of the coordinate algebra O(G) means finding quotient Hopf algebras.  There is a similar picture for O_q(G), although depending on the situation, there can be extra difficulties.  I believe that the Borel subgroup is quantized in a fairly straightforward way (dually, there is a Hopf subalgebra $U_q(\mathfrak b) \subset U_q(\mathfrak g)$).  I suspect it's slightly more tricky when you consider $U_q(\mathfrak p)$ for parabolics, but I believe it is understood by now (perhaps someone more knowledgeable can post another answer with references?).  For symmetric pairs, one considers one-sided co-ideal subalgebras of $U_q(\mathfrak g)$ instead of Hopf subalgebras.  The details in each example are technical, but the point I mean to clarify is that one doesn't find a new R-matrix for each sub-algebra, but rather uses the same R-matrix to define commutation relations and then studies quotients (dually, subalgebras) of the original (or dual) algebra.
By the way, I believe that the way one handles real forms, for instance $O_q(SU_n)$, is to observe that $O_q(SL_n)$ has an involution (discussed in Klymik and Schmudgen, for instance), and one studies $O_q(SL_n)$ representations which are compatible with the involution (meaning they have an inner product with a condition relating inner product to convolution).  This comes from thinking about $SU_n$ as a subgroup of $SL_n$ fixed by $X\mapsto (X^\dagger)^{-1}$.


How can I determine who dropped a DB in SQL Server 2005 (and when)?

Question: Is there a way to find out who dropped a database in SQL Server 2005 and the time / date that it was dropped?
Answer: If it was recent enough, it may still be in the default trace. The basic assumption will be that the DROP event will be the last event recorded for this database. So if someone dropped the database 'splunge' you should be able to catch it this way (again depending on how long ago it happened):
<code>DECLARE @FileName VARCHAR(255)

SELECT @FileName = SUBSTRING(path, 0,
    LEN(path)-CHARINDEX('\', REVERSE(path))+1) + '\Log.trc'  --'
  FROM sys.traces WHERE is_default = 1;

SELECT TOP 1 LoginName, HostName, ApplicationName, StartTime, TextData
  FROM sys.fn_trace_gettable( @FileName, DEFAULT ) AS gt
  WHERE EventClass = 47 AND DatabaseName = 'splunge'
  ORDER BY StartTime DESC;
</code>
Answer: If you use SQL Server Managnment Studio,
You can simply see all the data in the Report -> Standard Reports -> Schema Changes History
Details at: SQL Server: How to Find which user deleted the database in SQL Server


linear Regression Simplification

Question: I am trying to use a linear regression with four data points to calculate only the slope $b$. I am not interested in the point $a$ where the y-axis is crossed.
I have the following equation for the linear least square method:
$S(a,b) = \sum_{i=1}^{4} (y_i - a - bx_i)^2$
Setting the partial derivates to zero gives the following equation system
1: $\frac{\partial S}{\partial a} = \sum_{i=1}^{4} (2a + 2bx_i - 2y_i) := 0$
2: $\frac{\partial S}{\partial b} = \sum_{i=1}^{4} (2ax_i + 2bx_i^2 - 2x_iy_i) := 0$
Until now I think everything is correct.
But my assumption proved to be wrong: I thought I could just get rid of equation 1 and only use equation 2 by setting $a := const = 0$.
To my understanding this fitts the line to a line going through the origin with a wrong slope.
Can I simplify the problem in any way or should I implement a standard linear regression, calculating $a$ and $b$ and then just discard $a$?
Edit: What got me really confused is when I tried to verify my (wrong) solution with four test points $(1,1)$, $(2,2)$, $(3,3)$ and $(4,4)$. My solution was:
3: $\frac{\partial S}{\partial b} = \sum_{i=1}^{4} (2bx_i^2 -2x_iy_i)$
4: $b = \frac{\sum_{i=1}^{4}x_iy_i}{\sum_{i=1}^{4}x_i^2} = \frac{1+4+9+16}{1+2+3+4} = 3$
It got me confused since this should give the correct result of $b = 1$ since $a = 0$ anyway.
Edit: Corrected mistake.
Still my assumption that I can just set $a = 0$ and use the same data points with equation 4 is wrong. I checked with $(1,2)$, $(2,3)$, $(3,4)$ and $(4,5)$.
But if I subtract the vector (x_1, y_1) from each data point I shift the coordinate system to a resulting line through the origin. I think?
Comment: You made a mistake $b = \frac{\sum_{i=1}^{4}x_iy_i}{\sum_{i=1}^{4}x_i^2}$
Comment: @Claude: Thanks a lot for the correction.
Answer: It seems as if the coordination transformation works. So the solution is:
$b = \frac{\sum_{i=1}^4 (x_i - x_1)(y_i - y1)}{\sum_{i=1}^4 (x_i - x_1)^2} = \frac{\sum_{i=2}^4 (x_i - x_1)(y_i - y1)}{\sum_{i=2}^4 (x_i - x_1)^2}$

linear Regression Simplification


Nested form fields dissappear when validate => true

Question: I have two models with a has_many :through relationship. For some time the form has been working just fine. I decided to work on client-side validations, at which point attribute access permissions started to appear.
Here are the models:
class User < ActiveRecord::Base
  has_many :missions, :through => :participations
  has_many :participations
  accepts_nested_attributes_for :participations
end

class Mission < ActiveRecord::Base
  has_many :users, :through => :participations
  has_many :participations
end

class Participation < ActiveRecord::Base
  belongs_to :mission
  belongs_to :user
end

`
Here's the form (where resource is a User):
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :validate => true) do |f| %>
  <%= f.fields_for :missions do |ff| %>
     ....
  <% end %>
<% end %>

Which results in
client_side_validation_hash' for nil:NilClass)
If I remove the :validate => true, the form displays fine. This leads me to believe there is an issue with resource seeing mission attributes. Any modifications I make to the models results in the Mission fields not being displayed in the form.
I've looked at several similar questions here with answers (which is where I some ideas from), but none work for me. What am I doing wrong?
Answer: change the line
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :validate => true) do |f| %>

to
<%= form_for(@user, :url => registration_path(resource_name), :validate => true) do |f| %>


Why would a large transfer to a USB drive take longer than expected?

Question: I am backing up 225 GB to a Western Digital USB 2.0 hard drive but this seems really slow. Any ideas on what I could do to make this transfer faster? It's saying it will take seven hours and it is a USB 2.0-only drive.
Comment: Remember that file sizes can cause changes in the speed you can copy at, loads of small files run slower than large files - there is the filesystem management overhead and the way files are sent in packets
Comment: Could you add more details on your situation? What options do you have? Do you have USB 3, or Firewire available to use?
Comment: USB 2.0 maxes out at about 30MB/second == 2GB / minute == 112 minutes = ~2 hours.  Your only alternative is to pull the drive out of the external case and put it into a case with a faster interface, such as USB 3.0, Firewire 800, or eSATA. Or, buy a Drive Dock and pop the bare drive into that.
Comment: sorry, thought I put that info in there. saying 5-7 hrs. It's clearly running at USB 2.0 as 1.0 would be much longer than even 7 hrs. Activity Monitor -> Disk Activity was saying like 4 MB / sec.
Comment: ok, this is wierd. Disk Active just shot up to ~ 30 MB / sec so crankin now (relatively speaking). I didn't change a thing on my end (although Dropbox was consuming a ridiculous CPU amount and I killed it). I am not sure if that would have been it though.
Answer: I would run a terminal command like iostat 5 and also run Activity Monitor to see if other processes are taking precedence to the copy and also inspect the volume of IO operations as well as the aggregate read/write bandwidth.
You could have a bottleneck on the drive that is sending the data, the CPU that is doing the copy or the drive that is receiving the data in addition to the raw bandwidth of the external drive's connection.
Also, check in system profiler under the USB tree to inspect that the device is actually negotiated a USB 2.0 connection.
Spinning HDD typically have a few hundred iops limit due to seek time even if there is perfect alignment of the data on the spindle so that the next block to be read is always directly under the read head when the drive schedules the next read. Other drive access, file fragmentation and other effects can often slow down a write to 50 iops or less which would clearly limit the transfer speed to 10 Mbps or less given typical block sizes for HFS+ filesystems.
In short, it might be a slow transfer due to the Mac or the drive sending the data and not a full or fragmented drive on the receiving end.
Comment: I think there was some contention with dropbox and possibly some buggy code for how they handle contention with mutexes
Comment: Could be - isolating the Mac from the network might also be a great way to ensure no syncing or other delays are happening.
Comment: Y, thx for answer - I think you covered most of the issues - appreciate it
Comment: sorry took awhile, some things came up


PS4 controller turns off upon sign in

Question: So my controller will turn and stay on fine, but as soon as I choose an account to sign in as, the controller turns off. It will also turn off if I press the PlayStation button. Basically it functions as a normal controller until I try to sign in, then it turns off automatically. Also, if it has a charge, it will turn itself on automatically. I've tried resetting and the share+PS button combo. Neither worked. Any ideas? Thank you.
Answer: Narrow down which end the fault lies - controller or PS4 - by doing the following:
1.) Try using the controller and pairing it with another / different PS4.
2.) Try pairing a different PS4 controller to the PS4 in question.

If the fault is the controller, I'd suggest replacing it.
If the fault lies in the unit, note the BT receiver is near the HDD.

Other Solutions:

Is your unit vertical? Lay it flat and try again.
Is it in an enclosed space and near another devices BT device? Try disabling the BT on nearby devices. The PS4 could be booting your controller because another device is unexpectedly paired.

PS4 controller turns off upon sign in


if the startup disk is copied to external drive, can that external drive be used as a startup disk?

Question: If the startup disk is copied in its entirety to an external drive, can that external drive then be used as a startup disk?
Answer: Yes you can you can use disk utilty to clone the contents of one drive to another but  you can also use Carbon Copy Cloner.
You cannot use an external disk as startup disk if you drag and drop the system files as the permissions on the files might change leading to unbootable external disk.
So do not drag and drop the system files, only clone the disk into another disk as it preserves all the file attributes, permissions, owner, group, etc.
You can use Disk utilty 'Restore' feature to clone a drive. So suppose there are two drives A and B. I want to clone drive A to B so in Disk Utilty choose drive B then click restore option then choose "Restore from A"  That's it! let it do it's job but if you want to clone a lively booted up disk then you will need a third party app like Carbon Copy Cloner.
Comment: So to clone my current active startup disk I must use Carbon Copy Cloner?
Comment: @jmh Yes Disk utilty will simply not allow you to clone a lively booted up disk. I would suggest you to backup your Mac using time machine app as it is built in MacOS and it's free whereas Carbon Copy Cloner has only 30 days trial.
Comment: Thank you again.  I bought Carbon Copy Cloner over a year ago so I should be set if I decide to do this.


What was the youngest age at which a prodigy could be considered to have been a master?

Question: There is a photo of Reshevsky playing at a very young age (like 8) against many adult players but there were no ratings in those days. I assume that a modern GM who got the title at 12 must have been close to master strength at 8 but I am not sure this is true. I wonder in fact if there is some limitation of the human brain that prevents a certain level of play before a certain age in the same way that no child can run a 4 minute mile, etc.
Comment: It seems to me like this question is more or less impossible to give a definitive answer to. Practice seems to indicate that people younger than 12 years old will not be of GM level, but as far as I know there have been no studies done on the subject.
Comment: You can certainly keep your eyes on misha osipov which had a game against karpov at the age of 3. Maybe he can be the one to break that record.
Answer: Let's just say a master is someone who crosses the 2200 USCF mark to get a rough idea. In that case, Abhimanyu Mishra and Liran Zhou both crossed the 2200 barrier around 9 years and 3 months. Christopher Yoo did the same thing in just under 10 years. Note that these chess players did not necessarily reach 2200 strength at those ages, it is likely they were weaker than 2200 but from stochasticity, achieved the crossing. Also note that USCF is the federation associated with United States and 2200 USCF corresponds to something like 2100 FIDE.
Comment: It seems hard then to imagine that Reshevsky, in the pre-computer days, could have been a master much before this (at, for example, 8). The term doesn't really mean the same thing as today anyway. It would be interesting to subject very early Morphy, Capablanca and Reshevsky games to computer analysis and maybe that would tell us in an absolute sense how good they were and even possibly compare them to quality of the "masters" of that time.


Linux Mint 12 - Firefox keyboard shortcut bug

Question: The Ctrl+a (select all shortcut) does not work in Firefox on Linux mint 12;
I mean if you highlight a textbox (for example in google.com the box where you enter the search keyword ), enter some text and then press Ctrl+a, it will not select all the text you inserted before but instead it will move the character cursor to the beginning of the line.
The odd thing is that if you press Ctrl+a and you are not highlighting a textbox it works just perfect.
Also for the same user if i use the MATE layout(select it when I login) everything works just fine. (Now I'm using the gnome 3 layout). If I create another user everything works fine.
Is there any way I can fix this thing or should I create a new user and enjoy the new identity :)
Answer:
Is there any way I can fix this thing?
Answer: Yes. If you want to put the time into it, you can certainly fix this. That's one of the great things about Linux. You can probably fix this simply by editing some text config files (or possibly making a new Firefox profile). See below.
Diagnosis: it seems like your user has a setting that is invoking the line editor for text boxes. You can verify this if ctrl+e moves to the end of the line, ctrl+b moves back one letter, ctrl+f forward one letter, etc.
It is not possible for me to say, based on the info in your question, whether the configuration issue is in your Firefox profile or in Gnome 3. (I don't use Gnome 3.)
Possible Solutions:

Rather than make a new user, consider making a new Firefox profile. If that works, delete your current user's existing Firefox profile and use a new one.
check, edit and possibly delete your current user's customized Gnome 3 configuration files (usually hidden files such as .profile) in the home directory.
of course, since you know that making a new user account fixes the issue, that's one very easy solution. If you want to further diagnose this, do a diff on the various config files until you find the cause of the problem in your first user account.
Answer: It might be the case when you turn on Emacs Input mode.
To reverse the behavor, first open Gnome Tweak Tool application (mine v3.30), then go to Keyboard & Mouse section. After that, you might see the Emacs Input toggle enabled (which cause that strange behavior). Disable it.


Violating Newtons First Law!

Question: Suppose you are inside a very large empty box in deep space , floating ( i.e not touching the box from anywhere initially).The box is at complete rest.
Now you push the box  forward from inside.
Now you would go backwards but the box will move forward to conserve momentum.
However since you were inside the box your force is an internal force but the box would have moved forward.
So doesnt this violate newtons 1st law
as an internal force made a body move from state of rest?
Comment: The question is fine. The answer is primarily about centre of mass: although the box accelerates and the person accelerates, the centre of mass of the whole system does not. Things like this are happening all the time: the wings of a bird, a bullet fired from a gun, etc. "Internal" force means a force *between the parts* of a system; in this case the system of human being plus box.
Comment: It does not violate the laws of motion.  The center of mass of the system is not going to change state.
Answer: Internal forces can make things move. Nothing says they can't. It's just that any internal forces have an "equal and opposite force" that is also internal, so momentum is conserved, at least when considering internal forces. This has everything to do with Newton's third law and nothing to do with Newton's first law. Newton's first law says nothing about the distinction between internal and external forces.
If you want to apply Newton's first law, all you say is "I was at rest, the box pushed on me, I experience a net force, so I start to move."
Answer: Your confusion stems from the misunderstanding of the term "internal force".
Internal force in this context is not a force which acts from the geometrical inside of some body. It is internal in the sense that it results from the interaction of the parts of the system, whose collective motion (the acceleration of its center of mass) you are considering.
So when analysing the motion of the whole system (the box and the person together), we see that its center of mass has indeed not accelerated. But if we consider only the box, we see that it had accelerated, but Newton has no need to worry, as an external force (your hand) had caused the acceleration.
Comment: whats the problem with my answer?
Comment: It looks like everyone is getting down votes for some reason. I'll give you +1 to help haha
Comment: Excellent answer! It hadn't occurred to me that the OP might consider the force as internal to the box since it was pushed from the inside.
Answer: You are right, the force is internal to the system and not just the box. Overall the combined center of mass will remain fixed as you and the box exchange momentum.
There is no paradox here because you are either considering the entire system of box + human with no external forces, or you are considering the box by itself with an external force applied (by the human).
Answer: If you say that pushing against the box (and the box pushing against you) is an internal force, then that means that you and the box are considered to be two internal parts of a single object. The center of mass of this object does not move when you push against the box, since all forces are internal. So you will move in such a way that the center of mass of you and the box does not accelerate. The net force on this object is zero, and the object does not accelerate (if it accelerated, then its center of mass would also accelerate), so Newton's First Law is fulfilled.
Answer: System box
You exert an external force on the box and the box accelerates.
System you
The box exerts an external force on you and you accelerate.
System box and you
You exert an internal force on the box and the box accelerates.
The box exerts an internal force on you and you accelerate.
These two internal forces are a Newton's third law pair.
There is no external force on the system and so the centre of mass of the system does not move.
The linear momentum of the box is equal in magnitude and opposite in direction to your linear momentum.
The total linear momentum of the system had an initial and a final momentum of zero.
Answer: The thing with internal forces is they can't move the center of mass. And in this case too, COM remains fixed. And let me make it clear, its$$F_{net-external} = m_{total} × a_{COM}$$ In your case $F_{external}=0$ and so $a_{COM}=0$. This doesn't comment of individual acceleration of parts of the system.

Violating Newtons First Law!


Would 2FA's second factor be a safe enough way to login?

Question: I'm thinking of adding my website an option to login with just 2FA's second factor instead of just password. How safe would it be? I'm thinking of TOTP as 2FA method. Considering it isn't a big or important website, would it be safe?
Comment: You have to define "safe".
Comment: I second @schroeder, define your threat and your definition of 'safe' without that, I feel this question is far too broad and subjective...
Answer: The obvious problem with this is the same problem with just using a password: as soon as someone has that, they have all the access they need. Assuming you'd use your phone, then if your phone was stolen, then that person can log in.
If you feel that the risks of using this method is acceptable, then it's acceptable. But you have to understand the weaknesses of the approach and accept them as part of the deal.
Let's put it another way in an extreme case: is it "safe" (you haven't defined that) to use a password of "123456"? Sure, it does keep people out of your account, until someone tries to guess your password and tries this very, very common password. Your account is "safe" from people who will not try to guess your password (but unsafe against those who do).
Is using a super-complex random password of 30 characters "safe"? Sure, it is now safe against those who would try to guess your password, but unsafe against those who would try a keylogger, or a password database that stores everything in plaintext, or a super-computer dedicated to cracking your password.
Each layer of complexity increases "safety" and secures your account against certain groups of threats. By only using 1 factor, you reduce the complexity and reduce the number of groups that you are securing against, but perhaps that groups that remain are sufficient for your needs.
Comment: I like this answer because it defines the ubiquitous 'safe' pretty well. I do want to point out that 'complexity' itself should never be confused with randomness which is the **only** thing that truly improves security (in my opinion).


What port is used by SQL Server to write backups to a remote server?

Question: I have a SQL Server 2008 R2 Standard instance in a "DMZ", so that it can be client-facing. I am trying to have it write its backups to a central location that is within the network. The engineers suggest that they can open a port for me. Hence the question: What port is used by SQL Server to write backups to a remote server?
Comment: It will use the port that is assigned. By default it is 1433 (which is not a good practice to use due to security). Also, take the backup locally and then use ROBOCOPY or powershell to move the backups to a remote server. Dont try to write directly to a remote server as a n/w glitch will corrupt your backup.
Comment: @Kin "write backups to a remote server" would not occur over 1433. I'd of thought we were talking about [SMB ports](http://en.wikipedia.org/wiki/Server_Message_Block)?
Comment: @MarkStorey-Smith Yes, should have made it clear in my comment. It is the port on which sql server will listen the incoming client requests.
Comment: are you able to copy backup done locally to your network share ?
Answer: Remote file access occurs over SMB. Remote backups are just another form of remote file access. See File and Sharing Protocol Stack.
If you use SMB over TCP directly (ie. disable NetBIOS) then the port used is 445, both UDP and TCP. If you use NetBIOS then it requires 137 both UDP and TCP, 138 UDP and 139 TCP. See Directly Hosting SMB over TCP/IP:

NetBIOS over TCP traditionally uses the following ports:
<code>nbname            137/UDP
nbname            137/TCP
nbdatagram        138/UDP
nbsession         139/TCP
</code>
Direct hosted "NetBIOS-less" SMB traffic uses port 445 (TCP and UDP).
Answer: I am doing remote backup by backing-up locally and then copying the bak files to remote storage file share.
I do not think it is much different if to backup directly.
Anyway I've checked it with WireShark:

having shown that TCP port 445 was used. Though, depending on Windows version (it was not even clear if your backup will be stored on a device under Windows), TCP port 139 could have been used or whatever the backup application/device/OS is configured to use.
Another question is that a port as such is not sufficient for giving access since it is being "opened" in context of ports, protocols, applications/programs, accounts.


RAID 6 that can read with least 1000 Mbit/s?

Question: I purchased a Dell PERC 6/i which I expected to be able to read with 1000 Mbps. There is not much to do now, but there are some things I wanted knowledge about for another time.
I have configured it with four 2 TByte drives and RAID 6.
It has 256 MByte of RAM and transfer rate of 300 Mbps.
The benchmark test showed:
Min read rate: 136.3 Mbps
Max read rate: 329,6 Mbps
Avg read rate: 242,2 Mbps

What could I had done to get at least 1000 Mbps?
Is it normal for internal and external RAID controllers to have a lower transfer rate eg. 300 Mbps? (I did not noticed at the time that it was not 3 Gbps)
How would a RAID 10 had performed compared to RAID 6 or 5?
Would it have been better to use software RAID (Linux) with the internal 3 Gbps SATA controller?
UPDATE:
The drives is SATA III 6 Gbps.
http://www.seagate.com/files/staticfiles/docs/pdf/datasheet/disc/desktop-hdd-data-sheet-ds1770-1-1212us.pdf (2TB)
UPDATE 2:
I was asked what I had expected as transfer rate. I will put my answer here, although it is irrelevant. I did not ask about the speed could be correct or what I had expected.

I have calculated the numbers with a loss of 1/3.
Example 4 x 3 Gbps (SATA II. Total 12 Gbps) will provide 8 Gbps.

So what should I have done to get the 1000 Mbps or .... bump?
UPDATE 3:
Screenshot of the benchmark test:

https://docs.google.com/file/d/0B6swvDCUiDn9WmtZcEFJUTdZRE0/edit
UPDATE 4:
Screenshot of hdparm:

But it seems that the fault is in the switch.
Screenshot of the network test (iperf):
Comment: @DibloDk are you sure the benchmark units are in mega **bits** per second and not mega bytes?
Comment: @DibloDk have you tried another program?  [This question on AskUbuntu](http://askubuntu.com/questions/87035/how-to-check-hard-disk-performance) alludes me to believe that those benchmark units **should** be in MB/s (as per the pictures in the accepted answer on that AU question), so your benchmark either *is* in bits/sec, or the units are being displayed wrong (possible localization bug?).  Anyways, I'd try another disk utility or somehow otherwise verify those speed values you've provided (maybe try some real-world file transfers and see how long it takes?).
Comment: @Breakthrough You're right :)
Comment: *four 2 TByte drives* What if each drive is capable of reading 1MB/s, what would you expect the read rate to be?
Comment: @ta.speot.is it's RAID6 setup, so I'd say around 200 MB/s max. if you were using 100 MB/s drives.
Comment: The hard drives is SATA III 6Gbps, look at the update above :)
Comment: Here's a screenshot https://docs.google.com/file/d/0B6swvDCUiDn9WmtZcEFJUTdZRE0/edit?usp=sharing
Comment: I made also a test by copy 3.6 GByt over a 1 Gbps network and I got 45 MByt/s (360 Mbit/s). It was 25 files, that fill 3.6 Gbyt, but the 360 Mbit/s fits approx. with max the transfer rate
Comment: @ta.speot.is I do not know. 8000 Mbit/s, but because I was wrong about 300 and 3000 Gbit/s, I'd say 1600 Mbit/s (2/3)
Comment: 300 and 3000 Mbit/s
Comment: @Breakthrough But it says example. 4 TB (TByte) and 329.6 Mb/s (Mbit/s) I hope that I can trust the abbreviations :) ?
Comment: @DibloDk I agree with Breakthrough that those are megabytes, not megabits. From your screenshot you can see that the abbreviations are inconsistent. Assuming those are megabytes, you're averaging nearly 2000 megabits per second.
Comment: Okay, it sounds like that i need to make new benchmark and networks test :) It will take some time before I can make new tests, so I will let the topic stand and come back later.
Comment: @DibloDk try using `hdparm` to do some benchmarking and show us the results; you can find details using `hdparm` on [this AskUbuntu question](http://askubuntu.com/a/87036/28452).
Comment: @Breakthrough Yes, I will use both programs :)
Comment: Many switches cap out much lower than advertised spec. Always start with iperf when testing network-related speeds. Higher-end switches will allow for throughput of much closer to their rated speeds, as well total network traffic on the switch will affect speeds. Out of curiousity what switch was this? I've seen procurve and netgear switches doing this often. In addition, to test drive speeds use a program which writes and reads: memory-disk-memory, for an actual drive speed test.
Answer: According to the technical specifications page the controller is capable of 300 MBps (2400 Mbps).
It's not clear whether this is the maximum when running in RAID 6. Note that RAID levels with parity require parity calculations and this can slow the overall transfer rates. So the maximum might be applicable for a RAID level that's less demanding of the controller.
The parity calculations can come into play during reads, especially if one of the disks has failed and the controller has to "fill in the blanks".
That said, the RAID controller might not be the bottleneck. Take 2 disks with a sequential read speed of 20MB/s each in RAID 0. The fact that the controller can push 2.4 Gbs doesn't mean much if the disks can feed it enough information to transfer at that rate.
Comment: I accept your answer. But I think it's a lot when we're talking about, that it is almost 1/4 of the speed there is lost. - But it is not an answer to the four questions. Ex. what could I do to get 1000Mbps?
Comment: 3/4 of the speed there is*****
Comment: How did you get up to 2400 Mbps and not 1200 Mbps.
Answer: Performance of linear read per disk is not limited by interface (SATA III in your case). It may be so for SSDs, but not for HDDs anyway.
Measure your disks independently of RAID controller. They are likely to give about 100 Mb/s each, hence the benchmark result you provided.
Answer: There are many determining factors in a hard drive or controller's reported speeds when under use:

The speed of the hard drive
The speed of the controller/processor

For the speed of the hard drive, you need to also know that hard drives will not run at the fastest possible sped all the time, especially with desktop consumer drives, that are rated for up to 7200 RPM. There are server drives that spin at 10K or 15K RPM, are much more expensive, and much faster when looking for information.
There is also the cache to take into account. The cache is the information received from the spinning parts of the hard drive, which are then fed as a burst of data to the controller. I don't know of any hard drive with a 6 Gb cache to deliver the speed right up to 6Gbps... The most I've seen so far is 64Mb, but I'm sure there are larger caching hard drives available somewhere.
The next part is the controller or the CPU. Once the data leaves the hard drive for the rest of the system, the processor, whether it's a dedicated controller, or the CPU, needs to process the data and decide what's happening with it. There is a bottle neck here as well, as the processor has to do calculations on the data, and possibly manipulate it, before it does anything else (i.e. send to Network card). As well, if Anti virus programs are running and scanning files being accessed, this will also slow down (I realize this isn't part of your question, but not something to eliminate).
In theory, multiple drives increase speed and redundancy; this is true in most situations, but not always the best way. For the fastest speed, you need to lose all redundancy, and go with a RAID 0 (stripe). The issue with that is that if one drive fails, you typically lose all your data across all the drives (at least, the controller says you do). With a RAID 1, you lose half the space, but you have redundancy if one drive fails, and can rebuild easily. RAID 10 offers the best of both worlds, allowing the controller to read from the 4 hard drives at the same time, and not spend time calculating parity, while still allowing you to lose 1 (or, if you're lucky with the selection, 2) drive(s). RAID 5 and 6 both require calculating parity on each drive, for each write and read, which will slow down the processing of the data; their redundancy allows for 1 (RAID 5) or 2 (RAID 6) drive(s) to fail, while keeping the data intact.
With the data sheet you provided, it also shows the MAXIMUM sustained data reading speeds maxing out at 210 MB/s, which is not anywhere close to 6Gbps, which SATA 3 is rated at. So it's easy to see that you will not see the full 6Gbps from that, or from most consumer based Processors.
Comment: Okay thanks, now I understand what @ta.speot.is talk about. It sounds like that i need to make new benchmark and networks test :)
Comment: It's also sometimes known as the interface speed. Basically, the fact that your interface (e.g. SATAIII) can reach a high speed, does not mean that the drive itself can sustain such a transfer speed.
Answer: You need a better RAID controller.  Your PERC 6/i can only transfer at a maximum of 300Mbps.  That is less than a 1/3 of a gigabit per second (.292969 Gbps).  This is a relatively low performance card.
There are better cards out there, Googling one at random and came across this one.  It had a maximum of 1,850MB/s transfer.  This is the equivalent of 2.8 Gbps.  Factor in RAID calculations, latencies, etc... This card should be able to support 1Gbps transfer rates.
Your drives and PCIe x8 are more than capable of transferring 1Gbps.
Comment: Your numbers are completely inaccurate, I have a perc 6/i and typically perform near 300MB/s, that's 2.3Gbit/s-- easily saturating a single gig link-- that's with a RAID 6


Problems getting SQL Server linked server to work in web-based admin utility on Windows Server 2022

Question: I have an ASP classic web application based on an SQL Server database, with an admin component.  The database has a linked server with Microsoft.ACE.OLEDB.12.0 provider to allow bulk import of records from an access database.  Over the years, I have gotten it to work on Windows 2008 server, 2012 server, and Windows 10 (my development machine), though not without losing some hair.
Now I am trying to port the app to an AWS EC2 instance with 2022 Server Datacenter edition, and can't make it work.  I can run a linked server query in a SQL Server Management Studio window with no problem, so it works to that extent -- the linked server exists and works in principle.  But if the same query is attempted from the web app, it fails with:

"Microsoft OLE DB Provider for ODBC Drivers error '80040e14' [Microsoft][ODBC SQL Server Driver][SQL Server]OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "[name of server]" returned message "Unspecified error".

The error message seems very uninformative -- just a long-winded way of saying the query didn't work for unknown reasons.  It's possible to query the SQL server directly from the web app, and to query the Access database directly from the web app using the same provider as used by the linked server.  Only linked server queries fail.
Because it works from my admin login via Management Studio but not from an IIS process, the problem could be 1) permissions; or 2) something about configuration of IIS or its application pools or the ability of the query to work from within an IIS process.
Regarding permissions, I already made sure IUSR has full control of the folder where the linked server Access database sits.  Based on other research, I tried firing up Dcomcnfg and giving IUSR full permissions for MSDAINITIALIZE (even though this was not necessary on my 2012 Server or Windows 10 machines).  It didn't help.
Regarding configuration, "Allow in process" is checked for the linked server provider, same as for my earlier machines, where linked server queries are successful from the web app.
Answer: After poking at the problem for another day, I figured out that IUSR needs permissions to the folder "C:\Windows\ServiceProfiles\MSSQL$SQLEXPRESS\AppData\Local" -- so it's a matter of tracking down the relevant temp folder in the version of Windows server on which the database is running.  I still have problems with sporadic w3wp.exe crashes, but that's probably another problem.


Is it possible to search for Twitter account's retweets of another twitter account?

Question: I know there is a function to search a person's retweets but is there a step further where you can search for another party included in the retweet?
Answer: Yes it is! However, it is a bit tricky and unstable. You'll have to do the following:

Create a Twitter list and add to it the [retweeting_account]. Just this one!
Construct the following search query: filter:nativeretweets list:[your_list_id] @[retweeted_acount]

So, for example, if you wish to see all the retweets @realDonaldTrump did for his wife Melania, the query should look like this:
filter:nativeretweets list:1336103232754618374 @FLOTUS

The only problem with this is that it seem to give results a week back, not more + it is somewhat unstable when used on really high traffic accounts.
In some cases the below variations seem to work while the above one doesn't:
filter:nativeretweets list:[your_list_id] link:[retweeted_acount]

or
filter:nativeretweets list:[your_list_id] from:[retweeted_acount]


What does 六等星の夜 mean?

Question: Google translates 六等星の夜 to night of a million stars. But shouldn't a million stars be 百万星? Moreover google translates 六等星 as six stars. Is this a translation error? If not, can anyone explain why?
Answer: 六等星【ろくとうせい】 is definitely "a star of the sixth magnitude" or "6th magnitude star", not "six stars" nor "million stars." So it's an error made by Google Translate.
Google Translate recently started to use a neural network. It works excellently for many common sentences, but I feel it also makes terrible mistakes like this one when it encounters relatively rare words. From my experience, it's especially bad at dates and numbers.
By the way, 百万星 doesn't sound natural to me, either. You usually have to use の and say 百万個の星, 百万の星々, etc.
EDIT: I've found that there is one (and only one) fantranslation of the song that actually uses Million Stars. I believe it's a human error, but there is a small chance that Google automatically "learned" it as a translation of the title of this song.
Comment: Ah, this makes more sense. Thanks for your answer.

What does 六等星の夜 mean?


What happens if an index build is cut half way through?

Question: Today I ran a create NC index but stopped the execution after running for 1 hour 46 minutes. The main reason being I started to get worried about the disk space getting lower. It consumed roughly 10 gb of space on a rather expensive storage. Indexes of the db is on its dedicated filegroup and I created this one the same.
Even though I stopped the execution, the 10 gb of space was not released to the OS. The index file has not much free space either. My question is; where has my 10 gb gone?
Thank you,
Answer: Since you stopped the index creation, the index was not created. However, the space it had reserved already (10GB) was still added to the database size.
SQL Server will not automatically shrink the database file size back down unless you explicitly instruct it to (which is not recommended unless you are about to run out of space). You can add up to 10GB of data (rows, indexes) to the database before it will need to grow the file size again since that space is unused.
You can right click and select properties of the database in question in Management Studio to see how much space is free of its total size:

If you must shrink, you can read up on it at the MSDN article on how to Shrink a File.
Comment: 1) No, either the index exists or it does not.
2) You could write a job to query the file size and store it in a table.
3) Space available refers to the entire database, all data files included, that is not currently used. You can see individual file usage by right clicking the database, Tasks -> Shrink -> Files and then selecting files from the drop downs. Again do not actually shrink files unless you are sure you are need to.
Comment: Thanks mate. I have 4 data files and 1 log file. One data file is dedicated to the indexes (by filegroup). Whenever I create an index, it is created on index's filegroup (the only file on that filegroup). My question would be:
1) The index file is, for example 50 gb and its free space is 500 mb. So, is it possible that there might be some remnants of the index creation?
2) Is there a way to track file grow historically so that I can watch previous hours? I wonder if it really grew.
1) What does "space available" in the screenshot denotes? Which file's space does it refer?
Thank you.


Is there a word for the funny coincidence that sometimes happens..?

Question: When one person is thinking about another person and that other person happens to be thinking about the first person. I have had instances where I have reached out to someone or called someone and they say, "that's so weird I was just thinking of you!"
Is there a word for that phenomenon?
Comment: Given the number of persons that the average human knows, at any one time, and in a reasonably familiar way, and given that we humans spend a lot of time thinking about one another, the 'phenomenon' is very common indeed and so unsuprisingly so, that we have no word for it. Or at least not a commonly known one.
Comment: Probably not what you're looking for, but the example you give is a well known cognitive and unconscious bias, named variously frequency illusion, or Baader-Meinhof phenomenon. Basically the problem is that you haven't counted the number of times you've thought of that person and 'have not' received a phone call from them. We tend to notice the positive hits and are oblivious of non-events, or at least they don't figure into our statistical reckoning. Related can be pareidolia, seeing symbols of meaning where there may be just noise. Clustering illusion is related to this.
Answer: Some people call it "synchronicity", referring to the theory by the psychologist Carl Jung, which states that things can be connected by meaning even if they have no direct causal connection.


libqt5gamepad5-dev not available in 18.04 repos?

Question: I'm trying to install this according to this guide, but when I go to install libqt5gamepad5-dev, I get "Package not found". I've sudo apt update'd multiple times to no avail. How do I fix this problem?
Comment: The package package is only available for cosmic up (18.10-), https://packages.ubuntu.com/search?suite=all&searchon=names&keywords=libqt5gamepad5-dev  and looking at some of its requirements they require more modern packages than bionic provides (libqt5core5a: https://packages.ubuntu.com/cosmic/libqt5gamepad5 https://packages.ubuntu.com/bionic/libqt5core5a) so it could risk pulling your 18.04 away from LTS security (ie. causing parts of your system to go EOL next month with 18.10).  Jumping to a later release is an option.
Comment: Excuse my ignorance, but how do I jump to a later release?
Comment: Ubuntu 18.04 LTS offers two upgrade paths, (1) to Ubuntu 18.10 available now, see https://wiki.ubuntu.com/CosmicCuttlefish/ReleaseNotes in the *Upgrading from Ubuntu 18.04* section., or (2) upgrading to Ubuntu 20.04.1 LTS (which won't be out till mid-2020; note it's the first .1 release so not in April).  18.10 reaches EOL next month, so you'll need to jump again to 19.04 very soon as standard releases come out every 6 months and are supported for 9 months giving you 3 months to release-upgrade.
Comment: Thank you! I think I'll upgrade to 18.10 for the time being, then jump to 19.04
Comment: ps:  just because that's the best I can provide doesn't mean someone else won't have other ideas.  You may get a gamer who's came across this issue and thus has the drive & spent the time to come up with a solution, so you may find alternatives if you're patient.
Answer: That's right, the package libsq5gamepad5 and it's associated -dev are not in the 18.04 repositories. They were added to Ubuntu during the later 18.10 cycle, and are in releases of Ubuntu 18.10 and newer.
Deb packages in the repositories are re-built for each new release of Ubuntu. The easiest way to use the package is to migrate to a newer release of Ubuntu that has the package.
We generally recommend against trying to use a wrong-release package on your Ubuntu system. While an expert may (or may not) be able to make it work using a bit of dpkg magic, a new user is much more likely to merely break their system.


Undersampling approach in different types of study

Question: If I want to use an undersampling approach to construct the machine learning model, I am wondering if there are any criteria to determine how many times I should sample the data from the majority group (the minority is 14% and the majority is 86%) and build the ML model? I am working with biological data and I am recommended not to use oversampling approaches. To determine which sampling approach we should use, are there any criteria to determine before constructing the ML model? Is it really dependent on the field of study?
Comment: "If I want to use an undersampling approach to construct the machine learning model"—you probably don't. Stephen or Dave can explain why soon. If you want to read ahead, then look up "proper scoring rules".
Comment: [Class imbalance is less of a problem than you might think.](https://stats.stackexchange.com/questions/357466/are-unbalanced-datasets-problematic-and-how-does-oversampling-purport-to-he) I also like Sycorax's comment about how we got here, which I think is correct. // Frank Harrell has good blog posts, too: [1](https://www.fharrell.com/post/classification/) [2](https://www.fharrell.com/post/class-damage/). // [There is an interesting example on here where proper scoring rules do not win](https://stats.stackexchange.com/a/538524/247274), granted, under strict assumptions and a specified cost.
Comment: First you need to decide what performance criterion is important for your application, it could well be that there is no need for any over- or under-sampling.  We also need an idea of how big the dataset is (more data resolves imbalance problems).  Note that there doesn't seem to be a means of determining whether class imbalance is actually a problem for a specific application - it may be that assigning everything to the majority class is the optimal solution https://stats.stackexchange.com/questions/539638/how-do-you-know-that-your-classifier-is-suffering-from-class-imbalance/540792#540792
Comment: Whether proper scoring rules are appropriate depends on the needs of your application, but they are definitely something to investigate before considering up or (especially) down-sampling.  You might want to use a classifier that can weight the importance of patterns, rather than resampling, it achieves the same thing, but without throwing away information .  The SVM can do this, but so can neural nets and logistic regression etc.
Answer:
I am wondering if there are any criteria to determine how many times I
should sample the data from the majority group (the minority is 14%
and the majority is 86%) and build the ML model.

If you are interested in accuracy (or expected loss, which is just a sort of weighted accuracy), then I think the short answer is probably "no".  Class imbalance problems tend to arise when you have very little data, and so due to the imbalance, there are especially few patterns describing the distribution of the minority class.  This can lead to unduly biasing the decision surface towards the majority class.  However, the bias is generally fairly small.  If you do something as extreme as balancing the dataset so it has a 50:50 distribution, this is likely to way over-compensate, so that the true positive rate goes up, but the false negative rate goes up much faster and your accuracy goes down.  So basically you want to resample/reweight just enough to compensate for the bias, but no more, in order to improve test accuracy.  But if we have so little data that we have a class imbalance problem, we probably don't have enough data to estimate the required correction either (apart from simple methods like logistic regression), so in practice we may be better of doing nothing.
Fortunately, most parameter estimation problems go away if you collect enough new data, so that is often going to be the most practical solution.
Comment: Thanks everyone for the explanation.
Comment: It is a good question, I'm working on finding a better answer.


Parallel Computing

Question: Very new to Linux so here is what i'm trying to do.
i'm trying to connect 3 computers to have them work as one for more memory and more
Comment: Possible duplicate? [How can I cluster two machines to double the processing power?](https://askubuntu.com/q/57526/301745)
Answer: It doesn't work like that.
Memory has bandwidth measured in tens of gigabytes per second, and latency measured in nanoseconds.
Network latency is measured in milliseconds, and bandwidth in hundreds of megabytes per second, or single digit gigabytes per second for 10GbE.
This means that transferring data between nodes will be very expensive in terms of time and bandwidth, compared to a local memory operation. For some tasks, this is not a big issue. For instance film rendering is trivial to parallelize - simply send a chunk of the file to each node.
Same goes for some other operations, such as compilation, and a lot of heavy calculation; there is very little need for communication between nodes doing different subtasks.
But this does not expand to general computing, in the way you assume. If you want to use a cluster for a specific task, such as compiling or rendering. ask about that. The general use cluster like you seem to expect is simply impractical, and will probably be slower than each of the individual systems.

Parallel Computing


ASP.Net MVC3 C# query regarding viewing data stored in a database

Question: I have a question regarding the MVC3 C# Tutorial.
When creating Controller, it automatically creates the Views for you, and Index.cshtml is created (path being /Views/News/Index.cshtml). This code looks like the below:
@model IEnumerable<dale_harrison.Models.News>
@{
    ViewBag.Title = "Index";
}

Index

    @Html.ActionLink("Create New", "Create")

            News_Entry

        News_Date

@foreach (var item in Model) {

            @Html.DisplayFor(modelItem => item.News_Entry)

            @Html.DisplayFor(modelItem => item.News_Date)

}

This works fine, however, I would like to display the contents of @Html.DisplayFor(modelItem => item.News_Entry) and @Html.DisplayFor(modelItem => item.News_Date) on my homepage, which is in a different View.
I tried to copy the code from Index.cshtml into a new view (path being /Views/Home/homepage.cshtml), but it fails with the error: "NullReferenceException was unhandled by the user code" - sorry, but I'm unsure what this means?
Would someone mind explaining why simply copying the code to display data from the database from one View to another View doesn't work? Apologies for being thick, but I'm a beginner with no coding background.
I can post the Controller code if required.
Many thanks.
Comment: It means you are not passing a model to your other view. when you return the home view in the controller you need to pass the same model like you will have done in the news action.
Comment: does error occured when navigation to home.aspx?
Comment: Thank you Musefan, that explains it perfectly - all working now :-)
Answer: maybe you omitted passing model to view when calling it.you can do this like :
public ActionResult HomePage()
{
    IEnumerable<dale_harrison.Models.News> model = new List<dale_harrison.Models.News>();
    // prepare your model (populate it with proper data)

    return View(model);
}


Is there a way to recover macros from compiled code?

Question: I've been thinking of reversing some firmware I have laying around. One characteristic of the firmware is that it is compiled using lots of pre-processor macros. Now, as I understand it, these are not included in the binary, so a decompiler cannot help with these. Is there any way to recover these? Is there a known technique for inferring their existance?
Comment: Although the answers seem to be authoritative in their "No", I don't see offhand why such a translation system couldn't be written to at least make an effort. At heart,  think of this as text substitution going on which is *sometimes* reversible.  If my macro does a substitution of "abc" -> "x" and "def" -> "x", then when I see "x" it might be "abc" or "def" or just "x".  Bad. However in practice it works the other way where the bigger and more unique string is generally on the right-hand side. So I imagine that there might be *some* situations that could be detected.
Comment: When I wrote the post I was thinking more from a heuristic type of place, like if you saw a piece of code that seemed to be copied in a way consistent with the way the compiler handles a macro. In retrospect that would be pretty hard/impossible.
Answer: No.  Decompilers can include special pattern-matching heuristics layered on top of their other functionality to detect macros, but in general, macros are just pieces of code that get treated by the compiler the same way as other pieces of code.  They might be subject to optimizations that transform their appearance, such as constant propagation, dead code elimination, common subexpression elimination, loop-invariant code motion, etc. which means they might not manifest themselves with an easy-to-solidify syntactic pattern that can be matched against.  Your options are basically to write a post-pass for the decompiler (e.g. a Hex-Rays plugin) or to identify the macros manually.
Comment: And you may as well forget about conditional compilation.
Answer: No.
Macros are pieces of code that you have named.At compilation time when the compiler encounters a macro it just replaces it with the code behind it, then continues the compilation.


VS 2019 cannot deploy Sharepoint App - Missing AddSharePointResolver task

Question: We have a Sharepoint App that we have been maintaining & improving for a few years now.  The app is javascript/html code.  I recently (about 3 weeks ago) moved the solution to a new computer and upgraded the solution in VS 2019 and at that time I was able to deploy the App without issue.
Since then I have installed a some Microsoft Version Updates for VS 2019 that I was prompted to install.  The current version of VS 2019 is 16.3.10.  I have also set up the project with version control with a local Git repository and Teams Services.
Now I am not able to deploy the solution due to the following error that occurs when I deploy either the Solution or the App.
The error is as follows:

The "AddSharePointResolver" task was not found. Check the following:

1.) The name of the task in the project file is the same as the name of the task class.
2.) The task class is "public" and implements the Microsoft.Build.Framework.ITask interface.
3.) The task is correctly declared with  in the project file, or in the *.tasks files located in the "C:\Program Files
  (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin"
  directory.

To this point, to my knowledge, there have not been any "tasks" in the project nor do I know what these actually are.  I cannot find any reference on the internet to "AddSharePointResolver", within the solution, or on the internet.
After some investigating:

The Microsoft.Build.Framework.ITask interface isnt on my computer
There are no *.tasks files in C:\Program Files (x86)\Microsoft Visual
Studio\2019\Community\MSBuild\Current\Bin
I searched for the term "UsingTask" in the solution and it was not found

I'm a bit baffled as to what has changed to prompt for this and what it is actually referring to.
Any advice would be greatly appreciated.
Cheers
Greg J
Comment: Hi, Did you even figure out what this was?
Comment: Restarting the computer helped me. I should stop working with Microsoft Technologies! SMFH!!
Answer: ok so a bit late getting back to this but I did end up resolving the issue.
I reinstalled the Visual C# component, which was the format of the project of the app I was trying to build.


What do we call public schools with entry exam?

Question: I was looking for an equivalent for a type of school that we have in our country (they usually have entry exams) and I faced this phrase "public exemplary schools". Do we have such schools by this name generally? Is it common?
Comment: What do you mean by "public school"? The term has almost completely opposite meanings in British and American English.
Comment: We can't tell you if an equivalent institution exists if you don't describe what the institution is in the first place. Is this a classification, or some kind of ranking or award? How does it fit into the larger education system? Is there a link to a full description of it? Additionally, educational systems and labels vary widely by locale; in the U.S., schools only a short distance apart can be very different because the practices of their school districts or states differ. At some point, this ceases to be a question about English and becomes one of specialist terminology.
Comment: @Farzaneh In the U.S., a magnet school is one that teaches a specialized curriculum; it is not a tier or track like a *grammar school* in the UK or a *gymnasium* in northern Europe. Indeed, not all magnet schools require entrance exams, and not all are exclusive. To make this question easier to answer, I suggest you [edit] your question and simply describe the school as it exists in your locale, and what it is called, then ask if there is an equivalent in the specific locale you are interested in (Australia, UK, US, etc.).
Comment: In what country or countries?
Comment: Translating school types is usually hopeless.
Comment: @Jasper we have such schools in Iran but I mean if this equivalent "public exemplary school" can be used generally
Comment: Do you mean a "[laboratory school](https://www.infogalactic.com/info/Laboratory_school)" or "demonstration school"?
Comment: @Jasper No, check this https://goo.gl/YE3G6s it shows different types of schools, there is magnet school that  has entry exams but what I'm looking for is more similar to charter schools but with entry exams, they are not as selective as magnet schools
Comment: @choster check this goo.gl/YE3G6s it shows different types of schools, there is magnet school that has entry exams but what I'm looking for is more similar to charter schools but with entry exams, they are not as selective as magnet schools
Comment: @Farzaneh I still don't understand what you are trying to ask. These are some types of schools that are found in the U.S., but what are we supposed to be comparing them to? What are the characteristics of a "public exemplary school"?
Comment: @choster look, there is an entry exam, students who get the high scores will go to magnet schools (schools for talented students) but there is also another public school which I mentioned that those who got lower marks and can't go to magnet schools go there, and after that we have public schools which any one can go.. I hope I made my point clear
Comment: @JamesK I mean free state-run schools
Answer: In the UK, free state-run schools that require students to pass an exam to enter are called grammar schools. They are relatively rare now, only a few regions of the country still have them, but they have been widespread.
The name is because, traditionally, only at a grammar school could you learn Latin Grammar.
I believe that the term is not used in American English. In American English a "grammar school" is a school for younger pupils aged about 6-12. The terms used in American English are quite different to British English; for example in British English, a "public school" is a school that charges fees and is independent of the government. In America, a public school is state-run and doesn't charge.
What this means is, unfortunately, there is no term that is widely understood across all dialects of English for a "public school with an entrance exam"
Comment: In the US, a "grammar school" is school for younger children. When I was a boy, we had "kindergarten"; then "grammar school", also called "elementary school", grades 1 to 6; then "junior high", grades 7 to 9; then "senior high", grades 10 to 12. When my children were in school, they had "middle school" for 7 to 8; then "high school" for 9 to 12. I don't know if this changed over time or if it's different in different parts of the country. Anyway, in the US "grammar school" doesn't have anything to do with whether there's an entrance exam, it's about what grades it teaches.
Comment: What about public schools with entry exams? We don't have any name or phrase in general english so a I could use it in may translation?
Comment: @Farzaneh Please read the first sentence of my answer, which should answer your question, if you are writing in British English.
Answer: I am not aware of any well-known term in US English for a school that has an entrance exam. "Magnet schools" are public schools that serve more advanced students, but the name does not indicate how they decide who to admit. "Exclusive schools" are difficult to get into, but again, whether they select based on an entrance exam, grades in previous schooling, or whether your parents are willing to pay high tuition isn't implied by the name.
Answer: There is a term that is used in American English for free, state-run schools that require an entrance exam, but it isn't common or well-known, primarily because this kind of school isn't common in the US. We call them exam schools or occasionally competitive public schools (see, e.g., the definition in The Black Student's Guide to High School Success or this Salon article on the subject).
However, so far as I know the exam is generally peculiar to each individual school—that is, schools have their own tests, and you either get in to that school or you don't; there isn't a tiered system where highest marks send you to one school, and lower (but still high) marks send you to a different school. Even if there were such a scheme in some particular school system, there probably still isn't a widespread name to distinguish the two types of exam schools.
Answer: In Australia, those types of schools can be called 'Selective schools', as seen in the article below:
https://en.wikipedia.org/wiki/Selective_school_(New_South_Wales)
Comment: @Farzaneh In New South Wales, selective schools are public high schools, and are for years 7 to 12. "Partially selective" schools have both selective and non-selective streams.
Comment: @Farzaneh Depending on your location, the junior section can mean different things. I'd say 'Selective High School for grades 7-9', unless, in your area, junior high school is widely understood as those grades. However, if that's the case, I think 'Selective Junior High School' is better worded.
Comment: I've checked the above link, that's probably what I'm looking for, could you tell me If this phrase is structurally correct "Junior Selective High School" , I mean the selective school for junior students, grade 7 to 9
Comment: "Selective school" would be understood in British English too.


How to share files/folders between two different Ubuntu computers and are on different network?

Question: I want to share the folders between my laptop and local desktop. Both are connected to WiFi and ethernet respectively. How do I share the folders between these two?
Thank you!
Answer: If computers are connected to different networks, this can be achieved using Hamachi. It enables computers to see each other as if they were in the same network. It can be used with very nice front-end called Haguichi.

If your computers are connected to the same local network start from here.
Now you need to share files somehow. Fortunately, Ubuntu makes it really easy. Just right-click any directory and pick Local Network Share.
Window like this one should pop up:

Then configure your share and click Create Share.
On the other PC
Open Nautilus, click Connect to Server on the left menu. Another dialog should pop up:

Type in smb://[ip address of the other computer here] and click Connect.
If you use Hamachi, you will need to provide host's IP as seen by Hamachi. Either use hamachi list command or right-click other computer in Haguichi and select Copy IPv4 Address.
And that's it!
Answer: If you are capable to establish SSH connection between these two computers, you can use sshfs to mount a remote folder (even entire filesystem, if you have right permissions).
sudo apt update && sudo apt install -y sshfs

For example, if you are using key authentication, the mounting command looks like:
sshfs username@hostname_or_ip:/path/to/remote-folder/ /path/to/local-folder/ -p 2222 -o IdentityFile=/path/to/ssh-key/id_rsa

-p 2222 you can omit this option, if you are using the default ssh port 22;
-o IdentityFile=/path/to/ssh-key/id_rsa you can omit this option, if yours key is placed in the default location (~/.ssh), or if you using ~/.ssh/config file;
username@hostname_or_ip you can replace this entry with its equivalent short name, if you using ~/.ssh/config file;
use sudo umount /path/to/local-folder/ to unmount;
for more details check: sshfs -h or its man page.

So, if the ~/.ssh/config file looks like:
Host rh1
    HostName 188.8.131.52
    IdentityFile ~/.ssh/remote-host-1/id_rsa
    User spas
    Port 22

Host rh2
    HostName 184.108.40.206
    IdentityFile ~/.ssh/remote-host-2/id_rsa
    User spas
    Port 2222

The mounting command will looks more simple:
$ sshfs rh1:/path/to/remote-folder/ /path/to/local-folder/

Once sshfs mounting works, you can:

create custom by script file, alias or funcion for fast mounting;
create fstab entry for permanent mounting (also here and here);
or create pure ~/.bashrc entry, which could be enough for particular cases.
Answer: My preferred method is to use an online sync with a local client, which has the additional benefit of storing your data in the cloud. This is useful for instance if you have a PC at home and one at work/study, or in the extreme case that both of your computers fail.
I have experience with two clouds, which are very good: Dropbox and Mega. There are plenty more.
To share folders

Install the client in both computers (see links above). Both create a menu entry. (Dropbox seems to have a bug relating its icon. See this answer to fix).
Open the client in the computer which has the original folder and then create the sync. For example, in Megasync, right-click on the panel icon and select settings. Then, go to Sync tab, and select Add. Choose the local folder to share, and create a folder in your cloud. You should get something like this:

When you press OK, the files will start to be uploaded to Mega. The process is more or less similar with Dropbox. More details at the bottom of the post.

Once the upload is complete, open the client in the other computer, and create a sync. Now, select the folder in the cloud, and a new, empty folder as local destination. The client will understand and start downloading the data in the cloud to your new folder.

That's it. Your two folders are in sync and secure in the cloud.

As I said, there are many sync clients. I prefer Mega because:

it gives 50GB for free (Dropbox only gives 2GB)
it is cheaper than Dropbox (if you go Pro)
you can sync anywhere (e.g. ~/Music); Dropbox sync only the content inside a "Dropbox" folder (e.g. ~/Dropbox/Music), which is annoying.
you can have many folders synchronized (~/Music, ~/Pics/My_puppy, ~/.q3a); Dropbox only allows for stuff inside the same "Dropbox" folder.

The only problem I see is that Mega can go bust at any time (because of copyright issues). It happened to Megaupload before. Dropbox might me more secure.


Why is my cat losing hair in small patches on her head?

Question: I have noticed about two weeks ago that when my cat came back inside she was losing hair on the top of her head. There is a bit of dandruff, but the hair is slowly growing back. She is also showing signs of pregnancy, so if this is something to do with that, I have no clue.
Comment: Welcome to pets.SE! There could be some more causes which result in bald spots. From malenutrition (maybe caused by more needs while pregnant) over allergy to little animals like bugs or scabies. If the cat scratches the spots you should visit a vet in very near future. In general you should prefer the meaning of a vet more than the guesses of strangers in the internet ;) especially if you in worry about the health of your pet!
Answer:
An unhealthy diet, poor health or an undetected disease can all be causes for your cat to lose their hair. As these are all quite broad reasons, it's important to visit your vet to identify the underlying cause. Some causes for hair loss in cats can also affect humans, and are contagious.

According to this article at purina.co.uk.

Anxiety medications, synthetic feline facial pheromone spray, or other calming aids could prove helpful as well. Regular tick and flea control medication is also essential to keep the cat healthy and rule those pests out as a possible reason for hair loss.

According to this article at thesprucepets.com.
Answer: one likely possiblity is ringworm fungal infection (the same organism that is responsible for ringworm in public showers). cats can easily contract it from other animals and dirt and is considered highly contageous. for this reason i must agree with the first response to not attempt to diognose or treat this condition without a proper visit to your veterinarian. ESPECIALLY if she is pregnant as it could spread to the infants who are especially high risk for contracting it.


Deleting a Drupal 8 Content Type Field also Deletes all the Views linked to it... Undo?

Question: So I deleted a Drupal 8 content type field and it also deleted the views that is associated with it. Is there an undo button?
Comment: `Is there an undo button?` You backup your site daily like all the other good developers do, right? ...
Comment: No, there is no 'undo' button. This is a known core issue. This sort of behavior was also recently fixed in Paragraphs as well, where deleting a referenced paragraph type would also delete any field using it and all of its configuration. https://www.drupal.org/node/2468045
Answer: Yes, that's what currently happens. Drupal informs you on the delete confirmation page what all will be deleted.
You can try one thing that to restore your backed up database.
Also, there is an issue that tries to improve it so that the view updates itself instead.
Answer: There is no undo button. Deleted configurations are deleted configurations :-(
With Drupal 8.4: It is not deleting the view anymore - it is disabling the view so you can change your view and enable it again.

(taken from the issue Ashish mentioned above, Picture by vaplas)
Comment: I'm on 8.7.2 and still seeing this issue, just FYI.


They are like pieces of a puzzle in that they complement one another to form the whole

Question: Does in that make my sentence formal? If so, how can I change it to be more neutral?
Answer: You'd really need to specify your target audience if you want to fine-tune a sentence like that. There would be no problem with it in The Atlantic, say, or The Economist, but it might stand out in People as the phrase in that is not in the working vocabulary of a good percentage of native speakers.
If you wanted to get rid of it entirely and were willing to reorder your sentence

Like the pieces of a puzzle they complement one another.

But even the word complement would give some readers trouble.
If you want also to say "to form the whole" you're back to square one again, as the register of that phrase, with "the whole", is elevated above conversational— again for a large percentage of native speakers but by no means all.
P.S. If you find yourself explaining your metaphor, you're generally on thin ice.
Comment: I see. Is it necessary to use the definite article before **pieces**?
Comment: "*the* pieces of a puzzle" would suggest all of them, whereas "pieces of a puzzle" could mean only some of them, and so, if by "form the whole" you mean "*complete* the whole" not merely "*contribute* to the whole", then you'd want to use the article.
Comment: In a way "in that" makes the sentence more accessible to less sophisticated readers.  Where grammarians see a noun clause in a prolix prepositional phrase, the mind's ear hears two declarative sentences joined by an explicit clue to the relationship between them.  What more could an audience not in a hurry ask?
Comment: @remarkl:   I don't think your calling "in that" an "explicit clue" makes sense in that if you don't know what "in that" means it is not much of a clue at all.  That's a fairly sophisticated use of the preposition **in**.
Comment: @TRomano I don't think that matters all that much.  The two straightforward "sentences" that it enables seem to me to make the meaning very accessible.  I agree that an unsophisticated speaker would not use "in that," but I am less sure that the structure would be difficult for an unsophisticated audience to interpret.  But you may be right.
Comment: @remarkl:  We'll just have to find us some "unsophisticated" speakers. For me, that won't pose any problem at all.
Answer: I believe a re-arranged version is more neutral:
They complement one another to form the whole, like pieces of a puzzle.
(One could use '...like the pieces of a puzzle.' here; I see little difference between them.)
There's a great many valid ways this could be re-arranged, but I think this version is the least-belaboured.
Comment: What is being emphasized, that "they" are like puzzle pieces, insignificant looking on their own, or that the picture they combine to create is like a puzzle, visible only by combining the pieces?  That emphasis should determine the word order and the choice to use "pieces" (if the nature of the pieces is the focus) or "the pieces" (if the nature of the picture is the focus).


One quarter of the roots of a 50' tall white pine were cut off. Can I save it?

Question: About one quarter of the roots of a 50 foot tall white pine were cut off at the drip line, all on the same side. Can I save this tree?
Comment: How were they cut?  How deep is the trench?  Where do you live? Can you add a picture?  What kind of soil?
Answer: if they were cut at the dripline, and only on one side, I suppose that means a good bit less than 1/4 of the roots have been cut. Assuming that the tree is between 16 and 22" in diameter four and a half feet above ground, your structural root radius (that you can't safety be cutting within) will be 8-9'. This is the root plate, which supports the tree. Cutting into this will put you at risk of the tree coming down. That's your structural root zone. You also have to consider your critical root zone.
The critical root zone is the zone within which any cutting (or traffic from construction vehicles) will be extremely damaging to the tree. Do not work within this radius. Again assuming a tree diameter of 16 - 22", your critical rooting zone will be from 20 - 28', respectively.
If the roots on your tree were cut past that point, you should be fine. Mulching lightly (like 3") under the dripline will help recovery a lot. If the roots were cut inside the critical root zone, your tree may decline. Whether it will recover in that case depends partly on what the roots were cut for. If the soil was replaced (like if it was a trench for a line, and was backfilled), that's great. If the area the roots were cut is going to remain unviable for root growth (such as if you had a foundation put in, or regraded), things may be less bright.
In either case (of disturbing the critical root zone), there are a few steps you can take to help the tree survive. Maintain a layer of mulch under the tree (3-4" is good), keeping it off of the root flare, and have it out at least to the dripline, if possible. Also, reduce traffic (even foot traffic) as much as possible, to help prevent compaction.
I have very few details about your tree to go on, but I feel you will probably be fine, white pines can be quite resilient.
Answer: Please send pictures but if only 1/4 of the roots were compromised I think this tree will survive.  I'd water it, of course until it can recoup the roots lost.  Perhaps purchase some mychorrhizae to help.
Answer: It'll be fine, that's nothing. It has a whole rest of the root network to support it.


Can a square world/planet work?

Question: I'm working on a idea of  making a half square/cuboid, half sphere world. The shape of it will be like this from the side and I'm planning to make the cuboid side the main area where my story and stuff will be held. So how would gravity (or literally anything) work there ?
Comment: Factoid: a search on WB.SE for [cuboid planet](https://worldbuilding.stackexchange.com/search?q=cuboid+planet) currently results in 9 results.
Comment: This might be of interest, even if it might add more question than answers: [Time Cube](https://timecube.2enp.com/). Earth is (apparently) a cube. It even has [a Wikipedia page](https://en.wikipedia.org/wiki/Time_Cube).
Comment: No any body larger enough to be called a planet will (if not spherical) collapse into a roughly (they do tend to bulge a bit due to spin) spherical shape under the weight of its own gravity so even if you engineered it into a cube by some mighty act of engineering it would only be temporary // & also, this is already asked & answered on this site.
Comment: It got closed too fast!  Check this out.  https://www.wikiart.org/en/m-c-escher/tetrahedral-planetoid.  Your cuboid side is a built thing - a 3d megalopolis jutting up and off the planet.  It is not as dense as the planet and so concerns re gravity crushing etc don't apply.
Comment: I heard that someone asked Newton at a party why planets were round, and he went home and invented calculus because no math existed yet that could answer the question. Which either says a lot about how brilliant he was, or a lot about how boring he was at parties.
Answer: Under our current laws of physics, any body of sufficient mass will be under hydrostatic equilibrium, assuming a spheroid shape.
For a body with the radius and mass of Earth, the maximum elevation is a bit short of 9000-10000 meters (see here), which is consistent with the tallest peak we have on Earth, mount Everest.
For your world to work under our laws, it has to be really small, like an asteroid or a comet. And that implies it is not really life friendly, due to the extremely low and "weirdly oriented" gravity on its surface.
Comment: Then I gotta use some magical gibberish then?
Comment: @AdrianColomitchi, see edit
Comment: `the maximum elevation is a bit short of 9000 meters` I'd love some details on that. Do you have a link or ref, please?
Comment: Heh, first order approximation as it may be, but it works even for the case of [Olympus Mons](https://en.wikipedia.org/wiki/Olympus_Mons) on the lower gravity of Mars.
Comment: @ArouraAnhis69 - Magic or Sufficiently Advanced Technology - the planet could be assembled by some sort of planet builders who have some sort of material that is impossibly strong.
Answer: I'm just assuming this planet exists as an earth-sized thing.
According to Google the atmosphere is 480km thick, with most of that atmosphere located between 0 and 16km of the surface. This atmosphere would try to go to the lowest area, and those peaks on the cuboid side are the highest. They would be much much more than 16km high and people would not be able to live there.
Just imagine being on the beginning of the cuboid/sphere area. Gravity points to the center of the sphere so its straight down.
The farther you go on the cuboid area the more angle you get compared to the center of the earth. At the tip/edge of the cuboid gravity is at a 45 degree angle so it is a steep mountain you are climbing for those last kilometers. A mountain with too little air to breathe and any material with an angle of repose less than 45 degrees will be tumbling down the cuboid side for kilometers, gaining speed most of the way (small atmosphere!).
So if you want to do this you have to handwave the air (unless its an advanced species that uses this weird shape as a massive space elevator) and the structural integrity of the cuboid part. All interactions would also take place either at an angle or on platforms that are at a good angle with gravity.
Comment: The cuboid parts aren't mountains, it's hard to describe because the picture is 2D, but they aren't like mountains
Comment: For the intents and purposes of your question they function as one giant continuous mountain. They dont have to be made of rock, they could be artificial or natural it doesnt matter: functionally they'll act like the biggest mountain you've ever seen.

Can a square world/planet work?


TwitPic filter by hashtag

Question: I want to display twitPic photos with the hashtag of #animals. Currently, I am displaying photos through the username. This is my code below:
<code> $username = "smcsconverse";

//this is your twitpic RSS feed...
$yourRSS = "http://twitpic.com/photos/".$username."/feed.rss";
</code>
However, I am now stuck with how retrieving pictures through a given hashtag. I have been stuck quite awhile on this.
Answer: Looks like twit pic has added a beta hashtag search. Here is the documentation.

TwitPic filter by hashtag


How to type a backslash in emacs "\"

Question: I'm on Prelude, and there is no way I can type a \. I was thinking maybe I should create a keybinding but I don't know how to create it to output a character such as \. Any help welcome! Thank you!
Comment: What does `C-h k \ ` tell you?
Comment: What is Prelude? Why is there no way to type a `\\`? Do not expect other people to know what you are talking about just because you can see it: please explain.
Comment: Do you see the same thing when you start Emacs using `emacs -Q` (no init file)? If not, bisect your init file to find the culprit.
Answer: Emacs by default doesn't associate \ with any command… You should be able to directly type it without any trouble. If you cannot, then you should have a module enabled, which takes it.
If you need further help, please answer the following questions:

are you using emacs in terminal (in a TTY?) or in graphical mode?
where do you want to type a backslash? In a document body, in the minibuffer, elsewhere?
as @phils asks, what does C-h k \ give you?
what is your keyboard layout?
Comment: To be more precise, most keys are bound to `self-insert-command`, which is the command that inserts the key you pressed into the buffer.
Comment: Apologies. I managed to find the keyboard binding for that \. Apparently I needed the RIGHT Alt key, not the left one (even though in the Mac Kayboard layout both are giving the backslash). When I type C-h k \ I get "\ runs the command org-self-insert-command (found in org-mode-map), which is an interactive compiled Lisp
function in 'org-9.3.6/org.el'. It is bound to SPC..~, ..\377. (org-self-insert-command N). "
Answer: As a work-around you can try C-q \.  Try Étienne Deparis answer for a permanent resolution.
Comment: I did not get how to get \ if I can type it :P
Comment: Do you not have a \ key on your keyboard then?
Comment: I resolved this issue. My keyboard produces it outside Emacs when pressing SHIFT+ALT(left or right)+7. I always use ALT(left). Since it did not work in Emacs, I thought something was wrong. Apparently some other keybinding is associated with that combo, but using ALT(right) works.
Comment: I've never encountered such a keyboard.

How to type a backslash in emacs "\"


Trying to find title of book from 70s or 80s about super intelligent being

Question: From memory, the story had some military themes. Person or being became increasingly powerful and telepathically connected to everything and everyone. Think it was primarily set in UK. There may have also been reference to people losing minds/senses. Would like to read again (as have clearly forgotten quite a bit about it!)
Comment: Do you remember any of the following details: An investigator researching a report of a girl with psychic powers living on a remote Scottish island? The investigator later discovering that he has psychic powers himself? The use of sensory deprivation chambers? A Russian team of researchers who have kept a nine year old boy in a sensory deprivation chamber for all of his life?
Comment: Other than the U.K. setting, it sounds like Blood Music by Greg Bear (https://en.wikipedia.org/wiki/Blood_Music_(novel)). Leaving this as a comment because it's a long shot.
Comment: Thanks. It's not the one I remember but might give it a go anyway.
Answer: Fountains of Paradise by Arthur C Clarke maybe?

In the 22nd century, Dr Vannevar Morgan is a famous structural engineer who hopes to develop the 'space elevator' from a theoretical concept to reality and enlists the resources of his employers to carry out experiments. But the only suitable starting point (Earth station) for the elevator lies at the summit of a mountain in Taprobane occupied by an ancient order of Buddhist monks, who implacably oppose the plan.
Morgan is approached by a Mars-based consortium to develop the elevator on Mars as part of a massive terraforming project. To demonstrate the viability of the technology, Morgan tries to run a thin cable of 'hyperfilament' from an orbital factory down to ground level at Taprobane. A monk at the monastery, a former astrophysicist who is a mathematical genius, tries to sabotage the attempt by creating an artificial hurricane using a hijacked weather-control satellite. His attempt succeeds, but the hurricane blows butterflies to the peak of the mountain. This fulfills an ancient prophecy that causes the monks to leave the mountain. The tower can be built on Earth after all.
Forced to resign his position for acting beyond his authority, Morgan joins the Martian consortium named 'Astroengineering' and construction of the Tower commences.
Comment: Why do you think so? Can you tell us what elements of the story caused you to suggest this, can you tells us how the story elements may differ. The more detail you provide the more helpful your answer will be.
Comment: One liner opinions can be posted as comment.
Comment: I don't think this is the answer.  From what I recall, Fountains of Paradise was about a space elevator.  There are some advanced aliens, but they only have a probe at the beginning of the book as a plot device, and appear at the end when humanity has connected space elevators into a ring.  They are not part of the plot.


How to merge rasters with nodata cells in Arcgis

Question: I want to create a single attribute table base on multiple overlapping raster. Some raster do not overlap completely but have common areas. In that situation I need the value from other raster while keeping the non overlapping raster value as missing. I am using arcmap 10.
Answer: There are a few methods to tackle using map algebra, extract by mask, and the reclassify tool. For example:
Raster A = base raster
Raster B = additional raster who's values you want to use only in overlapping areas
Method.
1.) Use raster reclass to set all values other than "no value" to 1 for Raster B.
2.) Use raster math to multiply Raster A and the product of Step 1. The result will be a Boolean raster. Any value that isn't "no data" is an area of intersection.
3.) Use raster reclass on the newly created Boolean raster to set "No Value" to "1" and all other values to "0". The result will be an inverted product of Step 2.
4.) Use raster math to multiply Raster A with the product created in Step 3. The result will be a raster where all areas of non overlap between A and B is set with A values. Areas of overlap will be zero.
5.) Finally, use raster math to add the Step 4 product to the original Raster B. The result will a product raster that displays Raster A values in all cells except those that intersect (non-null) with Raster B. In those areas Raster B values will display.
There may be a more elegant solution that someone else can chime in with.
Comment: You can do this in a much more efficient way by setting your analysis extent to the maximum of all the rasters, create a background value for each raster using SetNull() and then use Combine() to overlay and get all of the original/all-combinations raster values in the raster attribute table.
Answer: IMPORTANT : please take into consideration that this solution could work but only for small areas or low resolution rasters, as it can be very computionnaly expensive.
You could create a point layer on the common max extent of all your rasters with a step based on the smallest pixel size then collect all raster values with one tool.

You can do that from a big polygon you create on your work area.
You rasterize it with the Polygon to raster tool for example, pixel size the smallest you have.
You convert it to points with the Raster to point tool.
You then simply use the Extract Multi-values to points tool from Spatial Analyst to get any raster values (including NULL values where there is nodata) from all you rasters.

It will generate a global attribute table you need with a field for each raster you selected, free to you to perform an analysis on a new column then recreate a raster from it with the Feature to Raster tool
Comment: This is not very good advice and computationally very expensive. You would effectively negate the advantage of using rasters and there are simple approaches that can be taken using raster algebra.
Comment: It is very computionnaly expensive but it works when the pixel data is in reasonnable amount. I agree it is not to be done on wide areas, but it works pretty well on small areas or low resolution. However, I lack the knowledge in the question to give a better advice, as I usually adapt the way I compute data from the info i receive. I'll add a warning to my answer


How do I setup SFTP for sites without giving shell access?

Question: I'd like to use SFTP for all the sites on my cPanel CentOS server as we had an FTP password hacked before (not hard). However I don't want each sites SFTP account to have shell access (not even jailed shell). Is this possible and how? I'm quiet new to UNIX, server management and the command line.
Answer: I'm not sure which version of OpenSSH is bundled with CentOS, but if it is 4.9 or newer then you can actually do it with OpenSSH with no need to install any additional software.
I wrote a blog post about this recently, you can check it out here:
http://blog.frands.net/sftp-only-chroot-users-with-openssh-in-debian-166/
The guide is for Debian, but it's pretty much the same if the version of OpenSSH is 4.9 or more. You find out the version by issuing this command:
<code>ssh -V
</code>
Also, in my example I use a static directory for all users. You can use %u in the config file, which will be replaced by the username. So the ChrootDirectory could be set to /www/users/%u
Comment: +1 for no add'l software!
Comment: Excellent blog post Frands! I followed it to a T and everything **just worked**
Answer: Set scponly as login shell for those users.
Answer: RSSH - Restricted SSH will do what you are after.
RSSH is a shell wrapper that will only allow a user to access the SSH parts you permit, it's a bit tricky to set up at first with a chroot environment etc.
http://www.pizzashack.org/rssh/
Answer: You may want to consider MySecureShell which offers:

Control of bandwidth. Security rights
  informations. Administration of the
  server with a graphical interface.
  Management of activity of the server
  with logs. Restrictions of users by
  ip, groups.

I've used this in the past; it's straightforward to install and configure and is actively developed. For you, there are CentOS packages and a GUI to help with configuration and administration.


Shortcut to step back in the block hierarchy in Trackmania Nations Forever's map editor?

Question: In Trackmania Nations Forever's map editor, is there any shortcut to step back in the block hierarchy?
I read on http://bandofscousers.proboards.com/thread/1652/tm2-map-editor-guide :

Besides using the mouse to click on them, you can use the keyboard
  keys 1-9 to reach them, and the ^ key to make 1 step back in the block
  hierarchy. Then use the mouse to move around the map, and use the
  mousewheel to select the desired height to place the part.
  Alternatively, use the cursor keys and the Scroll up/down keys

However  ^  does not seem to work in TMF (the guide was written for TM2).
Comment: I'm still interested in the answer.
Comment: If anyone has any idea.
Answer: You can do that with the right mouse button